/* PROXIMA — дизайн-система.
   Layout: одна колонка-«борт» до 1080px на чёрном космосе; HUD-сетка, моно-подписи [ 01 ], широкий дисплей капсом, один оранжевый неон. */
:root {
  --void: #050506;
  --hull: #0d0d0f;
  --panel: #131316;
  --line: rgba(255, 255, 255, .09);
  --line-2: rgba(255, 255, 255, .18);
  --text: #ecebe8;
  --dim: #8d8b87;
  --mute: #55534f;
  --ion: #ff5a1f;
  --ion-hot: #ff8a3d;
  --ion-glow: rgba(255, 90, 31, .45);
  --ok: #7dffb0;
  --f-display: 'Unbounded', 'Arial Black', system-ui, sans-serif;
  --f-body: 'Manrope', 'Segoe UI', system-ui, sans-serif;
  --f-mono: 'JetBrains Mono', ui-monospace, 'Consolas', monospace;
  --r: 14px;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { background: var(--void); }
body {
  margin: 0; min-height: 100vh;
  background: var(--void); color: var(--text);
  font: 400 16px/1.6 var(--f-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body::after { /* зерно */
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 50; opacity: .07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
#stars { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--ion); outline-offset: 3px; }

.ship {
  position: relative; z-index: 1;
  max-width: 1080px; margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
  padding-block: 18px 80px;
}

/* ── HUD-моно ── */
.mono, .hud { font-family: var(--f-mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; }
.hud { color: var(--dim); }
.br { color: var(--mute); }
.br b { color: var(--text); font-weight: 500; margin: 0 .5em; }
.ion { color: var(--ion); }

/* ── шапка ── */
.top { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.top a { text-decoration: none; }
.logo-mini { font-family: var(--f-display); font-weight: 800; font-size: 13px; letter-spacing: .12em; }
.logo-mini .ion { font-family: var(--f-mono); font-weight: 500; }

/* ── HERO ── */
.hero { position: relative; padding-top: 22px; }
.hero-grid { position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 64px 64px; mask-image: linear-gradient(#000 40%, transparent); opacity: .55; }
.wordmark {
  position: relative; margin: 0;
  font-family: var(--f-display); font-weight: 900; text-transform: uppercase;
  font-size: clamp(54px, 15.2vw, 168px); line-height: .86; letter-spacing: -.02em;
  background: linear-gradient(180deg, #fff 0%, #d9d6d0 55%, #6f6b66 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.navline { position: relative; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 18px; margin: 18px 0 0; padding: 0; list-style: none; }
.navline a { text-decoration: none; display: inline-flex; gap: .2em; }
.navline a span { color: var(--ion); }
.navline a[aria-current="page"] span, .navline a:hover span { color: var(--ion-hot); text-shadow: 0 0 12px var(--ion-glow); }
.navline a[aria-current="page"] { color: var(--text); }

.planet-wrap { position: relative; display: grid; grid-template-columns: 1fr; gap: 24px; margin-top: 28px; }
.planet { position: relative; aspect-ratio: 1.55; max-width: 100%; border-radius: var(--r); overflow: hidden; border: 1px solid var(--line); background: #000; }
.planet canvas { width: 100%; height: 100%; display: block; }
.reticle { position: absolute; width: 22px; height: 22px; border-color: var(--line-2); border-style: solid; }
.reticle.tl { top: 14px; left: 14px; border-width: 1px 0 0 1px; }
.reticle.tr { top: 14px; right: 14px; border-width: 1px 1px 0 0; }
.reticle.bl { bottom: 14px; left: 14px; border-width: 0 0 1px 1px; }
.reticle.br2 { bottom: 14px; right: 14px; border-width: 0 1px 1px 0; }
.coords { position: absolute; left: 18px; bottom: 16px; color: var(--dim); line-height: 1.7; }
.barcode { position: absolute; right: 18px; top: 50%; transform: translateY(-50%); writing-mode: vertical-rl; display: flex; gap: 6px; align-items: center; color: var(--mute); }
.barcode i { display: block; width: 26px; height: 92px; background: repeating-linear-gradient(0deg, var(--dim) 0 1px, transparent 1px 3px, var(--dim) 3px 5px, transparent 5px 6px, var(--dim) 6px 7px, transparent 7px 10px); opacity: .7; }

.claim { display: grid; gap: 18px; }
.claim h2 { margin: 0; font-family: var(--f-display); font-weight: 800; text-transform: uppercase; font-size: clamp(24px, 4.4vw, 40px); line-height: 1.02; text-wrap: balance; }
.claim p { margin: 0; color: var(--dim); max-width: 46ch; font-size: 15px; }

/* ── прогресс: дистанция до Проксимы ── */
.dist { margin-top: 28px; padding: 18px; border: 1px solid var(--line); border-radius: var(--r); background: rgba(13,13,15,.75); backdrop-filter: blur(6px); display: grid; gap: 14px; }
.dist-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.dist-num { font-family: var(--f-display); font-weight: 700; font-size: clamp(30px, 7vw, 54px); line-height: 1; font-variant-numeric: tabular-nums; }
.dist-num small { font-family: var(--f-mono); font-size: 12px; font-weight: 400; color: var(--dim); letter-spacing: .12em; margin-left: .4em; }
.track { position: relative; height: 8px; border-radius: 8px; background: repeating-linear-gradient(90deg, var(--line-2) 0 1px, transparent 1px 10px); }
.track b { position: absolute; inset: 0 auto 0 0; border-radius: 8px; background: linear-gradient(90deg, #7a2a0c, var(--ion)); box-shadow: 0 0 18px var(--ion-glow); }
.track b::after { content: ""; position: absolute; right: -5px; top: 50%; width: 10px; height: 10px; margin-top: -5px; border-radius: 50%; background: #fff; box-shadow: 0 0 10px #fff, 0 0 24px var(--ion); }

/* ── кнопки ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 26px; border-radius: 999px; cursor: pointer; text-decoration: none;
  font-family: var(--f-mono); font-size: 12px; letter-spacing: .14em; text-transform: uppercase;
  border: 1px solid rgba(255, 90, 31, .55); background: rgba(255, 90, 31, .06); color: var(--text);
  box-shadow: inset 0 0 18px rgba(255,90,31,.12), 0 0 0 0 var(--ion-glow);
  transition: box-shadow .25s, background .25s, border-color .25s;
}
.btn:hover { border-color: var(--ion); box-shadow: inset 0 0 24px rgba(255,90,31,.22), 0 0 26px -4px var(--ion-glow); }
.btn .ion { font-weight: 700; }
.btn.solid { background: var(--ion); color: #120600; border-color: var(--ion); font-weight: 700; }
.btn.solid:hover { background: var(--ion-hot); }
.btn.ghost { border-color: var(--line-2); background: transparent; box-shadow: none; }
.btn.done { border-color: rgba(125,255,176,.5); background: rgba(125,255,176,.07); color: var(--ok); box-shadow: none; }
.btn[disabled] { opacity: .38; cursor: not-allowed; box-shadow: none; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ── секции и модули ── */
.sec-head { display: flex; justify-content: space-between; align-items: end; gap: 12px; margin: 56px 0 18px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.sec-head h3 { margin: 0; font-family: var(--f-display); font-weight: 800; font-size: clamp(22px, 4vw, 32px); text-transform: uppercase; }

.resume { display: grid; grid-template-columns: auto 1fr auto; gap: 16px; align-items: center; margin-top: 16px; padding: 16px 18px; border-radius: var(--r); text-decoration: none; border: 1px solid rgba(255,90,31,.45); background: linear-gradient(90deg, rgba(255,90,31,.12), transparent 70%); }
.resume:hover { border-color: var(--ion); }
.resume .t { font-family: var(--f-display); font-weight: 700; font-size: 16px; text-transform: uppercase; line-height: 1.2; min-width: 0; }
.pulse { width: 10px; height: 10px; border-radius: 50%; background: var(--ion); box-shadow: 0 0 0 0 var(--ion-glow); animation: pulse 2s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 12px rgba(255,90,31,0); } 100% { box-shadow: 0 0 0 0 rgba(255,90,31,0); } }

.orbits { display: grid; gap: 10px; }
.orbit { border: 1px solid var(--line); border-radius: var(--r); background: rgba(13,13,15,.82); overflow: hidden; }
.orbit > summary { list-style: none; cursor: pointer; display: grid; grid-template-columns: 56px 1fr auto; gap: 14px; align-items: center; padding: 16px 18px; }
.orbit > summary::-webkit-details-marker { display: none; }
.orbit-n { font-family: var(--f-display); font-weight: 300; font-size: 30px; line-height: 1; color: var(--mute); font-variant-numeric: tabular-nums; }
.orbit[open] .orbit-n, .orbit.complete .orbit-n { color: var(--ion); }
.orbit-t { min-width: 0; }
.orbit-t b { display: block; font-family: var(--f-display); font-weight: 700; font-size: 16px; text-transform: uppercase; letter-spacing: .01em; }
.orbit-t span { display: block; color: var(--dim); font-size: 13px; }
.ring { width: 38px; height: 38px; }
.ring circle { fill: none; stroke-width: 3; }
.ring .bg { stroke: var(--line-2); }
.ring .fg { stroke: var(--ion); stroke-linecap: round; transform: rotate(-90deg); transform-origin: center; }
.missions { margin: 0; padding: 0 10px 10px; list-style: none; display: grid; gap: 2px; }
.missions a { display: grid; grid-template-columns: 44px 1fr auto; gap: 12px; align-items: center; padding: 11px 10px; border-radius: 10px; text-decoration: none; }
.missions a:hover { background: rgba(255,255,255,.04); }
.missions .id { font-family: var(--f-mono); font-size: 12px; color: var(--dim); }
.missions .nm { font-size: 15px; font-weight: 600; min-width: 0; }
.st { font-family: var(--f-mono); font-size: 10px; letter-spacing: .12em; text-transform: uppercase; padding: 4px 8px; border-radius: 6px; border: 1px solid var(--line-2); color: var(--dim); white-space: nowrap; }
.st.sent { color: var(--ion-hot); border-color: rgba(255,90,31,.5); }
.st.ok { color: var(--ok); border-color: rgba(125,255,176,.4); }

/* ── карточки скиллов/бонусов/ресурсов ── */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 12px; }
.card { position: relative; display: grid; gap: 10px; align-content: start; padding: 18px; border-radius: var(--r); border: 1px dashed var(--line-2); background: rgba(13,13,15,.85); text-decoration: none; }
a.card:hover { border-style: solid; border-color: rgba(255,90,31,.6); }
.card h4 { margin: 0; font-family: var(--f-display); font-weight: 700; font-size: 18px; text-transform: uppercase; line-height: 1.15; }
.card p { margin: 0; color: var(--dim); font-size: 14px; }
.card .arrow { position: absolute; top: 16px; right: 18px; color: var(--ion); font-family: var(--f-mono); }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.chip { cursor: pointer; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line-2); background: none; font-family: var(--f-mono); font-size: 11px; letter-spacing: .12em; color: var(--dim); }
.chip[aria-pressed="true"] { color: var(--text); border-color: var(--ion); background: rgba(255,90,31,.1); }

.res-list { list-style: none; margin: 4px 0 0; padding: 0; display: grid; }
.res-list li { display: grid; grid-template-columns: 1fr auto; gap: 10px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); }
.res-list b { font-weight: 600; display: block; }
.res-list span { color: var(--dim); font-size: 13px; }
.res-list a, .res-list em { font-family: var(--f-mono); font-size: 11px; letter-spacing: .12em; font-style: normal; text-transform: uppercase; }
.res-list a { color: var(--ion); text-decoration: none; }
.res-list em { color: var(--mute); }

/* ── урок ── */
.back { display: inline-block; margin: 22px 0 8px; text-decoration: none; }
.back:hover { color: var(--text); }
.l-head { padding: 18px 0 22px; border-bottom: 1px solid var(--line); }
.l-head h1 { margin: 10px 0 12px; font-family: var(--f-display); font-weight: 900; text-transform: uppercase; font-size: clamp(30px, 6.4vw, 64px); line-height: .98; text-wrap: balance; }
.lead { margin: 0; font-size: clamp(16px, 2.2vw, 19px); line-height: 1.5; max-width: 60ch; color: #cfcdc8; }
.l-body { display: grid; gap: 36px; margin-top: 28px; }
.l-body > * { min-width: 0; }
.block-t { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.block-t::after { content: ""; flex: 1; height: 1px; background: var(--line); }

.screens { display: grid; gap: 14px; }
.shot { position: relative; margin: 0; border-radius: var(--r); overflow: hidden; border: 1px solid var(--line); background: var(--hull); }
.shot img, .shot video { display: block; width: 100%; height: auto; }
.shot figcaption { display: flex; gap: 12px; padding: 10px 14px; border-top: 1px solid var(--line); color: var(--dim); font-size: 13px; }
.shot figcaption .mono { color: var(--ion); flex: none; padding-top: 2px; }
.slot { aspect-ratio: 16 / 9; display: grid; place-items: center; text-align: center; padding: 24px;
  background: repeating-linear-gradient(135deg, rgba(255,255,255,.025) 0 12px, transparent 12px 24px), var(--hull); }
.slot div { display: grid; gap: 8px; max-width: 36ch; }
.slot b { font-family: var(--f-display); font-weight: 600; font-size: 14px; text-transform: uppercase; letter-spacing: .02em; }

.steps { margin: 0; padding: 0; list-style: none; counter-reset: s; display: grid; gap: 2px; }
.steps li { counter-increment: s; display: grid; grid-template-columns: 44px 1fr; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); font-size: 16px; }
.steps li::before { content: "[" counter(s, decimal-leading-zero) "]"; font-family: var(--f-mono); font-size: 12px; color: var(--ion); padding-top: 4px; }

.prompt { border-radius: var(--r); border: 1px solid var(--line-2); background: #09090a; overflow: hidden; }
.prompt + .prompt { margin-top: 12px; }
.prompt-h { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.prompt pre { margin: 0; padding: 16px; white-space: pre-wrap; word-break: break-word; font: 14px/1.6 var(--f-mono); color: #f3e9e2; }
.copy { cursor: pointer; border: 1px solid rgba(255,90,31,.5); background: none; border-radius: 999px; padding: 6px 12px; font-family: var(--f-mono); font-size: 10px; letter-spacing: .14em; color: var(--ion-hot); }
.copy.ok { color: var(--ok); border-color: rgba(125,255,176,.5); }

/* ── задание ── */
.mission { border-radius: calc(var(--r) + 4px); border: 1px solid rgba(255,90,31,.5); background: linear-gradient(180deg, rgba(255,90,31,.09), rgba(13,13,15,.9) 50%); padding: 20px; display: grid; gap: 16px; box-shadow: 0 0 60px -30px var(--ion-glow); }
.mission-task { font-family: var(--f-display); font-weight: 600; font-size: clamp(17px, 2.6vw, 21px); line-height: 1.3; text-transform: uppercase; margin: 0; }
.field { display: grid; gap: 6px; }
.field label { font-family: var(--f-mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--dim); }
.field input[type=text], .field input[type=url], .field textarea {
  width: 100%; min-height: 48px; padding: 12px 14px; border-radius: 10px; border: 1px solid var(--line-2); background: #070708; color: var(--text); font: 15px/1.4 var(--f-body);
}
.field textarea { min-height: 84px; resize: vertical; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--ion); box-shadow: 0 0 0 3px rgba(255,90,31,.18); }
.drop { display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 10px 14px; border-radius: 10px; border: 1px dashed var(--line-2); cursor: pointer; color: var(--dim); font-size: 14px; }
.drop:hover { border-color: var(--ion); color: var(--text); }
.drop input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.msg { font-size: 14px; margin: 0; }
.msg.err { color: #ff9a7a; }
.msg.ok { color: var(--ok); }
.sent-box { display: grid; gap: 6px; padding: 14px; border-radius: 10px; border: 1px solid rgba(125,255,176,.3); background: rgba(125,255,176,.04); font-size: 14px; }
.sent-box a { color: var(--ok); word-break: break-all; }
.gate { display: grid; gap: 10px; padding-top: 4px; }

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 40px; }
.pager a { display: grid; gap: 4px; padding: 16px; border-radius: var(--r); border: 1px solid var(--line); text-decoration: none; min-width: 0; }
.pager a:hover { border-color: var(--line-2); }
.pager a.nx { text-align: right; }
.pager b { font-size: 14px; font-weight: 700; }

.faq details { border-top: 1px solid var(--line); }
.faq summary { cursor: pointer; padding: 16px 0; font-family: var(--f-display); font-weight: 600; font-size: 15px; text-transform: uppercase; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::after { content: "+"; color: var(--ion); font-family: var(--f-mono); }
.faq details[open] summary::after { content: "−"; }
.faq p { margin: 0 0 16px; color: var(--dim); max-width: 60ch; }

.foot { margin-top: 70px; padding-top: 16px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; }
.foot a { text-decoration: none; }

.toast { position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom, 0px)); transform: translate(-50%, 30px); opacity: 0; z-index: 60; padding: 12px 18px; border-radius: 999px; background: var(--panel); border: 1px solid var(--ion); font-family: var(--f-mono); font-size: 12px; letter-spacing: .1em; transition: .3s; pointer-events: none; }
.toast.on { opacity: 1; transform: translate(-50%, 0); }

.view { animation: in .45s ease both; }
@keyframes in { from { transform: translateY(6px); } }

@media (min-width: 820px) {
  .planet-wrap { grid-template-columns: 1.5fr 1fr; align-items: end; }
  .l-body { grid-template-columns: minmax(0, 1fr); }
  .mission { padding: 28px; }
}
@media (max-width: 560px) {
  .two { grid-template-columns: 1fr; }
  .orbit > summary { grid-template-columns: 40px 1fr auto; padding: 14px; }
  .orbit-n { font-size: 24px; }
  .missions a { grid-template-columns: 34px 1fr; }
  .missions .st { grid-column: 2; justify-self: start; }
  .barcode { display: none; }
  .resume { grid-template-columns: auto 1fr; }
  .resume .btn { grid-column: 1 / -1; }
  .pager { grid-template-columns: 1fr; }
  .navline { justify-content: flex-start; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ── СХЕМЫ: рисуются кодом, пока нет настоящего скрина ── */
.sch { position: relative; padding: clamp(14px, 3vw, 26px); background:
  linear-gradient(var(--line) 1px, transparent 1px) 0 0 / 32px 32px,
  linear-gradient(90deg, var(--line) 1px, transparent 1px) 0 0 / 32px 32px, #08080a; overflow: hidden; }
.sch-tag { position: absolute; top: 10px; right: 12px; font-family: var(--f-mono); font-size: 9px; letter-spacing: .16em; color: var(--mute); }
.sch .mono { font-size: 12px; }
/* окно */
.win { max-width: 620px; margin: 0 auto; border: 1px solid var(--line-2); border-radius: 12px; background: #0e0e11; overflow: hidden; box-shadow: 0 20px 60px -30px #000; }
.win-bar { display: flex; align-items: center; gap: 6px; padding: 9px 12px; border-bottom: 1px solid var(--line); font-family: var(--f-mono); font-size: 10px; letter-spacing: .14em; color: var(--dim); }
.win-bar i { width: 8px; height: 8px; border-radius: 50%; background: var(--line-2); }
.win-bar i:first-child { background: var(--ion); }
.win-bar span { margin-left: 8px; }
.win-body { display: grid; gap: 10px; padding: 14px; }
.msg-me { justify-self: end; max-width: 88%; padding: 10px 12px; border-radius: 12px 12px 4px 12px; background: rgba(255,90,31,.14); border: 1px solid rgba(255,90,31,.35); font-size: 13.5px; line-height: 1.45; }
.msg-ai { max-width: 92%; display: grid; gap: 6px; font-size: 13.5px; line-height: 1.45; color: #d6d3cd; }
.msg-ai .who { font-family: var(--f-mono); font-size: 10px; letter-spacing: .14em; color: var(--ion); }
.msg-ai .tool { font-family: var(--f-mono); font-size: 12px; padding: 7px 10px; border-radius: 8px; background: #050506; border: 1px solid var(--line); color: #bfe7c9; overflow-x: auto; white-space: nowrap; }
.msg-ai .ok { color: var(--ok); }
.win-input { margin: 0 14px 14px; padding: 10px 12px; border: 1px solid var(--line-2); border-radius: 10px; font-size: 13px; color: var(--dim); display: flex; justify-content: space-between; gap: 10px; }
.win-input b { font-family: var(--f-mono); font-size: 10px; color: var(--ion); font-weight: 500; white-space: nowrap; }
/* дерево */
.tree { max-width: 520px; margin: 0 auto; font: 13px/1.9 var(--f-mono); padding: 14px 18px; border: 1px solid var(--line-2); border-radius: 12px; background: #0e0e11; white-space: pre; overflow-x: auto; }
.tree .d { color: var(--ion-hot); } .tree .f { color: #cfcdc8; } .tree .c { color: var(--mute); }
/* цепочка */
.flow { display: flex; flex-wrap: wrap; align-items: stretch; justify-content: center; gap: 8px; }
.flow .node { flex: 1 1 120px; max-width: 200px; min-width: 0; padding: 12px; border: 1px solid var(--line-2); border-radius: 10px; background: #0e0e11; display: grid; gap: 6px; align-content: start; }
.flow .node b { font-family: var(--f-display); font-weight: 700; font-size: 13px; text-transform: uppercase; line-height: 1.15; }
.flow .node span { font-size: 12px; color: var(--dim); }
.flow .node em { font-style: normal; font-family: var(--f-mono); font-size: 10px; color: var(--ion); letter-spacing: .12em; }
.flow .node.hot { border-color: var(--ion); box-shadow: 0 0 24px -10px var(--ion-glow); }
.flow .arr { align-self: center; color: var(--ion); font-family: var(--f-mono); }
/* было / стало */
.vs { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; max-width: 760px; margin: 0 auto; }
.vs > div { min-width: 0; padding: 14px; border-radius: 12px; border: 1px solid; display: grid; gap: 8px; align-content: start; background: #0e0e11; }
.vs .bad { border-color: rgba(255,120,100,.35); } .vs .good { border-color: rgba(125,255,176,.35); }
.vs .h { font-family: var(--f-mono); font-size: 10px; letter-spacing: .16em; }
.vs .bad .h { color: #ff8f7a; } .vs .good .h { color: var(--ok); }
.vs p { margin: 0; font-size: 13px; line-height: 1.45; color: #d6d3cd; }
.vs .q { font-family: var(--f-mono); font-size: 12px; padding: 8px 10px; border-radius: 8px; background: #050506; border: 1px solid var(--line); white-space: pre-wrap; }
/* телефон 9:16 */
.phones { display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; }
.phone { position: relative; width: min(210px, 44vw); aspect-ratio: 9 / 16; border-radius: 22px; border: 2px solid #2a2a2e; background: #000; overflow: hidden; box-shadow: 0 20px 50px -25px #000; }
.phone .ph-in { position: absolute; inset: 0; display: grid; align-content: space-between; padding: 14% 9% 12%; }
.phone .ph-t { font-family: var(--f-display); font-weight: 900; font-size: clamp(14px, 3.4vw, 19px); line-height: 1; text-transform: uppercase; color: #fff; }
.phone .ph-s { font-family: 'Brush Script MT', cursive; font-size: 17px; color: var(--ion-hot); text-shadow: 0 0 10px var(--ion-glow); }
.phone .ph-sub { justify-self: center; font-family: var(--f-body); font-weight: 800; font-size: 13px; text-transform: uppercase; color: #fff; text-shadow: 0 1px 2px #000; }
.phone .ph-sub mark { background: #ffd23f; color: #111; padding: 0 4px; border-radius: 4px; }
.phone .head { position: absolute; left: 50%; bottom: 0; width: 64%; height: 58%; transform: translateX(-50%); border-radius: 50% 50% 8px 8px / 40% 40% 8px 8px; background: radial-gradient(circle at 50% 30%, #3b3b42 0 22%, transparent 23%), linear-gradient(#26262b, #18181b); }
.phone.premium { background: radial-gradient(circle at 30% 20%, #3a2a55, #0b0b14 60%); }
.phone.premium .card { position: absolute; left: 18%; right: 18%; top: 34%; height: 30%; border-radius: 14px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.2); backdrop-filter: blur(4px); }
.phone.collage { background: radial-gradient(circle, #4a0d12, #160305 70%); }
.phone.collage .head { background: repeating-radial-gradient(circle at 50% 40%, #ddd 0 1px, transparent 1px 4px); opacity: .55; }
.phone.collage .ph-t { font-family: 'Playfair Display', Georgia, serif; font-weight: 700; }
.phone.paper { background: #d8cfbd; }
.phone.paper .ph-t { color: #1a1a1a; font-family: 'Courier New', monospace; font-weight: 700; }
.phone.paper .head { background: repeating-radial-gradient(circle, #333 0 1px, transparent 1px 3px); opacity: .5; transform: translateX(-50%) rotate(-4deg); border-radius: 4px; height: 44%; bottom: 18%; box-shadow: 0 0 0 6px #f4efe4; }
.phone.split .board { position: absolute; left: 8%; right: 8%; top: 8%; height: 46%; border-radius: 10px; border: 1px solid var(--line-2); display: grid; gap: 6px; padding: 10px; align-content: start; }
.phone.split .board i { display: block; height: 14px; border-radius: 4px; background: rgba(255,90,31,.25); border: 1px solid rgba(255,90,31,.5); }
.phone.split .board i:nth-child(2) { width: 70%; } .phone.split .board i:nth-child(3) { width: 85%; }
.phone.split .head { height: 40%; width: 56%; box-shadow: 0 0 0 2px var(--ion); border-radius: 14px; bottom: 4%; }
.phone.cartoon { background: linear-gradient(#ffb36b, #ff7a59 55%, #6b3a8f); }
.phone.cartoon .bean { position: absolute; bottom: 12%; width: 30%; height: 34%; border-radius: 50% 50% 40% 40%; border: 2px solid #111; }
.phone.cartoon .bean.a { left: 12%; background: #7ad3ff; } .phone.cartoon .bean.b { right: 12%; background: #ffe066; height: 30%; }
.phone.cartoon .bean::before, .phone.cartoon .bean::after { content: ""; position: absolute; top: 28%; width: 12%; height: 10%; border-radius: 50%; background: #111; }
.phone.cartoon .bean::before { left: 30%; } .phone.cartoon .bean::after { right: 30%; }
.phone .ph-cap { position: absolute; left: 0; right: 0; bottom: -26px; text-align: center; font-family: var(--f-mono); font-size: 10px; color: var(--dim); letter-spacing: .12em; }
.phones.capd { padding-bottom: 26px; }
/* таймлайн */
.tl { max-width: 760px; margin: 0 auto; display: grid; gap: 10px; }
.tl-row { display: flex; height: 44px; border-radius: 8px; overflow: hidden; border: 1px solid var(--line-2); }
.tl-row div { display: grid; place-items: center; font-family: var(--f-mono); font-size: 10px; letter-spacing: .08em; color: #111; background: #c9c6bf; border-right: 1px solid #000; min-width: 0; overflow: hidden; white-space: nowrap; }
.tl-row div.cut { background: repeating-linear-gradient(135deg, rgba(255,90,31,.55) 0 6px, rgba(255,90,31,.15) 6px 12px); color: #fff; }
.tl-legend { display: flex; gap: 16px; flex-wrap: wrap; font-family: var(--f-mono); font-size: 10px; color: var(--dim); letter-spacing: .12em; }
/* таблица */
.stbl { max-width: 760px; margin: 0 auto; overflow-x: auto; border: 1px solid var(--line-2); border-radius: 12px; background: #0e0e11; }
.stbl table { width: 100%; border-collapse: collapse; font-size: 13px; }
.stbl th { text-align: left; font-family: var(--f-mono); font-size: 10px; letter-spacing: .12em; color: var(--ion); font-weight: 500; padding: 10px 12px; border-bottom: 1px solid var(--line-2); white-space: nowrap; }
.stbl td { padding: 9px 12px; border-bottom: 1px solid var(--line); color: #d6d3cd; vertical-align: top; }
.stbl td:first-child { font-family: var(--f-mono); font-size: 12px; color: var(--dim); white-space: nowrap; }
.stbl tr.hot td { background: rgba(255,90,31,.08); }
/* разрешение */
.permit { max-width: 520px; margin: 0 auto; border-radius: 12px; border: 1px solid var(--line-2); background: #0e0e11; padding: 14px; display: grid; gap: 10px; }
.permit .ask { font-size: 13px; color: var(--dim); }
.permit code { display: block; font: 12.5px/1.5 var(--f-mono); padding: 10px; border-radius: 8px; background: #050506; border: 1px solid var(--line); color: #f3e9e2; overflow-x: auto; white-space: nowrap; }
.permit .btns { display: flex; gap: 8px; flex-wrap: wrap; }
.permit .btns span { padding: 6px 12px; border-radius: 8px; border: 1px solid var(--line-2); font-size: 12px; }
.permit .verdict { font-family: var(--f-mono); font-size: 11px; letter-spacing: .12em; padding: 8px 10px; border-radius: 8px; }
.permit .verdict.ok { color: var(--ok); background: rgba(125,255,176,.07); border: 1px solid rgba(125,255,176,.3); }
.permit .verdict.stop { color: #ff8f7a; background: rgba(255,120,100,.07); border: 1px solid rgba(255,120,100,.35); }
/* спека */
.spec { max-width: 620px; margin: 0 auto; display: grid; gap: 12px; }
.spec .big { font-family: var(--f-display); font-weight: 800; font-size: clamp(26px, 6vw, 44px); line-height: 1; text-align: center; }
.spec dl { margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 8px; }
.spec dl div { padding: 10px 12px; border: 1px solid var(--line-2); border-radius: 10px; background: #0e0e11; min-width: 0; }
.spec dt { font-family: var(--f-mono); font-size: 10px; letter-spacing: .12em; color: var(--dim); }
.spec dd { margin: 2px 0 0; font-weight: 700; font-size: 14px; }

/* ── факт и ошибки ── */
.fact { position: relative; padding: 18px 18px 18px 20px; border-radius: var(--r); border: 1px solid var(--line-2); background: #0b0b0d; display: grid; gap: 8px; }
.fact::before { content: ""; position: absolute; left: 0; top: 14px; bottom: 14px; width: 2px; background: var(--ion); box-shadow: 0 0 12px var(--ion-glow); }
.fact p { margin: 0; font-size: 16px; line-height: 1.5; }
.mistakes { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.mistakes li { display: grid; grid-template-columns: 22px 1fr; gap: 10px; padding: 12px 14px; border-radius: 10px; border: 1px dashed rgba(255,120,100,.35); font-size: 15px; }
.mistakes li::before { content: "×"; color: #ff8f7a; font-family: var(--f-mono); font-size: 16px; line-height: 1.3; }
.mistakes b { color: var(--text); }
.mistakes span { color: var(--dim); }

@media (max-width: 560px) {
  .vs { grid-template-columns: 1fr; }
  .flow .arr { transform: rotate(90deg); flex-basis: 100%; text-align: center; }
  .flow .node { max-width: none; flex-basis: 100%; }
}

/* бонусы: обложка YouTube */
.card.bonus { padding: 0 0 18px; overflow: hidden; }
.card.bonus > :not(.thumb) { margin-inline: 18px; }
.card.bonus .thumb { position: relative; aspect-ratio: 16 / 9; background: #000; overflow: hidden; border-bottom: 1px solid var(--line); }
.card.bonus .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; filter: saturate(.9); transition: transform .4s; }
.card.bonus:hover .thumb img { transform: scale(1.04); }
.card.bonus .play { position: absolute; inset: 0; margin: auto; width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; padding-left: 4px; background: rgba(255,90,31,.92); color: #120600; font-size: 18px; box-shadow: 0 0 30px var(--ion-glow); }

/* хронология кейса */
.story { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; position: relative; }
.story::before { content: ""; position: absolute; left: 60px; top: 8px; bottom: 8px; width: 1px; background: var(--line-2); }
.story li { position: relative; display: grid; grid-template-columns: 52px 1fr; gap: 28px; padding: 12px 0; }
.story li::before { content: ""; position: absolute; left: 56px; top: 20px; width: 9px; height: 9px; border-radius: 50%; background: var(--dim); box-shadow: 0 0 0 4px var(--void); }
.story li.st-bad::before { background: #ff6b5a; }
.story li.st-win::before { background: var(--ok); box-shadow: 0 0 0 4px var(--void), 0 0 14px rgba(125,255,176,.6); }
.story li.st-mid::before { background: var(--ion); }
.story .mono { color: var(--dim); padding-top: 3px; font-variant-numeric: tabular-nums; }
.story li > div { min-width: 0; display: grid; gap: 4px; }
.story .tg { justify-self: start; font-family: var(--f-mono); font-size: 10px; letter-spacing: .14em; padding: 3px 7px; border-radius: 5px; border: 1px solid var(--line-2); color: var(--ion-hot); }
.story .st-bad .tg { color: #ff8f7a; border-color: rgba(255,120,100,.4); }
.story .st-win .tg { color: var(--ok); border-color: rgba(125,255,176,.4); }
.story b { font-family: var(--f-display); font-weight: 700; font-size: 16px; text-transform: uppercase; line-height: 1.2; }
.story p { margin: 0; color: #cfcdc8; font-size: 15px; line-height: 1.55; max-width: 64ch; }
@media (max-width: 560px) {
  .story::before { left: 46px; } .story li { grid-template-columns: 40px 1fr; gap: 20px; } .story li::before { left: 42px; }
}
