/* FF VAULT — vault-plate UI. Black + brushed silver from the logo, ember red for actions, FF gold for likes. */
:root {
  --bg: #000;
  --plate: #101216;
  --plate-2: #161920;
  --plate-3: #1d2129;
  --line: #252932;
  --line-2: #353a45;
  --text: #e8eaee;
  --muted: #9ba2ae;
  --faint: #6d7480;
  --ember: #e3262e;
  --ember-2: #ff3d44;
  --ember-dim: rgba(227, 38, 46, .14);
  --gold: #f5b301;
  --gold-dim: rgba(245, 179, 1, .11);
  --ok: #2fbf71;
  --ok-dim: rgba(47, 191, 113, .12);
  --warn: #f59e0b;
  --warn-dim: rgba(245, 158, 11, .11);
  --bad: #ef4444;
  --bad-dim: rgba(239, 68, 68, .12);
  --info: #5aa9ff;
  --info-dim: rgba(90, 169, 255, .11);
  --cut: 14px;
  --display: "Chakra Petch", "Rajdhani", "Segoe UI", system-ui, sans-serif;
  --body: "Hanken Grotesk", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --wrap: 1160px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 80px; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 400 16px/1.55 var(--body); -webkit-font-smoothing: antialiased;
  padding-bottom: calc(66px + env(safe-area-inset-bottom));
}
@media (min-width: 900px) { body { padding-bottom: 0; } }
a { color: inherit; }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { font-family: var(--display); line-height: 1.12; margin: 0 0 .45em; font-weight: 700; letter-spacing: .005em; }
h1 { font-size: clamp(1.8rem, 5.4vw, 2.6rem); }
h2 { font-size: clamp(1.35rem, 3.6vw, 1.7rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 .8em; }
small, .small { font-size: .875rem; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.gold { color: var(--gold); }
.ok-t { color: var(--ok); }
.bad-t { color: var(--bad); }
.num { font-family: var(--display); font-variant-numeric: tabular-nums; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .92em; }
.nowrap { white-space: nowrap; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }
@media (min-width: 760px) { .wrap { padding: 0 24px; } }
.ic { flex: none; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
::selection { background: var(--ember); color: #fff; }
hr { border: 0; border-top: 1px solid var(--line); margin: 20px 0; }

/* ── vault plate: chamfered panel with a 1px rim ── */
.plate {
  position: relative; isolation: isolate; background: var(--line); padding: 1px;
  clip-path: polygon(var(--cut) 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%, 0 var(--cut));
}
.plate::before {
  content: ""; position: absolute; inset: 1px; z-index: -1; background: var(--plate);
  clip-path: polygon(calc(var(--cut) - .6px) 0, 100% 0, 100% calc(100% - var(--cut) + .6px), calc(100% - var(--cut) + .6px) 100%, 0 100%, 0 calc(var(--cut) - .6px));
}
.plate.pad > .in, .plate > .in { padding: 18px; }
@media (min-width: 760px) { .plate > .in { padding: 22px; } }
.plate.raised::before { background: var(--plate-2); }
a.plate, .plate.click { text-decoration: none; transition: background .15s; }
a.plate:hover, .plate.click:hover { background: #4a505d; }

/* ── buttons ── */
.btn {
  --c: var(--ember);
  display: inline-flex; align-items: center; justify-content: center; gap: .5em; min-height: 46px; padding: 0 20px;
  font: 600 1rem/1 var(--display); letter-spacing: .02em; color: #fff; background: var(--c); border: 0; cursor: pointer;
  text-decoration: none; white-space: nowrap; transition: filter .15s, transform .06s;
  clip-path: polygon(9px 0, 100% 0, 100% calc(100% - 9px), calc(100% - 9px) 100%, 0 100%, 0 9px);
}
.btn:hover { filter: brightness(1.13); }
.btn:active { transform: translateY(1px); }
.btn:focus-visible { outline: none; box-shadow: inset 0 0 0 2px #fff, inset 0 0 0 4px var(--gold); }
.btn[disabled], .btn.is-busy { opacity: .55; cursor: not-allowed; filter: none; }
.btn-gold { --c: var(--gold); color: #191200; }
.btn-ok { --c: #1f9d5c; }
.btn-dark { --c: var(--plate-3); color: var(--text); }
.btn-ghost { background: transparent; color: var(--text); box-shadow: inset 0 0 0 1px var(--line-2); }
.btn-ghost:hover { box-shadow: inset 0 0 0 1px var(--muted); filter: none; }
.btn-line-gold { background: transparent; color: var(--gold); box-shadow: inset 0 0 0 1px rgba(245,179,1,.55); }
.btn-sm { min-height: 36px; padding: 0 14px; font-size: .9rem; clip-path: polygon(7px 0, 100% 0, 100% calc(100% - 7px), calc(100% - 7px) 100%, 0 100%, 0 7px); }
.btn-xs { min-height: 30px; padding: 0 10px; font-size: .82rem; clip-path: none; }
.btn-block { width: 100%; }
.btn-link { background: none; border: 0; padding: 0; color: var(--gold); font: inherit; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.row.end { justify-content: flex-end; }
.row.between { justify-content: space-between; }
.stack { display: grid; gap: 12px; }

/* ── forms ── */
.field { display: grid; gap: 6px; margin-bottom: 14px; }
.field > label, .label { font-size: .88rem; color: var(--muted); font-weight: 600; }
.hint { font-size: .82rem; color: var(--faint); }
.input, input:not([type]), input[type=text], input[type=password], input[type=email], input[type=number], input[type=search], input[type=tel], input[type=url], select, textarea {
  width: 100%; min-height: 46px; background: #0a0b0e; border: 1px solid var(--line-2); color: var(--text);
  padding: 10px 12px; font: 400 1rem/1.4 var(--body); border-radius: 2px; transition: border-color .15s, box-shadow .15s;
}
textarea { min-height: 110px; resize: vertical; }
select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 34px; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-dim); }
input::placeholder, textarea::placeholder { color: #4d5360; }
.input-group { display: flex; align-items: stretch; }
.input-group .prefix { display: grid; place-items: center; padding: 0 12px; border: 1px solid var(--line-2); border-right: 0; background: var(--plate-2); color: var(--muted); font: 600 1rem var(--display); }
.check { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; margin: 8px 0; }
.check input { width: 18px; height: 18px; margin-top: 3px; accent-color: var(--ember); flex: none; }
input[type=file] { color: var(--muted); font-size: .9rem; }

/* ── notices ── */
.notice { padding: 11px 14px; font-size: .94rem; border-left: 3px solid var(--info); background: var(--info-dim); margin: 0 0 12px; }
.notice.ok { border-color: var(--ok); background: var(--ok-dim); }
.notice.bad { border-color: var(--bad); background: var(--bad-dim); }
.notice.warn { border-color: var(--warn); background: var(--warn-dim); }
.notice.gold { border-color: var(--gold); background: var(--gold-dim); }
.notice p:last-child { margin: 0; }
.flashes { padding-top: 14px; }
.announce { background: var(--ember); color: #fff; text-align: center; font: 600 .9rem/1.3 var(--display); padding: 8px 14px; }

/* ── header ── */
.top { position: sticky; top: 0; z-index: 40; background: rgba(0,0,0,.9); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.top .wrap { display: flex; align-items: center; gap: 10px; height: 62px; }
.brand { display: flex; align-items: center; flex: none; }
.brand img { height: 36px; width: auto; }
.nav { display: none; gap: 2px; margin-left: 18px; }
@media (min-width: 900px) { .nav { display: flex; } }
.nav a { padding: 8px 12px; color: var(--muted); text-decoration: none; font: 600 .96rem var(--display); }
.nav a:hover { color: var(--text); }
.nav a.on { color: var(--text); box-shadow: inset 0 -2px 0 var(--ember); }
.top-right { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.wallet-chip { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 12px; background: var(--plate-2); color: var(--gold); font: 700 .95rem var(--display); text-decoration: none;
  clip-path: polygon(7px 0, 100% 0, 100% calc(100% - 7px), calc(100% - 7px) 100%, 0 100%, 0 7px); }
.wallet-chip:hover { background: var(--plate-3); }
.icon-btn { position: relative; width: 40px; height: 40px; display: grid; place-items: center; color: var(--muted); text-decoration: none; background: none; border: 0; cursor: pointer; }
.icon-btn:hover { color: var(--text); }
.icon-btn .dot { position: absolute; top: 4px; right: 3px; min-width: 17px; height: 17px; border-radius: 9px; background: var(--ember); color: #fff; font: 700 10px/17px var(--display); text-align: center; padding: 0 4px; }
.hide-sm { display: none; }
@media (min-width: 900px) { .hide-sm { display: inline-flex; } .hide-lg { display: none !important; } }

/* ── bottom tab bar (phones) ── */
.tabbar { position: fixed; bottom: 0; left: 0; right: 0; z-index: 40; background: rgba(0,0,0,.96); border-top: 1px solid var(--line);
  display: grid; grid-template-columns: repeat(4, 1fr); padding-bottom: env(safe-area-inset-bottom); }
.tabbar a { display: grid; justify-items: center; gap: 3px; padding: 9px 0 8px; color: var(--faint); text-decoration: none; font: 600 .72rem/1 var(--display); position: relative; }
.tabbar a.on { color: var(--text); }
.tabbar a.on .ic { color: var(--ember); }
.tabbar .dot { position: absolute; top: 5px; left: calc(50% + 6px); width: 8px; height: 8px; border-radius: 50%; background: var(--ember); }
@media (min-width: 900px) { .tabbar { display: none; } }

/* ── hero ── */
.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--line); padding: 30px 0 34px;
  background: radial-gradient(90% 70% at 85% 10%, rgba(120, 14, 20, .55), transparent 60%), #000; }
.hero::before { content: ""; position: absolute; right: -120px; top: -50px; width: 540px; height: 500px; background: url(/static/img/dragon.png) no-repeat center/contain; opacity: .5; pointer-events: none; }
.hero .wrap { position: relative; display: grid; gap: 30px; }
@media (min-width: 900px) {
  .hero { padding: 70px 0 64px; }
  .hero .wrap { grid-template-columns: 1.08fr .92fr; align-items: center; gap: 48px; }
  .hero::before { right: 2%; top: -30px; width: 620px; height: 580px; }
}
.hero h1 { font-size: clamp(2.15rem, 7.6vw, 3.75rem); line-height: 1.02; max-width: 13ch; margin-bottom: 16px;
  background: linear-gradient(180deg, #fff 0%, #e9ebef 38%, #a3a9b3 78%, #7c828d 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .lead { color: #b8bec8; font-size: 1.08rem; max-width: 44ch; }
.hero .actions { display: flex; gap: 12px; flex-wrap: wrap; margin: 22px 0 20px; }
.facts { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; color: var(--muted); font-size: .93rem; }
@media (min-width: 560px) { .facts { display: flex; flex-wrap: wrap; gap: 8px 22px; } }
.facts li { display: flex; gap: 8px; align-items: center; white-space: nowrap; }
.facts .ic { color: var(--gold); }

/* in-game profile card replica (hero) */
.likecard { margin: 0; filter: drop-shadow(0 20px 46px rgba(227, 38, 46, .35)); }
.lc { position: relative; display: grid; grid-template-columns: 74px 1fr auto; gap: 14px; align-items: center; padding: 14px 18px 14px 16px;
  background: linear-gradient(180deg, #ecedef, #dcdee1); color: #22252b; border-top: 3px solid var(--gold);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 16px), calc(100% - 16px) 100%, 0 100%); }
.lc::after { content: ""; position: absolute; left: 0; bottom: 0; width: 64px; height: 18px; background: linear-gradient(115deg, var(--gold) 0 58%, #1b2a44 58% 100%); clip-path: polygon(0 0, 70% 0, 100% 100%, 0 100%); }
.lc img { width: 74px; height: 74px; object-fit: cover; border: 3px solid #fff; box-shadow: 0 0 0 1px #1c1f25; }
.lc .who { min-width: 0; }
.lc .nm { font: 600 1.3rem/1.1 var(--display); color: #2a2d33; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lc .rg { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.lc .rg span { font: 600 .78rem/1 var(--display); padding: 4px 7px; background: #2a2e36; color: #e9ebef; }
.lc .cnt { text-align: right; }
.lc .plus { font: 700 1.05rem/1 var(--display); color: #4a4f58; opacity: 0; transform: translateY(8px); transition: opacity .45s ease, transform .45s cubic-bezier(.2,.9,.3,1.4); }
.lc.done .plus { opacity: 1; transform: none; color: #b07b00; }
.lc .lk { display: flex; align-items: center; gap: 6px; margin-top: 6px; font: 700 2rem/1 var(--display); color: #1d2026; font-variant-numeric: tabular-nums; }
.lc .lk .ic { color: #1d2026; }
.likecard figcaption { margin-top: 12px; color: var(--faint); font-size: .86rem; }
@media (max-width: 420px) { .lc { grid-template-columns: 60px 1fr auto; gap: 10px; padding: 12px 14px 12px 12px; } .lc img { width: 60px; height: 60px; } .lc .nm { font-size: 1.08rem; } .lc .lk { font-size: 1.55rem; } }

/* ── sections ── */
.sec-head { display: flex; justify-content: space-between; align-items: end; gap: 12px; margin: 34px 0 14px; }
.sec-head h2 { margin: 0; }
.sec-head p { margin: 4px 0 0; color: var(--muted); }
.toolbar { display: grid; gap: 12px; margin: 0 0 18px; }
@media (min-width: 760px) { .toolbar { grid-template-columns: minmax(0, 1fr) 210px; align-items: center; } }
.search { position: relative; }
.search .ic { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: var(--faint); pointer-events: none; }
.search input { padding-left: 42px; }
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; grid-column: 1 / -1; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border: 1px solid var(--line-2); color: var(--muted); text-decoration: none; font: 600 .9rem var(--display); background: transparent; cursor: pointer; }
.chip:hover { color: var(--text); }
.chip.on { border-color: var(--ember); color: var(--text); background: var(--ember-dim); }

.grid { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 620px) { .grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .grid { grid-template-columns: repeat(3, 1fr); } }
.pcard { display: flex; flex-direction: column; }
.pcard::before { background: var(--plate); }
.pcard-media { position: relative; aspect-ratio: 16 / 10; overflow: hidden; background: #050506;
  clip-path: polygon(calc(var(--cut) - 1px) 0, 100% 0, 100% 100%, 0 100%, 0 calc(var(--cut) - 1px)); }
.pcard-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.pcard:hover .pcard-media img { transform: scale(1.03); }
.tag { position: absolute; top: 12px; left: 12px; padding: 5px 13px 5px 10px; font: 700 .78rem/1.15 var(--display); letter-spacing: .02em; color: #fff; background: var(--ember);
  clip-path: polygon(0 0, 100% 0, calc(100% - 7px) 100%, 0 100%); z-index: 1; }
.tag-gold { background: var(--gold); color: #191200; }
.tag-green { background: #1f9d5c; }
.tag-blue { background: #2563eb; }
.tag-silver { background: #d8dbe0; color: #111; }
.tag-black { background: #000; color: #fff; box-shadow: inset 0 0 0 1px #555; }
.pcard-body { padding: 15px 16px 17px; display: grid; gap: 6px; flex: 1; align-content: start; }
.pcard h3 { font-size: 1.22rem; margin: 0; }
.pcard p { margin: 0; color: var(--muted); font-size: .95rem; }
.pcard-foot { display: flex; justify-content: space-between; align-items: baseline; margin-top: 8px; padding-top: 10px; border-top: 1px solid var(--line); }
.from { color: var(--muted); font-size: .9rem; }
.from b { color: var(--gold); font: 700 1.3rem var(--display); }
.empty { text-align: center; padding: 40px 16px; color: var(--muted); }
.empty .ic { color: var(--faint); margin: 0 auto 10px; }

.steps { display: grid; gap: 12px; }
@media (min-width: 760px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step .n { font: 700 2.3rem/1 var(--display); color: var(--ember); display: block; margin-bottom: 8px; }
.step h3 { margin-bottom: 6px; }
.step p { margin: 0; color: var(--muted); }
.rules-box { border-left: 3px solid var(--gold); background: linear-gradient(90deg, var(--gold-dim), transparent 75%); padding: 16px 18px; }
.rules-box h3 { color: var(--gold); }

/* ── product page ── */
.crumbs { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; color: var(--faint); font-size: .88rem; margin: 18px 0 14px; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--text); }
.pp { display: grid; gap: 22px; padding-bottom: 40px; grid-template-areas: "main" "buy" "info"; }
.pp-main { grid-area: main; min-width: 0; }
.pp-info { grid-area: info; min-width: 0; }
.buy-col { grid-area: buy; min-width: 0; }
@media (min-width: 980px) { .pp { grid-template-columns: minmax(0, 1fr) 410px; grid-template-areas: "main buy" "info buy"; align-items: start; column-gap: 32px; row-gap: 8px; } .buy-col { position: sticky; top: 80px; align-self: start; } }
.pp-media { position: relative; }
.pp-media .pcard-media { aspect-ratio: 16 / 9; }
.pp-title { margin: 18px 0 8px; font-size: clamp(1.8rem, 5vw, 2.5rem); }
.pp-short { color: #b8bec8; font-size: 1.05rem; max-width: 60ch; }
.prose { color: #cfd3da; max-width: 68ch; }
.prose h2, .prose h3, .prose h4 { color: var(--text); margin-top: 22px; }
.prose ul, .prose ol { padding-left: 1.25em; margin: 0 0 .8em; }
.prose li { margin: 5px 0; }
.prose li::marker { color: var(--ember); }
.prose ol li::marker { font-family: var(--display); font-weight: 700; }
.prose strong { color: var(--text); }
.prose a { color: var(--gold); }
.psec { padding: 22px 0; border-top: 1px solid var(--line); display: grid; gap: 16px; }
.psec:first-of-type { border-top: 0; }
@media (min-width: 760px) { .psec.has-img { grid-template-columns: 1fr 1fr; align-items: center; } }
.psec img { border: 1px solid var(--line-2); }

.pkgs { display: grid; gap: 10px; grid-template-columns: repeat(2, 1fr); }
@media (min-width: 560px) { .pkgs { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 980px) { .pkgs { grid-template-columns: repeat(2, 1fr); } }
.pkg { position: relative; display: grid; gap: 1px; padding: 13px 13px 12px; background: var(--plate); border: 1px solid var(--line-2); cursor: pointer; transition: border-color .15s, background .15s; min-width: 0; }
.pkg:hover { border-color: #5a606c; }
.pkg input { position: absolute; opacity: 0; pointer-events: none; }
.pkg .amt { font: 700 1.55rem/1.05 var(--display); font-variant-numeric: tabular-nums; }
.pkg .unit { color: var(--muted); font-size: .82rem; }
.pkg .price { display: flex; gap: 8px; align-items: baseline; margin-top: 9px; font: 700 1.12rem var(--display); color: var(--gold); }
.pkg .price s { color: var(--faint); font-size: .85rem; font-weight: 500; }
.pkg .badge { position: absolute; top: -1px; right: -1px; padding: 3px 9px 3px 12px; background: var(--ember); color: #fff; font: 700 .7rem/1.3 var(--display);
  clip-path: polygon(7px 0, 100% 0, 100% 100%, 0 100%); }
.pkg.on { border-color: var(--ember); background: linear-gradient(180deg, var(--ember-dim), transparent 85%), var(--plate); box-shadow: inset 0 0 0 1px var(--ember); }
.pkg:focus-within { outline: 2px solid var(--gold); outline-offset: 2px; }
.pkg-img { width: 100%; aspect-ratio: 16/9; object-fit: cover; margin-bottom: 8px; border: 1px solid var(--line); }

.buy h2 { font-size: 1.3rem; margin-bottom: 14px; }
.sel { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 14px; background: var(--plate-2); margin-bottom: 16px; }
.sel .t { font: 700 1.05rem var(--display); }
.sel .d { color: var(--muted); font-size: .86rem; }
.sel .p { font: 700 1.35rem var(--display); color: var(--gold); white-space: nowrap; }
.regions { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
@media (min-width: 420px) { .regions { grid-template-columns: repeat(5, 1fr); } }
@media (min-width: 980px) { .regions { grid-template-columns: repeat(4, 1fr); } }
.region { position: relative; display: grid; justify-items: center; gap: 1px; padding: 7px 2px; border: 1px solid var(--line-2); cursor: pointer; font: 600 .82rem/1.2 var(--display); color: var(--muted); text-align: center; }
.region input { position: absolute; opacity: 0; pointer-events: none; }
.region .fl { font-size: 1rem; line-height: 1; }
.region:hover { color: var(--text); }
.region.on { border-color: var(--gold); color: var(--gold); background: var(--gold-dim); }
.region:focus-within { outline: 2px solid var(--gold); outline-offset: 1px; }
.acct { display: grid; grid-template-columns: auto 1fr; gap: 5px 16px; padding: 13px 14px; background: var(--plate-2); font-size: .95rem; margin: 0 0 12px; }
.acct dt { color: var(--muted); }
.acct dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.acct .big { font: 700 1.15rem var(--display); }
.bal-line { display: flex; justify-content: space-between; font-size: .92rem; color: var(--muted); margin: 4px 0 10px; }
.bal-line b { color: var(--text); font-family: var(--display); }
.or { display: flex; align-items: center; gap: 10px; color: var(--faint); font-size: .82rem; margin: 10px 0; }
.or::before, .or::after { content: ""; flex: 1; border-top: 1px solid var(--line); }
.spin { width: 18px; height: 18px; border: 2px solid rgba(255,255,255,.2); border-top-color: currentColor; border-radius: 50%; animation: spin .8s linear infinite; display: inline-block; vertical-align: -3px; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ── orders ── */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin: 6px 0 18px; overflow-x: auto; }
.tabs a { padding: 10px 14px; color: var(--muted); text-decoration: none; font: 600 .95rem var(--display); white-space: nowrap; }
.tabs a.on { color: var(--text); box-shadow: inset 0 -2px 0 var(--ember); }
.tabs a .n { color: var(--faint); font-weight: 500; margin-left: 4px; }
.olist { display: grid; gap: 14px; }
@media (min-width: 900px) { .olist { grid-template-columns: repeat(2, 1fr); } }
.ocard > .in { display: grid; gap: 12px; }
.ohead { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.ohead h3 { margin: 0 0 3px; font-size: 1.12rem; }
.ometa { color: var(--muted); font-size: .88rem; display: flex; flex-wrap: wrap; gap: 4px 12px; }
.status { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; font: 600 .8rem/1.2 var(--display); border: 1px solid currentColor; white-space: nowrap; }
.status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.s-active { color: var(--gold); }
.s-active::before { animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .25; } }
.s-completed, .s-delivered, .s-merged { color: var(--ok); }
.s-refunded, .s-cancelled, .s-stopped, .s-failed, .s-expired, .s-rejected { color: var(--faint); }
.s-sent, .s-queued, .s-scheduled, .s-processing, .s-awaiting_payment, .s-pending, .s-review { color: var(--info); }
.bar { height: 8px; background: #1a1d24; overflow: hidden; }
.bar i { display: block; height: 100%; background: linear-gradient(90deg, #b88400, var(--gold)); transition: width .6s ease; }
.bar-label { display: flex; justify-content: space-between; font-size: .86rem; color: var(--muted); margin-bottom: 6px; }
.bar-label b { color: var(--text); font-family: var(--display); }
.ostats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.ostats > div { background: var(--plate-2); padding: 9px 10px; min-width: 0; }
.ostats b { display: block; font: 700 1.12rem/1.2 var(--display); font-variant-numeric: tabular-nums; overflow: hidden; text-overflow: ellipsis; }
.ostats span { color: var(--muted); font-size: .76rem; }
.ostats b.up { color: var(--gold); }
.copy { display: inline-flex; align-items: center; gap: 5px; background: none; border: 0; padding: 2px 0; color: inherit; font: inherit; cursor: pointer; }
.copy .ic { color: var(--faint); }
.copy:hover .ic, .copy.done .ic { color: var(--gold); }

.slip { position: relative; background: #1b2433; border-radius: 14px 14px 14px 4px; padding: 12px 14px 10px; max-width: 520px; color: #e9eef6; }
.slip pre { margin: 0; white-space: pre-wrap; word-break: break-word; font: 400 .95rem/1.5 var(--body); }
.slip-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 6px; font: 600 .82rem var(--display); color: #8fb4e8; }
.slip-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; color: #7f8ea6; font-size: .78rem; }
.log { display: grid; gap: 0; }
.log-row { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.log-row:last-child { border-bottom: 0; }
.log-row .when { color: var(--muted); font-size: .86rem; }
.log-row .gv { font: 700 1.1rem var(--display); color: var(--gold); text-align: right; }
.log-row .ba { grid-column: 1 / -1; color: var(--muted); font-size: .88rem; }
.log-row details { grid-column: 1 / -1; }
.log-row summary { cursor: pointer; color: var(--faint); font-size: .84rem; }
.log-row summary:hover { color: var(--text); }
.timeline { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.timeline li { display: grid; grid-template-columns: 14px 1fr; gap: 10px; font-size: .92rem; }
.timeline li::before { content: ""; width: 9px; height: 9px; margin-top: 6px; background: var(--line-2); transform: rotate(45deg); }
.timeline li.hl::before { background: var(--gold); }
.timeline .t { color: var(--faint); font-size: .8rem; display: block; }
.switch { position: relative; display: inline-flex; align-items: center; gap: 10px; cursor: pointer; font-size: .92rem; }
.switch input { position: absolute; opacity: 0; }
.switch .tr { width: 42px; height: 24px; background: var(--line-2); border-radius: 12px; position: relative; transition: background .2s; flex: none; }
.switch .tr::after { content: ""; position: absolute; left: 3px; top: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .2s; }
.switch input:checked + .tr { background: var(--ember); }
.switch input:checked + .tr::after { transform: translateX(18px); }
.switch input:focus-visible + .tr { outline: 2px solid var(--gold); outline-offset: 2px; }

/* ── wallet ── */
.wallet-top { display: grid; gap: 16px; margin: 18px 0 8px; }
@media (min-width: 900px) { .wallet-top { grid-template-columns: 330px 1fr; align-items: start; } }
.bal-card .amt { font: 700 clamp(2.1rem, 9vw, 2.9rem)/1 var(--display); margin: 6px 0 4px; font-variant-numeric: tabular-nums; }
.bal-card .label { display: flex; align-items: center; gap: 8px; }
.mtabs { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 16px; }
@media (min-width: 640px) { .mtabs.n3 { grid-template-columns: repeat(3, 1fr); } .mtabs.n4, .mtabs.n5, .mtabs.n6 { grid-template-columns: repeat(4, 1fr); } }
.mtab { display: grid; justify-items: center; gap: 5px; padding: 16px 8px 14px; background: var(--plate); border: 1px solid var(--line-2); color: var(--muted); text-decoration: none; text-align: center; transition: border-color .15s, background .15s; }
.mtab:hover { border-color: #5a606c; }
.mtab .ic { color: var(--muted); }
.mtab .t { font: 700 1.08rem/1.1 var(--display); color: var(--text); }
.mtab .s { font-size: .8rem; line-height: 1.3; }
.mtab.on { border-color: rgba(245,179,1,.6); background: rgba(245,179,1,.06); }
.mtab.on .ic { color: var(--gold); }
.quick { display: flex; flex-wrap: wrap; gap: 8px; margin: -4px 0 14px; }
.quick button { min-height: 34px; padding: 0 12px; background: var(--plate-2); border: 1px solid var(--line-2); color: var(--text); font: 600 .9rem var(--display); cursor: pointer; }
.quick button:hover { border-color: var(--gold); }
.conv { color: var(--muted); font-size: .9rem; margin: -6px 0 14px; }
.conv b { color: var(--gold); font-family: var(--display); }
.txlist { display: grid; }
.tx { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.tx:last-child { border-bottom: 0; }
.tx .w { font-weight: 600; }
.tx .d { color: var(--faint); font-size: .84rem; }
.tx .a { font: 700 1.05rem var(--display); text-align: right; font-variant-numeric: tabular-nums; }
.tx .a.plus { color: var(--ok); }
.tx .b { color: var(--faint); font-size: .8rem; text-align: right; }

/* deposit screens */
.dep { max-width: 560px; margin: 18px auto 40px; }
.dep-amt { font: 700 2.4rem/1 var(--display); text-align: center; margin: 6px 0 2px; font-variant-numeric: tabular-nums; }
.step-row { display: flex; gap: 12px; align-items: center; margin: 20px 0 12px; font-size: 1.04rem; }
.step-dot { width: 30px; height: 30px; border-radius: 50%; background: var(--gold); color: #191200; display: grid; place-items: center; font: 700 .95rem var(--display); flex: none; }
.payid { display: flex; justify-content: center; align-items: center; gap: 12px; padding: 18px 14px; border: 1.5px dashed rgba(245,179,1,.6); background: rgba(245,179,1,.08);
  color: var(--gold); font: 700 clamp(1.4rem, 6vw, 1.85rem)/1.1 var(--display); letter-spacing: .04em; cursor: pointer; width: 100%; overflow-wrap: anywhere; text-align: center; }
.payid .ic { color: var(--muted); }
.payid.small { font-size: 1.05rem; letter-spacing: .01em; }
.coins { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; font: 600 .92rem var(--display); margin: 14px 0 4px; }
.coins i { display: inline-block; width: 13px; height: 13px; border-radius: 50%; margin-right: 6px; vertical-align: -1px; }
.btn-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.btn-pair .btn { padding: 0 10px; }
.helpbar { display: flex; align-items: center; gap: 10px; padding: 12px 14px; background: #0f1823; border: 1px solid #1e2c3d; margin-top: 18px; font-size: .95rem; }
.helpbar .ic { color: #2aa3ef; }
.helpbar a { color: #4fb7ff; text-decoration: none; font-weight: 600; }
.qrcard { display: grid; justify-items: center; gap: 12px; text-align: center; }
.qr-frame { position: relative; padding: 14px; background: #fff; width: min(270px, 74vw); }
.qr-frame::before, .qr-frame::after { content: ""; position: absolute; width: 30px; height: 30px; border: 3px solid var(--gold); }
.qr-frame::before { top: -7px; left: -7px; border-right: 0; border-bottom: 0; }
.qr-frame::after { bottom: -7px; right: -7px; border-left: 0; border-top: 0; }
.qr-frame svg { width: 100%; height: auto; display: block; }
.countdown { font: 700 1.05rem var(--display); color: var(--gold); }
.state { display: flex; align-items: center; justify-content: center; gap: 10px; padding: 12px; background: var(--plate-2); font-weight: 600; }
.state.ok { color: var(--ok); background: var(--ok-dim); }
.state.bad { color: var(--bad); background: var(--bad-dim); }
.result { padding: 12px 14px; margin-top: 12px; font-size: .95rem; }
.result.ok { background: var(--ok-dim); border-left: 3px solid var(--ok); }
.result.bad { background: var(--bad-dim); border-left: 3px solid var(--bad); }
.result.info { background: var(--info-dim); border-left: 3px solid var(--info); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: .95rem; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }

/* ── auth ── */
.auth { min-height: calc(100vh - 140px); display: grid; place-items: center; padding: 28px 0 40px; }
.auth .plate { width: min(430px, 100%); }
.auth h1 { font-size: 1.7rem; }
.auth .switch-line { text-align: center; color: var(--muted); margin-top: 14px; font-size: .94rem; }
.auth .switch-line a { color: var(--gold); }
.hp { position: absolute; left: -9999px; }

/* ── misc ── */
.page-head { margin: 22px 0 6px; display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.page-head h1 { margin: 0; font-size: clamp(1.6rem, 5vw, 2.1rem); }
.two-col { display: grid; gap: 16px; }
@media (min-width: 900px) { .two-col { grid-template-columns: minmax(0, 1fr) 360px; align-items: start; } }
.card-list { display: grid; gap: 14px; }
.notif { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.notif .ic { color: var(--faint); margin-top: 2px; }
.notif.unread .ic { color: var(--ember); }
.notif .t { font-weight: 600; }
.notif .b { color: var(--muted); font-size: .92rem; }
.notif .w { color: var(--faint); font-size: .8rem; white-space: nowrap; }
.foot { border-top: 1px solid var(--line); margin-top: 56px; padding: 26px 0 30px; color: var(--faint); font-size: .9rem; }
.foot .wrap { display: grid; gap: 14px; }
@media (min-width: 760px) { .foot .wrap { grid-template-columns: 1fr auto; align-items: center; } }
.foot a { color: var(--muted); text-decoration: none; }
.foot a:hover { color: var(--text); }
.foot nav { display: flex; gap: 18px; flex-wrap: wrap; }
.foot img { height: 28px; width: auto; opacity: .85; }
.install { display: none; }
.install.show { display: flex; }
@media (max-width: 899px) { .top .install { display: none !important; } }
.err-page { text-align: center; padding: 70px 16px; }
.err-page .code { font: 700 4.5rem/1 var(--display); color: var(--ember); }
.toast-host { position: fixed; left: 50%; bottom: calc(80px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 100; display: grid; gap: 8px; width: min(92vw, 420px); pointer-events: none; }
@media (min-width: 900px) { .toast-host { bottom: 26px; } }
.toast { padding: 12px 14px; background: var(--plate-3); border-left: 3px solid var(--ok); box-shadow: 0 12px 34px rgba(0,0,0,.6); font-size: .94rem; animation: tin .25s ease; pointer-events: auto; }
.toast.bad { border-color: var(--bad); }
@keyframes tin { from { opacity: 0; transform: translateY(8px); } }
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th { text-align: left; color: var(--muted); font-weight: 600; padding: 10px 10px; border-bottom: 1px solid var(--line-2); white-space: nowrap; font-size: .84rem; }
.table td { padding: 11px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tr:hover td { background: rgba(255,255,255,.015); }
.table a { color: var(--text); }
.pill { display: inline-block; padding: 2px 8px; font: 600 .76rem/1.4 var(--display); background: var(--plate-3); color: var(--muted); }
.pill.red { background: var(--ember-dim); color: #ff8a8f; }
.pill.gold { background: var(--gold-dim); color: var(--gold); }
.pill.green { background: var(--ok-dim); color: var(--ok); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}

/* ── maintenance / stock states ── */
.maint-banner { background: linear-gradient(90deg, rgba(245,158,11,.16), rgba(245,158,11,.05)); border-bottom: 1px solid rgba(245,158,11,.35); color: #ffd58a; }
.maint-banner .wrap { display: flex; gap: 10px; align-items: center; padding-top: 10px; padding-bottom: 10px; font-weight: 600; font-size: .95rem; }
.maint-note { display: flex; gap: 10px; align-items: flex-start; }
.maint-note .ic { margin-top: 2px; color: var(--warn); }
.pkg.off { cursor: not-allowed; border-style: dashed; background: repeating-linear-gradient(135deg, rgba(255,255,255,.02) 0 8px, transparent 8px 16px), var(--plate); }
.pkg.off .amt, .pkg.off .price, .pkg.off .unit { opacity: .45; }
.pkg-state { position: absolute; top: -1px; right: -1px; padding: 3px 9px 3px 12px; background: #3a2a05; color: var(--warn); font: 700 .7rem/1.3 var(--display);
  clip-path: polygon(7px 0, 100% 0, 100% 100%, 0 100%); letter-spacing: .02em; }
.state-tag { position: absolute; top: 12px; right: 12px; padding: 5px 10px; font: 700 .76rem/1.15 var(--display); letter-spacing: .03em; z-index: 1;
  background: rgba(0,0,0,.78); color: var(--warn); border: 1px solid rgba(245,158,11,.6); }
.state-tag.soldout { color: #ff8a8f; border-color: rgba(227,38,46,.6); }
.maint-page { padding: 0; min-height: 100vh; display: grid; place-items: center;
  background: radial-gradient(80% 60% at 80% 0%, rgba(120,14,20,.45), transparent 60%), #000; }
.maint-wrap { width: min(520px, 100% - 32px); display: grid; gap: 18px; justify-items: center; text-align: center; padding: 40px 0; }
.maint-logo { height: 64px; width: auto; }
.maint-wrap .plate { width: 100%; }
.maint-wrap h1 { font-size: 1.9rem; margin: 6px 0 8px; }
.maint-ic { width: 64px; height: 64px; margin: 0 auto 6px; display: grid; place-items: center; color: var(--gold); background: var(--gold-dim); border-radius: 50%; }

/* ── deposit: ways to pay ── */
.dep-amt.copy { background: none; border: 0; color: var(--text); cursor: pointer; display: inline-flex; align-items: center; gap: 10px; }
.dep-amt.copy .ic { color: var(--faint); }
.dep-amt.copy:hover .ic, .dep-amt.copy.done .ic { color: var(--gold); }
.ways { width: 100%; display: grid; gap: 10px; text-align: left; margin: 4px 0 2px; }
.way { display: grid; grid-template-columns: 30px 1fr; gap: 12px; align-items: start; padding: 12px; background: var(--plate-2); }
.way b { font-family: var(--display); }

/* ── account: install / insecure ── */
.insecure { display: grid; gap: 6px; }
.insecure b .ic { vertical-align: -2px; margin-right: 4px; }
.install-box { display: grid; gap: 10px; justify-items: start; }
.install-help { width: 100%; padding: 12px 14px; background: var(--plate-2); border-left: 3px solid var(--gold); font-size: .93rem; display: grid; gap: 6px; }

/* combined AutoLikes packages */
.merged-line { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border: 1px dashed var(--line); color: var(--muted); font-size: .92rem; }
.merged-line svg { flex: none; color: var(--ok); }
.pkg-parts { margin-top: 6px; }
.parts-list { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.parts-list li { display: flex; justify-content: space-between; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); font-size: .92rem; }
.parts-list li .mono { font-size: .85rem; }
