/* =====================================================================
   Чепик и партнеры — Главная («Технологичный Bento»)
   Homepage-only rules. Requires ./assets/site.css loaded BEFORE this file
   (tokens, base, tiles, buttons, header, CTA, footer, widgets, reveal).
   Sections: 1 Hero · 2 Services bento · 3 Advantages · 4 About ·
   5 Testimonials · 6 Process · 7 Fine-tuning · 8 Hero reveal · 9 Reduced motion
   ===================================================================== */

/* Decorative dot grid on homepage tiles (same recipe as .dotgrid in site.css) */
.hero__content::before,
.adv-quote::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  pointer-events: none;
  background-image: radial-gradient(var(--dot) 1px, transparent 1.4px);
  background-size: 20px 20px;
}

/* ---------------------------------------------------------------------
   1. Hero bento
   --------------------------------------------------------------------- */
.hero { padding-block: 16px 28px; }

.hero__bento {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--gap);
}

.hero__content {
  isolation: isolate;
  overflow: hidden;
  padding: 28px 20px;
}
.hero__content::before {
  -webkit-mask-image: radial-gradient(90% 80% at 100% 0%, #000 0%, transparent 70%);
  mask-image: radial-gradient(90% 80% at 100% 0%, #000 0%, transparent 70%);
}

.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 34px;
  margin-bottom: 24px;
  padding: 0 14px 0 12px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--on-accent-soft);
  font-family: var(--font-head);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  font-variant-numeric: tabular-nums;
}
.hero__eyebrow-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft), 0 0 0 4px rgba(180, 83, 9, 0.25);
}

.hero__title {
  margin-bottom: 20px;
  font-family: var(--font-head);
  font-size: clamp(1.875rem, 0.25rem + 8vw, 3.75rem);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.03em;
  color: var(--ink);
}
.hero__title em {
  position: relative;
  font-style: normal;
  color: var(--primary);
  white-space: nowrap;
}
.hero__title em::after {
  content: "";
  position: absolute;
  left: 0.02em;
  right: 0.02em;
  bottom: -0.02em;
  height: 0.08em;
  border-radius: 0.08em;
  background: var(--accent);
  opacity: 0.9;
}

.hero__subtitle {
  max-width: 56ch;
  margin-bottom: 28px;
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink-2);
}

.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; }

@media (max-width: 479px) {
  .hero__cta .btn { width: 100%; }
}

/* Stat tiles */
.hero__stats-bar {
  order: 2;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--gap);
}

