:root {
  --primary-brand: #4d5ae5;
  --dark: #2e2f42;
  --success: #31d0aa;
  --text: #434455;
  --subtle-text: #8e8f99;
  --accent: #e7e9fc;
  --light: #f4f4fd;
  --primary-white-color: #ffffff;
  --section-padding: 120px;
  --card-shadow: 0px 1px 6px rgba(46, 47, 66, 0.08),
    0px 1px 1px rgba(46, 47, 66, 0.16), 0px 2px 1px rgba(46, 47, 66, 0.08);
  --card-shadow-second: 0px 2px 1px rgba(46, 47, 66, 0.08),
    0px 1px 1px rgba(46, 47, 66, 0.16), 0px 1px 6px rgba(46, 47, 66, 0.08);
}

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

a {
  text-decoration: none;
}

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

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

body {
  background-color: var(--primary-white-color);
  color: var(--text);
  font-family: Roboto, sans-serif;
  letter-spacing: 0.02em;
  font-size: 16px;
  line-height: 1.5;
}

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

.button {
  font-family: inherit;
  display: inline-block;
  min-width: 69px;
  text-align: center;
}

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

.section {
  padding-top: var(--section-padding);
  padding-bottom: var(var(--section-padding));
}

/* nav */

header {
  box-shadow: var(--card-shadow-second);
}

.header-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.logo {
  font-family: Raleway, cursive;
  font-weight: 800;
  font-size: 18px;
  line-height: 1.33;
  letter-spacing: 0.03em;
  color: var(--dark);
  margin-right: 76px;
}

.span {
  color: var(--primary-brand);
}

.site-nav .link {
  display: block;
  padding-top: 24px;
  padding-bottom: 24px;
  color: var(--dark);
}

.site-nav .link:hover,
.site-nav .link:focus {
  color: var(--primary-brand);
}

.site-nav {
  font-weight: 500;
  display: flex;
}

.site-nav .item {
  margin-right: 40px;
}

.site-nav .item:last-child {
  margin-right: 0;
}

.site-adress .link {
  color: var(--dark);
  padding-top: 24px;
  padding-bottom: 24px;
}

.site-adress .link:hover,
.site-adress .link:focus {
  color: var(--primary-brand);
}

.site-adress {
  display: flex;
}

.site-adress .item + .item {
  margin-left: 40px;
}

/* hero */

.hero {
  background-color: var(--dark);
  text-align: center;
  padding-top: 188px;
  padding-bottom: 188px;
  max-width: 1440px;
  margin: 0 auto;
  background-image: linear-gradient(
      rgba(46, 47, 66, 0.7),
      rgba(46, 47, 66, 0.7)
    ),
    url("../images/people-office\ 1.jpg");
  background-repeat: no-repeat;
  background-size: cover;
}

.hero-title {
  color: var(--primary-white-color);
  font-weight: 600;
  font-size: 56px;
  line-height: 1;
  margin-top: 0;
  margin-bottom: 48px;
  margin-left: auto;
  margin-right: auto;
  width: 494px;
}

.hero .button-primary {
  color: var(--primary-white-color);
  background-color: var(--primary-brand);
  cursor: pointer;
  font-weight: 600;
  font-size: 16px;
  line-height: 1.18;
  letter-spacing: 0.04em;
  border-radius: 4px;
  padding: 16px 32px;
  border: none;
  box-shadow: 0px 4px 4px rgba(0, 0, 0, 0.15);
}

.button-primary:hover {
  color: var(--primary-white-color);
  background-color: var(--primary-brand);
  box-shadow: 0px 1px 6px rgba(46, 47, 66, 0.08),
    0px 1px 1px rgba(46, 47, 66, 0.16), 0px 2px 1px rgba(46, 47, 66, 0.08);
}

.button-primary:focus {
  color: var(--primary-white-color);
  background-color: #404bbf;
  box-shadow: 0px 4px 4px rgba(0, 0, 0, 0.15);
}

/* adventages */

.advantages-ul {
  display: flex;
  column-gap: 24px;
}

.advantages-li {
  flex-basis: calc((100% - 72px) / 4);
}

.advantages-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 112px;
  background-color: var(--light);
  border-radius: 4px;
  margin-bottom: 8px;
}

.advantages-ul .title {
  color: var(--dark);
  font-size: 20px;
  margin-bottom: 8px;
}

/* our work */

.work {
  padding-bottom: 120px;
  text-align: center;
}

.work .title {
  color: var(--dark);
  font-weight: 600;
  font-size: 20px;
  line-height: 1.2;
}

.work-title {
  color: var(--dark);
  font-weight: 600;
  font-size: 36px;
  line-height: 1.11;
  margin-bottom: 72px;
}

.work-ul {
  display: flex;
}

.work-ul .work-li + .work-li {
  margin-left: 24px;
}

