/* Devign Academy. Tokens from ~/devign-brand/DESIGN.md: Night background, one violet for actions, Archivo 800
   headings, Inter body, Alexandria for Arabic, Tabler icons, buttons 8 px, cards 12 px. Mobile first, logical
   properties for RTL. No inline styles anywhere (CSP style-src 'self'); no gradients.

   ---- Classes for BILLING views (WEB-SPLIT.md contract 7). Use these; do not add a CSS file. -------------------
   Layout     .wrap (page width + gutter)  .narrow (820 px column)  .page-top (page title band: h1 + .lead)
              .page-body (content under it)  .section  .section__head  .block
   Text       .lead  .muted  .small  .tnum  .break  .visually-hidden  .h-small (small heading with an icon)
   Buttons    .btn  .btn--primary (one per view)  .btn--ghost  .btn--danger  .btn--small  .btn--large  .btn--block
              .actions (row of buttons/forms)  .actions--center  .linkish (button that looks like a link)
   Panels     .panel (card)  .panel--accent  .panel--danger  .panel--quiet  .side-card  .kv (dl of label/value rows)
   Status     .notice + .notice--ok | --info | --warn | --bad (an <svg class="ic"> first, then <p>)
              .chip + .chip--ok | --wait | --bad | --muted (tiny status label)
   Forms      .form (grid of fields)  .form__grid (two columns from 560 px)  .field  .field--full  .field__row
              .hint  .field-error  .optional  .check (checkbox + text label)  .form--inline  .hp (honeypot)
   Lists      .ticks (icon + text rows; .ticks--lg)  .steps-list (numbered steps)
   Auth-like  .auth > .auth__card (centred card with .auth__icon, h1, .muted lead)  .auth__alt  .auth__note
   Legal      .legal (long text page; h1, .legal__meta, h2, lists)
   Account    the account page prints billing_account_panel() inside <section class="panel" id="subscription">
              after its own h2; start the panel with <p>/.kv/.actions, not another h2.
   Icons      icon('name') prints an <svg class="ic"> for any Tabler name in app/lib/icons.php.
*/

:root {
  --night: #07070F;
  --night-2: #0B0B18;
  --deep: #10101E;
  --deep-2: #1A1A2E;
  --field: #0D0E1D;
  --line: #25263B;
  --line-strong: #34355A;
  --input-line: #6A6C88;
  --ink: #F4F4F8;
  --body: #B8BACB;
  --muted: #9A9CB0;
  --violet: #7B6EF0;
  --violet-soft: #C9C4FF;
  --violet-tint: rgba(123, 110, 240, .12);
  --violet-line: rgba(123, 110, 240, .5);
  --on-violet: #0B0B18;
  --btn-2: #161628;
  --ok: #34D399;
  --bad: #F87171;
  --warn: #FBBF24;
  --r-btn: 8px;
  --r-input: 8px;
  --r-chip: 6px;
  --r-card: 12px;
  --r-media: 16px;
  --r-phone: 36px;
  --ease: cubic-bezier(.22, .9, .3, 1);
  --t-fast: 120ms;
  --t-mid: 220ms;
  --t-slow: 420ms;
  --gutter: 16px;
  --page-max: 1200px;
  --font-display: Archivo, Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
}
html[lang="ar"] {
  --font-display: Alexandria, Inter, system-ui, sans-serif;
  --font-body: Alexandria, Inter, system-ui, sans-serif;
}

/* ---- base ---------------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 88px; scroll-behavior: smooth; background: var(--night); }
body {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column;
  background: var(--night); color: var(--body);
  font-family: var(--font-body); font-size: 16px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
html[lang="ar"] body { line-height: 1.8; }
.main { flex: 1 0 auto; }
h1, h2, h3, h4 {
  margin: 0 0 .5em; color: var(--ink); font-family: var(--font-display); font-weight: 800;
  letter-spacing: -.02em; line-height: 1.1; text-wrap: balance;
}
html[lang="ar"] :is(h1, h2, h3, h4), html[lang="th"] :is(h1, h2, h3, h4) { letter-spacing: 0; line-height: 1.35; }
h1 { font-size: clamp(30px, 6vw, 44px); }
h2 { font-size: clamp(24px, 3.4vw, 34px); }
h3 { font-size: 19px; letter-spacing: -.01em; }
p { margin: 0 0 1em; }
a { color: var(--violet-soft); text-underline-offset: 3px; }
a:hover { color: #E4E1FF; }
img, svg { max-width: 100%; }
img { height: auto; }
strong, b { color: var(--ink); font-weight: 600; }
ul, ol { padding-inline-start: 1.2em; }
bdi { unicode-bidi: isolate; }
::selection { background: rgba(123, 110, 240, .4); color: #fff; }
:focus-visible { outline: 2px solid var(--violet); outline-offset: 2px; border-radius: 4px; }
[hidden] { display: none !important; }
.ic {
  width: 1.15em; height: 1.15em; flex: none;
  fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; vertical-align: -.2em;
}
.ic--ok { color: var(--ok); }
html[dir="rtl"] .ic--flip { transform: scaleX(-1); }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.tnum { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.break { overflow-wrap: anywhere; }
.visually-hidden {
  position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important;
  overflow: hidden !important; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0 !important;
}
.skip {
  position: absolute; inset-inline-start: 8px; top: 8px; z-index: 100; padding: 10px 16px; border-radius: var(--r-btn);
  background: var(--violet); color: var(--on-violet); font-weight: 600; transform: translateY(-160%); transition: transform var(--t-fast) var(--ease);
}
.skip:focus { transform: none; color: var(--on-violet); }
.hp { position: absolute; inset-inline-start: -10000px; width: 1px; height: 1px; overflow: hidden; }
.js .js-hide { display: none; }
.wrap { width: 100%; max-width: var(--page-max); margin-inline: auto; padding-inline: var(--gutter); }
.narrow { max-width: 820px; }
.lead { font-size: 17px; color: var(--body); max-width: 62ch; }

/* ---- buttons ------------------------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px;
  border: 1px solid var(--line-strong); border-radius: var(--r-btn); background: var(--btn-2); color: var(--ink);
  font: inherit; font-weight: 600; font-size: 15px; line-height: 1.2; text-decoration: none; text-align: center; cursor: pointer;
  transition: filter var(--t-fast) var(--ease), transform var(--t-fast) var(--ease), background var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease);
}
.btn:hover { filter: brightness(1.12); color: var(--ink); border-color: #4A4B72; }
.btn:active { filter: brightness(.92); transform: translateY(1px); }
.btn:focus-visible { outline: 2px solid var(--violet); outline-offset: 2px; box-shadow: 0 0 0 2px var(--night); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .4; pointer-events: none; }
.btn--primary { background: var(--violet); border-color: var(--violet); color: var(--on-violet); }
.btn--primary:hover { color: var(--on-violet); border-color: var(--violet); }
.btn--ghost { background: transparent; border-color: transparent; color: var(--violet-soft); }
.btn--ghost:hover { color: #E4E1FF; background: var(--violet-tint); border-color: transparent; }
.btn--danger { color: var(--bad); border-color: rgba(248, 113, 113, .45); }
.btn--danger:hover { color: var(--bad); border-color: rgba(248, 113, 113, .7); }
.btn--small { min-height: 40px; padding: 8px 12px; font-size: 14px; }
.btn--large { min-height: 52px; padding: 14px 24px; font-size: 16px; }
.btn--block { width: 100%; }
.btn--icon { padding: 8px 10px; }
.btn--icon .ic { width: 22px; height: 22px; }
.linkish { background: none; border: 0; padding: 4px; color: var(--violet-soft); font: inherit; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.actions form { margin: 0; }
.actions--center { justify-content: center; }

/* ---- chips, notices ------------------------------------------------------------------------ */
.chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 1px 8px; border-radius: var(--r-chip); border: 1px solid var(--line-strong);
  font-size: 13px; font-weight: 600; line-height: 1.6; white-space: nowrap; color: var(--body); background: rgba(255, 255, 255, .03);
}
.chip .ic { width: 14px; height: 14px; }
.chip--ok { color: var(--ok); border-color: rgba(52, 211, 153, .35); background: rgba(52, 211, 153, .08); }
.chip--wait { color: var(--violet-soft); border-color: var(--violet-line); background: var(--violet-tint); }
.chip--bad { color: var(--bad); border-color: rgba(248, 113, 113, .35); background: rgba(248, 113, 113, .08); }
.chip--muted { color: var(--muted); }
.notice {
  display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; margin: 0 0 16px; border-radius: var(--r-card);
  border: 1px solid var(--line); background: var(--deep); color: var(--body); font-size: 15px;
}
.notice p { margin: 0; }
.notice > .ic { margin-top: 3px; }
.notice--ok { border-color: rgba(52, 211, 153, .35); }
.notice--ok > .ic { color: var(--ok); }
.notice--warn { border-color: rgba(248, 113, 113, .4); background: #171327; }
.notice--warn > .ic { color: var(--bad); }
.notice--info { border-color: rgba(123, 110, 240, .35); }
.notice--info > .ic { color: var(--violet-soft); }
.notice--bad { border-color: rgba(248, 113, 113, .5); }
.notice--bad > .ic { color: var(--bad); }
.flash-wrap { margin-top: 16px; }
.flash-wrap .notice { margin: 0; }

/* ---- forms --------------------------------------------------------------------------------- */
.form { display: grid; gap: 16px; margin: 0; }
.form + .form { margin-top: 24px; padding-top: 24px; border-top: 1px solid var(--line); }
.form__grid { display: grid; gap: 16px; }
.field { display: grid; gap: 6px; min-width: 0; align-content: start; }
.field__row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.field label, .label { color: var(--ink); font-weight: 600; font-size: 15px; margin: 0; }
.optional { color: var(--muted); font-weight: 400; font-size: 14px; }
.hint { margin: 0; font-size: 14px; color: var(--muted); }
.field-error { margin: 0; font-size: 14px; color: var(--bad); }
input[type="text"], input[type="email"], input[type="password"], input[type="url"], input[type="tel"], input[type="number"], select, textarea {
  width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid var(--input-line); border-radius: var(--r-input);
  background: var(--field); color: var(--ink); font: inherit; font-size: 16px; line-height: 1.4;
  transition: border-color var(--t-fast) var(--ease), background var(--t-fast) var(--ease);
}
input:hover, select:hover, textarea:hover { border-color: #8A8CA8; }
textarea { resize: vertical; min-height: 96px; }
select {
  appearance: none; cursor: pointer; padding-inline-end: 36px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%239A9CB0' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6l6 -6'/%3E%3C/svg%3E");
  background-position: right 14px center; background-size: 12px 12px; background-repeat: no-repeat;
}
html[dir="rtl"] select { background-position: left 14px center; }
select option { background: #15152b; color: var(--ink); }
input::placeholder, textarea::placeholder { color: var(--muted); opacity: 1; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid var(--violet); outline-offset: 1px; border-color: var(--violet); }
[aria-invalid="true"] { border-color: var(--bad) !important; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; color: var(--body); cursor: pointer; }
.check input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--violet); flex: none; }
.choice-group { border: 0; margin: 0 0 20px; padding: 0; min-width: 0; display: grid; gap: 10px; }
.choice-group legend { padding: 0; margin-bottom: 8px; font-weight: 600; color: var(--ink); }
.check--box { padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--r-card); background: var(--field);
  transition: border-color var(--t-fast) var(--ease), background var(--t-fast) var(--ease); }
