:root {
  /* Floodlit palette — luminance-stepped surface ramp (premium dark mode) */
  --bg: #0A0E13;          /* canvas — deeper for OLED black-point + glow contrast */
  --surface: #131A24;     /* level 1 — cards / panels */
  --surface-2: #1B2430;   /* level 2 — nested cards, hover, segments */
  --surface-3: #25303E;   /* level 3 — modals / overlays / sheets */
  --line: #33414F;        /* hairlines / dividers */
  --teal: #14E0C8;        /* brand / primary CTA */
  --teal-bright: #2FF3DC; /* hover / peak-chroma strokes (small areas only) */
  --teal-dim: #0BA899;    /* pressed / large fills (APCA-safe) */
  --indigo: #5B6CFF;      /* bridge accent — links / secondary */
  --purple: #7C3AED;      /* rivalry / versus (scarce) */
  --red: #FF5063;         /* rationed: the commit action only */
  --gold: #FFC83D;        /* winning / trophy / #1 */
  --green: #2BD17E;       /* money / positive (de-clichéd, cooler) */
  --loss: #E63946;        /* negative */
  --amber: #FF8C42;       /* streak flame */
  --text: #F4F7FB;
  --muted: #93A1B3;
  --muted-2: #5E6B7C;
  --radius: 16px;
  --shadow: 0 14px 40px rgba(0, 0, 0, 0.5);
  /* signature gradient — "Floodlit Teal" aurora */
  --aurora: radial-gradient(120% 90% at 15% 0%, rgba(24,232,255,.20) 0%, transparent 45%),
            radial-gradient(110% 80% at 85% 8%, rgba(91,108,255,.18) 0%, transparent 50%),
            linear-gradient(160deg, rgba(20,224,200,.10) 0%, rgba(91,108,255,.06) 55%, transparent 100%);
}

* { box-sizing: border-box; }

html, body {
  margin: 0; padding: 0;
  background:
    radial-gradient(900px 480px at 50% -8%, rgba(20, 224, 200, 0.10) 0%, transparent 60%),
    radial-gradient(700px 400px at 90% 10%, rgba(124, 58, 237, 0.06) 0%, transparent 55%),
    var(--bg);
  color: var(--text);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "tnum" 1, "cv05" 1;
}

.wrap { max-width: 470px; margin: 0 auto; padding: calc(20px + env(safe-area-inset-top)) 16px 56px; min-height: 100vh; min-height: 100dvh; }

/* ---------- brand header ---------- */
header.brand { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
header.brand a { color: inherit; text-decoration: none; display: flex; gap: 11px; align-items: center; }
header.brand .logo {
  width: 36px; height: 36px; border-radius: 11px;
  background: linear-gradient(140deg, var(--teal), var(--teal-dim));
  display: grid; place-items: center; font-size: 20px;
  box-shadow: 0 6px 18px rgba(20, 224, 200, 0.35);
}
header.brand h1 { font-family: "Anton", sans-serif; font-size: 24px; margin: 0; letter-spacing: 0.5px; text-transform: uppercase; }
header.brand .tag { color: var(--muted); font-size: 11.5px; margin-top: -2px; }
.idchip {
  display: flex; align-items: center; gap: 7px; background: var(--surface);
  border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px 5px 6px;
  font-size: 13px; font-weight: 700; cursor: pointer;
}
.idchip .av {
  width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center;
  font-size: 11px; font-weight: 800; color: #06140f;
  background: linear-gradient(140deg, var(--teal), var(--teal-dim));
}

/* ---------- cards ---------- */
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px; box-shadow: var(--shadow); margin-bottom: 14px;
  animation: rise .32s cubic-bezier(.2,.7,.3,1) both;
}
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

h2 { font-size: 18px; margin: 0 0 4px; letter-spacing: -0.3px; font-weight: 800; }
.sub { color: var(--muted); font-size: 13.5px; margin: 0 0 16px; line-height: 1.5; }
.cardhead { display: flex; justify-content: space-between; align-items: center; gap: 10px; }

