/* ============================================================
   coyn42 B2C lab — "radically simplified signal terminal"
   One idea per screen. The score is the interface.
   ============================================================ */

:root {
  --bg: #0B100E;
  --panel: #101714;
  --panel-2: #141D19;
  --line: rgba(120, 200, 168, 0.11);
  --line-strong: rgba(120, 200, 168, 0.26);
  --ink: #E9F3ED;
  --ink-2: #9FB4A9;
  --ink-3: #64796F;
  --accent: #2BE3A2;
  --accent-ink: #46EBAF;
  --accent-dim: rgba(43, 227, 162, 0.12);
  --pos: #3BDB9E;
  --neg: #F0685F;
  --warn: #E8B44C;
  --font-display: "Bricolage Grotesque", sans-serif;
  --font-body: "Spline Sans", sans-serif;
  --font-mono: "Spline Sans Mono", monospace;
  --rail: 560px;
  --tabbar-h: 64px;
  --sab: env(safe-area-inset-bottom, 0px);
}

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { height: 100%; }
body {
  min-height: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.45;
  overscroll-behavior-y: none;
  /* faint phosphor atmosphere behind everything */
  background-image:
    radial-gradient(ellipse 120% 55% at 50% -12%, rgba(43, 227, 162, 0.07), transparent 62%),
    radial-gradient(ellipse 80% 40% at 85% 108%, rgba(43, 227, 162, 0.04), transparent 60%);
  background-attachment: fixed;
}
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
input { font: inherit; color: inherit; }
a { color: var(--accent-ink); text-decoration: none; }

#app {
  max-width: var(--rail);
  margin: 0 auto;
  padding: 18px 18px calc(var(--tabbar-h) + var(--sab) + 32px);
  min-height: 100vh;
}

/* ---- view transitions ---------------------------------- */
.view { animation: view-in 0.34s cubic-bezier(0.22, 1, 0.36, 1) both; }
@keyframes view-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}
.rise { animation: view-in 0.5s cubic-bezier(0.22, 1, 0.36, 1) both; }
/* stagger helper: apply inline animation-delay */

/* ---- type ----------------------------------------------- */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.h-display {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 30px;
  line-height: 1.1;
  letter-spacing: -0.015em;
}
.h-section {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 17px;
  letter-spacing: -0.01em;
}
.mono { font-family: var(--font-mono); }
.muted { color: var(--ink-2); }
.dim { color: var(--ink-3); }
.pos { color: var(--pos); }
.neg { color: var(--neg); }

/* ---- top bar -------------------------------------------- */
.topbar {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 22px;
}
.topbar .date-chip {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  letter-spacing: 0.06em;
}
.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--ink-2);
  font-size: 14px;
  padding: 4px 0;
  margin-bottom: 14px;
}
.back-btn svg { width: 16px; height: 16px; }

/* ---- info dot (the only explainer affordance) ----------- */
.info-dot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  color: var(--ink-3);
  font-family: var(--font-mono);
  font-size: 11px;
  vertical-align: 2px;
  flex: none;
}
.info-dot:active { background: var(--accent-dim); color: var(--accent-ink); }

/* ---- exposure hero (Picks) ------------------------------ */
.exposure {
  padding: 4px 2px 26px;
  text-align: left;
}
.exposure .exp-label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}
.exposure .h-display { margin-bottom: 14px; }
.exposure .h-display em {
  font-style: normal;
  color: var(--accent-ink);
}
/* exposure gauge — an indicator, not a control: fill level = % invested */
.exp-gauge { max-width: 300px; margin-bottom: 12px; }
.exp-gauge .track {
  position: relative;
  height: 7px;
  border-radius: 4px;
  background: var(--panel-2);
  border: 1px solid var(--line);
}
.exp-gauge .fill {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  border-radius: 4px;
  background: linear-gradient(90deg, #1FA97C, var(--accent));
  box-shadow: 0 0 12px rgba(43, 227, 162, 0.35);
  transition: width 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}
.exp-gauge .ticks {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.09em;
  color: var(--ink-3);
}
.exp-gauge .ticks span.on { color: var(--accent-ink); font-weight: 600; }
.exposure .exp-note { font-size: 13.5px; color: var(--ink-2); }

/* ---- pick cards ----------------------------------------- */
.pick-card {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  text-align: left;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 15px 16px;
  margin-bottom: 10px;
  transition: transform 0.15s ease, border-color 0.15s ease;
}
.pick-card:active { transform: scale(0.985); border-color: var(--line-strong); }
.pick-card.top-rated {
  border-color: rgba(43, 227, 162, 0.45);
  background: linear-gradient(160deg, rgba(43, 227, 162, 0.10), var(--panel) 55%);
  box-shadow: 0 0 28px rgba(43, 227, 162, 0.10);
}
.pick-rank {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ink-3);
  width: 18px;
  flex: none;
  text-align: center;
}
.monogram {
  width: 42px;
  height: 42px;
  flex: none;
  position: relative;
  border-radius: 13px;
  background: var(--panel-2);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-ink);
  letter-spacing: 0.02em;
}
.monogram img {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 66%;
  height: 66%;
  object-fit: contain;
}
.monogram.img-ok span { visibility: hidden; }
.pick-main { flex: 1; min-width: 0; }
.pick-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 16px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pick-name .badge { margin-left: 8px; }
.pick-sub {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 5px;
}
.pick-score {
  text-align: right;
  flex: none;
}
.pick-score .q {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 21px;
  line-height: 1;
}
.pick-score .chg {
  font-family: var(--font-mono);
  font-size: 11.5px;
  margin-top: 4px;
}

