:root {
  --font-family-primary: "Roboto", sans-serif;
  --font-family-secondary: "Raleway", sans-serif;

  --text-h1-size: 56px;
  --text-h1-line-height: 60px;
  --text-h1-letter-spacing: 0.02em;
  --text-h1-weight: 700;

  --text-h2-size: 36px;
  --text-h2-line-height: 40px;
  --text-h2-letter-spacing: 0.02em;
  --text-h2-weight: 700;

  --text-h3-size: 20px;
  --text-h3-line-height: 24px;
  --text-h3-letter-spacing: 0.02em;
  --text-h3-weight: 500;

  --text-body-size: 16px;
  --text-body-line-height: 24px;
  --text-body-letter-spacing: 0.02em;
  --text-body-weight: 400;

  --text-small-size: 12px;
  --text-small-line-height: 14px;
  --text-small-letter-spacing: 0.04em;
  --text-small-weight: 400;

  --text-medium-size: 16px;
  --text-medium-line-height: 24px;
  --text-medium-letter-spacing: 0.02em;
  --text-medium-weight: 500;

  --text-button-size: 16px;
  --text-button-line-height: 24px;
  --text-button-letter-spacing: 0.04em;
  --text-button-weight: 500;

  --text-link-size: 12px;
  --text-link-line-height: 16px;
  --text-link-letter-spacing: 0.04em;
  --text-link-weight: 400;

  --text-logo-size: 18px;
  --text-logo-line-height: 21px;
  --text-logo-letter-spacing: 0.03em;
  --text-logo-weight: 700;

  --color-brand-primary: #4d5ae5;
  --color-brand-pressed: #404bbf;
  --color-dark: #2e2f42;
  --color-success: #31d0aa;
  --color-text: #434455;
  --color-text-subtle: #8e8f99;
  --color-accent: #e7e9fc;
  --color-light: #f4f4fd;
  --color-overlay: #2e2f42;
  --color-hero-background: #2e2f42;
  --color-white: #ffffff;
  --color-modal-background: #fcfcfc;
}

body {
  font-family: var(--font-family-primary);
  line-height: 1.5;
  letter-spacing: var(--text-body-letter-spacing);
  color: var(--color-text);
  background-color: var(--color-white);
}

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

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

a {
  text-decoration: none;
  color: var(--color-text);
}

img {
  display: block;
}

a:hover,
a:focus,
a:active {
  color: var(--color-brand-pressed);
}

address {
  font-style: normal;
}

button {
  cursor: pointer;
}

h1 {
  font-size: var(--text-h1-size);
  line-height: 1.07;
  letter-spacing: var(--text-h1-letter-spacing);
  font-weight: var(--text-h1-weight);
}

h2 {
  font-size: var(--text-h2-size);
  line-height: 1.11;
  letter-spacing: var(--text-h2-letter-spacing);
  font-weight: var(--text-h2-weight);
}

h3 {
  font-size: var(--text-h3-size);
  line-height: 1.2;
  letter-spacing: var(--text-h3-letter-spacing);
  font-weight: var(--text-h3-weight);
}

p {
  font-size: var(--text-body-size);
  line-height: 1.5;
  letter-spacing: var(--text-body-letter-spacing);
  font-weight: var(--text-body-weight);
}

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

.section {
  padding-top: 120px;
  padding-bottom: 120px;
}

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

.page-header {
  background-color: var(--color-white);
  border-bottom: 1px solid var(--color-accent);
}

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

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

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

.nav-list,
.contact-items {
  display: flex;
  align-items: center;
  gap: 40px;
}

.logo-link {
  font-family: var(--font-family-secondary);
  color: var(--color-brand-primary);
  font-size: var(--text-logo-size);
  font-weight: var(--text-logo-weight);
  line-height: 1.17;
  letter-spacing: var(--text-logo-letter-spacing);
  text-transform: uppercase;
  margin-right: 76px;
}

.logo-accent {
  color: var(--color-dark);
}

.nav-link {
  font-size: var(--text-medium-size);
  line-height: 1.5;
  letter-spacing: var(--text-medium-letter-spacing);
  font-weight: var(--text-medium-weight);
  color: var(--color-dark);
}

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

.contact-link {
  line-height: 1.5;
  letter-spacing: var(--text-medium-letter-spacing);
}

.hero-section,
.page-footer {
  background-color: var(--color-hero-background);
}

.hero-section {
  padding: 188px 0 188px;
}

.hero-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 48px;
}

.hero-title {
  color: var(--color-white);
  text-align: center;
  max-width: 496px;
}

.hero-button {
  background-color: var(--color-brand-primary);
  color: var(--color-white);
  line-height: 1.5;
  letter-spacing: var(--text-button-letter-spacing);
  font-weight: var(--text-button-weight);
  padding: 16px 32px;
  min-width: 169px;
  border-radius: 4px;
  box-shadow: 0 4px 4px 0 rgba(0, 0, 0, 0.15);
  border: transparent;
}

.hero-button:hover,
.hero-button:active,
.hero-button:focus {
  background-color: var(--color-brand-pressed);
}

.features-subtitle {
  margin-bottom: 8px;
}

.features-text {
  color: var(--color-text);
}

.features-list {
  display: flex;
  align-items: center;
  gap: 24px;
}

.features-item {
  display: flex;
  flex-direction: column;
  width: calc((100% - 72px) / 4);
}

.portfolio-category {
  color: var(--color-text-subtle);
}

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

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

.team-title {
  text-align: center;
  text-transform: capitalize;
  color: var(--color-dark);
  margin-bottom: 72px;
}

.team-name {
  color: var(--color-dark);
  margin-bottom: 8px;
  text-align: center;
}

.team-role {
  text-align: center;
}

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

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

.portfolio-title {
  text-align: center;
  text-transform: capitalize;
  margin-bottom: 72px;
}

.portfolio-list {
  display: flex;
  align-items: center;
  gap: 48px 24px;
  flex-wrap: wrap;
}

.portfolio-item {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  width: calc((100% - 48px) / 3);
}

.portfolio-app-info-container {
  display: flex;
  padding: 32px 16px;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  width: 100%;
  border-right: 1px solid var(--color-accent);
  border-bottom: 1px solid var(--color-accent);
  border-left: 1px solid var(--color-accent);
}

.portfolio-category {
  color: var(--color-text);
}

.portfolio-title,
.portfolio-name,
.features-subtitle {
  color: var(--color-dark);
}

.portfolio-name {
  margin-bottom: 8px;
}

.page-footer {
  padding-top: 100px;
  padding-bottom: 100px;
}

.page-footer .logo-link .logo-accent {
  color: var(--color-light);
}

.footer-text {
  color: var(--color-light);
}

.logo-footer {
  display: inline-block;
  margin-bottom: 16px;
}
