/* О компании — новая вёрстка (o-kompanii.html), палитра страницы:
   тёплый жёлтый #FFC839 / #F5A800, чернильный #232323 */

.ab-hero {
  position: relative;
  display: flex;
  align-items: center;
  height: 300px;
  overflow: hidden;
  background:
    linear-gradient(100deg, rgba(20, 20, 20, 0.86) 0%, rgba(20, 20, 20, 0.55) 45%, rgba(20, 20, 20, 0.15) 100%),
    repeating-linear-gradient(115deg, #2b2b2b 0 42px, #333333 42px 84px);
}

/* Фото из админки: лежит под градиентом — текст слева остаётся читаемым */
.ab-hero--img {
  background:
    linear-gradient(100deg, rgba(20, 20, 20, 0.86) 0%, rgba(20, 20, 20, 0.55) 45%, rgba(20, 20, 20, 0.15) 100%),
    var(--ab-hero-img) center / cover no-repeat;
}

.ab-hero::after {
  content: '';
  position: absolute;
  right: -60px;
  top: -60px;
  width: 420px;
  height: 420px;
  background: radial-gradient(circle at center, rgba(255, 200, 57, 0.18), transparent 70%);
  animation: ab-drift 9s ease-in-out infinite;
}

@keyframes ab-drift {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(-18px, 14px); }
}

.ab-hero .container {
  position: relative;
  z-index: 2;
}

.ab-hero__eyebrow {
  margin-bottom: 10px;
  font-weight: var(--fw-bold);
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #ffc839;
  opacity: 0;
  animation: ab-rise 0.6s ease forwards;
  animation-delay: 0.05s;
}

.ab-hero__title {
  margin-bottom: 14px;
  font-weight: var(--fw-bold);
  font-size: 42px;
  color: #ffffff;
  opacity: 0;
  animation: ab-rise 0.6s ease forwards;
  animation-delay: 0.15s;
}

.ab-hero__desc {
  max-width: 520px;
  font-size: 15px;
  line-height: 1.7;
  color: #d8d8d6;
  opacity: 0;
  animation: ab-rise 0.6s ease forwards;
  animation-delay: 0.28s;
}

@keyframes ab-rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

/* --- Секции и заголовки --- */
.ab-section {
  padding: 56px 0;
}

.ab-head {
  margin-bottom: 32px;
}

.ab-head__title {
  font-weight: var(--fw-bold);
  font-size: 28px;
  color: #232323;
}

