:root {
  --bg: #07070b;
  --bg-2: #0d0d14;
  --card: #12121b;
  --card-2: #181824;
  --line: #23232f;
  --text: #f4f4f8;
  --muted: #8b8b9e;
  --dim: #5c5c6e;
  --accent: #8b7cff;
  --accent-2: #2dd4bf;
  --yes: #2dd4bf;
  --yes-bg: rgba(45, 212, 191, 0.12);
  --no: #fb7185;
  --no-bg: rgba(251, 113, 133, 0.12);
  --up: #34d399;
  --down: #f87171;
  --radius: 18px;
  --display: "Space Grotesk", system-ui, sans-serif;
  --body: "Inter", system-ui, -apple-system, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --safe-b: env(safe-area-inset-bottom, 0px);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--body); }
body { min-height: 100dvh; overflow-x: hidden; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
svg { display: block; }
.num { font-variant-numeric: tabular-nums; }

.app {
  max-width: 560px; margin: 0 auto; min-height: 100dvh; position: relative;
  background:
    radial-gradient(120% 50% at 50% -10%, rgba(139, 124, 255, 0.16), transparent 60%),
    radial-gradient(80% 40% at 100% 0%, rgba(45, 212, 191, 0.08), transparent 60%),
    var(--bg);
}

/* ---------- top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px; backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  background: rgba(7, 7, 11, 0.72); border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.logo { font-family: "Outfit", var(--display); font-weight: 700; font-size: 24px; letter-spacing: -0.03em; display: flex; align-items: center; gap: 9px; }
.logo .dot { color: #14F1C8; }
.logo-mark { width: 34px; height: 34px; flex: none; margin-right: -2px; }
.balance { display: flex; flex-direction: column; align-items: flex-end; padding: 6px 12px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); }
.balance-label { font-size: 10px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.balance-value { font-family: var(--display); font-weight: 600; font-size: 15px; }

.view { padding: 8px 0 calc(96px + var(--safe-b)); }
.pad { padding: 0 16px; }

/* ---------- tabbar ---------- */
.tabbar {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 560px; z-index: 30;
  display: grid; grid-template-columns: repeat(4, 1fr); padding: 8px 8px calc(8px + var(--safe-b));
  background: rgba(10, 10, 16, 0.86); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border-top: 1px solid var(--line);
}
.tabbar a { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 11px; color: var(--dim); padding: 6px 0; font-weight: 500; }
.tabbar svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.tabbar a.active { color: var(--text); }
.tabbar a.active svg { stroke: var(--accent-2); }

/* ---------- chips ---------- */
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 8px 16px 14px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; padding: 8px 14px; border-radius: 999px; font-size: 13px; font-weight: 600; color: var(--muted);
  background: var(--card); border: 1px solid var(--line); transition: all .15s;
}
.chip.active { color: #0b0b12; background: var(--text); border-color: var(--text); }
.chip .live-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--no); margin-right: 6px; vertical-align: middle; animation: pulse 1.4s infinite; }

/* ---------- section heads ---------- */
.section-head { display: flex; align-items: baseline; justify-content: space-between; padding: 18px 16px 10px; }
.section-head h2 { margin: 0; font-family: var(--display); font-size: 20px; letter-spacing: -0.02em; }
.section-head span { color: var(--muted); font-size: 12px; }