.check--box:hover { border-color: var(--line-strong); }
.check--box:has(input:checked) { border-color: var(--violet-line); background: var(--violet-tint); }
.check--box:has(input:focus-visible) { outline: 2px solid var(--violet); outline-offset: 2px; }
.form--inline { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.form--inline input[type="text"], .form--inline input[type="email"], .form--inline select { width: auto; flex: 1 1 200px; }
.form--split { align-items: end; }

/* ---- header, footer ------------------------------------------------------------------------ */
.site-header {
  position: sticky; top: 0; z-index: 50; background: rgba(7, 7, 15, .88); border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
}
.site-header__inner { display: flex; align-items: center; gap: 16px; min-height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; flex: none; text-decoration: none; }
.brand__logo { height: 26px; width: auto; display: block; }
.brand__word {
  padding-inline-start: 10px; border-inline-start: 1px solid var(--line-strong);
  color: var(--ink); font-family: var(--font-body); font-weight: 600; font-size: 15px; letter-spacing: .01em; line-height: 1;
}
.site-nav { display: none; gap: 4px; margin-inline-start: 20px; }
.site-nav a { color: var(--body); text-decoration: none; font-size: 15px; font-weight: 500; padding: 8px 12px; border-radius: var(--r-btn); }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--ink); background: var(--deep); }
.site-header__actions { display: flex; align-items: center; gap: 8px; margin-inline-start: auto; }
.site-header__actions .btn { white-space: nowrap; }
.header-name { max-width: 14ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.menu { position: relative; }
.menu > summary { list-style: none; }
.menu > summary::-webkit-details-marker { display: none; }
.menu__panel {
  position: absolute; inset-inline-end: 0; top: calc(100% + 8px); z-index: 60; display: grid; min-width: 240px; padding: 8px;
  background: var(--deep); border: 1px solid var(--line-strong); border-radius: var(--r-card); box-shadow: 0 18px 40px rgba(0, 0, 0, .5);
}
.menu__panel a, .menu__button {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--r-btn); color: var(--ink); text-decoration: none;
  font: inherit; font-weight: 500; background: none; border: 0; width: 100%; cursor: pointer; text-align: start;
}
.menu__panel a .ic, .menu__button .ic { color: var(--muted); }
.menu__panel a:hover, .menu__button:hover { background: var(--deep-2); }
.menu__sep { height: 1px; background: var(--line); margin: 6px 4px; }
.menu__panel form { margin: 0; }
.site-footer { border-top: 1px solid var(--line); padding: 48px 0 24px; background: var(--night-2); margin-top: 64px; }
.site-footer__inner { display: grid; gap: 32px; }
.site-footer__brand p { margin: 14px 0 0; font-size: 15px; max-width: 36ch; }
.site-footer__col { display: grid; gap: 8px; align-content: start; font-size: 15px; }
.site-footer__col a { color: var(--body); text-decoration: none; }
.site-footer__col a:hover { color: var(--ink); text-decoration: underline; }
.site-footer__title { font-family: var(--font-body); font-size: 14px; font-weight: 600; letter-spacing: 0; color: var(--ink); margin: 0 0 4px; }
.site-footer__base { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--line); }
.site-footer__base p { margin: 0; }
.lang-form { display: flex; align-items: center; gap: 8px; margin: 8px 0 0; }
.lang-form__icon { color: var(--muted); display: inline-flex; }
.lang-form select { width: auto; min-width: 170px; min-height: 40px; padding-block: 8px; }
.store-badges { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 4px 0 12px; }
.store-badges img { height: 40px; width: auto; display: block; }

