/* =========================================
   О НАС — INTRO SECTION
   ========================================= */
.about-intro {
  background: #434345;
}

.about-intro__title-wrap {
  background: #fff;
  padding-top: 60px;
  padding-bottom: 60px;
  margin-top: var(--header-h);
}

.about-intro__title {
  font-size: 65px;
  font-weight: 700;
  letter-spacing: -1.3px;
  line-height: 1.044;
  text-transform: uppercase;
  color: #181818;
  margin: 0;
}

/* Figma: text 578 + photo 621 (of 1230) — keeps the proportion on wide screens */
.about-intro__inner {
  display: flex;
  gap: 31px;
  align-items: flex-start;
  min-height: 440px;
}

.about-intro__text {
  flex: 578 1 0;
  min-width: 0;
  padding: 40px 0 40px;
  color: #fff;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 22px;
  line-height: 25px;
}

.about-intro__text p {
  margin: 0 0 25px;
}

.about-intro__text p:last-child {
  margin-bottom: 0;
}

.about-intro__photo {
  flex: 621 1 0;
  min-width: 0;
  aspect-ratio: 621 / 440;
  max-height: 600px;
  overflow: hidden;
  position: relative;
}

/* original photo, no darkening overlay */
.about-intro__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

/* =========================================
   КОМАНДА
   ========================================= */
.about-team {
  background: #fff;
  padding-top: 70px;
  padding-bottom: 30px;
}

.about-team .section-title {
  margin-bottom: 70px;
}

.about-team__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 30px 23px;
  padding: 0 100px;
  box-sizing: border-box;
}

.about-team__card {
  display: flex;
  flex-direction: column;
}

.about-team__photo {
  width: 100%;
  aspect-ratio: 290 / 434;
  overflow: hidden;
  margin-bottom: 20px;
  flex-shrink: 0;
}

.about-team__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.about-team__name {
  display: block;
  font-family: Arial, Helvetica, sans-serif;
  font-weight: 700;
  font-size: 20px;
  color: #181818;
  text-transform: uppercase;
  line-height: 1.0435;
  margin-bottom: 4px;
}

.about-team__role {
  display: block;
  font-family: Arial, Helvetica, sans-serif;
  font-weight: 400;
  font-size: 18px;
  color: #181818;
  line-height: 1.2;
}

/* =========================================
   УСЛУГИ (about page — text list)
   ========================================= */
.about-services {
  background: #434345;
  padding-top: 70px;
  padding-bottom: 60px;
}

.about-services .section-title {
  margin-bottom: 70px;
}

.about-services__list {
  color: #fff;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 22px;
  line-height: 25px;
}

.about-services__list p {
  margin: 0;
}

.about-services__spacer {
  display: block;
  height: 25px;
}

/* =========================================
   ОТЗЫВЫ + ЛИЦЕНЗИЯ
   ========================================= */
.about-docs {
  background: #fff;
  padding-bottom: 70px;
}

.about-reviews,
.about-license {
  padding-top: 70px;
}

.about-reviews .section-title,
.about-license .section-title {
  margin-bottom: 70px;
}

/* Reviews / licenses: 5 documents across the full content width;
   click opens full screen with arrows (see lightbox in footer.php) */
.about-docs__grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 20px;
  padding: 0 100px;
  box-sizing: border-box;
}

.about-docs__grid img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1.414; /* A4 sheet — the whole document is visible */
  object-fit: contain;
  background: #fff;
  border: 1px solid rgba(24, 24, 24, 0.2);
  display: block;
  transition: box-shadow 0.2s, transform 0.2s;
}

.about-docs__grid img:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  transform: translateY(-2px);
}

/* wide screens: the text stays a narrow column (Figma 578px) instead of a wide strip */
@media (min-width: 1431px) {
  .about-intro__text p {
    max-width: 578px;
  }
}

@media (max-width: 1430px) {
  .about-intro__text {
    flex: 0 1 578px;
    min-width: 0;
  }

  .about-intro__photo {
    flex: 0 1 621px;
    min-width: 0;
  }
}

@media (max-width: 1100px) {
  .about-intro__text {
    flex: 1 1 0;
  }

  .about-intro__photo {
    flex: 0 1 50%;
  }

  .about-team__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding: 0 60px;
  }

  .about-docs__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    row-gap: 14px;
    padding: 0 60px;
  }
}

/* =========================================
   MOBILE — about.html specific overrides
   ========================================= */
@media (max-width: 768px) {

  /* О НАС intro */
  .about-intro__title-wrap {
    padding-top: 30px;
    padding-bottom: 30px;
  }

  .about-intro__title {
    font-size: 40px;
  }

  .about-intro__inner {
    flex-direction: column;
    min-height: auto;
    gap: 0;
  }

  .about-intro__text {
    flex: none;
    width: 100%;
    font-size: 18px;
    padding: 30px 0;
  }

  .about-intro__photo {
    flex: none;
    width: 100%;
    height: 260px;
  }

  /* Team */
  .about-team {
    padding-top: 50px;
    padding-bottom: 50px;
  }

  .about-team .section-title {
    margin-bottom: 40px;
  }

  .about-team__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px 16px;
    padding: 0 20px;
  }

  /* whole photo visible (keeps the 290×434 proportion, no crop) */
  .about-team__photo {
    height: auto;
  }

  .about-team__name {
    font-size: 15px;
  }

  .about-team__role {
    font-size: 14px;
  }

  /* Services */
  .about-services {
    padding-top: 50px;
    padding-bottom: 60px;
  }

  .about-services__list {
    font-size: 16px;
    line-height: 20px;
  }

  .about-reviews .section-title,
  .about-license .section-title {
    margin-bottom: 28px;
  }

  .about-services__spacer {
    height: 16px;
  }

  /* Reviews & License */
  .about-reviews,
  .about-license {
    padding-top: 50px;
  }

  .about-docs__grid {
    grid-template-columns: repeat(2, 1fr);
    column-gap: 10px;
    row-gap: 10px;
    padding: 0 20px;
  }

  .about-docs__grid img {
    height: 220px;
  }

  .about-docs__grid--license img {
    height: 240px;
  }
}

@media (max-width: 480px) {
  .about-intro__title {
    font-size: 32px;
  }

  .about-team__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px 12px;
    padding: 0 16px;
  }

  .about-team__photo {
    height: auto;
  }

  .about-team__name {
    font-size: 13px;
  }

  .about-team__role {
    font-size: 13px;
  }

  .about-docs__grid {
    grid-template-columns: 1fr 1fr;
    padding: 0 16px;
  }
}
