/* ---- 00-tokens.css ---- */
/* ==========================================================================
   Kursy Elektrykiv — stylesheet (generated from tools/styles/*.css by tools/build.py)
   00 · Fonts and design tokens.
   Palette: neutral graphite + electric blue (current) + warm LED light. Logo colours: blue hexagon, yellow bolt.
   Components only use semantic tokens (--bg, --fg, --accent ...). Sections are "base" (dark) or "alt" (light).
   ========================================================================== */

@font-face {
  font-family: "Fixel";
  src: url("../fonts/fixel-variable.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 87.5% 100%;
  font-display: swap;
}

:root {
  --font: "Fixel", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --text-stretch: 87.5%;   /* Fixel Text */
  --display-stretch: 100%; /* Fixel Display */

  --container: 1240px;
  --gutter: clamp(16px, 4vw, 40px);
  --section-y: clamp(72px, 9vw, 130px);
  --header-h: 80px;
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-spring: cubic-bezier(.34, 1.56, .64, 1);

  /* wire colour code (IEC 60446) */
  --wire-l: #7b4a26;
  --wire-n: #2160b8;

  /* base (dark) */
  --base-bg: #101114;
  --base-surface: #18191d;
  --base-surface-2: #141518;
  --base-fg: #edeef0;
  --base-muted: #9a9ea7;
  --base-line: rgba(237, 238, 240, .1);
  --base-line-strong: rgba(237, 238, 240, .22);
  --base-accent-text: #82a0ff;

  /* alt (light) */
  --alt-bg: #eeede9;
  --alt-surface: #f9f8f5;
  --alt-surface-2: #e6e4df;
  --alt-fg: #141518;
  --alt-muted: #585b62;
  --alt-line: rgba(20, 21, 24, .12);
  --alt-line-strong: rgba(20, 21, 24, .24);
  --alt-accent-text: #2449d8;

  /* electric blue: buttons and interactive accents */
  --accent: #2f5df0;
  --accent-hi: #4570ff;
  --accent-ink: #ffffff;
  --accent-soft: rgba(60, 108, 255, .14);
  --accent-glow: rgba(60, 108, 255, .45);

  /* LED light: the strip, lamps, lit states */
  --led: #ffe29a;
  --led-core: #fff7e0;
  --led-glow: rgba(255, 214, 120, .5);
  --led-off: #2b2c31;
  --led-off-alt: #cdcac2;

  --mark-stroke: #6e8dff;
  --mark-bolt: #ffd23f;

  --radius: 18px;
  --radius-sm: 12px;
  --radius-btn: 12px;
  --radius-photo: 22px;
  --h-weight: 500;
  --h-tracking: -.03em;

  --header-scrolled: rgba(16, 17, 20, .84);

  /* switchboard */
  --encl: #1b1c20;
  --encl-stroke: rgba(237, 238, 240, .14);
  --plate: #24252a;
  --flow: #ffe29a;
  --nameplate: #121316;
  --nameplate-ink: #6e8dff;

  --footer-bg: #0b0c0e;
  color-scheme: dark;

  /* semantic tokens (base by default) */
  --bg: var(--base-bg);
  --surface: var(--base-surface);
  --surface-2: var(--base-surface-2);
  --fg: var(--base-fg);
  --muted: var(--base-muted);
  --line: var(--base-line);
  --line-strong: var(--base-line-strong);
  --accent-text: var(--base-accent-text);
  --led-track: var(--led-off);
}
.section--alt {
  --bg: var(--alt-bg);
  --surface: var(--alt-surface);
  --surface-2: var(--alt-surface-2);
  --fg: var(--alt-fg);
  --muted: var(--alt-muted);
  --line: var(--alt-line);
  --line-strong: var(--alt-line-strong);
  --accent-text: var(--alt-accent-text);
  --led-track: var(--led-off-alt);
  color-scheme: light;
}

/* ---- 01-base.css ---- */
/* 01 · Reset, typography, layout primitives, buttons, cards, icons */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0;
  background: var(--base-bg);
  color: var(--base-fg);
  font-family: var(--font);
  font-stretch: var(--text-stretch);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg, video, iframe { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, h4, p, ul, ol, figure, dl, dd { margin: 0; }
:where(ul[role="list"], ol[role="list"]) { list-style: none; padding: 0; } /* zero specificity: component padding wins */
strong, b { font-weight: 650; color: var(--fg); }
::selection { background: var(--accent); color: var(--accent-ink); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 200;
  background: var(--accent); color: var(--accent-ink); padding: 10px 16px; border-radius: var(--radius-sm); font-weight: 600;
  transition: top .2s;
}
.skip-link:focus { top: 12px; }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.icon { width: 1.3em; height: 1.3em; flex: none; }

/* ---------- Layout ---------- */
.container { width: min(100% - 2 * var(--gutter), var(--container)); margin-inline: auto; }
.section { position: relative; padding-block: var(--section-y); background: var(--bg); color: var(--fg); }
.section--tint { --bg: var(--surface-2); }

/* ---------- Typography ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  font-weight: 600; font-size: 13px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--accent-text);
}
.eyebrow::before { content: ""; width: 28px; height: 2px; background: currentColor; }
.h1, .h2, .h3 {
  font-stretch: var(--display-stretch); font-weight: var(--h-weight); letter-spacing: var(--h-tracking);
  line-height: 1.04; text-wrap: balance; color: var(--fg);
}
.h1 { font-size: clamp(36px, 4.4vw, 62px); }
.h2 { font-size: clamp(30px, 3.9vw, 54px); }
.h3 { font-size: clamp(19px, 1.7vw, 23px); line-height: 1.25; letter-spacing: -.015em; }
.accent { color: var(--accent-text); }
.lead { font-size: clamp(17px, 1.4vw, 20px); color: var(--muted); max-width: 60ch; }
.section-head { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; margin-bottom: clamp(36px, 5vw, 64px); max-width: 860px; }

/* ---------- Buttons ---------- */
.btn {
  position: relative; isolation: isolate; overflow: hidden;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 54px; padding: 0 28px; border-radius: var(--radius-btn);
  background: transparent; color: var(--fg); border: 1px solid var(--line-strong);
  font-weight: 600; font-size: 16px; letter-spacing: .005em; white-space: nowrap;
  transition: transform .25s var(--ease-out), box-shadow .3s, background-color .25s, border-color .25s, color .25s;
}
.btn .icon { width: 20px; height: 20px; transition: transform .3s var(--ease-out); }
.btn:hover .icon--move { transform: translateX(4px); }
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn--primary:hover { background: var(--accent-hi); border-color: var(--accent-hi); box-shadow: 0 12px 34px -12px var(--accent-glow); }
.btn--ghost:hover { border-color: var(--fg); }
.btn--sm { min-height: 46px; padding: 0 20px; font-size: 15px; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Cards ---------- */
.card {
  position: relative; isolation: isolate; overflow: hidden;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: clamp(22px, 2.4vw, 32px);
  transition: border-color .3s, transform .4s var(--ease-out), box-shadow .4s;
}
.card::before {
  content: ""; position: absolute; inset: 0; z-index: -1; opacity: 0; transition: opacity .3s; border-radius: inherit;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), var(--accent-soft), transparent 50%);
}
.card:hover { border-color: var(--line-strong); }
.card:hover::before { opacity: 1; }
a.card:hover { transform: translateY(-2px); }

.icon-tile {
  display: grid; place-items: center; width: 56px; height: 56px; border-radius: var(--radius-sm); flex: none;
  background: var(--accent-soft); color: var(--accent-text);
}
.icon-tile .icon { width: 28px; height: 28px; }

/* ---- 02-header-footer.css ---- */
/* 02 · Header, mobile menu, footer, sticky mobile CTA, theme switcher (preview builds) */

/* Logo symbol: colours come from theme tokens */
.brand { display: inline-flex; align-items: center; gap: 14px; flex: none; }
.brand__mark { width: 58px; height: 58px; transition: transform .5s var(--ease-spring); }
.brand__mark .m-stroke { stroke: var(--mark-stroke); }
.brand__mark .m-bolt { fill: var(--mark-bolt); }
.brand:hover .brand__mark { transform: rotate(-8deg) scale(1.04); }
/* tagline next to the header logo (the same words as in the footer) */
.brand__text {
  font-weight: 600; font-size: 12px; line-height: 1.4; letter-spacing: .11em; text-transform: uppercase;
  color: var(--base-fg); white-space: nowrap;
}
.brand__text > span { display: block; }

.site-header {
  position: fixed; inset: 0 0 auto; z-index: 100; height: var(--header-h);
  color: var(--base-fg);
  transition: background-color .35s, border-color .35s, height .35s;
  border-bottom: 1px solid transparent;
}
.site-header.is-scrolled {
  background: var(--header-scrolled);
  -webkit-backdrop-filter: blur(16px) saturate(140%); backdrop-filter: blur(16px) saturate(140%);
  border-color: var(--base-line);
}
.site-header__inner { height: 100%; display: flex; align-items: center; gap: 28px; }
.site-nav { margin-left: auto; }
.site-nav__list { display: flex; gap: 4px; }
.site-nav__link {
  position: relative; display: inline-flex; align-items: center; height: 44px; padding: 0 14px; border-radius: var(--radius-sm);
  font-weight: 500; font-size: 16px; white-space: nowrap; color: var(--base-muted); transition: color .2s;
}
.site-nav__link:hover { color: var(--base-fg); }
.site-nav__link[aria-current="page"], .site-nav__link.is-active { color: var(--base-fg); }
.site-nav__link.is-active::after, .site-nav__link[aria-current="page"]::after {
  content: ""; position: absolute; left: 14px; right: 14px; bottom: 6px; height: 2px; background: var(--accent);
}
.header-phone { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: 16px; white-space: nowrap; transition: color .2s; }
.header-phone:hover { color: var(--base-accent-text); }
.header-phone .icon { width: 20px; height: 20px; color: var(--base-accent-text); }
.burger { display: none; width: 48px; height: 48px; border-radius: var(--radius-sm); border: 1px solid var(--base-line-strong); align-items: center; justify-content: center; }
.burger .icon { width: 24px; height: 24px; }
.burger--close { display: inline-flex; }

.mobile-menu {
  position: fixed; inset: 0; z-index: 150; display: grid; grid-template-rows: auto 1fr auto;
  background: var(--base-bg); color: var(--base-fg); padding: 0 var(--gutter) 28px;
  overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch;
  opacity: 0; visibility: hidden; transform: translateY(-8px);
  transition: opacity .3s, transform .4s var(--ease-out), visibility 0s .4s;
}
.mobile-menu.is-open { opacity: 1; visibility: visible; transform: none; transition: opacity .3s, transform .4s var(--ease-out); }
/* the top bar repeats the header exactly, so nothing moves when the menu opens */
.mobile-menu__top { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); }
.mobile-menu__list { align-self: center; display: grid; }
.mobile-menu__list a {
  display: flex; align-items: center; justify-content: space-between; padding: 18px 2px; border-bottom: 1px solid var(--base-line);
  font-stretch: var(--display-stretch); font-weight: 500; font-size: clamp(24px, 6.5vw, 32px); letter-spacing: -.02em;
}
.mobile-menu__list a .icon { width: 26px; height: 26px; color: var(--base-accent-text); }
.mobile-menu__foot { display: grid; gap: 12px; }
.mobile-menu__foot .btn { width: 100%; }