/* signal badge — tiny, quiet */
.badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.09em;
  padding: 2.5px 7px;
  border-radius: 20px;
  vertical-align: 2px;
}
.badge.top-rated { background: var(--accent-dim); color: var(--accent-ink); border: 1px solid rgba(43, 227, 162, 0.4); }
.badge.qualified { background: rgba(43, 227, 162, 0.07); color: var(--accent-ink); }
.badge.neutral { background: var(--panel-2); color: var(--ink-3); }
.badge.unproven { background: rgba(232, 180, 76, 0.1); color: var(--warn); }
.badge.lagging { background: rgba(240, 104, 95, 0.09); color: var(--neg); }

/* ---- quality gate bar (signature element) ---------------- */
.gate {
  position: relative;
  height: 4px;
  border-radius: 2px;
  background: var(--panel-2);
  overflow: visible;
  flex: 1;
  max-width: 130px;
}
.gate .fill {
  position: absolute;
  inset: 0 auto 0 0;
  border-radius: 2px;
  background: var(--ink-3);
  transition: width 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}
.gate.above .fill { background: linear-gradient(90deg, #1FA97C, var(--accent)); }
.gate .notch {
  position: absolute;
  top: -3px;
  bottom: -3px;
  width: 2px;
  background: var(--ink-2);
  opacity: 0.65;
  border-radius: 1px;
}
.gate.lg { height: 8px; max-width: none; border-radius: 4px; }
.gate.lg .fill { border-radius: 4px; }
.gate.lg .notch { top: -5px; bottom: -5px; width: 2.5px; }
.gate.lg .notch::after {
  content: attr(data-label);
  position: absolute;
  top: -18px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--ink-3);
  letter-spacing: 0.08em;
  white-space: nowrap;
}

/* ---- cash day ------------------------------------------- */
.cash-hero {
  text-align: center;
  padding: 10vh 12px 0;
}
.cash-orb {
  width: 132px;
  height: 132px;
  margin: 0 auto 34px;
  border-radius: 50%;
  position: relative;
  background: radial-gradient(circle at 38% 32%, rgba(43, 227, 162, 0.16), rgba(43, 227, 162, 0.03) 58%, transparent 72%);
  border: 1px solid var(--line-strong);
  animation: orb-breathe 5s ease-in-out infinite;
}
.cash-orb::after {
  content: "";
  position: absolute;
  inset: -18px;
  border-radius: 50%;
  border: 1px solid var(--line);
  animation: orb-breathe 5s ease-in-out infinite reverse;
}
@keyframes orb-breathe {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.045); opacity: 0.85; }
}
.cash-hero .h-display { margin-bottom: 12px; }
.cash-hero p { color: var(--ink-2); font-size: 14.5px; max-width: 30ch; margin: 0 auto; }
.cash-hero .cash-link { display: inline-block; margin-top: 26px; font-size: 14px; color: var(--accent-ink); }

/* ---- list rows (Coins) ----------------------------------- */
.searchbar {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 11px 14px;
  margin-bottom: 14px;
}
.searchbar svg { width: 16px; height: 16px; color: var(--ink-3); flex: none; }
.searchbar input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  font-size: 15px;
  color: var(--ink);
}
.searchbar input::placeholder { color: var(--ink-3); }