.hero__stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-height: 136px;
  padding: 16px;
}
.hero__stat-icon {
  width: 36px;
  height: 36px;
  margin-bottom: auto;
  padding: 7px;
  border-radius: var(--r-sm);
  background: var(--primary-soft);
  color: var(--primary);
}
.hero__stat-number {
  margin-top: 14px;
  font-family: var(--font-head);
  font-size: clamp(1.875rem, 1.4rem + 1.4vw, 2.5rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
}
.hero__stat-label {
  font-size: 0.9375rem;
  font-weight: 500;
  line-height: 1.35;
  color: var(--ink-2);
}

/* The one tinted hero tile */
.hero__stat--ai {
  background: linear-gradient(135deg, var(--tile-ink) 0%, var(--tile-ink) 45%, var(--tile-ink-2) 100%);
}
.hero__stat--ai .hero__stat-icon { background: rgba(255, 255, 255, 0.1); color: var(--accent-on-ink); }
.hero__stat--ai .hero__stat-number { color: var(--accent-on-ink); }
.hero__stat--ai .hero__stat-label { color: var(--on-ink-2); }

@media (min-width: 768px) {
  .hero { padding-block: 20px 36px; }
  .hero__bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero__content { grid-column: 1 / -1; padding: 56px 40px 44px; min-height: 440px; }
  .hero__subtitle { font-size: 1.1875rem; }
  .hero__stats-bar { order: 0; grid-column: 1 / -1; grid-row: 2; grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .hero__stat { padding: 20px; }
}

@media (min-width: 1024px) {
  .hero { padding-block: 24px 44px; }
  .hero__bento { grid-template-columns: repeat(12, minmax(0, 1fr)); }
  .hero__content { grid-column: 1 / -1; grid-row: 1; padding: 64px 56px 56px; min-height: 500px; }
  .hero__stats-bar { grid-column: 1 / -1; grid-row: 2; grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .hero__stat { min-height: 156px; }
}

/* Headline tile at every width: dark, with the scales artwork as background
   (the overlay keeps text ≥4.5:1). */
.hero__content {
  color: var(--on-ink);
  border-color: var(--on-ink-border);
  background-color: var(--tile-ink);
  /* size both layers to the border box: otherwise the artwork shows unshaded
     through the semi-transparent 1px border (gold lines along the bottom edge) */
  background-origin: border-box;
  background-image:
    linear-gradient(180deg, rgba(11, 18, 32, 0.50) 0%, rgba(11, 18, 32, 0.78) 34%, rgba(11, 18, 32, 0.93) 62%, rgba(11, 18, 32, 0.97) 100%),
    url("hero-main.png");
  background-image:
    linear-gradient(180deg, rgba(11, 18, 32, 0.50) 0%, rgba(11, 18, 32, 0.78) 34%, rgba(11, 18, 32, 0.93) 62%, rgba(11, 18, 32, 0.97) 100%),
    image-set(url("hero-main.webp") type("image/webp"), url("hero-main.png") type("image/png"));
  background-size: cover, cover;
  background-position: center, 50% 18%;
  background-repeat: no-repeat;
}
.hero__content::before { display: none; }
.hero__content :focus-visible { outline-color: var(--ring-on-ink); }

.hero__content .hero__eyebrow {
  background: rgba(242, 184, 75, 0.14);
  color: var(--accent-on-ink);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}
.hero__content .hero__eyebrow-dot {
  background: var(--accent-on-ink);
  box-shadow: 0 0 0 3px rgba(242, 184, 75, 0.18), 0 0 0 4px rgba(242, 184, 75, 0.35);
}
.hero__content .hero__title { color: var(--on-ink); text-shadow: 0 2px 18px rgba(11, 18, 32, 0.55); }
.hero__content .hero__title em { color: #93C5FD; }
.hero__content .hero__title em::after { background: var(--accent-on-ink); }
.hero__content .hero__subtitle { color: var(--on-ink-2); }

.hero__content .btn--primary { background: #2563EB; color: #FFFFFF; }
.hero__content .btn--primary:hover { background: #1D4ED8; }
.hero__content .btn--ghost {
  background: rgba(255, 255, 255, 0.06);
  color: var(--on-ink);
  border-color: rgba(255, 255, 255, 0.28);
}
.hero__content .btn--ghost:hover { background: rgba(255, 255, 255, 0.12); border-color: rgba(255, 255, 255, 0.45); }

/* ---------------------------------------------------------------------
   2. Services bento
   --------------------------------------------------------------------- */
.svc-bento {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--gap);
  margin: 0;
  padding: 0;
  list-style: none;
}
.svc-bento__item { display: flex; min-width: 0; }

.svc-card {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s var(--ease);
}
.svc-card::after {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  box-shadow: var(--shadow-md);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s var(--ease);
}

.svc-card__image {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border-radius: calc(var(--r-lg) - 1px) calc(var(--r-lg) - 1px) 0 0;
  background: var(--surface-3);
}
.svc-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s var(--ease);
}

.svc-card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  padding: 18px 20px 20px;
}

.svc-card__num {
  display: inline-block;
  padding: 5px 8px;
  border-radius: 7px;
  background: var(--primary-soft);
  color: var(--on-primary-soft);
  font-family: var(--font-head);
  font-size: 0.75rem;
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0.06em;
  font-variant-numeric: tabular-nums;
}

.svc-card__title {
  font-family: var(--font-head);
  font-size: 1.1875rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-wrap: balance;
}

.svc-card__desc { font-size: 1rem; line-height: 1.55; color: var(--ink-2); }

.svc-card__arrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: auto;
  padding-top: 6px;
  font-family: var(--font-head);
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--link);
}
.svc-card__arrow svg { transition: transform 0.2s var(--ease); }

.svc-card__link {
  position: absolute;
  inset: 0;
  z-index: 2;
  border-radius: inherit;
}
.svc-card__link:focus-visible { outline: 3px solid var(--ring); outline-offset: 3px; }

@media (hover: hover) {
  .svc-card:hover { transform: translateY(-3px); }
  .svc-card:hover::after { opacity: 1; }
  .svc-card:hover .svc-card__image img { transform: scale(1.04); }
  .svc-card:hover .svc-card__arrow svg { transform: translateX(3px); }
}
.svc-card:active { transform: translateY(-1px) scale(0.995); }

/* Featured tile — Абонентское обслуживание */
.svc-card--featured {
  min-height: 460px;
  background: var(--tile-ink);
  border-color: var(--on-ink-border);
  color: var(--on-ink);
}
.svc-card--featured .svc-card__image {
  position: absolute;
  inset: 0;
  aspect-ratio: auto;
  border-radius: calc(var(--r-lg) - 1px);
  background: var(--tile-ink);
}
.svc-card--featured .svc-card__image img { position: absolute; inset: 0; }
.svc-card--featured .svc-card__image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(var(--overlay-rgb), 0.30) 0%,
    rgba(var(--overlay-rgb), 0.62) 30%,
    rgba(var(--overlay-rgb), 0.90) 55%,
    rgba(var(--overlay-rgb), 0.96) 100%
  );
}
.svc-card--featured .svc-card__body {
  position: relative;
  z-index: 1;
  gap: 12px;
  padding: 22px 22px 24px;
}
.svc-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  margin-bottom: auto;
  padding-bottom: 32px;
}
.svc-card--featured .svc-card__num {
  padding: 7px 10px;
  border: 1px solid rgba(242, 184, 75, 0.45);
  background: rgba(var(--overlay-rgb), 0.82);
  color: #F6C76E;
  font-size: 0.8125rem;
}
.svc-card__icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--r-md);
  background: rgba(var(--overlay-rgb), 0.7);
  color: #F6C76E;
}
.svc-card--featured .svc-card__title {
  font-size: clamp(1.625rem, 1.2rem + 1.6vw, 2.375rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.02em;
  color: #FFFFFF;
}
.svc-card--featured .svc-card__desc {
  max-width: 44ch;
  font-size: 1.0625rem;
  line-height: 1.6;
  color: #D5DCE8;
}
.svc-card__price {
  display: inline-block;
  margin-top: 2px;
  padding: 1px 10px;
  border: 1px solid rgba(242, 184, 75, 0.4);
  border-radius: 8px;
  background: rgba(242, 184, 75, 0.14);
  color: #F6C76E;
  font-family: var(--font-head);
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.svc-card--featured .svc-card__arrow {
  margin-top: 8px;
  min-height: 48px;
  padding: 0 20px;
  border-radius: 12px;
  background: #FFFFFF;
  color: #0F1B33;
}

/* Wide tiles — image left, text right (from 640px) */
@media (min-width: 640px) {
  .svc-bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .svc-bento__item--featured,
  .svc-bento__item--wide { grid-column: span 2; }

  .svc-card--featured { min-height: 440px; }
  .svc-card--featured .svc-card__body { padding: 32px; }

  .svc-card--wide { flex-direction: row; }
  .svc-card--wide .svc-card__image {
    width: 44%;
    min-height: 220px;
    flex-shrink: 0;
    aspect-ratio: auto;
    border-radius: calc(var(--r-lg) - 1px) 0 0 calc(var(--r-lg) - 1px);
  }
  .svc-card--wide .svc-card__image img { position: absolute; inset: 0; }
  .svc-card--wide .svc-card__body { justify-content: center; padding: 24px 26px; }
  .svc-card--wide .svc-card__arrow { margin-top: 4px; }
}

@media (min-width: 1024px) {
  .svc-bento { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .svc-bento__item--featured { grid-column: span 2; grid-row: span 2; }
  /* двенадцатая карточка широкая и на десктопе: с ней 16 ячеек — четыре полных ряда без пустот */
  .svc-bento__item--wide-lg { grid-column: span 2; }
  .svc-card--featured .svc-card__body { padding: 40px; }
  .svc-card--wide .svc-card__image { width: 46%; }
}

/* ---------------------------------------------------------------------
   3. Advantages
   --------------------------------------------------------------------- */
.adv-quote {
  isolation: isolate;
  overflow: hidden;
  display: grid;
  gap: 16px;
  margin-bottom: var(--gap);
  padding: 28px 22px;
}
.adv-quote::before {
  background-image: radial-gradient(var(--dot-on-ink) 1px, transparent 1.4px);
  -webkit-mask-image: linear-gradient(90deg, transparent 30%, #000 100%);
  mask-image: linear-gradient(90deg, transparent 30%, #000 100%);
}
.adv-quote__mark { width: 40px; height: 40px; color: var(--accent-on-ink); }
.adv-quote__text {
  font-family: var(--font-head);
  font-size: clamp(1.625rem, 1.1rem + 2.2vw, 2.75rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--on-ink);
  text-wrap: balance;
}
.adv-quote__desc {
  max-width: 52ch;
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--on-ink-2);
}

.adv-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--gap);
}

.adv-item {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 24px;
}
.adv-item__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.adv-item__num {
  font-family: var(--font-head);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  font-variant-numeric: tabular-nums;
  color: var(--ink-3);
}
.adv-item__title {
  font-family: var(--font-head);
  font-size: 1.3125rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.adv-item__desc { color: var(--ink-2); line-height: 1.65; }

@media (min-width: 640px) {
  .adv-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .adv-grid > :last-child { grid-column: span 2; }
}
@media (min-width: 768px) {
  .adv-quote { padding: 40px; }
  .adv-item { padding: 28px; }
}
@media (min-width: 1024px) {
  .adv-quote {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
    align-items: end;
    column-gap: 56px;
    padding: 48px 56px;
  }
  .adv-quote__mark { grid-column: 1 / -1; }
  .adv-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .adv-grid > :last-child { grid-column: auto; }
  .adv-item { padding: 32px; }
}

/* ---------------------------------------------------------------------
   4. About
   --------------------------------------------------------------------- */
.about-bento {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--gap);
}

.about-photo {
  overflow: hidden;
  aspect-ratio: 4 / 4.6;
  background: var(--surface-3);
}
.about-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 28%;
}
.about-photo__stat {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--surface);
  box-shadow: var(--shadow-md);
}
.about-photo__stat-num {
  flex-shrink: 0;
  font-family: var(--font-head);
  font-size: 2.25rem;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--accent);
}
.about-photo__stat-label {
  font-size: 0.9375rem;
  font-weight: 500;
  line-height: 1.35;
  color: var(--ink-2);
}

