
@font-face { font-family: "Sora"; font-weight: 600; font-display: swap; src: url("/assets/fonts/Sora-SemiBold.woff2") format("woff2"); }
@font-face { font-family: "Sora"; font-weight: 700; font-display: swap; src: url("/assets/fonts/Sora-Bold.woff2") format("woff2"); }
@font-face { font-family: "Sora"; font-weight: 800; font-display: swap; src: url("/assets/fonts/Sora-ExtraBold.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 400; font-display: swap; src: url("/assets/fonts/Inter-Regular.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 500; font-display: swap; src: url("/assets/fonts/Inter-Medium.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 600; font-display: swap; src: url("/assets/fonts/Inter-SemiBold.woff2") format("woff2"); }

:root {
  --bg: #0B0D12; --surface: #151923; --surface-2: #1F2634; --surface-3: #1A1F2B; --bar: #0F1219;
  --border: #2A3140; --border-strong: #3A4356;
  --text: #F4F6FA; --body: #C5CBD8; --muted: #9AA3B5; --faint: #7E879A;
  --gold: #E3B65A; --glint: #F7DC94; --gold-tint: rgba(227, 182, 90, 0.1);
  --blue: #5AA9FF; --blue-tint: rgba(90, 169, 255, 0.14); --warn: #D9A066;
  --sora: "Sora", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --inter: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --wrap: 1160px; --gutter: 16px; --cut: 8px;
  color-scheme: dark;
}
@media (min-width: 640px) { :root { --gutter: 24px; } }
@media (min-width: 1024px) { :root { --gutter: 32px; } }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; display: flex; flex-direction: column; background: var(--bg); color: var(--text);
  font: 400 15px/1.55 var(--inter); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
main { flex: 1; }
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
img { display: block; max-width: 100%; }
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.chamfer { clip-path: polygon(var(--cut) 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%, 0 var(--cut)); }

/* Top bar */
.bar { background: var(--bar); border-bottom: 1px solid var(--border); }
.bar-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 60px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font: 800 15px/1 var(--sora);
  letter-spacing: 0.04em; text-transform: uppercase; }
.brand:hover { text-decoration: none; }
.bar-note { color: var(--muted); font: 600 11px/1.2 var(--sora); letter-spacing: 0.12em; text-transform: uppercase; }

/* Page head */
.head { padding: 28px 0 8px; }
.eyebrow { display: flex; align-items: center; gap: 8px; margin: 0 0 6px; color: var(--gold);
  font: 700 11px/1.3 var(--sora); letter-spacing: 0.16em; text-transform: uppercase; }
.eyebrow::before { content: ""; width: 7px; height: 7px; background: var(--gold); flex: none; }
h1 { margin: 0; font: 800 clamp(26px, 6vw, 40px)/1.08 var(--sora); letter-spacing: 0.01em; text-transform: uppercase;
  overflow-wrap: anywhere; }
.lede { margin: 8px 0 0; color: var(--muted); max-width: 60ch; }

/* Totals panel */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); margin: 20px 0 6px;
  background: var(--surface); border: 1px solid var(--border); }
.stat { padding: 14px 16px; border-left: 2px solid var(--gold); margin: 10px 0 10px 12px; }
.stat b { display: block; font: 800 clamp(22px, 5vw, 30px)/1.1 var(--sora); font-variant-numeric: tabular-nums; }
.stat span { display: block; margin-top: 4px; color: var(--muted); font: 700 10px/1.2 var(--sora); letter-spacing: 0.14em;
  text-transform: uppercase; }
.asof { margin: 6px 0 0; color: var(--faint); font-size: 12px; }
.head .local { margin: -4px 0 10px; color: var(--muted); font-size: 15px; }
.stat small { font-size: 0.55em; color: var(--muted); font-weight: 700; }
.dexbar { display: block; width: 100%; height: 6px; margin-top: 8px; }

/* Game chips */
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 18px 0 4px; padding: 0; list-style: none; }
.chips a { display: inline-block; padding: 8px 12px; background: var(--surface); border: 1px solid var(--border);
  color: var(--muted); font: 700 11px/1 var(--sora); letter-spacing: 0.1em; text-transform: uppercase; }
.chips a:hover { text-decoration: none; color: var(--text); border-color: var(--border-strong); }
.chips a[aria-current="true"] { background: var(--gold); border-color: var(--gold); color: var(--bg); }