/* ---- page scaffolding ----------------------------------------------------------------------- */
.page-top { padding: 40px 0 8px; }
.page-top h1 { margin-bottom: 8px; }
.page-body { padding-top: 16px; }
.section { padding: 64px 0; }
.section--band { background: var(--night-2); border-block: 1px solid var(--line); }
.section__head { margin-bottom: 32px; max-width: 720px; }
.section__head .lead { margin: 0; }
.block { margin-bottom: 40px; }
.panel { background: var(--deep); border: 1px solid var(--line); border-radius: var(--r-card); padding: 20px 16px; margin-bottom: 16px; min-width: 0; }
.panel h2 { font-size: 20px; display: flex; gap: 10px; align-items: center; }
.panel h2 > .ic { color: var(--violet-soft); }
.panel > :last-child { margin-bottom: 0; }
.panel--accent { border-color: var(--violet-line); }
.panel--danger { border-color: rgba(248, 113, 113, .35); }
.panel--quiet { background: transparent; }
.side-card { background: var(--deep); border: 1px solid var(--line); border-radius: var(--r-card); padding: 20px; }
.side-card p:last-child { margin: 0; }
.h-small { font-size: 15px; margin: 20px 0 10px; color: var(--ink); font-family: var(--font-body); font-weight: 600; letter-spacing: 0; display: flex; gap: 8px; align-items: center; }
.h-small > .ic { color: var(--violet-soft); }
.crumbs { margin: 0 0 16px; font-size: 14px; }
.crumbs a { display: inline-flex; gap: 6px; align-items: center; text-decoration: none; color: var(--body); }
.crumbs a:hover { color: var(--ink); }
.kv { margin: 0 0 12px; display: grid; gap: 10px; }
.kv div { display: flex; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--line); padding-bottom: 8px; min-width: 0; }
.kv div:last-child { border-bottom: 0; }
.kv dt { color: var(--muted); font-size: 14px; flex: none; }
.kv dd { margin: 0; color: var(--ink); text-align: end; min-width: 0; overflow-wrap: anywhere; }
.ticks { list-style: none; padding: 0; margin: 0 0 16px; display: grid; gap: 10px; }
.ticks li { display: flex; gap: 10px; align-items: flex-start; color: var(--body); }
.ticks li > .ic { color: var(--ok); margin-top: 3px; }
.ticks--lg { gap: 16px; }
.ticks--lg li > .ic { color: var(--violet-soft); width: 22px; height: 22px; margin-top: 1px; }
.ticks--lg li > span { display: grid; gap: 2px; }
.steps-list { padding-inline-start: 1.3em; display: grid; gap: 10px; }
.empty { text-align: center; padding: 40px 16px; border: 1px dashed var(--line-strong); border-radius: var(--r-card); }
.progress {
  -webkit-appearance: none; appearance: none; display: block; width: 100%; height: 6px; border: 0; border-radius: 3px;
  background: var(--deep-2); color: var(--violet); overflow: hidden;
}
.progress::-webkit-progress-bar { background: var(--deep-2); border-radius: 3px; }
.progress::-webkit-progress-value { background: var(--violet); border-radius: 3px; }
.progress::-moz-progress-bar { background: var(--violet); border-radius: 3px; }

/* ---- landing ---------------------------------------------------------------------------------- */
.hero { padding: 36px 0 48px; overflow: hidden; }
.hero__grid { display: grid; gap: 40px; align-items: center; }
.hero__text { min-width: 0; }
.hero h1 { font-size: clamp(38px, 9.5vw, 72px); line-height: 1.02; margin-bottom: 20px; max-width: 12ch; }
html[lang="ar"] .hero h1, html[lang="th"] .hero h1, html[lang="ru"] .hero h1 { line-height: 1.25; max-width: 16ch; }
.hero .lead { font-size: clamp(17px, 2vw, 19px); margin-bottom: 28px; }
.hero__facts { list-style: none; margin: 28px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px 22px; font-size: 15px; }
.hero__facts li { display: inline-flex; gap: 8px; align-items: center; }
.hero__facts .ic { color: var(--violet-soft); }
.hero__demo { margin: 0; display: grid; justify-items: center; gap: 14px; min-width: 0; }
.hero__demo figcaption { text-align: center; max-width: 34ch; }
.phone {
  width: min(300px, 78vw); padding: 10px; border-radius: var(--r-phone); background: #0E0E1C;
  border: 1px solid var(--line-strong); box-shadow: 0 40px 90px rgba(0, 0, 0, .55), 0 0 0 6px rgba(123, 110, 240, .06);
}
.phone .stage { border-radius: 27px; }