.about-text { padding: 28px 22px; }
.about-text__body {
  margin: 16px 0 24px;
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--ink-2);
}
.about-text__features {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
  margin: 0 0 32px;
  padding: 0;
  list-style: none;
}
.about-text__features li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface-2);
  font-weight: 500;
  line-height: 1.45;
  color: var(--ink);
}

@media (min-width: 768px) {
  .about-bento { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
  .about-photo { aspect-ratio: auto; min-height: 460px; }
  .about-photo__stat { left: 16px; right: 16px; bottom: 16px; }
  .about-text { padding: 40px; }
}
@media (min-width: 1024px) {
  .about-text { padding: 56px; }
  .about-text__features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------------------------------------------------------------------
   5. Testimonials
   --------------------------------------------------------------------- */
/* Лента отзывов едет вбок. Прокрутка нативная: свайп на телефоне, колесо и стрелки
   на десктопе — поэтому карусельная библиотека не нужна (её бы и CSP не пустил). */
.testimonials-slider { position: relative; }
.testimonials-track {
  /* flex, а не grid: у grid-auto-columns минимум равен нулю, и вместо прокрутки
     браузер сжимал все карточки в один экран — текст вставал по слову в строку.
     flex: 0 0 <ширина> сжиматься запрещает, поэтому лента честно уезжает вбок. */
  display: flex;
  gap: var(--gap);
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  /* поля, чтобы тень карточек не срезалась краем прокрутки */
  padding: 6px;
  margin: -6px;
  scroll-padding-left: 6px;
  scrollbar-width: none;
}
.testimonials-track::-webkit-scrollbar { display: none; }
/* min-width: 0 — иначе flex не даст карточке стать уже длинного слова внутри */
.testimonials-track > * { flex: 0 0 85%; min-width: 0; scroll-snap-align: start; }

.t-source {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 10px 0 0;
  font-size: 0.9375rem;
  color: var(--ink-2);
  text-decoration: none;
}
.t-source:hover { color: var(--ink); }
.t-source__star { flex-shrink: 0; color: var(--accent); }
.t-source__rating { font-family: var(--font-head); font-weight: 800; color: var(--ink); }

/* На телефоне стрелки не нужны и только сбивают с толку: там листают пальцем,
   а выглядывающий край следующей карточки и так показывает, что лента едет вбок. */
.t-nav { display: none; gap: 8px; }
@media (min-width: 640px) {
  .t-nav { display: flex; }
}
/* app.js прячет блок через hidden, когда листать нечего: класс с display сильнее
   стиля браузера для [hidden], поэтому скрытие нужно прописать явно */
.t-nav[hidden] { display: none; }
.t-nav__btn {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease);
}
.t-nav__btn:hover:not(:disabled) { border-color: var(--border-strong); background: var(--surface-2); }
.t-nav__btn:disabled { opacity: 0.35; cursor: default; }
.t-nav__btn:focus-visible { outline: 2px solid var(--ring); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
  .t-nav__btn { transition: none; }
}

.testimonial {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 0;
  padding: 24px;
}
.testimonial__quotemark {
  display: block;
  height: 30px;
  font-family: var(--font-head);
  font-size: 4rem;
  font-weight: 800;
  line-height: 0.9;
  color: var(--accent);
}
.testimonial__body { flex: 1; margin: 0; }
.testimonial__quote { font-size: 1.0625rem; line-height: 1.65; color: var(--ink); }
.testimonial__divider { height: 1px; background: var(--border); }
.testimonial__author { display: flex; align-items: center; gap: 12px; }
.testimonial__avatar {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  flex-shrink: 0;
  border-radius: var(--r-md);
  background: var(--primary-soft);
  color: var(--on-primary-soft);
  font-family: var(--font-head);
  font-size: 0.9375rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}
.testimonial__avatar--gold { background: var(--accent-soft); color: var(--on-accent-soft); }
.testimonial__avatar--ink { background: var(--btn-navy-bg); color: var(--btn-navy-fg); }
.testimonial__name { font-family: var(--font-head); font-weight: 700; color: var(--ink); }
.testimonial__role { font-size: 0.875rem; line-height: 1.4; color: var(--ink-3); }

@media (min-width: 640px) {
  /* две карточки и краешек третьей — сразу видно, что ленту можно листать */
  .testimonials-track > * { flex-basis: 46%; }
}
@media (min-width: 1024px) {
  .testimonials-track > * { flex-basis: 31%; }
  .testimonial { padding: 32px; }
}

/* ---------------------------------------------------------------------
   6. Process — connected steps
   --------------------------------------------------------------------- */
.process-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.process-step {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 24px;
}
.process-step__num {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: 10px;
  border-radius: var(--r-md);
  background: var(--primary);
  color: var(--on-primary);
  font-family: var(--font-head);
  font-size: 1rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.process-step--last .process-step__num { background: var(--accent); color: var(--on-accent); }

.process-step__bg {
  position: absolute;
  right: 18px;
  bottom: 6px;
  font-family: var(--font-head);
  font-size: 5.5rem;
  font-weight: 800;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  opacity: 0.05;
  pointer-events: none;
  user-select: none;
}
.process-step__title {
  font-family: var(--font-head);
  font-size: 1.3125rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.process-step__desc { position: relative; color: var(--ink-2); line-height: 1.65; }

/* Connectors: vertical on mobile */
.process-step:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 47px;
  bottom: -17px;
  width: 2px;
  height: 16px;
  background: var(--connector);
}
.process-step:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 44px;
  bottom: -12px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 0 0 0 3px var(--bg);
}

@media (min-width: 640px) {
  .process-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .process-step:not(:last-child)::before,
  .process-step:not(:last-child)::after { content: none; }
  .process-step:nth-child(odd)::before {
    content: "";
    position: absolute;
    top: 47px;
    left: 84px;
    right: -17px;
    bottom: auto;
    width: auto;
    height: 2px;
    background: repeating-linear-gradient(90deg, var(--connector) 0 6px, transparent 6px 11px);
  }
  .process-step:nth-child(odd)::after {
    content: "";
    position: absolute;
    top: 44px;
    right: -12px;
    left: auto;
    bottom: auto;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary);
    box-shadow: 0 0 0 3px var(--bg);
  }
}
@media (min-width: 768px) {
  .process-step { padding: 28px; }
  .process-step:nth-child(odd)::before { top: 51px; left: 88px; }
  .process-step:nth-child(odd)::after { top: 48px; }
}
@media (min-width: 1024px) {
  .process-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .process-step:not(:last-child)::before {
    content: "";
    position: absolute;
    top: 51px;
    left: 88px;
    right: -17px;
    bottom: auto;
    width: auto;
    height: 2px;
    background: repeating-linear-gradient(90deg, var(--connector) 0 6px, transparent 6px 11px);
  }
  .process-step:not(:last-child)::after {
    content: "";
    position: absolute;
    top: 48px;
    right: -12px;
    left: auto;
    bottom: auto;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary);
    box-shadow: 0 0 0 3px var(--bg);
  }
}