/* Card grid */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin: 18px 0 28px;
  padding: 0; list-style: none; }
@media (min-width: 640px) { .grid { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 16px; } }
.tile { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--border); min-width: 0; }
.art { aspect-ratio: 63 / 88; background: var(--surface-3); display: grid; place-items: center; overflow: hidden; }
.art img { width: 100%; height: 100%; object-fit: contain; }
.art .ph { color: var(--faint); font: 700 10px/1.2 var(--sora); letter-spacing: 0.12em; text-transform: uppercase; padding: 8px;
  text-align: center; }
.meta { padding: 10px 10px 12px; display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.name { margin: 0; font: 600 13px/1.3 var(--inter); color: var(--text); overflow-wrap: anywhere; }
.set { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.35; overflow-wrap: anywhere; }
.tags { display: flex; flex-wrap: wrap; gap: 4px; margin: 4px 0 0; padding: 0; list-style: none; }
.tags li { padding: 2px 6px; background: var(--surface-2); color: var(--body); font: 700 9.5px/1.4 var(--sora);
  letter-spacing: 0.08em; text-transform: uppercase; }
.tags li.foil { background: var(--gold-tint); color: var(--gold); }
.tags li.qty { background: transparent; color: var(--text); padding-left: 0; }
.price { margin: auto 0 0; padding-top: 6px; font: 700 14px/1.2 var(--sora); font-variant-numeric: tabular-nums; }
.price .lbl { margin-right: 6px; color: var(--muted); font: 700 9.5px/1 var(--sora); letter-spacing: 0.1em; text-transform: uppercase; }
.price.none { color: var(--faint); font: 500 12px/1.3 var(--inter); }
.manual { margin-left: 4px; padding: 1px 5px; border: 1px solid var(--border-strong); color: var(--muted);
  font: 700 9px/1.3 var(--sora); letter-spacing: 0.08em; text-transform: uppercase; vertical-align: 2px; }
.ask { margin: 2px 0 0; color: var(--blue); font: 700 12px/1.3 var(--sora); letter-spacing: 0.02em; }
.trade { margin: 0; color: var(--blue); font: 700 9.5px/1.4 var(--sora); letter-spacing: 0.1em; text-transform: uppercase; }
.note { margin: 2px 0 0; color: var(--body); font-size: 12px; line-height: 1.4; overflow-wrap: anywhere; }

/* Pager, notices, footer */
.pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 32px; color: var(--muted);
  font: 600 12px/1 var(--sora); letter-spacing: 0.08em; text-transform: uppercase; }
.pager a { padding: 10px 14px; background: var(--surface); border: 1px solid var(--border); }
.notice { margin: 48px 0; padding: 28px 22px; background: var(--surface); border: 1px solid var(--border); max-width: 620px; }
.notice h1 { font-size: clamp(22px, 5vw, 30px); }
.notice p { color: var(--muted); margin: 10px 0 0; }
.empty { margin: 32px 0; color: var(--muted); }
.button { display: inline-block; margin-top: 18px; padding: 13px 20px; background: var(--gold); color: var(--bg);
  font: 800 12px/1 var(--sora); letter-spacing: 0.12em; text-transform: uppercase; }
.button:hover { text-decoration: none; background: var(--glint); }
.foot { margin-top: 24px; padding: 24px 0 32px; border-top: 1px solid var(--border); background: var(--bar); color: var(--muted);
  font-size: 13px; }
.foot p { margin: 0 0 6px; }
.foot .fine { color: var(--faint); font-size: 12px; }

/* Signed-in website (/app) */
.tabs { display: flex; gap: 4px; margin-right: auto; margin-left: 16px; }
.tabs a { padding: 8px 10px; color: var(--muted); font: 700 11px/1 var(--sora); letter-spacing: 0.12em; text-transform: uppercase; }
.tabs a:hover { color: var(--text); text-decoration: none; }
.tabs a[aria-current="page"] { color: var(--gold); box-shadow: inset 0 -2px 0 var(--gold); }
.signout button { background: none; border: 0; padding: 8px 0; color: var(--blue); cursor: pointer; font: 700 11px/1 var(--sora);
  letter-spacing: 0.12em; text-transform: uppercase; }