.course-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.course-row {
  position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 16px; align-items: start;
  padding: 18px 16px; background: var(--deep); border: 1px solid var(--line); border-radius: var(--r-card);
  transition: border-color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease), background var(--t-fast) var(--ease);
}
.course-row:hover { border-color: var(--line-strong); background: #13132A; }
.course-row:focus-within { border-color: var(--violet-line); }
.course-row__icon {
  width: 48px; height: 48px; display: grid; place-items: center; border-radius: 12px;
  background: var(--violet-tint); border: 1px solid rgba(123, 110, 240, .3); color: var(--violet-soft);
}
.course-row__icon .ic { width: 24px; height: 24px; }
.course-row__body { min-width: 0; }
.course-row__kicker { margin: 0 0 4px; color: var(--violet-soft); font-size: 14px; font-weight: 600; }
.course-row__title { margin: 0 0 4px; font-size: 20px; }
.course-row__title a { color: var(--ink); text-decoration: none; }
.course-row__title a::after { content: ""; position: absolute; inset: 0; border-radius: var(--r-card); }
.course-row__title a:focus-visible { outline: none; }
.course-row__title a:focus-visible::after { outline: 2px solid var(--violet); outline-offset: 2px; }
.course-row__sub { margin: 0 0 10px; color: var(--body); font-size: 15px; }
.course-row__meta { display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: center; margin: 0; font-size: 14px; color: var(--muted); }
.course-row__meta > span:not(.chip) { display: inline-flex; gap: 6px; align-items: center; }
.course-row__state { display: grid; grid-template-columns: minmax(80px, 200px) auto; gap: 12px; align-items: center; margin: 12px 0 0; }
.course-row__state.is-done { display: flex; gap: 8px; color: var(--ok); font-size: 14px; font-weight: 600; }
.course-row__go { align-self: center; color: var(--muted); }
.course-row--featured { border-color: var(--violet-line); }
.course-row--featured .course-row__icon { background: var(--violet); color: var(--on-violet); border-color: var(--violet); }

.flow { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; counter-reset: none; }
.flow__step { position: relative; display: grid; grid-template-columns: 52px minmax(0, 1fr); column-gap: 18px; padding-bottom: 28px; }
.flow__step:last-child { padding-bottom: 0; }
.flow__step::before { content: ""; position: absolute; inset-inline-start: 25px; top: 52px; bottom: 0; width: 2px; background: var(--line-strong); }
.flow__step:last-child::before { display: none; }
.flow__icon {
  grid-row: span 2; width: 52px; height: 52px; display: grid; place-items: center; border-radius: 14px;
  background: var(--deep); border: 1px solid var(--line-strong); color: var(--violet-soft); position: relative; z-index: 1;
}
.flow__icon .ic { width: 24px; height: 24px; }
.flow__step h3 { margin: 4px 0 6px; font-size: 20px; }
.flow__step p { margin: 0; max-width: 46ch; }

.pricing { display: grid; gap: 16px; }
.pricing__plan, .pricing__creators { padding: 28px 20px; border-radius: var(--r-media); border: 1px solid var(--line); background: var(--deep); min-width: 0; }
.pricing__plan { border-color: var(--violet-line); }
.pricing__price { font-family: var(--font-display); font-weight: 800; font-size: clamp(26px, 4vw, 34px); color: var(--ink); letter-spacing: -.02em; line-height: 1.1; margin: 4px 0 10px; }
.pricing__creators { background: var(--night-2); }
.pricing__mark { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px; background: var(--deep-2); color: var(--violet-soft); margin-bottom: 16px; }
.pricing__creators h3 { font-size: 22px; }
.faq-wrap { display: grid; gap: 16px; }
.faq { border-top: 1px solid var(--line); }
.faq__item { border-bottom: 1px solid var(--line); }
.faq__item summary {
  display: flex; justify-content: space-between; gap: 16px; align-items: center; list-style: none; cursor: pointer;
  padding: 18px 2px; color: var(--ink); font-weight: 600; font-size: 17px;
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__chev { transition: transform var(--t-mid) var(--ease); color: var(--muted); }
details[open] > summary .faq__chev { transform: rotate(180deg); }
.faq__item p { padding: 0 2px 18px; margin: 0; max-width: 70ch; }

/* ---- catalog extras, course page ---------------------------------------------------------------- */
.continue {
  display: flex; align-items: center; gap: 14px; padding: 16px; margin-bottom: 20px; border-radius: var(--r-card);
  background: var(--deep); border: 1px solid var(--violet-line); text-decoration: none; color: var(--body);
}
.continue:hover { background: #13132A; color: var(--body); }
.continue__icon { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; background: var(--violet); color: var(--on-violet); flex: none; }
.continue__text { display: grid; min-width: 0; flex: 1; }
.continue__text strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.continue__label { font-size: 14px; color: var(--violet-soft); font-weight: 600; }
.continue__go { color: var(--muted); }
.course-hero { padding: 28px 0 32px; border-bottom: 1px solid var(--line); background: var(--night-2); }
.course-hero__head { display: flex; gap: 18px; align-items: flex-start; margin-bottom: 14px; }
.course-hero__head h1 { margin-bottom: 6px; }
.course-hero__head .lead { margin: 0; }
.course-hero__icon {
  width: 60px; height: 60px; flex: none; display: grid; place-items: center; border-radius: 16px;
  background: var(--violet); color: var(--on-violet);
}
.course-hero__icon .ic { width: 30px; height: 30px; }
.course-hero .course-row__meta { margin-bottom: 18px; }
.course-hero__progress { display: grid; grid-template-columns: minmax(120px, 280px) auto; gap: 12px; align-items: center; margin-bottom: 18px; }
.course-body { display: grid; gap: 24px; padding-top: 32px; }
.course-body__main, .course-body__side { min-width: 0; }
.course-body__main h2 { font-size: 24px; }
.lesson-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.lesson-item { position: relative; display: grid; grid-template-columns: 36px minmax(0, 1fr); gap: 4px 14px; padding: 16px 4px; border-bottom: 1px solid var(--line); }
.lesson-item:hover { background: rgba(255, 255, 255, .015); }
.lesson-item__state { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; border: 1.5px solid var(--input-line); color: var(--muted); font-weight: 700; font-size: 14px; }
.lesson-item--done .lesson-item__state { border-color: var(--ok); color: var(--ok); }
.lesson-item--started .lesson-item__state { border-color: var(--violet); color: var(--violet-soft); }
.lesson-item.is-locked .lesson-item__state { border-style: dashed; }
.lesson-item__state .ic { width: 17px; height: 17px; }
.lesson-item__body { min-width: 0; }
.lesson-item__title { color: var(--ink); font-weight: 600; text-decoration: none; font-size: 17px; }
.lesson-item__title::after { content: ""; position: absolute; inset: 0; }
.lesson-item__title:hover { color: var(--violet-soft); }
.lesson-item__sum { margin: 2px 0 0; font-size: 15px; }
.lesson-item__meta { grid-column: 2; display: flex; gap: 10px; align-items: center; }

/* ---- paywall -------------------------------------------------------------------------------- */
.paywall {
  display: grid; gap: 18px; margin: 32px 0 0; padding: 24px 20px; border-radius: var(--r-media);
  background: var(--deep); border: 1px solid var(--violet-line);
}
.course-body__side .paywall { margin: 0; }
.paywall h2 { font-size: 24px; margin-bottom: 6px; }
.paywall__icon { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px; background: var(--violet-tint); color: var(--violet-soft); margin-bottom: 14px; }
.paywall__price { font-family: var(--font-display); font-weight: 800; font-size: 24px; color: var(--ink); margin: 0 0 14px; line-height: 1.15; }
.paywall__form { margin: 0; }
.paywall__aside { display: flex; gap: 10px; align-items: flex-start; margin: 0; padding-top: 16px; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.paywall__aside .ic { color: var(--violet-soft); margin-top: 2px; }

/* ---- lesson page and player ------------------------------------------------------------------- */
.lesson-page { padding-top: 20px; }
.lesson-layout { display: grid; gap: 24px; align-items: start; }
.lesson-layout__stage { min-width: 0; width: 100%; max-width: 440px; margin-inline: auto; }
.lesson-layout__info { min-width: 0; }
.lesson-kicker { display: flex; flex-wrap: wrap; gap: 8px 10px; align-items: center; margin: 0 0 8px; font-size: 14px; color: var(--muted); }
.lesson-title { font-size: clamp(26px, 4vw, 36px); margin-bottom: 10px; }
.lesson-summary { font-size: 17px; }
.mini-lessons { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.mini-lessons a { display: flex; gap: 12px; align-items: center; padding: 8px 10px; border-radius: var(--r-btn); color: var(--body); text-decoration: none; font-size: 15px; }
.mini-lessons a:hover { background: var(--deep); color: var(--ink); }
.mini-lessons .is-current a { background: var(--deep); color: var(--ink); box-shadow: inset 2px 0 0 var(--violet); }
html[dir="rtl"] .mini-lessons .is-current a { box-shadow: inset -2px 0 0 var(--violet); }
.mini-lessons__state { width: 26px; height: 26px; flex: none; display: grid; place-items: center; border-radius: 50%; background: var(--deep-2); font-size: 13px; font-weight: 700; color: var(--muted); }
.mini-lessons__state .ic { width: 15px; height: 15px; }
.mini-lessons__state.is-done { color: var(--ok); }
.mini-lessons__title { min-width: 0; }

.player { display: grid; gap: 10px; }
.stage {
  position: relative; width: 100%; aspect-ratio: 9 / 16; overflow: hidden; border-radius: var(--r-media);
  background: var(--night-2); border: 1px solid var(--line); container-type: inline-size; isolation: isolate;
}
.stage:focus-visible { outline: 2px solid var(--violet); outline-offset: 3px; }
.stage__backdrop { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.stage__backdrop::before {
  content: ""; position: absolute; inset: -10%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22'%3E%3Ccircle cx='2' cy='2' r='1.1' fill='%2325263B'/%3E%3C/svg%3E");
  animation: drift 40s linear infinite;
}
.stage__backdrop span {
  position: absolute; left: 50%; top: 40%; width: 70%; aspect-ratio: 1; border-radius: 50%;
  border: 1px solid rgba(123, 110, 240, .16); transform: translate(-50%, -50%) scale(.6); animation: breathe 9s var(--ease) infinite;
}
.stage__backdrop span:nth-child(2) { width: 105%; animation-delay: -3s; border-color: rgba(123, 110, 240, .1); }
.stage__backdrop span:nth-child(3) { width: 140%; animation-delay: -6s; border-color: rgba(123, 110, 240, .07); }
@keyframes drift { to { transform: translate(22px, 22px); } }
@keyframes breathe { 0%, 100% { transform: translate(-50%, -50%) scale(.82); opacity: .7; } 50% { transform: translate(-50%, -50%) scale(1); opacity: 1; } }
.stage__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 1; background: #000; }
.stage__visual { position: absolute; inset: 0 0 34% 0; z-index: 2; display: grid; place-items: center; padding: 8%; }
.stage--video .stage__visual { display: none; }
.stage__caption {
  position: absolute; inset-inline: 6%; bottom: 6%; z-index: 3; padding: .55em .7em; border-radius: 10px;
  background: rgba(7, 7, 15, .78); border: 1px solid rgba(255, 255, 255, .06); color: #fff;
  font-family: var(--font-body); font-weight: 600; font-size: 20px; font-size: clamp(16px, 6.2cqi, 26px); line-height: 1.35;
  text-align: center; text-wrap: balance; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  transition: opacity var(--t-mid) var(--ease), transform var(--t-mid) var(--ease);
}
html[lang="ar"] .stage__caption { line-height: 1.6; }
.stage__caption:empty { opacity: 0; }
.stage__caption.is-swap { opacity: 0; transform: translateY(6px); }
.stage__start {
  position: absolute; inset: 0; z-index: 4; display: grid; place-content: center; justify-items: center; gap: 12px; border: 0;
  background: rgba(7, 7, 15, .72); color: var(--ink); font: inherit; font-weight: 600; font-size: 17px; cursor: pointer;
  backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px);
}
.stage__start .ic {
  width: 72px; height: 72px; padding: 20px; border-radius: 50%; background: var(--violet); color: var(--on-violet);
  box-shadow: 0 0 0 10px rgba(123, 110, 240, .18); transition: transform var(--t-fast) var(--ease);
}
.stage__start:hover .ic { transform: scale(1.05); }
.stage__start:focus-visible { outline: 2px solid var(--violet); outline-offset: -4px; }
.stage.is-playing .stage__start, .stage.is-started .stage__start { display: none; }
.stage__dots { position: absolute; top: 14px; inset-inline: 14px; z-index: 3; display: flex; gap: 4px; }
.stage__dots span { flex: 1; height: 3px; border-radius: 2px; background: rgba(255, 255, 255, .18); }
.stage__dots span.is-on { background: var(--violet-soft); }
.stage--locked { display: grid; place-items: center; aspect-ratio: 4 / 5; }
.stage__locked { position: relative; z-index: 2; display: grid; justify-items: center; gap: 14px; padding: 24px; text-align: center; color: var(--ink); font-weight: 600; }
.stage__lock { width: 64px; height: 64px; display: grid; place-items: center; border-radius: 50%; background: var(--deep-2); border: 1px solid var(--line-strong); color: var(--violet-soft); }
.stage__lock .ic { width: 28px; height: 28px; }

.player__bar { display: flex; align-items: center; gap: 8px; }
.pbtn {
  width: 44px; height: 44px; flex: none; display: grid; place-items: center; border-radius: var(--r-btn);
  background: var(--btn-2); border: 1px solid var(--line-strong); color: var(--ink); cursor: pointer;
}
.pbtn:hover { filter: brightness(1.15); }
.pbtn .ic { width: 22px; height: 22px; }
.pbtn .ic--pause, .is-playing-bar .pbtn .ic--play { display: none; }
.is-playing-bar .pbtn .ic--pause { display: block; }
.segments { flex: 1; min-width: 0; display: flex; gap: 3px; height: 28px; align-items: center; cursor: pointer; }
.seg { position: relative; flex: 1 1 0; height: 6px; border-radius: 3px; background: var(--deep-2); overflow: hidden; border: 0; padding: 0; }
.seg.is-ahead { opacity: .4; }
.seg__fill { position: absolute; inset-block: 0; inset-inline-start: 0; width: 0; background: var(--violet); border-radius: 3px; }
.seg.is-current { height: 8px; }
.player__time { min-width: 76px; text-align: end; font-size: 14px; color: var(--muted); }
.player__hint { margin: 0; min-height: 1.4em; }
.transcript { margin-top: 14px; border: 1px solid var(--line); border-radius: var(--r-card); background: var(--deep); }
.transcript summary { display: flex; gap: 10px; align-items: center; padding: 12px 14px; cursor: pointer; list-style: none; color: var(--ink); font-weight: 600; font-size: 15px; }
.transcript summary::-webkit-details-marker { display: none; }
.transcript summary .faq__chev { margin-inline-start: auto; }
.transcript ol { margin: 0; padding: 0 16px 14px 34px; padding-inline: 34px 16px; display: grid; gap: 6px; font-size: 15px; }

/* scene visuals (drawn by player.js from scenes[].visual) */
.v { position: relative; display: grid; place-items: center; width: 100%; height: 100%; animation: v-in var(--t-slow) var(--ease) both; }
@keyframes v-in { from { opacity: 0; transform: translateY(10px) scale(.97); } to { opacity: 1; transform: none; } }
.v svg.vi { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; width: 56%; height: auto; }
.v-tile {
  position: relative; width: 50cqi; aspect-ratio: 1; display: grid; place-items: center; border-radius: 22%;
  background: var(--deep-2); border: 1px solid var(--line-strong); color: var(--violet-soft); box-shadow: 0 20px 50px rgba(0, 0, 0, .4);
}
.v-tile--accent { background: var(--violet); border-color: var(--violet); color: var(--on-violet); }
.v-tile--good { color: var(--ok); border-color: rgba(52, 211, 153, .45); }
.v-tile--bad { color: var(--bad); border-color: rgba(248, 113, 113, .45); }
.v-tile--warn { color: var(--warn); border-color: rgba(251, 191, 36, .45); }
.v-tile--sm { width: 24cqi; border-radius: 24%; }
.v-tile--md { width: 32cqi; }
.v-badge {
  position: absolute; inset-inline-end: -8%; top: -8%; width: 34%; aspect-ratio: 1; display: grid; place-items: center; border-radius: 50%;
  background: var(--ok); color: var(--on-violet); border: 3px solid var(--night-2); animation: pop var(--t-slow) var(--ease) .5s both;
}
.v-badge--bad { background: var(--bad); }
.v-badge svg { width: 62%; height: auto; fill: none; stroke: currentColor; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
@keyframes pop { from { opacity: 0; transform: scale(.3); } 70% { transform: scale(1.12); } to { opacity: 1; transform: scale(1); } }
.v-intro .v-tile { width: 46cqi; }
.v-pulse { position: absolute; width: 46cqi; aspect-ratio: 1; border-radius: 22%; border: 2px solid var(--violet); animation: pulse 2.4s var(--ease) infinite; }
.v-pulse:nth-child(2) { animation-delay: 1.2s; }
@keyframes pulse { from { transform: scale(1); opacity: .7; } to { transform: scale(1.6); opacity: 0; } }
.v-pair { display: flex; align-items: center; justify-content: center; gap: 4cqi; }
.v-pair .v-tile { width: 34cqi; }
.v-pair__link { width: 10cqi; flex: none; display: grid; place-items: center; color: var(--violet-soft); }
.v-pair__link svg { width: 100%; height: auto; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.v-pair--vs .v-tile:first-child { opacity: .6; filter: grayscale(.5); }
.v-pair > :last-child { animation: v-in var(--t-slow) var(--ease) .35s both; }
.v-steps { display: flex; align-items: center; justify-content: center; gap: 2.5cqi; flex-wrap: nowrap; }
.v-steps .v-tile { width: 23cqi; border-radius: 26%; opacity: .35; animation: step-on 3.6s var(--ease) infinite; }
.v-steps .v-tile:nth-of-type(2) { animation-delay: .9s; }
.v-steps .v-tile:nth-of-type(3) { animation-delay: 1.8s; }
.v-steps .v-tile:nth-of-type(4) { animation-delay: 2.7s; }
.v-steps--4 .v-tile { width: 17cqi; }
.v-steps__arrow { width: 5cqi; flex: none; color: var(--input-line); }
.v-steps__arrow svg { width: 100%; height: auto; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
html[dir="rtl"] .v-steps__arrow svg { transform: scaleX(-1); }
@keyframes step-on { 0% { opacity: .35; border-color: var(--line-strong); } 15%, 70% { opacity: 1; border-color: var(--violet); color: var(--ink); } 100% { opacity: .35; } }
.v-phone {
  position: relative; width: 48cqi; aspect-ratio: 9 / 17; border-radius: 6cqi; border: 2px solid var(--line-strong);
  background: var(--deep); overflow: hidden; box-shadow: 0 24px 60px rgba(0, 0, 0, .45);
}
.v-phone__live {
  position: absolute; top: 5cqi; inset-inline-start: 4cqi; padding: .5cqi 2cqi; border-radius: 1.4cqi;
  background: var(--bad); color: #fff; font: 800 3.2cqi/1.4 var(--font-body); letter-spacing: .04em;
}
.v-phone__face { position: absolute; left: 50%; top: 36%; width: 18cqi; aspect-ratio: 1; border-radius: 50%; background: var(--deep-2); transform: translate(-50%, -50%); border: 2px solid var(--line-strong); }
.v-phone__face::after { content: ""; position: absolute; left: 50%; top: 118%; width: 30cqi; height: 16cqi; border-radius: 15cqi 15cqi 0 0; background: var(--deep-2); transform: translateX(-50%); border: 2px solid var(--line-strong); }
.v-phone__fx { position: absolute; inset: 0; }
.v-float { position: absolute; bottom: 8%; inset-inline-end: 10%; width: 10cqi; color: var(--bad); animation: float-up 2.8s ease-in infinite; opacity: 0; }
.v-float svg { width: 100%; height: auto; fill: none; stroke: currentColor; stroke-width: 2.4; }
.v-float:nth-child(2) { inset-inline-end: 20%; animation-delay: .7s; }
.v-float:nth-child(3) { inset-inline-end: 6%; animation-delay: 1.4s; }
.v-float:nth-child(4) { inset-inline-end: 16%; animation-delay: 2.1s; }
.v-float--gift { color: var(--warn); }
@keyframes float-up { 0% { opacity: 0; transform: translateY(0) scale(.7); } 15% { opacity: 1; } 100% { opacity: 0; transform: translateY(-34cqi) scale(1.1); } }
.v-lines { position: absolute; inset-inline: 6%; bottom: 7%; display: grid; gap: 1.6cqi; }
.v-lines span { display: block; height: 3cqi; border-radius: 2cqi; background: rgba(255, 255, 255, .14); width: 70%; animation: v-in var(--t-slow) var(--ease) both; }
.v-lines span:nth-child(2) { width: 52%; animation-delay: .5s; }
.v-lines span:nth-child(3) { width: 62%; animation-delay: 1s; }
.v-eyes { position: absolute; top: 5cqi; inset-inline-end: 4cqi; display: flex; gap: 1cqi; align-items: center; padding: .5cqi 1.6cqi; border-radius: 1.4cqi; background: rgba(0, 0, 0, .4); color: #fff; }
.v-eyes svg { width: 7cqi; height: 7cqi; flex: none; fill: none; stroke: currentColor; stroke-width: 2.4; }
.v-eyes b { font: 700 3cqi/1.4 var(--font-body); color: #fff; display: inline-flex; }
.v-eyes b::after { content: ""; display: inline-block; width: 9cqi; height: 2.6cqi; border-radius: 1cqi; background: rgba(255, 255, 255, .5); vertical-align: middle; animation: grow-x 2.4s var(--ease) infinite alternate; transform-origin: left; }
@keyframes grow-x { from { transform: scaleX(.4); } to { transform: scaleX(1); } }
.v-match { position: absolute; top: 14cqi; inset-inline: 4cqi; height: 3.4cqi; border-radius: 2cqi; overflow: hidden; display: flex; background: var(--bad); }
.v-match span { display: block; height: 100%; background: var(--violet); width: 50%; animation: tug 3s var(--ease) infinite alternate; }
@keyframes tug { from { width: 38%; } to { width: 66%; } }
.v-bell { position: absolute; left: 50%; top: 66%; width: 12cqi; transform: translateX(-50%); color: var(--warn); animation: ring-bell 1.2s ease-in-out infinite; }
.v-bell svg { width: 100%; height: auto; fill: none; stroke: currentColor; stroke-width: 2.2; }
@keyframes ring-bell { 0%, 100% { transform: translateX(-50%) rotate(0); } 25% { transform: translateX(-50%) rotate(14deg); } 75% { transform: translateX(-50%) rotate(-14deg); } }
.v-glow { position: absolute; top: 9%; inset-inline-end: 12%; width: 22%; aspect-ratio: 1; border-radius: 50%; background: #FFE9B0; box-shadow: 0 0 0 4cqi rgba(255, 233, 176, .12), 0 0 12cqi 6cqi rgba(255, 233, 176, .22); animation: breathe-glow 3s ease-in-out infinite; }
@keyframes breathe-glow { 50% { box-shadow: 0 0 0 6cqi rgba(255, 233, 176, .16), 0 0 16cqi 9cqi rgba(255, 233, 176, .3); } }
.v-ring { position: relative; width: 52cqi; aspect-ratio: 1; display: grid; place-items: center; }
.v-ring > svg.v-ring__track { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
html[dir="rtl"] .v-ring > svg.v-ring__track { transform: rotate(-90deg) scaleY(-1); }
.v-ring circle { fill: none; stroke-width: 6; }
.v-ring .v-ring__bg { stroke: var(--deep-2); }
.v-ring .v-ring__fg { stroke: var(--violet); stroke-linecap: round; stroke-dasharray: 289; stroke-dashoffset: 289; animation: fill-ring 3.2s var(--ease) .2s forwards; }
@keyframes fill-ring { to { stroke-dashoffset: 18; } }
.v-ring .v-tile { width: 30cqi; border-radius: 50%; }
.v-clock { position: relative; width: 50cqi; aspect-ratio: 1; }
.v-clock svg { width: 100%; height: 100%; display: block; }
.v-clock__face { fill: var(--deep-2); stroke: var(--line-strong); stroke-width: 2; }
.v-clock__tick { stroke: var(--input-line); stroke-width: 2; stroke-linecap: round; }
.v-clock__sweep { fill: none; stroke: var(--violet); stroke-width: 16; opacity: .55; stroke-dasharray: 0 999; animation: sweep 2.6s var(--ease) .2s forwards; }
@keyframes sweep { to { stroke-dasharray: var(--sweep, 100) 999; } }
.v-clock__hand { stroke: var(--ink); stroke-width: 4; stroke-linecap: round; transform-origin: 60px 60px; animation: hand 2.6s var(--ease) .2s forwards; }
@keyframes hand { from { transform: rotate(0deg); } to { transform: rotate(var(--turn, 90deg)); } }
.v-clock__label { position: absolute; inset-inline: 0; bottom: -12cqi; text-align: center; font: 800 6cqi/1 var(--font-display); color: var(--ink); }
.v-week { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2cqi; width: 86cqi; }
.v-week span {
  aspect-ratio: 3 / 4; display: grid; place-items: center; border-radius: 2.4cqi; background: var(--deep-2); border: 1px solid var(--line);
  color: var(--muted); font: 700 4.6cqi/1 var(--font-body); animation: v-in var(--t-slow) var(--ease) both;
}
.v-week span.is-on { background: var(--violet); border-color: var(--violet); color: var(--on-violet); animation: pop var(--t-slow) var(--ease) both; }
.v-week span:nth-child(2) { animation-delay: .08s; } .v-week span:nth-child(3) { animation-delay: .16s; }
.v-week span:nth-child(4) { animation-delay: .24s; } .v-week span:nth-child(5) { animation-delay: .32s; }
.v-week span:nth-child(6) { animation-delay: .4s; } .v-week span:nth-child(7) { animation-delay: .48s; }
.v-chart { display: flex; align-items: flex-end; gap: 3cqi; width: 70cqi; height: 50cqi; padding-bottom: 2px; border-bottom: 2px solid var(--line-strong); }
.v-chart span { flex: 1; border-radius: 1.6cqi 1.6cqi 0 0; background: var(--deep-2); border: 1px solid var(--line-strong); border-bottom: 0; transform-origin: bottom; animation: bar 1s var(--ease) both; }
.v-chart span:nth-child(2) { animation-delay: .12s; } .v-chart span:nth-child(3) { animation-delay: .24s; }
.v-chart span:nth-child(4) { animation-delay: .36s; } .v-chart span:nth-child(5) { animation-delay: .48s; }
.v-chart span:last-child { background: var(--violet); border-color: var(--violet); }
.v-chart--up span:nth-child(1) { height: 22%; } .v-chart--up span:nth-child(2) { height: 36%; } .v-chart--up span:nth-child(3) { height: 50%; }
.v-chart--up span:nth-child(4) { height: 70%; } .v-chart--up span:nth-child(5) { height: 92%; }
.v-chart--down span:nth-child(1) { height: 90%; } .v-chart--down span:nth-child(2) { height: 72%; } .v-chart--down span:nth-child(3) { height: 54%; }
.v-chart--down span:nth-child(4) { height: 38%; } .v-chart--down span:nth-child(5) { height: 22%; background: var(--bad); border-color: var(--bad); }
.v-chart--steady span { height: 56%; } .v-chart--steady span:nth-child(2n) { height: 62%; }
@keyframes bar { from { transform: scaleY(0); } to { transform: scaleY(1); } }
.v-chat { display: grid; gap: 3cqi; width: 78cqi; }
.v-bubble { display: flex; align-items: center; gap: 2.4cqi; animation: v-in var(--t-slow) var(--ease) both; }
.v-bubble i { width: 9cqi; aspect-ratio: 1; border-radius: 50%; background: var(--deep-2); border: 1px solid var(--line-strong); flex: none; }
.v-bubble b { display: block; height: 9cqi; border-radius: 4cqi; background: var(--deep-2); border: 1px solid var(--line-strong); width: 56cqi; }
.v-bubble:nth-child(2) { flex-direction: row-reverse; animation-delay: .6s; }
.v-bubble:nth-child(2) b { background: var(--violet); border-color: var(--violet); width: 46cqi; }
.v-bubble:nth-child(3) { animation-delay: 1.2s; }
.v-bubble:nth-child(3) b { width: 38cqi; }
.v-outro { position: relative; }
.v-outro .v-tile { border-radius: 50%; background: var(--ok); border-color: var(--ok); color: var(--on-violet); animation: pop .6s var(--ease) both; }
.v-spark { position: absolute; width: 3cqi; aspect-ratio: 1; border-radius: 1cqi; background: var(--violet-soft); animation: spark 1.6s var(--ease) .3s both; }
.v-spark:nth-child(odd) { background: var(--ok); }
@keyframes spark { from { transform: translate(0, 0) scale(0); opacity: 1; } to { transform: translate(var(--dx, 20cqi), var(--dy, -20cqi)) scale(1); opacity: 0; } }

/* after the video: takeaways, quiz, completion */
.after { margin-top: 40px; padding-top: 32px; border-top: 1px solid var(--line); }
.after__wait { display: none; gap: 10px; align-items: center; color: var(--muted); margin: 0 0 20px; }
.js .after.is-waiting .after__wait { display: flex; }
.js .after.is-waiting .after__grid { opacity: .35; pointer-events: none; filter: blur(2px); user-select: none; }
.after__grid { display: grid; gap: 32px; transition: opacity var(--t-slow) var(--ease), filter var(--t-slow) var(--ease); }
.takeaways h2, .quiz h2 { font-size: 26px; }
.quiz__form { display: grid; gap: 18px; }
.q { margin: 0; padding: 18px 16px; border: 1px solid var(--line); border-radius: var(--r-card); background: var(--deep); min-width: 0; }
.q legend { float: inline-start; width: 100%; display: flex; gap: 12px; align-items: baseline; margin: 0 0 14px; padding: 0; color: var(--ink); font-weight: 600; font-size: 17px; line-height: 1.45; }
.q legend + * { clear: both; }
.q__n { flex: none; width: 28px; height: 28px; display: inline-grid; place-items: center; border-radius: 50%; background: var(--deep-2); color: var(--violet-soft); font-size: 14px; font-weight: 700; }
.q__opt {
  display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; margin-top: 8px; border-radius: var(--r-btn);
  border: 1px solid var(--line-strong); background: var(--field); color: var(--body); cursor: pointer; transition: border-color var(--t-fast) var(--ease), background var(--t-fast) var(--ease);
}
.q__opt:hover { border-color: #4A4B72; }
.q__opt input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--violet); flex: none; }
.q__opt:has(input:checked) { border-color: var(--violet); background: var(--violet-tint); color: var(--ink); }
.q__opt:has(input:focus-visible) { outline: 2px solid var(--violet); outline-offset: 2px; }
.q.is-right { border-color: rgba(52, 211, 153, .5); }
.q.is-wrong { border-color: rgba(248, 113, 113, .5); }
.q.is-right .q__opt:has(input:checked) { border-color: var(--ok); background: rgba(52, 211, 153, .08); }
.q.is-wrong .q__opt:has(input:checked) { border-color: var(--bad); background: rgba(248, 113, 113, .07); }
.q__result { display: flex; gap: 10px; align-items: flex-start; margin: 14px 0 0; font-size: 15px; }
.q__result .ic { margin-top: 3px; }
.q.is-right .q__result .ic { color: var(--ok); }
.q.is-wrong .q__result .ic { color: var(--bad); }
.quiz__actions { display: flex; flex-wrap: wrap; gap: 12px 16px; align-items: center; }
.quiz__msg { margin: 0; font-weight: 600; color: var(--ink); }
.done-panel {
  display: grid; gap: 16px; align-items: center; margin-top: 32px; padding: 22px 20px; border-radius: var(--r-media);
  background: var(--deep); border: 1px solid rgba(52, 211, 153, .45); animation: v-in var(--t-slow) var(--ease) both;
}
.done-panel h2 { font-size: 24px; margin-bottom: 4px; }
.done-panel p { margin: 0; }
.done-panel__icon { width: 52px; height: 52px; display: grid; place-items: center; border-radius: 50%; background: rgba(52, 211, 153, .12); color: var(--ok); }
.done-panel__icon .ic { width: 28px; height: 28px; }
.celebrate {
  position: relative; overflow: hidden; display: grid; justify-items: center; gap: 8px; margin-top: 24px; padding: 40px 20px;
  text-align: center; border-radius: var(--r-media); background: var(--deep); border: 1px solid var(--violet-line);
}
.celebrate h2 { font-size: clamp(28px, 5vw, 40px); margin: 8px 0 4px; }
.celebrate p { max-width: 46ch; font-size: 17px; }
.celebrate__icon { width: 76px; height: 76px; display: grid; place-items: center; border-radius: 50%; background: var(--violet); color: var(--on-violet); animation: pop .7s var(--ease) both; }
.celebrate__icon .ic { width: 40px; height: 40px; }
.celebrate__burst { position: absolute; inset: 0; pointer-events: none; }
.celebrate__burst span { position: absolute; top: -12px; width: 8px; height: 14px; border-radius: 2px; background: var(--violet-soft); animation: confetti 2.8s linear both; }
.celebrate__burst span:nth-child(3n) { background: var(--ok); }
.celebrate__burst span:nth-child(4n) { background: var(--warn); width: 10px; height: 10px; border-radius: 50%; }
.celebrate__burst span:nth-child(1) { left: 6%; animation-delay: .05s; } .celebrate__burst span:nth-child(2) { left: 14%; animation-delay: .4s; }
.celebrate__burst span:nth-child(3) { left: 22%; animation-delay: .15s; } .celebrate__burst span:nth-child(4) { left: 30%; animation-delay: .6s; }
.celebrate__burst span:nth-child(5) { left: 38%; animation-delay: .25s; } .celebrate__burst span:nth-child(6) { left: 46%; animation-delay: .75s; }
.celebrate__burst span:nth-child(7) { left: 54%; animation-delay: .1s; } .celebrate__burst span:nth-child(8) { left: 62%; animation-delay: .5s; }
.celebrate__burst span:nth-child(9) { left: 70%; animation-delay: .3s; } .celebrate__burst span:nth-child(10) { left: 78%; animation-delay: .7s; }
.celebrate__burst span:nth-child(11) { left: 86%; animation-delay: .2s; } .celebrate__burst span:nth-child(12) { left: 94%; animation-delay: .55s; }
.celebrate__burst span:nth-child(13) { left: 10%; animation-delay: .9s; } .celebrate__burst span:nth-child(14) { left: 90%; animation-delay: 1s; }
@keyframes confetti { from { transform: translateY(0) rotate(0); opacity: 1; } to { transform: translateY(420px) rotate(540deg); opacity: 0; } }

/* ---- auth pages --------------------------------------------------------------------------- */
.auth { display: grid; place-items: start center; gap: 32px; padding: 40px var(--gutter) 24px; }
.auth__card { width: 100%; max-width: 460px; background: var(--deep); border: 1px solid var(--line); border-radius: var(--r-media); padding: 28px 20px; }
.auth__card h1 { font-size: 30px; }
.auth__alt { text-align: center; margin: 18px 0 0; font-size: 15px; }
.auth__note { display: flex; gap: 10px; align-items: flex-start; margin: 18px 0 0; padding-top: 16px; border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; }
.auth__note .ic { color: var(--violet-soft); margin-top: 2px; }
.auth__icon { display: inline-grid; place-items: center; width: 48px; height: 48px; border-radius: 12px; background: var(--deep-2); border: 1px solid var(--line-strong); color: var(--violet-soft); margin-bottom: 16px; }
.auth__side { width: 100%; max-width: 460px; }
.auth__side-title { font-size: clamp(22px, 3vw, 28px); margin-bottom: 20px; }
.auth__side-note { display: flex; gap: 10px; align-items: flex-start; margin: 24px 0 0; padding-top: 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; }
.auth__side-note .ic { color: var(--violet-soft); margin-top: 2px; }
.error-code { font-family: var(--font-display); font-weight: 800; font-size: 44px; color: var(--violet-soft); margin: 0 0 4px; }

/* ---- legal -------------------------------------------------------------------------------- */
.legal { padding-block: 40px 16px; }
.legal h1 { margin-bottom: 8px; }
.legal__meta { color: var(--muted); font-size: 14px; }
.legal h2 { margin-top: 36px; font-size: 22px; }
.legal li { margin-bottom: 6px; }

/* ---- account ------------------------------------------------------------------------------ */
.account-layout { display: grid; gap: 16px; align-items: start; padding-top: 16px; }
.account-nav { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; }
.account-nav a { display: inline-flex; gap: 8px; align-items: center; padding: 8px 12px; border-radius: var(--r-btn); color: var(--body); text-decoration: none; white-space: nowrap; font-size: 15px; border: 1px solid var(--line); }
.account-nav a:hover { color: var(--ink); background: var(--deep); }
.account-nav .ic { color: var(--muted); }
.account-body { min-width: 0; }

/* ---- breakpoints -------------------------------------------------------------------------- */
@media (max-width: 479px) {
  .hide-xs { display: none !important; }
  .course-row { grid-template-columns: auto minmax(0, 1fr); }
  .course-row__go { display: none; }
  .course-row__icon { width: 42px; height: 42px; }
  .player__time { min-width: 0; }
}
@media (min-width: 560px) {
  .form__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .field--full { grid-column: 1 / -1; }
  .auth__card { padding: 36px; }
  .done-panel { grid-template-columns: auto minmax(0, 1fr) auto; padding: 24px 28px; }
  .form--split { grid-template-columns: minmax(0, 1fr) auto; }
  .q { padding: 22px 22px; }
}
@media (min-width: 720px) {
  :root { --gutter: 24px; }
  .section { padding: 88px 0; }
  .panel { padding: 24px; }
  .course-row { padding: 22px 22px; gap: 20px; }
  .pricing { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
  .pricing__plan, .pricing__creators { padding: 36px; }
  .site-footer__inner { grid-template-columns: minmax(0, 2fr) repeat(3, minmax(0, 1fr)); }
  .paywall { padding: 28px; }
}
@media (min-width: 1024px) {
  :root { --gutter: 40px; }
  .hide-lg { display: none !important; }
  .site-nav { display: flex; }
  .hero { padding: 64px 0 88px; }
  .hero__grid { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 56px; }
  .phone { width: 320px; }
  .course-list--grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .flow { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; }
  .flow__step { grid-template-columns: 1fr; padding: 0; }
  .flow__step::before { inset-inline-start: 64px; inset-inline-end: -24px; top: 25px; bottom: auto; width: auto; height: 2px; }
  .flow__icon { grid-row: auto; margin-bottom: 18px; }
  .faq-wrap { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 64px; align-items: start; }
  .course-body { grid-template-columns: minmax(0, 1fr) 360px; gap: 48px; }
  .course-body__side { position: sticky; top: 88px; }
  .lesson-layout { grid-template-columns: minmax(0, auto) minmax(0, 1fr); gap: 48px; }
  .lesson-layout__stage { width: min(420px, calc((100vh - 230px) * 9 / 16)); min-width: 300px; margin: 0; }
  .after__grid { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 48px; }
  .account-layout { grid-template-columns: 220px minmax(0, 1fr); gap: 32px; }
  .account-layout--single { grid-template-columns: minmax(0, 760px); }
  .account-nav { position: sticky; top: 88px; flex-direction: column; overflow: visible; }
  .account-nav a { border: 0; }
  .auth--split { grid-template-columns: 460px 400px; justify-content: center; gap: 56px; place-items: start; }
  .auth__side { padding-top: 40px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; animation-delay: 0s !important; transition-duration: 1ms !important; scroll-behavior: auto !important; }
  .celebrate__burst { display: none; }
}