/* ---------- Footer ---------- */
.site-footer {
  --bg: var(--footer-bg); --fg: #ece9e3; --muted: rgba(236, 233, 227, .7); --line: rgba(255, 255, 255, .1); --line-strong: rgba(255, 255, 255, .22);
  --accent-text: var(--alt-accent-text);
  background: var(--bg); color: var(--muted); padding: clamp(56px, 7vw, 88px) 0 32px;
}
.site-footer .brand__mark .m-stroke { stroke: #ece9e3; }
.footer-grid { display: grid; grid-template-columns: auto auto auto; justify-content: start; gap: 48px clamp(48px, 8vw, 120px); }
.footer-brand { display: grid; gap: 22px; align-content: start; }
.footer-brand .brand__mark { width: 64px; height: 64px; }
.footer-tagline {
  font-weight: 500; font-size: 13px; line-height: 1.45; letter-spacing: .12em; text-transform: uppercase; color: var(--fg); white-space: nowrap;
}
.footer-tagline > span { display: block; }
.footer-brand p { max-width: 40ch; font-size: 15px; line-height: 1.6; }
.footer-brand p a { color: var(--fg); text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px; transition: color .2s; }
.footer-brand p a:hover { color: var(--accent-text); }
.footer-title { font-weight: 600; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--fg); margin-bottom: 18px; }
.footer-links { display: grid; gap: 12px; font-size: 16px; }
.footer-links a { display: inline-flex; align-items: center; gap: 12px; transition: color .2s; }
.footer-links a:hover { color: var(--fg); }
.footer-links .icon { width: 22px; height: 22px; }
.footer-bottom { margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--line); font-size: 14px; }
.footer-bottom .container { display: flex; flex-wrap: wrap; gap: 12px 24px; justify-content: space-between; }
.footer-bottom a:hover { color: var(--fg); }

/* ---------- Mobile sticky CTA ---------- */
.sticky-cta { display: none; }


@media (max-width: 1320px) {
  .site-header__inner { gap: 20px; }
  .site-nav__link { padding: 0 10px; font-size: 15px; }
  .site-nav__link.is-active::after, .site-nav__link[aria-current="page"]::after { left: 10px; right: 10px; }
}
@media (max-width: 1180px) {
  .header-phone span { display: none; }
}
@media (max-width: 1024px) {
  :root { --header-h: 70px; }
  .site-nav, .header-phone, .site-header__cta { display: none; }
  .burger { display: inline-flex; margin-left: auto; }
  .footer-grid { grid-template-columns: auto auto; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  .brand__mark { width: 50px; height: 50px; }
  .footer-grid { grid-template-columns: 1fr; }
  .sticky-cta {
    position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 90; display: grid; grid-template-columns: 1fr auto auto; gap: 8px;
    padding: 8px; border-radius: calc(var(--radius) + 6px); background: var(--header-scrolled); border: 1px solid var(--base-line-strong);
    -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
    transform: translateY(140%); transition: transform .45s var(--ease-out);
  }
  .sticky-cta.is-visible { transform: none; }
  .sticky-cta .btn { min-height: 50px; }
  .sticky-cta .contact-ico { width: 50px; height: 50px; }
  .site-footer { padding-bottom: 104px; }
}
.footer-brand__head { display: flex; align-items: center; gap: 18px; }

/* ---------- Back to top ---------- */
.to-top {
  position: fixed; right: 20px; bottom: 20px; z-index: 95; display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%;
  background: var(--accent); color: var(--accent-ink); box-shadow: 0 10px 30px -8px var(--accent-glow);
  opacity: 0; visibility: hidden; transform: translateY(12px); transition: opacity .3s, transform .4s var(--ease-out), visibility 0s .4s, background-color .2s;
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; transition: opacity .3s, transform .4s var(--ease-out), background-color .2s; }
.to-top:hover { background: var(--accent-hi); }
.to-top .icon { width: 24px; height: 24px; }
@media (max-width: 720px) { .to-top { right: 14px; bottom: 84px; width: 46px; height: 46px; } }

/* ---- 03-hero.css ---- */
/* 03 · Hero (home) */

.hero {
  position: relative; overflow: hidden; isolation: isolate; background: var(--bg);
  padding: calc(var(--header-h) + clamp(24px, 3.5vw, 48px)) 0 clamp(40px, 5vw, 72px);
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -2; pointer-events: none;
  background: radial-gradient(40% 50% at 78% 38%, rgba(60, 108, 255, .14), transparent 70%);
}

.hero__grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero__content { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; justify-items: start; }
.chip {
  display: inline-flex; align-items: center; gap: 10px; padding: 7px 14px 7px 7px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--line); font-size: 14px; font-weight: 500;
}
.chip__badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px; border-radius: 999px;
  background: var(--accent); color: var(--accent-ink); font-weight: 600; font-size: 12px; letter-spacing: .08em; text-transform: uppercase;
}
.chip__badge .icon { width: 16px; height: 16px; }
.chip__icon { width: 20px; height: 20px; color: var(--accent-text); margin-right: -2px; }
.chip, .chip__badge { white-space: nowrap; }
@media (max-width: 480px) {
  .chip { gap: 8px; padding-right: 12px; font-size: 13px; }
  .chip__badge { padding: 5px 9px; font-size: 11px; letter-spacing: .06em; }
  .chip__icon { width: 18px; height: 18px; }
}
@media (max-width: 374px) { .chip { flex-wrap: wrap; row-gap: 8px; border-radius: 20px; } }
.hero__title { display: grid; gap: 6px; }
.hero__kicker { font-weight: 500; font-size: clamp(14px, 1.2vw, 16px); letter-spacing: .16em; text-transform: uppercase; color: var(--accent-text); margin-bottom: 8px; }
.hero__title .line { display: block; overflow: hidden; padding-bottom: .08em; }
.hero__title .line > span { display: inline-block; }
.hero__title em { font-style: normal; color: var(--accent-text); }
.hero__tagline { display: flex; flex-wrap: wrap; gap: 8px 20px; color: var(--muted); font-weight: 500; font-size: clamp(16px, 1.35vw, 19px); }
.hero__tagline li { display: inline-flex; align-items: center; gap: 8px; }
.hero__tagline .icon { color: var(--led); width: 20px; height: 20px; }