.seg {
  display: inline-flex;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 3px;
  gap: 2px;
  margin-bottom: 14px;
}
.seg button {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.05em;
  color: var(--ink-3);
  padding: 6px 13px;
  border-radius: 9px;
}
.seg button.on { background: var(--panel-2); color: var(--accent-ink); }

.coin-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  text-align: left;
  padding: 12px 4px;
  border-bottom: 1px solid var(--line);
}
.coin-row:active { background: rgba(255, 255, 255, 0.02); }
.coin-row .rank {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  width: 24px;
  flex: none;
  text-align: right;
}
.coin-row .monogram { width: 30px; height: 30px; border-radius: 10px; font-size: 8.5px; }
.coin-row .cr-main { flex: 1; min-width: 0; }
.coin-row .cr-name {
  font-size: 14.5px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.coin-row .cr-name .tk { color: var(--ink-3); font-family: var(--font-mono); font-size: 11px; margin-left: 6px; }
.coin-row .cr-name .badge { margin-left: 8px; }
.coin-row .gate { margin-top: 6px; max-width: 110px; }
.coin-row .cr-right { text-align: right; flex: none; }
.coin-row .cr-q { font-family: var(--font-mono); font-weight: 600; font-size: 15px; }
.coin-row .cr-chg { font-family: var(--font-mono); font-size: 11px; margin-top: 2px; }

/* ---- coin detail ---------------------------------------- */
.coin-head { display: flex; align-items: center; gap: 14px; margin-bottom: 6px; }
.coin-head .monogram { width: 50px; height: 50px; border-radius: 16px; font-size: 13px; }
.coin-head .ch-name { flex: 1; min-width: 0; }
.coin-head .h-display { font-size: 26px; }
.coin-head .ch-cat { font-size: 12.5px; color: var(--ink-3); margin-top: 2px; }
.star-btn {
  width: 46px;
  height: 46px;
  flex: none;
  border-radius: 15px;
  border: 1px solid var(--line);
  background: var(--panel);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.12s ease;
}
.star-btn svg { width: 22px; height: 22px; color: var(--ink-3); transition: color 0.15s; }
.star-btn.on { border-color: rgba(43, 227, 162, 0.45); background: var(--accent-dim); }
.star-btn.on svg { color: var(--accent-ink); }
.star-btn.pop { animation: star-pop 0.35s cubic-bezier(0.34, 1.56, 0.64, 1); }
@keyframes star-pop { 0% { transform: scale(0.8); } 60% { transform: scale(1.12); } 100% { transform: scale(1); } }

.price-line {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin: 14px 0 22px;
}
.price-line .px { font-family: var(--font-mono); font-weight: 600; font-size: 22px; }
.price-line .chg { font-family: var(--font-mono); font-size: 13px; }

.score-hero {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 20px 18px 22px;
  margin-bottom: 12px;
}
.score-hero .sh-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 4px;
}
.score-hero .sh-num {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 56px;
  line-height: 1;
  letter-spacing: -0.02em;
}
.score-hero .sh-num small { font-size: 18px; color: var(--ink-3); font-weight: 500; }
.score-hero .sh-delta { font-family: var(--font-mono); font-size: 12.5px; margin-top: 8px; }
.score-hero .gate.lg { margin: 26px 0 12px; }
.score-hero .sh-reason { font-size: 13.5px; color: var(--ink-2); }
.score-hero .sh-rank {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  letter-spacing: 0.06em;
  margin-top: 10px;
}

