/* KaroVox v5 "cosmos" design layer. Loaded after style.css (and scenes.css) on every page: it redefines the design
   tokens and restyles the shared components, and adds the landing / Mini App building blocks (x-*). No logic here.
   Palette: deep space (near black with violet-blue), neon pink as the brand, cold violet + teal as the second accent,
   glass, thin lines, glow. Light theme: cold white / ice grey with the same neon accents. No warm browns or creams
   anywhere (test/v5-cosmos.test.mjs). Type: Geologica (display) + Onest (interface) + JetBrains Mono (numbers, codes).
   Theme: dark by default; the visitor's choice (ui.js themeToggle -> <html data-theme>) wins; in Telegram its theme. */

/* ============ 1. tokens ============ */
:root {
  /* brand constants (same in both themes) */
  --pink: #ff2e7e;
  --pink-2: #ff4fa3;
  --pink-deep: #d6176a;
  --violet: #7c5cff;
  --violet-2: #a28bff;
  --cyan: #28e0d0;
  --wine: #3a1f8f;
  --cog: #7c5cff;
  --cog-2: #28e0d0;
  --cog-deep: #1a1650;
  --grad: linear-gradient(100deg, #ff2e7e 0%, #e23aa6 40%, #a24bf0 70%, #7c5cff 100%);
  --grad-cool: linear-gradient(100deg, #7c5cff 0%, #28e0d0 100%);
  --grad-text: linear-gradient(100deg, #ff4fa3 0%, #ff2e7e 35%, #a28bff 100%);
  --grad-btn: linear-gradient(110deg, #ff2e7e 0%, #e2328f 45%, #9a4cf2 100%);
  --grad-btn-hover: linear-gradient(110deg, #ff4f93 0%, #ea45a0 45%, #a660ff 100%);
  --grad-btn-press: linear-gradient(110deg, #e01a6a 0%, #c42a80 45%, #8440e0 100%);
  --tile: linear-gradient(140deg, #ff2e7e 0%, #b23ad8 55%, #7c5cff 100%);
  --glow: 0 0 0 1px rgba(255, 46, 126, 0.35), 0 10px 40px -8px rgba(255, 46, 126, 0.55), 0 0 60px -10px rgba(124, 92, 255, 0.45);
  --ease: cubic-bezier(0.2, 0, 0, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --radius: 18px;
  --radius-s: 14px;
  --radius-l: 26px;
  --font: "Onest", "Onest Fallback", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --display: "Geologica", "Onest", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", "Cascadia Mono", Consolas, "Liberation Mono", monospace;
  --fs-cap: 11.5px;
  --tr-caps: 0.18em;
  --tr-display: -0.035em;
  --tr-head: -0.03em;
  --lh-display: 1.02;
  --lh-head: 1.1;
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --gutter: max(16px, env(safe-area-inset-left), env(safe-area-inset-right));

  /* LIGHT = cold white / ice grey (the visitor's choice; never cream) */
  --bg: #f4f6fb;
  --bg-2: #eaeef7;
  --bg-deep: #dfe5f2;
  --surface: #ffffff;
  --surface-2: #eef1f8;
  --card: #ffffff;
  --glass: rgba(255, 255, 255, 0.72);
  --text: #0b0d1a;
  --text-soft: #2a2f45;
  --muted: #555b74;
  --line: rgba(20, 26, 60, 0.1);
  --line-strong: rgba(20, 26, 60, 0.2);
  --edge: linear-gradient(160deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.3) 45%, rgba(124, 92, 255, 0.35));
  --accent: #e0156a;
  --accent-hover: #f0207a;
  --accent-pressed: #b8105a;
  --accent-text: #ffffff;
  --accent-soft: rgba(224, 21, 106, 0.09);
  --eyebrow: #5a3fd6;
  --ok: #0f7a52;
  --ok-soft: rgba(15, 122, 82, 0.1);
  --danger: #c4202e;
  --danger-text: #ffffff;
  --danger-soft: rgba(196, 32, 46, 0.09);
  --focus: #5a3fd6;
  --me: #e9ecfb;
  --peer: #ffffff;
  --banner: #e8e4ff;
  --banner-text: #2c1f80;
  --scrim: rgba(8, 10, 30, 0.45);
  --shadow: 0 24px 60px -28px rgba(30, 36, 90, 0.35);
  --shadow-s: 0 10px 28px -16px rgba(30, 36, 90, 0.3);
  --star: rgba(40, 50, 110, 0.35);
  --page-glow:
    radial-gradient(70% 45% at 10% -8%, rgba(255, 46, 126, 0.1), transparent 62%),
    radial-gradient(70% 50% at 100% 20%, rgba(124, 92, 255, 0.14), transparent 65%),
    radial-gradient(80% 50% at 30% 110%, rgba(40, 224, 208, 0.1), transparent 60%),
    linear-gradient(180deg, #f7f9fd 0%, #f2f5fb 55%, #edf1f9 100%);
  color-scheme: light;
}
/* DARK = deep space (the default look) */
:root:not([data-theme="light"]), :root[data-theme="dark"], .x-night {
  --bg: #05060f;
  --bg-2: #0b0d24;
  --bg-deep: #030409;
  --surface: #0e1030;
  --surface-2: #161840;
  --card: #0c0e28;
  --glass: rgba(16, 18, 52, 0.55);
  --text: #f3f4ff;
  --text-soft: #d3d6f2;
  --muted: #9aa0c8;
  --line: rgba(160, 170, 255, 0.12);
  --line-strong: rgba(160, 170, 255, 0.24);
  --edge: linear-gradient(160deg, rgba(200, 190, 255, 0.35), rgba(255, 255, 255, 0.03) 45%, rgba(255, 46, 126, 0.3));
  --accent: #ff2e7e;
  --accent-hover: #ff4f93;
  --accent-pressed: #e01a6a;
  --accent-text: #ffffff;
  --accent-soft: rgba(255, 46, 126, 0.14);
  --eyebrow: #a28bff;
  --ok: #3de3a0;
  --ok-soft: rgba(61, 227, 160, 0.14);
  --danger: #ff5a6e;
  --danger-text: #12030a;
  --danger-soft: rgba(255, 90, 110, 0.14);
  --focus: #a28bff;
  --me: #1a1c4a;
  --peer: #0e1030;
  --banner: #1d1650;
  --banner-text: #d9d0ff;
  --scrim: rgba(2, 3, 10, 0.7);
  --shadow: 0 30px 70px -30px rgba(0, 0, 0, 0.9);
  --shadow-s: 0 12px 30px -16px rgba(0, 0, 0, 0.85);
  --star: rgba(220, 225, 255, 0.85);
  --page-glow:
    radial-gradient(60% 40% at 85% -5%, rgba(124, 92, 255, 0.28), transparent 62%),
    radial-gradient(55% 35% at 0% 20%, rgba(255, 46, 126, 0.16), transparent 62%),
    radial-gradient(70% 45% at 50% 105%, rgba(40, 224, 208, 0.08), transparent 60%),
    linear-gradient(180deg, #05060f 0%, #0b0d24 55%, #141033 100%);
  color-scheme: dark;
}
.x-night { color: var(--text); }

/* ============ 2. page ============ */
html { background: var(--bg); }
body {
  background: var(--page-glow);
  background-color: var(--bg);
  background-attachment: fixed;
  min-height: 100vh;
  min-height: 100dvh;
  font-size: 16px;
  line-height: 1.55;
  letter-spacing: 0.002em;
  font-feature-settings: "kern" 1, "ss01" 1;
}
/* fine woven texture over the whole page: two offset dot lattices (no image, no request) */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.5;
  background:
    radial-gradient(rgba(237, 240, 248, 0.05) 0.6px, transparent 0.9px) 0 0 / 3px 3px,
    radial-gradient(rgba(0, 0, 0, 0.12) 0.6px, transparent 0.9px) 1px 2px / 5px 5px;
}
html[data-theme="light"] body::before { opacity: 0.35; }
::selection { background: rgba(255, 45, 125, 0.32); color: var(--text); }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: 10px; }

/* type */
h1, h2, .x-h1, .x-h2 { font-family: var(--display); font-weight: 600; letter-spacing: var(--tr-head); text-wrap: balance; }
h1 { font-size: clamp(34px, 9vw, 44px); line-height: 1.04; margin: 10px 0 12px; }
h2 { font-size: clamp(26px, 6.6vw, 32px); line-height: 1.08; margin: 22px 0 8px; }
h3 { font-family: var(--font); font-weight: 650; letter-spacing: -0.01em; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.mono, .num { font-family: var(--font); font-weight: 600; font-variant-numeric: tabular-nums lining-nums; letter-spacing: -0.01em; }
.t-caps, .x-eyebrow, .sec-title, .descriptor {
  font-family: var(--font);
  font-size: var(--fs-cap);
  font-weight: 650;
  letter-spacing: var(--tr-caps);
  text-transform: uppercase;
  color: var(--eyebrow);
}
.x-eyebrow { display: flex; align-items: center; gap: 12px; margin: 0 0 14px; line-height: 1.4; }
.x-eyebrow::before { content: ""; flex: none; width: 26px; height: 1px; background: currentColor; opacity: 0.8; }
.sec-title { margin: 30px 0 14px; display: flex; align-items: center; gap: 12px; }
.sec-title::before { content: ""; width: 26px; height: 1px; background: currentColor; opacity: 0.8; border-radius: 0; flex: none; }
.x-grad-text, .x-h1 em, h1 em {
  font-style: italic;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  padding-right: 0.06em;
}

/* ============ 3. buttons: depth, one primary per screen ============ */
.btn {
  position: relative;
  isolation: isolate;
  min-height: 56px;
  border-radius: 999px;
  border: 0;
  padding: 0 26px;
  font-family: var(--font);
  font-size: 16.5px;
  font-weight: 650;
  letter-spacing: 0.01em;
  color: #f8f9fd;
  background: var(--grad-btn);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.42),
    inset 0 -2px 0 rgba(32, 13, 77, 0.35),
    0 1px 0 rgba(0, 0, 0, 0.15),
    0 14px 34px -14px rgba(255, 45, 125, 0.75),
    0 4px 12px -6px rgba(43, 17, 103, 0.6);
  text-shadow: 0 1px 1px rgba(39, 15, 95, 0.35);
  transition: transform 0.18s var(--ease-out), box-shadow 0.2s var(--ease), filter 0.2s var(--ease), background 0.2s var(--ease);
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
/* glossy top light */
.btn::before {
  content: "";
  position: absolute;
  inset: 1px 1px 50% 1px;
  border-radius: 999px 999px 40% 40% / 999px 999px 18px 18px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.28), rgba(255, 255, 255, 0));
  pointer-events: none;
  z-index: -1;
}
.btn:hover:not(:disabled) { background: var(--grad-btn-hover); }
.btn:active:not(:disabled) {
  background: var(--grad-btn-press);
  transform: translateY(1px) scale(0.985);
  box-shadow: inset 0 2px 6px rgba(28, 11, 69, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.18), 0 6px 16px -10px rgba(255, 45, 125, 0.7);
}
.btn:focus-visible { outline: 0; box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px var(--cog-2), 0 14px 34px -14px rgba(255, 45, 125, 0.75); }
.btn:disabled { opacity: 0.45; filter: saturate(0.6); }
.btn.big { min-height: 60px; font-size: 17px; }
.btn.compact { min-height: 50px; padding: 0 20px; font-size: 15.5px; }
.btn svg { width: 21px; height: 21px; stroke-width: 1.8; }
/* secondary: thin outline on glass */
.btn.secondary, .btn.ghost, .btn.share:not(.lead), .btn.quiet {
  color: var(--text);
  background: transparent;
  box-shadow: inset 0 0 0 1px var(--line-strong);
  text-shadow: none;
}
.btn.secondary::before, .btn.ghost::before, .btn.link::before, .btn.quiet::before, .btn.share:not(.lead)::before { display: none; }
.btn.secondary:hover:not(:disabled), .btn.ghost:hover:not(:disabled), .btn.quiet:hover:not(:disabled), .btn.share:not(.lead):hover:not(:disabled) {
  background: var(--accent-soft);
  box-shadow: inset 0 0 0 1px rgba(255, 45, 125, 0.45);
}
.btn.secondary:active:not(:disabled), .btn.ghost:active:not(:disabled), .btn.quiet:active:not(:disabled) { background: var(--accent-soft); transform: scale(0.985); box-shadow: inset 0 0 0 1px rgba(255, 45, 125, 0.55); }
.btn.ghost { box-shadow: none; font-weight: 550; }
.btn.link {
  background: none; box-shadow: none; text-shadow: none; color: var(--muted);
  min-height: 48px; font-weight: 550; text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 4px;
}
.btn.link:hover:not(:disabled), .btn.link:active:not(:disabled) { background: none; color: var(--text); }
.btn.danger {
  background: linear-gradient(180deg, #f2545e 0%, #c92a36 55%, #a01d29 100%);
  color: #fff6f6;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), inset 0 -2px 0 rgba(20, 21, 60, 0.35), 0 14px 30px -16px rgba(200, 40, 50, 0.8);
}
.btn.quiet.active { background: var(--accent-soft); box-shadow: inset 0 0 0 1px var(--accent); color: var(--text); }
.btn.copy-main.copied { background: linear-gradient(180deg, #43d48c, #1f9a5c); }
.row2 .btn { border-radius: 999px; }
.retry {
  min-height: 44px; padding: 0 16px; border-radius: 999px; border: 0; cursor: pointer;
  background: transparent; color: var(--text); box-shadow: inset 0 0 0 1px var(--line-strong); font: 600 14.5px var(--font);
}
.linkbtn, .code-toggle { min-height: 44px; color: var(--text-soft); font-family: var(--font); }
.linkbtn svg { stroke: var(--cog-2); }

/* ============ 4. cards, fields, chips, sheets ============ */
.card {
  background: linear-gradient(var(--card), var(--card)) padding-box, var(--edge) border-box;
  border: 1px solid transparent;
  border-radius: var(--radius);
  box-shadow: var(--shadow-s);
  padding: 18px;
}
label { font-size: 13.5px; font-weight: 600; letter-spacing: 0.01em; color: var(--muted); }
select, input[type="text"], input[type="email"], input[type="tel"], input[type="number"], input[type="search"], input[inputmode="numeric"], textarea {
  font-family: var(--font);
  font-size: 16.5px; /* >= 16: iOS never zooms the page into a field */
  color: var(--text);
  background-color: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-s);
  min-height: 54px;
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease), background-color 0.18s var(--ease);
}
html[data-theme="light"] select, html[data-theme="light"] input[type="text"], html[data-theme="light"] input[type="email"], html[data-theme="light"] textarea { background-color: rgba(244, 246, 251, 0.45); }
input[type="text"] { font-family: var(--font); font-size: 16.5px; letter-spacing: 0.06em; }
select:hover, input:hover, textarea:hover { border-color: rgba(255, 45, 125, 0.4); }
select:focus, input:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
select option { background: var(--surface); color: var(--text); }

.chip, .balance {
  min-height: 58px;
  border-radius: 999px;
  padding: 10px 18px 12px;
  background: linear-gradient(var(--glass), var(--glass)) padding-box, var(--edge) border-box;
  border: 1px solid transparent;
  -webkit-backdrop-filter: blur(14px) saturate(1.3);
  backdrop-filter: blur(14px) saturate(1.3);
  box-shadow: var(--shadow-s);
}
.chip .bar { left: 22px; right: 22px; bottom: 7px; height: 2px; background: var(--line); border-radius: 2px; }
.chip .bar > i { background: var(--grad); border-radius: 2px; }
.chip .bal-text { font-weight: 600; }
.chip .n, .n { font-family: var(--display); font-weight: 600; font-size: 1.28em; letter-spacing: -0.01em; font-variant-numeric: lining-nums; }
.chip[data-state="active"] .dot { background: var(--ok); box-shadow: 0 0 0 4px var(--ok-soft), 0 0 12px var(--ok); }
.chip[data-state="trial"] .dot { background: var(--cog-2); box-shadow: 0 0 0 4px rgba(167, 146, 252, 0.18), 0 0 12px var(--cog-2); }
.chip[data-state="locked"] .dot { background: var(--pink); box-shadow: 0 0 0 4px var(--accent-soft), 0 0 12px var(--pink); }
.badge { background: var(--accent-soft); color: var(--accent); border-radius: 999px; font-weight: 650; letter-spacing: 0.12em; }
.banner { border-radius: var(--radius-s); border: 1px solid rgba(167, 146, 252, 0.25); }
.toast {
  border-radius: 999px;
  background: rgba(10, 11, 32, 0.92);
  color: #ebedf6;
  border: 1px solid rgba(230, 233, 244, 0.14);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  box-shadow: 0 20px 50px -20px rgba(0, 0, 0, 0.8);
  bottom: max(20px, calc(var(--safe-b) + 12px));
}
.toast-act { color: var(--pink-2); }

/* sheets */
.sheet-back { background: var(--scrim); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.sheet-body {
  background:
    radial-gradient(120% 60% at 50% -20%, rgba(255, 45, 125, 0.14), transparent 60%),
    linear-gradient(var(--surface), var(--bg-2));
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: 28px 28px 0 0;
  box-shadow: 0 -30px 80px -30px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  padding-bottom: max(22px, calc(var(--safe-b) + 14px));
}
.sheet-body h2 { font-size: 30px; margin-top: 8px; }
.grabber { background: var(--line-strong); width: 44px; height: 5px; }
.sheet-x { border-radius: 50%; background: rgba(255, 255, 255, 0.05); box-shadow: inset 0 0 0 1px var(--line); width: 44px; height: 44px; }
@media (min-width: 700px) { .sheet-body { border-radius: 28px; border-bottom: 1px solid var(--line); } }

/* brand */
.kv-tile { background: var(--tile); color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 10px 24px -10px rgba(255, 45, 125, 0.8); border-radius: 28%; }
.wordmark { font-family: var(--display); font-weight: 600; letter-spacing: 0.005em; }
.wordmark span { font-style: italic; color: var(--pink); background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; padding-right: 0.05em; }
.brand .wordmark { font-size: 24px; }
.page-head .brand .wordmark { font-size: 21px; }
.descriptor { color: var(--eyebrow); }
.icon-btn {
  background: linear-gradient(var(--glass), var(--glass)) padding-box, var(--edge) border-box;
  border: 1px solid transparent !important;
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}
.page-head .back { background: rgba(255, 255, 255, 0.04); box-shadow: inset 0 0 0 1px var(--line); margin-left: 0; }
.seg { background: rgba(255, 255, 255, 0.04); border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.seg button { border-radius: 999px; min-height: 40px; min-width: 48px; font-weight: 650; letter-spacing: 0.08em; color: var(--muted); background: transparent; }
.seg button[aria-pressed="true"] { background: var(--grad-btn); color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35); }

/* market switch: a jewel-like two-position pill */
.mk {
  background: linear-gradient(rgba(8, 9, 24, 0.55), rgba(8, 9, 24, 0.55)) padding-box, var(--edge) border-box;
  border: 1px solid transparent;
  border-radius: 999px;
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), var(--shadow-s);
}
.mk-thumb { background: var(--grad-btn) !important; border-radius: 999px !important; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4), 0 8px 22px -8px rgba(255, 45, 125, 0.8) !important; }
.mk-thumb::after { display: none; }
.mk-opt b { font-family: var(--font); font-weight: 650; font-size: 14px; letter-spacing: 0.01em; }
.mk-opt small { font-family: var(--font); letter-spacing: 0.16em; font-weight: 600; }
.mk-opt[aria-checked="false"] { color: rgba(235, 237, 246, 0.62); }

/* ============ 5. common page frame (inner pages) ============ */
.wrap { padding-left: var(--gutter); padding-right: var(--gutter); padding-top: max(14px, var(--safe-t), var(--tg-top, 0px)); padding-bottom: max(20px, var(--safe-b), var(--tg-bottom, 0px)); }
.page-head { min-height: 56px; }
.foot-nav { border-top: 1px solid var(--line); margin-top: 40px; padding-top: 22px; }
.foot-links a { color: var(--text-soft); font-weight: 550; min-height: 44px; display: inline-flex; align-items: center; }
.foot-legal { color: var(--muted); font-size: 12.5px; letter-spacing: 0.02em; }
.foot-legal a { min-height: 32px; display: inline-flex; align-items: center; }

/* steps of a flow */
.steps li span { background: transparent; box-shadow: inset 0 0 0 1px var(--line-strong); font-family: var(--display); font-size: 16px; }
.steps li.on span, .steps li.cur span { background: var(--grad-btn); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 6px 16px -8px rgba(255, 45, 125, 0.8); color: #fff; }
.steps li.on::before, .steps li.cur::before { background: var(--grad); }
.step-title { font-family: var(--display); font-weight: 600; font-size: 28px; letter-spacing: -0.005em; }
.step-title .num { font-family: var(--display); background: transparent; color: var(--eyebrow); box-shadow: inset 0 0 0 1px currentColor; }
.done-ico { background: radial-gradient(circle at 30% 25%, rgba(255, 255, 255, 0.18), transparent 50%), var(--grad-btn); color: #fff; box-shadow: 0 20px 50px -18px rgba(255, 45, 125, 0.85), inset 0 1px 0 rgba(255, 255, 255, 0.35); }
.done-ico.warn { background: radial-gradient(circle at 30% 25%, rgba(255, 255, 255, 0.18), transparent 50%), linear-gradient(180deg, #a792fc, #3808f9); }
.pulse span { background: var(--grad-btn); box-shadow: 0 20px 50px -18px rgba(255, 45, 125, 0.85); }
.pulse i { border-color: rgba(255, 45, 125, 0.5); }
.link-box { background: rgba(255, 255, 255, 0.03); border: 1px dashed var(--line-strong); border-radius: var(--radius-s); font-family: var(--mono); }

/* in-call screens stay clean: dark glass controls */
.round { background: linear-gradient(var(--surface), var(--surface)) padding-box, var(--edge) border-box; border: 1px solid transparent; box-shadow: var(--shadow-s); }
.round.on { background: var(--grad-btn); color: #fff; }
.round.hang { background: linear-gradient(180deg, #f2545e, #b4232f); color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 14px 30px -14px rgba(200, 40, 50, 0.9); }
.line.me .tr, .line .tr { font-size: 17px; }
.line.me { background: linear-gradient(135deg, rgba(255, 45, 125, 0.18), rgba(92, 53, 250, 0.14)); border: 1px solid rgba(255, 45, 125, 0.22); }
.line.peer { background: var(--peer); border: 1px solid var(--line); }
.status[data-state="live"]::before, .status.live::before { background: var(--ok); }
.meter > i { background: var(--grad); }
.mic-btn { background: var(--grad-btn); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4), 0 24px 60px -20px rgba(255, 45, 125, 0.9); }
.mic-btn[data-state="rec"] { background: linear-gradient(180deg, #f2545e, #b4232f); }
.style-chip, .aud-chip, .pill { border-radius: 999px; font-weight: 600; }
.style-chip.on { background: var(--grad-btn); color: #fff; border-color: transparent; }
.qr-box { background: #e6e9f4; border: 0; border-radius: 22px; box-shadow: 0 30px 70px -30px rgba(255, 45, 125, 0.55); }

/* ============ 6. scene / media containers (shared) ============ */
.x-art {
  position: relative;
  display: block;
  overflow: hidden;
  background: radial-gradient(120% 90% at 50% 0%, #0F102D, #080816 70%);
  isolation: isolate;
}
.x-art > svg.sc { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
/* reveal on scroll (visual.js adds .x-in; nothing hidden without the script or with reduced motion) */
.x-rise { opacity: 1; }
html.x-js .x-rise:not(.x-in) { opacity: 0; transform: translateY(26px); }
html.x-js .x-rise { transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out); }

/* ============ 7. LANDING (index.html, body.landing) ============ */
body.landing .wrap.home { max-width: none; padding: 0; display: block; }
.x-wrap { width: 100%; max-width: 1240px; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.x-sec { padding: 76px 0; position: relative; }
.x-sec-head { margin-bottom: 26px; }
.x-h2 { font-size: clamp(34px, 9.4vw, 64px); line-height: 1.02; margin: 0; letter-spacing: -0.012em; }
.x-lead { color: var(--muted); font-size: 16.5px; margin: 12px 0 0; max-width: 46ch; }

/* top bar over the hero */
.x-top {
  position: absolute;
  z-index: 5;
  top: 0; left: 0; right: 0;
  padding-top: max(10px, var(--safe-t));
}
.x-top .x-wrap { display: flex; align-items: center; gap: 10px; min-height: 62px; }
.x-top .brand { margin-right: auto; color: #ebedf6; }
.x-top .brand .kv-tile { width: 34px; height: 34px; }
.x-top .mk-box { margin: 0; }
.x-top .mk { width: 196px; min-height: 44px; }
.x-top .mk-opt { min-height: 40px; padding: 0 6px; }
.x-top .mk-opt small { display: none; }
.x-top .mk-opt b { font-size: 13px; }
.x-top .top-links a.desk { color: rgba(235, 237, 246, 0.75); }

/* HERO: always the night look (the photo of a real-estate hero, here our own film + light) */
.x-hero {
  position: relative;
  overflow: hidden;
  min-height: 100vh;
  min-height: 100svh;
  padding: calc(max(10px, var(--safe-t)) + 74px) 0 34px;
  background:
    radial-gradient(70% 45% at 85% 58%, rgba(255, 45, 125, 0.42), transparent 70%),
    radial-gradient(60% 40% at 0% 92%, rgba(92, 53, 250, 0.45), transparent 70%),
    radial-gradient(90% 40% at 50% -5%, rgba(64, 25, 155, 0.35), transparent 70%),
    linear-gradient(180deg, #09091a 0%, #060714 60%, #050610 100%);
  color: var(--text);
  isolation: isolate;
}
.x-hero::after { /* soft hand-off into the page below */
  content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 90px; z-index: -1;
  background: linear-gradient(180deg, transparent, var(--bg));
  opacity: 0;
}
.x-hero-world { position: absolute; inset: 0; z-index: -2; opacity: 0.55; background: none; }
.x-hero-world > svg.sc { position: absolute; inset: 0; width: 100%; height: 100%; }
.x-hero-grid {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image: linear-gradient(rgba(230, 233, 244, 0.06) 1px, transparent 1px), linear-gradient(90deg, rgba(230, 233, 244, 0.06) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: radial-gradient(70% 55% at 60% 55%, #000 20%, transparent 75%);
  mask-image: radial-gradient(70% 55% at 60% 55%, #000 20%, transparent 75%);
}
.x-hero .x-wrap { display: grid; grid-template-columns: 1fr; gap: 0; }
.x-hero-copy { position: relative; z-index: 2; }
.x-h1 {
  font-size: clamp(44px, 12.6vw, 96px);
  line-height: 0.98;
  margin: 0;
  letter-spacing: -0.015em;
  color: #f1f3f9;
}
.x-h1 > span { display: block; }
.x-h1 em { font-weight: 600; }
.x-hero .x-eyebrow { color: #a792fc; }
.x-stage {
  position: relative;
  height: min(430px, 50svh);
  margin: 16px 0 6px;
  display: grid;
  place-items: center;
}
.x-film {
  position: relative;
  height: 100%;
  aspect-ratio: 9 / 16;
  border-radius: 34px;
  overflow: hidden;
  background: #121115;
  box-shadow: 0 50px 90px -40px rgba(255, 45, 125, 0.7), 0 30px 60px -30px rgba(0, 0, 0, 0.9);
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 12%, #000 86%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0%, #000 12%, #000 86%, transparent 100%);
}
.x-film video, .x-film img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 70%; display: block; }
.x-film .x-art { position: absolute; inset: 0; background: none; }
.x-halo { position: absolute; width: 120%; aspect-ratio: 1; max-width: 520px; border-radius: 50%; z-index: -1;
  background: conic-gradient(from 200deg, rgba(255, 45, 125, 0), rgba(255, 45, 125, 0.4), rgba(92, 53, 250, 0.35), rgba(255, 45, 125, 0));
  filter: blur(40px); opacity: 0.8; animation: x-spin 18s linear infinite; }
.x-ring { position: absolute; width: 92%; max-width: 420px; aspect-ratio: 1; border-radius: 50%; border: 1px solid rgba(230, 233, 244, 0.1); z-index: -1; }
.x-ring.r2 { width: 128%; max-width: 560px; border-style: dashed; border-color: rgba(167, 146, 252, 0.14); animation: x-spin 60s linear infinite reverse; }
@keyframes x-spin { to { transform: rotate(360deg); } }
/* floating translation bubbles around the film */
.x-bub {
  position: absolute; z-index: 3; max-width: 62%;
  padding: 10px 14px 11px; border-radius: 18px;
  font: 600 14px/1.25 var(--font); color: #f1f3f9;
  background: rgba(12, 12, 35, 0.72);
  border: 1px solid rgba(230, 233, 244, 0.14);
  -webkit-backdrop-filter: blur(14px) saturate(1.4); backdrop-filter: blur(14px) saturate(1.4);
  box-shadow: 0 18px 40px -18px rgba(0, 0, 0, 0.9);
  animation: x-float 7s var(--ease) infinite;
}
.x-bub small { display: block; font-weight: 500; font-size: 12.5px; color: rgba(235, 237, 246, 0.66); margin-top: 3px; }
.x-bub b { display: inline-block; font: 700 10px/1 var(--font); letter-spacing: 0.16em; color: #a792fc; margin-right: 6px; vertical-align: 1px; }
.x-bub.b1 { left: 0; top: 12%; border-bottom-left-radius: 6px; }
.x-bub.b2 { right: 0; top: 52%; animation-delay: -3.5s; background: linear-gradient(120deg, rgba(255, 22, 111, 0.92), rgba(92, 53, 250, 0.9)); border-color: rgba(255, 255, 255, 0.18); border-bottom-right-radius: 6px; }
.x-bub.b2 small { color: rgba(248, 249, 253, 0.82); }
.x-bub.b2 b { color: #eff1f8; }
@keyframes x-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
.x-cta-row { position: relative; z-index: 2; display: flex; flex-direction: column; gap: 12px; margin-top: 10px; }
.x-cta { width: 100%; }
.x-cta .x-arrow { width: 20px; height: 20px; transition: transform 0.25s var(--ease-out); }
.x-cta:hover .x-arrow { transform: translateX(4px); }
.x-note { margin: 0; text-align: center; color: rgba(235, 237, 246, 0.62); font-size: 13.5px; letter-spacing: 0.01em; }
.x-hero .sub-box { margin: 4px 0 0; }
/* anon: the hero button opens the sign-in; only the quiet "I have a code" stays here */
.x-hero .auth-box { background: none; border: 0; box-shadow: none; padding: 0; margin: 0; text-align: center; }
.x-hero .auth-box > b, .x-hero .auth-box > p, .x-hero #signInBtn, .x-hero #tgTry { display: none !important; }
.x-hero .code-toggle { color: rgba(235, 237, 246, 0.6); font-size: 14px; margin: 0 auto; display: inline-flex; }
.x-hero .install-hint { display: none !important; }
.x-scroll { display: none; }

/* scenario cards: four big visual scenes */
.x-modes .cards { display: grid; grid-template-columns: 1fr; gap: 18px; margin: 0; }
.x-modes .mode-group { display: contents; }
.bigcard[data-mode] {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  padding: 0;
  min-height: 0;
  text-align: left;
  text-decoration: none;
  color: var(--text);
  border-radius: var(--radius-l);
  overflow: hidden;
  background: linear-gradient(var(--card), var(--card)) padding-box, var(--edge) border-box;
  border: 1px solid transparent;
  box-shadow: var(--shadow);
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease);
  font: inherit;
  width: 100%;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.bigcard[data-mode]:hover:not(:disabled) { transform: translateY(-3px); background: linear-gradient(var(--card), var(--card)) padding-box, var(--edge) border-box; }
.bigcard[data-mode]:active:not(:disabled) { transform: scale(0.985); background: linear-gradient(var(--card), var(--card)) padding-box, var(--edge) border-box; }
.bigcard[data-mode] .x-art { aspect-ratio: 4 / 3; width: 100%; flex: none; }
.bigcard[data-mode] .ico { display: none; }
.bigcard[data-mode] .txt { display: block; padding: 18px 20px 4px; }
.bigcard[data-mode] .txt > b { display: block; font-family: var(--display); font-weight: 600; font-size: 30px; line-height: 1.04; letter-spacing: -0.008em; margin: 0 0 6px; }
.bigcard[data-mode] .txt > span { display: block; color: var(--muted); font-size: 15.5px; line-height: 1.45; }
.bigcard[data-mode] .trial-tag {
  position: absolute; top: 14px; left: 14px; z-index: 2; margin: 0;
  padding: 7px 12px; border-radius: 999px; font: 650 11px/1 var(--font); letter-spacing: 0.16em; text-transform: uppercase; font-style: normal;
  color: #f0f2f9; background: rgba(8, 9, 24, 0.6); border: 1px solid rgba(167, 146, 252, 0.4);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.bigcard[data-mode] .trial-tag.approx { color: #ebedf6; border-color: rgba(230, 233, 244, 0.25); letter-spacing: 0.04em; text-transform: none; font-size: 12.5px; }
.bigcard[data-mode] .trial-tag:empty { display: none; }
.bigcard[data-mode] .x-go {
  display: inline-flex; align-items: center; gap: 8px; margin: 12px 20px 20px; align-self: flex-start;
  min-height: 44px; padding: 0 18px; border-radius: 999px;
  font: 650 14.5px var(--font); letter-spacing: 0.01em; color: var(--text);
  box-shadow: inset 0 0 0 1px var(--line-strong);
  transition: background 0.2s var(--ease), box-shadow 0.2s var(--ease), color 0.2s var(--ease);
}
.bigcard[data-mode] .x-go svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; transition: transform 0.25s var(--ease-out); }
.bigcard[data-mode]:hover .x-go { background: var(--grad-btn); color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 10px 24px -12px rgba(255, 45, 125, 0.8); }
.bigcard[data-mode]:hover .x-go svg { transform: translateX(3px); }
.bigcard[data-mode] > .chev { display: none; }
.bigcard[data-mode] > .lock {
  position: absolute; top: 14px; right: 14px; z-index: 2; width: 40px; height: 40px; padding: 10px;
  border-radius: 50%; background: rgba(8, 9, 24, 0.6); color: #ebedf6; stroke: currentColor; fill: none; stroke-width: 1.8;
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border: 1px solid rgba(230, 233, 244, 0.18);
}
.bigcard[data-mode]:not(.locked) > .lock { display: none; }
.bigcard[data-mode].locked .x-go { color: var(--muted); }
.subcard {
  border-radius: var(--radius); min-height: 56px; padding: 10px 16px;
  background: linear-gradient(var(--card), var(--card)) padding-box, var(--edge) border-box; border: 1px solid transparent;
  color: var(--text-soft);
}
.x-modes .subcard { grid-column: 1 / -1; order: 9; }
.x-modes #cardInterp { order: 10; }

/* audience chips */
.aud-chips { gap: 8px; padding: 2px 0 6px; }
.aud-chip {
  min-height: 44px; padding: 0 16px; font-size: 14.5px; color: var(--text-soft);
  background: linear-gradient(var(--glass), var(--glass)) padding-box, var(--edge) border-box; border: 1px solid transparent;
}
.aud-chip:hover { color: var(--text); }
body.landing .aud-grid { display: none; }

/* how it works */
.x-how { display: grid; grid-template-columns: 1fr; gap: 16px; margin: 0; padding: 0; list-style: none; counter-reset: x; }
.x-how li { position: relative; border-radius: var(--radius-l); overflow: hidden; background: linear-gradient(var(--card), var(--card)) padding-box, var(--edge) border-box; border: 1px solid transparent; box-shadow: var(--shadow-s); }
.x-how .x-art { aspect-ratio: 16 / 10; }
.x-how .x-step { display: grid; grid-template-columns: auto 1fr; gap: 4px 16px; align-items: baseline; padding: 16px 20px 20px; }
.x-how .x-num { grid-row: span 2; font-family: var(--display); font-style: italic; font-weight: 600; font-size: 46px; line-height: 0.9; background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; }
.x-how b { font-family: var(--display); font-size: 26px; font-weight: 600; line-height: 1.05; }
.x-how p { margin: 0; color: var(--muted); font-size: 15px; }

/* demo reel (ui.js demoStrip): cinematic 9:16 film cards */
.demos .sec-title { margin-top: 0; }
.demo-row { gap: 14px; padding: 4px var(--gutter) 18px; margin: 0 calc(-1 * var(--gutter)); scroll-padding-inline: var(--gutter); scroll-snap-type: x mandatory; }
.demo-card {
  flex: 0 0 min(64vw, 260px); border-radius: 26px; scroll-snap-align: start;
  background: #121115; box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(230, 233, 244, 0.1);
}
.demo-card video { object-fit: cover; }
.demo-play { background: radial-gradient(60% 50% at 50% 50%, rgba(0, 0, 0, 0.0), rgba(0, 0, 0, 0.0)); }
.demo-play svg { width: 64px; height: 64px; padding: 20px 18px 20px 22px; border-radius: 50%; background: var(--grad-btn); color: #fff; fill: #fff; stroke: none; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4), 0 18px 40px -14px rgba(255, 45, 125, 0.9); }
.demo-cap { left: 14px; right: 14px; bottom: 14px; font: 600 15px/1.25 var(--font); color: #f1f3f9; text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7); }
.demo-card::after { content: ""; position: absolute; inset: auto 0 0 0; height: 40%; background: linear-gradient(180deg, transparent, rgba(4, 4, 12, 0.85)); pointer-events: none; border-radius: 0 0 26px 26px; }
.demo-card.playing::after { opacity: 0; }
.demo-card > * { z-index: 1; }

/* trust: big numbers as graphics, over the dotted world */
.x-trust { position: relative; border-radius: var(--radius-l); overflow: hidden; padding: 34px 22px 26px; isolation: isolate;
  background: radial-gradient(90% 60% at 80% 0%, rgba(255, 45, 125, 0.35), transparent 60%), radial-gradient(80% 60% at 0% 100%, rgba(92, 53, 250, 0.35), transparent 60%), #080918; color: #ebedf6; box-shadow: var(--shadow); }
.x-trust > .x-art { position: absolute; inset: 0; z-index: -1; background: none; opacity: 0.9; }
.x-big { font-family: var(--display); font-weight: 600; font-size: clamp(120px, 40vw, 220px); line-height: 0.82; letter-spacing: -0.04em; background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; margin: 0; }
.x-big-cap { font: 650 12px var(--font); letter-spacing: 0.22em; text-transform: uppercase; color: #a792fc; margin: 8px 0 26px; }
.x-facts { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.x-facts li { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 18px; background: rgba(8, 9, 24, 0.55); border: 1px solid rgba(230, 233, 244, 0.1); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.x-facts svg { flex: none; width: 40px; height: 40px; padding: 9px; border-radius: 50%; fill: none; stroke: #dfe2f7; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; background: linear-gradient(140deg, rgba(255, 45, 125, 0.55), rgba(92, 53, 250, 0.45)); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25); }
.x-facts b { display: block; font: 650 16px/1.25 var(--font); }
.x-facts span { display: block; color: rgba(235, 237, 246, 0.66); font-size: 14px; }

/* price band (the teaser) */
.teaser.x-price {
  position: relative; display: grid; gap: 6px; justify-items: start; text-align: left;
  border-radius: var(--radius-l); overflow: hidden; padding: 30px 22px 24px; margin: 0; isolation: isolate;
  background: radial-gradient(80% 70% at 100% 100%, rgba(255, 45, 125, 0.45), transparent 60%), radial-gradient(70% 60% at 0% 0%, rgba(92, 53, 250, 0.4), transparent 60%), #08091a;
  color: #ebedf6; border: 1px solid rgba(230, 233, 244, 0.12); box-shadow: var(--shadow);
}
.teaser.x-price > .x-art { position: absolute; inset: auto 0 0 0; height: 58%; z-index: -1; background: none; opacity: 0.95; }
.teaser.x-price h3 { margin: 0; font: 650 11.5px var(--font); letter-spacing: 0.22em; text-transform: uppercase; color: #a792fc; }
.teaser.x-price .pw-price { font-family: var(--display); font-weight: 600; font-size: clamp(64px, 20vw, 110px); line-height: 0.95; letter-spacing: -0.03em; white-space: normal; margin: 4px 0 2px; }
.teaser.x-price p { margin: 0; color: rgba(235, 237, 246, 0.75); font-size: 15px; }
.teaser.x-price .x-free { color: #dfe2f7; font-weight: 600; }
.teaser.x-price .btn { width: auto; margin-top: 18px; color: #ebedf6; box-shadow: inset 0 0 0 1px rgba(230, 233, 244, 0.35); }

/* final call */
.x-final { text-align: center; padding: 90px 0 30px; position: relative; overflow: hidden; }
.x-final .x-art.x-final-art { position: absolute; inset: 0; z-index: -1; background: none; opacity: 0.8; -webkit-mask-image: linear-gradient(180deg, transparent, #000 30%, #000 70%, transparent); mask-image: linear-gradient(180deg, transparent, #000 30%, #000 70%, transparent); }
.x-final .x-h2 { max-width: 13ch; margin: 0 auto; }
.x-final .btn { max-width: 420px; margin: 26px auto 10px; }
.x-final .linkbtn { margin: 0 auto; }

/* landing footer */
body.landing .foot-nav { max-width: 1240px; margin: 0 auto; padding: 24px var(--gutter) max(28px, var(--safe-b)); }

/* ============ 8. MINI APP (tg.html) ============ */
html.in-tg #vHome > .hero { display: none; }
html.in-tg .x-tgtop { display: flex; align-items: center; gap: 10px; margin: 2px 0 14px; }
.x-tgtop .brand { margin-right: auto; }
.x-tgtop .brand .kv-tile { width: 32px; height: 32px; }
.x-tgtop .mk { width: 176px; min-height: 44px; }
.x-tgtop .mk-opt { min-height: 40px; padding: 0 4px; }
.x-tgtop .mk-opt small { display: none; }
.x-tgtop .mk-opt b { font-size: 12.5px; }
.x-tgtop .mk-box { margin: 0; }
html.in-tg #vHome .sub-box { margin: 0 0 14px; }
.x-tiles .cards { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 0; }
.x-tiles .mode-group { display: contents; }
.x-tiles .bigcard[data-mode] { border-radius: 24px; }
.x-tiles .bigcard[data-mode] .x-art { aspect-ratio: auto; height: clamp(150px, 46vw, 240px); }
.x-tiles .bigcard[data-mode] .txt { padding: 12px 14px 14px; }
.x-tiles .bigcard[data-mode] .txt > b { font-size: 21px; line-height: 1.04; margin: 0; }
.x-tiles .bigcard[data-mode] .txt > span { display: none; }
.x-tiles .bigcard[data-mode] .x-go { display: none; }
.x-tiles .bigcard[data-mode] .trial-tag { top: 10px; left: 10px; font-size: 9.5px; padding: 6px 9px; letter-spacing: 0.12em; }
.x-tiles .bigcard[data-mode] > .lock { top: 10px; right: 10px; width: 34px; height: 34px; padding: 8px; }
.x-tiles .subcard { grid-column: 1 / -1; order: 9; margin: 0; }
html.in-tg #vHome .linkbtn { justify-content: center; }
html.in-tg #vHome .audience .sec-title { margin-top: 22px; }

/* ============ 9. MODE PAGES: a visual header on the setup screen ============ */
.x-mode-art { height: clamp(170px, 30svh, 300px); margin: 4px calc(-1 * var(--gutter)) 18px; border-radius: 0 0 var(--radius-l) var(--radius-l); }
.x-mode-art::after { content: ""; position: absolute; inset: auto 0 0 0; height: 40%; background: linear-gradient(180deg, transparent, rgba(8, 8, 22, 0.0)); }
@media (min-width: 520px) { .x-mode-art { margin-left: 0; margin-right: 0; border-radius: var(--radius-l); } }

/* ============ 10. PRICING / PAYWALL ============ */
.x-pagehero { position: relative; border-radius: var(--radius-l); overflow: hidden; margin: 4px 0 18px; padding: 26px 22px 24px; min-height: clamp(220px, 34svh, 330px); display: flex; flex-direction: column; justify-content: flex-end; isolation: isolate; color: #ebedf6; background: #080918; box-shadow: var(--shadow); }
.x-pagehero > .x-art { position: absolute; inset: 0; z-index: -1; background: radial-gradient(90% 70% at 80% 10%, rgba(255, 45, 125, 0.35), transparent 60%), radial-gradient(80% 60% at 0% 100%, rgba(92, 53, 250, 0.35), transparent 60%), #080918; }
.x-pagehero h1 { color: #f1f3f9; font-size: clamp(42px, 12vw, 72px); margin: 0; }
.x-pagehero .x-eyebrow { color: #a792fc; margin-bottom: 8px; }
.x-pagehero p { margin: 6px 0 0; color: rgba(235, 237, 246, 0.72); }
.pw-head h2 { font-size: 30px; }
.pw-plan, .pw-term, .pw-once {
  background: linear-gradient(var(--card), var(--card)) padding-box, var(--edge) border-box !important;
  border: 1px solid transparent !important;
  border-radius: 22px !important;
  box-shadow: var(--shadow-s);
  transition: transform 0.25s var(--ease-out), box-shadow 0.25s var(--ease);
}
.pw-plan[aria-pressed="true"], .pw-term[aria-pressed="true"], .pw-once[aria-pressed="true"] {
  background: linear-gradient(var(--card), var(--card)) padding-box, linear-gradient(120deg, #ff3b86, #5c35fa) border-box !important;
  box-shadow: 0 20px 50px -24px rgba(255, 45, 125, 0.75);
}
.pw-plan:active, .pw-term:active, .pw-once:active { transform: scale(0.985); }
/* the main plan: a visual panel (waves scene added by visual.js), the price as graphics */
.pw-plan.x-main { position: relative; overflow: hidden; isolation: isolate; min-height: 250px; display: flex; flex-direction: column; justify-content: flex-end; padding: 22px !important; color: #ebedf6;
  background: linear-gradient(#080919, #080919) padding-box, linear-gradient(120deg, #ff3b86, #5c35fa) border-box !important; }
.pw-plan.x-main > .x-art { position: absolute; inset: 0; z-index: -1; background: radial-gradient(80% 70% at 90% 0%, rgba(255, 45, 125, 0.4), transparent 60%), radial-gradient(70% 60% at 0% 100%, rgba(92, 53, 250, 0.38), transparent 60%), #080919; }
.pw-plan.x-main .pw-plan-top { flex-direction: column; align-items: flex-start; gap: 0; }
.pw-plan.x-main .pw-plan-top b { font: 650 11.5px var(--font); letter-spacing: 0.22em; text-transform: uppercase; color: #a792fc; order: -1; }
.pw-plan.x-main .pw-price { font-size: clamp(58px, 18vw, 92px); line-height: 0.95; letter-spacing: -0.03em; color: #f1f3f9; }
.pw-plan.x-main .pw-price small { font-family: var(--font); font-size: 15px; letter-spacing: 0.01em; color: rgba(235, 237, 246, 0.7); font-weight: 550; }
.pw-plan.x-main .pw-plan-line { color: rgba(235, 237, 246, 0.75); }
.pw-price { font-family: var(--display); font-weight: 600; letter-spacing: -0.02em; }
.pw-term .pw-term-price { font-family: var(--display); font-size: 30px; }
.pw-term em, .pr-tag { color: var(--accent); font-style: normal; }
.pw-facts svg, .pw-via svg { stroke: var(--cog-2); }
.pw-free { border-radius: 16px; background: var(--accent-soft); border: 1px solid rgba(255, 45, 125, 0.22); padding: 12px 14px; }
.skeleton { background: linear-gradient(90deg, var(--surface), var(--surface-2), var(--surface)); background-size: 200% 100%; border-radius: 18px; }

/* profile / history / legal */
.pr-section > h2, .hist-day { font-family: var(--display); }
.pr-big { font-family: var(--display); font-weight: 600; font-size: 64px; letter-spacing: -0.03em; background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; }
.pr-meter i, .usage .u-bar i { background: var(--grad); }
.hist-open { border-radius: 18px; }
.hist-ico { background: var(--accent-soft); color: var(--accent); border-radius: 14px; }
.x-empty { height: 200px; margin: 6px 0 12px; border-radius: var(--radius-l); }
.legal h1 { font-size: clamp(36px, 10vw, 56px); }
.legal h2 { font-size: 26px; margin-top: 30px; }
.legal p, .legal li { color: var(--text-soft); line-height: 1.65; }

/* sign-in sheet (signin.js): same depth */
.kvs-mark, .kvs-ico { background: var(--tile); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 16px 40px -14px rgba(255, 45, 125, 0.85); border-radius: 20px; }
.kvs-head h2 { font-size: 32px; }
.kvs-or { color: var(--muted); letter-spacing: 0.16em; text-transform: uppercase; font-size: 11.5px; font-weight: 650; }
.consent h2 { font-size: 30px; }

/* boot failure line */
.boot-fail { background: var(--surface); border: 1px solid var(--line); border-radius: 999px; }

/* ============ 11. large screens ============ */
@media (min-width: 760px) {
  .x-sec { padding: 110px 0; }
  .x-modes .cards { grid-template-columns: 1fr 1fr; gap: 22px; }
  .x-how { grid-template-columns: repeat(3, 1fr); }
  .x-trust { padding: 56px 48px 44px; display: grid; grid-template-columns: 1fr 1.1fr; gap: 20px 48px; align-items: end; }
  .x-trust .x-big-cap { margin-bottom: 0; }
  .x-trust .x-facts { grid-row: span 2; }
  .teaser.x-price { padding: 48px; grid-template-columns: 1fr auto; align-items: end; }
  .teaser.x-price > div { grid-column: 1; }
  .teaser.x-price .btn { grid-column: 2; grid-row: 1 / span 3; align-self: end; }
  .demo-card { flex-basis: 250px; }
  .x-tiles .cards { grid-template-columns: repeat(4, 1fr); }
  .x-tiles .bigcard[data-mode] .x-art { height: 200px; }
}
@media (min-width: 1000px) {
  .x-hero { padding-top: 120px; display: flex; align-items: center; }
  .x-hero .x-wrap { grid-template-columns: 1.08fr 0.92fr; gap: 40px; align-items: center; }
  .x-hero-copy { grid-row: 1; }
  .x-stage { grid-column: 2; grid-row: 1 / span 2; height: min(640px, 76vh); margin: 0; }
  .x-cta-row { grid-column: 1; grid-row: 2; align-self: start; max-width: 420px; margin-top: 30px; }
  .x-note { text-align: left; }
  .x-h1 { font-size: clamp(72px, 7.2vw, 108px); }
  .x-bub { font-size: 15.5px; max-width: 280px; }
  .x-bub.b1 { left: -2%; top: 18%; }
  .x-bub.b2 { right: -4%; top: 58%; }
  .x-modes .cards { grid-template-columns: repeat(4, 1fr); }
  .bigcard[data-mode] .x-art { aspect-ratio: 3 / 4; }
  .bigcard[data-mode] .txt > b { font-size: 28px; }
  .x-sec-head { display: flex; align-items: end; justify-content: space-between; gap: 40px; margin-bottom: 40px; }
  .x-modes .aud-chips { justify-content: flex-end; }
  .x-final { padding: 140px 0 60px; }
}
/* the inner pages and the Mini App: a centred column that still looks composed on a big screen */
@media (min-width: 1000px) {
  body:not(.landing) .wrap { max-width: 560px; }
  html.in-tg .wrap { max-width: 980px; }
}

/* ============ 12. motion preferences ============ */
@media (prefers-reduced-motion: reduce) {
  .x-halo, .x-ring.r2, .x-bub { animation: none !important; }
  html.x-js .x-rise:not(.x-in) { opacity: 1; transform: none; }
  .btn, .bigcard[data-mode] { transition: none; }
}

/* ============ 13. photo backgrounds (public/img, free licences: img/LICENSES.txt) ============ */
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
/* hero: a warm still life, the placeholder colour + tiny blurred frame first (no flash) */
.x-hero-photo { position: absolute; inset: 0; z-index: -3; background: #171946 center / cover no-repeat; }
.x-hero-photo picture, .x-hero-photo img { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.x-hero-photo img { object-fit: cover; object-position: 50% 50%; }
/* warm dark veil: text on top keeps a contrast well above 4.5:1 */
.x-veil {
  position: absolute; inset: 0; z-index: -2; pointer-events: none;
  background:
    linear-gradient(180deg, rgba(6, 6, 16, 0.86) 0%, rgba(6, 6, 16, 0.55) 30%, rgba(6, 6, 16, 0.25) 52%, rgba(6, 6, 16, 0.72) 78%, rgba(5, 5, 14, 0.96) 100%),
    radial-gradient(70% 50% at 70% 60%, rgba(255, 45, 125, 0.22), transparent 70%),
    radial-gradient(60% 40% at 0% 100%, rgba(92, 53, 250, 0.3), transparent 70%);
}
.x-veil::after { /* fine grain */
  content: ""; position: absolute; inset: 0; opacity: 0.55;
  background:
    radial-gradient(rgba(237, 240, 248, 0.07) 0.6px, transparent 0.9px) 0 0 / 3px 3px,
    radial-gradient(rgba(0, 0, 0, 0.25) 0.6px, transparent 0.9px) 1px 2px / 5px 5px;
}
.x-hero { background: #070715; }
.x-hero .x-hero-grid { display: none; }
@media (min-width: 1000px) {
  .x-veil { background:
    linear-gradient(90deg, rgba(6, 6, 16, 0.92) 0%, rgba(6, 6, 16, 0.72) 34%, rgba(6, 6, 16, 0.25) 62%, rgba(6, 6, 16, 0.45) 100%),
    linear-gradient(180deg, rgba(6, 6, 16, 0.55) 0%, transparent 25%, transparent 70%, rgba(5, 5, 14, 0.95) 100%),
    radial-gradient(50% 50% at 75% 55%, rgba(255, 45, 125, 0.2), transparent 70%); }
}
/* the demo film stands in the still life like a phone on the table */
.x-film {
  -webkit-mask-image: none; mask-image: none;
  border-radius: 38px;
  padding: 0;
  background: #070714;
  box-shadow: 0 0 0 1px rgba(230, 233, 244, 0.16), 0 0 0 7px #09091a, 0 0 0 8px rgba(167, 146, 252, 0.28), 0 60px 90px -30px rgba(0, 0, 0, 0.95), 0 30px 80px -40px rgba(255, 45, 125, 0.7);
}
.x-film .x-art { border-radius: inherit; }
.x-film video { opacity: 0; transition: opacity 0.8s var(--ease); object-fit: cover; object-position: 48% 100%; transform: scale(1.16); transform-origin: 50% 92%; }
.x-film.has-video video { opacity: 1; }
.x-film.has-video .x-art { opacity: 0; transition: opacity 0.8s var(--ease); }
.x-stage { height: min(400px, 47svh); }
.x-halo { opacity: 0.55; }
/* photo scenes in the scenario cards: the photo + the brand scene drawn transparently over it */
.x-art.x-photo { background: #0e0f2b; }
.x-art.x-photo picture, .x-art.x-photo img { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.x-art.x-photo img { object-fit: cover; }
.x-art.x-photo::after { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(180deg, rgba(6, 6, 16, 0.25) 0%, rgba(6, 6, 16, 0.05) 40%, rgba(6, 6, 16, 0.55) 100%), radial-gradient(70% 60% at 50% 50%, rgba(255, 45, 125, 0.12), transparent 70%); }
.x-art-scene { position: absolute; inset: 0; z-index: 2; display: block; }
.x-art-scene > svg.sc { position: absolute; inset: 0; width: 100%; height: 100%; }
.x-art-scene .sc-bgr, .x-art-scene .sc-vgr { display: none; }
.teaser.x-price > .x-art.x-photo { inset: 0; height: auto; opacity: 1; }
.teaser.x-price > .x-art.x-photo::after { background: linear-gradient(180deg, rgba(6, 6, 16, 0.6), rgba(6, 6, 16, 0.35) 45%, rgba(6, 6, 16, 0.85)); }
.x-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 18px; margin-top: 18px; }
/* Mini App: a calm leather texture behind the tiles */
html.in-tg body {
  background-color: #09091a;
  background-size: cover; background-position: center; background-attachment: fixed;
}
html.in-tg[data-theme="light"] body {
  background-color: #a792fc;
}
/* pricing page hero photo */
.x-pagehero > .x-art.x-photo::after { background: linear-gradient(180deg, rgba(6, 6, 16, 0.35), rgba(6, 6, 16, 0.2) 40%, rgba(6, 6, 16, 0.88)); }
/* narrow phones: the switch shows its short codes (RU | EN · ES), the brand keeps its name down to 360 px */
@media (max-width: 439px) {
  .x-top .mk, .x-tgtop .mk { width: 150px; }
  .x-top .mk-opt b, .x-tgtop .mk-opt b { display: none; }
  .x-top .mk-opt small, .x-tgtop .mk-opt small { display: block; font-size: 11.5px; letter-spacing: 0.14em; margin: 0; opacity: 1; color: inherit; }
  .x-top .brand .wordmark { font-size: 22px; }
}
@media (max-width: 359px) { .x-top .brand .wordmark, .x-tgtop .brand .wordmark { display: none; } }
.x-art-scene > svg.sc { background: transparent; }
.x-hero-world > svg.sc, .x-trust > .x-art > svg.sc, .x-final-art > svg.sc { background: transparent; }
/* rhythm, numbers, trust map, final photo */
.x-sec { padding: 46px 0; }
@media (min-width: 760px) { .x-sec { padding: 92px 0; } }
.x-big, .pw-price, .x-num, .n, .pr-big, .pw-term-price { font-variant-numeric: lining-nums tabular-nums; }
.x-trust > .x-art { inset: 0 0 auto 0; height: 62%; -webkit-mask-image: linear-gradient(180deg, #000 55%, transparent); mask-image: linear-gradient(180deg, #000 55%, transparent); }
.x-final { padding: 0; min-height: min(720px, 92svh); display: flex; flex-direction: column; justify-content: flex-end; isolation: isolate; color: var(--text); }
.x-final .x-wrap { padding-bottom: 56px; position: relative; z-index: 2; }
.x-final-photo { position: absolute !important; inset: 0; z-index: -2; }
.x-final-photo::after { background: linear-gradient(180deg, var(--bg) 0%, rgba(6, 6, 16, 0.35) 22%, rgba(6, 6, 16, 0.3) 45%, rgba(5, 5, 14, 0.92) 85%, #080816 100%) !important; }
.x-final .x-art.x-final-art { inset: auto 0 0 0; height: 180px; z-index: -1; -webkit-mask-image: none; mask-image: none; opacity: 0.85; }
.x-final .x-h2 { color: #f1f3f9; }
.bigcard[data-mode] .txt { padding: 16px 20px 2px; }
.bigcard[data-mode] .x-go { margin: 10px 20px 18px; }
.x-final-art .sc-bgr, .x-final-art .sc-vgr, .x-trust .sc-bgr, .x-trust .sc-vgr, .pw-plan.x-main .sc-vgr { display: none; }
/* inner pages: header scenes */
.x-mode-art { position: relative; display: block; }
.x-mode-art-s { height: clamp(130px, 22svh, 210px); }
.x-mode-art-xs { height: 120px; margin-bottom: 8px; }
.x-pagehero-s { min-height: 170px; }
.x-pagehero > .x-art.x-photo { position: absolute; inset: 0; z-index: -1; }
.x-pagehero > .x-art.x-photo picture, .x-pagehero > .x-art.x-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
body[data-page="pricing"] .pw-head { display: none; }
html.in-tg .x-mode-art { margin-top: 0; }
body[data-page="pricing"] .x-pagehero h1, .x-pagehero h1 { font-family: var(--display); font-size: clamp(46px, 13vw, 76px); font-weight: 600; letter-spacing: -0.012em; text-transform: none; color: #f1f3f9; line-height: 1; margin: 0; }
.x-pagehero { min-height: clamp(280px, 42svh, 380px); }
.x-mode-art { height: clamp(230px, 40svh, 380px); }
.x-mode-art.x-mode-art-s { height: clamp(150px, 24svh, 230px); }
.x-mode-art.x-mode-art-xs { height: 130px; }
.x-mini4 { margin: 28px 0 8px; }
.x-mini4 ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.x-mini4 li { position: relative; border-radius: 22px; overflow: hidden; background: #141217; aspect-ratio: 1 / 1.08; box-shadow: var(--shadow-s); }
.x-mini4 .x-art { position: absolute; inset: 0; }
.x-mini4 b { position: absolute; left: 12px; right: 12px; bottom: 10px; z-index: 2; font: 600 19px/1.05 var(--display); color: #f1f3f9; text-shadow: 0 2px 12px rgba(0, 0, 0, 0.8); }
.x-mini4 li::after { content: ""; position: absolute; inset: 45% 0 0 0; z-index: 1; background: linear-gradient(180deg, transparent, rgba(5, 5, 14, 0.9)); }
label.check { font-size: 14.5px; font-weight: 500; line-height: 1.45; color: var(--text-soft); letter-spacing: 0; }
input[type="checkbox"], input[type="radio"] { accent-color: var(--pink); width: 22px; height: 22px; }
.pw-plan.x-main .pw-hours, .pw-plan.x-main .pw-enough, .pw-plan.x-main .pw-enough li, .pw-plan.x-main p { color: rgba(235, 237, 246, 0.82); }
.pw-plan.x-main .pw-enough li span:last-child { color: #f1f3f9; }
.x-tgtop .mk { width: 216px; }
.x-top .top-links a.desk { display: inline-flex !important; }
@media (max-width: 439px) { .x-tgtop .mk { width: 150px; } }
.hist-seg { border-radius: 999px; }
.hist-seg button { border-radius: 999px; min-height: 44px; font-weight: 600; }
.hist-seg button[aria-checked="true"] { background: var(--grad-btn); color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 8px 20px -10px rgba(255, 45, 125, 0.7); border-color: transparent; }
/* PWA install hint: a quiet glass pill under the hero button (hidden in Telegram, in the installed app, after "got it") */
.x-hero .install-hint:not([hidden]) {
  display: inline-flex !important; align-items: center; justify-content: center; gap: 10px; align-self: center;
  min-height: 44px; padding: 0 18px; margin: 4px auto 0; border-radius: 999px; border: 0; cursor: pointer;
  font: 600 14px var(--font); color: #ebedf6; background: rgba(12, 12, 35, 0.55);
  box-shadow: inset 0 0 0 1px rgba(167, 146, 252, 0.35); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
}
.x-hero .install-hint svg { width: 18px; height: 18px; fill: none; stroke: #a792fc; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.how li span { background: var(--grad-btn); color: #fff; font-family: var(--display); font-size: 18px; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35); }
.demo-tabs button { border-radius: 999px; min-height: 44px; }
.demo-tabs button[aria-pressed="true"] { background: var(--grad-btn); color: #fff; border-color: transparent; }
.aud-list li.on { border-color: rgba(255, 45, 125, 0.45); background: var(--accent-soft); }
html:not(.in-tg) body.landing .x-reel .home-demos { margin: 0; }
@media (min-width: 760px) {
  .x-sec { padding: 64px 0; }
  .x-trust > .x-art { height: 100%; opacity: 0.75; -webkit-mask-image: radial-gradient(90% 90% at 60% 40%, #000 40%, transparent 90%); mask-image: radial-gradient(90% 90% at 60% 40%, #000 40%, transparent 90%); }
}
.sheet-body { max-width: 100vw; box-sizing: border-box; }
.pw-terms { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.pw-term, .pw-term > * { min-width: 0; }
.pw-term em, .pw-term .pw-term-month { white-space: normal; overflow-wrap: anywhere; }
.pr-section > h2 { font-family: var(--font); font-size: var(--fs-cap); font-weight: 650; letter-spacing: var(--tr-caps); text-transform: uppercase; color: var(--eyebrow); }
.x-top .top-links a.desk { display: none !important; }
@media (min-width: 960px) { .x-top .top-links a.desk { display: inline-flex !important; } }
.x-mode-art.x-mode-art-xs { margin: 10px 0 14px; border-radius: var(--radius-l); }
.draft { border-radius: 14px; }
/* the night hero melts into the page below in either theme */
:root { --seam: #e6e9f4; }
:root:not([data-theme="light"]) { --seam: #08091a; }
:root[data-theme="dark"] { --seam: #08091a; }
.x-hero::after { opacity: 1; height: 80px; z-index: -1; background: linear-gradient(180deg, transparent, var(--seam)); }
@media (min-width: 440px) { .x-top .mk { width: 250px; } }
.x-hero .install-hint:not([hidden]) { width: auto; }
@media (min-width: 1000px) { .x-hero .install-hint:not([hidden]) { margin-left: 0; } .x-hero .auth-box { text-align: left; } }
.x-top .top-links { align-items: center; }
.x-top .top-links a.desk { align-items: center; min-height: 44px; margin: 0; padding: 0 12px; }
/* light theme: a crisp photo edge instead of the seam (a fade into cream read as a white band) */
:root { --seam: transparent; }
@media (min-width: 1000px) { .x-hero .code-toggle { margin-left: 0; } }
/* the switch follows the theme it sits in (night hero: dark glass; Mini App light: cream glass) */
.mk { background: linear-gradient(var(--glass), var(--glass)) padding-box, var(--edge) border-box; }
.mk-opt[aria-checked="false"] { color: var(--muted); }
@media (min-width: 1000px) {
  body[data-page="pricing"] .wrap { max-width: 820px; }
  body[data-page="pricing"] .x-pagehero { min-height: 340px; }
  body[data-page="pricing"] .x-mini4 ul { grid-template-columns: repeat(4, 1fr); }
}
.x-tiles .bigcard[data-mode] .x-art { height: clamp(160px, 52vw, 260px); }
@media (min-width: 760px) { .x-tiles .bigcard[data-mode] .x-art { height: 210px; } }
.x-pagehero.x-pagehero-s { min-height: clamp(220px, 32svh, 300px); }

/* ==================================================================================================================
   14. v5 COSMOS (17.11): deep space, neon pink + violet + teal, glass and thin lines, Geologica + JetBrains Mono.
   Everything below overrides the v4 layer above. Both themes through the tokens of section 1.
   ================================================================================================================== */
/* --- page: star dust + nebula (no image: layered radial dots), a faint grid near the top --- */
html, body { background-color: var(--bg); }
body { background: var(--page-glow); background-color: var(--bg); background-attachment: fixed; }
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none; opacity: 1;
  background:
    radial-gradient(1.2px 1.2px at 23px 41px, var(--star), transparent 70%) 0 0 / 211px 197px,
    radial-gradient(1px 1px at 141px 113px, var(--star), transparent 70%) 0 0 / 211px 197px,
    radial-gradient(0.8px 0.8px at 77px 160px, var(--star), transparent 70%) 0 0 / 211px 197px,
    radial-gradient(1.6px 1.6px at 190px 60px, var(--star), transparent 70%) 0 0 / 337px 293px,
    radial-gradient(1px 1px at 52px 230px, var(--star), transparent 70%) 0 0 / 337px 293px,
    radial-gradient(0.9px 0.9px at 260px 180px, var(--star), transparent 70%) 0 0 / 337px 293px,
    radial-gradient(2px 2px at 300px 20px, rgba(162, 139, 255, 0.9), transparent 70%) 0 0 / 523px 461px,
    radial-gradient(1.8px 1.8px at 120px 380px, rgba(255, 79, 163, 0.75), transparent 70%) 0 0 / 523px 461px,
    radial-gradient(1.6px 1.6px at 430px 300px, rgba(40, 224, 208, 0.7), transparent 70%) 0 0 / 523px 461px;
}
body::after {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(80% 45% at 50% 0%, rgba(0, 0, 0, 0.55), transparent 75%);
  mask-image: radial-gradient(80% 45% at 50% 0%, rgba(0, 0, 0, 0.55), transparent 75%);
}
html[data-theme="light"] body::before { opacity: 0.45; }
/* iPhone: the status bar never sits over moving text (installed app / edge-to-edge Safari) */
html::before {
  content: ""; position: fixed; top: 0; left: 0; right: 0; z-index: 60; pointer-events: none;
  height: max(env(safe-area-inset-top, 0px), 3px);
  background: var(--bg);
}
html.in-tg::before { display: none; }
.hist-bar { top: env(safe-area-inset-top, 0px); }
::selection { background: rgba(124, 92, 255, 0.4); color: var(--text); }

/* --- type: a technical grotesque, tight; numbers in mono --- */
h1, h2, .x-h1, .x-h2 { font-family: var(--display); font-weight: 650; letter-spacing: var(--tr-head); font-style: normal; }
h1 { font-size: clamp(30px, 8.4vw, 40px); line-height: 1.04; }
h2 { font-size: clamp(22px, 6vw, 28px); line-height: 1.1; }
.x-h1 em, h1 em, .x-grad-text { font-style: normal; background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; padding-right: 0.02em; }
.x-h2 { font-size: clamp(28px, 7.6vw, 52px); line-height: 1.02; letter-spacing: -0.035em; }
.x-eyebrow, .t-caps, .sec-title, .descriptor { font-family: var(--mono); font-weight: 600; letter-spacing: 0.14em; color: var(--eyebrow); }
.x-eyebrow::before, .sec-title::before { background: var(--grad); height: 1px; }
.mono, .num, .bal-num, .x-num, .code, .link-box, .inv-code { font-family: var(--mono); font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.pw-price, .x-big, .pr-big, .pw-term-price { font-family: var(--display); font-weight: 600; letter-spacing: -0.045em; font-variant-numeric: tabular-nums lining-nums; }

/* --- buttons: neon gradient with glow; secondary = glass with a hairline --- */
.btn { color: #fff; background: var(--grad-btn); font-family: var(--font); font-weight: 650; letter-spacing: 0; border-radius: 16px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28), 0 0 0 1px rgba(255, 46, 126, 0.35), 0 12px 34px -12px rgba(255, 46, 126, 0.65), 0 0 40px -14px rgba(124, 92, 255, 0.6); }
.btn:hover:not(:disabled) { background: var(--grad-btn-hover); }
.btn:active:not(:disabled) { background: var(--grad-btn-press); }
.btn.big { border-radius: 18px; }
.btn.secondary, .btn.ghost { color: var(--text); background: var(--glass); box-shadow: inset 0 0 0 1px var(--line-strong); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
.btn.secondary:hover:not(:disabled), .btn.ghost:hover:not(:disabled) { background: var(--glass); box-shadow: inset 0 0 0 1px var(--violet), 0 0 24px -8px rgba(124, 92, 255, 0.6); }
.btn.link { background: none; box-shadow: none; color: var(--muted); }
.btn::before, .btn::after { border-radius: inherit; }

/* --- glass cards and fields --- */
.card, .sheet-body, .pr-section, .hist-open, .aud-chip, .chip, .subcard, .code-card {
  background: linear-gradient(var(--glass), var(--glass)) padding-box, var(--edge) border-box;
  border: 1px solid transparent;
  -webkit-backdrop-filter: blur(16px) saturate(1.3); backdrop-filter: blur(16px) saturate(1.3);
}
.sheet-body { background: linear-gradient(var(--surface), var(--surface)) padding-box, var(--edge) border-box; }
select, input[type="text"], input[type="email"], input[type="tel"], textarea { background-color: var(--surface); color: var(--text); border-color: var(--line-strong); font-size: 16px; }
html[data-theme="light"] select, html[data-theme="light"] input[type="text"], html[data-theme="light"] input[type="email"], html[data-theme="light"] textarea { background-color: #ffffff; }
select:hover, input:hover, textarea:hover { border-color: rgba(124, 92, 255, 0.55); }
select:focus, input:focus, textarea:focus { border-color: var(--violet); box-shadow: 0 0 0 4px rgba(124, 92, 255, 0.18); }
.kv-tile { background: var(--tile); box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12), 0 8px 24px -8px rgba(255, 46, 126, 0.7); }
.wordmark span { background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* --- icon buttons (theme, profile) --- */
.icon-btn { display: inline-grid; place-items: center; width: 44px; height: 44px; min-width: 44px; padding: 0; border-radius: 14px; border: 0; cursor: pointer;
  color: var(--text); background: var(--glass); box-shadow: inset 0 0 0 1px var(--line-strong); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
.icon-btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon-btn:hover { box-shadow: inset 0 0 0 1px var(--violet), 0 0 18px -6px rgba(124, 92, 255, 0.7); }
.theme-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 14px 0; }
.theme-row-label { color: var(--muted); font-size: 14.5px; }
.theme-seg { display: inline-flex; padding: 3px; border-radius: 14px; background: var(--glass); box-shadow: inset 0 0 0 1px var(--line-strong); }
.theme-seg button { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px; border: 0; border-radius: 11px; background: none; color: var(--muted); font: 600 14.5px var(--font); cursor: pointer; }
.theme-seg button svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.theme-seg button[aria-checked="true"] { color: #fff; background: var(--grad-btn); box-shadow: 0 6px 18px -8px rgba(255, 46, 126, 0.8); }

/* --- scenes follow the theme --- */
html[data-theme="light"] .sc { --sc-bg: #eef1fa; --sc-bg2: #ffffff; --sc-ink: rgba(11, 13, 26, 0.85); --sc-dim: rgba(11, 13, 26, 0.38); --sc-line: rgba(11, 13, 26, 0.12); --sc-cogdeep: #dcd6ff; --sc-pinkdeep: #b9a8ff; }

/* --- top bar (landing): glass strip that follows the theme --- */
.x-top { position: absolute; }
.x-top .brand { color: var(--text); }
.x-top .top-links { display: flex; gap: 8px; }
.x-top .top-links a.desk { color: var(--text-soft); }
.x-top .top-links a.desk { display: none !important; }
@media (min-width: 900px) { .x-top .top-links a.desk { display: inline-flex !important; } }

/* --- HERO v5: space, globe, phone, two voice waves --- */
.x-hero { background: transparent; min-height: 0; padding: calc(max(10px, var(--safe-t)) + 70px) 0 28px; color: var(--text); }
.x-hero::after { display: none; }
.x-cosmos { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.x-cosmos > .x-art { position: absolute; left: 50%; top: 52%; width: min(980px, 190vw); aspect-ratio: 1; transform: translate(-50%, -50%); background: none; }
.x-cosmos svg.sc { background: transparent; }
.x-cosmos .sc-vgr { display: none; }
.x-cosmos::after { content: ""; position: absolute; inset: 0; background: radial-gradient(60% 50% at 50% 50%, transparent 40%, var(--bg) 100%); opacity: 0.55; }
.x-hero .x-wrap { position: relative; }
.x-hero-copy { text-align: center; max-width: 720px; margin: 0 auto; }
.x-live { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 14px; padding: 7px 14px 7px 12px; border-radius: 999px;
  font: 600 11.5px/1.2 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-soft);
  background: var(--glass); box-shadow: inset 0 0 0 1px var(--line-strong); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
.x-live i { width: 8px; height: 8px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 0 0 rgba(40, 224, 208, 0.6); animation: x-ping 2s ease-out infinite; }
@keyframes x-ping { 0% { box-shadow: 0 0 0 0 rgba(40, 224, 208, 0.55); } 80%, 100% { box-shadow: 0 0 0 9px rgba(40, 224, 208, 0); } }
.x-h1 { font-size: clamp(38px, 11.2vw, 92px); line-height: 0.98; letter-spacing: -0.045em; color: var(--text); font-weight: 650; }
.x-h1 > span { display: inline; }
.x-h1 em { display: inline-block; }
.x-sub { margin: 14px auto 0; max-width: 34ch; color: var(--muted); font-size: 16px; line-height: 1.45; }
.x-stage { height: min(380px, 44svh); margin: 18px 0 8px; }
.x-wave { position: absolute; left: -20%; right: -20%; top: 50%; height: 46%; transform: translateY(-10%); z-index: 0; pointer-events: none; }
.x-wave svg.sc { background: transparent; }
.x-wave .sc-bgr, .x-wave .sc-vgr { display: none; }
.x-film { z-index: 1; background: var(--bg-2); border-radius: 34px;
  box-shadow: 0 0 0 1px rgba(200, 190, 255, 0.28), 0 0 0 6px rgba(5, 6, 15, 0.9), 0 0 0 7px rgba(124, 92, 255, 0.4), 0 40px 80px -30px rgba(0, 0, 0, 0.9), 0 0 90px -20px rgba(255, 46, 126, 0.55), 0 0 140px -30px rgba(124, 92, 255, 0.6); }
html[data-theme="light"] .x-film { box-shadow: 0 0 0 1px rgba(20, 26, 60, 0.18), 0 0 0 6px #ffffff, 0 0 0 7px rgba(124, 92, 255, 0.35), 0 40px 70px -30px rgba(30, 36, 90, 0.45), 0 0 90px -20px rgba(255, 46, 126, 0.35); }
.x-halo { display: none; }
.x-bub { z-index: 3; max-width: 60%; color: var(--text); background: var(--glass); border: 1px solid var(--line-strong); font: 600 13.5px/1.3 var(--font); padding: 9px 13px; }
.x-bub b { font-family: var(--mono); font-weight: 600; letter-spacing: 0.06em; font-size: 10.5px; color: var(--cyan); }
html[data-theme="light"] .x-bub b { color: #0b8f84; }
.x-bub.b2 { color: #fff; background: linear-gradient(120deg, rgba(255, 46, 126, 0.95), rgba(124, 92, 255, 0.95)); border-color: rgba(255, 255, 255, 0.2); }
.x-bub.b2 b { color: #fff; }
.x-bub.b1 { left: 2%; top: 10%; }
.x-bub.b2 { right: 2%; top: 58%; }
.x-cta-row { max-width: 440px; margin: 10px auto 0; width: 100%; }
.x-note { display: flex; justify-content: center; align-items: center; gap: 10px; flex-wrap: wrap; color: var(--muted); font-size: 13.5px; }
.x-free { display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px; border-radius: 999px; font: 600 12.5px var(--mono); letter-spacing: 0; color: var(--text);
  background: rgba(40, 224, 208, 0.12); box-shadow: inset 0 0 0 1px rgba(40, 224, 208, 0.45); }
.x-free::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--cyan); }
.x-free[hidden] { display: none; }
.x-note > span + span::before { content: none; }
.x-hero .code-toggle { color: var(--muted); }
.x-hero .chip { margin: 0 auto; }
@media (min-width: 1000px) {
  .x-hero { padding-top: 120px; padding-bottom: 60px; min-height: min(860px, 100svh); display: flex; align-items: center; }
  .x-hero .x-wrap { grid-template-columns: 1.05fr 0.95fr; grid-template-areas: "copy stage" "cta stage"; align-items: center; column-gap: 40px; }
  .x-hero-copy { grid-area: copy; text-align: left; margin: 0; align-self: end; }
  .x-sub { margin-left: 0; }
  .x-stage { grid-area: stage; height: min(600px, 70svh); margin: 0; }
  .x-cta-row { grid-area: cta; margin: 26px 0 0; align-self: start; }
  .x-note { justify-content: flex-start; }
  .x-cosmos > .x-art { left: 72%; width: 1100px; }
}

/* --- mode tiles: a scene, the name, the free try; no paragraph --- */
.x-modes .cards { grid-template-columns: 1fr 1fr; gap: 12px; }
.bigcard[data-mode] { background: linear-gradient(var(--card), var(--card)) padding-box, var(--edge) border-box; border-radius: 24px; box-shadow: var(--shadow-s); }
.bigcard[data-mode]:hover:not(:disabled) { box-shadow: var(--shadow-s), 0 0 0 1px rgba(124, 92, 255, 0.45), 0 0 40px -12px rgba(124, 92, 255, 0.6); }
.bigcard[data-mode] .x-art { aspect-ratio: auto; height: clamp(140px, 40vw, 260px); }
.bigcard[data-mode] .txt { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 4px; }
.bigcard[data-mode] .txt > b { font-family: var(--display); font-weight: 650; font-size: clamp(17px, 4.6vw, 26px); line-height: 1.08; letter-spacing: -0.03em; margin: 0; }
.bigcard[data-mode] .txt > span { display: none; }
.bigcard[data-mode] .txt > span.x-dict-cap { display: block; font: 600 12px/1.3 var(--mono); color: var(--eyebrow); letter-spacing: 0; }
.bigcard[data-mode] .x-go { display: none; }
.bigcard[data-mode] .trial-tag { top: 10px; left: 10px; padding: 6px 10px; font: 600 11px/1 var(--mono); letter-spacing: 0; text-transform: none; color: #fff;
  background: rgba(5, 6, 15, 0.62); border: 1px solid rgba(40, 224, 208, 0.6); box-shadow: 0 0 16px -4px rgba(40, 224, 208, 0.6); }
.bigcard[data-mode] .trial-tag::before { content: ""; display: inline-block; width: 6px; height: 6px; margin-right: 6px; border-radius: 50%; background: var(--cyan); vertical-align: 1px; }
.bigcard[data-mode] .trial-tag.approx { border-color: var(--line-strong); box-shadow: none; }
.bigcard[data-mode] .trial-tag.approx::before { display: none; }
.x-tiles .bigcard[data-mode] .trial-tag { font-size: 10.5px; }
.x-modes .subcard, .x-tiles .subcard { grid-column: 1 / -1; }
@media (min-width: 900px) {
  .x-modes .cards { grid-template-columns: repeat(4, 1fr); gap: 16px; }
  .bigcard[data-mode] .x-art { height: 240px; }
}

/* --- dictation: rambling speech -> a ready message (tile, mode screen) --- */
.x-dict-art { position: relative; display: block; overflow: hidden; isolation: isolate;
  background: radial-gradient(80% 70% at 100% 100%, rgba(124, 92, 255, 0.35), transparent 60%), radial-gradient(70% 60% at 0% 0%, rgba(255, 46, 126, 0.22), transparent 60%), var(--bg-2); }
html[data-theme="light"] .x-dict-art { background: radial-gradient(80% 70% at 100% 100%, rgba(124, 92, 255, 0.18), transparent 60%), radial-gradient(70% 60% at 0% 0%, rgba(255, 46, 126, 0.12), transparent 60%), #eef1fa; }
.x-dict { position: absolute; inset: 0; display: grid; grid-template-rows: auto auto 1fr; align-content: center; gap: 4px; padding: 30px 10px 10px; }
.x-dict-raw, .x-dict-clean { display: block; border-radius: 14px; padding: 7px 9px 8px; font-size: 10.5px; line-height: 1.35; text-align: left; }
.x-dict-raw b, .x-dict-clean b { display: block; margin-bottom: 2px; font: 600 9px/1.2 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; }
.x-dict-raw { color: var(--muted); background: var(--glass); border: 1px dashed var(--line-strong); max-width: 92%; font-style: italic; }
.x-dict-raw b { color: var(--muted); font-style: normal; }
.x-dict-clean { justify-self: end; max-width: 94%; color: #fff; font-weight: 600; background: linear-gradient(120deg, rgba(255, 46, 126, 0.95), rgba(124, 92, 255, 0.95));
  box-shadow: 0 10px 30px -12px rgba(255, 46, 126, 0.8); animation: x-dict-in 6s var(--ease-out) infinite; }
.x-dict-clean b { color: rgba(255, 255, 255, 0.85); }
.x-dict-arrow { justify-self: center; width: 22px; height: 22px; display: grid; place-items: center; border-radius: 50%; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line-strong); }
.x-dict-arrow svg { width: 13px; height: 13px; fill: none; stroke: var(--cyan); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; animation: x-dict-arrow 6s ease-in-out infinite; }
@keyframes x-dict-in { 0%, 18% { opacity: 0; transform: translateY(8px) scale(0.96); clip-path: inset(0 100% 0 0 round 14px); } 40%, 88% { opacity: 1; transform: none; clip-path: inset(0 0 0 0 round 14px); } 100% { opacity: 0; transform: none; clip-path: inset(0 0 0 0 round 14px); } }
@keyframes x-dict-arrow { 0%, 10% { transform: translateY(-3px); opacity: 0.4; } 25% { transform: translateY(2px); opacity: 1; } 40%, 100% { transform: none; opacity: 1; } }
@media (min-width: 420px) { .x-dict-raw, .x-dict-clean { font-size: 11.5px; } }
@media (min-width: 900px) { .x-dict { padding: 34px 14px 14px; } .x-dict-raw, .x-dict-clean { font-size: 12.5px; } }
/* the big variant on the message screen */
.x-dict-hero { position: relative; margin: 4px 0 16px; border-radius: var(--radius-l); min-height: 250px; overflow: hidden; box-shadow: inset 0 0 0 1px var(--line); }
.x-dict-hero .x-dict { padding: 46px 16px 16px; gap: 8px; }
.x-dict-hero .x-dict-raw, .x-dict-hero .x-dict-clean { font-size: 14.5px; padding: 10px 13px 11px; border-radius: 18px; }
.x-dict-hero .x-dict-raw b, .x-dict-hero .x-dict-clean b { font-size: 10px; }
.x-dict-hero .x-dict-arrow { width: 30px; height: 30px; }
.x-dict-hero .x-dict-arrow svg { width: 16px; height: 16px; }
.x-dict-hero > .x-dict-title { position: absolute; top: 14px; left: 16px; right: 16px; margin: 0; font: 600 12px/1.3 var(--mono); letter-spacing: 0.04em; color: var(--eyebrow); z-index: 1; }

/* --- how it works / trust / price / final: tokens, no warm or fixed dark panels --- */
.x-how li { background: linear-gradient(var(--card), var(--card)) padding-box, var(--edge) border-box; }
.x-how .x-num { font-family: var(--mono); font-style: normal; font-weight: 600; font-size: 13px; line-height: 1; padding: 6px 9px; border-radius: 8px; color: var(--text); background: var(--accent-soft); box-shadow: inset 0 0 0 1px rgba(255, 46, 126, 0.4); -webkit-background-clip: border-box; background-clip: border-box; grid-row: auto; }
.x-how .x-step { grid-template-columns: auto 1fr; align-items: center; }
.x-how b { font-size: 22px; font-weight: 650; letter-spacing: -0.03em; }
.x-trust { color: var(--text); background: radial-gradient(90% 60% at 80% 0%, rgba(255, 46, 126, 0.22), transparent 60%), radial-gradient(80% 60% at 0% 100%, rgba(124, 92, 255, 0.3), transparent 60%), var(--bg-2);
  border: 1px solid var(--line); box-shadow: var(--shadow-s); }
html[data-theme="light"] .x-trust { background: radial-gradient(90% 60% at 80% 0%, rgba(255, 46, 126, 0.1), transparent 60%), radial-gradient(80% 60% at 0% 100%, rgba(124, 92, 255, 0.14), transparent 60%), #ffffff; }
.x-big { font-size: clamp(120px, 38vw, 220px); }
.x-big-cap { font-family: var(--mono); color: var(--eyebrow); letter-spacing: 0.12em; }
.x-facts { grid-template-columns: repeat(3, 1fr); gap: 8px; }
.x-facts li { flex-direction: column; text-align: center; gap: 8px; padding: 14px 6px; background: var(--glass); border: 1px solid var(--line); }
.x-facts svg { stroke: #fff; background: var(--grad); }
.x-facts b { font-size: 13px; line-height: 1.25; }
.teaser.x-price { color: var(--text); background: radial-gradient(80% 70% at 100% 100%, rgba(255, 46, 126, 0.25), transparent 60%), radial-gradient(70% 60% at 0% 0%, rgba(124, 92, 255, 0.3), transparent 60%), var(--bg-2); border: 1px solid var(--line); }
html[data-theme="light"] .teaser.x-price { background: radial-gradient(80% 70% at 100% 100%, rgba(255, 46, 126, 0.1), transparent 60%), radial-gradient(70% 60% at 0% 0%, rgba(124, 92, 255, 0.14), transparent 60%), #ffffff; }
.teaser.x-price h3 { font-family: var(--mono); color: var(--eyebrow); letter-spacing: 0.14em; }
.teaser.x-price .pw-price { font-size: clamp(60px, 18vw, 110px); }
.teaser.x-price .pw-price small { font-family: var(--mono); font-size: 14px; letter-spacing: 0; color: var(--muted); }
.teaser.x-price p { color: var(--muted); }
.teaser.x-price .btn { color: var(--text); box-shadow: inset 0 0 0 1px var(--line-strong); }
.teaser.x-price > .x-art .sc-bgr, .teaser.x-price > .x-art .sc-vgr { display: none; }
.teaser.x-price > .x-art svg.sc { background: transparent; }
.x-final { min-height: min(560px, 80svh); color: var(--text); }
.x-final .x-h2 { color: var(--text); }
.x-final .x-art.x-final-art { inset: 0; height: auto; opacity: 0.9; -webkit-mask-image: radial-gradient(70% 70% at 50% 40%, #000 30%, transparent 85%); mask-image: radial-gradient(70% 70% at 50% 40%, #000 30%, transparent 85%); }
.x-final .x-art.x-final-art svg.sc { background: transparent; }
.x-final .x-wrap { display: flex; flex-direction: column; align-items: center; }
.x-final .btn { width: 100%; }
.demo-card { background: var(--bg-2); box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.8), 0 0 0 1px var(--line-strong); }

/* --- Mini App: same space, no texture photo --- */
html.in-tg body { background: var(--page-glow); background-color: var(--bg); background-attachment: fixed; }
html.in-tg[data-theme="light"] body { background: var(--page-glow); background-color: var(--bg); }
.x-tgtop .icon-btn { flex: none; }
.x-tiles .bigcard[data-mode] .x-art { height: clamp(140px, 42vw, 230px); }
.x-tiles .bigcard[data-mode] .txt > b { font-size: clamp(16px, 4.4vw, 21px); }

/* --- inner pages: page head with a theme button, pricing hero without photo --- */
.x-mini4 li { background: var(--bg-2); }
.x-mini4 b { color: #fff; }
.x-pagehero h1, body[data-page="pricing"] .x-pagehero h1 { color: var(--text); font-family: var(--display); font-weight: 650; letter-spacing: -0.04em; }
.x-pagehero p { color: var(--muted); }

/* --- Cloudflare Turnstile: a quiet glass frame in the palette --- */
.kv-turnstile { display: flex; justify-content: center; min-height: 0; margin: 10px auto; padding: 6px; border-radius: 14px; background: var(--glass); box-shadow: inset 0 0 0 1px var(--line); max-width: 320px; }
.kv-turnstile:empty { display: none; }
.kv-turnstile iframe { border-radius: 10px; }

/* --- motion --- */
@media (prefers-reduced-motion: reduce) {
  .x-live i, .x-dict-clean, .x-dict-arrow svg { animation: none !important; }
  .x-dict-clean { opacity: 1; clip-path: none; }
}
/* narrow phones: brand tile + switch + theme + profile in one row; the headline in two lines, no sub line */
@media (max-width: 439px) {
  .x-top .x-wrap { gap: 6px; }
  .x-top .mk, .x-tgtop .mk { width: 140px; }
  .x-top .brand .wordmark { display: none; }
  .x-h1 { font-size: clamp(30px, 9.4vw, 40px); line-height: 1.02; }
  .x-h1 > span, .x-h1 em { display: block; }
  .x-sub { display: none; }
  .x-live { margin-bottom: 10px; }
}
@media (max-width: 439px) and (min-width: 400px) { .x-top .brand .wordmark { display: inline; font-size: 20px; } .x-top .mk { width: 132px; } }
/* v5 tuning after the first shots */
.x-stage { height: min(440px, 52svh); }
@media (min-width: 1000px) { .x-stage { height: min(600px, 70svh); } }
body.landing .x-modes .aud-chips { display: none; }
.x-hero .install-hint:not([hidden]) { color: var(--text); background: var(--glass); box-shadow: inset 0 0 0 1px var(--line-strong); }
.bigcard[data-mode] .x-art, .x-tiles .bigcard[data-mode] .x-art { height: clamp(150px, 48vw, 260px); }
.bigcard[data-mode] .txt > b, .x-tiles .bigcard[data-mode] .txt > b { font-size: clamp(16px, 4.3vw, 24px); }
.bigcard[data-mode] .trial-tag { white-space: nowrap; max-width: calc(100% - 20px); overflow: hidden; text-overflow: ellipsis; }
.x-dict { padding: 38px 9px 9px; gap: 3px; align-content: start; }
.x-dict-raw > span, .x-dict-clean > span { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }
.x-dict-art .x-dict-raw > span { -webkit-line-clamp: 2; }
.x-dict-hero .x-dict-raw > span, .x-dict-hero .x-dict-clean > span { -webkit-line-clamp: unset; display: block; }
.x-dict-hero .x-dict { padding-top: 46px; }
#msgMain:has(#resultBox:not([hidden])) .x-dict-hero, #msgMain:has(#liveBox:not([hidden])) .x-dict-hero { display: none; }
.page-head { display: flex; align-items: center; gap: 10px; }
.page-head .page-theme { margin-left: 4px; flex: none; }
.x-dict-hero { min-height: 0; }
.x-dict-hero .x-dict { position: relative; inset: auto; padding: 44px 14px 16px; }
.x-stage { height: min(470px, 56svh); }
@media (min-width: 1000px) {
  .x-stage { height: min(620px, 72svh); }
  .x-h1 { font-size: clamp(56px, 5.6vw, 80px); }
  .x-h1 > span, .x-h1 em { display: block; }
  .x-top .top-links { align-items: center; }
  .x-top .top-links a.desk { min-height: 44px; align-items: center; padding: 0 14px; border-radius: 12px; }
}
html.in-tg .x-tiles .bigcard[data-mode] .x-art { height: clamp(160px, 54vw, 260px); }
html.in-tg #vHome .sub-box { margin-bottom: 10px; }
/* v5: fewer words on the mode screens: the hints under the hints go (the scene and the field speak for themselves) */
[data-t="codeHint"], [data-t="trialHint"], [data-t="origHint"], [data-t="pickHint"], [data-t="subCodeHint"] { display: none !important; }
.kvs-art { height: 150px; margin: -6px -4px 12px; border-radius: 22px; }
.kvs-art + .kvs-mark { display: none; }
@media (max-width: 439px) {
  .x-live { display: none; }
  .x-h1 { font-size: clamp(28px, 8.6vw, 36px); }
  .x-hero { padding-top: calc(max(10px, var(--safe-t)) + 66px); }
  .x-stage { height: min(500px, 60svh); margin-top: 12px; }
  .x-hero .btn.big { min-height: 56px; }
}
.bigcard[data-mode] .txt > b, .bigcard[data-mode] .txt > span.x-dict-cap, .x-h1 > span, .x-h1 em, .x-how b, .x-facts b { width: fit-content; max-width: 100%; }
.x-hero-copy .x-h1 { display: flex; flex-direction: column; align-items: center; }
@media (min-width: 1000px) { .x-hero-copy .x-h1 { align-items: flex-start; } }
/* v5 contrast: white labels on the neon gradient stay at 4.5:1 or more */
:root {
  --grad-btn: linear-gradient(110deg, #e0136b 0%, #c02a8c 50%, #7a3ff0 100%);
  --grad-btn-hover: linear-gradient(110deg, #e3166d 0%, #c8308f 50%, #8247f2 100%);
  --grad-btn-press: linear-gradient(110deg, #c70f5c 0%, #a8257c 50%, #6a33dc 100%);
}
.x-bub.b2, .x-dict-clean { background: linear-gradient(120deg, #d61a72, #6d3ef0); }
html[data-theme="light"] .x-bub b { color: #08776e; }
html[data-theme="light"] .x-bub.b2 b { color: #fff; }
@media (max-width: 699px) { .x-mode-art:not(.x-mode-art-s):not(.x-mode-art-xs) { height: clamp(260px, 50svh, 440px); } }
.bigcard[data-mode] .trial-tag { font-family: var(--font); font-weight: 650; font-size: 11px; letter-spacing: 0; }
@media (max-width: 419px) {
  .x-dict-art .x-dict { padding-top: 34px; gap: 2px; }
  .x-dict-art .x-dict-raw, .x-dict-art .x-dict-clean { font-size: 10px; padding: 6px 8px 7px; }
  .x-dict-art .x-dict-arrow { width: 18px; height: 18px; }
}
@media (min-width: 440px) and (max-width: 999px) {
  .x-h1 { font-size: clamp(40px, 7.4vw, 60px); }
  .x-h1 > span, .x-h1 em { display: inline; }
  .x-hero-copy .x-h1 { display: block; }
  .x-stage { height: min(520px, 50svh); }
  .x-bub.b1 { left: 8%; } .x-bub.b2 { right: 8%; }
}
.x-dict { grid-template-columns: minmax(0, 1fr); } .x-dict-raw, .x-dict-clean { min-width: 0; overflow-wrap: break-word; }

/* ============ v6: the demo strip near the top (site: right under the hero; Mini App: under the status, compact) ============ */
.x-reel { padding: 6px 0 10px; }
@media (min-width: 760px) { .x-reel { padding: 8px 0 24px; } }
/* v7: (the Mini App films strip is the web one; its compact cards were removed here) */

/* ==================================================================================================================
   v7 (17.11): Mini App home = web home; light theme fixes (owner's iPhone shots); support; trial-over lead line
   ================================================================================================================== */
/* the Mini App: the web blocks edge to edge, the compact status row on top (tg.html, landing.js) */
html.in-tg .landing-tg { margin-left: calc(-1 * var(--gutter)); margin-right: calc(-1 * var(--gutter)); }
html.in-tg .landing-tg .x-hero { padding-top: 6px; }
html.in-tg #vHome .sub-box { margin: 0 0 4px; }
html.in-tg #vHome .linkbtn { justify-content: flex-start; }
html.in-tg .landing-tg .foot-nav { padding-bottom: max(28px, var(--tg-bottom, 0px)); }
.bigcard.is-wait { opacity: 0.85; }

/* status-bar guard: opaque in the colour of the theme, blurred edge; iOS draws the clock over it, never over text */
html::before { background: var(--bg); -webkit-backdrop-filter: saturate(1.4) blur(14px); backdrop-filter: saturate(1.4) blur(14px); box-shadow: 0 1px 0 var(--line); }

/* light theme: the free-try pills were dark grey glass on white */
html[data-theme="light"] .bigcard[data-mode] .trial-tag:not(.approx) {
  color: #0b0d1a; background: rgba(255, 255, 255, 0.86); border: 1px solid rgba(124, 92, 255, 0.28);
  box-shadow: 0 6px 18px -10px rgba(60, 40, 140, 0.45);
}
html[data-theme="light"] .bigcard[data-mode] .trial-tag::before { background: #0fa39a; }
html[data-theme="light"] .bigcard[data-mode] .trial-tag.approx { color: #2a2f45; background: rgba(255, 255, 255, 0.86); }
html[data-theme="light"] .x-free { color: #0b0d1a; background: rgba(255, 255, 255, 0.8); border-color: rgba(15, 163, 154, 0.45); }

/* light theme: the price band is a white card, so its text uses the light tokens (it carried the night ones: 2 999 ₽
   white on white); the price itself in the brand gradient (dark enough for 4.5:1 on white) */
html[data-theme="light"] .teaser.x-price {
  --text: #0b0d1a; --text-soft: #2a2f45; --muted: #555b74; --line: rgba(20, 26, 60, 0.1); --line-strong: rgba(20, 26, 60, 0.2);
  --glass: rgba(255, 255, 255, 0.72); --eyebrow: #5a3fd6; color: var(--text);
}
html[data-theme="light"] .teaser.x-price .pw-price { color: #b0145e; background: linear-gradient(100deg, #c8125f 0%, #a01e86 45%, #5b34d6 100%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
html[data-theme="light"] .teaser.x-price .pw-price small { -webkit-text-fill-color: #555b74; color: #555b74; }
/* "Все тарифы": the brand button in both themes (was a grey glass one) */
.teaser.x-price .btn, .teaser.x-price .btn.secondary {
  color: #fff; background: linear-gradient(110deg, #e0136b 0%, #c02a8c 50%, #7a3ff0 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28), 0 0 0 1px rgba(255, 46, 126, 0.35), 0 12px 34px -12px rgba(255, 46, 126, 0.65);
  -webkit-backdrop-filter: none; backdrop-filter: none;
}
.teaser.x-price .btn:hover { filter: brightness(1.06); }

/* the globe tapped a language: the four modes blink once */
@keyframes kv-flash { 0% { box-shadow: 0 0 0 0 rgba(255, 46, 126, 0); } 30% { box-shadow: 0 0 0 3px rgba(255, 46, 126, 0.55), 0 0 40px -6px rgba(124, 92, 255, 0.7); } 100% { box-shadow: 0 0 0 0 rgba(255, 46, 126, 0); } }
#cards.kv-flash .bigcard[data-mode] { animation: kv-flash 1.3s var(--ease) 0.35s 1; }
@media (prefers-reduced-motion: reduce) { #cards.kv-flash .bigcard[data-mode] { animation: none; } }

/* support, partnerships, offers: a quiet section in the footer and the profile */
.kv-support { margin: 0 0 22px; padding: 16px 18px; border-radius: var(--radius); background: var(--glass); border: 1px solid var(--line); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
.kv-support:empty { display: none; }
.kv-sup-title { margin: 0 0 12px; font: 600 12px/1.3 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--eyebrow, var(--muted)); }
.kv-sup-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; }
.kv-sup-tg { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; border-radius: 999px; text-decoration: none; font: 600 15px/1 var(--font);
  color: #fff; background: linear-gradient(110deg, #e0136b 0%, #c02a8c 50%, #7a3ff0 100%); box-shadow: 0 10px 26px -14px rgba(255, 46, 126, 0.7); }
.kv-sup-tg svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linejoin: round; }
.kv-sup-mailbox { display: inline-flex; align-items: center; gap: 4px; min-width: 0; }
.kv-sup-mail { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; color: var(--text); font: 500 15px/1.2 var(--font); text-decoration: none; overflow-wrap: anywhere; }
.kv-sup-mail svg, .kv-sup-copy svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.kv-sup-mail:hover span { text-decoration: underline; text-underline-offset: 3px; }
.kv-sup-copy { display: inline-grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 12px; background: transparent; color: var(--muted); cursor: pointer; }
.kv-sup-copy:hover { color: var(--text); background: var(--line); }
.kv-sup-copy.is-done { color: #0fa39a; }
.kv-sup-done { font: 600 12.5px/1 var(--font); color: #0fa39a; }
:root:not([data-theme="light"]) .kv-sup-copy.is-done, :root:not([data-theme="light"]) .kv-sup-done { color: var(--cyan); }
.pr-support { margin-top: 18px; }

/* the free try is over (guest): one optional line under the heading */
.pw-lead { display: inline-flex; align-items: center; min-height: 40px; margin: 8px 0 0; padding: 0; border: 0; background: none; cursor: pointer;
  font: 600 14.5px/1.3 var(--font); color: var(--eyebrow, #a28bff); text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; }
:root:not([data-theme="light"]) .pw-lead { color: #c8b9ff; }

/* light theme: the final call sits on the light page, so its heading uses the light tokens (it was white on white) */
html[data-theme="light"] .x-final.x-night { --text: #0b0d1a; --text-soft: #2a2f45; --muted: #555b74; --line: rgba(20, 26, 60, 0.1); color: var(--text); }
html[data-theme="light"] .x-final .x-h2 { color: #0b0d1a; }
/* the period next to the price never breaks into its own tall line */
.teaser.x-price .pw-price small { display: inline-block; white-space: nowrap; line-height: 1.2; }/* light theme: the lock of a used free try is a light glass button with a brand-coloured lock (was dark grey) */
html[data-theme="light"] .bigcard[data-mode] > .lock { background: rgba(255, 255, 255, 0.88); stroke: #a01e86; color: #a01e86; border: 1px solid rgba(124, 92, 255, 0.28); box-shadow: 0 6px 18px -10px rgba(60, 40, 140, 0.45); }