/* Third Eye 21: dark felt theme */
:root {
  --bg: #0b1410;
  --bg2: #0f1b15;
  --surface: #13221b;
  --surface2: #1a2d24;
  --border: #26402f;
  --text: #e9f2ed;
  --muted: #92a99c;
  --accent: #2fd17a;
  --accent-ink: #062614;
  --gold: #f2c14e;
  --red: #ef6060;
  --blue: #5aa9ff;
  --hit: #e05656;
  --stand: #e8b23a;
  --double: #34b874;
  --split: #8f72f2;
  --surr: #a3aea8;
  --radius: 14px;
  --shadow: 0 6px 24px rgba(0, 0, 0, .35);
  --nav-h: 64px;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: radial-gradient(1200px 600px at 50% -200px, #163325 0%, var(--bg) 60%) fixed, var(--bg);
  color: var(--text);
  font: 15px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  min-height: 100vh;
  padding-bottom: calc(var(--nav-h) + env(safe-area-inset-bottom) + 12px);
  -webkit-tap-highlight-color: transparent;
}
a { color: var(--accent); }
h2 { margin: 0 0 8px; font-size: 1.2rem; }
h3 { margin: 16px 0 8px; font-size: 1rem; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
p { margin: 6px 0; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.fine { color: var(--muted); font-size: .78rem; margin-top: 10px; }
.hint { color: var(--muted); font-size: .75rem; text-align: center; margin: 8px 0 0; }
.mono { font-variant-numeric: tabular-nums; font-family: ui-monospace, Consolas, monospace; }
.pos { color: var(--accent) !important; }
.neg { color: var(--red) !important; }
.center { text-align: center; }
.row { display: flex; align-items: center; }
.row.gap { gap: 10px; }
.row.wrap { flex-wrap: wrap; }
.row.between { justify-content: space-between; gap: 10px; }
.row.end { justify-content: flex-end; gap: 10px; }

/* ---------- top bar & nav ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between;
  padding: calc(10px + env(safe-area-inset-top)) 16px 10px;
  background: rgba(11, 20, 16, .88); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 800; font-size: 1.1rem; letter-spacing: .02em; }
.logo {
  display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 9px;
  background: linear-gradient(145deg, var(--accent), #1a9c58); color: var(--accent-ink); font-weight: 900; font-size: .95rem;
}
.brand-lg { display: flex; align-items: center; gap: 12px; font-size: 1.6rem; font-weight: 800; margin-bottom: 8px; }
.brand-lg .logo { width: 44px; height: 44px; font-size: 1.2rem; border-radius: 12px; }
.tier-badge { font-size: .72rem; font-weight: 800; letter-spacing: .08em; padding: 5px 10px; border-radius: 999px; text-decoration: none; border: 1px solid var(--border); color: var(--muted); }
.tier-badge.pro { background: var(--gold); color: #2b1d00; border-color: var(--gold); }
.tier-badge.dev { background: var(--blue); color: #001a33; border-color: var(--blue); }

.nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  display: flex; justify-content: space-around;
  height: calc(var(--nav-h) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom);
  background: rgba(13, 24, 19, .96); backdrop-filter: blur(10px); border-top: 1px solid var(--border);
}
.nav-item { position: relative; flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; color: var(--muted); text-decoration: none; font-size: .72rem; }
.nav-item.on { color: var(--accent); }
.nav-icon { font-size: 1.25rem; line-height: 1; }
.pro-dot { position: absolute; top: 12px; right: calc(50% - 18px); width: 7px; height: 7px; border-radius: 50%; background: var(--gold); }

@media (min-width: 900px) {
  body { padding-bottom: 24px; }
  .nav { position: sticky; top: 57px; bottom: auto; height: auto; padding: 0 16px; justify-content: flex-start; gap: 4px; border-top: 0; border-bottom: 1px solid var(--border); background: rgba(11, 20, 16, .88); }
  .nav-item { flex: 0 0 auto; flex-direction: row; gap: 8px; padding: 12px 16px; font-size: .9rem; border-bottom: 2px solid transparent; }
  .nav-item.on { border-bottom-color: var(--accent); }
  .nav-icon { font-size: 1rem; }
  .pro-dot { top: 10px; right: 6px; }
}

main { outline: none; }
.view { max-width: 1180px; margin: 0 auto; padding: 14px 16px; display: grid; gap: 14px; }

/* ---------- cards & controls ---------- */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); min-width: 0; }
.card.inset { box-shadow: none; background: var(--surface2); }
.btn {
  appearance: none; border: 1px solid var(--border); background: var(--surface2); color: var(--text);
  padding: 10px 16px; border-radius: 11px; font: inherit; font-weight: 600; cursor: pointer; text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 42px; transition: transform .05s, background .15s;
}
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn.primary:hover { filter: brightness(1.07); }
.btn.ghost:hover { background: #22392e; }
.btn.danger-ghost { color: var(--red); }
.btn.big { padding: 13px 22px; font-size: 1.02rem; }
.btn.small { min-height: 32px; padding: 6px 12px; font-size: .82rem; }
.btn[disabled], .btn.disabled { opacity: .5; cursor: not-allowed; }
.btn:focus-visible, .key:focus-visible, .chip:focus-visible, .abtn:focus-visible, .nav-item:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

.form-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; margin: 12px 0; }
.field { display: grid; gap: 5px; font-size: .82rem; color: var(--muted); }
select, input[type=number], input[type=text] {
  width: 100%; background: var(--bg2); color: var(--text); border: 1px solid var(--border); border-radius: 10px;
  padding: 10px 12px; font: inherit; font-size: .95rem; min-height: 42px;
}
select:focus, input:focus { outline: 2px solid var(--accent); outline-offset: 0; }
.checks { display: grid; gap: 10px; margin: 12px 0; }
.check { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; }
.check input { width: 20px; height: 20px; accent-color: var(--accent); margin: 1px 0 0; flex: none; }
.big-input { font-size: 1.4rem !important; text-align: center; max-width: 200px; }
.key-input { flex: 1; min-width: 240px; font-family: ui-monospace, Consolas, monospace; }
.tag { font-size: .7rem; padding: 2px 8px; border-radius: 999px; background: var(--surface2); color: var(--muted); border: 1px solid var(--border); margin-left: 6px; font-weight: 600; }
.tag.warn { color: var(--gold); border-color: #5c4a1c; }
.pro-pill { font-size: .62rem; font-weight: 800; background: var(--gold); color: #2b1d00; padding: 1px 6px; border-radius: 6px; margin-left: 6px; vertical-align: middle; }

/* ---------- playing cards ---------- */
.pcard {
  position: relative; flex: none; width: 46px; height: 64px; border-radius: 7px; background: #fbfbf7; color: #15171a;
  box-shadow: 0 2px 6px rgba(0,0,0,.4); border: 1px solid #d9d9d0; font-weight: 800; user-select: none;
}
.pcard.red { color: #c8202c; }
.pc-rank { position: absolute; top: 3px; left: 5px; font-size: .95rem; line-height: 1; }
.pc-suit { position: absolute; top: 19px; left: 5px; font-size: .75rem; line-height: 1; }
.pc-big { position: absolute; right: 5px; bottom: 3px; font-size: 1.4rem; line-height: 1; }
.pcard.sm { width: 38px; height: 54px; }
.pcard.sm .pc-rank { font-size: .85rem; }
.pcard.sm .pc-suit { top: 17px; font-size: .65rem; }
.pcard.sm .pc-big { font-size: 1.1rem; }
.pcard.md { width: 58px; height: 82px; }
.pcard.md .pc-rank { font-size: 1.2rem; }
.pcard.md .pc-suit { top: 24px; font-size: .95rem; }
.pcard.md .pc-big { font-size: 1.8rem; }
.pcard.xl { width: 150px; height: 210px; border-radius: 14px; }
.pcard.xl .pc-rank { font-size: 2.6rem; top: 8px; left: 12px; }
.pcard.xl .pc-suit { font-size: 1.8rem; top: 52px; left: 14px; }
.pcard.xl .pc-big { font-size: 5rem; right: 14px; bottom: 8px; }
.pcard.back { background: repeating-linear-gradient(45deg, #8a1e2a 0 6px, #a3283a 6px 12px); border-color: #fbfbf7; border-width: 3px; }

/* ---------- live counter ---------- */
.counter-grid { display: grid; gap: 14px; }
@media (min-width: 900px) { .counter-grid { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); align-items: start; } .col-right { position: sticky; top: 112px; } }
.col-left, .col-right { display: grid; gap: 12px; min-width: 0; }
/* Phones: keep the keypad pinned above the bottom nav so you never scroll to enter a card */
@media (max-width: 899px) {
  .col-right {
    position: sticky; bottom: calc(var(--nav-h) + env(safe-area-inset-bottom)); z-index: 10;
    margin: 0 -16px; padding: 8px 12px 10px; gap: 8px;
    background: rgba(13, 24, 19, .97); backdrop-filter: blur(8px); border-top: 1px solid var(--border);
    box-shadow: 0 -8px 24px rgba(0, 0, 0, .4);
  }
  .col-right .key { min-height: 54px; border-radius: 11px; box-shadow: none; }
  .col-right .key-rank { font-size: 1.35rem; }
  .col-right .key-left, .col-right .hint, .col-right .targets-label { display: none; }
  .col-right .chip { padding: 6px 12px; min-height: 34px; }
  .col-right .action-row .btn { min-height: 36px; padding: 6px 10px; font-size: .85rem; }
  .mini-verdict { display: flex !important; }
  .stats { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 5px; }
  .stats .stat { padding: 6px 2px; border-radius: 10px; }
  .stats .stat-value { font-size: .95rem; letter-spacing: -.02em; }
  .l-long { display: none; }
  .l-short { display: inline !important; }
  .stats .stat-label { font-size: .56rem; letter-spacing: .02em; }
  .stats .stat-sub { font-size: .56rem; }
}
.mini-verdict { display: none; align-items: baseline; justify-content: space-between; gap: 10px; padding: 7px 12px; border-radius: 10px; }
.mini-verdict b { font-size: 1.15rem; font-weight: 900; letter-spacing: .03em; }
.mini-verdict span { font-size: .75rem; opacity: .85; }
.did-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; border-top: 1px solid var(--border); padding-top: 10px; }
.did-label { color: var(--muted); font-size: .85rem; }
.did-hint { color: var(--muted); font-size: .72rem; margin-left: auto; }
.stats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 10px 8px; text-align: center; min-width: 0; }
.stat-label { font-size: .66rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stat-value { font-size: 1.45rem; font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.2; white-space: nowrap; }
.stat-sub { font-size: .66rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stat.pos .stat-value { color: var(--accent); }
.stat.neg .stat-value { color: var(--red); }
.penbar-wrap { display: grid; gap: 4px; }
.penbar { position: relative; height: 8px; background: var(--surface2); border-radius: 99px; overflow: hidden; border: 1px solid var(--border); }
.penbar-fill { position: absolute; inset: 0 auto 0 0; background: linear-gradient(90deg, #1d7d4c, var(--accent)); }
.penbar-cut { position: absolute; top: -2px; bottom: -2px; width: 2px; background: var(--gold); }
.pen-meta { display: flex; justify-content: space-between; gap: 10px; font-size: .72rem; color: var(--muted); flex-wrap: wrap; }

.advisor { display: grid; gap: 10px; }
.zone { border: 1px dashed var(--border); border-radius: 12px; padding: 8px 10px; cursor: pointer; transition: border-color .15s, background .15s; }
.zone.targeted { border: 1px solid var(--accent); background: rgba(47, 209, 122, .07); }
.zone.inactive { opacity: .6; }
.zone-label { font-size: .75rem; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; margin-bottom: 6px; display: flex; align-items: center; flex-wrap: wrap; gap: 4px; }
.zone-total { color: var(--text); font-weight: 700; text-transform: none; letter-spacing: 0; margin-left: 6px; font-size: .85rem; }
.cards { display: flex; gap: 6px; flex-wrap: wrap; min-height: 54px; align-items: center; }
.placeholder { color: var(--muted); font-size: .85rem; font-style: italic; }
.verdict { display: grid; gap: 8px; padding-top: 4px; }
.verdict.idle { min-height: 70px; align-content: center; text-align: center; }
.big-action { font-size: 2.6rem; font-weight: 900; letter-spacing: .03em; text-align: center; line-height: 1.1; padding: 8px 0; border-radius: 12px; }
.why { display: grid; gap: 4px; text-align: center; font-size: .85rem; }
.why .dev { color: var(--gold); font-weight: 600; }
.why .diff { color: var(--blue); }
.why .agree { color: var(--muted); }
.insurance { padding: 8px 12px; border-radius: 10px; background: var(--surface2); font-size: .85rem; border-left: 3px solid var(--muted); }
.insurance.take { border-left-color: var(--accent); }
.evs summary { cursor: pointer; color: var(--muted); font-size: .8rem; }
.ev-list { display: grid; gap: 6px; margin-top: 8px; }
.ev-row { display: grid; grid-template-columns: 96px 1fr 62px 52px; gap: 8px; align-items: center; font-variant-numeric: tabular-nums; font-size: .85rem; }
.ev-bar { height: 8px; background: var(--surface2); border-radius: 99px; overflow: hidden; }
.ev-fill { height: 100%; }
.ev-fill.pos { background: var(--accent); }
.ev-fill.neg { background: var(--red); opacity: .7; }
.ev-num { text-align: right; font-weight: 700; }
.ev-gap { text-align: right; font-size: .75rem; }

.targets { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.targets-label { font-size: .75rem; color: var(--muted); margin-right: 2px; }
.chip { appearance: none; border: 1px solid var(--border); background: var(--surface); color: var(--text); border-radius: 999px; padding: 8px 14px; font: inherit; font-weight: 600; cursor: pointer; min-height: 38px; }
.chip.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.auto { font-size: .7rem; color: var(--muted); margin-left: auto; }
.auto.on { color: var(--accent); }
.keypad { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.key {
  appearance: none; position: relative; border: 1px solid var(--border); border-radius: 14px; background: var(--surface);
  color: var(--text); cursor: pointer; min-height: 78px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  font: inherit; touch-action: manipulation; transition: transform .05s, background .1s; box-shadow: var(--shadow);
}
.key:active { transform: scale(.94); background: var(--surface2); }
.key-rank { font-size: 1.6rem; font-weight: 900; line-height: 1; }
.key:last-child .key-rank { font-size: .95rem; line-height: 1.15; text-align: center; padding: 0 4px; }
.key-tag { font-size: .72rem; font-weight: 800; }
.key-left { font-size: .62rem; color: var(--muted); }
.k-plus { border-bottom: 3px solid var(--accent); } .k-plus .key-tag { color: var(--accent); }
.k-minus { border-bottom: 3px solid var(--red); } .k-minus .key-tag { color: var(--red); }
.k-zero .key-tag { color: var(--muted); }
.action-row { display: flex; flex-wrap: wrap; gap: 8px; }
.action-row .btn { flex: 1 1 auto; }

/* action colours */
.abadge { display: inline-block; min-width: 86px; text-align: center; padding: 6px 10px; border-radius: 8px; font-weight: 800; font-size: .8rem; letter-spacing: .03em; color: #10140f; }
.a-hit { background: var(--hit); color: #fff; }
.a-stand { background: var(--stand); color: #2a1d00; }
.a-double { background: var(--double); color: #032012; }
.a-split { background: var(--split); color: #fff; }
.a-surr { background: var(--surr); color: #151a17; }
.a-bj { background: var(--gold); color: #2b1d00; }
.a-bust { background: #4a2424; color: #ffd2d2; }

/* ---------- trainer ---------- */
.subtabs { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 2px; scrollbar-width: none; }
.subtab { appearance: none; border: 1px solid var(--border); background: var(--surface); color: var(--muted); border-radius: 999px; padding: 9px 15px; font: inherit; font-weight: 600; cursor: pointer; white-space: nowrap; }
.subtab.on { color: var(--accent-ink); background: var(--accent); border-color: var(--accent); }
.trainer-body { display: grid; gap: 14px; }
.drill { display: grid; gap: 12px; }
.drill.center { justify-items: center; text-align: center; }
.flash { display: flex; gap: 12px; justify-content: center; min-height: 214px; align-items: center; }
.result { padding: 12px 14px; border-radius: 12px; background: var(--surface2); display: grid; gap: 6px; border-left: 4px solid var(--muted); }
.result.good { border-left-color: var(--accent); }
.result.bad { border-left-color: var(--red); }
.result .btn { justify-self: start; margin-top: 4px; }
.seq { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; }
.seqc { padding: 2px 6px; border-radius: 5px; background: var(--surface2); font-weight: 700; font-size: .8rem; }
.seqc.plus { color: var(--accent); } .seqc.minus { color: var(--red); }
.tags-legend { display: grid; grid-template-columns: repeat(10, 1fr); gap: 4px; }
.tl { display: grid; text-align: center; background: var(--surface2); border-radius: 8px; padding: 6px 0; font-size: .8rem; }
.tl.plus span { color: var(--accent); } .tl.minus span { color: var(--red); }
.tc-q { display: flex; gap: 30px; justify-content: center; align-items: flex-end; padding: 10px 0; }
.tc-big { font-size: 2.6rem; font-weight: 900; font-variant-numeric: tabular-nums; }
.tray { width: 40px; height: 70px; border: 2px solid var(--border); border-radius: 6px; position: relative; overflow: hidden; margin: 6px auto 0; }
.tray-fill { position: absolute; bottom: 0; left: 0; right: 0; background: repeating-linear-gradient(0deg, #e9e6dc 0 2px, #b9b5a8 2px 3px); }
.seg { display: inline-flex; border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.seg button { appearance: none; border: 0; background: var(--surface2); color: var(--muted); padding: 8px 12px; font: inherit; font-weight: 600; cursor: pointer; }
.seg button.on { background: var(--accent); color: var(--accent-ink); }
.table-felt { background: radial-gradient(ellipse at 50% 0%, #1f6b45, #10442b 70%); border: 6px solid #3b2a17; border-radius: 22px; padding: 18px 14px; display: grid; gap: 14px; justify-items: center; box-shadow: inset 0 0 40px rgba(0,0,0,.4); }
.table-felt.big { min-height: 300px; align-content: space-between; }
.felt-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: center; padding: 4px 8px; border-radius: 12px; }
.felt-row.active { outline: 2px solid var(--gold); }
.felt-label { width: 100%; text-align: center; color: #cfe8da; font-size: .8rem; font-weight: 600; }
.tc-chip { background: rgba(0,0,0,.35); color: var(--gold); padding: 6px 14px; border-radius: 999px; font-weight: 800; }
.bots { display: flex; gap: 18px; justify-content: center; flex-wrap: wrap; }
.bot { display: grid; justify-items: center; gap: 4px; opacity: .9; }
.you-hands { display: grid; gap: 8px; }
.answer-row { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.abtn { appearance: none; border: 0; background: none; padding: 0; cursor: pointer; border-radius: 10px; }
.abtn .abadge { min-width: 104px; padding: 13px 12px; font-size: .95rem; }
.abtn.right .abadge { outline: 3px solid #fff; }
.abtn.wrong .abadge { opacity: .45; text-decoration: line-through; }
.abtn.dim .abadge { opacity: .3; }
.bet-controls { display: flex; align-items: center; gap: 10px; justify-content: center; flex-wrap: wrap; }
.bet-amt { font-size: 1.5rem; font-weight: 800; min-width: 90px; text-align: center; font-variant-numeric: tabular-nums; }
.feedback { margin: 0; padding-left: 18px; display: grid; gap: 3px; font-size: .88rem; }
.feedback .ok { color: var(--accent); } .feedback .bad { color: var(--red); }

/* ---------- charts ---------- */
.charts { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.chart-block { min-width: 0; }
.chart-scroll { overflow-x: auto; }
table.chart { border-collapse: separate; border-spacing: 2px; width: 100%; font-size: .78rem; font-weight: 800; text-align: center; }
table.chart th { color: var(--muted); font-weight: 700; padding: 4px; }
table.chart tbody th { text-align: right; padding-right: 6px; white-space: nowrap; }
table.chart td { padding: 6px 0; border-radius: 4px; min-width: 26px; }
.c-h { background: var(--hit); color: #fff; } .c-s { background: var(--stand); color: #2a1d00; } .c-d { background: var(--double); color: #032012; }
.c-p { background: var(--split); color: #fff; } .c-r { background: var(--surr); color: #151a17; }
.legend { display: flex; flex-wrap: wrap; gap: 12px; margin: 10px 0; font-size: .8rem; color: var(--muted); }
.leg { display: inline-flex; align-items: center; gap: 6px; }
.leg-sw { display: inline-grid; place-items: center; min-width: 26px; height: 20px; border-radius: 4px; font-weight: 800; font-size: .7rem; padding: 0 4px; }
.leg-line { display: inline-block; width: 22px; height: 3px; border-radius: 2px; background: var(--accent); }
.leg-line.neg { background: var(--red); }
.edge-pill { background: var(--surface2); border: 1px solid var(--border); padding: 8px 12px; border-radius: 10px; font-size: .82rem; }
table.devs { border-collapse: collapse; width: 100%; font-size: .88rem; }
table.devs th, table.devs td { padding: 8px 10px; border-bottom: 1px solid var(--border); text-align: left; }
table.devs th { color: var(--muted); font-weight: 600; font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; }

/* ---------- simulator ---------- */
.sim-progress { height: 8px; border-radius: 99px; background: var(--surface2); overflow: hidden; margin-top: 12px; }
.sim-progress-fill { height: 100%; background: var(--accent); transition: width .2s; }
.compare { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.cmp-col { background: var(--surface2); border-radius: 12px; padding: 12px 14px; border: 1px solid var(--border); }
.cmp-col.main { border-color: var(--accent); }
.cmp-col h3 { margin-top: 0; }
.kv { display: flex; justify-content: space-between; gap: 10px; padding: 5px 0; border-bottom: 1px dashed var(--border); font-size: .9rem; }
.kv:last-child { border-bottom: 0; }
.kv span { color: var(--muted); }
.kvs { margin: 10px 0; }
.spark { width: 100%; height: 220px; background: var(--bg2); border-radius: 12px; border: 1px solid var(--border); }
.verdict-line { font-size: 1rem; padding: 10px 12px; border-radius: 10px; background: var(--surface2); color: var(--text) !important; border-left: 4px solid var(--accent); }
.verdict-line.neg { border-left-color: var(--red); }
details summary { cursor: pointer; color: var(--muted); margin: 10px 0; }

/* ---------- gate & account ---------- */
.gate { text-align: left; display: grid; gap: 12px; max-width: 640px; margin: 0 auto; }
.gate-badge { justify-self: start; background: var(--gold); color: #2b1d00; font-weight: 900; padding: 4px 10px; border-radius: 8px; font-size: .8rem; letter-spacing: .08em; }
.gate-list { margin: 0; padding-left: 18px; display: grid; gap: 6px; color: var(--muted); }
.gate-list b { color: var(--text); }
.tier-banner { padding: 12px 14px; border-radius: 12px; font-weight: 700; margin: 8px 0; background: var(--surface2); border: 1px solid var(--border); }
.tier-banner.pro { background: rgba(242, 193, 78, .12); border-color: var(--gold); color: var(--gold); }
.tier-banner.dev { background: rgba(90, 169, 255, .12); border-color: var(--blue); color: var(--blue); }
.license-msg { min-height: 1.2em; margin: 8px 0; }

/* ---------- modal & toast ---------- */
.backdrop { position: fixed; inset: 0; z-index: 100; background: rgba(0, 0, 0, .6); display: grid; place-items: center; padding: 16px; backdrop-filter: blur(3px); }
.modal { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; padding: 22px; width: min(560px, 100%); max-height: 90vh; overflow: auto; box-shadow: var(--shadow); }
#toast { position: fixed; left: 50%; bottom: calc(var(--nav-h) + 20px + env(safe-area-inset-bottom)); transform: translateX(-50%) translateY(20px); opacity: 0; pointer-events: none; background: #233b2f; color: var(--text); border: 1px solid var(--border); padding: 10px 16px; border-radius: 12px; z-index: 200; transition: .2s; max-width: calc(100% - 32px); box-shadow: var(--shadow); }
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
#toast.warn { border-color: var(--gold); }
#toast.good { border-color: var(--accent); }
@media (min-width: 900px) { #toast { bottom: 24px; } }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
.l-short { display: none; }