/* ---------- form ---------- */
label { display: block; font-size: 12.5px; color: var(--muted); margin: 15px 0 6px; font-weight: 700; letter-spacing: .2px; }
input, select {
  width: 100%; background: var(--surface-2); border: 1px solid var(--line); color: var(--text);
  border-radius: 12px; padding: 13px 14px; font-size: 15px; outline: none;
  -webkit-appearance: none; appearance: none; font-family: inherit; transition: border-color .15s;
}
input::placeholder { color: var(--muted-2); }
input:focus, select:focus { border-color: var(--teal); }
.row { display: flex; gap: 10px; } .row > * { flex: 1; }

.seg { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px; }
.seg button {
  background: var(--surface-2); border: 1px solid var(--line); color: var(--text);
  border-radius: 12px; padding: 13px 6px; font-size: 13.5px; font-weight: 700; cursor: pointer;
  transition: all .14s ease;
}
.seg button.active {
  background: linear-gradient(140deg, var(--teal), var(--teal-dim));
  border-color: transparent; color: #06140f; transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(20, 224, 200, 0.3);
}

/* ---------- buttons ---------- */
button.cta {
  width: 100%; border: none; border-radius: 14px; padding: 16px; font-size: 16px; font-weight: 800;
  cursor: pointer; margin-top: 20px; letter-spacing: -0.2px; font-family: inherit;
  background: linear-gradient(140deg, var(--teal), var(--teal-dim)); color: #06140f;
  transition: transform .08s, box-shadow .2s; box-shadow: 0 8px 22px rgba(20, 224, 200, 0.28);
}
button.cta.commit { background: linear-gradient(140deg, #FF6271, var(--red)); color: #fff; box-shadow: 0 8px 22px rgba(255, 71, 87, 0.32); }
button.cta.gold { background: linear-gradient(140deg, #FFD976, var(--gold)); color: #2a1d00; box-shadow: 0 8px 22px rgba(255, 200, 61, 0.3); }
button.cta.wa { background: #25D366; color: #04241a; box-shadow: 0 8px 22px rgba(37, 211, 102, 0.28); }
button.cta:active { transform: translateY(2px); }
button.cta:disabled { opacity: .55; cursor: default; }
button.ghost {
  width: 100%; background: var(--surface-2); color: var(--text); border: 1px solid var(--line);
  border-radius: 13px; padding: 14px; font-size: 14.5px; font-weight: 700; cursor: pointer;
  margin-top: 10px; font-family: inherit;
}
.muted-link { background: none; border: none; color: var(--muted); font-size: 13px; cursor: pointer; text-decoration: underline; margin-top: 14px; display: block; width: 100%; font-family: inherit; }

/* ---------- pills / status ---------- */
.pill { display: inline-block; font-size: 11px; font-weight: 800; padding: 4px 11px; border-radius: 999px; text-transform: uppercase; letter-spacing: .5px; }
.pill.open { background: rgba(20,224,200,.15); color: var(--teal); }
.pill.accepted { background: rgba(255,200,61,.16); color: var(--gold); }
.pill.resolved { background: rgba(46,213,115,.16); color: var(--green); }
.pill.settled { background: rgba(154,167,184,.16); color: var(--muted); }

/* ---------- match card ---------- */
.match { text-align: center; padding: 18px 12px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 14px; margin: 8px 0 4px; }
.match .teams { font-size: 20px; font-weight: 800; letter-spacing: -0.4px; }
.match .vs { color: var(--muted); font-weight: 700; margin: 0 9px; font-size: 13px; font-family: "Anton", sans-serif; letter-spacing: 1px; }
.match .meta { color: var(--muted); font-size: 12.5px; margin-top: 6px; }

/* ---------- sides ---------- */
.side { display: flex; align-items: center; justify-content: space-between; padding: 13px 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); margin-top: 10px; }
.side .who { font-weight: 800; font-size: 14.5px; }
.side .pick { color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.side .stake { font-weight: 800; font-size: 16px; font-variant-numeric: tabular-nums; }
.side.win { border-color: var(--gold); box-shadow: inset 0 0 0 1px var(--gold), 0 0 24px rgba(255,200,61,.12); background: linear-gradient(140deg, rgba(255,200,61,.08), transparent); }

/* ---------- rivalry banner ---------- */
.rivalry {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 12px 14px; border-radius: 12px; margin: 10px 0;
  background: linear-gradient(140deg, rgba(124,58,237,.16), rgba(20,224,200,.06));
  border: 1px solid rgba(124,58,237,.3);
}
.rivalry .vsline { font-weight: 800; font-size: 14.5px; }
.rivalry .score { font-family: "Anton", sans-serif; font-size: 22px; letter-spacing: 1px; }
.rivalry .lead { color: var(--teal); } .rivalry .trail { color: var(--loss); } .rivalry .level { color: var(--muted); }

/* ---------- owes / payoff ---------- */
.owes { text-align: center; padding: 22px 14px; border-radius: 16px; margin: 8px 0; background: linear-gradient(140deg, rgba(46,213,115,.14), rgba(20,224,200,.05)); border: 1px solid rgba(46,213,115,.3); }
.owes .lbl { color: var(--muted); font-size: 13px; font-weight: 600; }
.owes .big { font-family: "Anton", sans-serif; font-size: 30px; letter-spacing: 0.5px; margin: 6px 0; }
.owes .amt { font-family: "Anton", sans-serif; font-size: 26px; color: var(--green); font-variant-numeric: tabular-nums; }

.note { background: rgba(20,224,200,.07); border-left: 3px solid var(--teal); padding: 10px 12px; border-radius: 8px; font-size: 13.5px; color: #cfe9e5; margin: 12px 0; font-style: italic; }

.linkbox { display: flex; gap: 8px; margin-top: 12px; }
.linkbox input { font-size: 12.5px; color: var(--muted); }
.linkbox button { flex: 0 0 auto; padding: 0 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); color: var(--text); font-weight: 700; cursor: pointer; font-size: 13px; font-family: inherit; }

.banner { font-size: 12px; color: var(--muted); text-align: center; background: var(--surface); border: 1px dashed var(--line); border-radius: 10px; padding: 9px; margin-top: 4px; }

.cardimg { width: 100%; aspect-ratio: 1200 / 630; border-radius: 14px; border: 1px solid var(--line); margin: 14px 0 12px; display: block; background: var(--bg); box-shadow: 0 8px 24px rgba(0,0,0,.35); }

/* ---------- dashboard stats ---------- */
.stats { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; margin: 4px 0 6px; }
.stat { background: var(--surface-2); border: 1px solid var(--line); border-radius: 14px; padding: 14px 10px; text-align: center; }
.stat .n { font-family: "Anton", sans-serif; font-size: 26px; letter-spacing: .5px; font-variant-numeric: tabular-nums; line-height: 1; }
.stat .k { color: var(--muted); font-size: 11px; margin-top: 6px; text-transform: uppercase; letter-spacing: .5px; font-weight: 700; }
.stat .n.pos { color: var(--green); } .stat .n.neg { color: var(--loss); } .stat .n.gold { color: var(--gold); }

.riv-row { display: flex; align-items: center; justify-content: space-between; padding: 13px 4px; border-bottom: 1px solid var(--line); }
.riv-row:last-child { border-bottom: none; }
.riv-row .nm { font-weight: 800; font-size: 15px; display: flex; align-items: center; gap: 8px; }
.riv-row .rec { font-family: "Anton", sans-serif; font-size: 18px; letter-spacing: 1px; }
.riv-row .sm { font-size: 11.5px; color: var(--muted); font-weight: 600; }
.tag-rival { font-size: 9.5px; background: rgba(124,58,237,.25); color: #c9b4ff; padding: 2px 7px; border-radius: 999px; font-weight: 800; letter-spacing: .5px; text-transform: uppercase; }

.linkbtn { background: none; border: none; color: var(--teal); font-size: 13px; font-weight: 700; cursor: pointer; font-family: inherit; padding: 0; }

.lg-head, .lg-row { display: grid; grid-template-columns: 34px 1fr 58px 82px; align-items: center; gap: 6px; padding: 11px 6px; border-bottom: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.lg-head { color: var(--muted); font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px; }
.lg-row:last-child { border-bottom: none; }
.lg-row.me { background: rgba(20,224,200,.08); border-radius: 10px; }
.lg-rank { font-family: "Anton", sans-serif; font-size: 18px; color: var(--muted); text-align: center; }
.lg-row.me .lg-rank { color: var(--teal); }
.lg-name { font-weight: 800; font-size: 14.5px; }
.lg-rec { font-weight: 700; font-size: 13.5px; text-align: center; color: var(--muted); }
.lg-net { font-weight: 800; font-size: 14px; text-align: right; }
.lg-net.pos { color: var(--green); } .lg-net.neg { color: var(--loss); }

.flame { color: var(--amber); font-weight: 800; display: inline-flex; align-items: center; gap: 3px; }
.flame.on { animation: flicker 1.4s ease-in-out infinite; }
@keyframes flicker { 0%,100% { transform: scale(1); filter: drop-shadow(0 0 2px rgba(255,140,66,.5)); } 50% { transform: scale(1.12); filter: drop-shadow(0 0 8px rgba(255,140,66,.85)); } }

.recent { display: flex; align-items: center; justify-content: space-between; padding: 9px 2px; font-size: 13px; border-bottom: 1px solid var(--line); }
.recent:last-child { border-bottom: none; }
.recent .res { font-weight: 800; font-variant-numeric: tabular-nums; }
.recent .res.w { color: var(--green); } .recent .res.l { color: var(--loss); }

/* ---------- animations: lock-in, reveal, win ---------- */
.locking { animation: lockpulse .6s cubic-bezier(.2,.8,.2,1); }
@keyframes lockpulse { 0% { transform: scale(1); } 35% { transform: scale(.96); } 70% { transform: scale(1.02); } 100% { transform: scale(1); } }
.sealwrap { text-align: center; padding: 30px 0; }
.seal {
  width: 88px; height: 88px; margin: 0 auto 14px; border-radius: 50%;
  background: linear-gradient(140deg, var(--teal), var(--teal-dim)); display: grid; place-items: center;
  font-size: 44px; color: #06140f; animation: pop .5s cubic-bezier(.2,1.4,.4,1) both;
  box-shadow: 0 10px 30px rgba(20,224,200,.4);
}
@keyframes pop { 0% { transform: scale(0) rotate(-25deg); } 100% { transform: scale(1) rotate(0); } }
.reveal { animation: revealUp .55s cubic-bezier(.2,.7,.3,1) both; }
@keyframes revealUp { 0% { opacity: 0; transform: translateY(14px) scale(.97); } 100% { opacity: 1; transform: none; } }
.delay1 { animation-delay: .12s; } .delay2 { animation-delay: .26s; } .delay3 { animation-delay: .42s; }

#confetti { position: fixed; inset: 0; pointer-events: none; z-index: 60; }

.toast { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); background: var(--text); color: var(--bg); padding: 11px 18px; border-radius: 999px; font-weight: 800; font-size: 13.5px; box-shadow: var(--shadow); opacity: 0; pointer-events: none; transition: opacity .2s; z-index: 70; }
.toast.show { opacity: 1; }

.foot { text-align: center; color: var(--muted-2); font-size: 11.5px; margin-top: 24px; line-height: 1.6; }
.spin { text-align: center; color: var(--muted); padding: 48px; }

/* =========================================================
   Floodlit — ambient background, intro, motion
   ========================================================= */
.wrap { position: relative; z-index: 1; }

.amb { position: fixed; inset: 0; pointer-events: none; z-index: 0; }
.amb-aurora {
  background:
    radial-gradient(38vw 30vw at 16% 10%, rgba(20,224,200,.14), transparent 60%),
    radial-gradient(44vw 34vw at 86% 16%, rgba(124,58,237,.12), transparent 62%),
    radial-gradient(52vw 42vw at 50% 112%, rgba(255,140,66,.07), transparent 60%);
  animation: auroraDrift 26s ease-in-out infinite alternate;
  will-change: transform, opacity;
}
@keyframes auroraDrift {
  0%   { transform: translate3d(0,0,0) scale(1);        opacity: .82; }
  50%  { transform: translate3d(2.5%,-2%,0) scale(1.07); opacity: 1; }
  100% { transform: translate3d(-2%,2%,0) scale(1.04);   opacity: .8; }
}
.amb-spot {
  background: radial-gradient(340px 340px at var(--mx,50%) var(--my,12%), rgba(20,224,200,.12), transparent 72%);
  transition: background .12s linear;
}
.amb-grain {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: .04; mix-blend-mode: soft-light;
}

/* animated logo (header + intro) */
.logo { position: relative; overflow: hidden; }
.logo .ball, .intro-logo .ball { display: block; width: 76%; height: 76%; filter: drop-shadow(0 2px 4px rgba(0,0,0,.25)); }
.ball-spin { transform-box: fill-box; transform-origin: 50% 50%; animation: ballSpin 6s linear infinite; }
/* dramatic spin-in on the entry page (2 full rotations as it scales in), then a quick continuous spin */
.intro-logo .ball-spin { animation: ballKick 1.4s cubic-bezier(.15,.85,.25,1) .15s both, ballSpin 1.6s linear 1.55s infinite; }
@keyframes ballSpin { to { transform: rotate(360deg); } }
@keyframes ballKick { 0% { transform: rotate(0deg) scale(.2); } 70% { transform: rotate(560deg) scale(1.12); } 100% { transform: rotate(720deg) scale(1); } }
.logo::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(115deg, transparent 42%, rgba(255,255,255,.42) 50%, transparent 58%);
  transform: translateX(-130%); animation: logoSheen 7s ease-in-out infinite;
}
@keyframes logoSheen { 0%,72% { transform: translateX(-130%); } 88%,100% { transform: translateX(130%); } }

/* intro — floodlights on */
.no-intro .intro { display: none; }
.intro {
  position: fixed; inset: 0; z-index: 100; background: var(--aurora), #06080c;
  display: flex; align-items: center; justify-content: center; overflow: hidden;
  animation: introOut .55s ease 1.2s forwards;
}
.intro.gone { display: none; }
.intro-beam { position: absolute; top: -25%; width: 42%; height: 150%; opacity: 0; filter: blur(38px); }
.beam-l { left: 2%;  transform: rotate(15deg);  background: linear-gradient(180deg, rgba(20,224,200,.30), transparent 72%); animation: beamIn .9s ease .05s forwards; }
.beam-r { right: 2%; transform: rotate(-15deg); background: linear-gradient(180deg, rgba(124,58,237,.26), transparent 72%); animation: beamIn .9s ease .18s forwards; }
@keyframes beamIn { to { opacity: 1; } }
.intro-core { text-align: center; animation: coreIn .8s cubic-bezier(.2,.9,.3,1) .28s both; }
@keyframes coreIn { from { opacity: 0; transform: translateY(10px) scale(.9); filter: blur(7px); } to { opacity: 1; transform: none; filter: blur(0); } }
.intro-logo {
  width: 100px; height: 100px; margin: 0 auto 18px; border-radius: 28px;
  background: linear-gradient(140deg, #14E0C8, #0FB7A4); display: grid; place-items: center; font-size: 54px;
  animation: logoBloom 1.4s ease .3s both;
}
@keyframes logoBloom {
  0%   { box-shadow: 0 10px 40px rgba(20,224,200,0); }
  45%  { box-shadow: 0 12px 72px rgba(20,224,200,.6); }
  100% { box-shadow: 0 12px 38px rgba(20,224,200,.32); }
}
.intro-word { font-family: "Anton", sans-serif; font-size: 50px; letter-spacing: 3px; color: #F5F7FA; line-height: 1; }
.intro-rule { height: 3px; width: 0; margin: 12px auto 0; background: linear-gradient(90deg, #14E0C8, #7C3AED); border-radius: 2px; animation: ruleDraw .6s ease .7s forwards; }
@keyframes ruleDraw { to { width: 150px; } }
.intro-tag { color: #9AA7B8; font-size: 13px; margin-top: 10px; letter-spacing: 2px; }
@keyframes introOut { to { opacity: 0; transform: scale(1.05); visibility: hidden; } }

/* button sheen + commit glow */
button.cta { position: relative; overflow: hidden; }
button.cta::after {
  content: ''; position: absolute; top: 0; left: 0; width: 55%; height: 100%;
  background: linear-gradient(110deg, transparent, rgba(255,255,255,.20), transparent);
  transform: translateX(-180%) skewX(-16deg); animation: ctaSheen 5s ease-in-out infinite; pointer-events: none;
}
@keyframes ctaSheen { 0%,58% { transform: translateX(-180%) skewX(-16deg); } 82%,100% { transform: translateX(320%) skewX(-16deg); } }
button.cta.commit { animation: commitPulse 3s ease-in-out infinite; }
@keyframes commitPulse { 0%,100% { box-shadow: 0 8px 22px rgba(255,71,87,.30); } 50% { box-shadow: 0 10px 34px rgba(255,71,87,.52); } }

@media (prefers-reduced-motion: reduce) {
  .amb-aurora, .logo::after, button.cta::after, button.cta.commit { animation: none !important; }
}

/* =========================================================
   Motion system, tab bar, sheet, reactions, odometer
   ========================================================= */
:root {
  --smooth: cubic-bezier(.4, 0, .2, 1);          /* content / screen changes */
  --snappy: cubic-bezier(.2, .9, .25, 1);        /* controls / taps */
  --bouncy: cubic-bezier(.18, 1.5, .4, 1);       /* celebration only */
  --glass: rgba(19, 26, 36, 0.72);
}

/* ---- bottom tab bar (thumb-zone IA) ---- */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: none; grid-template-columns: repeat(4, 1fr);
  gap: 2px; padding: 8px 10px calc(8px + env(safe-area-inset-bottom));
  background: var(--glass); backdrop-filter: blur(18px) saturate(1.3); -webkit-backdrop-filter: blur(18px) saturate(1.3);
  border-top: 1px solid rgba(255, 255, 255, .06);
}
body.has-tabbar .tabbar { display: grid; }
body.has-tabbar .wrap { padding-bottom: 96px; }
.tab {
  background: none; border: none; color: var(--muted-2); font-family: inherit; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 7px 0; border-radius: 12px;
  font-size: 10.5px; font-weight: 800; letter-spacing: .3px; transition: color .2s var(--snappy), transform .2s var(--snappy);
}
.tab .ti { font-size: 19px; line-height: 1; filter: grayscale(.4) opacity(.7); transition: filter .2s, transform .2s var(--snappy); }
.tab.active { color: var(--teal); }
.tab.active .ti { filter: none; transform: translateY(-1px) scale(1.08); }
.tab:active { transform: scale(.92); }

/* ---- bottom sheet ---- */
.sheet-scrim {
  position: fixed; inset: 0; z-index: 90; background: rgba(4, 6, 10, .6);
  backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px);
  display: none; align-items: flex-end; justify-content: center; opacity: 0; transition: opacity .25s var(--smooth);
}
.sheet-scrim.open { display: flex; opacity: 1; }
.sheet {
  width: 100%; max-width: 480px; max-height: 92vh; overflow: hidden;
  background: linear-gradient(180deg, var(--surface-2), var(--surface));
  border: 1px solid var(--line); border-bottom: none;
  border-radius: 24px 24px 0 0; box-shadow: 0 -20px 60px rgba(0, 0, 0, .55);
  transform: translateY(14px); opacity: .6; transition: transform .32s var(--bouncy), opacity .2s var(--smooth);
  display: flex; flex-direction: column;
}
.sheet-scrim.open .sheet { transform: translateY(0); opacity: 1; }
.sheet-handle { width: 40px; height: 4px; border-radius: 99px; background: var(--line); margin: 10px auto 2px; flex: 0 0 auto; }
.sheet-head { padding: 6px 18px 4px; display: flex; align-items: center; justify-content: space-between; flex: 0 0 auto; }
.sheet-head h2 { font-size: 18px; margin: 0; }
.sheet-x { background: var(--surface-3); border: 1px solid var(--line); color: var(--muted); width: 30px; height: 30px; border-radius: 50%; cursor: pointer; font-size: 15px; line-height: 1; }
.sheet-body { padding: 4px 18px 14px; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.sheet-foot {
  flex: 0 0 auto; padding: 12px 18px calc(14px + env(safe-area-inset-bottom));
  background: var(--glass); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid rgba(255, 255, 255, .05);
}
.sheet-foot .cta { margin-top: 0; }

/* ---- in-card emoji reactions ---- */
.reacts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; align-items: center; }
.react-chip {
  display: inline-flex; align-items: center; gap: 5px; background: var(--surface-2); border: 1px solid var(--line);
  border-radius: 999px; padding: 5px 11px; font-size: 14px; cursor: pointer; font-family: inherit; color: var(--text);
  transition: transform .15s var(--snappy), border-color .15s, background .15s;
}
.react-chip:active { transform: scale(.9); }
.react-chip.mine { border-color: var(--teal); background: rgba(20, 224, 200, .1); }
.react-chip .ct { font-size: 12px; font-weight: 800; color: var(--muted); }
.react-add { color: var(--muted-2); }
.react-pop { display: flex; gap: 4px; margin-top: 8px; }
.react-pop button { background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; font-size: 18px; padding: 6px 9px; cursor: pointer; transition: transform .12s var(--snappy); }
.react-pop button:active { transform: scale(.85); }

/* ---- odometer (rolling digits) ---- */
.odo { display: inline-flex; font-variant-numeric: tabular-nums; line-height: 1; }
.odo .col { overflow: hidden; height: 1em; }
.odo .col .strip { display: flex; flex-direction: column; will-change: transform; }
.odo .col .strip span { height: 1em; display: flex; align-items: center; justify-content: center; }

/* ---- league row reveal (scroll-driven where supported) ---- */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .lg-row { animation: rowIn linear both; animation-timeline: view(); animation-range: entry 0% entry 30%; }
    @keyframes rowIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
  }
}
.lg-row.climb { animation: climbFlash 1.1s var(--smooth); }
@keyframes climbFlash { 0%, 100% { background: transparent; } 30% { background: rgba(255, 200, 61, .14); } }

/* ---- live duel hero / glass card ---- */
.hero-duel {
  background: var(--aurora), linear-gradient(160deg, var(--surface-2), var(--surface));
  border: 1px solid rgba(124, 58, 237, .35);
}
.glass { background: var(--glass); backdrop-filter: blur(16px) saturate(1.2); -webkit-backdrop-filter: blur(16px) saturate(1.2); }

/* responsible-design net line */
.resp { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--muted); margin-top: 12px; justify-content: center; }
.resp b { color: var(--text); font-variant-numeric: tabular-nums; }
.checkrow { display: flex; align-items: center; gap: 12px; margin-top: 16px; padding: 13px 14px; border: 1.5px solid var(--line); border-radius: 14px; background: var(--surface-2); cursor: pointer; transition: border-color .2s, background .2s, box-shadow .2s; }
.checkrow:has(input:checked) { border-color: var(--teal); background: rgba(20,224,200,.10); box-shadow: 0 0 22px rgba(20,224,200,.14); }
.checkrow input { appearance: none; -webkit-appearance: none; width: 26px; height: 26px; flex: 0 0 auto; border: 2px solid var(--teal); border-radius: 8px; background: transparent; cursor: pointer; position: relative; transition: all .18s ease; }
.checkrow input:checked { background: var(--teal); box-shadow: 0 0 0 4px rgba(20,224,200,.22), 0 0 16px rgba(20,224,200,.55); }
.checkrow input:checked::after { content: ''; position: absolute; left: 8px; top: 3.5px; width: 6px; height: 12px; border: solid #06140f; border-width: 0 3px 3px 0; transform: rotate(45deg); }
.checkrow label { margin: 0; font-size: 13px; color: var(--muted); line-height: 1.45; cursor: pointer; }
.checkrow:has(input:checked) label { color: var(--text); }