/* ---------------------------------------------------------------------
   7. Fine-tuning for narrow desktops
   --------------------------------------------------------------------- */
.svc-card__title,
.adv-item__title,
.process-step__title { overflow-wrap: break-word; -webkit-hyphens: auto; hyphens: auto; }

@media (min-width: 1024px) {
  .svc-card:not(.svc-card--featured) .svc-card__title { font-size: clamp(1.0625rem, 0.6rem + 0.6vw, 1.1875rem); }
  .svc-card:not(.svc-card--featured):not(.svc-card--wide) .svc-card__body { padding: 16px 18px 18px; }
  .hero__stat { padding: 18px; }
}
@media (min-width: 1200px) {
  .hero__content { padding: 56px 56px 52px; }
  .hero__stat { padding: 20px; }
}

/* Process sits right above the CTA: tighter bottom padding */
#process { padding-bottom: 24px; }
@media (min-width: 1024px) {
  #process { padding-bottom: 32px; }
}

/* ---------------------------------------------------------------------
   8. Scroll reveal: headline tile paints immediately (LCP)
   --------------------------------------------------------------------- */
@media (prefers-reduced-motion: no-preference) {
  .hero .hero__content.reveal { opacity: 1; animation: none; }
}

/* ---------------------------------------------------------------------
   9. Reduced motion (homepage-only selectors)
   --------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .svc-card, .svc-card::after, .svc-card__image img, .svc-card__arrow svg { transition: none !important; }

  .svc-card:hover, .svc-card:active,
  .svc-card:hover .svc-card__image img,
  .svc-card:hover .svc-card__arrow svg { transform: none !important; }
}

.svc-card__image picture { display: contents; }
