:root {
  --paper: #F5F3EE; --ink: #14202B; --ink-2: #22313F; --muted: #5B6470; --text-2: #3E4954; --line: #E2DED5; --line-2: #C9C3B7;
  --accent: #C2410C; --accent-dark: #9A3412; --accent-soft: #FDE7D9; --note: #FDF6EE; --note-line: #F3D9C2;
  --amber: #F59E0B; --ok: #14532D; --ok-soft: #E7F5EC; --urgent: #B42318; --on-dark: #CBD2D9;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 16px/1.5 Inter, system-ui, sans-serif; }
a { color: var(--accent); } a:hover { color: var(--accent-dark); }
button, input, select { font: inherit; }
button { cursor: pointer; }
h1, h2, h3, .display { font-family: Archivo, Inter, sans-serif; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.muted { color: var(--muted); }
.hidden { display: none !important; }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; }

/* header */
header.top { background: var(--ink); color: var(--paper); }
header.top .wrap { padding-top: 14px; padding-bottom: 14px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; }
.brand { display: flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; }
.brand b { font-family: Archivo, sans-serif; font-weight: 800; font-size: 22px; letter-spacing: -0.01em; display: block; line-height: 1.05; }
.brand small { font-size: 12px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--on-dark); }
nav.main { display: flex; flex-wrap: wrap; gap: 4px 20px; font-size: 15px; font-weight: 500; }
nav.main a { color: var(--paper); text-decoration: none; }
nav.main a:hover { text-decoration: underline; color: #fff; }
.clock { display: flex; align-items: center; gap: 10px; background: var(--ink-2); border-radius: 999px; padding: 8px 16px; }
.clock span { font-size: 14px; color: var(--on-dark); }
.clock strong { font-family: Archivo, sans-serif; font-size: 16px; font-variant-numeric: tabular-nums; color: #fff; }

/* hero */
.hero { display: flex; flex-wrap: wrap; gap: 32px; padding-top: 48px; padding-bottom: 32px; }
.hero .pitch { flex: 1 1 520px; min-width: 0; display: flex; flex-direction: column; justify-content: center; gap: 20px; }
.pill { align-self: flex-start; background: var(--accent-soft); color: var(--accent-dark); font-weight: 700; font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; padding: 6px 12px; border-radius: 999px; }
.hero h1 { margin: 0; font-weight: 800; font-size: clamp(36px, 6vw, 56px); line-height: 1.02; letter-spacing: -0.02em; }
.hero p { margin: 0; font-size: 19px; color: var(--text-2); max-width: 560px; }
.stats { display: flex; flex-wrap: wrap; gap: 12px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 14px 18px; display: flex; flex-direction: column; }
.stat b { font-family: Archivo, sans-serif; font-weight: 800; font-size: 26px; }
.stat span { font-size: 14px; color: var(--muted); }

.dark-card { flex: 1 1 360px; min-width: 0; background: var(--ink); color: var(--paper); border-radius: 18px; padding: 28px; display: flex; flex-direction: column; gap: 14px; }
.dark-card h2 { margin: 0; font-weight: 800; font-size: 26px; line-height: 1.1; }
.dark-card p { margin: 0; font-size: 15px; color: var(--on-dark); }
.dark-card label { font-size: 14px; font-weight: 600; }
.dark-card input[type=text], .dark-card input[type=email] { height: 48px; border-radius: 10px; border: 1px solid #3A4A59; background: #1C2A37; color: #fff; padding: 0 14px; width: 100%; }
.field { display: flex; flex-direction: column; gap: 6px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { height: 44px; padding: 0 16px; border-radius: 999px; font-weight: 600; font-size: 15px; background: #fff; color: var(--ink); border: 1px solid var(--line-2); }
.chip[aria-pressed=true] { background: var(--ink); color: #fff; border-color: var(--ink); }
.dark-card .chip { background: transparent; color: var(--paper); border-color: #3A4A59; font-size: 14px; padding: 0 14px; }
.dark-card .chip[aria-pressed=true] { background: var(--amber); color: var(--ink); border-color: var(--amber); }
.fine { font-size: 13px; color: #9AA5B1; }
.okbox { background: #1C2A37; border-radius: 12px; padding: 18px; display: flex; gap: 12px; align-items: flex-start; }

.btn { height: 52px; border: 0; border-radius: 12px; background: var(--accent); color: #fff; font-weight: 700; font-size: 17px; padding: 0 22px; display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }
.btn:hover { background: var(--accent-dark); color: #fff; }
.btn.small { height: 44px; font-size: 15px; border-radius: 10px; padding: 0 18px; }
.btn.ghost { background: #fff; color: var(--ink); border: 1px solid var(--line-2); }
.btn.ghost:hover { background: var(--paper); }
.btn.dark { background: var(--ink); }
.btn[disabled] { opacity: 0.55; cursor: not-allowed; }

/* how */
section h2.sec { margin: 0 0 16px; font-weight: 800; font-size: 28px; }
.how { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 16px; }
.card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 20px; display: flex; flex-direction: column; gap: 8px; }
.card .when { font-family: Archivo, sans-serif; font-weight: 800; font-size: 15px; color: var(--accent); }
.card strong { font-size: 18px; }
.card span { font-size: 15px; color: var(--muted); }

/* lots */
.lots-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.search { height: 44px; border: 1px solid var(--line-2); border-radius: 999px; padding: 0 16px; background: #fff; min-width: 220px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; }
.lot { background: #fff; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; display: flex; flex-direction: column; color: inherit; text-decoration: none; }
.lot:hover { border-color: var(--line-2); color: inherit; }
.lot .ph { position: relative; background: #fff; }
.lot img { width: 100%; aspect-ratio: 1 / 1; object-fit: contain; display: block; }
.cond { position: absolute; top: 10px; left: 10px; background: var(--ink); color: #fff; font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 999px; }
.tag-mine { position: absolute; top: 10px; right: 10px; font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; }
.tag-mine.leading, .tag-mine.won { background: var(--ok-soft); color: var(--ok); }
.tag-mine.outbid, .tag-mine.lost { background: var(--accent-soft); color: var(--accent-dark); }
.lot .body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 6px; flex-grow: 1; }
.lotno { font-size: 12px; font-weight: 600; color: var(--muted); letter-spacing: 0.04em; }
.lot h3 { margin: 0; font-family: Inter, sans-serif; font-size: 16px; font-weight: 600; line-height: 1.3; }
.lot .foot { margin-top: auto; display: flex; align-items: flex-end; justify-content: space-between; gap: 8px; }
.amt { font-family: Archivo, sans-serif; font-weight: 800; font-size: 26px; line-height: 1.1; }
.urgent { color: var(--urgent) !important; }
.empty { background: #fff; border: 1px dashed var(--line-2); border-radius: 16px; padding: 32px; text-align: center; color: var(--muted); }

/* lot page */
.back { align-self: flex-start; height: 44px; padding: 0 14px; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink); font-weight: 600; display: inline-flex; align-items: center; gap: 8px; margin: 24px 0 20px; text-decoration: none; }
.lotpage { display: flex; flex-wrap: wrap; gap: 32px; align-items: flex-start; padding-bottom: 56px; }
.gallery { flex: 1 1 460px; min-width: 0; background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 24px; }
.gallery .main { width: 100%; aspect-ratio: 1 / 1; object-fit: contain; display: block; }
.thumbs { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.thumbs button { border: 2px solid var(--line); border-radius: 10px; padding: 0; background: #fff; width: 72px; height: 72px; overflow: hidden; }
.thumbs button[aria-current=true] { border-color: var(--accent); }
.thumbs img { width: 100%; height: 100%; object-fit: contain; }
.info { flex: 1 1 420px; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.info h1 { margin: 0; font-weight: 800; font-size: clamp(26px, 4vw, 36px); line-height: 1.1; }
.bidbox { background: #fff; border: 2px solid var(--line); border-radius: 18px; padding: 22px; display: flex; flex-direction: column; gap: 16px; }
.bidbox.hot { border-color: var(--urgent); }
.bidbox .row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; }
.big { font-family: Archivo, sans-serif; font-weight: 800; font-size: 44px; line-height: 1; }
.timer { font-family: Archivo, sans-serif; font-weight: 700; font-size: 24px; font-variant-numeric: tabular-nums; }
.bar { height: 8px; border-radius: 999px; background: #EDE9E1; overflow: hidden; }
.bar i { display: block; height: 8px; background: var(--urgent); }
.quick { display: flex; flex-wrap: wrap; gap: 8px; }
.quick button { height: 48px; flex: 1 1 120px; border: 1px solid var(--accent); border-radius: 10px; background: #fff; color: var(--accent-dark); font-weight: 700; font-size: 16px; }
.quick button:hover { background: var(--note); }
.bidrow { display: flex; gap: 8px; }
.bidrow input { flex: 1 1 auto; min-width: 0; height: 52px; border: 1px solid var(--line-2); border-radius: 10px; padding: 0 14px; font-size: 18px; background: #fff; color: var(--ink); }
.status { border-radius: 10px; padding: 10px 14px; font-weight: 600; font-size: 15px; }
.status.ok { background: var(--ok-soft); color: var(--ok); }
.status.warn { background: var(--accent-soft); color: var(--accent-dark); }
.err { font-size: 14px; color: var(--accent-dark); font-weight: 600; }
.note { background: var(--note); border: 1px solid var(--note-line); border-radius: 14px; padding: 16px 18px; display: flex; gap: 12px; align-items: flex-start; font-size: 15px; color: var(--text-2); }
.hist div { display: flex; justify-content: space-between; border-bottom: 1px solid var(--line); padding: 8px 0; font-size: 15px; }

/* account + panels */
.panel { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 22px; display: flex; flex-direction: column; gap: 14px; }
.panel h2 { margin: 0; font-weight: 800; font-size: 22px; }
.panel input[type=text], .panel input[type=email], .panel input[type=tel], .panel input[type=number], .panel select { height: 48px; border-radius: 10px; border: 1px solid var(--line-2); padding: 0 14px; background: #fff; color: var(--ink); width: 100%; }
.page { padding-top: 32px; padding-bottom: 56px; display: flex; flex-direction: column; gap: 20px; }
.cols { display: flex; flex-wrap: wrap; gap: 20px; align-items: flex-start; }
.cols > * { flex: 1 1 360px; min-width: 0; }
.slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
.slots button { height: 56px; border: 1px solid var(--line-2); border-radius: 10px; background: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; font-weight: 600; }
.slots button small { font-weight: 400; color: var(--muted); font-size: 12px; }
.slots button[aria-pressed=true] { background: var(--ink); color: #fff; border-color: var(--ink); }
.slots button[aria-pressed=true] small { color: var(--on-dark); }
.slots button[disabled] { opacity: 0.45; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; color: var(--muted); font-weight: 600; padding: 8px 10px; border-bottom: 1px solid var(--line); }
td { padding: 9px 10px; border-bottom: 1px solid #EFEBE4; vertical-align: top; }
.scroll { overflow-x: auto; }
.badge { display: inline-block; font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: var(--paper); color: var(--text-2); white-space: nowrap; }
.badge.ready, .badge.live, .badge.paid, .badge.picked_up, .badge.sold { background: var(--ok-soft); color: var(--ok); }
.badge.held, .badge.unpaid, .badge.withdrawn { background: var(--accent-soft); color: var(--accent-dark); }
.right { text-align: right; }

/* console */
.console { display: flex; flex-wrap: wrap; min-height: calc(100vh - 70px); }
.console nav { flex: 1 1 220px; max-width: 100%; background: var(--ink); color: var(--on-dark); padding: 22px 18px; display: flex; flex-direction: column; gap: 6px; }
.console nav a { color: var(--on-dark); text-decoration: none; border-radius: 8px; padding: 10px 12px; }
.console nav a[aria-current=page] { background: var(--ink-2); color: #fff; font-weight: 600; }
.console main { flex: 999 1 560px; min-width: 0; padding: 28px 32px 40px; display: flex; flex-direction: column; gap: 22px; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; }
.kpi { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; display: flex; flex-direction: column; gap: 2px; }
.kpi b { font-family: Archivo, sans-serif; font-weight: 800; font-size: 30px; }
.kpi span { font-size: 13px; color: var(--muted); }
.formula { background: var(--ink); color: var(--paper); border-radius: 16px; padding: 20px 22px; display: flex; flex-direction: column; gap: 8px; }
.formula div { display: flex; justify-content: space-between; border-bottom: 1px solid #2F3F4E; padding-bottom: 6px; }

footer.bottom { background: var(--ink); color: var(--on-dark); }
footer.bottom .wrap { padding-top: 36px; padding-bottom: 36px; display: flex; flex-wrap: wrap; gap: 24px 48px; justify-content: space-between; }
footer.bottom div.col { display: flex; flex-direction: column; gap: 6px; flex: 1 1 240px; font-size: 15px; }
footer.bottom strong { color: #fff; }
footer.bottom a { color: var(--on-dark); }

@media (max-width: 640px) {
  .wrap { padding: 0 16px; }
  .console main { padding: 20px 16px 32px; }
  .bidrow { flex-direction: column; }
  .big { font-size: 36px; }
}