/* ---- chart card ------------------------------------------ */
.chart-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 16px 14px 10px;
  margin-bottom: 12px;
}
.chart-card .cc-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 6px;
  padding: 0 4px;
}
.chart-card .seg { margin-bottom: 0; }
.chart-box { position: relative; height: 190px; }
.chart-box svg { display: block; width: 100%; height: 100%; }
.chart-tip {
  position: absolute;
  top: 4px;
  pointer-events: none;
  background: var(--panel-2);
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  padding: 5px 9px;
  font-family: var(--font-mono);
  font-size: 11px;
  white-space: nowrap;
  transform: translateX(-50%);
  display: none;
}
.lag-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.07em;
  color: var(--ink-2);
  border: 1px solid var(--line-strong);
  border-radius: 20px;
  padding: 6px 11px;
  white-space: nowrap;
  margin-left: auto;
}
.lag-chip:active { background: var(--panel-2); }
.lag-chip.on { color: var(--warn); border-color: rgba(232, 180, 76, 0.45); background: rgba(232, 180, 76, 0.08); }
.corr-note {
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.07em;
  color: var(--ink-3);
  padding: 9px 4px 0;
}
.corr-note b { font-weight: 600; }
.corr-note .info-dot { width: 16px; height: 16px; font-size: 10px; margin-left: 6px; }
/* amber dot = legend for the overlaid score line */
.corr-note i {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--warn);
  box-shadow: 0 0 7px rgba(232, 180, 76, 0.6);
  margin-right: 7px;
}
.range-tabs { display: flex; gap: 4px; justify-content: center; padding: 8px 0 4px; }
.range-tabs button {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-3);
  padding: 5px 12px;
  border-radius: 9px;
  letter-spacing: 0.05em;
}
.range-tabs button.on { background: var(--panel-2); color: var(--accent-ink); }

/* ---- quiet rows (about / buy / etc) ---------------------- */
.quiet-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  text-align: left;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 15px 16px;
  margin-bottom: 10px;
  font-size: 14.5px;
  font-weight: 500;
}
.quiet-row .qr-sub { display: block; font-size: 12px; color: var(--ink-3); font-weight: 400; margin-top: 2px; }
.quiet-row svg { width: 16px; height: 16px; color: var(--ink-3); flex: none; }
.quiet-body {
  padding: 4px 16px 16px;
  font-size: 13.5px;
  color: var(--ink-2);
  display: none;
}
.quiet-wrap { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; margin-bottom: 10px; }
.quiet-wrap .quiet-row { background: none; border: none; margin: 0; }
.quiet-wrap.open .quiet-body { display: block; }
.quiet-wrap.open .chev { transform: rotate(180deg); }
.chev { transition: transform 0.2s ease; }

.xchg-list { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 6px; }
.xchg-list a {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ink);
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 7px 13px;
}

/* ---- watchlist ------------------------------------------- */
.wl-summary {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 18px;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.wl-summary .wl-big {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 32px;
  line-height: 1;
}
.wl-summary .eyebrow { margin-bottom: 8px; }
.wl-summary .wl-count { text-align: right; font-size: 12.5px; color: var(--ink-3); }

.wl-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 15px 16px;
  margin-bottom: 10px;
}
.wl-card .wl-row1 {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  text-align: left;
}
.wl-card .wl-main { flex: 1; min-width: 0; }
.wl-card .wl-name { font-family: var(--font-display); font-weight: 600; font-size: 15.5px; }
.wl-card .wl-since { font-size: 11.5px; color: var(--ink-3); font-family: var(--font-mono); margin-top: 3px; }
.wl-card .wl-ret { text-align: right; flex: none; }
.wl-card .wl-ret .r { font-family: var(--font-mono); font-weight: 700; font-size: 20px; line-height: 1; }
.wl-card .wl-ret .rl { font-size: 10px; color: var(--ink-3); font-family: var(--font-mono); letter-spacing: 0.08em; margin-top: 4px; }
.wl-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.wl-actions .gate { max-width: none; }
.bell-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-3);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 6px 12px;
  flex: none;
}
.bell-chip svg { width: 13px; height: 13px; }
.bell-chip.on { color: var(--accent-ink); border-color: rgba(43, 227, 162, 0.4); background: var(--accent-dim); }

.wl-x {
  width: 30px;
  height: 30px;
  flex: none;
  border-radius: 50%;
  border: 1px solid var(--line);
  color: var(--ink-3);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s, border-color 0.15s;
}
.wl-x svg { width: 13px; height: 13px; }
.wl-x.confirm {
  width: auto;
  border-radius: 20px;
  padding: 0 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--neg);
  border-color: rgba(240, 104, 95, 0.5);
  background: rgba(240, 104, 95, 0.08);
}
.empty-state { text-align: center; padding: 12vh 20px 0; }
.empty-state .es-star {
  width: 74px;
  height: 74px;
  margin: 0 auto 26px;
  border-radius: 24px;
  background: var(--panel);
  border: 1px solid var(--line-strong);
  display: flex;
  align-items: center;
  justify-content: center;
}
.empty-state .es-star svg { width: 32px; height: 32px; color: var(--accent-ink); }
.empty-state .h-section { margin-bottom: 8px; }
.empty-state p { color: var(--ink-2); font-size: 14px; max-width: 30ch; margin: 0 auto; }