@media (max-width: 520px) { .brand span { display: none; } .tabs { margin-left: 4px; } }
.banner { background: var(--gold-tint); border-bottom: 1px solid var(--border); color: var(--body); font-size: 13px; padding: 10px 0; }
.signins { display: flex; flex-direction: column; gap: 10px; margin: 22px 0 6px; max-width: 320px; }
.signin { display: flex; align-items: center; justify-content: center; gap: 8px; height: 48px; padding: 0 18px; border-radius: 6px;
  font: 600 16px/1 -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif; }
.signin:hover { text-decoration: none; opacity: 0.92; }
.signin.apple { background: #FFFFFF; color: #000000; }
.signin.google { background: #FFFFFF; color: #1F1F1F; border: 1px solid #747775; font-family: Roboto, Arial, sans-serif; font-weight: 500; }
.notice .fine { color: var(--faint); font-size: 12px; margin-top: 16px; }
.error { color: var(--warn); margin: 12px 0 0; }
.saved { margin: 0 0 12px; padding: 10px 14px; background: var(--gold-tint); color: var(--gold); font-size: 13px; }

.filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; margin: 14px 0 4px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 120px; }
.field.grow { flex: 1 1 220px; }
.field span, fieldset legend { color: var(--muted); font: 700 9.5px/1 var(--sora); letter-spacing: 0.14em; text-transform: uppercase; }
.field input, .field select { height: 42px; padding: 0 12px; background: var(--surface); border: 1px solid var(--border); color: var(--text);
  font: 400 15px/1 var(--inter); border-radius: 0; -webkit-appearance: none; appearance: none; width: 100%; }
.field select { background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 16px) 18px, calc(100% - 11px) 18px; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 30px; }
.field input:focus, .field select:focus { outline: 2px solid var(--blue); outline-offset: -1px; }
.check { display: inline-flex; align-items: center; gap: 8px; min-height: 42px; color: var(--body); font-size: 14px; cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--gold); }
.btn { height: 42px; padding: 0 20px; background: var(--gold); color: var(--bg); border: 0; cursor: pointer;
  font: 800 11px/1 var(--sora); letter-spacing: 0.14em; text-transform: uppercase;
  clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px); }