/* team */
.team-ul {
  display: flex;
}

.team-ul .team-li + .team-li {
  margin-left: 24px;
}

.team {
  background-color: var(--light);
  padding-top: 120px;
  padding-bottom: 120px;
  text-align: center;
}

.team-title {
  color: var(--dark);
  font-weight: 600;
  font-size: 36px;
  line-height: 1.11;
  margin-bottom: 72px;
}

.team-li {
  background-color: var(--primary-white-color);
  box-shadow: var(--card-shadow);
  border-radius: 0px 0px 4px 4px;
  padding-bottom: 32px;
}

.team .title {
  color: var(--dark);
  font-weight: 600;
  font-size: 20px;
  line-height: 1.2;
  margin-bottom: 8px;
}

.team img {
  margin-bottom: 32px;
}

.social-ul {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-top: 8px;
}

.social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background-color: var(--primary-brand);
  border-radius: 50%;
}

.social-link:hover,
.social-link:focus {
  background-color: #404bbf;
}

/* customers */

.customers {
  padding-top: 120px;
  padding-bottom: 120px;
  text-align: center;
}

.customers-title {
  color: var(--dark);
  font-weight: 600;
  font-size: 36px;
  line-height: 1.11;
  margin-bottom: 72px;
}

.customers-ul {
  display: flex;
  gap: 24px;
  justify-content: center;
}

.customers-link {
  display: flex;
  align-items: center;
  justify-items: center;
  border: 1px solid var(--subtle-text);
  border-radius: 4px;
  width: 168px;
  height: 88px;
  padding: 16px 32px;
  color: var(--subtle-text);
}

.customers-link:hover,
.customers-link:focus {
  border-color: var(--primary-brand);
  color: var(--primary-brand);
}

.logo-icon {
  fill: currentColor;
}

/* footer */

.footer {
  background-color: var(--dark);
  padding-top: 100px;
  padding-bottom: 100px;
}

.footer-link {
  color: var(--light);
  font-family: Raleway, cursive;
  font-weight: 800;
  font-size: 18px;
  line-height: 1.16;
  letter-spacing: 0.03em;
}

.footer-text {
  color: var(--accent);
  margin-top: 16px;
}

.box-footer {
  width: 264px;
}

.footer-title {
  color: var(--light);
  font-weight: 500;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.02em;
  margin-bottom: 16px;
}

.footer-ul {
  display: flex;
  gap: 16px;
}

.footer-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.1);
}

.footer-icon:hover,
.footer-icon:focus {
  background-color: var(--success);
}

.footer-section {
  display: flex;
}

.second-box-footer {
  margin-left: 120px;
}

/* portfolio */

.portfolio {
  padding-top: 96px;
  padding-bottom: 120px;
}

/* button */

.portfolio-ul {
  display: flex;
  justify-content: center;
  margin-bottom: 72px;
}

.portfolio-ul .portfolio-li + .portfolio-li {
  margin-left: 24px;
}

.portfolio-ul .button-secondary {
  color: var(--primary-brand);
  background-color: var(--light);
  cursor: pointer;
  font-weight: 600;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.04em;
  border-radius: 4px;
  padding: 12px 24px;
  border: 1px solid var(--accent);
}

.button-secondary:hover,
.button-secondary:focus {
  color: var(--primary-white-color);
  background-color: #404bbf;
  border-color: transparent;
  box-shadow: 0px 3px 1px rgba(0, 0, 0, 0.1), 0px 2px 1px rgba(0, 0, 0, 0.08),
    0px 2px 2px rgba(0, 0, 0, 0.12);
}

/* examples */

.examples {
  color: var(--text);
  display: flex;
  flex-wrap: wrap;
  column-gap: 24px;
  row-gap: 48px;
}

.examples-li {
  flex-basis: calc((100% - 48px) / 3);
  box-shadow: 0px 1px 6px rgba(46, 47, 66, 0.08);
}

.examples .examples-title {
  display: block;
  color: var(--dark);
  box-shadow: 0px 1px 6px rgba(46, 47, 66, 0.08);
}

.examples-title:hover,
.examples-title:focus {
  box-shadow: 0px 1px 6px rgba(46, 47, 66, 0.08),
    0px 1px 1px rgba(46, 47, 66, 0.16), 0px 2px 1px rgba(46, 47, 66, 0.08);
}

.examples-text {
  padding-top: 32px;
  padding-bottom: 32px;
  padding-left: 16px;
}

.examples-text > .card-title {
  color: var(--dark);
  font-weight: 500;
  font-size: 20px;
  line-height: 1.2;
  margin-bottom: 8px;
}

.examples-text {
  border-bottom: 1px solid var(--accent);
  border-left: 1px solid var(--accent);
  border-right: 1px solid var(--accent);
}