/* ---- more ------------------------------------------------ */
.more-list .quiet-row { margin-bottom: 8px; }
.lab-panel {
  margin-top: 28px;
  border: 1px dashed var(--line-strong);
  border-radius: 16px;
  padding: 14px 16px;
}
.lab-panel .eyebrow { margin-bottom: 10px; color: var(--warn); }
.lab-panel .seg { margin-bottom: 0; }

/* ---- performance ----------------------------------------- */
.perf-hero { padding: 4px 2px 20px; }
.perf-hero .p-big {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 52px;
  line-height: 1;
  letter-spacing: -0.02em;
  margin: 10px 0 6px;
}
.perf-hero .p-sub { font-size: 13.5px; color: var(--ink-2); }
.kpi-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; }
.kpi {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 13px 14px;
}
.kpi .k-v { font-family: var(--font-mono); font-weight: 600; font-size: 19px; }
.kpi .k-l { font-size: 11px; color: var(--ink-3); margin-top: 3px; letter-spacing: 0.04em; }
.legend { display: flex; gap: 14px; padding: 8px 4px 0; }
.legend span { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-mono); font-size: 11px; color: var(--ink-2); }
.legend i { width: 14px; height: 3px; border-radius: 2px; display: inline-block; }

/* ---- how it works ---------------------------------------- */
.step-card {
  display: flex;
  gap: 15px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 17px 16px;
  margin-bottom: 10px;
  align-items: flex-start;
}
.step-num {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 13px;
  color: var(--accent-ink);
  width: 30px;
  height: 30px;
  flex: none;
  border-radius: 10px;
  background: var(--accent-dim);
  display: flex;
  align-items: center;
  justify-content: center;
}
.step-card .st-t { font-family: var(--font-display); font-weight: 600; font-size: 15.5px; margin-bottom: 3px; }
.step-card p { font-size: 13.5px; color: var(--ink-2); }

/* ---- tab bar --------------------------------------------- */
#tabbar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: calc(var(--tabbar-h) + var(--sab));
  padding-bottom: var(--sab);
  background: rgba(11, 16, 14, 0.92);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: center;
  z-index: 40;
}
#tabbar .tabs { display: flex; width: 100%; max-width: var(--rail); }
#tabbar button {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  color: var(--ink-3);
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
#tabbar button svg { width: 21px; height: 21px; }
#tabbar button.on { color: var(--accent-ink); }
#tabbar button.on svg { filter: drop-shadow(0 0 7px rgba(43, 227, 162, 0.5)); }

/* ---- bottom sheet ---------------------------------------- */
#sheet-root .backdrop {
  position: fixed;
  inset: 0;
  background: rgba(4, 7, 6, 0.6);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
  z-index: 60;
  animation: fade-in 0.25s ease both;
}
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
body.sheet-open {
  position: fixed;
  left: 0;
  right: 0;
  width: 100%;
  overflow: hidden;
}
.sheet {
  touch-action: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 61;
  max-width: var(--rail);
  margin: 0 auto;
  background: var(--panel-2);
  border: 1px solid var(--line-strong);
  border-bottom: none;
  border-radius: 24px 24px 0 0;
  padding: 10px 20px calc(24px + var(--sab));
  animation: sheet-up 0.36s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@keyframes sheet-up { from { transform: translateY(100%); } to { transform: none; } }
.sheet.closing { animation: sheet-down 0.25s ease both; }
#sheet-root .backdrop.closing { animation: fade-in 0.25s ease reverse both; }
@keyframes sheet-down { from { transform: none; } to { transform: translateY(100%); } }
.sheet .grab {
  width: 38px;
  height: 4px;
  border-radius: 2px;
  background: var(--line-strong);
  margin: 4px auto 18px;
}
.sheet .h-section { margin-bottom: 10px; }
.sheet p { font-size: 14px; color: var(--ink-2); margin-bottom: 10px; }
.sheet p strong { color: var(--ink); font-weight: 600; }
.sheet-legend { display: grid; gap: 8px; margin: 14px 0 4px; }
.sheet-legend > div { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--ink-2); }

