/*main*/

*,
*::before,
*::after {
  box-sizing: border-box;
  padding: 0;
  margin: 0;
}

body {
  font-family: 'Roboto', sans-serif;
  color: var(--slate);
  background-color: #ffffff;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/*main {
  flex-grow: 1;
}*/

:root {
  --second-family: 'Raleway', sans-serif;
  --iris: #4d5ae5;
  --ocean: #404bbf;
  --navy-blue: #2e2f42;
  --green: #31d0aa;
  --slate: #434455;
  --light-slate: #8e8f99;
  --cornflower: #e7e9fc;
  --cloud: #f4f4fd;
  --navy-blue-modal: rgba(46, 47, 66, 0.4);
  --grey: rgba(46, 47, 66, 0.7);
  --white: #ffffff;
  --dairy: #fcfcfc;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0;
}

p {
  margin: 0;
}

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style-type: none;
  margin: 0;
}

.container {
  max-width: 1158px;
  padding: 0 15px;
  margin: 0 auto;
}

img {
  display: block;
  max-width: 100%;
}

/*head*/

.header {
  border-bottom: 1px solid #e7e9fc;
}

.container-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 15px;
}

.accent {
  font-family: var(--second-family);
  font-weight: 700;
  font-size: 18px;
  line-height: 1.17;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--navy-blue);
}

.site-logo {
  font-family: var(--second-family);
  font-weight: 700;
  font-size: 18px;
  line-height: 1.17;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--iris);
  margin-right: 76px;
}

.header-nav {
  display: flex;
  align-items: center;
}

.header-list {
  font-weight: 500;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.02em;
  color: var(--navy-blue);
  display: flex;
  gap: 40px;
}

.header-list-link {
  display: inline-block;
  padding: 24px 0;
}

.header-list-link:hover,
.header-list-link:focus {
  color: var(--ocean);
  text-decoration: underline;
}

.address {
  font-style: normal;
}

.address-list {
  display: flex;
  gap: 40px;
  align-items: flex-end;
}

.address-link {
  font-weight: 400;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.02em;
  color: var(--slate);
}

.address-link:hover,
.address-link:focus {
  color: var(--ocean);
}

/*title*/

.title {
  background-color: var(--navy-blue);
  padding: 188px 0;
}

.main-title {
  font-family: var(--font-family);
  font-weight: 700;
  font-size: 56px;
  line-height: 1.07;
  letter-spacing: 0.02em;
  color: var(--white);
  margin: 0 auto;
  margin-bottom: 48px;
  max-width: 496px;
}

.title-button {
  font-family: 'Roboto', sans-serif;
  font-weight: 500;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.04em;
  color: var(--white);
  background-color: var(--iris);
  cursor: pointer;
  border-radius: 4px;
  height: 56px;
  padding: 16px 32px;
  box-shadow: 0 4px 4px 0 rgba(0, 0, 0, 0.15);
  background-color: var(--iris);
  display: block;
  min-width: 169px;
  border: none;
  margin: 0 auto;
}

.title-button:hover,
.title-button:focus {
  background-color: var(--ocean);
}

/*info*/

.info {
  padding: 120px 0;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  border: 0;
  padding: 0;
  white-space: nowrap;
  clip-path: inset(100%);
  clip: rect(0 0 0 0);
  overflow: hidden;
}

.info-list {
  display: flex;
  flex-direction: row;
  justify-content: center;
  gap: 24px;
}

.info-item {
  width: calc((100% - 72px) / 4);
}

.title-benefits {
  font-weight: 500;
  font-size: 20px;
  line-height: 1.2;
  letter-spacing: 0.02em;
  color: var(--navy-blue);
  margin-bottom: 8px;
}

.title-benefits-text {
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.02em;
}

/*team*/

.team {
  padding: 120px 0;
}

.team-list-head {
  font-weight: 700;
  font-size: 36px;
  line-height: 1.11;
  letter-spacing: 0.02em;
  text-align: center;
  color: var(--navy-blue);
  text-transform: capitalize;
  margin-bottom: 72px;
}

.team {
  background-color: var(--cloud);
}

.team-list {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: row;
  gap: 24px;
}

.team-list-img {
  width: calc((100% - 72px) / 4);
  background-color: var(--white);
  border-radius: 0 0 4px 4px;
  box-shadow: 0 2px 1px 0 rgba(46, 47, 66, 0.08),
    0 1px 1px 0 rgba(46, 47, 66, 0.16), 0 1px 6px 0 rgba(46, 47, 66, 0.08);
  background: var(--white);
}

.team-list-img img {
  height: 100%;
  width: 100%;
  object-fit: cover;
}

.team-info {
  padding: 32px 0;
}

.team-list-name {
  font-weight: 500;
  font-size: 20px;
  line-height: 1.2;
  letter-spacing: 0.02em;
  color: var(--navy-blue);
  text-align: center;

  margin-bottom: 8px;
}

.team-list-descr {
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.02em;
  text-align: center;
}

/*portfolio*/

.portfolio {
  padding: 120px 0 120px 0;
}

.portfolio-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  row-gap: 48px;
  column-gap: 24px;
}

.portfolio-list-img {
  display: flex;
  flex-direction: column;
  width: calc((100% - 48px) / 3);
  padding: 0;
  overflow: hidden;
}

.portfolio-list-img img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}

.portfolio-card {
  padding: 32px 16px;
  border: 1px solid var(--cornflower);
  border-top: none;
}

.portfolio-list-head {
  font-weight: 700;
  font-size: 36px;
  line-height: 1.11;
  letter-spacing: 0.02em;
  text-align: center;
  color: var(--navy-blue);
  text-transform: capitalize;
  margin-bottom: 72px;
}

.portfolio-list-name {
  font-weight: 500;
  font-size: 20px;
  line-height: 1.2;
  letter-spacing: 0.02em;
  color: var(--navy-blue);
  margin-bottom: 8px;
}

.portfolio-list-descr {
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.02em;
}

/*footer*/

footer {
  background-color: var(--navy-blue);
  padding: 100px 0;
}

.accent-footer {
  font-family: var(--second-family);
  font-weight: 700;
  font-size: 18px;
  line-height: 1.17;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--cloud);
}

.footer-site {
  font-family: var(--second-family);
  font-weight: 700;
  font-size: 18px;
  line-height: 1.17;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--iris);
  display: inline-block;
  margin-bottom: 16px;
}

.footer-text {
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.02em;
  color: var(--cloud);
  max-width: 264px;
}