.btn:hover { background: var(--glint); }
.btn.danger { background: #E5484D; color: var(--bg); }
.tile.linked { position: relative; }
.tile.linked:hover { border-color: var(--border-strong); }
a.name { color: var(--text); }
a.name::after { content: ""; position: absolute; inset: 0; }

.back { margin: 20px 0 12px; font: 700 11px/1 var(--sora); letter-spacing: 0.12em; text-transform: uppercase; }
.detail { display: grid; gap: 24px; margin-bottom: 32px; }
@media (min-width: 760px) { .detail { grid-template-columns: minmax(240px, 360px) 1fr; gap: 36px; } }
.detail-art { aspect-ratio: 63 / 88; background: var(--surface-3); display: grid; place-items: center; max-width: 360px; }
.detail-art img { width: 100%; height: 100%; object-fit: contain; }
.detail-body h1 { margin-bottom: 14px; }
.pricebox { background: var(--surface); border: 1px solid var(--border); border-left: 2px solid var(--gold); padding: 14px 16px; margin: 0 0 16px; }
.pricebox .label { display: block; color: var(--gold); font: 700 10px/1 var(--sora); letter-spacing: 0.14em; text-transform: uppercase; margin-bottom: 8px; }
.pricebox b { font: 800 30px/1.1 var(--sora); font-variant-numeric: tabular-nums; }
.pricebox b.none { font: 500 15px/1.3 var(--inter); color: var(--faint); }
.pricebox .out { display: inline-block; margin-top: 10px; font: 700 11px/1 var(--sora); letter-spacing: 0.1em; text-transform: uppercase; }
.facts { margin: 0 0 20px; display: grid; }
.facts div { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; text-align: right; color: var(--text); overflow-wrap: anywhere; }
.edit { display: flex; flex-direction: column; gap: 12px; padding: 18px 0 0; border-top: 1px solid var(--border); }
.edit h2 { margin: 0; font: 800 14px/1 var(--sora); letter-spacing: 0.12em; text-transform: uppercase; }
.edit .row { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; }
.edit fieldset { border: 1px dashed var(--border); padding: 10px 12px 12px; margin: 0; }
.edit fieldset legend { padding: 0 4px; }
.edit .btn { align-self: flex-start; margin-top: 4px; }
.hint { margin: 0; color: var(--faint); font-size: 12px; }
details.delete { margin-top: 18px; color: var(--muted); }
details.delete summary { cursor: pointer; color: #E5484D; font: 700 11px/1 var(--sora); letter-spacing: 0.12em; text-transform: uppercase; padding: 8px 0; }
details.delete p { font-size: 13px; }

.btn.small { height: 34px; padding: 0 10px; font-size: 9.5px; letter-spacing: 0.1em; flex: 1 1 auto; white-space: nowrap; }
.btn.ghost { background: var(--surface-2); color: var(--blue); }
.btn.ghost:hover { background: var(--surface-3); }
.addform { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }
.addbtns { display: flex; flex-wrap: wrap; gap: 6px; }
.field.compact { min-width: 0; gap: 4px; }
.field.compact select { height: 34px; font-size: 13px; padding-right: 26px; background-position: calc(100% - 14px) 14px, calc(100% - 9px) 14px; }
.section-head { margin: 26px 0 0; display: flex; align-items: center; gap: 8px; color: var(--gold); font: 800 13px/1 var(--sora);
  letter-spacing: 0.14em; text-transform: uppercase; }
.section-head::before { content: ""; width: 7px; height: 7px; background: var(--gold); }
.results .grid { margin-top: 12px; }
.more { margin: -12px 0 8px; font: 700 11px/1 var(--sora); letter-spacing: 0.12em; text-transform: uppercase; }
.tile.result .price { margin-top: 6px; }

/* Binders and progress */
.tabs { overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { white-space: nowrap; }
.rows { list-style: none; padding: 0; margin: 18px 0 28px; display: grid; gap: 8px; }
.rowlink { display: flex; align-items: center; gap: 16px; padding: 14px 16px; background: var(--surface); border: 1px solid var(--border); color: var(--text); }
.rowlink:hover { text-decoration: none; border-color: var(--border-strong); }
.rowmain { display: flex; flex-direction: column; gap: 3px; flex: 1; min-width: 0; }
.rowmain .eyebrow { margin: 0; font-size: 9.5px; }
.rowmain b { font: 600 15px/1.3 var(--inter); overflow-wrap: anywhere; }
.rowsub { color: var(--muted); font-size: 12px; }
.rowlink .meter { width: 120px; flex: none; }
.meter { -webkit-appearance: none; appearance: none; display: block; width: 100%; height: 6px; margin-top: 8px; border: 0; background: var(--surface-2); }
.meter::-webkit-progress-bar { background: var(--surface-2); }
.meter::-webkit-progress-value { background: var(--gold); }
.meter::-moz-progress-bar { background: var(--gold); }
.chips.small a { padding: 6px 9px; font-size: 10px; }
.modes { display: flex; flex-wrap: wrap; gap: 14px; margin: 10px 0 0; font: 700 11px/1 var(--sora); letter-spacing: 0.1em; text-transform: uppercase; }
.modes a { color: var(--muted); padding: 6px 0; }
.modes a[aria-current="true"] { color: var(--gold); box-shadow: inset 0 -2px 0 var(--gold); }
.dexgrid { list-style: none; padding: 0; margin: 14px 0 32px; display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 8px; }
.slot { display: flex; flex-direction: column; gap: 4px; font-size: 11px; color: var(--faint); min-width: 0; }
.slot a { display: flex; flex-direction: column; gap: 4px; color: var(--body); }
.slot a:hover { text-decoration: none; }
.slot img, .slot .hole { aspect-ratio: 63 / 88; width: 100%; object-fit: contain; background: var(--surface-3); }
.slot .hole { display: grid; place-items: center; border: 1px dashed var(--border); color: var(--faint); font: 700 13px/1 var(--sora); }
.slot span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.slot.have b { color: var(--gold); }
.bpages { display: grid; gap: 18px; margin: 18px 0 24px; }
@media (min-width: 900px) { .bpages { grid-template-columns: 1fr 1fr; } }
.bpage { background: var(--bar); border: 1px solid var(--border); padding: 10px; }
.pageno { margin: 0 0 8px; color: var(--faint); font: 700 9.5px/1 var(--sora); letter-spacing: 0.14em; text-transform: uppercase; }
.pockets { display: grid; gap: 6px; align-items: start; }
.cols-1 .pockets { grid-template-columns: repeat(1, 1fr); } .cols-2 .pockets { grid-template-columns: repeat(2, 1fr); }
.cols-3 .pockets { grid-template-columns: repeat(3, 1fr); } .cols-4 .pockets { grid-template-columns: repeat(4, 1fr); }
.cols-5 .pockets { grid-template-columns: repeat(5, 1fr); } .cols-6 .pockets { grid-template-columns: repeat(6, 1fr); }
.pocket { position: relative; display: block; width: 100%; aspect-ratio: 63 / 88; background: var(--surface-3); border: 1px solid var(--border); overflow: hidden; min-width: 0; }
.slab .pocket { aspect-ratio: 79 / 135; }
.pocket.filled img { width: 100%; height: 100%; object-fit: contain; }
.pocket.open { display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 3px; padding: 6px; text-align: center;
  border-style: dashed; color: var(--faint); font-size: 10.5px; line-height: 1.25; }
.pocket.open b { color: var(--muted); font: 700 12px/1.1 var(--sora); }
.pocket.open span { overflow-wrap: anywhere; }
.pocket.open .pr { color: var(--muted); font-size: 9.5px; }
.pocket.gone { opacity: 0.45; }
.pocket.blank { border-style: dashed; }
.flag { margin-top: 2px; padding: 1px 5px; background: var(--surface-2); color: var(--muted); font: 700 8.5px/1.4 var(--sora); letter-spacing: 0.08em; text-transform: uppercase; }
.flag.chasing { background: var(--blue-tint); color: var(--blue); }
.qtybadge { position: absolute; right: 4px; bottom: 4px; padding: 1px 5px; background: rgba(11, 13, 18, 0.85); color: var(--text); font: 700 10px/1.4 var(--sora); }
.entry .art { position: relative; }
.entry:not(.owned) .art img { opacity: 0.38; filter: grayscale(0.6); }
.entry.owned { border-color: rgba(227, 182, 90, 0.45); }
.chase { position: absolute; top: 6px; left: 6px; padding: 2px 6px; background: var(--gold); color: var(--bg); font: 800 9px/1.3 var(--sora); letter-spacing: 0.1em; text-transform: uppercase; }
.tags li.gone { text-decoration: line-through; color: var(--faint); }
.tags li.extra { border: 1px dashed var(--border); background: transparent; }
.tags li:has(> button) { padding: 0; background: none; }
.tags button { padding: 2px 6px; border: 1px solid var(--blue); background: transparent; color: var(--blue); cursor: pointer;
  font: 700 9.5px/1.4 var(--sora); letter-spacing: 0.08em; text-transform: uppercase; text-align: left; }
.tags button:hover { background: var(--surface-2); }
.tags button.gone { border-color: var(--border); color: var(--faint); text-decoration: line-through; }
.markchase { margin-top: 6px; width: 100%; min-height: 32px; border: 1px solid var(--gold); background: transparent; color: var(--gold);
  cursor: pointer; font: 800 9.5px/1.2 var(--sora); letter-spacing: 0.1em; text-transform: uppercase; }
.markchase.on { background: var(--gold); color: var(--bg); }
.marking { margin: 0 0 18px; padding: 16px; background: var(--surface); border: 1px solid var(--border); }
.marking p { margin: 0 0 10px; color: var(--body); font-size: 13px; line-height: 1.5; }
.marking .over { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0 0 10px; }
.marking .over label { color: var(--muted); font-size: 12px; }
.marking .over input { width: 110px; height: 34px; padding: 0 10px; background: var(--bg); color: var(--text); border: 1px solid var(--border); font: 13px var(--inter); }
.marking .over .btn.small { flex: 0 0 auto; }
.marking .flash { color: var(--gold); }
.marking .done { font: 700 11px/1 var(--sora); letter-spacing: 0.1em; text-transform: uppercase; }

/* Market movers */
.tile.mover .price { margin-top: 6px; }
.change { margin: 3px 0 0; font: 700 12px/1.2 var(--sora); font-variant-numeric: tabular-nums; }
.change.up { color: var(--gold); }
.change.down { color: var(--muted); }
.was { margin: 3px 0 0; color: var(--faint); font-size: 11.5px; font-variant-numeric: tabular-nums; }
.notice h2 { margin: 0; font: 800 clamp(20px, 4.5vw, 26px)/1.1 var(--sora); text-transform: uppercase; }