/* ---- alert editor sheet ---------------------------------- */
.alert-scale { position: relative; height: 74px; margin: 30px 6px 6px; }
.alert-track {
  position: absolute;
  top: 34px;
  left: 0;
  right: 0;
  height: 8px;
  border-radius: 4px;
  background: var(--panel);
  border: 1px solid var(--line);
}
.alert-track .notch {
  position: absolute;
  top: -5px;
  bottom: -5px;
  width: 2px;
  background: var(--ink-3);
}
.alert-track .now-dot {
  position: absolute;
  top: 50%;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ink);
  transform: translate(-50%, -50%);
  box-shadow: 0 0 8px rgba(233, 243, 237, 0.6);
}
.alert-handle {
  position: absolute;
  top: 22px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  transform: translateX(-50%);
  touch-action: none;
  display: flex;
  align-items: center;
  justify-content: center;
}
.alert-handle::before {
  content: "";
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--panel-2);
  border: 2.5px solid var(--accent);
  box-shadow: 0 0 10px rgba(43, 227, 162, 0.35);
}
.alert-handle.below::before { border-color: var(--warn); box-shadow: 0 0 10px rgba(232, 180, 76, 0.3); }
.alert-handle.off::before { border-color: var(--ink-3); box-shadow: none; opacity: 0.5; }
.alert-handle .hv {
  position: absolute;
  top: -20px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-ink);
}
.alert-handle.below .hv { color: var(--warn); top: auto; bottom: -20px; }
.alert-handle.off .hv { color: var(--ink-3); }
.alert-toggles { display: flex; gap: 8px; margin: 22px 0 4px; }
.alert-toggles button {
  flex: 1;
  font-family: var(--font-mono);
  font-size: 12px;
  padding: 11px 8px;
  border-radius: 13px;
  border: 1px solid var(--line);
  color: var(--ink-3);
  letter-spacing: 0.04em;
}
.alert-toggles button.on { color: var(--accent-ink); border-color: rgba(43, 227, 162, 0.4); background: var(--accent-dim); }
.alert-toggles button.on.warn { color: var(--warn); border-color: rgba(232, 180, 76, 0.4); background: rgba(232, 180, 76, 0.08); }
.sheet .primary-btn {
  width: 100%;
  margin-top: 18px;
  padding: 15px;
  border-radius: 15px;
  background: var(--accent);
  color: #06231A;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 15.5px;
}
.sheet .primary-btn:active { transform: scale(0.985); }
.sheet .ghost-btn {
  width: 100%;
  margin-top: 8px;
  padding: 12px;
  border-radius: 15px;
  color: var(--ink-3);
  font-size: 13.5px;
}
.sheet .danger { color: var(--neg); }

/* ---- auth / funnel screens -------------------------------- */
.auth-wrap { padding-top: 6vh; }
.auth-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 26px 22px;
}
.auth-card .h-display { font-size: 26px; margin-bottom: 8px; }
.auth-card .sub { font-size: 14px; color: var(--ink-2); margin-bottom: 20px; }
.field { display: block; margin-bottom: 14px; font-size: 12.5px; color: var(--ink-2); }
.field .field-hint { color: var(--ink-3); font-size: 11px; margin-left: 6px; }
.field input {
  display: block;
  width: 100%;
  margin-top: 6px;
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 13px 14px;
  font-size: 15px;
  color: var(--ink);
  outline: none;
}
.field input:focus { border-color: var(--line-strong); }
.field-error { color: var(--neg); font-size: 12.5px; min-height: 18px; margin: 4px 0 8px; }
.primary-btn {
  width: 100%;
  padding: 15px;
  border-radius: 15px;
  background: var(--accent);
  color: #06231A;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 15.5px;
}
.primary-btn:active { transform: scale(0.985); }
.primary-btn:disabled { opacity: 0.55; }
.ghost-btn { width: 100%; padding: 12px; border-radius: 15px; color: var(--ink-3); font-size: 13.5px; }
.ghost-btn.danger, .danger { color: var(--neg); }
.auth-alt { text-align: center; font-size: 13px; color: var(--ink-3); margin-top: 16px; }
.auth-alt a { color: var(--accent-ink); }
.auth-consent { text-align: center; font-size: 11.5px; color: var(--ink-3); margin-top: 12px; }
.auth-consent a { color: var(--ink-2); text-decoration: underline; text-decoration-color: var(--line-strong); }

.consent-check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 12.5px;
  color: var(--ink-2);
  line-height: 1.5;
  margin: 4px 0 14px;
  cursor: pointer;
}
.consent-check input { margin-top: 2px; flex: 0 0 auto; accent-color: var(--accent); width: 16px; height: 16px; }
.consent-check a { color: var(--accent-ink); font-weight: 600; }

