/* MLB Pool: dark scoreboard theme, mobile first. */
:root {
  --bg: #0a0e16; --bg2: #0f1522; --card: #131a29; --card2: #182236; --line: #22304a; --line2: #2c3b5a;
  --ink: #f1f5fb; --muted: #8a97ad; --faint: #5d6a82;
  --accent: #38bdf8; --accent2: #22c55e; --gold: #f5b82e; --gold2: #ffd76a; --hot: #fb923c; --bad: #f87171; --good: #4ade80;
  --radius: 16px; --radius-sm: 10px;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --display: "Oswald", "Inter", -apple-system, sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg) radial-gradient(900px 500px at 50% -120px, rgba(56, 189, 248, 0.16), transparent 70%);
  color: var(--ink); font-family: var(--font); font-size: 15px; line-height: 1.45; -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
.wrap { max-width: 760px; margin: 0 auto; padding: 18px 14px 56px; }
svg.i { width: 16px; height: 16px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; vertical-align: -3px; }

/* Buttons */
button, .btn { font: inherit; font-weight: 600; border: 1px solid var(--line2); background: var(--card); color: var(--ink); border-radius: 999px; padding: 8px 14px; cursor: pointer; display: inline-flex; align-items: center; gap: 7px; transition: border-color .15s, background .15s, transform .05s; }
button:hover, .btn:hover { border-color: var(--accent); text-decoration: none; }
button:active { transform: translateY(1px); }
button.primary, .btn.primary { background: linear-gradient(135deg, var(--accent), #2563eb); border-color: transparent; color: #061018; }
button.danger { color: var(--bad); }
button:disabled { opacity: 0.55; cursor: default; }

/* Header / hero */
header.top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
header.top .brand { display: flex; align-items: center; gap: 10px; }
header.top .logo { width: 38px; height: 38px; border-radius: 12px; background: linear-gradient(135deg, var(--accent), #2563eb); display: grid; place-items: center; color: #061018; box-shadow: 0 8px 24px rgba(56,189,248,0.25); }
header.top h1 { margin: 0; font-family: var(--display); font-weight: 600; font-size: 24px; letter-spacing: 0.02em; text-transform: uppercase; line-height: 1.1; }
header.top .sub { color: var(--muted); font-size: 13px; }
.nav { display: flex; gap: 8px; align-items: center; }
.nav .btn { padding: 7px 12px; font-size: 13px; }

.hero { background: linear-gradient(180deg, var(--card2), var(--card)); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 16px 14px; margin-bottom: 14px; position: relative; overflow: hidden; }
.hero::after { content: ""; position: absolute; inset: auto -40px -60px auto; width: 220px; height: 220px; border-radius: 50%; background: radial-gradient(circle, rgba(245,184,46,0.18), transparent 70%); pointer-events: none; }
.hero .lead { font-family: var(--display); font-size: 22px; font-weight: 600; letter-spacing: 0.01em; line-height: 1.15; }
.hero .lead b { color: var(--gold2); }
.hero .lead .gap { color: var(--accent); }
.hero .stats { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 10px; color: var(--muted); font-size: 13px; }
.hero .stats b { color: var(--ink); font-weight: 600; }
.progress { margin-top: 12px; }
.progress .bar { height: 6px; border-radius: 999px; background: rgba(255,255,255,0.08); overflow: hidden; }
.progress .bar i { display: block; height: 100%; width: 0; border-radius: 999px; background: linear-gradient(90deg, var(--accent2), var(--accent)); transition: width .6s ease; }
.progress .labels { display: flex; justify-content: space-between; color: var(--faint); font-size: 11.5px; margin-top: 5px; text-transform: uppercase; letter-spacing: 0.06em; }

.meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; color: var(--muted); font-size: 12.5px; margin: 0 2px 10px; }

/* Messages */
.notice { border-left: 4px solid var(--hot); padding: 12px 14px; margin: 12px 0; background: var(--card); border-radius: var(--radius-sm); }
.notice.bad { border-left-color: var(--bad); }
.notice.good { border-left-color: var(--good); }
.notice b { display: block; margin-bottom: 2px; }
.notice .next { color: var(--muted); }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }

/* Leaderboard cards */
.board { display: flex; flex-direction: column; gap: 10px; }
.row-card { position: relative; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 14px 12px; display: grid; grid-template-columns: 44px 1fr auto; grid-template-areas: "rank who total" "bar bar bar" "picks picks picks" "chips chips chips"; column-gap: 12px; row-gap: 8px; animation: rise .35s ease both; }
.row-card:nth-child(n+2) { animation-delay: calc(var(--i, 0) * 40ms); }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.row-card.leader { border-color: rgba(245,184,46,0.55); background: linear-gradient(180deg, rgba(245,184,46,0.10), var(--card) 60%); box-shadow: 0 10px 30px rgba(245,184,46,0.10); }
.row-card.podium { border-color: var(--line2); }
.rank { grid-area: rank; width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-family: var(--display); font-size: 22px; font-weight: 600; background: rgba(255,255,255,0.05); color: var(--muted); }
.leader .rank { background: linear-gradient(135deg, var(--gold), #d98a06); color: #1a1200; box-shadow: 0 6px 18px rgba(245,184,46,0.35); }
.podium .rank { color: var(--ink); background: rgba(56,189,248,0.14); }
.who { grid-area: who; min-width: 0; align-self: center; }
.who .name { font-weight: 700; font-size: 17px; letter-spacing: -0.01em; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.who .move { font-size: 12px; font-weight: 600; display: inline-flex; align-items: center; gap: 3px; padding: 2px 8px; border-radius: 999px; background: rgba(255,255,255,0.06); color: var(--muted); }
.who .move.up { color: var(--good); background: rgba(74,222,128,0.12); }
.who .move.down { color: var(--bad); background: rgba(248,113,113,0.12); }
.who .behind { color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.leader .who .behind { color: var(--gold2); }
.total { grid-area: total; text-align: right; align-self: center; }
.total .n { font-family: var(--display); font-size: 34px; font-weight: 600; line-height: 1; letter-spacing: 0.01em; font-variant-numeric: tabular-nums; }
.leader .total .n { color: var(--gold2); }
.total .l { color: var(--faint); font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em; margin-top: 2px; }
.bar { grid-area: bar; height: 5px; border-radius: 999px; background: rgba(255,255,255,0.06); overflow: hidden; }
.bar i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--accent), var(--accent2)); width: var(--w, 0%); animation: grow .7s cubic-bezier(.2,.8,.2,1) both; }
@keyframes grow { from { width: 0; } }
.leader .bar i { background: linear-gradient(90deg, var(--gold), var(--gold2)); }
.picks { grid-area: picks; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pick { background: rgba(255,255,255,0.03); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 9px 10px; min-width: 0; }
.pick .role { color: var(--faint); font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.09em; display: flex; align-items: center; gap: 5px; }
.pick .pname { font-weight: 600; font-size: 14px; margin-top: 3px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.pick .team { color: var(--muted); font-size: 11.5px; font-weight: 600; letter-spacing: 0.04em; }
.pick .pts { font-family: var(--display); font-size: 22px; font-weight: 500; line-height: 1.1; margin-top: 4px; font-variant-numeric: tabular-nums; }
.pick .pts small { font-family: var(--font); font-size: 11px; color: var(--muted); margin-left: 5px; text-transform: uppercase; letter-spacing: 0.06em; }
.pick .detail { color: var(--muted); font-size: 12px; margin-top: 4px; line-height: 1.35; }
.tag { display: inline-flex; align-items: center; gap: 4px; font-size: 10.5px; font-weight: 600; padding: 2px 7px; border-radius: 999px; border: 1px solid var(--line2); color: var(--muted); text-transform: uppercase; letter-spacing: 0.05em; }
.tag.lock { color: var(--hot); border-color: rgba(251,146,60,0.5); }
.tag.miss { color: var(--bad); border-color: rgba(248,113,113,0.5); }
.tag.gold { color: var(--gold2); border-color: rgba(245,184,46,0.5); }
.chips { grid-area: chips; display: flex; gap: 8px; flex-wrap: wrap; }
.chip { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; padding: 5px 10px; border-radius: 999px; background: rgba(255,255,255,0.05); color: var(--muted); }
.chip b { color: var(--ink); font-variant-numeric: tabular-nums; }
.chip.hot { background: rgba(251,146,60,0.14); color: var(--hot); }
.chip.hot b { color: var(--hot); }
.chip.adj { background: rgba(56,189,248,0.10); }

/* Sections */
section.rules { margin-top: 18px; padding: 16px 18px; }
section.rules h2 { margin: 0 0 10px; font-family: var(--display); font-weight: 600; font-size: 18px; letter-spacing: 0.02em; text-transform: uppercase; }
section.rules ul, section.rules ol { margin: 0; padding-left: 20px; color: var(--muted); }
section.rules li { margin: 6px 0; }
section.rules li::marker { color: var(--accent); font-weight: 700; }
.winners { display: flex; flex-direction: column; gap: 8px; }
.winner { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--radius-sm); background: rgba(245,184,46,0.08); border: 1px solid rgba(245,184,46,0.25); }
.winner .yr { font-family: var(--display); font-size: 22px; color: var(--gold2); min-width: 56px; }
.winner .nm { font-weight: 700; }
.winner .sm { color: var(--muted); font-size: 12.5px; }
footer { margin-top: 22px; color: var(--faint); font-size: 12px; text-align: center; }

/* Admin */
.grid { display: grid; gap: 14px; grid-template-columns: 1fr; }
form.panel, .panel { padding: 16px 16px; }
form.panel h2, .panel h2 { margin: 0 0 12px; font-family: var(--display); font-weight: 600; font-size: 18px; letter-spacing: 0.02em; text-transform: uppercase; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
label { display: block; font-size: 12.5px; color: var(--muted); margin-bottom: 4px; }
input[type=text], input[type=number], input[type=date], input[type=search], textarea, select { font: inherit; width: 100%; padding: 9px 11px; border: 1px solid var(--line2); border-radius: var(--radius-sm); background: var(--bg2); color: var(--ink); }
input:focus, textarea:focus, select:focus { outline: 2px solid rgba(56,189,248,0.45); outline-offset: 1px; border-color: var(--accent); }
textarea { min-height: 160px; resize: vertical; }
.field { margin-bottom: 12px; position: relative; }
.picker .chosen { font-size: 12.5px; color: var(--good); margin-top: 4px; min-height: 16px; cursor: pointer; }
.picker .menu { position: absolute; z-index: 5; left: 0; right: 0; top: 100%; background: var(--card2); border: 1px solid var(--line2); border-radius: var(--radius-sm); box-shadow: 0 12px 30px rgba(0,0,0,0.45); max-height: 260px; overflow: auto; }
.picker .menu div { padding: 9px 11px; cursor: pointer; display: flex; justify-content: space-between; gap: 8px; }
.picker .menu div:hover, .picker .menu div.active { background: rgba(56,189,248,0.12); }
.picker .menu small { color: var(--muted); }
.actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 6px; }
table.admin { width: 100%; border-collapse: collapse; }
table.admin th, table.admin td { padding: 10px 8px; text-align: left; vertical-align: top; border-top: 1px solid var(--line); font-size: 14px; }
table.admin th { font-size: 11px; text-transform: uppercase; letter-spacing: 0.07em; color: var(--faint); border-top: 0; }
.slotbox .line { margin-bottom: 4px; }
.slotbox .muted { color: var(--muted); font-size: 12.5px; }
.swapform { display: flex; gap: 6px; align-items: center; margin-top: 6px; flex-wrap: wrap; }
.swapform input[type=date], .swapform input[type=number], .swapform input[type=text] { width: auto; padding: 6px 9px; }
.swapform button { padding: 6px 11px; font-size: 13px; }
.me { color: var(--muted); font-size: 13px; }
.adjlist { margin: 4px 0 0; padding-left: 16px; color: var(--muted); font-size: 12.5px; }
.adjlist button { padding: 0 8px; font-size: 11px; margin-left: 4px; }

@media (min-width: 640px) {
  .wrap { padding: 28px 20px 64px; }
  header.top h1 { font-size: 30px; }
  .hero { padding: 20px 22px 18px; }
  .hero .lead { font-size: 28px; }
  .row-card { grid-template-columns: 52px 1fr auto; grid-template-areas: "rank who total" "bar bar bar" "picks picks chips"; padding: 16px 18px 14px; }
  .picks { grid-template-columns: 1fr 1fr; }
  .chips { flex-direction: column; align-items: flex-end; justify-content: flex-start; }
  .rank { width: 52px; height: 52px; font-size: 26px; }
  .total .n { font-size: 40px; }
}
@media (max-width: 420px) {
  .picks { grid-template-columns: 1fr; }
  .row { grid-template-columns: 1fr; }
  header.top .sub { display: none; }
}
@media (prefers-reduced-motion: reduce) { .row-card, .bar i { animation: none; } .progress .bar i { transition: none; } }

/* Navigation */
#nav { display: none; gap: 6px; flex-wrap: wrap; margin: 0 0 14px; }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line2); color: var(--muted); font-weight: 600; font-size: 13px; background: var(--card); }
.pill:hover { color: var(--ink); border-color: var(--accent); text-decoration: none; }
.pill.active { color: #061018; background: linear-gradient(135deg, var(--accent), #2563eb); border-color: transparent; }
.tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; display: flex; justify-content: space-around; padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); background: rgba(10,14,22,0.92); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-top: 1px solid var(--line); }
.tab { display: flex; flex-direction: column; align-items: center; gap: 3px; flex: 1; padding: 6px 4px; border-radius: 12px; color: var(--muted); font-size: 11px; font-weight: 600; letter-spacing: 0.02em; }
.tab svg.i { width: 20px; height: 20px; }
.tab.active { color: var(--accent); background: rgba(56,189,248,0.10); }
.tab:hover { text-decoration: none; color: var(--ink); }
body.has-tabbar .wrap { padding-bottom: 92px; }
@media (min-width: 640px) {
  #nav { display: flex; }
  .tabbar { display: none; }
  body.has-tabbar .wrap { padding-bottom: 64px; }
}
.signin { color: var(--faint); }

/* Rosters */
.roster { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 14px 12px; margin-bottom: 10px; }
.roster .head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.roster .head .nm { font-weight: 700; font-size: 17px; }
.roster .head .tot { font-family: var(--display); font-size: 22px; color: var(--muted); }
.roster .slots { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.slot { background: rgba(255,255,255,0.03); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 9px 10px; }
.slot .role { color: var(--faint); font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.09em; display: flex; align-items: center; gap: 5px; margin-bottom: 4px; }
.slot .p { display: flex; justify-content: space-between; gap: 8px; padding: 4px 0; border-top: 1px dashed var(--line); font-size: 14px; }
.slot .p:first-of-type { border-top: 0; }
.slot .p .k { color: var(--faint); font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; min-width: 52px; }
.slot .p .v { flex: 1; font-weight: 600; }
.slot .p .v small { color: var(--muted); font-weight: 600; font-size: 11.5px; margin-left: 5px; }
.slot .p .v.out { color: var(--muted); text-decoration: line-through; font-weight: 500; }
.slot .p .n { font-family: var(--display); font-size: 16px; color: var(--muted); }
.slot .note { color: var(--hot); font-size: 12px; margin-top: 5px; display: flex; align-items: center; gap: 5px; }
table.players { width: 100%; border-collapse: collapse; font-size: 14px; }
table.players th, table.players td { padding: 8px 8px; border-top: 1px solid var(--line); text-align: left; }
table.players th { font-size: 11px; text-transform: uppercase; letter-spacing: 0.07em; color: var(--faint); border-top: 0; }
table.players td.n { text-align: right; font-family: var(--display); font-size: 16px; }
table.players tr.bk td { color: var(--muted); }

/* Seasons */
.season { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 12px; }
.season .head { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.season .yr { font-family: var(--display); font-size: 30px; color: var(--gold2); }
.season .champ { font-weight: 700; font-size: 16px; }
.season .sm { color: var(--muted); font-size: 12.5px; }
table.final { width: 100%; border-collapse: collapse; font-size: 14px; }
table.final td { padding: 7px 8px; border-top: 1px solid var(--line); }
table.final td.r { color: var(--faint); width: 32px; font-family: var(--display); }
table.final td.n { text-align: right; font-family: var(--display); font-size: 16px; }
table.final tr:first-child td { color: var(--gold2); }
@media (max-width: 420px) { .roster .slots { grid-template-columns: 1fr; } }

.logo svg.i { width: 22px; height: 22px; stroke-width: 1.9; }

/* Chart */
:root { --s1: #3987e5; --s2: #d95926; --s3: #199e70; --s4: #c98500; --s5: #d55181; --s6: #9085e9; --s-other: #3a4661; }
section.chart { margin: 0 0 14px; padding: 14px 14px 10px; }
.chart-head h2 { margin: 0; font-family: var(--display); font-weight: 600; font-size: 18px; letter-spacing: 0.02em; text-transform: uppercase; }
.chart-head .sub { color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.chart-wrap { position: relative; margin-top: 8px; }
#chart { display: block; width: 100%; height: auto; touch-action: pan-y; }
#chart .grid { stroke: rgba(255,255,255,0.07); stroke-width: 1; }
#chart .axis { fill: var(--faint); font-size: 11px; font-family: var(--font); }
#chart .line { fill: none; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
#chart .line.other { stroke: var(--s-other); stroke-width: 1.25; }
#chart .lbl { font-size: 11.5px; font-weight: 600; font-family: var(--font); fill: var(--ink); }
#chart .lbl.other { fill: var(--muted); font-weight: 500; }
#chart .cross { stroke: rgba(255,255,255,0.35); stroke-width: 1; stroke-dasharray: 3 3; }
#chart .dot { stroke: var(--card); stroke-width: 2; }
.tip { position: absolute; top: 8px; pointer-events: none; background: rgba(15,21,34,0.96); border: 1px solid var(--line2); border-radius: 10px; padding: 8px 10px; font-size: 12px; min-width: 150px; box-shadow: 0 10px 30px rgba(0,0,0,0.45); z-index: 3; }
.tip .d { color: var(--muted); margin-bottom: 4px; font-weight: 600; }
.tip .r { display: flex; justify-content: space-between; gap: 12px; padding: 1px 0; }
.tip .r i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 6px; vertical-align: 0; }
.tip .r b { font-variant-numeric: tabular-nums; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 12px; margin-top: 8px; font-size: 12px; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 14px; height: 3px; border-radius: 2px; display: inline-block; }

/* Compact standings rows */
.row-compact { position: relative; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px 9px; display: grid; grid-template-columns: 36px 1fr auto; column-gap: 10px; row-gap: 6px; grid-template-areas: "rank who total" "bar bar bar"; animation: rise .3s ease both; animation-delay: calc(var(--i, 0) * 30ms); }
.row-compact.leader { border-color: rgba(245,184,46,0.55); background: linear-gradient(180deg, rgba(245,184,46,0.10), var(--card) 70%); }
.row-compact .rank { grid-area: rank; width: 36px; height: 36px; border-radius: 10px; font-size: 18px; align-self: start; }
.row-compact .who { grid-area: who; }
.row-compact .who .name { font-size: 15.5px; gap: 6px; }
.row-compact .who .line2 { color: var(--muted); font-size: 12.5px; margin-top: 2px; display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: center; }
.row-compact .who .line2 b { color: var(--ink); font-weight: 600; font-variant-numeric: tabular-nums; }
.row-compact .who .line2 .hot { color: var(--hot); display: inline-flex; align-items: center; gap: 4px; }
.row-compact .who .line2 .adj { color: var(--accent); display: inline-flex; align-items: center; gap: 4px; }
.row-compact .total { grid-area: total; align-self: start; }
.row-compact .total .n { font-size: 28px; }
.row-compact .total .l { font-size: 10.5px; }
.row-compact .bar { grid-area: bar; height: 4px; }
.row-compact .tag { font-size: 9.5px; padding: 1px 6px; }
@media (min-width: 640px) { .row-compact .total .n { font-size: 30px; } .row-compact { padding: 11px 16px 10px; } }

.row-compact .who .line2 .odds { color: var(--ink); background: rgba(255,255,255,0.06); padding: 1px 7px; border-radius: 999px; font-weight: 600; font-size: 11.5px; }
.row-compact .who .line2 .odds.big { background: rgba(245,184,46,0.16); color: var(--gold2); }
.row-compact .who .line2 .odds.nil { color: var(--faint); background: transparent; padding: 0; font-weight: 500; }

.tag.il { color: #fff; background: var(--bad); border-color: var(--bad); }
.subnote { color: var(--bad); font-size: 12.5px; margin-top: 5px; display: flex; align-items: center; gap: 6px; }
a.plink { color: inherit; text-decoration: none; border-bottom: 1px dotted var(--faint); }
a.plink:hover { color: var(--accent); border-bottom-color: var(--accent); }
.il-name { color: var(--bad); }

/* Player page */
.player-head { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.player-head .num { font-family: var(--display); font-size: 40px; color: var(--muted); }
.player-head h1 { margin: 0; font-size: 26px; }
.player-head .sub { color: var(--muted); font-size: 13px; }
.status-line { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 13px; padding: 4px 10px; border-radius: 999px; background: rgba(74,222,128,0.12); color: var(--good); }
.status-line.il { background: rgba(248,113,113,0.14); color: var(--bad); }
.stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 12px 0; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.stat .v { font-family: var(--display); font-size: 26px; }
.stat .k { color: var(--faint); font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.08em; }
table.log { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.log th, table.log td { padding: 7px 8px; border-top: 1px solid var(--line); text-align: right; }
table.log th:first-child, table.log td:first-child, table.log th:nth-child(2), table.log td:nth-child(2) { text-align: left; }
table.log th { font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.07em; color: var(--faint); border-top: 0; }
table.log td.big { font-family: var(--display); font-size: 16px; }
.owners { color: var(--muted); font-size: 13px; margin: 6px 0 0; }
.links { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }

.pick3 { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.pick3 .player { grid-column: 1 / -1; }
.picker.locked select { opacity: 0.55; }

/* Range pills */
.chart-head { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: flex-start; justify-content: space-between; }
.pills { display: inline-flex; gap: 4px; background: rgba(255,255,255,0.05); border-radius: 999px; padding: 3px; }
.pills button { border: 0; background: transparent; color: var(--muted); padding: 5px 10px; font-size: 12px; border-radius: 999px; }
.pills button.active { background: var(--card2); color: var(--ink); border: 1px solid var(--line2); }

/* Tap-to-explain */
.tip-btn { font: inherit; cursor: pointer; }
button.tag { line-height: 1.3; }
.tip-btn.plain { border: 0; background: transparent; color: var(--muted); padding: 0; display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; }
.tip-btn.plain.hot { color: var(--hot); }
.tip-btn.odds { border: 0; }
.tip-btn.adj { border: 0; background: transparent; padding: 0; color: var(--accent); display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; }
.popover { position: absolute; z-index: 30; background: var(--card2); border: 1px solid var(--line2); border-radius: 12px; padding: 10px 12px; font-size: 13px; line-height: 1.45; color: var(--ink); box-shadow: 0 14px 40px rgba(0,0,0,0.5); animation: rise .15s ease both; }

/* Expandable rows */
.row-compact { cursor: pointer; grid-template-columns: 36px 1fr auto 28px; grid-template-areas: "rank who total expand" "bar bar bar bar" "detail detail detail detail"; }
.row-compact .expand { grid-area: expand; align-self: start; justify-self: end; width: 28px; height: 28px; padding: 0; border-radius: 8px; border: 1px solid var(--line); background: transparent; color: var(--muted); display: grid; place-items: center; transition: transform .2s; }
.row-compact.open .expand { transform: rotate(180deg); color: var(--ink); }
.row-compact .expand svg.i { width: 16px; height: 16px; }
.detail-panel { grid-area: detail; border-top: 1px solid var(--line); padding-top: 10px; margin-top: 2px; cursor: default; }
.dgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.dslot { background: rgba(255,255,255,0.03); border: 1px solid var(--line); border-radius: 10px; padding: 9px 10px; min-width: 0; }
.dslot .role { color: var(--faint); font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.09em; display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.dslot .who2 { margin-top: 4px; font-size: 15px; font-weight: 700; color: var(--ink); text-align: left; }
.dslot .who2 .team { color: var(--muted); font-size: 11.5px; font-weight: 600; margin-left: 5px; letter-spacing: 0.04em; }
.muted { color: var(--muted); }
.small { font-size: 12.5px; margin-top: 5px; line-height: 1.4; }
.glabel { color: var(--faint); font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.08em; margin-top: 8px; }
.games { display: flex; flex-direction: column; margin-top: 3px; }
.games .g { display: grid; grid-template-columns: 56px 1fr auto; gap: 8px; padding: 3px 0; border-top: 1px dashed var(--line); font-size: 13px; }
.games .g:first-child { border-top: 0; }
.games .g .d { color: var(--muted); }
.games .g .o { color: var(--muted); }
.games .g b { font-family: var(--display); font-size: 16px; font-variant-numeric: tabular-nums; }
.games .g b.zero { color: var(--faint); }
@media (max-width: 420px) { .dgrid { grid-template-columns: 1fr; } }

/* Player news cards */
.newsgrid { display: grid; grid-template-columns: 1fr; gap: 10px; }
a.news { display: grid; grid-template-columns: 112px 1fr; gap: 10px; background: rgba(255,255,255,0.03); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; color: inherit; text-decoration: none; }
a.news:hover { border-color: var(--accent); text-decoration: none; }
a.news img, a.news .noimg { width: 112px; height: 100%; min-height: 72px; object-fit: cover; display: block; background: var(--bg2); }
a.news .noimg { display: grid; place-items: center; color: var(--faint); }
a.news .nb { padding: 9px 10px 9px 0; min-width: 0; }
a.news .nd { color: var(--muted); font-size: 11.5px; }
a.news .nt { font-weight: 700; font-size: 14px; line-height: 1.3; margin-top: 2px; }
a.news .na { color: var(--faint); font-size: 11.5px; margin-top: 3px; }
@media (min-width: 640px) { .newsgrid { grid-template-columns: 1fr 1fr; } }
