/* ============================================================
   ATLAS 2.0 — справочник взглядов и убеждений + арена
   тема: чёрная арена (near-black + золото + коралл)
   редизайн 2026-07-15 — Tenor Sans, сплит-герой, VS-карты
   ============================================================ */

/* --- Tenor Sans, self-hosted (офлайн, без CDN) --- */
@font-face {
  font-family: 'Tenor Sans'; font-style: normal; font-weight: 400; font-display: swap;
  src: url(./fonts/tenor-sans-cyrillic.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Tenor Sans'; font-style: normal; font-weight: 400; font-display: swap;
  src: url(./fonts/tenor-sans-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Tenor Sans'; font-style: normal; font-weight: 400; font-display: swap;
  src: url(./fonts/tenor-sans-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg: #0E0E10;
  --bg-deep: #090A0C;
  --panel: #181A22;
  --panel-2: #1F222C;
  --panel-3: #262A36;
  --line: #2A2F40;
  --line-soft: #252A3D;
  --ink: #E8E4D8;
  --ink-dim: #A29E90;
  --ink-faint: #6C6A60;
  --ghost: #47484E;
  --gold: #D8B96A;
  --gold-dim: rgba(216,185,106,.13);
  --gold-line: rgba(216,185,106,.5);
  --coral: #D87B6A;
  --coral-line: rgba(216,123,106,.5);
  --v-pos: #94D86A; --v-mid: #D8B96A; --v-neg: #D87B6A; /* вердикт: за / спорно / против */
  --ancient: #C8A86A; --medieval: #9B8BC5; --modern: #6A9BD8; --contemporary: #D87B6A; --eastern: #7FA184;
  --ok: #9CBF8E; --warn: #D8B96A; --bad: #D87B6A; --info: #6A9BD8;
  --r-sm: 6px; --r-md: 10px; --r-lg: 14px; --r-xl: 18px; --r-pill: 999px;
  --m-fast: 150ms; --m-smooth: 240ms; --ease: cubic-bezier(.4,0,.2,1);
  --e2: 0 2px 8px rgba(0,0,0,.45), 0 6px 18px rgba(0,0,0,.35);
  --e4: 0 10px 30px rgba(0,0,0,.6), 0 24px 70px rgba(0,0,0,.5);
  --serif: "Tenor Sans", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --brand: Georgia, "Times New Roman", serif;
  --script: "Segoe Script", "Bradley Hand", "Brush Script MT", cursive;
  --sans: -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --mono: "JetBrains Mono", Consolas, monospace;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body { background: var(--bg); color: var(--ink); font-family: var(--sans); font-size: 14px; line-height: 1.55; -webkit-font-smoothing: antialiased; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
input, select, textarea { font: inherit; color: var(--ink); background: var(--bg-deep); border: 1px solid var(--line); border-radius: var(--r-md); padding: 9px 12px; }
input:focus, select:focus { outline: none; border-color: var(--gold-line); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--panel-3); border-radius: 5px; }

/* ================= TOP / NAV ================= */
.top {
  position: sticky; top: 0; z-index: 60; padding: 12px 22px 0;
  background: rgba(14,14,16,.92); backdrop-filter: blur(10px);
  border-bottom: .8px solid var(--line-soft);
}
.top-inner { max-width: 1060px; margin: 0 auto; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.hamb { display: none; align-items: center; justify-content: center; width: 40px; height: 40px; color: var(--ink-dim); transition: color var(--m-fast); }
.hamb:hover { color: var(--ink); }
.hamb svg { width: 20px; height: 20px; stroke: currentColor; fill: none; stroke-width: 1.6; }
.nav-veil { display: none; }
.brand { font-family: var(--brand); font-style: italic; font-size: 22px; color: var(--gold); line-height: 1.4; }
.brand small { font-family: var(--sans); font-style: normal; font-size: 10px; color: var(--ink-faint); margin-left: 9px; letter-spacing: .2px; }
.nav { display: flex; gap: 2px; margin-top: 8px; overflow-x: auto; }
.nav button {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 14px 11px; font-family: var(--serif); font-size: 13.5px; color: var(--ink-dim);
  border-bottom: 2.4px solid transparent; white-space: nowrap; transition: color var(--m-fast);
}
.nav button svg { width: 14px; height: 14px; flex: none; stroke: currentColor; fill: none; stroke-width: 1; opacity: .9; }
.nav button:hover { color: var(--ink); }
.nav button.active { color: var(--gold); border-bottom-color: var(--gold); }
.nav .nav-sp { margin-left: auto; }

.wrap { max-width: 1060px; margin: 0 auto; padding: 26px 22px 110px; }

/* page header (все вкладки кроме арены) */
h2.page { font-family: var(--serif); font-weight: 400; font-size: 46px; line-height: 1; letter-spacing: -.5px; margin-bottom: 12px; color: var(--ink); }
.lead { color: var(--ink-dim); margin-bottom: 22px; font-size: 14px; line-height: 1.6; max-width: 720px; }

/* ================= buttons / chips ================= */
.btn {
  display: inline-flex; align-items: center; gap: 7px; padding: 8px 16px;
  border-radius: var(--r-pill); font-size: 13px; font-family: var(--serif);
  background: var(--panel); border: .8px solid var(--line);
  transition: all var(--m-fast) var(--ease);
}
.btn:hover { border-color: var(--gold-line); color: var(--ink); }
.btn.primary { background: var(--gold); border-color: var(--gold); color: #241d0d; }
.btn.primary:hover { filter: brightness(1.07); }
.btn.ghost { background: transparent; border-color: transparent; color: var(--ink-dim); }
.btn.ghost:hover { color: var(--ink); }

.chips { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; align-items: center; }
.chip {
  padding: 5px 13px; border-radius: var(--r-pill); font-size: 12.5px; font-family: var(--serif);
  background: var(--panel); border: .8px solid transparent; color: var(--ink-dim);
  cursor: pointer; transition: all var(--m-fast) var(--ease); white-space: nowrap;
}
.chip:hover { color: var(--ink); }
.chip.on { background: transparent; border-color: var(--gold-line); color: var(--gold); }
.search-row { display: flex; gap: 10px; margin-bottom: 16px; flex-wrap: wrap; }
.search-row input[type=search]{ flex: 1; min-width: 220px; }
.muted { color: var(--ink-faint); font-size: 12px; }

/* ================= cards grid ================= */
.grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(250px,1fr)); gap: 12px; }
.tile {
  background: var(--panel); border: .8px solid var(--line-soft); border-radius: var(--r-lg);
  padding: 16px 17px 16px; cursor: pointer; position: relative;
  transition: border-color var(--m-fast) var(--ease), transform var(--m-fast) var(--ease), background var(--m-fast);
}
.tile:hover { border-color: var(--gold-line); transform: translateY(-2px); background: var(--panel-2); }
.tile .tname { font-family: var(--serif); font-size: 18px; color: var(--ink); }
.tile .tsub { font-family: var(--sans); font-size: 9.5px; color: var(--ink-faint); margin-top: 3px; letter-spacing: .5px; text-transform: uppercase; }
.tile .tdesc { font-size: 12.5px; color: var(--ink-dim); margin-top: 9px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.tile .edge { position: absolute; left: 0; top: 12px; bottom: 12px; width: 3px; border-radius: 2px; }
.tagrow { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 10px; }
.mini-tag { font-family: var(--sans); font-size: 8.5px; letter-spacing: .4px; padding: 2px 8px; border-radius: var(--r-pill); background: var(--bg-deep); color: var(--ink-faint); }

/* ================= ARENA hero ================= */
.arena-hero { display: flex; justify-content: space-between; align-items: flex-start; gap: 40px; margin-bottom: 46px; flex-wrap: wrap; }
.hero-title { display: flex; flex-direction: column; font-family: var(--serif); font-weight: 400; letter-spacing: -1px; }
.hero-title span { font-size: clamp(58px, 8.5vw, 96px); line-height: .82; }
.hero-title .ht-1 { color: var(--ink); }
.hero-title .ht-2 { color: var(--ghost); }
.hero-side { flex: 1; min-width: 300px; max-width: 400px; padding-top: 6px; }
.mode-seg { display: flex; align-items: center; gap: 22px; margin-bottom: 12px; flex-wrap: wrap; }
.mode-seg button {
  font-family: var(--serif); font-size: 14px; color: var(--ink-dim);
  padding: 4px 0; transition: color var(--m-fast); border-radius: var(--r-pill);
}
.mode-seg button:hover { color: var(--ink); }
.mode-seg button.on { color: #fff; border: .8px solid #fff; padding: 4px 14px; }
.hero-desc { color: var(--ink-dim); font-size: 14px; line-height: 1.55; }

/* dilemma sub-nav */
.dil-nav { display: flex; flex-wrap: wrap; gap: 6px 26px; align-items: center; margin-bottom: 8px; }
.dil-nav .dchip { font-family: var(--serif); font-size: 14px; color: var(--ink-dim); cursor: pointer; padding: 4px 0; transition: color var(--m-fast); }
.dil-nav .dchip:hover { color: var(--ink); }
.dil-nav .dchip.on { color: var(--gold); border: .8px solid var(--gold-line); border-radius: var(--r-pill); padding: 4px 13px; }

.dil-scenario { padding-top: 8px; margin-bottom: 6px; }
.dil-scenario .ds-text { font-family: var(--serif); font-size: 24px; line-height: 1.12; color: var(--ink); }
.dil-scenario .ds-src { font-family: var(--sans); font-size: 10px; color: var(--ink-faint); margin-top: 12px; }

/* ================= VS row + fighter cards ================= */
.vs-row { display: grid; grid-template-columns: 1fr 60px 1fr; gap: 12px; align-items: stretch; margin: 30px 0 8px; }
@media (max-width: 720px){ .vs-row { grid-template-columns: 1fr; } .vs-badge { height: auto; padding: 6px 0; } }
.vs-badge {
  font-family: var(--serif); font-size: 34px; color: var(--ink-faint);
  display: flex; align-items: center; justify-content: center; align-self: center;
}
.fighter {
  background: var(--panel); border: .8px solid transparent; border-radius: var(--r-xl);
  padding: 18px 20px 20px; position: relative; display: flex; flex-direction: column;
}
.fighter .f-cat { position: absolute; top: 18px; right: 20px; display: inline-flex; align-items: center; font-family: var(--sans); font-size: 9.5px; font-weight: 700; letter-spacing: .8px; text-transform: uppercase; color: var(--ink-faint); cursor: pointer; transition: color var(--m-fast); }
.fighter .f-cat:hover { color: #fff; }
.fighter .f-name { margin-bottom: 16px; cursor: pointer; display: inline-block; }
.fighter .f-first { font-family: var(--script); font-size: 16px; font-weight: 700; line-height: 1.1; }
.fighter .f-last { font-family: var(--serif); font-size: 32px; line-height: 1.05; color: #fff; margin-top: 2px; display: inline-flex; align-items: center; }
/* стрелка-подсказка перехода */
.f-arw { display: inline-flex; width: 0; opacity: 0; overflow: hidden; transition: width var(--m-fast) var(--ease), opacity var(--m-fast) var(--ease); }
.f-arw svg { stroke: currentColor; fill: none; stroke-width: 1.4; }
.fighter .f-cat .f-arw svg { width: 11px; height: 11px; }
.fighter .f-last .f-arw svg { width: 20px; height: 20px; }
.fighter .f-cat:hover .f-arw { width: 13px; opacity: 1; margin-left: 5px; }
.fighter .f-name:hover .f-last { color: #fff; }
.fighter .f-name:hover .f-last .f-arw { width: 22px; opacity: 1; margin-left: 6px; }
/* пустая карточка-плейсхолдер */
.fighter.empty { background: #0A0A0A; align-items: center; justify-content: center; padding: 24px; }
.fighter.empty .f-empty { font-family: var(--serif); font-size: 120px; line-height: 1; color: var(--ink-faint); opacity: .5; user-select: none; }
.fighter .f-verdict { font-family: var(--serif); font-size: 16px; margin-bottom: 8px; }
.fighter .f-arg { font-size: 13px; line-height: 1.55; color: var(--ink-dim); }
.fighter .f-src { font-family: var(--sans); font-size: 10px; color: var(--ink-faint); margin-top: auto; padding-top: 16px; }
.fighter.v-do .f-first, .fighter.v-do .f-verdict { color: var(--v-pos); }
.fighter.v-depends .f-first, .fighter.v-depends .f-verdict { color: var(--v-mid); }
.fighter.v-dont .f-first, .fighter.v-dont .f-verdict { color: var(--v-neg); }

/* generic fighter (lens/meaning duels) keep h4/.fsub/.one/.fsec */
.fighter h4 { font-family: var(--serif); font-weight: 400; font-size: 22px; color: #fff; }
.fighter .fsub { font-family: var(--sans); font-size: 9.5px; color: var(--ink-faint); letter-spacing: .8px; text-transform: uppercase; margin: 3px 0 12px; }
.fighter .one { font-family: var(--serif); font-size: 15px; color: var(--gold); margin-bottom: 12px; }
.fsec { margin-bottom: 11px; }
.fsec h6 { font-family: var(--sans); font-size: 9px; letter-spacing: 1px; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 4px; }
.fsec p, .fsec li { font-size: 13px; color: var(--ink-dim); }
.fsec ul { padding-left: 17px; }
.fsec.strong h6 { color: var(--ok); } .fsec.weak h6 { color: var(--bad); }
.verdict { display: inline-block; padding: 3px 12px; border-radius: var(--r-pill); font-size: 11.5px; font-weight: 700; margin-bottom: 10px; }
.verdict.do { background: rgba(156,191,142,.16); color: var(--ok); border: 1px solid rgba(156,191,142,.4); }
.verdict.dont { background: rgba(216,123,106,.14); color: var(--bad); border: 1px solid rgba(216,123,106,.4); }
.verdict.depends { background: rgba(216,185,106,.13); color: var(--warn); border: 1px solid rgba(216,185,106,.4); }

/* philosopher pool under the duel */
.phil-pool { display: flex; flex-wrap: wrap; gap: 10px; margin: 26px 0 4px; }
.phil-pool .pchip {
  --vc: var(--gold);
  padding: 5px 13px; border-radius: var(--r-pill); font-size: 12.5px; font-family: var(--serif);
  background: var(--panel); border: .8px solid transparent; color: var(--ink-dim);
  cursor: pointer; transition: all var(--m-fast) var(--ease); display: inline-flex; align-items: center; gap: 7px;
}
.phil-pool .pchip.v-do { --vc: var(--v-pos); }
.phil-pool .pchip.v-depends { --vc: var(--v-mid); }
.phil-pool .pchip.v-dont { --vc: var(--v-neg); }
.phil-pool .pchip:hover { background: var(--vc); border-color: var(--vc); color: #14120a; }
.phil-pool .pchip.sel { background: transparent; border-color: var(--vc); color: var(--vc); }
.phil-pool .pchip.sel:hover { background: var(--vc); color: #14120a; }
.phil-pool .pchip svg { width: 13px; height: 13px; stroke: currentColor; fill: none; stroke-width: 1; }

/* closing reflection — пары строк: 4px внутри, 12px между парами (как в макете) */
.reflect { margin-top: 30px; display: flex; flex-direction: column; gap: 12px; }
.reflect .rgroup { display: flex; flex-direction: column; gap: 4px; }
.reflect p { font-family: var(--serif); font-size: 16px; line-height: 1.2; color: #fff; }
.reflect p .hl { color: var(--gold); }
.reflect p.sub { font-size: 14px; color: var(--ink-dim); line-height: 1.2; }

/* bridge / danger cards (lens & meaning arenas) */
.bridge-card {
  background: linear-gradient(160deg, rgba(127,161,132,.08), var(--panel));
  border: .8px solid rgba(127,161,132,.4); border-radius: var(--r-xl); padding: 20px 22px; margin-top: 18px;
}
.bridge-card h4 { font-family: var(--serif); font-weight: 400; font-size: 19px; color: var(--eastern); margin-bottom: 10px; }
.danger-card {
  background: linear-gradient(160deg, rgba(216,123,106,.07), var(--panel));
  border: .8px solid rgba(216,123,106,.35); border-radius: var(--r-xl); padding: 20px 22px; margin-top: 18px;
}
.danger-card h4 { font-family: var(--serif); font-weight: 400; font-size: 19px; color: var(--bad); margin-bottom: 10px; }
.phr { padding: 9px 13px; background: var(--bg-deep); border-radius: var(--r-md); margin-bottom: 6px; font-size: 13.5px; color: var(--ink-dim); }
.phr .cp { float: right; color: var(--ink-faint); cursor: pointer; font-size: 11px; }
.phr .cp:hover { color: var(--gold); }
.pick-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 8px; }
.pick-row select { flex: 1; min-width: 230px; }
.resp-strip { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin: 14px 0 4px; }
.resp-chip-strip { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; align-items: center; }

/* ================= metaphors ================= */
.era-line { display: flex; gap: 3px; margin-top: 10px; }
.era-cell { flex: 1; height: 8px; border-radius: 2px; background: var(--panel-3); }
.era-cell.timeless { background: var(--gold); }
.era-cell.proven { background: var(--ok); }
.era-cell.experimental { background: var(--info); }
.era-cell.future { background: var(--medieval); }
.era-cell.dated-rhetoric, .era-cell.dated-cliche { background: var(--bad); opacity: .55; }
.legend-row { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; font-size: 11.5px; color: var(--ink-dim); }
.legend-row .li { display: inline-flex; align-items: center; gap: 5px; }
.legend-row .li i { width: 11px; height: 8px; border-radius: 2px; display: inline-block; }

/* ================= flashcards ================= */
.fc-stage { perspective: 1200px; margin: 22px auto; max-width: 560px; }
.fc-card { position: relative; width: 100%; min-height: 260px; cursor: pointer; transform-style: preserve-3d; transition: transform 480ms var(--ease); }
.fc-card.flip { transform: rotateY(180deg); }
.fc-face {
  position: absolute; inset: 0; backface-visibility: hidden;
  background: var(--panel); border: .8px solid var(--gold-line); border-radius: var(--r-xl);
  padding: 30px; display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; box-shadow: var(--e2);
}
.fc-face.back { transform: rotateY(180deg); background: var(--panel-2); }
.fc-face .q { font-family: var(--serif); font-size: 21px; color: var(--ink); }
.fc-face .a { font-size: 15px; color: var(--ink-dim); }
.fc-hint { text-align: center; color: var(--ink-faint); font-size: 11.5px; }
.fc-know-row { display: flex; gap: 10px; justify-content: center; margin-top: 12px; }
.fc-progress { max-width: 560px; margin: 0 auto; }
.fc-progress .bar { height: 6px; background: var(--panel-2); border-radius: 3px; overflow: hidden; }
.fc-progress .bar i { display: block; height: 100%; background: var(--ok); }

/* scenario (reused by flashcards done-state) */
.scenario {
  background: var(--panel); border: .8px solid var(--gold-line); border-radius: var(--r-xl);
  padding: 20px 24px; margin-bottom: 6px; font-size: 15px; color: var(--ink);
}
.scenario .src { font-family: var(--sans); font-size: 10px; color: var(--ink-faint); margin-top: 8px; }

/* ================= modal ================= */
.modal-veil { position: fixed; inset: 0; background: rgba(4,4,6,.82); display: flex; align-items: center; justify-content: center; z-index: 100; opacity: 0; pointer-events: none; transition: opacity var(--m-smooth) var(--ease); }
.modal-veil.open { opacity: 1; pointer-events: auto; }
.modal { width: min(760px, 93vw); max-height: 86vh; overflow-y: auto; background: var(--panel); border: .8px solid var(--line); border-radius: var(--r-xl); box-shadow: var(--e4); padding: 24px 28px; transform: translateY(12px); transition: transform var(--m-smooth) var(--ease); }
.modal-veil.open .modal { transform: none; }
.modal h3 { font-family: var(--serif); font-weight: 400; font-size: 27px; margin-bottom: 5px; color: var(--ink); }
.modal .subline { font-family: var(--sans); font-size: 10px; color: var(--ink-faint); letter-spacing: .5px; text-transform: uppercase; margin-bottom: 16px; }
.modal .close { position: sticky; float: right; top: 0; color: var(--ink-faint); font-size: 18px; padding: 2px 8px; }
.modal .close:hover { color: var(--ink); }
.kv { margin-bottom: 14px; }
.kv h5 { font-family: var(--sans); font-size: 9.5px; letter-spacing: 1px; color: var(--gold); text-transform: uppercase; margin-bottom: 5px; }
.kv p, .kv li { font-size: 13.5px; }
.kv ul { padding-left: 18px; }
.kv code { display: block; font-family: var(--mono); font-size: 11.5px; background: var(--bg-deep); padding: 9px 11px; border-radius: var(--r-sm); color: var(--ink-dim); white-space: pre-wrap; }
.kv .warn { color: var(--bad); }
.phil-block { border-left: 2px solid var(--gold-line); padding-left: 14px; margin-bottom: 14px; }
.phil-block .pn { font-weight: 700; font-size: 14.5px; }
.phil-block .pd { font-family: var(--sans); font-size: 9.5px; color: var(--ink-faint); }
.concept { background: var(--panel-2); border-radius: var(--r-md); padding: 11px 13px; margin-top: 8px; }
.concept .cn { font-weight: 600; font-size: 13px; color: var(--gold); }
.concept .cd { font-size: 12.5px; margin-top: 2px; }
.concept .ce { font-size: 12px; color: var(--ink-dim); margin-top: 5px; font-style: italic; }
.concept .cs { font-family: var(--sans); font-size: 9px; color: var(--ink-faint); margin-top: 5px; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }

#toast { position: fixed; bottom: 22px; left: 50%; transform: translate(-50%,70px); background: var(--panel-3); border: .8px solid var(--gold-line); padding: 9px 18px; border-radius: var(--r-pill); font-size: 12.5px; z-index: 200; transition: transform var(--m-smooth) var(--ease), opacity var(--m-smooth); opacity: 0; }
#toast.show { transform: translate(-50%,0); opacity: 1; }

/* ================= v2.0 onboarding / misc ================= */
.welcome-veil { position: fixed; inset: 0; background: rgba(4,4,6,.88); z-index: 300; display: flex; align-items: center; justify-content: center; padding: 16px; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.welcome { width: min(560px,92vw); margin: auto; background: var(--panel); border: .8px solid var(--gold-line); border-radius: var(--r-xl); padding: 28px 30px; box-shadow: var(--e4); }
.welcome h2 { font-family: var(--serif); font-weight: 400; font-size: 30px; color: var(--gold); margin-bottom: 4px; }
.welcome .wsub { color: var(--ink-dim); font-size: 13px; margin-bottom: 20px; }
.wstep { display: flex; gap: 13px; margin-bottom: 15px; align-items: flex-start; }
.wstep .wn { font-family: var(--sans); font-size: 11px; background: var(--gold); color: #241d0d; min-width: 24px; height: 24px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 700; }
.wstep .wt { font-weight: 600; font-size: 14px; }
.wstep .wd { font-size: 12.5px; color: var(--ink-dim); }
.hk-row { display: flex; justify-content: space-between; gap: 14px; padding: 6px 0; border-bottom: 1px dashed var(--line-soft); font-size: 13px; }

/* favorites */
.tile { padding-right: 34px; }
.tile .fav { position: absolute; top: 10px; right: 11px; font-size: 14px; opacity: .3; padding: 2px 5px; cursor: pointer; transition: opacity var(--m-fast); }
.tile .fav:hover, .tile .fav.on { opacity: 1; color: var(--gold); }

/* era sections */
.era-section { margin: 24px 0 12px; display: flex; align-items: center; gap: 10px; }
.era-section i { width: 12px; height: 12px; border-radius: 3px; }
.era-section h4 { font-family: var(--serif); font-weight: 400; font-size: 20px; }
.era-section .muted { font-family: var(--sans); font-size: 9.5px; }

/* global search */
.gs-input { width: 100%; font-size: 16px; padding: 13px 16px; margin-bottom: 14px; }
.gs-group h6 { font-family: var(--sans); font-size: 9.5px; letter-spacing: 1px; color: var(--gold); text-transform: uppercase; margin: 12px 0 5px; }
.gs-item { display: flex; gap: 10px; align-items: baseline; padding: 8px 11px; border-radius: var(--r-md); cursor: pointer; font-size: 13.5px; }
.gs-item:hover { background: var(--panel-2); }
.gs-item .gsub { color: var(--ink-faint); font-size: 11.5px; }

/* school modal accordions */
.phil-acc { border: .8px solid var(--line-soft); border-radius: var(--r-md); margin-bottom: 8px; overflow: hidden; }
.phil-acc-head { width: 100%; text-align: left; padding: 11px 14px; display: flex; align-items: baseline; gap: 10px; }
.phil-acc-head:hover { background: var(--panel-2); }
.phil-acc-head .pn { font-weight: 700; font-size: 14px; }
.phil-acc-head .pd { font-family: var(--sans); font-size: 9.5px; color: var(--ink-faint); }
.phil-acc-head .chev { margin-left: auto; color: var(--ink-faint); transition: transform var(--m-smooth); }
.phil-acc.open .phil-acc-head .chev { transform: rotate(90deg); }
.phil-acc-body { display: none; padding: 0 14px 12px; }
.phil-acc.open .phil-acc-body { display: block; }

.ladder-toggle { cursor: pointer; user-select: none; }

/* ================= WORKSHOP ================= */
.wk-quiz { max-width: 640px; }
.wk-progress { font-family: var(--sans); font-size: 10px; letter-spacing: .8px; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 14px; }
.wk-q { font-family: var(--serif); font-size: 26px; line-height: 1.15; color: var(--ink); margin-bottom: 22px; }
.wk-opts { display: flex; flex-direction: column; gap: 10px; margin-bottom: 18px; }
.wk-opt {
  text-align: left; font-family: var(--serif); font-size: 15px; color: var(--ink-dim);
  background: var(--panel); border: .8px solid transparent; border-radius: var(--r-lg);
  padding: 14px 18px; transition: all var(--m-fast) var(--ease);
}
.wk-opt:hover { color: var(--ink); border-color: var(--gold-line); background: var(--panel-2); }

.wk-result { max-width: 760px; }
.wk-card { display: flex; gap: 16px; background: var(--panel); border-radius: var(--r-xl); padding: 18px 20px; margin-bottom: 12px; }
.wk-rank { font-family: var(--serif); font-size: 28px; color: var(--gold); min-width: 28px; }
.wk-rank.sm { font-size: 14px; min-width: 18px; color: var(--ink-faint); }
.wk-card-body { flex: 1; }
.wk-card-title { font-family: var(--serif); font-size: 21px; color: #fff; }
.wk-card-one { font-family: var(--serif); font-size: 14px; color: var(--gold); margin: 3px 0 12px; }
.wk-anti { background: linear-gradient(160deg, rgba(216,123,106,.07), var(--panel)); border: .8px solid rgba(216,123,106,.35); border-radius: var(--r-xl); padding: 16px 20px; margin-top: 14px; }
.wk-anti h6 { font-family: var(--sans); font-size: 9.5px; letter-spacing: 1px; text-transform: uppercase; color: var(--bad); margin-bottom: 8px; }
.wk-anti p, .wk-anti li { font-size: 13px; color: var(--ink-dim); }
.wk-anti ul { padding-left: 17px; }
.wk-block { background: var(--panel); border-radius: var(--r-xl); padding: 16px 20px; margin-top: 14px; }
.wk-block h6 { font-family: var(--sans); font-size: 9.5px; letter-spacing: 1px; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 8px; }
.wk-block.ok h6 { color: var(--ok); }
.wk-block li { font-size: 13px; color: var(--ink-dim); }
.wk-block ul { padding-left: 17px; }

.wk-portrait { background: var(--panel); border: .8px solid var(--gold-line); border-radius: var(--r-xl); padding: 20px 24px; margin-bottom: 16px; }
.wk-portrait h6 { font-family: var(--sans); font-size: 9.5px; letter-spacing: 1px; text-transform: uppercase; color: var(--gold); margin-bottom: 10px; }
.wk-portrait p { font-family: var(--serif); font-size: 16px; line-height: 1.35; color: var(--ink); margin-bottom: 8px; }
.wk-axes { margin-top: 16px; display: flex; flex-direction: column; gap: 9px; }
.wk-axis { display: grid; grid-template-columns: 1fr 120px 1fr; gap: 10px; align-items: center; font-size: 11px; color: var(--ink-faint); }
.wk-axis .wa-l { text-align: right; }
.wk-axis .wa-bar { position: relative; height: 4px; background: var(--panel-3); border-radius: 2px; }
.wk-axis .wa-bar i { position: absolute; top: -3px; margin-left: -5px; width: 10px; height: 10px; border-radius: 50%; background: var(--gold); }
.wk-two { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 4px; }
@media (max-width: 720px){ .wk-two { grid-template-columns: 1fr; } }
.wk-h { font-family: var(--sans); font-size: 9.5px; letter-spacing: 1px; text-transform: uppercase; color: var(--ink-faint); margin: 14px 0 8px; }
.wk-line { display: flex; gap: 9px; align-items: baseline; padding: 5px 0; font-size: 13px; flex-wrap: wrap; }
.wk-line.shadow { opacity: .75; margin-top: 6px; }
.wk-link { font-family: var(--serif); font-size: 14.5px; color: var(--ink); border-bottom: 1px dotted var(--ink-faint); padding: 0; }
.wk-link:hover { color: var(--gold); border-bottom-color: var(--gold); }

/* раскрываемые блоки результата (учения/смыслы) */
.wk-exp { padding: 8px 0 10px; border-bottom: .8px dashed var(--line-soft); }
.wk-exp.shadow { opacity: .8; }
.wk-exp-head { display: flex; align-items: baseline; gap: 9px; width: 100%; text-align: left; padding: 0; }
.wk-exp-title { font-family: var(--serif); font-size: 16px; color: var(--ink); border-bottom: 1px dotted var(--ink-faint); }
.wk-exp-head:hover .wk-exp-title { color: var(--gold); border-bottom-color: var(--gold); }
.wk-exp-head .chev { margin-left: auto; color: var(--ink-faint); transition: transform var(--m-smooth); }
.wk-exp.open .wk-exp-head .chev { transform: rotate(90deg); }
.wk-exp-sum { font-size: 12.5px; color: var(--ink-dim); line-height: 1.5; margin-top: 5px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.wk-exp.open .wk-exp-sum { display: block; -webkit-line-clamp: unset; overflow: visible; color: var(--ink); }
.wk-exp-body { display: none; margin-top: 9px; }
.wk-exp.open .wk-exp-body { display: block; }
.wk-exp-body p { font-size: 12.5px; color: var(--ink-dim); line-height: 1.55; margin-bottom: 8px; }
.wk-k { font-family: var(--sans); font-size: 9px; letter-spacing: .8px; text-transform: uppercase; color: var(--gold); margin-right: 4px; }
.wk-k.warn { color: var(--bad); }
/* практики под зоны */
.wk-pr-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); flex: none; align-self: center; }
.wk-pr-zone { font-size: 11px; color: var(--ink-faint); margin-left: auto; padding-left: 12px; text-align: right; }
.wk-block .wk-exp:last-child { border-bottom: none; padding-bottom: 2px; }
.wk-block .wk-exp .wk-exp-head { gap: 10px; }
.wk-block .wk-exp .wk-exp-head .chev { margin-left: 0; }
@media (max-width: 620px){ .wk-pr-zone { display: none; } }

/* конструктор: выбранное и пикер с выдержками */
.wk-slot { margin-bottom: 10px; }
.wk-chosen { display: flex; align-items: flex-start; gap: 10px; background: var(--panel); border: .8px solid var(--gold-line); border-radius: var(--r-lg); padding: 11px 14px; margin-bottom: 8px; }
.wk-chosen-body { flex: 1; }
.wk-chosen-body b { display: block; font-family: var(--serif); font-weight: 400; font-size: 15.5px; color: var(--ink); }
.wk-chosen-body span { display: block; font-size: 12px; color: var(--ink-dim); margin-top: 2px; line-height: 1.45; }
.wk-chosen-rm { color: var(--ink-faint); padding: 2px 6px; }
.wk-chosen-rm:hover { color: var(--bad); }
.wk-picker { margin-top: 8px; padding: 12px; background: var(--bg-deep); border-radius: var(--r-lg); }
.wk-pick-search { width: 100%; margin-bottom: 10px; background: var(--panel); }
.wk-pick-list { max-height: 300px; overflow-y: auto; display: flex; flex-direction: column; gap: 6px; }
.wk-pick-row { text-align: left; background: var(--panel); border: .8px solid transparent; border-radius: var(--r-md); padding: 10px 13px; transition: all var(--m-fast) var(--ease); }
.wk-pick-row:hover { border-color: var(--gold-line); background: var(--panel-2); }
.wk-pick-row b { display: block; font-family: var(--serif); font-weight: 400; font-size: 14.5px; color: var(--ink); }
.wk-pick-row span { display: block; font-size: 12px; color: var(--ink-dim); margin-top: 2px; line-height: 1.45;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.wk-saved { margin-top: 26px; border-top: .8px solid var(--line-soft); padding-top: 6px; }

@media (max-width: 620px){
  h2.page { font-size: 38px; }
  .top { padding: 12px 16px 0; backdrop-filter: none; background: var(--bg); }
  .wrap { padding: 22px 16px 90px; }
  /* боковое меню (drawer) вместо горизонтальной навигации */
  .hamb { display: inline-flex; margin: -4px -6px -4px 0; }
  .nav {
    position: fixed; top: 0; right: 0; z-index: 58;
    height: 100vh; height: 100dvh; width: min(300px, 82vw);
    flex-direction: column; align-items: stretch; gap: 0;
    margin: 0; padding: 64px 0 24px; overflow-y: auto;
    background: var(--panel); border-left: .8px solid var(--line-soft);
    box-shadow: var(--e4);
    transform: translateX(100%); transition: transform var(--m-smooth) var(--ease);
  }
  .nav.open { transform: none; }
  .nav button { width: 100%; justify-content: flex-start; gap: 13px; padding: 14px 22px; font-size: 16px; border-bottom: none; border-left: 2.4px solid transparent; }
  .nav button svg { width: 16px; height: 16px; }
  .nav button.active { border-bottom-color: transparent; border-left-color: var(--gold); background: var(--gold-dim); }
  .nav .nav-sp { margin-left: 0; margin-top: 8px; padding-top: 18px; border-top: .8px solid var(--line-soft); }
  .nav-veil { display: block; position: fixed; inset: 0; z-index: 55; background: rgba(4,4,6,.6); opacity: 0; pointer-events: none; transition: opacity var(--m-smooth) var(--ease); }
  .nav-veil.open { opacity: 1; pointer-events: auto; }
  body.nav-lock { overflow: hidden; }
  /* arena hero — заголовок и блок под ним в столбик, не в две колонки */
  .hero-title span { font-size: 48px; }
  .arena-hero { flex-direction: column; gap: 18px; margin-bottom: 28px; }
  .hero-side { min-width: 0; max-width: 100%; width: 100%; }
  .mode-seg { gap: 16px; }
  .dil-nav { gap: 6px 18px; }
  .dil-scenario .ds-text { font-size: 21px; }
  /* stacked duel */
  .vs-row { margin: 22px 0 8px; }
  .vs-badge { font-size: 26px; }
  .fighter { padding: 16px 17px 18px; }
  .fighter .f-last { font-size: 28px; }
  .fighter.empty { min-height: 150px; padding: 20px; }
  .fighter.empty .f-empty { font-size: 66px; }
  /* крупнее тач-таргеты */
  .chip, .dchip { padding: 7px 14px; }
  .phil-pool .pchip { padding: 7px 14px; }
  .dil-nav .dchip.on { padding: 6px 13px; }
  .reflect p { font-size: 15px; }
  /* welcome */
  .welcome { padding: 20px 16px; }
  .welcome h2 { font-size: 23px; }
  .welcome .actions { flex-wrap: wrap; }
  .welcome .actions .btn { width: 100%; justify-content: center; }
}
/* тач-устройства: hover недоступен — стрелку-подсказку показываем постоянно */
@media (hover: none){
  .fighter .f-cat .f-arw { width: 12px; opacity: .75; margin-left: 5px; }
  .fighter .f-name .f-last .f-arw { width: 19px; opacity: .7; margin-left: 5px; }
}
