/* ==========================================================
   AFF CASE — DEVILS
   Кольори живуть тільки тут, у коді всюди CSS-змінні.
   ========================================================== */

/* ---------- 1. Токени ---------- */
:root {
  --devils-red: #E90000;
  --devils-black: #171516;
  --devils-white: #F6F6F6;
  --devils-graphite: #211F20;
  --devils-concrete: #D9DBDC;
  --devils-silver: #C0C0C0;
  --devils-gray: #7C7C7C;

  --font-heading: CyGrotesk, "Druk Wide Cy", sans-serif;
  --font-mono: FiraMono, "Fira Mono", monospace;

  --gutter: 48px;
  --header-h: 72px;
  --ease: cubic-bezier(.2, .7, .1, 1);
  --bg-speed: .7s;
}

/* Реєстрація токенів теми — щоб вони плавно анімувались при зміні слайда */
@property --bg     { syntax: "<color>"; inherits: true; initial-value: #171516; }
@property --fg     { syntax: "<color>"; inherits: true; initial-value: #F6F6F6; }
@property --muted  { syntax: "<color>"; inherits: true; initial-value: #F6F6F68C; }
@property --line   { syntax: "<color>"; inherits: true; initial-value: #F6F6F624; }
@property --accent { syntax: "<color>"; inherits: true; initial-value: #E90000; }
@property --chip-bg { syntax: "<color>"; inherits: true; initial-value: #F6F6F6; }
@property --chip-fg { syntax: "<color>"; inherits: true; initial-value: #171516; }
@property --logo-inv { syntax: "<number>"; inherits: true; initial-value: 0; }

/* ---------- 2. Теми слайдів ----------
   Кожна секція фарбується сама; на body (data-slide активного слайда) —
   та сама тема для хедера, вона плавно перетікає. */
body[data-slide="1"], .slide[data-slide="1"],
body[data-slide="2"], .slide[data-slide="2"],
body[data-slide="6"], .slide[data-slide="6"] {
  --bg: var(--devils-black);
  --fg: var(--devils-white);
  --muted: color-mix(in srgb, var(--devils-white) 55%, transparent);
  --line: color-mix(in srgb, var(--devils-white) 14%, transparent);
  --accent: var(--devils-red);
  --chip-bg: var(--devils-white);
  --chip-fg: var(--devils-black);
  --logo-inv: 0;
}
body[data-slide="3"], .slide[data-slide="3"] {
  --bg: var(--devils-graphite);
  --fg: var(--devils-white);
  --muted: color-mix(in srgb, var(--devils-white) 55%, transparent);
  --line: color-mix(in srgb, var(--devils-white) 14%, transparent);
  --accent: var(--devils-red);
  --chip-bg: var(--devils-white);
  --chip-fg: var(--devils-black);
  --logo-inv: 0;
}
/* 04 — майже чорний: червона сфера світиться лише на темному */
body[data-slide="4"], .slide[data-slide="4"] {
  --bg: #0E0C0D;
  --fg: var(--devils-white);
  --muted: color-mix(in srgb, var(--devils-white) 55%, transparent);
  --line: color-mix(in srgb, var(--devils-white) 14%, transparent);
  --accent: var(--devils-red);
  --chip-bg: var(--devils-white);
  --chip-fg: var(--devils-black);
  --logo-inv: 0;
}
/* 05 — темна сцена з червоною сіткою DEVILS */
body[data-slide="5"], .slide[data-slide="5"] {
  --bg: #121011;
  --fg: var(--devils-white);
  --muted: color-mix(in srgb, var(--devils-white) 55%, transparent);
  --line: color-mix(in srgb, var(--devils-white) 14%, transparent);
  --accent: var(--devils-red);
  --chip-bg: var(--devils-white);
  --chip-fg: var(--devils-black);
  --logo-inv: 0;
}

/* ---------- 3. Шрифти ---------- */
@font-face {
  font-display: swap; font-family: CyGrotesk; font-style: normal; font-weight: 800;
  src: url(../fonts/CyGrotesk-GrandBold.woff2) format("woff2");
}
@font-face {
  font-display: swap; font-family: FiraMono; font-style: normal; font-weight: 400;
  src: url(../fonts/FiraMono-Regular.woff2) format("woff2");
}
@font-face {
  font-display: swap; font-family: FiraMono; font-style: normal; font-weight: 500;
  src: url(../fonts/FiraMono-Medium.woff2) format("woff2");
}

/* ---------- 4. База ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* Без CSS scroll-snap і scroll-behavior: smooth — обидва конфліктують із pin/snap ScrollTrigger:
   proximity-snap повертав сторінку назад після короткого жесту колесом (скрол «застрягав»).
   Плавний перехід за якорями робить JS. */
html {
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-mono);
  font-size: 15px;
  line-height: 1.5;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  transition:
    --bg var(--bg-speed) var(--ease), --fg var(--bg-speed) var(--ease),
    --muted var(--bg-speed) var(--ease), --line var(--bg-speed) var(--ease),
    --accent var(--bg-speed) var(--ease), --chip-bg var(--bg-speed) var(--ease),
    --chip-fg var(--bg-speed) var(--ease), --logo-inv var(--bg-speed) var(--ease);
}

a { color: inherit; text-decoration: none; }
/* iOS/Android: без сірої плями при тапі — стан кнопок і так видно */
a, button, textarea { -webkit-tap-highlight-color: transparent; }
img { display: block; max-width: 100%; }

.container {
  margin: 0 auto;
  max-width: 1440px;
  padding: 0 var(--gutter);
  width: 100%;
}

/* ---------- 5. Мікрографіка ---------- */
.chip {
  background: var(--chip-bg);
  color: var(--chip-fg);
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .06em;
  line-height: 1;
  padding: 6px 10px;
  text-transform: uppercase;
  white-space: nowrap;
}

.tech {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .12em;
  line-height: 1.3;
  text-transform: uppercase;
}

/* ---------- 6. Хедер ---------- */
.header {
  align-items: center;
  display: grid;
  gap: 24px;
  grid-template-columns: 1fr auto 1fr;
  height: var(--header-h);
  left: 0;
  padding: 0 var(--gutter);
  position: fixed;
  right: 0;
  top: 0;
  z-index: 50;
}
/* Підкладка під хедер: контент слайдів більше не проїжджає крізь логотип і лічильник.
   На самому верху сторінки прозора — там фото обкладинки має йти до краю */
.header::before {
  background: linear-gradient(var(--bg) 55%, color-mix(in srgb, var(--bg) 0%, transparent));
  content: "";
  inset: 0 0 -16px;
  opacity: 1;
  pointer-events: none;
  position: absolute;
  transition: opacity .5s var(--ease);
  z-index: -1;
}
body.is-top .header::before { opacity: 0; }
.header__logo-img {
  filter: invert(var(--logo-inv));
  height: 16px;
  width: auto;
}
.header__title,
.header__counter {
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.header__title { color: var(--muted); }
.header__counter { justify-self: end; font-variant-numeric: tabular-nums; }
.header__progress {
  background: var(--line);
  bottom: 0;
  height: 1px;
  left: var(--gutter);
  position: absolute;
  right: var(--gutter);
}
.header__progress-bar {
  background: var(--accent);
  display: block;
  height: 100%;
  transform: scaleX(0);
  transform-origin: left;
}

/* ---------- 7. Слайд (загальне) ---------- */
.slide {
  display: flex;
  min-height: 100vh;
  min-height: 100svh;
  padding: calc(var(--header-h) + 40px) 0 48px;
}
/* Кожен слайд фарбується своєю темою сам. Тема на body керує лише хедером —
   інакше колір сусіднього слайда «просвічує» крізь поточний під час переходу */
.slide { background: var(--bg); color: var(--fg); }
.slide > .container { display: flex; flex-direction: column; }

.slide__meta {
  align-items: center;
  display: flex;
  gap: 24px;
  justify-content: space-between;
}

.placeholder {
  color: var(--muted);
  font-size: 13px;
  letter-spacing: .12em;
  margin: auto 0;
  text-transform: uppercase;
}

/* Рядок заголовка, що виїжджає знизу */
/* запас зверху — щоб не обрізалась дужка над Й (padding компенсує negative margin) */
.line { display: block; margin-top: -.14em; overflow: hidden; padding: .14em 0 .06em; }
.line__in { display: block; }

/* ---------- 8. Слайд 01 — Обкладинка (hero з фото) ---------- */
.cover { overflow: hidden; padding-bottom: 32px; position: relative; }

.cover__bg { inset: 0; position: absolute; z-index: 0; }
.cover__bg picture, .cover__img { display: block; height: 100%; width: 100%; }
.cover__img { object-fit: cover; object-position: 68% 35%; }
/* затемнення зліва під текст + легка віньєтка знизу */
.cover__shade {
  background:
    linear-gradient(90deg, rgba(23, 21, 22, .55) 0%, rgba(23, 21, 22, .18) 42%, transparent 62%),
    linear-gradient(0deg, rgba(23, 21, 22, .55) 0%, transparent 28%);
  inset: 0;
  position: absolute;
}
/* спалах від очей маскота (анімується при відкритті) */
.cover__flare {
  background: radial-gradient(circle, rgba(255, 90, 60, .55) 0%, rgba(233, 0, 0, .18) 30%, transparent 62%);
  height: 60vmin;
  left: 57%;
  mix-blend-mode: screen;
  opacity: 0;
  pointer-events: none;
  position: absolute;
  top: 47%;
  transform: translate(-50%, -50%);
  width: 60vmin;
}

.cover__inner { justify-content: center; position: relative; z-index: 1; }

.cover__text { margin: auto 0; max-width: min(620px, 44vw); }

.cover__chip { background: var(--devils-white); color: var(--devils-black); margin-top: 28px; }

.cover__hero {
  color: var(--devils-white);
  font-family: var(--font-heading);
  font-size: clamp(120px, 13.5vw, 230px);
  font-weight: 800;
  letter-spacing: -.045em;
  line-height: .8;
  margin-top: 20px;
  text-shadow: 0 0 18px rgba(255, 255, 255, .45), 0 0 60px rgba(255, 60, 40, .55);
  white-space: nowrap;
}
.cover__num { font-variant-numeric: tabular-nums; }

.cover__title {
  font-family: var(--font-heading);
  font-size: clamp(22px, 2.15vw, 36px);
  font-weight: 800;
  letter-spacing: -.01em;
  line-height: 1.08;
  margin-top: 36px;
  text-shadow: 0 2px 24px rgba(23, 21, 22, .35);
  text-transform: uppercase;
}
.cover__sub {
  color: rgba(246, 246, 246, .85);
  font-family: var(--font-mono);
  font-size: 17px; /* 14px × 1.2 */
  font-weight: 500;
  letter-spacing: .16em;
  line-height: 1.3;
  text-transform: uppercase;
  white-space: nowrap;
}

.cover__foot {
  align-items: center;
  display: flex;
  justify-content: space-between;
}
.cover__foot .tech { color: rgba(246, 246, 246, .7); }
.cover__scroll { align-items: center; display: inline-flex; gap: 12px; }
.cover__scroll-line {
  background: currentColor;
  display: block;
  height: 1px;
  width: 40px;
}

/* ---------- 8b. Слайд 02 — Крупная сделка (скляна арка) ---------- */
.deal { overflow: hidden; padding-top: calc(var(--header-h) + 34px); position: relative; }

/* Сцена зі спіраллю — права частина слайда (під шапкою й підписом) */
.deal__stage {
  bottom: 0;
  left: 0;
  perspective: 1100px;
  pointer-events: none;
  position: absolute;
  right: 0;
  top: calc(var(--header-h) + 70px);
  z-index: 0;
}
.deal__world {
  height: 100%;
  left: 72%;
  position: absolute;
  top: 0;
  transform-style: preserve-3d;
  width: 0;
}
.deal__slot {
  aspect-ratio: 1.5;
  left: 0;
  position: absolute;
  top: 0;
  transform-style: preserve-3d;
}
.deal__pane {
  background:
    linear-gradient(115deg, transparent 38%, rgba(255, 255, 255, .16) 47%, transparent 56%),
    linear-gradient(160deg, rgba(255, 120, 110, .62) 0%, rgba(233, 0, 0, .30) 42%, rgba(110, 0, 0, .38) 100%);
  border: 1px solid rgba(255, 175, 165, .6);
  border-radius: 3px;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, .05),
    inset 0 0 36px rgba(255, 70, 60, .28),
    0 0 26px rgba(233, 0, 0, .12);
  display: block;
  height: 100%;
  opacity: var(--o);
  position: relative;
  width: 100%;
}
/* Тонкий блік на верхньому ребрі скла */
.deal__pane::after {
  background: linear-gradient(90deg, transparent, rgba(255, 225, 220, .85) 30%, transparent 85%);
  content: "";
  height: 1px;
  left: 6%;
  position: absolute;
  right: 6%;
  top: 0;
}

/* Мʼяке червоне світло всередині арки */
.deal__glow {
  background: radial-gradient(closest-side, rgba(233, 0, 0, .22), transparent);
  height: 90vmin;
  left: 72%;
  pointer-events: none;
  position: absolute;
  top: 58%;
  transform: translate(-50%, -50%);
  width: 130vmin;
  z-index: 0;
}

.deal__inner { position: relative; z-index: 1; }

.deal__meta { position: absolute; right: var(--gutter); top: 6px; }
.deal__meta > span:empty { display: none; }
.deal__inner { position: relative; }

/* Текст ліворуч, спіраль праворуч */
.deal__text { margin: auto 0; padding-bottom: 2vh; }

.deal__title {
  font-family: var(--font-heading);
  font-size: clamp(30px, 3.2vw, 56px);
  font-weight: 800;
  letter-spacing: -.025em;
  line-height: .95;
  text-transform: uppercase;
  white-space: nowrap;
}
.deal__title em { color: var(--accent); font-style: normal; }

.deal__body {
  border-top: 1px solid var(--line);
  display: grid;
  gap: 20px;
  max-width: min(540px, 40vw);
  margin-top: clamp(28px, 4.5vh, 44px);
  padding-top: 24px;
}
.deal__body p { color: rgba(246, 246, 246, .78); font-size: clamp(15px, 1.1vw, 20px); line-height: 1.65; }
.deal__body b { color: var(--fg); font-weight: 500; }
.deal__body mark {
  background: linear-gradient(var(--devils-red), var(--devils-red)) no-repeat 0 100% / 100% 100%;
  color: var(--devils-white);
  font-weight: 500;
  padding: 0 4px;
}

/* Мобайл: заголовок → спіраль окремою смугою → текст на всю ширину.
   Контейнер і текстовий блок «розчиняються» (display: contents), щоб спіраль стала між ними */
@media (max-width: 768px) {
  .deal { flex-direction: column; padding-top: calc(var(--header-h) + 28px); }
  .deal > .deal__inner, .deal__text { display: contents; }
  .deal__meta { display: none; }
  .deal__title {
    font-size: clamp(26px, 8.6vw, 44px);
    line-height: 1;
    order: 1;
    padding: 0 var(--gutter);
    position: relative;
    white-space: normal;
    z-index: 1;
  }
  .deal__stage {
    height: 42svh;
    margin: 0 0 28px;
    order: 2;
    position: relative;
    top: auto;
  }
  .deal__world { left: 50%; }
  .deal__glow { height: 70vh; left: 50%; top: 50%; width: 120vw; }
  .deal__body {
    margin: 0 var(--gutter);
    max-width: none;
    order: 3;
    position: relative;
    z-index: 1;
  }
  .deal__body p { font-size: 15px; line-height: 1.6; }
  .deal__body b { white-space: nowrap; }
}

/* ---------- 8c. Слайд 03 — Цель (неоновий моноліт) ---------- */
.goal { overflow: hidden; position: relative; }

/* Сцена з монолітом — ліва половина слайда */
.goal__stage {
  bottom: 0;
  left: 0;
  pointer-events: none;
  position: absolute;
  top: var(--header-h);
  width: 50%;
  z-index: 0;
}
.goal__canvas { display: block; height: 100%; width: 100%; }

/* Вертикальні промені світла за монолітом */
.goal__rays {
  background: repeating-linear-gradient(90deg,
    transparent 0 46px, rgba(233, 0, 0, .07) 46px 48px, transparent 48px 97px, rgba(255, 90, 60, .05) 97px 98px);
  inset: 0;
  -webkit-mask-image: radial-gradient(ellipse 55% 70% at 50% 55%, #000 10%, transparent 75%);
  mask-image: radial-gradient(ellipse 55% 70% at 50% 55%, #000 10%, transparent 75%);
  position: absolute;
}
.goal__glow {
  background: radial-gradient(closest-side, rgba(233, 0, 0, .26), rgba(233, 0, 0, .08) 55%, transparent);
  height: 110vmin;
  left: 50%;
  position: absolute;
  top: 55%;
  transform: translate(-50%, -50%);
  width: 80vmin;
}

.goal__inner { position: relative; z-index: 1; }
.goal__meta { position: absolute; right: var(--gutter); top: -34px; }
.goal__meta > span:empty { display: none; }

/* Текст — права половина */
.goal__text {
  margin: auto 0 auto 50%;
  max-width: 640px;
  padding-left: clamp(0px, 2vw, 40px);
}

.goal__chip { background: var(--devils-red); color: var(--devils-white); }

.goal__lead {
  font-family: var(--font-heading);
  font-size: clamp(22px, 2vw, 34px);
  font-weight: 800;
  letter-spacing: -.01em;
  line-height: 1;
  margin-top: 30px;
  text-transform: uppercase;
}

.goal__hero {
  font-family: var(--font-heading);
  font-size: clamp(72px, 8.4vw, 150px);
  font-weight: 800;
  letter-spacing: -.045em;
  line-height: .85;
  margin-top: 24px;
  white-space: nowrap;
}
.goal__sum {
  color: var(--fg);
  display: inline-block;
  text-shadow: 0 0 22px rgba(255, 90, 60, .45), 0 0 70px rgba(233, 0, 0, .5);
}
.goal__sum span, .goal__x span { font-variant-numeric: tabular-nums; }

.goal__caption {
  align-items: center;
  color: var(--muted);
  display: flex;
  font-size: 13px;
  font-weight: 500;
  gap: 14px;
  letter-spacing: .14em;
  margin-top: 22px;
  text-transform: uppercase;
}
.goal__caption-line { background: var(--accent); display: block; flex: none; height: 1px; width: 48px; }
.goal__x { color: var(--accent); font-weight: 500; }

/* Два пункти: підпис над абзацом, кожен відділений лінією */
.goal__body {
  display: grid;
  gap: clamp(22px, 3.2vh, 32px);
  margin-top: clamp(40px, 7vh, 72px);
}
.goal__point {
  border-top: 1px solid var(--line);
  display: grid;
  gap: 12px;
  padding-top: 18px;
}
.goal__num { color: var(--accent); }
.goal__point p { color: rgba(246, 246, 246, .78); font-size: clamp(15px, 1.05vw, 19px); line-height: 1.65; max-width: 58ch; }
.goal__point b { color: var(--fg); font-weight: 500; }
.goal__point mark {
  background: linear-gradient(var(--devils-red), var(--devils-red)) no-repeat 0 100% / 100% 100%;
  color: var(--devils-white);
  font-weight: 500;
  padding: 0 4px;
}

/* ---------- 8d. Слайд 04 — Собственная аналитика (сфера + скляна колода) ---------- */
.sys { overflow: hidden; position: relative; }

/* Сцена зі сферою — на весь слайд, сфера праворуч */
.sys__stage { inset: var(--header-h) 0 0 0; pointer-events: none; position: absolute; z-index: 0; }
.sys__canvas { display: block; height: 100%; width: 100%; }
.sys__glow {
  background: radial-gradient(closest-side, rgba(233, 0, 0, .22), rgba(233, 0, 0, .06) 55%, transparent);
  height: 95vmin;
  left: 72%;
  position: absolute;
  top: 47%;
  transform: translate(-50%, -50%);
  width: 95vmin;
}

.sys__inner { position: relative; z-index: 1; }
.sys__meta { position: absolute; right: var(--gutter); top: -34px; }
.sys__meta > span:empty { display: none; }

.sys__title {
  font-family: var(--font-heading);
  font-size: clamp(30px, 3.2vw, 56px);
  font-weight: 800;
  letter-spacing: -.025em;
  line-height: .95;
  text-transform: uppercase;
  white-space: nowrap;
  width: max-content;
}
.sys__title em { color: var(--accent); font-style: normal; text-shadow: 0 0 28px rgba(233, 0, 0, .45); }
html:not(.js) .sys__title .line { overflow: visible; }

.sys__lead {
  color: rgba(246, 246, 246, .75);
  font-size: clamp(14px, 1vw, 17px);
  line-height: 1.6;
  margin-top: clamp(16px, 2.4vh, 26px);
  max-width: 50ch;
}

.sys__bottom { margin-top: auto; padding-top: 24px; width: min(660px, 48vw); }

.sys__split {
  align-items: center;
  color: var(--muted);
  display: flex;
  font-size: 12px;
  font-weight: 500;
  gap: 14px;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.sys__split b { color: var(--accent); font-weight: 500; }
.sys__split-line { background: var(--accent); display: block; flex: none; height: 1px; width: 48px; }

/* Перемикач 01 — 02 з лінією прогресу (--prog ставить JS) */
.sys__tabs { align-items: center; display: flex; gap: 20px; margin-top: clamp(14px, 2.2vh, 22px); }
.sys__tab {
  background: none;
  border: 0;
  color: var(--muted);
  cursor: pointer;
  font: 500 11px/1.3 var(--font-mono);
  letter-spacing: .12em;
  padding: 6px 0;
  text-transform: uppercase;
  transition: color .4s;
  white-space: nowrap;
}
.sys__tab:hover, .sys__tab.is-active { color: var(--fg); }
.sys__tab b { color: var(--accent); font-weight: 500; margin-right: 8px; }
.sys__bar { background: var(--line); flex: 1; height: 1px; min-width: 40px; position: relative; }
.sys__bar::after {
  background: var(--accent);
  box-shadow: 0 0 10px rgba(233, 0, 0, .8);
  content: "";
  inset: 0;
  position: absolute;
  transform: scaleX(var(--prog, 0));
  transform-origin: left;
}

/* Колода: обидві картки в одній клітинці, активна спереду, інша визирає позаду */
.sys__deck { display: grid; grid-template-columns: minmax(0, 1fr); margin-top: clamp(22px, 3.4vh, 34px); }
.sys__card {
  background: linear-gradient(160deg, #3a0e0e, #171213 55%);
  border: 1px solid rgba(255, 120, 110, .28);
  box-shadow: 0 30px 60px rgba(0, 0, 0, .45), inset 0 1px 0 rgba(255, 200, 190, .18);
  display: grid;
  align-content: start;
  gap: 12px 24px;
  grid-area: 1 / 1;
  grid-template-columns: minmax(0, 1fr) auto;
  overflow: hidden;
  padding: clamp(20px, 2.8vh, 28px) 28px;
  position: relative;
  transition: transform .8s var(--ease), opacity .6s var(--ease), filter .6s var(--ease);
}
/* блік на верхньому ребрі скла */
.sys__card::after {
  background: linear-gradient(90deg, transparent, rgba(255, 190, 180, .8) 30%, transparent 85%);
  content: "";
  height: 1px;
  left: 8%;
  position: absolute;
  right: 8%;
  top: 0;
}
/* великий контурний індекс у куті картки */
.sys__idx {
  color: transparent;
  font-family: var(--font-heading);
  font-size: clamp(64px, 6vw, 104px);
  font-weight: 800;
  letter-spacing: -.04em;
  line-height: .8;
  grid-column: 2;
  grid-row: 1;
  margin: -4px -6px 0 0;
  pointer-events: none;
  -webkit-text-stroke: 1px rgba(255, 120, 110, .35);
}
.sys__h {
  font-family: var(--font-heading);
  font-size: clamp(18px, 1.5vw, 26px);
  font-weight: 800;
  letter-spacing: -.01em;
  line-height: 1.05;
  align-self: center;
  grid-column: 1;
  grid-row: 1;
  text-transform: uppercase;
}
.sys__card p { grid-column: 1 / -1; }
.sys__card p { color: rgba(246, 246, 246, .75); font-size: clamp(13px, .95vw, 16px); line-height: 1.6; }
.sys__lead mark,
.sys__card mark {
  background: linear-gradient(var(--devils-red), var(--devils-red)) no-repeat 0 100% / 100% 100%;
  color: var(--devils-white);
  font-weight: 500;
  padding: 0 4px;
}

/* Десктоп з JS: слайд на весь екран, картки перемикаються */
@media (min-width: 769px) {
  .js .sys { height: 100vh; height: 100svh; }
  .js .sys__card > * { transition: opacity .4s; }
  .js .sys__card:not(.is-active) {
    filter: blur(1.5px);
    opacity: .4;
    transform: translate(34px, -34px) scale(.93);
    transform-origin: top right;
    z-index: 0;
  }
  .js .sys__card:not(.is-active) > * { opacity: 0; }
  .js .sys__card.is-active { z-index: 2; }
}
/* Невисокі екрани — компактніше, щоб картка влізла */
@media (min-width: 769px) and (max-height: 820px) {
  .sys { padding-top: calc(var(--header-h) + 28px); padding-bottom: 28px; }
  .sys__meta { top: -20px; }
  .sys__title { font-size: clamp(28px, 2.7vw, 44px); }
  .sys__card { gap: 9px; }
  .sys__card p { font-size: 13px; line-height: 1.5; }
  .sys__idx { font-size: 64px; }
}

/* ---------- 8e. Слайд 05 — Динамика масштабирования (графік на паттернах DEVILS) ---------- */
.scale { overflow: hidden; position: relative; }

.scale__stage { inset: 0; pointer-events: none; position: absolute; z-index: 0; }
.scale__canvas { display: block; height: 100%; width: 100%; }
/* тонкі лінії модульної сітки, як у референсі */
.scale__grid {
  background: linear-gradient(var(--line), var(--line)) calc(79% - 24px) 0 / 1px 100% no-repeat;
  inset: var(--header-h) 0 0;
  opacity: .5;
  position: absolute;
}

/* Мітки на лінії росту: пін → горизонтальна лінія → підпис у правій колонці.
   --x/--y (точка на ребрі) і --lx (колонка підписів) ставить JS */
.scale__marks { inset: 0; pointer-events: none; position: absolute; z-index: 1; }
.scale__mark { left: 0; position: absolute; top: 0; }
.scale__pin {
  height: 15px;
  left: var(--x);
  position: absolute;
  top: var(--y);
  transform: translate(-50%, -50%);
  width: 15px;
}
.scale__pin::before, .scale__pin::after {
  background: var(--devils-white);
  content: "";
  left: 50%;
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
}
.scale__pin::before { height: 1px; width: 15px; }
.scale__pin::after { height: 15px; width: 1px; }
.scale__lead {
  background: repeating-linear-gradient(90deg, rgba(246, 246, 246, .5) 0 4px, transparent 4px 8px);
  height: 1px;
  left: calc(var(--x) + 12px);
  position: absolute;
  top: var(--y);
  transform-origin: left;
  width: calc(var(--lx) - var(--x) - 24px);
}
.scale__tag {
  display: grid;
  gap: 6px;
  left: var(--lx);
  position: absolute;
  top: var(--y);
  transform: translateY(-50%);
  white-space: nowrap;
}
.scale__tag .tech { color: var(--accent); }
.scale__tag b {
  font-family: var(--font-heading);
  font-size: clamp(22px, 2vw, 34px);
  font-weight: 800;
  letter-spacing: -.02em;
  line-height: 1;
}
.scale__mark[data-f="2"] .scale__tag b { font-size: clamp(34px, 3.2vw, 56px); text-shadow: 0 0 30px rgba(233, 0, 0, .55); }

.scale__inner { position: relative; z-index: 2; }
.scale__meta { position: absolute; right: var(--gutter); top: -34px; }
.scale__meta > span:empty { display: none; }

.scale__label {
  color: var(--accent);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.scale__title {
  font-family: var(--font-heading);
  font-size: clamp(48px, min(6vw, 10.5vh), 110px);
  font-weight: 800;
  letter-spacing: -.03em;
  line-height: .92;
  margin-top: clamp(14px, 2.4vh, 26px);
  text-transform: uppercase;
  white-space: nowrap;
}
.scale__title em { color: var(--accent); font-style: normal; font-variant-numeric: tabular-nums; text-shadow: 0 0 34px rgba(233, 0, 0, .5); }
html:not(.js) .scale__title .line { overflow: visible; }

.scale__kpi {
  align-items: center;
  border: 1px solid var(--line);
  display: inline-flex;
  font-size: 12px;
  font-weight: 500;
  gap: 12px;
  letter-spacing: .12em;
  margin-top: clamp(22px, 4vh, 40px);
  padding: 14px 18px;
  position: relative;
  text-transform: uppercase;
}
.scale__check {
  fill: none;
  flex: none;
  height: 16px;
  stroke: var(--accent);
  stroke-dasharray: 20;
  stroke-linecap: square;
  stroke-width: 2;
  width: 16px;
}

/* Низ: два місяці + лічильник обсягу */
.scale__bottom {
  align-items: start;
  display: grid;
  gap: clamp(24px, 2.8vw, 48px);
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(200px, .5fr);
  margin-top: auto;
  padding-top: 24px;
}
.scale__month {
  border-top: 1px solid var(--line);
  display: grid;
  gap: 20px;
  grid-template-columns: clamp(76px, 7vw, 112px) minmax(0, 1fr);
  padding-top: 20px;
  position: relative;
  transition: opacity .6s var(--ease);
}
/* червона лінія зверху — заповнюється, коли місяць «досягнуто» */
.scale__month::before {
  background: var(--accent);
  box-shadow: 0 0 10px rgba(233, 0, 0, .8);
  content: "";
  height: 1px;
  left: 0;
  position: absolute;
  right: 0;
  top: -1px;
  transform: scaleX(var(--on, 1));
  transform-origin: left;
}
.scale__thumb {
  align-self: start;
  aspect-ratio: 1;
  background: #141112 var(--thumb, none) center / cover;
  border: 1px solid var(--line);
  position: relative;
}
.scale__thumb i {
  bottom: 6px;
  color: rgba(246, 246, 246, .7);
  font-size: 10px;
  font-style: normal;
  letter-spacing: .12em;
  position: absolute;
  right: 8px;
}
.scale__body { display: grid; gap: 10px; }
.scale__when { color: var(--accent); font-size: 11px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; }
.scale__h {
  font-family: var(--font-heading);
  font-size: clamp(18px, 1.5vw, 26px);
  font-weight: 800;
  letter-spacing: -.01em;
  line-height: 1;
  text-transform: uppercase;
}
.scale__nums { align-items: end; display: flex; gap: 18px; margin-top: 4px; }
.scale__nums > div { display: grid; gap: 4px; }
.scale__nums b {
  font-family: var(--font-heading);
  font-size: clamp(18px, 1.6vw, 28px);
  font-weight: 800;
  letter-spacing: -.02em;
  line-height: 1;
  white-space: nowrap;
}
.scale__nums > div:first-child b { color: var(--muted); }
.scale__to { color: var(--fg); text-shadow: 0 0 22px rgba(233, 0, 0, .55); }
.scale__arrow { color: var(--accent); font-size: 18px; line-height: 1.2; }
.scale__body p { color: rgba(246, 246, 246, .72); font-size: clamp(12px, .9vw, 15px); line-height: 1.55; margin-top: 2px; }
.scale__body mark {
  background: linear-gradient(var(--devils-red), var(--devils-red)) no-repeat 0 100% / 100% 100%;
  color: var(--devils-white);
  font-weight: 500;
  padding: 0 4px;
}

@media (min-width: 769px) and (max-height: 820px) {
  .scale { padding-top: calc(var(--header-h) + 30px); padding-bottom: 30px; }
  .scale__meta { top: -22px; }
  .scale__month { gap: 16px; padding-top: 16px; }
  .scale__body { gap: 8px; }
  .scale__body p { font-size: 12.5px; line-height: 1.5; }
}

/* Мобайл: заголовок і KPI → графік окремим блоком (мітки лягають поверх нього) → місяці стовпчиком */
@media (max-width: 768px) {
  .scale { --chart-h: 54svh; flex-direction: column; padding-top: calc(var(--header-h) + 28px); }
  .scale > .scale__inner { display: contents; }
  .scale__meta, .scale__grid { display: none; }
  .scale__head { margin: 0 var(--gutter); position: relative; z-index: 2; }
  .scale__title { column-gap: .28em; display: flex; flex-wrap: wrap; font-size: 10.4vw; margin-top: 14px; white-space: normal; }
  .scale__title .line:first-child { width: 100%; }
  .scale__kpi { font-size: 11px; gap: 10px; letter-spacing: .1em; margin-top: 20px; padding: 12px 14px; }
  /* верх графіка розчиняється у фон слайда — без «шва» */
  .scale__stage {
    height: var(--chart-h); inset: auto; margin-top: 8px; order: 1; position: relative;
    -webkit-mask-image: linear-gradient(transparent, #000 14%); mask-image: linear-gradient(transparent, #000 14%);
  }
  .scale__marks { height: var(--chart-h); inset: auto; margin-top: calc(-1 * var(--chart-h)); order: 2; position: relative; }
  .scale__tag b { font-size: 24px; }
  .scale__mark[data-f="2"] .scale__tag b { font-size: 36px; }
  .scale__bottom { gap: 28px; grid-template-columns: minmax(0, 1fr); margin: 0 var(--gutter); order: 3; padding-top: 4px; position: relative; z-index: 2; }
  .scale__month { gap: 16px; grid-template-columns: 64px minmax(0, 1fr); }
  .scale__h { font-size: 20px; }
  .scale__nums b { font-size: 22px; }
  .scale__body p { font-size: 14px; }
}

/* ---------- 8f. Слайд 06 — От фида к собственной оценке (маскот: оберт 360° → деталі) ---------- */

/* Фон = фон фото маскота, щоб краї кадру зливались зі сторінкою */
body[data-slide="6"], .slide[data-slide="6"] { --bg: #030302; }

/* Свій pin і покрокова навігація в JS */
.zoom { overflow: hidden; position: relative; }

/* Сцена на весь слайд; камера — обгортка, яку JS зсуває й масштабує */
.zoom__stage { inset: 0; overflow: hidden; perspective: 1400px; pointer-events: none; position: absolute; z-index: 0; }
.zoom__cam { height: 100%; left: 0; perspective: 1400px; position: absolute; top: 0; transform-origin: 0 0; width: 100%; will-change: transform; }
.zoom__img {
  aspect-ratio: 1100 / 1800;
  height: 100%;
  left: var(--img-l, 50%);
  max-width: none;
  position: absolute;
  top: 0;
  transform-origin: 50% 60%;
  width: auto;
  will-change: transform;
}
/* Вирізаний маскот (PNG без фону); світіння й відблиск на підлозі вже в картинках */
/* червона підсвітка підлоги під ногами */
.zoom__floor {
  background: radial-gradient(closest-side, rgba(233, 0, 0, .5), rgba(233, 0, 0, .16) 55%, transparent);
  position: absolute;
  transform: translate(-50%, -50%);
}
.zoom__dust { display: block; height: 100%; inset: 0; position: absolute; width: 100%; }
/* Оберт: кадри лежать точно на головному фото, позицію ставить JS */
.zoom__turn { opacity: 0; position: absolute; top: 0; will-change: transform, opacity; }
.zoom__turn img { height: 100%; inset: 0; opacity: 0; position: absolute; width: 100%; }

/* затемнення зліва під текст */
.zoom__vignette {
  background:
    linear-gradient(90deg, rgba(3, 3, 2, .92) 0%, rgba(3, 3, 2, .7) 30%, transparent 55%),
    linear-gradient(0deg, rgba(3, 3, 2, .8) 0%, transparent 22%);
  inset: 0;
  position: absolute;
}

/* Рамка-приціл: 4 кути + підпис; позицію й розмір ставить JS */
.zoom__frame { height: 0; left: 0; opacity: 0; position: absolute; top: 0; width: 0; }
.zoom__frame i { border: 0 solid var(--devils-red); height: 22px; position: absolute; width: 22px; filter: drop-shadow(0 0 6px rgba(233, 0, 0, .8)); }
.zoom__frame i:nth-child(1) { border-left-width: 2px; border-top-width: 2px; left: 0; top: 0; }
.zoom__frame i:nth-child(2) { border-right-width: 2px; border-top-width: 2px; right: 0; top: 0; }
.zoom__frame i:nth-child(3) { border-bottom-width: 2px; border-left-width: 2px; bottom: 0; left: 0; }
.zoom__frame i:nth-child(4) { border-bottom-width: 2px; border-right-width: 2px; bottom: 0; right: 0; }
.zoom__frame-label { color: var(--devils-white); left: 0; position: absolute; top: calc(100% + 12px); white-space: nowrap; }

.zoom__inner { position: relative; z-index: 1; }
.zoom__meta { position: absolute; right: var(--gutter); top: -34px; }
.zoom__meta > span:empty { display: none; }

/* Усі панелі в одній клітинці, видно активну */
.zoom__text { display: grid; margin: auto 0; width: min(560px, 42vw); }
.zoom__panel { align-self: center; grid-area: 1 / 1; }

.zoom__chip { margin-bottom: clamp(18px, 2.6vh, 28px); }
.zoom__title {
  font-family: var(--font-heading);
  font-size: clamp(30px, 3.1vw, 54px);
  font-weight: 800;
  letter-spacing: -.025em;
  line-height: .95;
  text-transform: uppercase;
}
.zoom__h {
  font-family: var(--font-heading);
  font-size: clamp(44px, 5.4vw, 92px);
  font-weight: 800;
  letter-spacing: -.03em;
  line-height: .9;
  margin-top: 14px;
  text-transform: uppercase;
}
.zoom__title em, .zoom__h em { color: var(--accent); font-style: normal; text-shadow: 0 0 28px rgba(233, 0, 0, .45); }
.zoom__num { color: var(--accent); }

.zoom__body {
  color: rgba(246, 246, 246, .75);
  font-size: clamp(14px, 1.05vw, 17px);
  line-height: 1.6;
  margin-top: clamp(18px, 2.6vh, 28px);
  max-width: 46ch;
}
.zoom__body mark {
  background: linear-gradient(var(--devils-red), var(--devils-red)) no-repeat 0 100% / 100% 100%;
  color: var(--devils-white);
  font-weight: 500;
  padding: 0 4px;
}
/* «Было» — сірий маркер: стара модель */
.zoom__panel--was .zoom__body mark { background-image: linear-gradient(#4a4647, #4a4647); }

/* «Что это изменило?» — зʼявляється через 2 с на кроці «Стало» */
.zoom__next {
  align-items: center;
  color: var(--fg);
  display: flex;
  font: 500 13px/1.3 var(--font-mono);
  gap: 14px;
  letter-spacing: .14em;
  margin-top: clamp(26px, 4vh, 44px);
  text-transform: uppercase;
}
.zoom__next-line { background: var(--accent); display: block; flex: none; height: 1px; width: 48px; }
.zoom__next-arrow { color: var(--accent); animation: zoom-bob 1.4s ease-in-out infinite; }
@keyframes zoom-bob { 50% { transform: translateY(4px); } }

/* Рейка кроків з лінією прогресу (--prog ставить JS) */
.zoom__rail { display: flex; flex-wrap: wrap; gap: 6px 22px; padding-top: 16px; position: relative; width: min(560px, 42vw); }
.zoom__rail button {
  background: none;
  border: 0;
  color: var(--muted);
  cursor: pointer;
  font: 500 11px/1.3 var(--font-mono);
  letter-spacing: .12em;
  padding: 4px 0;
  text-transform: uppercase;
  transition: color .4s;
  white-space: nowrap;
}
.zoom__rail button:hover, .zoom__rail button.is-active { color: var(--fg); }
.zoom__rail b { color: var(--accent); font-weight: 500; margin-right: 6px; }
.zoom__bar { background: var(--line); height: 1px; left: 0; position: absolute; right: 0; top: 0; }
.zoom__bar::after {
  background: var(--accent);
  box-shadow: 0 0 10px rgba(233, 0, 0, .8);
  content: "";
  inset: 0;
  position: absolute;
  transform: scaleX(var(--prog, 0));
  transform-origin: left;
}

/* З JS: слайд на весь екран, неактивні панелі сховані */
.js .zoom { height: 100vh; height: 100svh; }
.js .zoom__panel { visibility: hidden; }
.js .zoom__panel.is-active { visibility: visible; }

/* Без JS / reduced motion: усі тексти списком */
html:not(.js) .zoom__panel + .zoom__panel { margin-top: 48px; }
html:not(.js) .zoom__panel { grid-area: auto; }
html:not(.js) .zoom__text { display: block; }

@media (min-width: 769px) and (max-height: 820px) {
  .zoom { padding-top: calc(var(--header-h) + 28px); padding-bottom: 28px; }
  .zoom__meta { top: -20px; }
  .zoom__title { font-size: clamp(28px, 2.7vw, 44px); }
  .zoom__h { font-size: clamp(40px, 4.4vw, 72px); }
  .zoom__body { font-size: 14px; line-height: 1.5; }
}

/* Мобільний: маскот зверху, текст знизу */
@media (max-width: 768px) {
  /* щільніше затемнення під текстом — підписи не губляться на яскравих деталях (хвіст, гроші) */
  .zoom__vignette {
    background: linear-gradient(0deg, rgba(3, 3, 2, .98) 0%, rgba(3, 3, 2, .9) 40%, rgba(3, 3, 2, .55) 54%, transparent 68%);
  }
  .zoom__text { margin: auto 0 0; width: auto; }
  .zoom__panel { align-self: end; }
  .zoom__title { font-size: 7vw; }
  .zoom__h { font-size: 12vw; }
  .zoom__body { font-size: 14px; line-height: 1.55; margin-top: 16px; }
  .zoom__next { font-size: 12px; margin-top: 20px; }
  /* рейка кроків — завжди в один рядок */
  .zoom__rail { flex-wrap: nowrap; gap: 10px; justify-content: space-between; margin-top: 18px; width: auto; }
  .zoom__rail button { font-size: 10px; letter-spacing: .06em; }
  .zoom__rail b { margin-right: 4px; }
  .zoom__frame { display: none; }
}

/* ---------- 8g. Слайд 07 — Слово CBDO (портрет у контровому світлі + цитата) ---------- */

body[data-slide="7"], .slide[data-slide="7"] {
  --bg: #070506;
  --fg: var(--devils-white);
  --muted: color-mix(in srgb, var(--devils-white) 55%, transparent);
  --line: color-mix(in srgb, var(--devils-white) 14%, transparent);
  --accent: var(--devils-red);
  --chip-bg: var(--devils-white);
  --chip-fg: var(--devils-black);
  --logo-inv: 0;
}

.voice { overflow: hidden; position: relative; }

/* Сцена праворуч: джерело світла за спиною → ореол → портрет */
.voice__stage { inset: 0; pointer-events: none; position: absolute; z-index: 0; }
.voice__img {
  aspect-ratio: 1122 / 1402;
  bottom: 0;
  height: calc(100% - var(--header-h) + 2vh);
  max-width: none;
  position: absolute;
  right: 5vw;
  width: auto;
  will-change: transform, filter;
  /* низ портрета розчиняється у фоні */
  -webkit-mask-image: linear-gradient(0deg, transparent 0%, #000 22%);
  mask-image: linear-gradient(0deg, transparent 0%, #000 22%);
}
/* центр ореолу — за головою (≈45% ширини портрета, 22% висоти) */
.voice__halo {
  background: radial-gradient(closest-side, rgba(233, 0, 0, .55), rgba(233, 0, 0, .2) 45%, rgba(233, 0, 0, .06) 70%, transparent);
  height: 92vh;
  mix-blend-mode: screen;
  position: absolute;
  right: calc(5vw + (100vh - var(--header-h)) * .8 * .55 - 46vh);
  top: calc(var(--header-h) + (100vh - var(--header-h)) * .24 - 46vh);
  width: 92vh;
}
/* вертикальна світлова щілина за фігурою */
.voice__beam {
  background: linear-gradient(180deg, transparent, rgba(255, 70, 50, .9) 22%, rgba(233, 0, 0, .5) 48%, transparent 66%);
  bottom: 0;
  box-shadow: 0 0 24px 4px rgba(233, 0, 0, .55), 0 0 90px 20px rgba(233, 0, 0, .25);
  position: absolute;
  right: calc(5vw + (100vh - var(--header-h)) * .8 * .55);
  top: var(--header-h);
  transform-origin: 50% 100%;
  width: 2px;
}
.voice__shade {
  background:
    linear-gradient(90deg, rgba(7, 5, 6, .96) 0%, rgba(7, 5, 6, .8) 34%, transparent 52%),
    linear-gradient(0deg, rgba(7, 5, 6, .9) 0%, transparent 16%);
  inset: 0;
  position: absolute;
}

.voice__inner { position: relative; z-index: 1; }
.voice__meta { position: absolute; right: var(--gutter); top: -34px; }
.voice__meta > span:empty { display: none; }

.voice__text { margin: auto 0; width: min(660px, 48vw); }

.voice__title {
  font-family: var(--font-heading);
  font-size: clamp(24px, 2.3vw, 40px);
  font-weight: 800;
  letter-spacing: -.025em;
  line-height: .95;
  text-transform: uppercase;
  white-space: nowrap;
}
/* На широких екранах рядок довший за колонку — не обрізати його маскою .line */
@media (min-width: 769px) { .voice__title { width: max-content; } }
.voice__title em { color: var(--accent); font-style: normal; text-shadow: 0 0 28px rgba(233, 0, 0, .45); }

.voice__quote {
  border-left: 1px solid var(--line);
  display: grid;
  gap: 16px;
  margin-top: clamp(24px, 4vh, 40px);
  max-width: 54ch;
  padding-left: 24px;
  position: relative;
}
/* червона частина лінії «заповнюється» при появі цитати */
.voice__quote::before {
  background: var(--accent);
  box-shadow: 0 0 10px rgba(233, 0, 0, .8);
  content: "";
  height: calc(var(--fill, 1) * 100%);
  left: -1px;
  position: absolute;
  top: 0;
  width: 1px;
}
.voice__quote p { color: rgba(246, 246, 246, .75); font-size: clamp(14px, 1.05vw, 17px); line-height: 1.6; }
.voice__quote mark {
  background: linear-gradient(var(--devils-red), var(--devils-red)) no-repeat 0 100% / 100% 100%;
  color: var(--devils-white);
  font-weight: 500;
  padding: 0 4px;
}
.voice__cta { border-top: 1px solid var(--line); color: var(--fg) !important; padding-top: 16px; }
.voice__cta b { color: var(--accent); font-weight: 500; text-shadow: 0 0 18px rgba(233, 0, 0, .5); }

.voice__sign { align-items: baseline; display: flex; gap: 14px; margin-top: clamp(24px, 4vh, 40px); }
.voice__sign-line { align-self: center; background: var(--accent); display: block; height: 1px; width: 48px; transform-origin: left; }
.voice__name { font-family: var(--font-heading); font-size: clamp(20px, 1.6vw, 28px); font-weight: 800; letter-spacing: -.01em; text-transform: uppercase; }
.voice__role { color: var(--fg); }

/* Невисокі екрани — компактніше */
@media (min-width: 769px) and (max-height: 820px) {
  .voice { padding-top: calc(var(--header-h) + 28px); padding-bottom: 28px; }
  .voice__meta { top: -20px; }
  .voice__title { font-size: clamp(24px, 2.2vw, 38px); }
  .voice__quote { gap: 12px; }
  .voice__quote p { font-size: 14px; line-height: 1.5; }
}

/* Мобільний: портрет зверху, цитата під ним */
@media (max-width: 768px) {
  .voice { --st-h: min(58svh, 118vw); flex-direction: column; }
  .voice__stage { height: var(--st-h); margin: -24px 0 calc(var(--st-h) * -.2); position: relative; }
  .voice__img { height: 100%; left: 50%; right: auto; transform: translateX(-50%); }
  /* контрове світло на мобайлі — лише ореол за головою (≈22% висоти портрета); щілину прибрано — на вузькому кадрі вона проходить за обличчям */
  .voice__halo {
    height: 96vw; left: calc(50% - 48vw); right: auto;
    top: calc(var(--st-h) * .24 - 48vw); width: 96vw;
  }
  .voice__beam { display: none; }
  .voice__shade { background: linear-gradient(0deg, rgba(7, 5, 6, 1) 0%, transparent 40%); }
  .voice__text { width: auto; }
  /* «МАСШТАБИРОВАНИЯ» — найдовше слово, під нього й розмір */
  .voice__title { font-size: 6vw; white-space: normal; }
  .voice__quote { padding-left: 18px; }
  .voice__quote p { font-size: 14px; line-height: 1.6; }
}

/* ---------- 8h. Слайд 08 — Контакт (червоний екран + чорний маскот + форма) ---------- */

/* Червоний = фон рендера маскота (#F40002), щоб картинка зливалась зі слайдом */
body[data-slide="8"], .slide[data-slide="8"] {
  --bg: #F40002;
  --fg: var(--devils-black);
  --muted: rgba(23, 21, 22, .7);
  --line: rgba(23, 21, 22, .25);
  --accent: var(--devils-white);
  --chip-bg: var(--devils-black);
  --chip-fg: var(--devils-white);
  --logo-inv: 0;
}

.contact { overflow: hidden; position: relative; }

.contact__stage { inset: 0; pointer-events: none; position: absolute; z-index: 0; }
/* поле хрестиків DEVILS зліва, розчиняється до маскота */
.contact__plus {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='40'%3E%3Cpath d='M20 16v8M16 20h8' stroke='%23171516' stroke-opacity='.22'/%3E%3C/svg%3E");
  inset: 0;
  position: absolute;
  -webkit-mask-image: linear-gradient(90deg, #000, transparent 55%);
  mask-image: linear-gradient(90deg, #000, transparent 55%);
}
.contact__img {
  bottom: 0;
  height: min(100vh, 58vw);
  max-width: none;
  position: absolute;
  right: -2vw;
  width: auto;
  will-change: transform;
}

.contact__inner { position: relative; z-index: 1; }
.contact__meta { position: absolute; right: var(--gutter); top: -34px; }
.contact__meta > span:empty { display: none; }

.contact__text { margin: auto 0; max-width: 780px; }
.contact__title {
  font-family: var(--font-heading);
  font-size: clamp(34px, 4.6vw, 76px); /* 76 — щоб «ПАРТНЕРСТВО» влазило в колонку 780 */
  font-weight: 800;
  letter-spacing: -.03em;
  line-height: .9;
  margin-top: clamp(18px, 3vh, 24px);
  text-transform: uppercase;
}
.contact__title em { color: var(--devils-white); font-style: normal; }

/* Форма — чорний блок із жорсткою тінню */
.contact__form {
  background: var(--devils-black);
  box-shadow: 18px 18px 0 rgba(23, 21, 22, .25);
  color: var(--devils-white);
  display: grid;
  gap: 12px 16px;
  grid-template-columns: 1fr auto;
  margin-top: clamp(28px, 5vh, 48px);
  max-width: 640px;
  padding: 16px;
}
.contact__field {
  background: transparent;
  border: 0;
  border-bottom: 1px solid rgba(246, 246, 246, .25);
  border-radius: 0;
  color: inherit;
  font: inherit;
  font-size: 15px;
  padding: 10px 2px;
  resize: none;
  transition: border-color .3s var(--ease);
}
.contact__field::placeholder { color: rgba(246, 246, 246, .5); }
.contact__field:focus { border-color: #F40002; outline: none; }
.contact__send {
  align-items: center;
  align-self: end;
  background: var(--devils-white);
  border: 0;
  color: var(--devils-black);
  cursor: pointer;
  display: inline-flex;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  gap: 14px;
  letter-spacing: .1em;
  padding: 14px 18px;
  text-transform: uppercase;
  transition: background .3s var(--ease), color .3s var(--ease);
  white-space: nowrap;
}
.contact__send i { font-style: normal; transition: transform .3s var(--ease); }
.contact__send:hover { background: #F40002; color: var(--devils-white); }
.contact__send:hover i { transform: translateX(4px); }
.contact__send:focus-visible { outline: 2px solid var(--devils-white); outline-offset: 3px; }
.contact__count { color: rgba(246, 246, 246, .45); grid-column: 1 / -1; font-variant-numeric: tabular-nums; }

.contact__bottom { display: flex; gap: 24px; justify-content: space-between; margin-top: clamp(20px, 3vh, 32px); }
/* праворуч лягає на чорну футболку маскота — тому білим */
.contact__link { color: var(--devils-white); position: relative; text-underline-offset: 4px; z-index: 1; }
.contact__link:hover { text-decoration: underline; }

/* Невисокі екрани — компактніше */
@media (min-width: 769px) and (max-height: 820px) {
  .contact { padding-top: calc(var(--header-h) + 28px); padding-bottom: 24px; }
  .contact__meta { top: -20px; }
  .contact__title { font-size: clamp(30px, 4vw, 64px); }
  .contact__form { margin-top: 24px; }
}

/* Мобільний: текст і форма зверху, маскот знизу */
@media (max-width: 768px) {
  /* маскот — окремо внизу, цілком у кадрі; підписи й посилання — одразу під формою, на червоному */
  .contact { --mascot-h: min(46svh, 104vw); }
  .contact__img { height: var(--mascot-h); left: 50%; right: auto; transform: translateX(-46%); }
  .contact__text { margin: 0; }
  .contact__title { font-size: 8.6vw; }
  .contact__form { grid-template-columns: minmax(0, 1fr); box-shadow: 10px 10px 0 rgba(23, 21, 22, .25); }
  .contact__field { font-size: 16px; } /* ≥16px — iOS Safari не зумить сторінку при фокусі */
  .contact__send { justify-content: space-between; }
  .contact__bottom { flex-direction: column; gap: 8px; margin-top: 28px; padding-bottom: calc(var(--mascot-h) - 24px); }
  .contact__link { color: var(--devils-black); text-decoration: underline; }
}

/* ---------- 9. Адаптив ---------- */
@media (max-width: 1024px) {
  :root { --gutter: 32px; }
}

@media (max-width: 768px) {
  :root { --gutter: 16px; --header-h: 56px; }
  .header { grid-template-columns: 1fr auto; }
  .header__title { display: none; }
  .slide { padding: calc(var(--header-h) + 24px) 0 32px; }
  .slide__meta .tech { display: none; }

  /* обидва ока в кадрі; спалах — точно на очах */
  .cover__img { object-position: 57% 30%; }
  .cover__flare { height: 90vmin; left: 44%; top: 36%; width: 90vmin; }
  .cover__shade {
    background: linear-gradient(0deg, rgba(23, 21, 22, .9) 0%, rgba(23, 21, 22, .55) 40%, transparent 68%);
  }
  .cover__inner { justify-content: flex-end; }
  .cover__text { margin: 0; max-width: none; }
  .cover__hero { font-size: 30vw; margin-top: 14px; }
  .cover__title { font-size: clamp(17px, 5.5vw, 30px); margin-top: 22px; }
  .cover__sub { font-size: 11px; letter-spacing: .1em; }
  .cover__chip { margin-top: 20px; }
  .cover__foot { margin-top: 28px; }

  /* 03: ціль ($1M+) першою → компактний моноліт → два пункти.
     Контейнер і текстовий блок «розчиняються», щоб моноліт став між ними */
  .goal { flex-direction: column; padding-top: calc(var(--header-h) + 28px); }
  .goal > .goal__inner, .goal__text { display: contents; }
  .goal__meta { display: none; }
  .goal__chip, .goal__lead, .goal__hero, .goal__caption, .goal__body {
    margin-left: var(--gutter); margin-right: var(--gutter); position: relative; z-index: 1;
  }
  .goal__chip { align-self: flex-start; }
  .goal__lead { font-size: clamp(20px, 6vw, 30px); margin-top: 22px; }
  .goal__hero { font-size: 26vw; margin-top: 14px; }
  .goal__caption { font-size: 11px; gap: 12px; letter-spacing: .1em; margin-top: 18px; }
  .goal__caption-line { width: 32px; }
  .goal__stage { height: 40svh; margin: 4px 0 8px; order: 1; position: relative; top: auto; width: 100%; }
  .goal__glow { height: 60vh; width: 70vw; }
  .goal__body { margin-top: 0; order: 2; }
  .goal__point p { font-size: 15px; line-height: 1.6; }

  /* 04: заголовок і лід першими → сфера окремою смугою → два напрями й картки */
  .sys { flex-direction: column; padding-top: calc(var(--header-h) + 28px); }
  .sys > .sys__inner { display: contents; }
  .sys__meta { display: none; }
  .sys__title, .sys__lead, .sys__bottom {
    margin-left: var(--gutter); margin-right: var(--gutter); position: relative; z-index: 1;
  }
  .sys__lead { font-size: 15px; }
  .sys__stage { height: 44svh; inset: auto; margin: 16px 0 0; order: 1; position: relative; }
  .sys__glow { height: 80vw; left: 50%; top: 50%; width: 80vw; }
  .sys__bottom { margin-top: 0; order: 2; padding-top: 8px; }
  .sys__split b { white-space: nowrap; }
  .sys__title { font-size: 7.1vw; width: auto; }
  .sys__bottom { width: auto; }
  .sys__split { align-items: flex-start; font-size: 11px; letter-spacing: .1em; }
  .sys__split-line { margin-top: .7em; width: 28px; }
  .sys__tabs { display: none; }
  .sys__deck { gap: 16px; }
  .sys__card { grid-area: auto; padding: 20px; }
  .sys__card { grid-template-columns: minmax(0, 1fr); }
  .sys__h { font-size: 3.8vw; grid-row: 2; }
  .sys__idx { font-size: 44px; grid-column: 1; justify-self: end; margin: 0 0 -10px; }
}

@media (min-width: 769px) and (max-width: 1100px) {
  .goal__stage { width: 42%; }
  .goal__text { margin-left: 42%; }
}

/* Телефон у ландшафті (низький екран + тач): плашка «поверніть телефон» поверх сторінки */
.rotate { display: none; }
@media (orientation: landscape) and (max-height: 500px) and (pointer: coarse) {
  .rotate {
    align-items: center;
    background: var(--devils-black);
    color: var(--devils-white);
    display: flex;
    flex-direction: column;
    gap: 20px;
    inset: 0;
    justify-content: center;
    position: fixed;
    z-index: 100;
  }
  .rotate__icon {
    animation: rotate-hint 2.4s var(--ease) infinite;
    border: 2px solid var(--devils-red);
    border-radius: 8px;
    box-shadow: 0 0 18px rgba(233, 0, 0, .5);
    height: 64px;
    width: 38px;
  }
  .rotate__text { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; }
  body { overflow: hidden; }
}
@keyframes rotate-hint { 0%, 30% { transform: rotate(-90deg); } 60%, 100% { transform: rotate(0); } }

/* ---------- 10. Страховка: якщо JS-анімація не стартувала — показати все ---------- */
.js .cover__inner { animation: failsafe-show 0s 2.5s forwards; visibility: hidden; }
.js.is-ready .cover__inner { animation: none; visibility: visible; }
@keyframes failsafe-show { to { visibility: visible; } }

@media (prefers-reduced-motion: reduce) {
  body { transition: none; }
}