.ab-head__rule {
  width: 0;
  height: 4px;
  margin-top: 14px;
  border-radius: 2px;
  background: #ffc839;
  transition: width 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.js-ab-reveal.in-view .ab-head__rule,
.ab-head.in-view .ab-head__rule {
  width: 56px;
}

.ab-eyebrow {
  margin-bottom: 8px;
  font-size: 12px;
  font-weight: var(--fw-bold);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #f5a800;
}

.ab-text {
  margin: 0 0 16px;
  font-size: 15px;
  line-height: 1.7;
  color: #4a4a4a;
}

/* --- Появление при скролле --- */
.js-ab-reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.js-ab-reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

.js-ab-stagger > * {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.5s ease, transform 0.5s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.js-ab-stagger.in-view > * {
  opacity: 1;
  transform: translateY(0);
}

.js-ab-stagger.in-view > *:nth-child(1) { transition-delay: 0.05s; }
.js-ab-stagger.in-view > *:nth-child(2) { transition-delay: 0.13s; }
.js-ab-stagger.in-view > *:nth-child(3) { transition-delay: 0.21s; }
.js-ab-stagger.in-view > *:nth-child(4) { transition-delay: 0.29s; }
.js-ab-stagger.in-view > *:nth-child(5) { transition-delay: 0.37s; }
.js-ab-stagger.in-view > *:nth-child(6) { transition-delay: 0.45s; }
.js-ab-stagger.in-view > *:nth-child(7) { transition-delay: 0.53s; }
.js-ab-stagger.in-view > *:nth-child(8) { transition-delay: 0.61s; }

/* --- О компании: текст + фото --- */
.ab-about {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 56px;
  align-items: center;
}

.ab-photo {
  position: relative;
  height: 360px;
  border-radius: 14px;
  overflow: hidden;
  background: repeating-linear-gradient(100deg, #dadad6 0 28px, #e9e9e6 28px 56px);
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.ab-photo:hover {
  transform: scale(1.015);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.12);
}

.ab-photo--img img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ab-photo__label {
  position: absolute;
  bottom: 16px;
  left: 16px;
  padding: 6px 12px;
  border-radius: 20px;
  background: rgba(35, 35, 35, 0.72);
  font-size: 12px;
  letter-spacing: 0.03em;
  color: #ffffff;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.ab-photo:hover .ab-photo__label {
  background: rgba(245, 168, 0, 0.9);
  color: #232323;
}

/* --- Бейджи-иконки --- */
.ab-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), background-color 0.25s ease, color 0.25s ease;
}

.ab-badge svg {
  width: 22px;
  height: 22px;
}

.ab-badge--dark { background: #232323; color: #ffc839; }
.ab-badge--yellow { background: #ffc839; color: #232323; }
.ab-badge--cream { background: #fff3d6; color: #f5a800; }

/* --- История / география --- */
.ab-strip {
  background: #f7f7f5;
  border-top: 1px solid #ebebe8;
  border-bottom: 1px solid #ebebe8;
}

.ab-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}

.ab-card {
  padding: 32px;
  border: 1px solid #ebebe8;
  border-radius: 14px;
  background: #ffffff;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.ab-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.06);
  border-color: #dcdcd8;
}

.ab-card:hover .ab-badge {
  transform: rotate(-8deg) scale(1.08);
}

.ab-card__num {
  margin: 18px 0 14px;
  font-size: 12px;
  font-weight: var(--fw-bold);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #f5a800;
}

.ab-card__title {
  margin-bottom: 14px;
  font-weight: var(--fw-bold);
  font-size: 20px;
  color: #232323;
}

.ab-card__text {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.7;
  color: #4a4a4a;
}

/* --- Принципы --- */
.ab-principles {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}

.ab-principle {
  position: relative;
  padding: 30px;
  border: 1px solid #ebebe8;
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff, #fefcf6);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.ab-principle:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.06);
  border-color: #dcdcd8;
}

.ab-principle:hover .ab-badge {
  transform: rotate(-8deg) scale(1.08);
}

.ab-principle .ab-badge {
  margin-bottom: 16px;
}

.ab-principle__title {
  margin-bottom: 12px;
  font-weight: var(--fw-bold);
  font-size: 18px;
  color: #232323;
}

.ab-principle__text {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.7;
  color: #4a4a4a;
}

.ab-principle__stat {
  display: inline-block;
  margin-top: 10px;
  padding: 6px 12px;
  border-radius: 20px;
  background: #fff6e0;
  font-size: 13px;
  font-weight: var(--fw-bold);
  color: #f5a800;
  transition: transform 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}

.ab-principle:hover .ab-principle__stat {
  background: #ffc839;
  color: #232323;
  transform: translateY(-1px);
}

/* --- Почему мы? --- */
.ab-why {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.ab-why__card {
  padding: 30px 18px;
  border: 1px solid #ebebe8;
  border-radius: 14px;
  text-align: center;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.ab-why__card:hover {
  transform: translateY(-5px);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.08);
  border-color: #dcdcd8;
}

.ab-why__card:hover .ab-badge {
  background: #ffc839;
  color: #232323;
  transform: rotate(6deg) scale(1.1);
}

.ab-why__card .ab-badge {
  margin: 0 auto 16px;
}

.ab-why__card strong {
  display: block;
  font-size: 14.5px;
  font-weight: var(--fw-bold);
  line-height: 1.4;
  color: #232323;
}

/* --- Миссия --- */
.ab-mission {
  position: relative;
  padding: 52px 48px;
  border-radius: 20px;
  overflow: hidden;
  background: linear-gradient(120deg, #ffc839 0%, #ffdd7a 100%);
}

.ab-mission::before {
  content: '';
  position: absolute;
  right: -80px;
  top: -100px;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.25);
  animation: ab-float 7s ease-in-out infinite;
}

@keyframes ab-float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-14px, 16px) scale(1.05); }
}

.ab-mission__eyebrow {
  position: relative;
  color: #232323;
}

.ab-mission__title {
  position: relative;
  max-width: 760px;
  margin-bottom: 16px;
  font-weight: var(--fw-bold);
  font-size: 26px;
  line-height: 1.4;
  color: #232323;
}

.ab-mission__text {
  position: relative;
  max-width: 720px;
  margin: 0;
  font-size: 15.5px;
  line-height: 1.7;
  font-weight: var(--fw-bold);
  color: #3a3320;
  transition: letter-spacing 0.3s ease;
}

.ab-mission:hover .ab-mission__text {
  letter-spacing: 0.02em;
}

/* --- Адаптив --- */
@media (max-width: 860px) {
  .ab-about,
  .ab-split,
  .ab-principles {
    grid-template-columns: 1fr;
  }

  .ab-about {
    gap: 32px;
  }

  .ab-why {
    grid-template-columns: repeat(2, 1fr);
  }

  .ab-hero__title {
    font-size: 30px;
  }

  .ab-mission {
    padding: 36px 24px;
  }

  .ab-section {
    padding: 40px 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ab-hero::after,
  .ab-mission::before {
    animation: none;
  }

  .ab-hero__eyebrow,
  .ab-hero__title,
  .ab-hero__desc {
    animation: none;
    opacity: 1;
  }

  .js-ab-reveal,
  .js-ab-stagger > * {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