/* ---- risk strip (v5.3: quiet, below content) --------------- */
.risk-strip {
  margin: 18px 4px 0;
  font-size: 11.5px;
  line-height: 1.55;
  color: var(--ink-3);
}
.risk-strip a { color: var(--ink-2); text-decoration: underline; text-decoration-color: var(--line-strong); }

/* ---- legal pages ------------------------------------------- */
.legal-updated { font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); margin-top: 6px; }
.legal-copy { color: var(--ink-2); font-size: 14px; margin-top: 18px; }
.legal-copy h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15.5px;
  color: var(--ink);
  margin: 20px 0 6px;
}
.legal-copy p + p { margin-top: 10px; }
.legal-copy ul { margin: 8px 0 8px 18px; }
.legal-copy li { margin: 4px 0; }
.legal-copy a { color: var(--accent-ink); }
.legal-copy strong { color: var(--ink); }

/* ---- account ----------------------------------------------- */
.acct-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 13.5px;
  color: var(--ink-2);
  padding: 9px 0;
  border-bottom: 1px solid var(--line);
}
.acct-line b { color: var(--ink); font-weight: 600; text-align: right; overflow-wrap: anywhere; }
.acct-actions { display: grid; gap: 8px; margin-top: 16px; }
.outline-btn {
  width: 100%;
  padding: 13px;
  border-radius: 15px;
  border: 1px solid var(--line-strong);
  color: var(--ink);
  font-size: 14px;
  font-weight: 500;
}

/* ---- onboarding -------------------------------------------- */
.onb { text-align: center; padding: 12vh 10px 0; position: relative; }
.onb-skip { position: absolute; top: 10px; right: 6px; color: var(--ink-3); font-size: 13px; padding: 8px; }
.onb-icon {
  width: 74px;
  height: 74px;
  margin: 0 auto 28px;
  border-radius: 24px;
  background: var(--accent-dim);
  border: 1px solid rgba(43, 227, 162, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  color: var(--accent-ink);
}
.onb .h-section { font-size: 19px; line-height: 1.35; margin-bottom: 12px; }
.onb p { color: var(--ink-2); font-size: 14px; max-width: 34ch; margin: 0 auto 26px; }
.onb-dots { display: flex; gap: 7px; justify-content: center; margin-bottom: 26px; }
.onb-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--panel-2); border: 1px solid var(--line); }
.onb-dots i.on { background: var(--accent); border-color: transparent; }
.onb .primary-btn { max-width: 340px; }

/* ---- paywall blurred board --------------------------------- */
.pw-board { position: relative; margin: 4px 0 18px; }
.pw-row {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 13px 14px;
  margin-bottom: 8px;
}
.pw-logo { width: 30px; height: 30px; border-radius: 10px; background: var(--panel); border: 1px solid var(--line); }
.pw-lines { flex: 1; display: grid; gap: 6px; }
.pw-lines i { display: block; height: 8px; border-radius: 4px; background: var(--panel); }
.pw-lines i:last-child { width: 55%; }
.pw-score { width: 34px; height: 20px; border-radius: 6px; background: rgba(43, 227, 162, 0.18); }
.pw-veil {
  position: absolute;
  inset: -4px;
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  background: linear-gradient(180deg, transparent, rgba(11, 16, 14, 0.55));
}

/* ---- consent banner (Meta pixel) --------------------------- */
#c42-consent {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 80;
  background: rgba(16, 23, 20, 0.97);
  border-top: 1px solid var(--line-strong);
  padding: 14px 18px calc(14px + var(--sab));
}
#c42-consent .cc-inner { max-width: var(--rail); margin: 0 auto; }
#c42-consent p { font-size: 13px; color: var(--ink-2); margin-bottom: 10px; }
#c42-consent .cc-actions { display: flex; align-items: center; gap: 10px; }
#c42-consent button {
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  padding: 9px 18px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
}
#c42-consent .cc-accept { background: var(--accent); color: #06231A; }
#c42-consent .cc-decline { background: none; border: 1px solid var(--line-strong); color: var(--ink-2); }
#c42-consent a { font-size: 12px; color: var(--ink-3); text-decoration: underline; margin-left: auto; }

/* small screens */
@media (max-width: 380px) {
  .h-display { font-size: 26px; }
  .score-hero .sh-num { font-size: 48px; }
}