/* ---------- hero carousel ---------- */
.hero-rail { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 16px 4px; scrollbar-width: none; }
.hero-rail::-webkit-scrollbar { display: none; }
.hero {
  flex: none; width: 86%; scroll-snap-align: center; border-radius: 24px; padding: 18px; position: relative; overflow: hidden;
  background: linear-gradient(160deg, #1a1830 0%, #101019 55%, #0b1a1a 100%); border: 1px solid #2a2840;
}
.hero::after { content: ""; position: absolute; inset: auto -30% -60% auto; width: 220px; height: 220px; border-radius: 50%; background: radial-gradient(circle, rgba(45, 212, 191, .18), transparent 70%); pointer-events: none; }
.hero .hero-title { font-family: var(--display); font-size: 22px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.15; margin: 10px 0 6px; }
.hero .hero-chart { margin: 8px -4px 4px; height: 90px; }

/* ---------- event cards ---------- */
.list { display: flex; flex-direction: column; gap: 12px; padding: 0 16px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; transition: border-color .15s, transform .15s; }
.card:active { transform: scale(.99); }
.card:hover { border-color: #33334a; }
.meta { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.badge { width: 30px; height: 30px; border-radius: 10px; display: grid; place-items: center; font-size: 16px; background: var(--card-2); border: 1px solid var(--line); flex: none; }
.live-tag { color: var(--no); display: inline-flex; align-items: center; gap: 5px; }
.live-tag::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; animation: pulse 1.4s infinite; }
.card-title { font-family: var(--display); font-size: 17px; font-weight: 600; letter-spacing: -0.01em; margin: 10px 0 12px; line-height: 1.25; }
.card-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 8px; padding: 7px 0; }
.card-row + .card-row { border-top: 1px solid rgba(255, 255, 255, .04); }
.row-label { font-size: 14px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: flex; align-items: center; gap: 8px; }
.row-label i { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.pct { font-family: var(--display); font-weight: 700; font-size: 16px; min-width: 44px; text-align: right; }
.delta { font-size: 11px; font-weight: 600; }
.delta.up { color: var(--up); } .delta.down { color: var(--down); } .delta.flat { color: var(--dim); }
.yn { display: flex; gap: 6px; }
.btn-yes, .btn-no {
  min-width: 58px; padding: 8px 10px; border-radius: 10px; font-weight: 700; font-size: 13px; font-variant-numeric: tabular-nums; transition: transform .1s, background .15s;
}
.btn-yes { color: var(--yes); background: var(--yes-bg); border: 1px solid rgba(45, 212, 191, .25); }
.btn-no { color: var(--no); background: var(--no-bg); border: 1px solid rgba(251, 113, 133, .25); }
.btn-yes:hover { background: rgba(45, 212, 191, .2); } .btn-no:hover { background: rgba(251, 113, 133, .2); }
.btn-yes:active, .btn-no:active { transform: scale(.95); }
.card-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; color: var(--dim); font-size: 12px; }
.more { color: var(--muted); font-size: 12px; margin-top: 6px; }

/* ---------- event page ---------- */
.ev-top { display: flex; justify-content: space-between; align-items: center; padding: 6px 12px; }
.icon-btn { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--card); border: 1px solid var(--line); }
.icon-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.icon-btn.on svg { fill: #fbbf24; stroke: #fbbf24; }
.ev-actions { display: flex; gap: 8px; }
.ev-title { font-family: var(--display); font-size: 28px; font-weight: 700; letter-spacing: -0.03em; line-height: 1.1; margin: 12px 0 4px; }
.ev-sub { color: var(--muted); font-size: 13px; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 14px 0 4px; font-size: 13px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.legend b { color: var(--text); font-variant-numeric: tabular-nums; }
.legend i { width: 8px; height: 8px; border-radius: 50%; }
.chart-wrap { position: relative; margin: 6px 0 0; height: 220px; touch-action: pan-y; }
.chart-wrap svg { width: 100%; height: 100%; overflow: visible; }
.chart-tip { position: absolute; top: -6px; transform: translateX(-50%); font-size: 11px; color: var(--muted); white-space: nowrap; pointer-events: none; }
.ranges { display: flex; justify-content: space-between; align-items: center; margin: 8px 0 4px; }
.ranges .vol { color: var(--muted); font-size: 12px; }
.range-tabs { display: flex; gap: 4px; }
.range-tabs button { padding: 6px 10px; border-radius: 8px; font-size: 12px; font-weight: 700; color: var(--dim); }
.range-tabs button.active { color: var(--text); background: var(--card-2); }
.mk-row { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: center; padding: 14px 0; border-top: 1px solid var(--line); }
.mk-name { font-weight: 600; font-size: 15px; display: flex; align-items: center; gap: 8px; }
.mk-sub { display: flex; gap: 10px; align-items: center; margin-top: 4px; font-size: 12px; color: var(--muted); }
.mk-sub .bar { width: 60px; height: 3px; border-radius: 3px; background: var(--line); overflow: hidden; }
.mk-sub .bar i { display: block; height: 100%; }
.mk-row.resolved { opacity: .6; }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin-top: 14px; }
.panel h3 { margin: 0 0 10px; font-family: var(--display); font-size: 16px; }
.rules { color: var(--muted); font-size: 13px; line-height: 1.55; margin: 0; }
.feed { list-style: none; margin: 0; padding: 0; font-size: 13px; }
.feed li { display: flex; justify-content: space-between; gap: 10px; padding: 8px 0; border-top: 1px solid rgba(255, 255, 255, .04); }
.feed li:first-child { border-top: 0; }
.feed .who { color: var(--muted); }
.feed .yes { color: var(--yes); font-weight: 600; } .feed .no { color: var(--no); font-weight: 600; }
.feed li.fresh { animation: flash 1.2s ease-out; }

/* ---------- portfolio ---------- */
.equity { padding: 18px 16px 6px; }
.equity .label { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
.equity .big { font-family: var(--display); font-size: 42px; font-weight: 700; letter-spacing: -0.03em; margin: 4px 0; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 10px 16px; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 12px; }
.stat .k { color: var(--muted); font-size: 11px; }
.stat .v { font-family: var(--display); font-weight: 600; font-size: 16px; margin-top: 4px; }
.pos { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; }
.pos-title { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pos-name { font-weight: 600; margin-top: 2px; }
.pos-side { font-size: 11px; font-weight: 700; padding: 2px 6px; border-radius: 6px; margin-left: 6px; }
.pos-side.yes { color: var(--yes); background: var(--yes-bg); } .pos-side.no { color: var(--no); background: var(--no-bg); }
.pos-val { text-align: right; }
.pos-val .v { font-family: var(--display); font-weight: 600; }
.pos-actions { display: flex; gap: 8px; margin-top: 12px; }
.btn { flex: 1; padding: 11px; border-radius: 12px; font-weight: 700; font-size: 14px; background: var(--card-2); border: 1px solid var(--line); }
.btn.primary { background: var(--text); color: #0b0b12; border-color: var(--text); }
.empty { text-align: center; color: var(--muted); padding: 40px 24px; }
.empty h3 { color: var(--text); font-family: var(--display); margin: 10px 0 6px; }
.up { color: var(--up); } .down { color: var(--down); }

/* ---------- search ---------- */
.search-box { margin: 8px 16px 8px; display: flex; align-items: center; gap: 10px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; }
.search-box svg { width: 18px; height: 18px; fill: none; stroke: var(--muted); stroke-width: 2; }
.search-box input { flex: 1; background: none; border: 0; outline: 0; color: var(--text); font: inherit; font-size: 16px; }

/* ---------- leaderboard ---------- */
.lb-row { display: grid; grid-template-columns: 28px 1fr auto; gap: 10px; align-items: center; padding: 12px 0; border-top: 1px solid var(--line); }
.lb-row:first-child { border-top: 0; }
.lb-rank { font-family: var(--display); font-weight: 700; color: var(--muted); }

/* ---------- trade sheet ---------- */
.sheet-backdrop { position: fixed; inset: 0; background: rgba(0, 0, 0, .6); z-index: 40; animation: fade .2s; }
.sheet {
  position: fixed; left: 50%; bottom: 0; transform: translateX(-50%); width: 100%; max-width: 560px; z-index: 50;
  background: #101018; border: 1px solid var(--line); border-bottom: 0; border-radius: 26px 26px 0 0;
  padding: 10px 18px calc(20px + var(--safe-b)); animation: rise .28s cubic-bezier(.2, .9, .3, 1.1); max-height: 92dvh; overflow-y: auto;
}
.grabber { width: 40px; height: 4px; border-radius: 4px; background: var(--line); margin: 0 auto 12px; }
.sheet-head { display: flex; gap: 12px; align-items: center; }
.sheet-head .t { font-size: 12px; color: var(--muted); }
.sheet-head h3 { margin: 2px 0 0; font-family: var(--display); font-size: 18px; }
.seg { display: grid; grid-template-columns: 1fr 1fr; background: var(--bg); border: 1px solid var(--line); border-radius: 14px; padding: 4px; margin-top: 14px; }
.seg button { padding: 10px; border-radius: 10px; font-weight: 700; color: var(--muted); }
.seg button.on-yes { background: var(--yes-bg); color: var(--yes); }
.seg button.on-no { background: var(--no-bg); color: var(--no); }
.seg button.on { background: var(--card-2); color: var(--text); }
.amount { text-align: center; margin: 18px 0 6px; }
.amount input {
  width: 100%; text-align: center; background: none; border: 0; outline: 0; color: var(--text);
  font-family: var(--display); font-size: 52px; font-weight: 700; letter-spacing: -0.03em;
}
.amount .hint { color: var(--muted); font-size: 12px; }
.quick { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 10px 0 14px; }
.quick button { padding: 9px 0; border-radius: 10px; background: var(--card); border: 1px solid var(--line); font-weight: 600; font-size: 13px; }
.quote { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 4px 14px; }
.quote .r { display: flex; justify-content: space-between; padding: 9px 0; font-size: 14px; }
.quote .r + .r { border-top: 1px solid rgba(255, 255, 255, .04); }
.quote .r span:first-child { color: var(--muted); }
.quote .r.hl span:last-child { font-family: var(--display); font-weight: 700; font-size: 17px; color: var(--up); }
.warn { color: #fbbf24; font-size: 12px; margin-top: 8px; }
.err { color: var(--no); font-size: 13px; margin-top: 8px; min-height: 18px; }
.confirm { width: 100%; margin-top: 14px; padding: 16px; border-radius: 16px; font-weight: 700; font-size: 16px; color: #07070b; transition: filter .15s, transform .1s; }
.confirm.yes { background: var(--yes); } .confirm.no { background: var(--no); }
.confirm:disabled { filter: grayscale(.8) brightness(.6); cursor: not-allowed; }
.confirm:active:not(:disabled) { transform: scale(.98); }
.fine { text-align: center; color: var(--dim); font-size: 11px; margin-top: 10px; }

/* ---------- share ticket ---------- */
.ticket {
  margin-top: 8px; border-radius: 22px; overflow: hidden; position: relative;
  background: linear-gradient(155deg, #2a2150, #141226 55%, #0c2422); border: 1px solid #3a3366;
}
.ticket-top { padding: 18px; }
.ticket-brand { display: flex; justify-content: space-between; align-items: center; font-size: 11px; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.ticket-brand b { font-family: "Outfit", var(--display); font-weight: 700; font-size: 16px; color: var(--text); text-transform: none; letter-spacing: -0.02em; }
.ticket h4 { font-size: 15px; font-weight: 500; margin: 14px 0 10px; color: #d6d6e4; }
.ticket .pick { font-family: var(--display); font-weight: 700; font-size: 26px; letter-spacing: -0.02em; }
.ticket .pick small { display: block; font-family: var(--body); font-size: 13px; font-weight: 500; color: var(--muted); margin-top: 2px; letter-spacing: 0; }
.ticket-tape { font-family: var(--mono); font-size: 10px; letter-spacing: .2em; color: rgba(255, 255, 255, .35); white-space: nowrap; overflow: hidden; padding: 6px 18px; background: rgba(0, 0, 0, .25); border-top: 1px dashed rgba(255, 255, 255, .15); border-bottom: 1px dashed rgba(255, 255, 255, .15); }
.ticket-bottom { display: grid; grid-template-columns: 1fr 1fr; padding: 16px 18px; }
.ticket-bottom .k { font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.ticket-bottom .v { font-family: var(--display); font-weight: 700; font-size: 24px; margin-top: 2px; }
.ticket-bottom .v.win { color: var(--yes); }

/* ---------- v2: combos, accounts, live data, install ---------- */
.topbar { padding-top: calc(14px + env(safe-area-inset-top, 0px)); }
.closed-tag { color: #fbbf24; }
.data-tag { margin-left: auto; color: var(--accent-2); font-size: 10px; letter-spacing: .04em; }
.model { color: var(--accent); font-weight: 600; }
.in-combo { color: #fbbf24; font-weight: 600; }
.notice { color: #fbbf24; font-size: 13px; }
.live-data { background: linear-gradient(140deg, rgba(45, 212, 191, .08), rgba(139, 124, 255, .06)), var(--card); }
.ld-head { display: flex; align-items: center; gap: 8px; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--accent-2); }
.pulse-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent-2); animation: pulse 1.4s infinite; }
.ld-value { font-family: var(--display); font-size: 28px; font-weight: 700; margin: 6px 0 4px; }
.ld-value.ld-text { font-size: 20px; line-height: 1.3; }
.ld-value.ld-text small { display: block; margin: 4px 0 0; }
.ld-value small { font-family: var(--body); font-size: 12px; color: var(--muted); font-weight: 500; margin-left: 8px; }
.combo-add { width: 100%; margin-top: 10px; padding: 12px; border-radius: 14px; border: 1px dashed #3a3366; color: var(--accent); font-weight: 600; font-size: 14px; }
.combo-add:hover { background: rgba(139, 124, 255, .08); }
.confirm.combo { background: linear-gradient(90deg, var(--accent), var(--accent-2)); }
.combo-bar {
  position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(74px + var(--safe-b)); z-index: 29; width: calc(100% - 24px); max-width: 536px;
  display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 16px; font-weight: 600; font-size: 14px; text-align: left;
  background: linear-gradient(90deg, #2a2150, #12302c); border: 1px solid #3a3366; box-shadow: 0 10px 30px rgba(0, 0, 0, .5); animation: rise .25s;
}
.combo-bar[hidden] { display: none; }
.cb-count { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--text); color: #0b0b12; font-weight: 700; }
.cb-go { margin-left: auto; color: var(--accent-2); }
body:has(.combo-bar:not([hidden])) .view { padding-bottom: calc(150px + var(--safe-b)); }
.legs { list-style: none; margin: 10px 0 0; padding: 0; }
.legs li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 9px 0; border-top: 1px solid rgba(255, 255, 255, .05); font-size: 14px; font-weight: 500; }
.legs li:first-child { border-top: 0; }
.legs small { display: block; color: var(--muted); font-size: 11px; font-weight: 400; margin-top: 2px; }
.legs li.won .num { color: var(--up); } .legs li.lost { opacity: .55; } .legs li.lost .num { color: var(--down); }
.legs .x, .install .x { width: 28px; height: 28px; border-radius: 50%; color: var(--muted); margin-left: 8px; }
.legs .x:hover, .install .x:hover { background: var(--card-2); color: var(--text); }
.legs.editable .num { display: flex; align-items: center; }
.link-btn { color: var(--muted); font-size: 13px; font-weight: 600; padding: 6px; }
.status-pill { margin-left: auto; font-size: 10px; padding: 3px 8px; border-radius: 999px; letter-spacing: .04em; }
.status-pill.open { color: var(--accent-2); background: var(--yes-bg); }
.status-pill.won { color: #0b0b12; background: var(--up); }
.status-pill.lost { color: var(--no); background: var(--no-bg); }
.status-pill.cashed { color: var(--text); background: var(--card-2); }
.account b { font-family: var(--display); font-size: 16px; }
.account p { color: var(--muted); font-size: 13px; margin: 4px 0 0; line-height: 1.45; }
.account.row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 4px; }
.auth { display: flex; flex-direction: column; gap: 12px; margin-top: 16px; }
.auth label { display: flex; flex-direction: column; gap: 6px; font-size: 12px; color: var(--muted); font-weight: 600; }
.auth select { background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 13px 14px; color: var(--text); font: inherit; font-size: 16px; outline: 0; }
.auth input { background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 13px 14px; color: var(--text); font: inherit; font-size: 16px; outline: 0; }
.auth input:focus { border-color: var(--accent); }
.install { margin: 0 16px 14px; display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); }
.install img { border-radius: 10px; }
.install b { font-size: 14px; }
.install p { margin: 2px 0 0; color: var(--muted); font-size: 12px; }
.install .btn { flex: none; padding: 9px 14px; }
.install-row { width: 100%; margin: 4px 0 0; cursor: pointer; color: var(--text); font: inherit; }
.install-row .cb-go { margin-left: auto; font-size: 22px; color: var(--accent-2); }

/* ---------- motion: live prices, entrances, charts, celebrations ---------- */
/* price ticks: digits roll in JS; the chip flashes in the direction of the move */
.btn-yes.flash-up, .btn-no.flash-up { animation: chipUp .9s ease-out; }
.btn-yes.flash-down, .btn-no.flash-down { animation: chipDown .9s ease-out; }
.pct.flash-up, b.flash-up, .ld-value span.flash-up, .vol span.flash-up, .balance-value.flash-up { animation: textUp .9s ease-out; }
.pct.flash-down, b.flash-down, .ld-value span.flash-down, .vol span.flash-down, .balance-value.flash-down { animation: textDown .9s ease-out; }
@keyframes chipUp { 0% { background: rgba(52, 211, 153, .45); box-shadow: 0 0 0 2px rgba(52, 211, 153, .7), 0 0 18px rgba(52, 211, 153, .5); transform: translateY(-2px); } 100% { } }
@keyframes chipDown { 0% { background: rgba(248, 113, 113, .4); box-shadow: 0 0 0 2px rgba(248, 113, 113, .7), 0 0 18px rgba(248, 113, 113, .45); transform: translateY(2px); } 100% { } }
@keyframes textUp { 0% { color: var(--up); text-shadow: 0 0 14px rgba(52, 211, 153, .8); } 100% { } }
@keyframes textDown { 0% { color: var(--down); text-shadow: 0 0 14px rgba(248, 113, 113, .8); } 100% { } }
.mk-sub .bar i { transition: width .7s cubic-bezier(.2, .8, .2, 1); }

/* page entrance: blocks cascade in */
.view.enter .chips, .view.enter .hero, .view.enter .section-head, .view.enter .list > *, .view.enter .ev-top,
.view.enter .pad > *, .view.enter .equity, .view.enter .stat, .view.enter .install, .view.enter .search-box, .view.enter .mk-row {
  animation: rise-in .7s cubic-bezier(.2, .8, .2, 1) both; animation-delay: calc(var(--i, 0) * 55ms);
}
@keyframes rise-in { from { opacity: 0; transform: translateY(22px) scale(.985); filter: blur(4px); } }

/* charts draw themselves */
.view.enter .spark { stroke-dasharray: 100; animation: draw 1.3s cubic-bezier(.3, .7, .2, 1) both .25s; }
.chart-wrap.animate path.draw { stroke-dasharray: 100; animation: draw 1.4s cubic-bezier(.3, .7, .2, 1) both; animation-delay: var(--d, 0ms); }
.chart-wrap.animate .area { animation: fade-in 1s ease-out both .6s; }
.chart-wrap.animate circle.end { animation: pop-in .5s cubic-bezier(.2, 1.6, .4, 1) both 1.25s; transform-box: fill-box; transform-origin: center; }
@keyframes draw { from { stroke-dashoffset: 100; } to { stroke-dashoffset: 0; } }
@keyframes fade-in { from { opacity: 0; } }
@keyframes pop-in { from { transform: scale(0); } }

/* live activity: new trades slide in */
.feed li.fresh { animation: slide-in .6s cubic-bezier(.2, .8, .2, 1), flash 1.4s ease-out; }
@keyframes slide-in { from { opacity: 0; transform: translateX(-16px); } }

/* tickets pop off the sheet, confetti bursts */
.ticket { animation: ticket-pop .8s cubic-bezier(.2, 1.3, .35, 1) both; transform-origin: 50% 80%; }
@keyframes ticket-pop { from { opacity: 0; transform: perspective(900px) rotateX(-28deg) translateY(40px) scale(.86); } }
.ticket::after { content: ""; position: absolute; inset: 0; background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .22) 50%, transparent 65%);
  transform: translateX(-120%); animation: shine 1.2s ease-out .55s both; pointer-events: none; }
@keyframes shine { to { transform: translateX(120%); } }
.confetti-box { position: absolute; left: 50%; top: 40%; width: 0; height: 0; pointer-events: none; z-index: 5; }
.confetti-box i { position: absolute; width: 8px; height: 13px; border-radius: 2px; animation: confetti 1.5s cubic-bezier(.15, .7, .3, 1) both; }
@keyframes confetti { 0% { transform: translate(0, 0) rotate(0) scale(.4); opacity: 1; }
  70% { opacity: 1; } 100% { transform: translate(var(--dx), calc(var(--dy) + 260px)) rotate(var(--r)) scale(1); opacity: 0; } }
.sheet { position: fixed; }
.quote .r.hl span:last-child { transition: color .3s; }

/* ---------- toast ---------- */
.toast { position: fixed; left: 50%; top: calc(76px + env(safe-area-inset-top, 0px)); transform: translateX(-50%); z-index: 60; background: var(--text); color: #0b0b12; padding: 10px 16px; border-radius: 12px; font-weight: 600; font-size: 14px; animation: drop .25s; max-width: 90vw; z-index: 70; box-shadow: 0 8px 24px rgba(0,0,0,.4); }

/* ---------- skeleton ---------- */
.skel { height: 140px; border-radius: var(--radius); background: linear-gradient(90deg, var(--card) 0%, var(--card-2) 50%, var(--card) 100%); background-size: 200% 100%; animation: shimmer 1.2s infinite; }

.disclaimer { color: var(--dim); font-size: 11px; text-align: center; padding: 24px 24px 0; line-height: 1.5; }

@keyframes pulse { 50% { opacity: .35; } }
@keyframes rise { from { transform: translate(-50%, 30px); opacity: 0; } }
@keyframes drop { from { transform: translate(-50%, -16px); opacity: 0; } }
@keyframes fade { from { opacity: 0; } }
@keyframes shimmer { to { background-position: -200% 0; } }
@keyframes flash { from { background: rgba(139, 124, 255, .18); } }

@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }
@media (min-width: 600px) { .app { border-left: 1px solid var(--line); border-right: 1px solid var(--line); } }

.hero .btn-no { display: none; }
.hero .card-row { grid-template-columns: minmax(0, 1fr) auto auto; }
@media (max-width: 380px) { .btn-yes, .btn-no { min-width: 50px; padding: 8px 7px; font-size: 12px; } }

/* ---------- weekly tournament */
.tourney { position: relative; border-radius: var(--radius); padding: 18px 16px 14px; overflow: hidden;
  background: radial-gradient(120% 90% at 100% 0%, rgba(123,63,242,.35), transparent 60%), radial-gradient(90% 80% at 0% 100%, rgba(20,241,200,.18), transparent 60%), var(--card);
  border: 1px solid rgba(139,124,255,.35); }
.tourney::after { content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit;
  background: linear-gradient(115deg, transparent 30%, rgba(255,255,255,.07) 50%, transparent 70%); background-size: 250% 100%; animation: th-shine 5s ease-in-out infinite; }
@keyframes th-shine { 0%, 40% { background-position: 120% 0; } 100% { background-position: -120% 0; } }
.th-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.th-badge { font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: #c4b5fd; }
.th-count { font-family: var(--mono); font-size: 13px; color: var(--text); white-space: nowrap; }
.th-count small { color: var(--muted); font-family: var(--body); font-size: 11px; }
.th-prize { margin-top: 10px; font-family: var(--display); font-size: 26px; font-weight: 700; letter-spacing: -.02em;
  background: linear-gradient(90deg, #14F1C8, #19C6EE 45%, #a78bfa); -webkit-background-clip: text; background-clip: text; color: transparent; }
.th-sub { color: var(--muted); font-size: 13px; margin-top: 4px; }
.th-you { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 14px; padding: 12px 14px; border-radius: 14px; background: rgba(7,7,11,.55); border: 1px solid var(--line); }
.th-you p { margin: 2px 0 0; color: var(--muted); font-size: 12px; }
.th-you .btn { flex: none; padding: 9px 16px; }
.th-rank { font-family: var(--display); font-size: 24px; font-weight: 700; }
.th-rank small { font-size: 13px; color: var(--muted); font-weight: 500; }
.th-ret { text-align: right; display: flex; flex-direction: column; font-family: var(--display); }
.th-ret b { font-size: 22px; } .th-ret small { font-family: var(--mono); font-size: 12px; opacity: .8; }
.th-warn { display: flex; align-items: center; gap: 10px; margin-top: 10px; font-size: 12px; color: #fcd34d; }
.th-warn .btn { flex: none; padding: 8px 14px; }
.th-won { padding: 14px 16px; border-radius: 14px; background: linear-gradient(120deg, rgba(20,241,200,.16), rgba(123,63,242,.2)); border: 1px solid rgba(20,241,200,.4); }
.th-won p { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.th-last { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; font-size: 13px; padding: 2px 2px 0; }
.th-last > span:first-child { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; font-weight: 700; }
.th-pod b { font-weight: 700; margin-left: 2px; }
.lb-row.me { background: linear-gradient(90deg, rgba(45,212,191,.08), transparent); margin: 0 -16px; padding-left: 16px; padding-right: 16px; }
.lb-ret { display: flex; flex-direction: column; align-items: flex-end; font-weight: 700; }
.lb-ret small { font-size: 11px; color: var(--muted); font-weight: 500; }
.guest-tag { color: var(--dim); font-size: 11px; }
.th-rules { color: var(--dim); font-size: 11px; line-height: 1.5; margin: 12px 2px 0; }
@media (prefers-reduced-motion: reduce) { .tourney::after { animation: none; } }

/* ---------- share cards */
.share-prev { display: grid; place-items: center; aspect-ratio: 9 / 16; max-height: 52vh; margin: 0 auto; border-radius: 18px; overflow: hidden; background: var(--bg); border: 1px solid var(--line); }
.share-prev img { width: 100%; height: 100%; object-fit: contain; display: block; animation: card-in .5s cubic-bezier(.2,.9,.3,1.2); }
.share-load { color: var(--muted); font-size: 13px; animation: pulse 1.2s ease-in-out infinite; }
@keyframes card-in { from { opacity: 0; transform: scale(.92) translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes pulse { 50% { opacity: .4; } }
.share-btn { flex: 0 0 auto !important; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding-left: 14px; padding-right: 14px; }
.share-btn.grow { flex: 1 1 auto !important; }
.th-share { width: 100%; margin-top: 10px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.invite-row { font-size: 14px; }

/* ---------- streaks */
.top-right { display: flex; align-items: center; gap: 8px; }
.streak-chip { display: inline-flex; align-items: center; gap: 4px; padding: 8px 11px; border-radius: 12px; background: var(--card); border: 1px solid rgba(251,146,60,.4); font-family: var(--display); font-size: 15px; }
.streak-chip .flame { font-size: 16px; display: inline-block; animation: flicker 2.4s ease-in-out infinite; transform-origin: 50% 90%; }
.streak-chip.cold { border-color: var(--line); color: var(--muted); }
.streak-chip.cold .flame { filter: grayscale(1) opacity(.55); animation: none; }
.streak-chip.at-risk { animation: risk 1.8s ease-in-out infinite; }
@keyframes flicker { 0%, 100% { transform: scale(1) rotate(-2deg); } 30% { transform: scale(1.12) rotate(3deg); } 60% { transform: scale(.96) rotate(-1deg); } }
@keyframes risk { 0%, 100% { box-shadow: 0 0 0 0 rgba(251,146,60,0); } 50% { box-shadow: 0 0 0 4px rgba(251,146,60,.25); } }
.streak-banner { display: flex; align-items: center; gap: 12px; margin-top: 14px; padding: 12px 14px; border-radius: 14px; background: rgba(251,146,60,.1); border: 1px solid rgba(251,146,60,.35); animation: card-in .5s cubic-bezier(.2,.9,.3,1.2) both .15s; }
.streak-banner.bonus { background: linear-gradient(110deg, rgba(251,146,60,.18), rgba(250,204,21,.14)); border-color: rgba(250,204,21,.55); }
.streak-banner p { margin: 2px 0 0; font-size: 13px; color: var(--muted); }
.flame.big { font-size: 30px; animation: flicker 2s ease-in-out infinite; display: inline-block; transform-origin: 50% 90%; }
.streak-hero { text-align: center; padding: 6px 0 4px; }
.flame.huge { font-size: 64px; display: inline-block; animation: flicker 2s ease-in-out infinite; transform-origin: 50% 90%; filter: drop-shadow(0 6px 24px rgba(251,146,60,.5)); }
.streak-hero.cold .flame.huge { filter: grayscale(1) opacity(.5); animation: none; }
.streak-count { font-family: var(--display); font-size: 56px; font-weight: 700; line-height: 1; margin-top: 4px;
  background: linear-gradient(180deg, #fde68a, #fb923c 60%, #f43f5e); -webkit-background-clip: text; background-clip: text; color: transparent; }
.streak-hero.cold .streak-count { background: none; color: var(--muted); }
.streak-label { color: var(--muted); font-size: 14px; margin-top: 2px; }
.streak-status { text-align: center; font-size: 14px; margin: 12px 0 14px; }
.ladder { display: grid; gap: 8px; }
.rung { display: grid; grid-template-columns: 64px 1fr auto; gap: 10px; align-items: center; font-size: 13px; padding: 10px 12px; border-radius: 12px; background: var(--bg); border: 1px solid var(--line); }
.rung-day { font-weight: 700; }
.rung-bar { height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; }
.rung-bar i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #fb923c, #facc15); transition: width .8s cubic-bezier(.2,.8,.2,1); }
.rung-bonus { font-family: var(--display); font-weight: 700; color: var(--muted); }
.rung.done { border-color: rgba(250,204,21,.4); } .rung.done .rung-bonus { color: #facc15; }
.rung.next { border-color: rgba(251,146,60,.55); }
@media (max-width: 340px) { .logo span { display: none; } }
@media (prefers-reduced-motion: reduce) { .streak-chip .flame, .flame.big, .flame.huge, .streak-chip.at-risk { animation: none; } }

/* ---------- first pick */
.first-pick { position: relative; margin-top: 4px; padding: 18px 16px 14px; border-radius: var(--radius); overflow: hidden;
  background: radial-gradient(110% 80% at 0% 0%, rgba(20,241,200,.16), transparent 60%), radial-gradient(100% 90% at 100% 100%, rgba(123,63,242,.28), transparent 60%), var(--card);
  border: 1px solid rgba(20,241,200,.35); animation: card-in .55s cubic-bezier(.2,.9,.3,1.2) both; }
.fp-x { position: absolute; top: 10px; right: 10px; width: 30px; height: 30px; border-radius: 50%; color: var(--muted); font-size: 14px; }
.fp-kicker { font-size: 12px; font-weight: 700; color: #5eead4; letter-spacing: .02em; }
.first-pick h3 { margin: 6px 0 2px; font-family: var(--display); font-size: 24px; letter-spacing: -.02em; }
.fp-sub { color: var(--muted); font-size: 13px; }
.fp-teams { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
.fp-team { position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 14px 12px 12px; border-radius: 16px; text-align: left;
  background: linear-gradient(160deg, color-mix(in srgb, var(--c) 38%, transparent), rgba(18,18,27,.9) 70%); border: 1px solid color-mix(in srgb, var(--c) 60%, #ffffff22);
  transition: transform .15s ease, box-shadow .2s ease; min-height: 112px; }
.fp-team:active { transform: scale(.97); }
.fp-team:hover { box-shadow: 0 8px 28px -10px color-mix(in srgb, var(--c) 80%, transparent); }
.fp-name { font-weight: 700; font-size: 15px; line-height: 1.2; }
.fp-pct { font-family: var(--display); font-size: 30px; font-weight: 700; margin-top: auto; }
.fp-pay { font-size: 12px; color: var(--muted); }
.fp-team.picking { animation: pulse 1s ease-in-out infinite; }
.fp-team:disabled:not(.picking) { opacity: .45; }
.fp-foot { color: var(--muted); font-size: 12px; line-height: 1.45; margin-top: 12px; }
@media (prefers-reduced-motion: reduce) { .first-pick, .fp-team.picking { animation: none; } }

/* ---------- real-money partners */
.realmoney { margin-top: 0; border-color: rgba(250,204,21,.28); background: linear-gradient(160deg, rgba(250,204,21,.07), transparent 55%), var(--card); }
.rm-tag { display: inline-block; font-size: 10px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); border: 1px solid var(--line); border-radius: 6px; padding: 2px 6px; }
.rm-title { display: block; font-family: var(--display); font-size: 18px; margin-top: 8px; }
.realmoney p { color: var(--muted); font-size: 13px; margin: 6px 0 10px; line-height: 1.45; }
.rm-ages { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.rm-ages .btn { padding: 10px 6px; font-size: 13px; }
.rm-offer { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.rm-offer > div { display: flex; flex-direction: column; min-width: 0; }
.rm-offer span { color: var(--muted); font-size: 13px; }
.rm-offer small { color: var(--dim); font-size: 11px; margin-top: 2px; }
.rm-offer .btn { flex: none; padding: 9px 18px; text-decoration: none; }
.realmoney .rm-fine { font-size: 11px; color: var(--dim); margin: 10px 0 4px; }
.rm-hide { color: var(--muted); font-size: 12px; text-decoration: underline; padding: 4px 0; }

/* ---------- email & account */
.auth label.check { flex-direction: row; align-items: flex-start; gap: 10px; font-weight: 500; font-size: 13px; color: var(--text); cursor: pointer; }
.auth label.check input { width: 20px; height: 20px; padding: 0; margin: 1px 0 0; flex: none; accent-color: var(--accent-2); }
.linkish { color: var(--accent); text-decoration: underline; font-size: inherit; padding: 0; }
.email-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; margin-top: 12px; padding: 12px 0 2px; border-top: 1px solid var(--line); text-align: left; }
.email-row > span:first-child { display: flex; flex-direction: column; font-size: 14px; min-width: 0; overflow-wrap: anywhere; }
.email-row small { color: var(--muted); font-size: 12px; margin-top: 2px; }
.disclaimer a { color: var(--muted); }

/* ---------- language picker */
.lang-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: 14px; }
.lang-row select { background: var(--bg); color: var(--text); border: 1px solid var(--line); border-radius: 12px; padding: 9px 12px; font: inherit; font-weight: 700; font-size: 14px; }

/* ---------- 🌐 language chip */
.lang-chip { display: inline-flex; align-items: center; gap: 4px; padding: 8px 10px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); font-family: var(--display); font-size: 13px; }
.lang-chip b { font-weight: 700; letter-spacing: .02em; }
.lang-menu { position: fixed; z-index: 60; min-width: 170px; padding: 6px; border-radius: 14px; background: var(--card-2); border: 1px solid var(--line);
  box-shadow: 0 18px 40px -12px rgba(0,0,0,.7); animation: card-in .18s ease-out; }
.lang-menu button { display: flex; justify-content: space-between; align-items: center; width: 100%; padding: 11px 12px; border-radius: 10px; font-size: 15px; text-align: left; }
.lang-menu button:hover, .lang-menu button:focus { background: var(--card); outline: 0; }
.lang-menu button.on { color: var(--accent-2); font-weight: 700; }
@media (max-width: 400px) {
  .topbar { padding-left: 12px; padding-right: 12px; }
  .top-right { gap: 6px; }
  .logo { font-size: 21px; gap: 7px; }
  .logo-mark { width: 30px; height: 30px; }
  .lang-chip span { display: none; }
  .lang-chip, .streak-chip { padding: 8px 9px; }
  .balance { padding: 6px 10px; }
  .balance-label { display: none; }
}
/* ---------- legal links & delete account */
.legal-links { text-align: center; color: var(--dim); font-size: 12px; margin: 22px 16px 8px; }
.legal-links a { color: var(--muted); }
.danger-link { color: var(--no) !important; font-size: 12px; }
.th-rules a { color: var(--muted); }

/* ---------- private leagues */
.seg.lb-tabs3 { grid-template-columns: repeat(3, 1fr); }
.lg-item { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 13px 0; border-top: 1px solid var(--line); color: inherit; text-decoration: none; }
.lg-item:first-child { border-top: 0; padding-top: 2px; }
.lg-item > div:first-child { display: flex; flex-direction: column; min-width: 0; }
.lg-item small { color: var(--muted); font-size: 12px; margin-top: 2px; }
.lg-me { display: flex; flex-direction: column; align-items: flex-end; font-family: var(--display); }
.lg-me b { font-size: 18px; }
.lg-empty { text-align: center; }
.lg-empty p { color: var(--muted); font-size: 13px; line-height: 1.45; margin: 6px 0 0; }
.lg-form { display: flex; gap: 8px; }
.lg-form input { flex: 1; min-width: 0; background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; color: var(--text); font: inherit; font-size: 16px; outline: 0; }
.lg-form input:focus { border-color: var(--accent); }
.lg-form .btn { flex: none; padding: 0 18px; }
.lg-hero { padding: 4px 0 6px; }
.lg-code { font-family: var(--mono); letter-spacing: .08em; color: var(--text); }
.lg-invite { display: flex; justify-content: space-between; align-items: center; gap: 12px;
  background: linear-gradient(120deg, rgba(20,241,200,.12), rgba(123,63,242,.16)), var(--card); border-color: rgba(20,241,200,.35); }
.lg-invite > div { display: flex; flex-direction: column; }
.lg-invite small { color: var(--muted); font-size: 12px; margin-top: 2px; }
.lg-invite .btn { flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 10px 16px; }
.seg.lb-tabs3 button { font-size: 14px; padding-left: 4px; padding-right: 4px; line-height: 1.2; }

/* ---------- league questions */
.q-title { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.q-title small { color: var(--muted); font-size: 12px; }
.q-card { display: block; padding: 14px 0; border-top: 1px solid var(--line); color: inherit; text-decoration: none; }
.q-card.settled { opacity: .75; }
.q-head { display: flex; gap: 10px; align-items: center; }
.q-head b { font-size: 15px; line-height: 1.3; }
.q-opts { display: grid; gap: 6px; margin: 10px 0 8px; }
.q-opt { display: grid; grid-template-columns: minmax(0, 1fr) 80px 44px; align-items: center; gap: 10px; font-size: 14px; }
.q-opt span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.q-opt b { text-align: right; }
.q-opt.win span:first-child { color: var(--accent); font-weight: 700; }
.q-status { font-size: 12px; color: var(--muted); }
.q-won { color: var(--accent); font-weight: 700; }
.q-wait { color: #FFB020; }
.q-ask-btn { width: 100%; margin-top: 10px; }
.q-form { display: grid; gap: 10px; margin-top: 14px; }
.q-form label { display: grid; gap: 6px; font-size: 13px; color: var(--muted); }
.q-form input { background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; color: var(--text); font: inherit; font-size: 16px; outline: 0; min-width: 0; width: 100%; color-scheme: dark; }
.q-form input:focus { border-color: var(--accent); }
#qOpts { display: grid; gap: 8px; }
.q-icons { display: flex; gap: 6px; flex-wrap: wrap; }
.q-icons button { width: 40px; height: 40px; border-radius: 12px; background: var(--bg); border: 1px solid var(--line); font-size: 19px; }
.q-icons button.on { border-color: var(--accent); background: rgba(20,241,200,.12); }
.q-league-chip { display: inline-flex; align-items: center; gap: 4px; margin-top: 12px; padding: 7px 12px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); color: var(--text); font-size: 13px; text-decoration: none; }
.q-settle { border-color: rgba(255,176,32,.45); }
.q-settle-btns { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 8px; margin-bottom: 12px; }
.q-settle-btns .btn { padding: 12px; }
.q-opt .bar { display: block; height: 6px; border-radius: 6px; background: var(--line); overflow: hidden; }
.q-opt .bar i { display: block; height: 100%; }
.q-form[hidden], #qAddOpt[hidden] { display: none; }

/* ---------- live score on league questions */
.q-score { margin-top: 12px; text-align: center; border-color: rgba(255,92,122,.45);
  background: linear-gradient(160deg, rgba(255,92,122,.10), rgba(123,63,242,.10)), var(--card); }
.q-score.final { border-color: var(--line); background: var(--card); }
.q-score-top { display: flex; justify-content: center; align-items: center; gap: 10px; color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
.q-score-text { font-family: var(--display); font-size: 26px; font-weight: 700; line-height: 1.2; margin-top: 8px; overflow-wrap: anywhere; }
.q-card-score { display: flex; align-items: center; gap: 8px; margin: 0 0 6px; font-size: 15px; }

/* ---------- games */
.g-card { padding: 14px 0; border-top: 1px solid var(--line); }
.g-head { display: flex; align-items: center; gap: 12px; }
.g-sport { width: 44px; height: 44px; flex: none; display: grid; place-items: center; border-radius: 14px; background: var(--bg); border: 1px solid var(--line); font-size: 22px; }
.g-main { flex: 1; min-width: 0; }
.g-main b { font-size: 16px; }
.g-when { font-size: 13px; color: var(--muted); margin-top: 2px; }
.g-soon { color: #FFB020; font-weight: 600; }
.g-count { display: flex; flex-direction: column; align-items: flex-end; font-family: var(--display); }
.g-count b { font-size: 18px; }
.g-count small { color: var(--muted); font-size: 11px; }
.g-place { display: flex; align-items: center; gap: 6px; margin-top: 10px; color: var(--text); text-decoration: none; font-size: 14px; }
.g-place small { color: var(--accent); margin-left: auto; flex: none; }
.g-note { margin: 6px 0 0; color: var(--muted); font-size: 13px; }
.g-bar { height: 6px; border-radius: 6px; background: var(--line); overflow: hidden; margin: 10px 0 6px; }
.g-bar i { display: block; height: 100%; background: linear-gradient(90deg, #14F1C8, #7B3FF2); }
.g-names { font-size: 12px; color: var(--muted); line-height: 1.4; }
.g-actions { display: flex; align-items: center; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.g-in { flex: 1; min-width: 140px; }
.g-in.on { border-color: var(--accent); color: var(--accent); }
.g-in.wait { border-color: #FFB020; color: #FFB020; }
.g-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.g-chips button { padding: 9px 12px; border-radius: 999px; background: var(--bg); border: 1px solid var(--line); font-size: 14px; }
.g-chips button.on { border-color: var(--accent); background: rgba(20,241,200,.12); }
.q-form input[hidden] { display: none; }

/* ---------- prediction on a game card */
.g-pred { display: block; margin-top: 10px; padding: 10px 12px; border-radius: 12px; text-decoration: none; color: var(--text);
  background: linear-gradient(120deg, rgba(123,63,242,.14), rgba(20,241,200,.08)); border: 1px solid rgba(123,63,242,.35); }
.g-pred-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.g-pred-score b { color: var(--text); font-size: 14px; }
.g-pred-opts { display: flex; gap: 14px; flex-wrap: wrap; margin: 6px 0 4px; font-size: 14px; }
.g-pred-opts .win { color: var(--accent); font-weight: 700; }
.g-pred-cta { font-size: 13px; color: var(--accent); font-weight: 600; }
.g-pred-add { display: inline-block; margin-top: 8px; }
.g-pred-form { display: grid; gap: 10px; margin-top: 10px; }
.g-pred-form[hidden], .g-pred-add[hidden] { display: none; }
.g-pred-teams { display: grid; grid-template-columns: 1fr auto 1fr; gap: 8px; align-items: center; color: var(--muted); font-size: 13px; }
.g-pred-form input.g-team { min-width: 0; width: 100%; background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 12px; color: var(--text); font: inherit; font-size: 16px; outline: 0; }
.g-pred-form input.g-team:focus { border-color: var(--accent); }
.g-draw { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
.g-draw input { width: 18px; height: 18px; accent-color: #14F1C8; }
.g-pred-top { flex-wrap: wrap; } .g-pred-top > span:first-child { white-space: nowrap; }
