/* Career Tracker - the MDT look (gold on near-black, serif italic accents, gold pill buttons),
   with the club's own colour (--club, set from the career) glowing behind the hero. */
:root {
  --bg: #0b0a09; --surface: #151411; --surface2: #1d1b17; --line: rgba(255,236,190,.09); --line2: rgba(255,236,190,.17);
  --ink: #f5f0e6; --ink2: #bdb5a5; --ink3: #8a8375;
  --gold: #dba63c; --gold2: #f8e3a8; --gold-deep: #9a6f22;
  --gold-grad: linear-gradient(120deg, #f8e3a8 0%, #dba63c 45%, #9a6f22 100%);
  --green: #3fd06e; --red: #ff6b6b; --silver: #c9ced6;
  --goals: #b98521; --assists: #4a8fd6;   /* the chart pair: checked for colour-blind separation on --surface */
  --club: #3fd06e;
  --r: 20px; --page: 1180px;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.5 var(--sans); overflow-x: hidden;
  background-image: radial-gradient(1100px 520px at 80% -12%, rgba(219,166,60,.12), transparent 60%); background-attachment: fixed; }
body.locked { overflow: hidden; }
button { font: inherit; color: inherit; cursor: pointer; }
a { color: var(--gold2); }
:focus-visible { outline: 2px solid var(--gold2); outline-offset: 3px; }
em { font-family: var(--serif); font-style: italic; font-weight: 500; }
.boot { text-align: center; color: var(--ink3); padding: 80px 16px; }
.muted { color: var(--ink2); } .small { font-size: 13px; } .center { text-align: center; }
#buildTag { position: fixed; right: 6px; bottom: 4px; font-size: 10px; color: #ffffff40; pointer-events: none; z-index: 5; }
.ic { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid var(--line2); background: var(--surface2); color: var(--ink); border-radius: 999px; padding: 11px 18px; font-weight: 700; font-size: 14.5px; min-height: 44px; text-decoration: none; }
.btn.primary { background: var(--gold-grad); color: #1a1206; border-color: transparent; box-shadow: 0 10px 26px -12px rgba(219,166,60,.75); }
.btn.ghost { background: transparent; }
.btn.danger { background: transparent; color: var(--red); border-color: rgba(255,107,107,.35); margin-right: auto; }
.btn.block { width: 100%; }
.btn:disabled { opacity: .6; cursor: default; }
.linkbtn { display: inline-flex; align-items: center; gap: 5px; background: none; border: 0; color: var(--gold2); font-weight: 700; font-size: 13.5px; padding: 6px 4px; min-height: 36px; }
.linkbtn .ic { width: 15px; height: 15px; }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 14px 0; }
.row.center { justify-content: center; }
.spin { width: 16px; height: 16px; border: 2.5px solid rgba(26,18,6,.3); border-top-color: #1a1206; border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* hero */
.hero { position: relative; padding: 26px 16px 18px; overflow: hidden; }
.hero::before { content: ''; position: absolute; inset: -40% -10% auto; height: 420px; background: radial-gradient(closest-side, color-mix(in srgb, var(--club) 34%, transparent), transparent); opacity: .55; pointer-events: none; }
.hero-in { position: relative; max-width: var(--page); margin: 0 auto; }
.hero-id { display: flex; align-items: center; gap: 14px; }
.hero-id > div { flex: 1; min-width: 0; }
.crest { flex: none; filter: drop-shadow(0 10px 18px rgba(0,0,0,.6)); }
.hero h1 { font: 800 clamp(28px, 7vw, 46px)/1.02 var(--sans); letter-spacing: -.03em; margin: 0; overflow-wrap: anywhere; }
.hero-sub { margin: 6px 0 0; color: var(--ink2); font-weight: 600; font-size: 14px; }
.hero-sub i { color: var(--ink3); font-style: normal; margin: 0 2px; }
.paste-btn { flex: none; }
/* tabs */
.tabs { position: sticky; top: var(--mdts-h, 0); z-index: 20; background: rgba(11,10,9,.92); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.tabrow { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; padding: 0 10px; max-width: var(--page); margin: 0 auto; }
.tabrow::-webkit-scrollbar { display: none; }
.tabrow button { flex: none; background: none; border: 0; padding: 13px 10px 11px; font-weight: 700; font-size: 14.5px; color: var(--ink2); border-bottom: 3px solid transparent; white-space: nowrap; }
.tabrow button.on { color: var(--gold2); border-bottom-color: var(--gold); }

.page { max-width: var(--page); margin: 0 auto; padding: 14px 16px 60px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; margin: 0 0 14px; }
.card h2 { font: 800 19px/1.2 var(--sans); letter-spacing: -.01em; margin: 0 0 10px; }
.sec-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.sec-h h2 { margin: 0; }
.kind { font-size: 12px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--gold); margin: 22px 2px 10px; }
/* the overview: two columns on a wide screen, one in reading order on a phone */
.ov { display: flex; flex-direction: column; }
.ov .col { display: contents; }
.o1 { order: 1; } .o2 { order: 2; } .o3 { order: 3; } .o4 { order: 4; } .o5 { order: 5; } .o6 { order: 6; }
@media (min-width: 900px) {
  .ov { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; align-items: start; }
  .ov .col { display: block; }
}

/* the cups */
.cup { width: 34px; height: 40px; fill: none; stroke: var(--ink3); stroke-width: 1.8; flex: none; }
.cup path, .cup circle { fill: rgba(255,255,255,.03); stroke-linejoin: round; }
.cup.on path, .cup.on circle { fill: #dba63c; stroke: #f8e3a8; }
.cup.on .cut { fill: #6b4b12; stroke: none; }
.cup .cut { fill: none; stroke: var(--ink3); }
/* lists of results */
.list { display: flex; flex-direction: column; gap: 6px; }
.li { display: flex; align-items: center; gap: 10px; width: 100%; background: var(--surface2); border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px; text-align: left; min-height: 48px; }
.li:hover { border-color: var(--line2); }
.li.cur { border-color: var(--gold); }
.li-n { font-weight: 700; min-width: 0; }
.opp { flex: 1; min-width: 0; color: var(--ink2); font-size: 13.5px; text-align: right; }
.opp .sc { color: var(--ink); font-variant-numeric: tabular-nums; }
.opp small { color: var(--ink3); }
.ga { color: var(--ink2); font-size: 12.5px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.li .opp + .res, .li .ga + .res { margin-left: 0; }
.li > .li-n + .res { margin-left: auto; }
.li > .li-n + .muted { flex: 1; }
@media (max-width: 520px) {
  .li { flex-wrap: wrap; row-gap: 2px; }
  .li .li-n { flex: 1; }
  .li .opp { order: 3; flex-basis: 100%; text-align: left; }
  .li .ga { order: 2; }
}
.res { flex: none; display: inline-flex; align-items: center; gap: 5px; border-radius: 999px; padding: 4px 10px; font-size: 12.5px; font-weight: 800; white-space: nowrap; border: 1px solid transparent; }
.res.won { background: var(--gold-grad); color: #1a1206; }
.res.final { background: rgba(201,206,214,.14); color: var(--silver); border-color: rgba(201,206,214,.3); }
.res.lost { background: rgba(255,107,107,.1); color: #ff9b9b; border-color: rgba(255,107,107,.25); }
.res.placed { background: rgba(255,255,255,.06); color: var(--ink); border-color: var(--line2); }
.res.pend { background: transparent; color: var(--ink3); border: 1px dashed var(--line2); }
.unb { display: inline-grid; place-items: center; width: 17px; height: 17px; border-radius: 50%; background: #1a1206; color: var(--gold2); font-size: 10px; }
.res:not(.won) .unb { background: var(--gold); color: #1a1206; }
.addrow { display: flex; align-items: center; gap: 6px; width: 100%; margin-top: 8px; background: none; border: 1px dashed var(--line2); border-radius: 14px; padding: 9px 12px; color: var(--ink2); font-weight: 700; font-size: 13.5px; }
.addrow .ic { width: 15px; height: 15px; }

/* chart */
.legend { display: flex; gap: 16px; font-size: 13px; color: var(--ink2); font-weight: 600; margin: 0 0 6px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 12px; height: 12px; border-radius: 3px; }
.legend .kg { background: var(--goals); } .legend .ka { background: var(--assists); }
.chart-wrap { overflow-x: auto; scrollbar-width: thin; }
.chart { display: block; width: 100%; height: auto; }
.chart .gl { stroke: rgba(255,236,190,.08); stroke-width: 1; }
.chart .ax { fill: var(--ink3); font: 600 11px var(--sans); }
.chart .ax.s { fill: var(--ink2); font-size: 12px; }
.chart .vl { fill: var(--ink); font: 700 11.5px var(--sans); }
.chart .bg { fill: var(--goals); } .chart .ba { fill: var(--assists); }
.chart .hit { fill: transparent; }
.chart .gp:hover .hit, .chart .gp:focus .hit { fill: rgba(255,255,255,.04); }
.chart .gp:focus { outline: none; }
#tip { position: fixed; z-index: 60; background: #24221d; border: 1px solid var(--line2); color: var(--ink); font-size: 13px; font-weight: 600; padding: 7px 10px; border-radius: 10px; pointer-events: none; max-width: 260px; box-shadow: 0 10px 30px rgba(0,0,0,.5); }

/* seasons */
.season h2 em { font-size: 24px; }
.season-ga { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: flex-end; font-size: 13px; color: var(--ink2); }
.season-ga b { color: var(--ink); font-size: 16px; }
.won-row { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 10px; }
.wonpill { display: inline-flex; align-items: center; gap: 6px; background: rgba(219,166,60,.12); border: 1px solid rgba(219,166,60,.35); color: var(--gold2); border-radius: 999px; padding: 3px 10px 3px 4px; font-size: 12.5px; font-weight: 800; }
.wonpill .cup { width: 18px; height: 22px; }

/* competitions */
.comps { display: grid; grid-template-columns: 1fr; gap: 0 14px; }
@media (min-width: 900px) { .comps { grid-template-columns: 1fr 1fr; } }
.comp-h { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.comp-h > div { flex: 1; }
.comp-h h2 { margin: 0; }
.comp-h p { margin: 0; }
.comp.has { border-color: rgba(219,166,60,.25); }

/* records */
.recs { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.recs.mini { grid-template-columns: 1fr; }
.rec { display: block; width: 100%; text-align: left; background: var(--surface2); border: 1px solid var(--line); border-radius: 16px; padding: 14px; }
.rec.beaten { border-color: rgba(219,166,60,.45); background: linear-gradient(160deg, rgba(219,166,60,.16), var(--surface2) 60%); }
.rec-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.rec-big { display: flex; align-items: baseline; gap: 4px; flex-wrap: wrap; }
.rec-big b { font: 800 34px/1 var(--sans); letter-spacing: -.03em; }
.rec-big small { color: var(--ink2); font-weight: 700; font-size: 13px; margin-right: 4px; }
.rec-big i { font-family: var(--serif); color: var(--ink3); margin: 0 4px; }
.badge { flex: none; background: var(--gold-grad); color: #1a1206; border-radius: 999px; padding: 3px 10px; font-size: 12px; font-weight: 800; }
.rec-l { font-weight: 700; margin-top: 6px; }
.rec-h { color: var(--ink2); font-size: 13px; }
.rec-new { margin-top: 8px; color: var(--gold2); font-size: 14px; }
.rbar { margin-top: 10px; }
.rbar-t { display: flex; justify-content: space-between; gap: 8px; font-size: 12.5px; color: var(--ink2); margin-bottom: 5px; }
.rbar-t b { color: var(--ink); }
.rbar-t small { color: var(--ink3); }
.track { height: 8px; border-radius: 99px; background: rgba(255,255,255,.07); overflow: hidden; }
.fill { height: 100%; border-radius: 99px; background: linear-gradient(90deg, #6b4b12, var(--gold)); }
.fill.done { background: var(--gold-grad); }

/* notes */
.notes { margin: 0; padding-left: 18px; color: var(--ink2); }
.notes li { margin: 3px 0; }

/* empty / auth */
.empty { text-align: center; padding: 30px 18px; }
.empty h2 { font-size: 24px; }
.empty p { max-width: 560px; margin: 0 auto 6px; color: var(--ink2); }
.empty-cups { display: flex; justify-content: center; gap: 10px; margin-bottom: 10px; }
.empty-cups .cup { width: 46px; height: 56px; }
.auth { max-width: 480px; margin: 0 auto; padding: 30px 16px 60px; text-align: center; }
.auth .ttl { font: 800 clamp(30px, 8vw, 44px)/1.05 var(--sans); letter-spacing: -.03em; margin: 6px 0 10px; }
.lede { color: var(--ink2); margin: 0 auto 18px; }
.auth-card { text-align: left; }
.auth-card h2 { margin-bottom: 4px; }
.err { color: #ff9b9b; background: rgba(255,107,107,.1); border-radius: 10px; padding: 8px 10px; font-size: 14px; }
.lbl { display: block; font-size: 13px; font-weight: 700; color: var(--ink2); margin: 12px 0 5px; }
.auth-card .btn { margin-top: 12px; }
.or { display: flex; align-items: center; gap: 10px; color: var(--ink3); font-size: 13px; margin: 12px 0 0; }
.or::before, .or::after { content: ''; flex: 1; height: 1px; background: var(--line2); }

/* forms */
.inp, .ta { width: 100%; background: var(--bg); border: 1px solid var(--line2); color: var(--ink); border-radius: 12px; padding: 11px 12px; font: 16px/1.35 var(--sans); }
.ta { resize: vertical; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 14.5px; line-height: 1.5; min-height: 200px; }
.inp:focus, .ta:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(219,166,60,.2); }
select.inp { appearance: none; -webkit-appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--ink2) 50%), linear-gradient(135deg, var(--ink2) 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 32px; }
.fld { display: block; margin: 0 0 12px; }
.fld > span { display: block; font-size: 13px; font-weight: 700; color: var(--ink2); margin-bottom: 5px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 10px; }
.chk { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; font-weight: 600; min-height: 32px; }
.chk input { width: 20px; height: 20px; accent-color: var(--gold); }
.seg { display: flex; flex-wrap: wrap; gap: 6px; }
.seg button { border: 1px solid var(--line2); background: var(--bg); border-radius: 999px; padding: 8px 14px; font-weight: 700; font-size: 14px; color: var(--ink2); min-height: 40px; }
.seg button.on { background: var(--gold-grad); color: #1a1206; border-color: transparent; }
.pick { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.chip { border: 1px solid var(--line2); background: var(--surface2); color: var(--ink); border-radius: 999px; padding: 8px 14px; font-size: 14px; font-weight: 700; min-height: 40px; }

/* paste + preview */
.paste h2 { font-size: 22px; }
.preview { border-color: rgba(219,166,60,.35); }
.by { display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; padding: 4px 10px; font-size: 12.5px; font-weight: 800; background: var(--surface2); border: 1px solid var(--line2); color: var(--ink2); white-space: nowrap; }
.by.ai { background: var(--gold-grad); color: #1a1206; border-color: transparent; }
.by .ic { width: 15px; height: 15px; }
.pv-sum { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 10px 0; }
.pv-sum span { background: var(--surface2); border: 1px solid var(--line); border-radius: 14px; padding: 8px; text-align: center; font-size: 12px; color: var(--ink2); font-weight: 600; line-height: 1.2; }
.pv-sum b { display: block; font-size: 22px; color: var(--ink); }
.pv-sum .warn b { color: #ffb36b; }
@media (max-width: 420px) { .pv-sum { grid-template-columns: 1fr 1fr; } }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 12px; }
.tag { background: var(--surface2); border: 1px solid var(--line2); border-radius: 999px; padding: 4px 11px; font-size: 13px; color: var(--ink2); }
.tag b { color: var(--ink); }
.pv-comps { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 8px; }
.pv-comp { background: var(--surface2); border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px; }
.pv-comp small { color: var(--ink3); }
.pv-e { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 6px; }
.pv-chip { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--ink2); background: var(--bg); border: 1px solid var(--line); border-radius: 999px; padding: 2px 4px 2px 9px; }
.pv-chip > i { font-style: normal; color: var(--ink); font-weight: 700; }
.pv-chip .res { padding: 2px 8px; font-size: 11.5px; }
.pv-recs { display: flex; flex-direction: column; gap: 6px; }
.pv-recs div { background: var(--surface2); border: 1px solid var(--line); border-radius: 12px; padding: 8px 12px; font-size: 14px; }
.pv-recs span { color: var(--ink2); }
.pv-recs em { color: var(--gold2); font-family: var(--sans); font-style: normal; font-weight: 700; }
.lines { margin: 14px 0 0; }
.lines summary { cursor: pointer; font-weight: 700; color: var(--gold2); padding: 6px 0; }
.ln { display: flex; flex-direction: column; gap: 3px; margin-top: 6px; }
.ln-r { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; align-items: baseline; font-size: 12.5px; padding: 4px 8px; border-radius: 8px; background: var(--surface2); }
.ln-r code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; color: var(--ink); white-space: pre-wrap; overflow-wrap: anywhere; }
.ln-r span { color: var(--ink2); }
.ln-r.unplaced span { color: #ffb36b; }
.ln-r.won span { color: var(--gold2); }
.ln-r.head { background: transparent; }
.ln-r.head code { font-weight: 800; }
@media (max-width: 520px) { .ln-r { grid-template-columns: 1fr; gap: 0; } }
.mode { display: grid; gap: 8px; margin: 16px 0 4px; }
.mode label { display: flex; gap: 10px; align-items: flex-start; background: var(--surface2); border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px; cursor: pointer; }
.mode input { margin-top: 3px; width: 18px; height: 18px; accent-color: var(--gold); }
.mode b { display: block; }
.mode small { display: block; color: var(--ink2); font-size: 12.5px; }
@media (min-width: 640px) { .mode { grid-template-columns: 1fr 1fr; } }

/* sheets */
.sheet-bg { position: fixed; inset: 0; background: rgba(0,0,0,.6); z-index: 400; }
.sheet { position: fixed; z-index: 401; left: 50%; transform: translateX(-50%); bottom: 0; width: min(560px, 100%); max-height: calc(100dvh - var(--mdts-h, 0px) - 12px); display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line2); border-bottom: 0; border-radius: 22px 22px 0 0; box-shadow: 0 -20px 60px rgba(0,0,0,.6); }
@media (min-width: 700px) { .sheet { bottom: auto; top: 50%; transform: translate(-50%, -50%); border-radius: 22px; border-bottom: 1px solid var(--line2); max-height: min(86dvh, 760px); } }
.sh-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px 6px; }
.sh-head h2 { margin: 0; font-size: 19px; }
.x { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line2); background: var(--surface2); font-size: 22px; line-height: 1; color: var(--ink2); }
.sh-body { padding: 8px 16px 12px; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.sh-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); }

#toast { position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); transform: translate(-50%, 20px); background: #24221d; border: 1px solid var(--line2); color: var(--ink); padding: 10px 16px; border-radius: 999px; font-weight: 700; font-size: 14px; opacity: 0; pointer-events: none; transition: .25s; z-index: 500; max-width: calc(100% - 32px); text-align: center; }
#toast.on { opacity: 1; transform: translate(-50%, 0); }

/* 1.1: insights, the career grid, record rings, confetti */
.insights { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 12px; }
.ins { display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; padding: 6px 12px; font-size: 13px; font-weight: 700; background: rgba(21,20,17,.82); border: 1px solid var(--line2); color: var(--ink); }
.ins.gold { background: linear-gradient(120deg, rgba(248,227,168,.22), rgba(219,166,60,.12)); border-color: rgba(219,166,60,.5); color: var(--gold2); }
.ins.hot { border-color: rgba(255,140,60,.55); color: #ffb47a; background: rgba(255,120,40,.1); }
.ins.hot::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: #ff8c3c; box-shadow: 0 0 0 0 rgba(255,140,60,.7); animation: pulse 1.6s infinite; }
.ins.chase { color: var(--ink2); border-style: dashed; }
@keyframes pulse { 70% { box-shadow: 0 0 0 8px rgba(255,140,60,0); } 100% { box-shadow: 0 0 0 0 rgba(255,140,60,0); } }

.rings { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 12px; }
.ring { position: relative; display: grid; grid-template-columns: 72px auto; grid-template-rows: auto auto; column-gap: 12px; align-items: center; }
.ring svg { grid-row: 1 / 3; width: 72px; height: 72px; transform: rotate(-90deg); }
.ring .rt { fill: none; stroke: rgba(255,255,255,.08); stroke-width: 7; }
.ring .rf { fill: none; stroke: var(--gold); stroke-width: 7; stroke-linecap: round; transition: stroke-dasharray .9s cubic-bezier(.2,.8,.2,1); }
.ring.hot .rf { stroke: #ff9d4d; }
.ring.done .rf { stroke: var(--gold2); filter: drop-shadow(0 0 6px rgba(248,227,168,.8)); }
.ring > b { position: absolute; left: 0; top: 0; width: 72px; height: 72px; display: grid; place-items: center; font: 800 20px var(--sans); padding-bottom: 8px; }
.ring > small { position: absolute; left: 0; top: 40px; width: 72px; text-align: center; font-size: 10.5px; color: var(--ink3); font-weight: 700; }
.ring > span { grid-column: 2; grid-row: 1 / 3; font-size: 13.5px; color: var(--ink2); font-weight: 600; }
.ring > span em { font: 800 22px var(--sans); color: var(--ink); font-style: normal; display: block; line-height: 1; }
.ring.hot > span em { color: #ffb47a; }
.rec.beaten { box-shadow: 0 0 0 1px rgba(219,166,60,.3), 0 14px 40px -18px rgba(219,166,60,.7); }

.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 900; overflow: hidden; }
.confetti i { position: absolute; top: -20px; border-radius: 2px; animation: fall linear forwards; }
@keyframes fall { to { transform: translate(var(--dx), 110vh) rotate(var(--r)); opacity: .9; } }

/* 1.2: the careers bar */
.cbar { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: -6px 0 14px; padding-bottom: 2px; }
.cbar::-webkit-scrollbar { display: none; }
.cpill { flex: none; display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; border: 1px solid var(--line2); background: rgba(21,20,17,.75); padding: 5px 12px 5px 6px; font-size: 13px; font-weight: 700; color: var(--ink2); min-height: 34px; white-space: nowrap; }
.cpill .crest { filter: none; }
.cpill.on { color: var(--ink); border-color: var(--gold); background: rgba(219,166,60,.14); }
.cpill.add { color: var(--gold2); border-style: dashed; padding-left: 10px; }
.cpill.manage { padding: 5px 9px; }
.cpill .ic { width: 15px; height: 15px; }

/* 1.3: the career report. One look throughout: thin rules not boxes, small caps labels,
   tabular numbers, gold only for what was won. */
@media (max-width: 560px) { .hero-id { flex-wrap: wrap; } .paste-btn { width: 100%; } }
.band { display: grid; grid-template-columns: repeat(6, 1fr); margin-top: 18px; border-top: 1px solid var(--line2); border-bottom: 1px solid var(--line2); }
.band > div { padding: 12px 6px 10px; text-align: center; border-left: 1px solid var(--line); }
.band > div:first-child { border-left: 0; }
.band b { display: block; font: 800 clamp(24px, 5.6vw, 38px)/1 var(--sans); letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.band b small { font-size: .5em; color: var(--ink3); }
.band b span { font: inherit; color: inherit; letter-spacing: inherit; display: inline; margin: 0; text-transform: none; }
.band .gold b { background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.band span { display: block; margin-top: 5px; font-size: 10.5px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--ink3); }
@media (max-width: 560px) { .band { grid-template-columns: repeat(3, 1fr); } .band > div:nth-child(4) { border-left: 0; } .band > div:nth-child(n+4) { border-top: 1px solid var(--line); } }

.report { display: flex; flex-direction: column; gap: 14px; }
.rep { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px 16px 14px; min-width: 0; }
.rep-h { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 12px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.rep-h h2 { margin: 0; font: 800 12px var(--sans); letter-spacing: .18em; text-transform: uppercase; color: var(--gold); }
.rep-k { font-size: 12px; color: var(--ink3); text-align: right; }
.two { display: grid; gap: 14px; }
@media (min-width: 900px) { .two { grid-template-columns: 1fr 1.25fr; align-items: start; } }

/* the season table */
.tbl-wrap { overflow-x: auto; margin: 0 -16px; padding: 0 16px; scrollbar-width: thin; }
.stbl { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; min-width: 520px; }
.stbl th, .stbl td { padding: 0; height: 52px; text-align: center; border-bottom: 1px solid var(--line); }
.stbl thead th { height: 34px; font-size: 10.5px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--ink3); white-space: nowrap; padding: 0 4px; }
.stbl tbody th, .stbl tfoot th, .stbl thead th:first-child { position: sticky; left: 0; z-index: 1; background: var(--surface); text-align: left; padding: 0 12px 0 0; white-space: nowrap; }
.stbl tbody th b { font-size: 15px; font-weight: 800; }
.sw { display: inline-flex; align-items: center; gap: 1px; margin-left: 6px; color: var(--gold2); font-size: 11.5px; font-weight: 800; vertical-align: 1px; }
.sw i .cup { width: 11px; height: 13px; }
.rc { min-width: 58px; cursor: pointer; }
.rc.none { cursor: default; }
.rc span { display: inline-flex; align-items: center; justify-content: center; gap: 3px; min-width: 40px; height: 28px; padding: 0 8px; border-radius: 8px; font-size: 12.5px; font-weight: 800; color: var(--ink3); }
.rc.won span.w { background: var(--gold-grad); color: #1a1206; box-shadow: 0 6px 16px -8px rgba(219,166,60,.9); }
.rc.won .cup { width: 13px; height: 15px; }
.rc.won .cup path, .rc.won .cup circle { fill: #1a1206; stroke: #1a1206; }
.rc.ru span { background: linear-gradient(120deg, #eef1f5, #9aa2ad); color: #16181c; }
.rc.out.sf span { color: #e0b48c; background: rgba(217,166,121,.12); }
.rc.out span { background: rgba(255,255,255,.04); }
.rc.pend span { color: var(--ink3); background: none; border: 1px dashed var(--line2); }
.rc.lg { position: relative; }
.rc.lg b { display: block; font-size: 15px; font-weight: 800; line-height: 1.1; }
.rc.lg small { display: block; font-size: 11px; color: var(--ink3); font-weight: 600; }
.rc.lg.won b { background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.ub { position: absolute; top: 6px; right: 4px; width: 15px; height: 15px; border-radius: 50%; background: var(--gold); color: #1a1206; font: 800 9px/15px var(--sans); font-style: normal; }
.rc:not(.none):hover { background: rgba(255,255,255,.03); }
.stbl .num { min-width: 44px; padding: 0 6px; font-size: 15px; color: var(--ink2); font-weight: 600; }
.stbl .num.ga b { color: var(--ink); font-weight: 800; }
.stbl thead .num { color: var(--ink3); }
.stbl tfoot th, .stbl tfoot td { border-bottom: 0; border-top: 2px solid var(--line2); height: 50px; }
.stbl tfoot th { font-size: 11px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--ink3); }
.stbl tfoot .num b { color: var(--ink); font-size: 16px; }
.stbl tfoot .rc span { color: var(--ink3); background: none; }
.stbl tfoot .rc.won span.w { background: var(--gold-grad); color: #1a1206; }

/* honours */
.hon { list-style: none; margin: 0; padding: 0; }
.hon li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.hon li:last-child { border-bottom: 0; }
.h-ic .cup { width: 30px; height: 36px; }
.h-n { flex: 1; min-width: 0; }
.h-n b { display: block; font-size: 15.5px; }
.h-n small { display: block; color: var(--ink2); font-size: 13px; font-variant-numeric: tabular-nums; }
.h-x { font: 800 22px var(--sans); letter-spacing: -.02em; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.sub { margin: 14px 0 2px; font-size: 10.5px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--ink3); }
.hon.ru li { padding: 7px 0; }
.hon.ru b { font-size: 14px; color: var(--ink2); }
.still { margin: 14px 0 0; padding-top: 12px; border-top: 1px solid var(--line); font-size: 13px; color: var(--ink3); line-height: 1.9; }
.still > span { display: block; font-size: 10.5px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.still i { margin: 0 6px; font-style: normal; }
.linkish { background: none; border: 0; padding: 0; color: var(--ink2); font-weight: 600; font-size: 13px; text-decoration: underline; text-decoration-color: var(--line2); text-underline-offset: 3px; }

/* the records ledger */
.ledger { list-style: none; margin: 0; padding: 0; }
.ledger li { display: grid; grid-template-columns: 1fr auto auto; grid-template-areas: "what mark you" "bar bar tag"; column-gap: 14px; row-gap: 8px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.ledger li:last-child { border-bottom: 0; }
.l-what { grid-area: what; min-width: 0; }
.l-what b { display: block; font-size: 14.5px; line-height: 1.25; }
.l-what small { color: var(--ink3); font-size: 12.5px; }
.l-mark, .l-you { text-align: right; font-variant-numeric: tabular-nums; }
.l-mark { grid-area: mark; } .l-you { grid-area: you; min-width: 52px; }
.l-mark span, .l-you span { display: block; font-size: 9.5px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--ink3); }
.l-mark b, .l-you b { font: 800 18px var(--sans); white-space: nowrap; }
.l-mark small { font-size: 11px; color: var(--ink3); font-weight: 700; margin-left: 2px; }
.l-mark b { color: var(--ink2); }
.l-bar { grid-area: bar; height: 5px; border-radius: 9px; background: rgba(255,255,255,.07); overflow: hidden; }
.l-bar i { display: block; height: 100%; border-radius: 9px; background: linear-gradient(90deg, #6b4b12, var(--gold)); }
.l-tag { grid-area: tag; font-size: 11.5px; font-weight: 800; color: var(--gold2); white-space: nowrap; text-align: right; }
.l-tag.dim { color: var(--ink3); }
.ledger li.close .l-tag { color: #ffb47a; }
.ledger li.close .l-bar i { background: linear-gradient(90deg, #7a3d12, #ff9d4d); }
.ledger li.broken .l-you b { background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.ledger li.broken .l-bar i { background: var(--gold-grad); }

/* career bests */
.bests { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.bests > div { padding: 4px 14px 2px; border-left: 1px solid var(--line); }
.bests > div:first-child { border-left: 0; padding-left: 0; }
.bests b { display: block; font: 800 30px/1.05 var(--sans); letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.bests span { display: block; font-size: 13px; font-weight: 700; margin-top: 4px; }
.bests small { display: block; font-size: 12px; color: var(--ink3); }
@media (max-width: 560px) { .bests { grid-template-columns: 1fr 1fr; row-gap: 14px; } .bests > div:nth-child(odd) { border-left: 0; padding-left: 0; } }
/* the insight pills, quieter: they sit under the stat band */
.insights { margin-top: 12px; }
.ins { background: transparent; }

.stbl th.ga, .stbl td.ga { border-right: 1px solid var(--line2); padding-right: 10px; }
.rep .chart-wrap { max-width: 760px; }
.rc.lg .ub { right: auto; left: calc(50% + 14px); top: 5px; }
@media (max-width: 560px) { .rep-k { display: none; } .stbl { min-width: 0; } .rc { min-width: 54px; } }