/* teacher credential: a proof line under the tagline (kept off the photo) */
.credential {
  display: flex; align-items: center; gap: 14px; max-width: 520px; padding: 12px 18px 12px 12px; border-radius: var(--radius-sm);
  background: var(--surface); border: 1px solid var(--line); font-weight: 500; font-size: 15px; line-height: 1.4; color: var(--fg);
}
.credential .icon-tile { width: 44px; height: 44px; background: var(--accent); color: var(--accent-ink); }
.credential .icon-tile .icon { width: 22px; height: 22px; }

.hero__visual { position: relative; }
.photo-frame { position: relative; border-radius: var(--radius-photo); overflow: hidden; aspect-ratio: 4 / 3.7; background: var(--surface-2); }
.photo-frame img { width: 100%; height: 100%; object-fit: cover; }
.photo-frame img.obj-hero { object-position: 82% 50%; } /* keeps the teacher, the student and the stand in frame */

/* ---------- Stat band: the four key numbers; lights up when the LED strip docks into it ---------- */
.statband {
  position: relative; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: clamp(28px, 3.2vw, 44px);
  border-top: 1px solid var(--line-strong); border-bottom: 1px solid var(--line-strong);
}
.statband__item { container-type: inline-size; position: relative; display: flex; align-items: center; gap: 16px; padding: 24px 18px 24px 0; min-width: 0; }
.statband__item + .statband__item { padding-left: 22px; border-left: 1px solid var(--line); }
.statband__item .icon-tile {
  width: 68px; height: 68px; border-radius: 50%; flex: none; border: 2px solid var(--line-strong);
  transition: background-color .4s, color .4s, border-color .4s, box-shadow .4s; transition-delay: var(--led-delay, 0s);
}
.statband__item .icon-tile .icon { width: 32px; height: 32px; }
.statband__num {
  font-stretch: var(--display-stretch); font-weight: var(--h-weight); line-height: .95; letter-spacing: -.035em; color: var(--fg);
  font-size: min(56px, 17cqi); white-space: nowrap; transition: color .4s, text-shadow .4s; transition-delay: var(--led-delay, 0s);
}
.statband__num small { font-size: .42em; letter-spacing: 0; font-weight: 500; color: var(--muted); }
.statband__num, .statband__label { display: block; }
.statband__label { margin-top: 6px; font-size: 15px; color: var(--muted); font-weight: 500; }
.statband::after { /* LED edge; -3px sits on the 1px border. It starts at the strip itself (under the lamp bead),
                       so the branch and the edge are one line with no joint */
  content: ""; position: absolute; left: calc(-1 * var(--branch)); right: 0; top: -3px; height: 4px; pointer-events: none;
  background: linear-gradient(90deg, var(--led), var(--led-core), var(--led)); box-shadow: 0 0 12px var(--led-glow);
  transform: scaleX(0); transform-origin: left; transition: transform .9s var(--ease-out);
}
.statband.is-lit::after { transform: scaleX(1); }
.statband.is-lit .icon-tile { background: rgba(255, 214, 120, .12); color: var(--led); border-color: var(--led); box-shadow: 0 0 16px rgba(255, 214, 120, .25); }
.statband.is-lit .statband__num { color: var(--led); text-shadow: 0 0 18px rgba(255, 214, 120, .35); }
/* rolling digits, like the drums of an electricity meter (built by main.js) */
.statband__num { font-variant-numeric: tabular-nums; }
.odo { display: inline-flex; vertical-align: top; }
.odo { transition: filter .4s; transition-delay: var(--led-delay, 0s); }
.odo__d { display: inline-block; height: 1em; text-shadow: none; -webkit-mask: linear-gradient(transparent, #000 12%, #000 88%, transparent); mask: linear-gradient(transparent, #000 12%, #000 88%, transparent); }
/* the glow sits on the whole number, so the digit windows do not cut it into boxes */
.statband.is-lit .odo { filter: drop-shadow(0 0 9px rgba(255, 214, 120, .4)); }
.odo__s { display: block; transition: transform var(--odo-dur, 1.6s) cubic-bezier(.2, .7, .2, 1) var(--odo-delay, 0s); }
.odo__s > span { display: block; height: 1em; line-height: 1em; }
.statband__item:nth-child(1) { --led-delay: .1s; }
.statband__item:nth-child(2) { --led-delay: .3s; }
.statband__item:nth-child(3) { --led-delay: .5s; }
.statband__item:nth-child(4) { --led-delay: .7s; }

@media (max-width: 1024px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__visual { max-width: 640px; width: 100%; }
  .photo-frame { aspect-ratio: 4 / 3.2; }
  .statband { grid-template-columns: 1fr 1fr; }
  .statband__item:nth-child(3) { padding-left: 0; border-left: 0; }
  .statband__item:nth-child(n + 3) { border-top: 1px solid var(--line); }
}
@media (max-width: 1024px) { .statband__num { font-size: min(52px, 19cqi); } }
@media (max-width: 520px) {
  .statband__item { flex-direction: column; align-items: flex-start; gap: 12px; padding: 20px 12px 20px 0; }
  .statband__item + .statband__item { padding-left: 14px; }
  .statband__item:nth-child(3) { padding-left: 0; }
  .statband__item .icon-tile { width: 50px; height: 50px; }
  .statband__item .icon-tile .icon { width: 24px; height: 24px; }
  .statband__num { font-size: min(44px, 26cqi); }
  .credential { font-size: 14px; }
}

/* ---- 04-sections.css ---- */
/* 04 · Content sections */

/* ---------- Two formats, styled as pricing cards ---------- */
.formats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.format { display: grid; grid-template-rows: auto auto 1fr auto; gap: 0; padding: 0; }
.format__head { display: flex; align-items: center; gap: 16px; padding: 28px 30px 0; }
.format__head .h3 { font-size: clamp(22px, 2vw, 28px); }
.format__price { padding: 22px 30px 24px; margin-top: 22px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--surface-2); }
.format__price-label { display: block; font-size: 13px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.format__price-value {
  display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px 10px;
  font-stretch: var(--display-stretch); font-weight: var(--h-weight); font-size: clamp(48px, 5vw, 76px); line-height: .9; letter-spacing: -.045em; color: var(--fg);
}
.format__price-value small { font-size: .36em; letter-spacing: -.01em; font-weight: 500; color: var(--muted); }
/* both key values (price, duration) are lit in LED colour once the card is reached */
.format__price-value { transition: color .5s .3s, text-shadow .5s .3s; }
.format.is-lit .format__price-value { color: var(--led); text-shadow: 0 0 28px rgba(255, 214, 120, .25); }
.format__list { display: grid; gap: 12px; padding: 24px 30px; align-content: start; }
.format__list li { display: grid; grid-template-columns: 26px 1fr; gap: 12px; align-items: start; font-size: 17px; line-height: 1.45; color: var(--fg); }
.tick-sm { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-text); margin-top: -1px; }
.tick-sm .icon { width: 15px; height: 15px; stroke-width: 2.8; }
.format__cta { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 0 30px 30px; }
.format__cta .btn { width: 100%; padding: 0 16px; }

/* ---------- Особливості курсу: an LED line enters each icon, the circle fills, the line runs on ---------- */
.features { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; --rail-y: 70px; --pad: clamp(22px, 2.4vw, 32px); --step: .8s; }
.feature { display: grid; grid-template-columns: minmax(0, 1fr); gap: 22px; align-content: start; padding-top: 32px; overflow: visible; --i: 0; }
.feature .icon-tile {
  position: relative; z-index: 1; width: 76px; height: 76px; border-radius: 50%;
  background: var(--surface); border: 2px solid var(--line-strong); color: var(--fg);
  transition: background-color .3s, color .3s, border-color .3s, box-shadow .3s; transition-delay: calc(var(--i) * var(--step) + .28s);
}
.feature .icon-tile .icon { width: 36px; height: 36px; }
.feature__title { font-weight: 600; font-size: 18px; line-height: 1.4; color: var(--fg); }
.feature__note { display: block; margin-top: 6px; font-weight: 400; font-size: 15px; color: var(--muted); }
.led-rail { position: absolute; top: calc(var(--rail-y) - 2px); height: 4px; background: var(--led-track); z-index: 0; pointer-events: none; }
.led-rail::after {
  content: ""; position: absolute; inset: 0; background: var(--led-lit); box-shadow: 0 0 10px var(--led-glow);
  transform: scaleX(0); transform-origin: left; transition: transform .28s linear;
}
.led-rail--in { left: -18px; width: calc(18px + var(--pad)); }
.led-rail--out { left: calc(var(--pad) + 76px); right: 0; }
.led-rail--in::after { transition-delay: calc(var(--i) * var(--step)); }
.led-rail--out::after { transition-delay: calc(var(--i) * var(--step) + .5s); }
.feature.is-lit .led-rail::after { transform: scaleX(1); }
.feature.is-lit .icon-tile { background: var(--led); border-color: var(--led); color: #3d2c00; box-shadow: 0 0 0 6px rgba(255, 214, 120, .1), 0 0 24px rgba(255, 214, 120, .45); }
/* 4 columns: first card connects to the strip, last card ends at its icon */
.features > .feature:nth-child(4n + 1) { --i: 0; }
.features > .feature:nth-child(4n + 2) { --i: 1; }
.features > .feature:nth-child(4n + 3) { --i: 2; }
.features > .feature:nth-child(4n + 4) { --i: 3; }
.features > .feature:nth-child(4n + 1) .led-rail--in { left: calc(-1 * var(--branch) - 1px); width: calc(var(--branch) + 1px + var(--pad)); }
.features > .feature:nth-child(4n) .led-rail--out { display: none; }
.hl { color: var(--accent-text); font-weight: 600; }
.pill-list { display: flex; flex-wrap: wrap; gap: 10px; }
.pill { display: inline-flex; align-items: center; gap: 10px; padding: 10px 16px; border-radius: 999px; border: 1px solid var(--line-strong); font-size: 15px; font-weight: 500; color: var(--fg); }
.pill .icon { width: 22px; height: 22px; color: var(--accent-text); }

/* ---------- Чому унікальний: big proof numbers + statements on an LED line ---------- */
.why { display: grid; grid-template-columns: minmax(0, .62fr) minmax(0, 1.38fr); gap: clamp(32px, 4.5vw, 64px); align-items: start; }
.why__aside { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; }
.why__proof { display: grid; gap: 8px; margin-top: 18px; }
.why__proof div { container-type: inline-size; padding: 12px 0; }
.why__proof b { display: block; font-stretch: var(--display-stretch); font-weight: var(--h-weight); font-size: min(96px, 34cqi); line-height: .9; letter-spacing: -.05em; color: var(--accent-text); }
.why__proof > div > span { display: block; margin-top: 8px; font-size: 16px; font-weight: 500; color: var(--muted); }
.why__list { position: relative; display: grid; gap: 0; }
.why__row { position: relative; display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 22px; padding: 26px 0 30px; }
.why__row::before { /* LED line linking the lamps */
  content: ""; position: absolute; left: 30px; top: 92px; bottom: -26px; width: 4px; border-radius: 2px; background: var(--led-track);
}
.why__row:last-child::before { display: none; }
.why__row::after {
  content: ""; position: absolute; left: 30px; top: 92px; bottom: -26px; width: 4px; border-radius: 2px; background: var(--led-lit);
  box-shadow: 0 0 8px rgba(240, 173, 44, .6); transform: scaleY(0); transform-origin: top; transition: transform .7s var(--ease-out);
}
.why__row:last-child::after { display: none; }
.why__row.is-lit::after { transform: scaleY(1); }
.why__row .icon-tile { width: 64px; height: 64px; border-radius: 50%; background: #e2ded5; color: #3a3d44; border: 2px solid #b4ada0; transition: background-color .4s, color .4s, border-color .4s, box-shadow .4s; }
.why__row.is-lit .icon-tile { background: #ffd879; color: #5a3d00; border-color: #d08f12; box-shadow: 0 0 18px rgba(240, 173, 44, .45); }
.why__row .icon-tile .icon { width: 30px; height: 30px; }
.why__row p { font-size: clamp(17px, 1.45vw, 20px); line-height: 1.6; color: var(--muted); padding-top: 14px; }
.why__row strong { color: var(--fg); font-weight: 600; }

/* ---------- Приклад лекцій ---------- */
.videos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.video { display: grid; gap: 16px; }
.video__frame { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; background: #000; }
.video__frame img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease-out), opacity .3s; opacity: .9; }
.video__frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video__play { position: absolute; inset: 0; display: grid; place-items: center; width: 100%; background: linear-gradient(180deg, transparent 40%, rgba(0, 0, 0, .55)); }
.video__play-btn {
  display: grid; place-items: center; width: 84px; height: 84px; border-radius: 50%;
  background: var(--accent); color: var(--accent-ink); box-shadow: 0 0 0 10px rgba(60, 108, 255, .22);
  transition: transform .4s var(--ease-spring);
}
.video__play-btn .icon { width: 32px; height: 32px; margin-left: 4px; fill: currentColor; }
.video__frame:hover img { transform: scale(1.03); opacity: 1; }
.video__frame:hover .video__play-btn { transform: scale(1.08); }
.video__title { display: flex; align-items: center; gap: 12px; font-weight: 600; font-size: 19px; }
.video__title .icon { color: #ff0000; width: 28px; height: 28px; }

/* ---------- Практичний курс: banner ---------- */
.practice-hero { position: relative; overflow: hidden; isolation: isolate; background: var(--base-bg); color: var(--base-fg); padding: clamp(80px, 11vw, 160px) 0; }
.practice-hero__bg { position: absolute; inset: 0; z-index: -2; }
.practice-hero__bg img { width: 100%; height: 100%; object-fit: cover; }
.practice-hero__bg::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, var(--base-bg) 22%, rgba(16, 17, 20, .72) 55%, rgba(16, 17, 20, .25));
}
.practice-hero__content { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; max-width: 720px; justify-items: start; }
.practice-hero .h1 { font-size: clamp(34px, 4.6vw, 64px); }
.practice-hero .h1 em { font-style: normal; color: var(--base-accent-text); }
.duo { display: flex; align-items: flex-end; flex-wrap: wrap; gap: 10px 24px; margin: 8px 0 4px; }
.duo__item { display: grid; gap: 10px; justify-items: start; }
/* LED display: seven-segment digits light up when the strip reaches the section */
.duo__display {
  display: block; padding: clamp(12px, 1.4vw, 18px) clamp(14px, 1.6vw, 22px); border-radius: 16px;
  background: rgba(8, 9, 11, .62); border: 1px solid rgba(255, 255, 255, .12);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .5), inset 0 10px 30px rgba(0, 0, 0, .35);
}
.seg { display: block; height: clamp(76px, 8.4vw, 118px); width: auto; overflow: visible; }
.seg polygon { fill: rgba(255, 255, 255, .07); transition: fill .12s; }
.seg polygon.on { fill: var(--led); }
.seg { filter: drop-shadow(0 0 7px rgba(255, 214, 120, .55)); }
.duo__label { font-stretch: var(--display-stretch); font-weight: 500; font-size: clamp(20px, 2vw, 28px); letter-spacing: -.01em; color: var(--base-fg); }
.practice-hero__cta { margin-top: 14px; min-height: 60px; padding: 0 34px; font-size: 17px; }
@media (max-width: 480px) { .practice-hero__cta { width: 100%; padding: 12px 20px; white-space: normal; text-align: center; } }
.duo__by { padding-bottom: calc(clamp(20px, 2vw, 28px) * 1.2 + 10px + clamp(12px, 1.4vw, 18px) + 30px); font-stretch: var(--display-stretch); font-weight: 500; font-size: clamp(20px, 2vw, 28px); color: var(--base-muted); }
.fact { display: flex; gap: 16px; align-items: center; font-weight: 600; font-size: 17px; color: var(--fg); }
.fact small { display: block; font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
a.fact:hover span:last-child { color: var(--accent-text); }

/* ---------- Програма практичного курсу: LED stepper (left -> right) with line illustrations ---------- */
.stepper { display: grid; gap: 28px; margin-bottom: clamp(32px, 4vw, 56px); }
.stepper__rail { position: relative; }
.stepper__rail { --art-r: 66px; }
.stepper__feed, .stepper__track, .stepper__led { position: absolute; top: calc(var(--art-r) - 2px); height: 4px; }
.stepper__track, .stepper__led { left: calc(100% / 6); right: calc(100% / 6); border-radius: 2px; }
/* the feed is a branch of the page LED strip: it runs into the first circle */
.stepper__feed { left: calc(-1 * var(--branch) - 1px); width: calc(100% / 6 - var(--art-r) + var(--branch) + 1px); background: var(--led-track); }
.stepper__feed::after {
  content: ""; position: absolute; inset: 0; background: var(--led-lit); box-shadow: 0 0 10px rgba(240, 173, 44, .6);
  transform: scaleX(0); transform-origin: left; transition: transform .4s linear;
}
.stepper__track { background: var(--led-track); }
.stepper__led { background: var(--led-lit); box-shadow: 0 0 10px rgba(240, 173, 44, .6); transform: scaleX(0); transform-origin: left; transition: transform 1.6s linear .5s; }
.stepper.is-lit .stepper__feed::after, .stepper.is-lit .stepper__led { transform: scaleX(1); }
.stepper__nodes { position: relative; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.stepper__node { display: grid; justify-items: center; gap: 10px; padding: 0 8px 6px; text-align: center; border-radius: var(--radius-sm); }
.stepper__art {
  position: relative; display: grid; place-items: center; width: calc(2 * var(--art-r)); height: calc(2 * var(--art-r)); border-radius: 50%;
  background: var(--surface); border: 2px solid #b4ada0; transition: border-color .4s, box-shadow .4s; transition-delay: var(--led-delay, 0s);
}
.stepper__art svg { width: 96px; height: 96px; overflow: visible; }
.ill-base { fill: none; stroke: #8f897c; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.ill-live { fill: none; stroke: #e19a12; stroke-width: 3.4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1 1; stroke-dashoffset: 1;
  transition: stroke-dashoffset 1s ease; transition-delay: calc(var(--led-delay, 0s) + .1s); }
.ill-flow { fill: none; stroke: #fff2c4; stroke-width: 2; stroke-linecap: round; stroke-dasharray: .03 .09; opacity: 0; transition: opacity .4s; transition-delay: calc(var(--led-delay, 0s) + 1.1s); }
.stepper.is-lit .ill-live { stroke-dashoffset: 0; }
.stepper.is-lit .ill-flow { opacity: 1; animation: ill-flow 1.4s linear infinite; }
@keyframes ill-flow { to { stroke-dashoffset: -.24; } }
.stepper.is-lit .stepper__art { border-color: #d08f12; box-shadow: 0 0 0 6px rgba(240, 173, 44, .14), 0 0 26px rgba(240, 173, 44, .35); }
/* timing follows the current: feed (0-.4s) -> node 1 -> track (.5-2.1s) reaches node 2 at 1.3s and node 3 at 2.1s */
.stepper__node:nth-child(1) { --led-delay: .4s; }
.stepper__node:nth-child(2) { --led-delay: 1.3s; }
.stepper__node:nth-child(3) { --led-delay: 2.1s; }
.stepper__label { font-stretch: var(--display-stretch); font-weight: var(--h-weight); font-size: clamp(20px, 1.9vw, 26px); letter-spacing: -.02em; color: var(--fg); }
.stepper__meta { display: inline-flex; align-items: center; padding: 4px 14px; border-radius: 999px; background: var(--accent); color: var(--accent-ink); font-size: 15px; font-weight: 600; letter-spacing: .01em; }
.stepper__node[aria-selected="true"] .stepper__label { color: var(--accent-text); }
.stepper__node[aria-selected="true"] .stepper__art { outline: 3px solid var(--accent); outline-offset: 6px; }
.stepper__node:hover .stepper__label { color: var(--accent-text); }
.stepper__panel { padding: clamp(24px, 3vw, 40px); }
.stepper__panel[hidden] { display: none; }
.work__list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 56px; }
.work__list li {
  position: relative; padding: 18px 0 18px 42px; border-top: 1px solid var(--line);
  font-size: clamp(16.5px, 1.25vw, 18px); font-weight: 400; line-height: 1.6; color: var(--fg);
}
.work__list li:nth-child(-n + 2) { border-top: 0; padding-top: 4px; }
.work__list li:nth-child(-n + 2)::before { top: calc(4px + (1.6em - 28px) / 2); }
/* bullets: the blue bolt from the logo */
.work__list li::before {
  content: ""; position: absolute; left: 4px; top: calc(18px + (1.6em - 28px) / 2); width: 18px; height: 28px; background: var(--accent);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 40'%3E%3Cpath d='M14 .5.5 23h9.6l-3.4 16.5L21.5 16.6h-9.8l4.3-16.1z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 40'%3E%3Cpath d='M14 .5.5 23h9.6l-3.4 16.5L21.5 16.6h-9.8l4.3-16.1z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.schemes { display: inline-flex; align-items: center; margin-left: 4px; padding: 1px 10px; border-radius: 999px; background: var(--accent); color: var(--accent-ink); font-weight: 600; font-size: 13px; white-space: nowrap; }

/* ---------- Викладач ---------- */
.teacher { display: grid; grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr); gap: clamp(32px, 6vw, 88px); align-items: center; }
.teacher__photo .photo-frame { aspect-ratio: 4 / 5; transition: box-shadow .5s .3s; }
/* the strip feeds the photo card: its edge lights up */
#vykladach.is-powered .photo-frame { box-shadow: 0 0 0 2px var(--led), 0 0 36px rgba(255, 214, 120, .22); }
.teacher__plate {
  position: absolute; left: 16px; right: 16px; bottom: 16px; z-index: 2;
  display: flex; align-items: center; gap: 16px; padding: 16px 18px; border-radius: var(--radius-sm);
  background: rgba(24, 25, 29, .9); color: var(--base-fg); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.teacher__plate .icon-tile { width: 52px; height: 52px; background: var(--accent); color: var(--accent-ink); }
.teacher__plate small { display: block; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--base-muted); font-weight: 600; }
.teacher__plate b { display: block; font-stretch: var(--display-stretch); font-weight: var(--h-weight); font-size: 24px; line-height: 1.15; letter-spacing: -.02em; color: var(--base-fg); }
.teacher__name { font-stretch: var(--display-stretch); font-weight: var(--h-weight); font-size: clamp(30px, 3.6vw, 48px); line-height: 1.06; letter-spacing: var(--h-tracking); margin-top: 14px; }
.teacher__role { margin-top: 14px; font-size: 19px; font-weight: 600; color: var(--fg); }
.teacher__org { margin-top: 16px; display: flex; gap: 14px; align-items: center; color: var(--muted); font-size: 16px; line-height: 1.45; }
.teacher__list-title { margin: 32px 0 16px; font-weight: 600; font-size: 14px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.checklist { display: grid; gap: 14px; }
.checklist li { display: grid; grid-template-columns: 32px 1fr; gap: 14px; align-items: start; font-size: 17px; line-height: 1.45; color: var(--fg); }
.checklist .tick { display: grid; place-items: center; width: 32px; height: 32px; border-radius: var(--radius-sm); background: var(--accent); color: var(--accent-ink); }
.checklist .tick .icon { width: 18px; height: 18px; stroke-width: 2.6; }

/* ---------- Gallery + lightbox ---------- */
.gallery { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); grid-auto-rows: clamp(120px, 14vw, 190px); gap: 12px; }
.gallery__item { position: relative; overflow: hidden; border-radius: var(--radius-sm); grid-column: span 4; grid-row: span 2; background: var(--surface-2); }
.gallery__item:nth-child(5n + 1), .gallery__item:nth-child(5n + 2) { grid-column: span 6; }
.gallery--even .gallery__item, .gallery--even .gallery__item:nth-child(n) { grid-column: span 4; }
.gallery__item button { position: absolute; inset: 0; width: 100%; height: 100%; }
.gallery__item img { width: 100%; height: 100%; object-fit: cover; transition: transform .7s var(--ease-out); }
.gallery__item:hover img { transform: scale(1.04); }
.gallery-caption { margin-top: 18px; font-size: 14px; letter-spacing: .08em; text-transform: uppercase; font-weight: 600; color: var(--muted); }

.lightbox { padding: 0; border: 0; background: transparent; max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; }
.lightbox::backdrop { background: rgba(5, 5, 5, .92); }
.lightbox__inner { position: relative; width: 100%; height: 100%; display: grid; place-items: center; padding: 64px 72px; }
.lightbox img { max-width: 100%; max-height: calc(100vh - 128px); width: auto; border-radius: 8px; }
.lightbox__btn { position: absolute; display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; background: rgba(255, 255, 255, .1); color: #fff; transition: background-color .2s; }
.lightbox__btn:hover { background: rgba(255, 255, 255, .25); }
.lightbox__btn .icon { width: 24px; height: 24px; }
.lightbox__close { top: 16px; right: 16px; }
.lightbox__prev { left: 16px; top: 50%; transform: translateY(-50%) rotate(180deg); }
.lightbox__next { right: 16px; top: 50%; transform: translateY(-50%); }
.lightbox__count { position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%); font-weight: 600; font-size: 14px; color: rgba(255, 255, 255, .7); }

/* ---------- Запис (enrolment) ---------- */
.enroll__grid { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: clamp(32px, 5vw, 72px); align-items: start; }
.enroll__aside { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; }
.enroll__text { font-size: 18px; color: var(--muted); }
.enroll__text a { color: var(--fg); font-weight: 600; text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 4px; transition: color .2s, text-decoration-color .2s; }
.enroll__text a:hover { color: var(--accent-text); text-decoration-color: currentColor; }
.messengers { display: grid; gap: 10px; }
.messenger {
  display: flex; align-items: center; gap: 16px; padding: 14px 18px 14px 14px; border-radius: var(--radius-sm);
  background: var(--surface); border: 1px solid var(--line); font-weight: 600; font-size: 17px; color: var(--fg);
  transition: border-color .25s, background-color .25s, box-shadow .25s;
}
/* hover: the card fills with the brand blue instead of jumping */
.messenger:hover, .messenger:focus-visible { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 16%, var(--surface)); box-shadow: 0 12px 30px -16px var(--accent-glow); }
.messenger .go { transition: transform .3s var(--ease-out), color .25s; }
.messenger:hover .go, .messenger:focus-visible .go { color: var(--accent-text); transform: translate(2px, -2px); }
.messenger small { display: block; font-weight: 400; font-size: 14px; color: var(--muted); }
.messenger .go { margin-left: auto; width: 22px; height: 22px; color: var(--muted); }
.contact-ico { display: grid; place-items: center; width: 52px; height: 52px; border-radius: var(--radius-sm); color: #fff; flex: none; }
.contact-ico .icon { width: 26px; height: 26px; }
.c-telegram { background: #229ed9; }
.c-viber { background: #7360f2; }
.c-whatsapp { background: #1fa855; }
.c-phone { background: var(--accent); color: var(--accent-ink); }
.c-mail { background: #3b6fd9; }
.c-facebook { background: #1877f2; }

.form-card { border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); overflow: hidden; }
.tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 8px; border-bottom: 1px solid var(--line); }
.tab { min-height: 52px; border-radius: var(--radius-btn); font-weight: 600; font-size: 16px; color: var(--muted); display: inline-flex; align-items: center; justify-content: center; gap: 10px; transition: background-color .25s, color .25s; }
.tab .icon { width: 20px; height: 20px; }
.tab:hover { color: var(--fg); }
.tab[aria-selected="true"] { background: var(--accent); color: var(--accent-ink); }
.tabpanel[hidden] { display: none; }
.form-frame { position: relative; background: #fff; }
.form-frame iframe { width: 100%; height: 980px; border: 0; }
.tabpanel--practice .form-frame iframe { height: 1240px; }
.form-fallback { display: flex; flex-wrap: wrap; gap: 10px 20px; align-items: center; justify-content: space-between; padding: 16px 20px; border-top: 1px solid var(--line); font-size: 15px; color: var(--muted); }
.form-fallback a { color: var(--accent-text); font-weight: 600; display: inline-flex; gap: 6px; align-items: center; }
.form-fallback .icon { width: 18px; height: 18px; }

/* ---------- Контакти ---------- */
.contacts-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.contact-card { display: flex; align-items: center; gap: 16px; padding: 18px 20px 18px 18px; }
.contact-card__label { display: block; font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.contact-card__value { display: block; font-weight: 600; font-size: 17px; color: var(--fg); overflow-wrap: anywhere; }
.contact-card .contact-ico { transition: box-shadow .4s; transition-delay: calc(var(--led-delay, 0s) + .3s); }
.contact-card.is-lit .contact-ico { box-shadow: 0 0 0 3px var(--alt-surface), 0 0 0 5px #f0ad2c, 0 0 16px rgba(240, 173, 44, .45); }
.contacts-grid > li:nth-child(3n + 2) .contact-card { --led-delay: .25s; }
.contacts-grid > li:nth-child(3n + 3) .contact-card { --led-delay: .5s; }
.contact-card .go { margin-left: auto; width: 22px; height: 22px; color: var(--muted); transition: transform .3s var(--ease-out); }
.contact-card:hover .go { transform: translate(2px, -2px); color: var(--accent-text); }
/* same hover as the messengers: fill with the brand blue, no jump */
a.contact-card { transition: border-color .25s, background-color .25s, box-shadow .25s; }
a.contact-card:hover, a.contact-card:focus-visible { transform: none; border-color: var(--accent); background: color-mix(in srgb, var(--accent) 10%, var(--surface)); box-shadow: 0 12px 30px -18px var(--accent-glow); }
.address-card { margin: 12px 0 clamp(32px, 4vw, 48px); display: flex; flex-wrap: wrap; align-items: center; gap: 14px 24px; }
.address-card .contact-card__value { font-size: 19px; }
.address-card__org { flex-basis: 100%; font-size: 15px; color: var(--muted); }

/* ---------- Prose (privacy) and 404 ---------- */
.prose { max-width: 760px; font-size: 17px; color: var(--muted); }
.prose h2 { font-stretch: var(--display-stretch); font-weight: var(--h-weight); font-size: clamp(22px, 2.2vw, 28px); color: var(--fg); margin: 44px 0 14px; letter-spacing: -.02em; }
.prose p, .prose ul { margin: 0 0 14px; }
.prose ul { padding-left: 22px; }
.prose li { margin-bottom: 6px; }
.prose a { color: var(--accent-text); text-decoration: underline; text-underline-offset: 3px; }
.prose .meta { display: flex; flex-wrap: wrap; gap: 8px 24px; font-size: 15px; padding: 16px 20px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--line); }
.page-hero { position: relative; padding: calc(var(--header-h) + clamp(40px, 6vw, 80px)) 0 clamp(40px, 5vw, 64px); background: var(--bg); }
.page-hero__content { display: grid; gap: 20px; }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 15px; color: var(--muted); }
.crumbs a:hover { color: var(--fg); }
.not-found { min-height: 100vh; display: grid; place-items: center; text-align: center; }
.not-found .big-num { font-stretch: var(--display-stretch); font-weight: var(--h-weight); font-size: clamp(120px, 22vw, 240px); line-height: .9; letter-spacing: -.05em; color: var(--led); }
.btn-row--center { justify-content: center; margin-top: 32px; }

@media (max-width: 1180px) {
  .features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .features > .feature:nth-child(n) { --i: 0; }
  .features > .feature:nth-child(2n) { --i: 1; }
  .features > .feature:nth-child(n) .led-rail--in { left: -18px; width: calc(18px + var(--pad)); }
  .features > .feature:nth-child(2n + 1) .led-rail--in { left: calc(-1 * var(--branch) - 1px); width: calc(var(--branch) + 1px + var(--pad)); }
  .features > .feature:nth-child(n) .led-rail--out { display: block; }
  .features > .feature:nth-child(2n) .led-rail--out { display: none; }
}
@media (max-width: 1024px) {
  .formats, .why, .teacher, .enroll__grid { grid-template-columns: 1fr; }
  .why__proof { grid-template-columns: 1fr 1fr; gap: 0 20px; }
  .teacher__photo { max-width: 540px; }
  .contacts-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .work__list { grid-template-columns: 1fr; }
  .work__list li:nth-child(2) { border-top: 1px solid var(--line); padding-top: 18px; }
  .work__list li:nth-child(2)::before { top: calc(18px + (1.6em - 28px) / 2); }
}
@media (max-width: 720px) {
  body { font-size: 16px; }
  .features { grid-template-columns: 1fr; }
  .features > .feature:nth-child(n) { --i: 0; }
  .features > .feature:nth-child(n) .led-rail--in { left: calc(-1 * var(--branch) - 1px); width: calc(var(--branch) + 1px + var(--pad)); }
  .features > .feature:nth-child(n) .led-rail--out { display: none; }
  .videos { grid-template-columns: 1fr; }
  .why__row { grid-template-columns: 52px minmax(0, 1fr); gap: 16px; }
  .why__row .icon-tile { width: 52px; height: 52px; }
  .why__row::before, .why__row::after { left: 25px; top: 80px; }
  .why__row p { padding-top: 8px; }
  .format__head, .format__price, .format__list { padding-left: 22px; padding-right: 22px; }
  .format__cta { grid-template-columns: 1fr; padding: 0 22px 22px; }
  .contacts-grid { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: 150px; gap: 8px; }
  .gallery__item, .gallery__item:nth-child(n), .gallery--even .gallery__item:nth-child(n) { grid-column: span 1; grid-row: span 1; }
  .gallery__item:nth-child(3n + 1), .gallery--even .gallery__item:nth-child(3n + 1) { grid-column: span 2; grid-row: span 2; }
  .stepper__rail { --art-r: 42px; }
  .stepper__art svg { width: 60px; height: 60px; }
  .stepper__label { font-size: 17px; }
  .stepper__meta { padding: 3px 10px; font-size: 13px; }
  .form-frame iframe { height: 1060px; }
  .tabpanel--practice .form-frame iframe { height: 1380px; }
  .lightbox__inner { padding: 64px 12px; }
  .lightbox__prev, .lightbox__next { top: auto; bottom: 12px; }
  .lightbox__prev { transform: rotate(180deg); }
  .lightbox__next { transform: none; }
}

/* ---- 05-switchboard.css ---- */
/* 05 · Programme as a distribution board (desktop) + module cards with mini breakers (all sizes) */

.program__layout { display: grid; grid-template-columns: minmax(0, 340px) minmax(0, 1fr); gap: clamp(28px, 4.5vw, 72px); align-items: start; }
.program__board { position: sticky; top: calc(var(--header-h) + 20px); }
.board-hint { display: flex; align-items: center; gap: 10px; margin-top: 16px; color: var(--muted); font-size: 15px; }
.board-hint .icon { width: 20px; height: 20px; color: var(--accent-text); }

/* Board */
.panel { width: 100%; height: auto; max-height: calc(100vh - var(--header-h) - 80px); overflow: visible; }
.panel .encl { fill: var(--encl); stroke: var(--encl-stroke); stroke-width: 2; }
.panel .plate { fill: var(--plate); }
.panel .rail-slot { fill: rgba(0, 0, 0, .28); }
.panel .nameplate rect { fill: var(--nameplate); }
.panel .nameplate { color: var(--nameplate-ink); }
.panel .nameplate .np-bolt { fill: var(--mark-bolt); }
.panel.is-complete .encl { stroke: var(--led); stroke-width: 3; transition: stroke .6s; }

/* Wires: real colour code; energised wires carry a moving "current" overlay */
.w .w-base { fill: none; stroke-width: 6; stroke-linecap: round; stroke-linejoin: round; }
.w .w-core { fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; stroke: rgba(255, 255, 255, .28); }
.w .w-flow { fill: none; stroke: var(--flow); stroke-width: 2.2; stroke-linecap: round; stroke-dasharray: .006 .03; opacity: 0; transition: opacity .5s; }
.w--l .w-base { stroke: var(--wire-l); }
.w--n .w-base { stroke: var(--wire-n); }
.w--sheath .w-base { stroke: #5c6168; stroke-width: 12; }
.w--sheath .w-core { stroke: rgba(255, 255, 255, .18); stroke-width: 3; }
.w[data-on] .w-base { opacity: .55; transition: opacity .5s; }
/* the supply is energised when the LED strip reaches the programme section */
.w.is-on .w-base, .program.is-powered .supply .w .w-base { opacity: 1; }
.w.is-on .w-flow, .program.is-powered .supply .w .w-flow { opacity: 1; animation: wire-flow 1.6s linear infinite; }
.supply .w .w-base { opacity: .55; transition: opacity .5s; }
@keyframes wire-flow { to { stroke-dashoffset: -.144; } }
.busbar .bus-ins { fill: #8f949b; }
.busbar[data-on] { opacity: .6; transition: opacity .5s; }
.busbar.is-on { opacity: 1; }

/* Devices (shared by board and mini cards) */
.dev .d-body { stroke: #b4b8b2; stroke-width: .8; }
.dev .d-hole { fill: #25282d; }
.dev .d-slot { fill: #1b1d21; }
.dev .d-step { stroke: rgba(0, 0, 0, .14); stroke-width: 1; fill: none; }
.dev .d-nose { fill: #fafbf8; stroke: rgba(0, 0, 0, .07); }
.dev .d-label { fill: #fff; stroke: rgba(0, 0, 0, .12); stroke-width: .6; }
.dev .d-label-t { font: 600 9.5px var(--font); font-stretch: 100%; fill: #15171a; text-anchor: middle; }
.dev .d-rating { font: 600 8.5px var(--font); font-stretch: 87.5%; fill: #2a2d31; text-anchor: middle; }
.dev .d-recess { fill: #2a2d32; }
.dev .d-mark { font: 700 6px var(--font); fill: #5e636b; text-anchor: middle; }
.dev .d-lever { transition: transform .5s var(--ease-spring); transform-box: view-box; }
.dev .d-ind { fill: #2f9e4f; transition: fill .25s .15s; }
.dev .d-test { fill: #f2c230; stroke: #b8901c; stroke-width: .6; }
.dev .d-test-t { font: 700 6.5px var(--font); fill: #5a4300; text-anchor: middle; }
.dev .d-halo { display: none; }
.dev.is-on .d-lever { transform: translateY(-15px); }
.dev.is-on .d-ind { fill: #e2352b; }
.panel a { cursor: pointer; outline: none; }
.panel a:focus, .panel a:focus-visible { outline: none; }
button.mini-brk:focus:not(:focus-visible) { outline: none; }
.panel a:hover .d-nose { fill: #fff; }

/* Module cards */
.modules-wrap { position: relative; }
.modules { display: grid; gap: 14px; }
.module {
  position: relative; display: grid; grid-template-columns: 46px minmax(0, 1fr); gap: 22px;
  padding: clamp(20px, 2.2vw, 30px); border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--line);
  transition: border-color .4s, box-shadow .4s;
  scroll-margin-top: calc(var(--header-h) + 24px);
}
.module__num { display: block; font-weight: 600; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--accent-text); margin-bottom: 8px; }
.module__title { font-stretch: var(--display-stretch); font-weight: var(--h-weight); font-size: clamp(19px, 1.7vw, 24px); line-height: 1.25; letter-spacing: -.015em; color: var(--fg); margin-bottom: 12px; }
.module__body { display: grid; gap: 10px; color: var(--muted); font-size: 16.5px; line-height: 1.62; }
.module__body p { max-width: 72ch; }
.module__more { margin-top: 2px; }
.module__more summary {
  display: inline-flex; align-items: center; gap: 8px; cursor: pointer; list-style: none;
  font-weight: 600; font-size: 15px; color: var(--fg); padding: 6px 0;
}
.module__more summary::-webkit-details-marker { display: none; }
.module__more summary .icon { width: 20px; height: 20px; color: var(--accent-text); transition: transform .3s var(--ease-out); }
.module__more[open] summary .icon { transform: rotate(45deg); }
.module__more summary .less { display: none; }
.module__more[open] summary .more { display: none; }
.module__more[open] summary .less { display: inline; }
.module__more > div { display: grid; gap: 10px; padding-top: 8px; }
.module__more::details-content { block-size: 0; overflow: clip; transition: block-size .4s var(--ease-out), content-visibility .4s allow-discrete; }
.module__more[open]::details-content { block-size: auto; }
:root { interpolate-size: allow-keywords; }

.mini-dev { width: 46px; height: auto; overflow: visible; }
.module.is-on .mini-dev .d-lever { transform: translateY(-15px); }
.module.is-on .mini-dev .d-ind { fill: #e2352b; }
.modules__wire { display: none; }
.program__more { margin-top: 32px; }

@media (max-width: 1024px) {
  .program__layout { grid-template-columns: 1fr; }
  .program__board { display: none; }
  .modules__wire {
    display: block; position: absolute; left: calc(clamp(20px, 2.2vw, 30px) + 21px); top: 40px; bottom: 40px; width: 5px; border-radius: 3px;
    background: var(--wire-l); opacity: .35; z-index: 0;
  }
  .modules__wire span {
    position: absolute; inset: 0; border-radius: inherit; background: var(--wire-l);
    transform-origin: top; transform: scaleY(var(--p, 0)); transition: transform .2s linear;
  }
  .modules__wire { --p: 0; }
  .modules-wrap .modules__wire { opacity: 1; background: color-mix(in srgb, var(--wire-l) 35%, transparent); }
  .module { z-index: 1; }
}
@media (max-width: 720px) {
  .module { grid-template-columns: 38px minmax(0, 1fr); gap: 16px; padding: 20px 16px; }
  .mini-dev { width: 38px; }
  .modules__wire { left: 35px; }
}

/* Mini breaker is a real control: switching it opens the module text */
button.mini-brk { cursor: pointer; border-radius: 6px; align-self: start; }
button.mini-brk:hover .d-nose { fill: #fff; }
.module.is-flick .mini-dev .d-lever { animation: lever-flick .5s var(--ease-out); }
@keyframes lever-flick { 0% { transform: translateY(-15px); } 40% { transform: translateY(0); } 100% { transform: translateY(-15px); } }
.panel .dev[data-m] { cursor: pointer; }

/* ---- 06-motion.css ---- */
/* 06 · Motion: reveal on scroll, hero entrance, pausing, reduced motion */

.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .9s var(--ease-out), transform .9s var(--ease-out); transition-delay: var(--d, 0s); }
.js .reveal.is-in { opacity: 1; transform: none; }

/* Hero entrance: pure CSS so it does not wait for JS (better LCP) */
@keyframes fade-up { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes rise { from { transform: translateY(105%); } to { transform: none; } }
.hero-in { animation: fade-up .9s var(--ease-out) both; animation-delay: var(--d, .2s); }
.hero__title .line > span { animation: rise 1s var(--ease-out) both; animation-delay: var(--d, .1s); }

/* Pause decorative loops when off-screen (class set by JS) */
.program.is-paused .w-flow { animation-play-state: paused !important; }

/* Skip rendering work for far-below-the-fold sections */
/* (no content-visibility: the LED strip measures positions inside every section) */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* Lenis smooth scrolling */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: hidden; }

/* ---- 07-led.css ---- */
/* 07 · LED strip concept.
   The strip starts at the header logo (the logo "gives the charge"), runs down the left gutter of the page and
   ends at the footer logo, which lights up at the end of the scroll. JS moves the lit head with the scroll:
   a lamp turns on only after the lit part has passed it, then its section lights up.
   Elements marked [data-led] light up individually as the head passes them. */

.page { position: relative; }
:root {
  --content-left: calc((100% - min(100% - 2 * var(--gutter), var(--container))) / 2);
  --spine-x: calc(var(--content-left) + 29px); /* = centre of the 58px header logo */
  --branch: 35px;                              /* spine -> content start (64px content inset - 29px) */
  --led-lit: var(--led);
}
.section--alt { --led-lit: #f0ad2c; --led-track: #b4ada0; }

/* room for the strip: content shifts right on desktop; the header keeps the logo on the strip */
@media (min-width: 1101px) {
  .container { padding-left: 64px; }
  .site-header .container, .mobile-menu .container { padding-left: 0; }
}
@media (max-width: 1100px) {
  /* content starts at gutter + 14px, the strip sits at 9px: the branch spans exactly the gap */
  :root { --spine-x: 9px; --branch: calc(var(--gutter) + 5px); }
  .container { padding-left: 14px; }
  .site-header .container { padding-left: 0; }
}

/* --- the strip (height is set by JS: from the header logo to the footer logo) --- */
.spine {
  position: absolute; top: calc(var(--header-h) / 2 + 27px); left: var(--spine-x); width: 6px; margin-left: -3px;
  height: var(--spine-h, 100%); z-index: 6; pointer-events: none;
}
.spine__cable { position: absolute; inset: 0; border-radius: 3px; background: var(--led-off); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .05); }
.spine__live {
  position: absolute; left: 0; right: 0; top: 0; height: calc(var(--spine-p, 0) * 100%); border-radius: 3px; overflow: hidden;
  background: var(--led); box-shadow: 0 0 10px var(--led-glow), 0 0 24px rgba(255, 214, 120, .22);
}
.spine__live::before { /* moving LED pattern: transform only, no repaint */
  content: ""; position: absolute; left: 0; right: 0; top: -12px; bottom: 0; will-change: transform;
  background: repeating-linear-gradient(180deg, var(--led-core) 0 4px, var(--led) 4px 8px, rgba(255, 214, 120, .4) 8px 12px);
  animation: led-run .5s linear infinite;
}
.spine.is-intro .spine__live { transition: height var(--intro-dur, 1.5s) cubic-bezier(.45, 0, .2, 1); }
@keyframes led-run { to { transform: translateY(12px); } }
.spine__spark {
  position: absolute; left: 50%; top: calc(var(--spine-p, 0) * 100%); width: 26px; height: 26px; margin: -13px 0 0 -13px; border-radius: 50%;
  background: radial-gradient(circle, #fff 0 18%, var(--led-core) 30%, var(--led-glow) 48%, transparent 70%);
  animation: spark-flicker .2s steps(2) infinite;
}
.spine.is-intro .spine__spark { transition: top var(--intro-dur, 1.5s) cubic-bezier(.45, 0, .2, 1); }
.spine.is-done .spine__spark { opacity: 0; transition: opacity .4s; }
@keyframes spark-flicker { 50% { transform: scale(.8); } }

/* header logo gives the charge on load */
.site-header .brand__mark { position: relative; }
.is-charging .site-header .brand .m-bolt { animation: bolt-charge 1.4s ease-in-out; }
@keyframes bolt-charge { 0%, 100% { filter: none; } 30%, 60% { filter: drop-shadow(0 0 6px var(--led)) drop-shadow(0 0 14px var(--led)); } }

/* --- lamps: an LED bead on the strip + a branch into the section heading --- */
.lamp { position: absolute; z-index: 7; pointer-events: none; left: var(--spine-x); top: 0; width: 0; height: 0; }
.lamp__branch { position: absolute; left: 0; top: -2px; width: calc(var(--branch) + 2px); height: 4px; border-radius: 0 2px 2px 0; background: var(--led-off); }
.lamp__branch::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; background: var(--led); box-shadow: 0 0 8px var(--led-glow);
  transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease-out) .05s;
}
.lamp__bead {
  position: absolute; left: -9px; top: -9px; width: 18px; height: 18px; border-radius: 50%;
  background: #23242a; box-shadow: 0 0 0 3px #101114, inset 0 0 0 2px #4a4d55; transition: background-color .3s, box-shadow .3s;
}
.lamp__halo {
  position: absolute; left: -70px; top: -70px; width: 140px; height: 140px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 214, 120, .45), rgba(255, 214, 120, .08) 45%, transparent 70%);
  opacity: 0; transform: scale(.4); transition: opacity .45s, transform .5s var(--ease-out);
}
.lamp.is-powered .lamp__branch::after { transform: scaleX(1); }
.lamp.is-powered .lamp__bead { background: var(--led-core); box-shadow: 0 0 0 3px #101114, inset 0 0 0 2px var(--led), 0 0 14px var(--led-glow); }
.lamp.is-powered .lamp__halo { opacity: 1; transform: none; }
/* lamps sit outside their sections: repeat the light-section strip colours here */
.lamp--alt { --led-track: #b4ada0; --led-lit: #f0ad2c; }
.lamp--alt .lamp__branch { background: var(--led-track); }
/* when the lamp points at an eyebrow, its branch runs on through the eyebrow line: one piece, no joint
   (JS adds .lamp--eyebrow and hides that eyebrow's own line, keeping its space) */
.lamp--eyebrow .lamp__branch { width: calc(var(--branch) + 28px); }
.lamp--eyebrow .lamp__branch::after { transition-duration: .45s; }
.eyebrow--lamp::before { visibility: hidden; }
/* a branch into a box (stat band, photo) stops flush at its edge with a square end: no overlap, no step */
.lamp:not(.lamp--eyebrow) .lamp__branch { width: var(--branch); border-radius: 0; }
.lamp--band .lamp__branch { display: none; }
.lamp--alt .lamp__bead { box-shadow: 0 0 0 3px #eeede9, inset 0 0 0 2px #8f897c; background: #d9d5cc; }
.lamp--alt.is-powered .lamp__bead { background: #ffd879; box-shadow: 0 0 0 3px #eeede9, inset 0 0 0 2px #d08f12, 0 0 14px rgba(240, 173, 44, .7); }
.lamp--alt .lamp__branch::after { background: var(--led-lit); }

/* end of the strip: a smooth bend into the footer logo (SVG path set by JS), then the logo lights up */
.spine-end { position: absolute; left: var(--spine-x); top: 0; width: 1px; height: 1px; overflow: visible; z-index: 6; pointer-events: none; }
.spine-end path { fill: none; stroke-width: 6; stroke-linecap: butt; stroke-linejoin: round; }
.spine-end__track { stroke: var(--led-off); }
.spine-end__live { stroke: var(--led); stroke-dasharray: 1 1; stroke-dashoffset: 1; filter: drop-shadow(0 0 5px var(--led-glow)); transition: stroke-dashoffset .45s linear; }
.spine-end.is-powered .spine-end__live { stroke-dashoffset: 0; }
.site-footer .brand__mark { transition: filter .6s .35s; }
.site-footer .brand__mark .m-stroke, .site-footer .brand__mark .m-bolt { transition: stroke .4s .35s, fill .4s .35s; }
.site-footer.is-powered .brand__mark { filter: drop-shadow(0 0 8px rgba(110, 141, 255, .8)) drop-shadow(0 0 18px rgba(255, 210, 63, .45)); }
.site-footer.is-powered .brand__mark .m-stroke { stroke: #9db3ff; }
.site-footer.is-powered .brand__mark .m-bolt { fill: #ffe066; }
.site-footer.is-powered .footer-tagline { color: #fff; text-shadow: 0 0 18px rgba(255, 214, 120, .35); }

/* each powered section receives soft light from its lamp (clipped to the section) */
[data-lamp] { isolation: isolate; overflow: clip; }
.site-footer { position: relative; }
[data-lamp]::after {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
  left: var(--spine-x); top: var(--lamp-y, 120px); width: 1200px; height: 900px; transform: translate(-50%, -40%);
  background: radial-gradient(closest-side, rgba(255, 214, 120, .06), transparent);
  opacity: 0; transition: opacity 1s;
}
.section--alt[data-lamp]::after { background: radial-gradient(closest-side, rgba(255, 190, 80, .12), transparent); }
[data-lamp].is-powered::after { opacity: 1; }
/* --- generic lit items: an LED edge along the top runs left -> right, a dot turns on --- */
[data-led] { position: relative; }
.led-edge { position: absolute; left: 0; right: 0; top: 0; height: 3px; overflow: hidden; border-radius: inherit; pointer-events: none; z-index: 2; }
.led-edge::after {
  content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, var(--led-lit), var(--led-core), var(--led-lit));
  box-shadow: 0 0 12px var(--led-glow); transform: scaleX(0); transform-origin: left;
  transition: transform .7s var(--ease-out); transition-delay: var(--led-delay, 0s);
}
.is-lit > .led-edge::after { transform: scaleX(1); }

@media (prefers-reduced-motion: reduce) {
  .spine__live::before { animation: none; }
  .spine__spark { display: none; }
}
@media (max-width: 1100px) {
  .spine { top: calc(var(--header-h) + 6px); width: 4px; margin-left: -2px; }
  .spine-end path { stroke-width: 4; }
  .lamp__halo { left: -46px; top: -46px; width: 92px; height: 92px; }
  .lamp__bead { left: -7px; top: -7px; width: 14px; height: 14px; }
}
