/* Rack Lens — PocketPlay tokens, no framework. */

:root {
  --bg: #f6f7f9;
  --panel: #ffffff;
  --panel-2: #f0f2f5;
  --line: #e3e6ec;
  --line-2: #d5d9e2;
  --fg: #16181d;
  --muted: #5c6470;
  --dim: #838b98;
  --accent: #3f68f5;
  --accent-soft: #e8edff;
  --accent-fg: #ffffff;
  --good: #1a7f4b;
  --good-bg: #e7f6ee;
  --bad: #b42318;
  --bad-bg: #fdecea;
  --shadow: 0 1px 2px rgba(16, 20, 30, .06), 0 6px 20px rgba(16, 20, 30, .05);
  --shadow-lift: 0 4px 10px rgba(16, 20, 30, .08), 0 14px 34px rgba(16, 20, 30, .09);
  --radius: 12px;
  --topbar-h: 54px;
}

:root[data-theme="dark"] {
  --bg: #0e1117;
  --panel: #161a22;
  --panel-2: #1c212b;
  --line: #262c38;
  --line-2: #333b4a;
  --fg: #e7eaf0;
  --muted: #a3acbb;
  --dim: #7b8595;
  --accent: #6f92ff;
  --accent-soft: #1e2740;
  --accent-fg: #0d1017;
  --good: #3dcc86;
  --good-bg: #163024;
  --bad: #f97066;
  --bad-bg: #3a1c1c;
  --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 6px 20px rgba(0, 0, 0, .28);
  --shadow-lift: 0 4px 10px rgba(0, 0, 0, .45), 0 14px 34px rgba(0, 0, 0, .4);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0e1117;
    --panel: #161a22;
    --panel-2: #1c212b;
    --line: #262c38;
    --line-2: #333b4a;
    --fg: #e7eaf0;
    --muted: #a3acbb;
    --dim: #7b8595;
    --accent: #6f92ff;
    --accent-soft: #1e2740;
    --accent-fg: #0d1017;
    --good: #3dcc86;
    --good-bg: #163024;
    --bad: #f97066;
    --bad-bg: #3a1c1c;
    --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 6px 20px rgba(0, 0, 0, .28);
    --shadow-lift: 0 4px 10px rgba(0, 0, 0, .45), 0 14px 34px rgba(0, 0, 0, .4);
  }
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--topbar-h) + 12px); }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 15px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
        "Helvetica Neue", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei",
        Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 200;
  padding: 10px 16px; background: var(--accent); color: var(--accent-fg);
  border-radius: 0 0 8px 0;
}
.skip:focus { left: 0; }

.topbar {
  position: sticky; top: 0; z-index: 60;
  display: flex; align-items: center; gap: 10px;
  height: var(--topbar-h); padding: 0 16px;
  background: color-mix(in srgb, var(--panel) 88%, transparent);
  border-bottom: 1px solid var(--line);
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
}
.topbrand { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 16px; letter-spacing: -.01em; }
.brand-logo {
  width: 28px; height: 28px; border-radius: 8px;
  object-fit: cover; display: block; flex: 0 0 28px;
}
.spacer { flex: 1; }
.top-nav { display: flex; gap: 4px; }
.top-nav a {
  padding: 6px 10px; border-radius: 8px;
  color: var(--muted); font-size: 13.5px; font-weight: 500;
}
.top-nav a:hover { background: var(--panel-2); color: var(--fg); }

.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 38px; height: 38px; padding: 0 10px;
  border: 1px solid var(--line); border-radius: 10px;
  background: var(--panel); color: var(--fg);
  font: inherit; font-size: 13px; font-weight: 600;
  cursor: pointer; transition: background .15s ease, border-color .15s ease;
}
.icon-btn:hover { background: var(--panel-2); border-color: var(--line-2); }
.icon-btn img { width: 22px; height: 22px; border-radius: 6px; display: block; }
.ico-moon { display: none; }
:root[data-theme="dark"] .ico-sun { display: none; }
:root[data-theme="dark"] .ico-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .ico-sun { display: none; }
  :root:not([data-theme="light"]) .ico-moon { display: block; }
  :root[data-theme="light"] .ico-sun { display: block; }
  :root[data-theme="light"] .ico-moon { display: none; }
}

.wrap { max-width: 1120px; margin: 0 auto; padding: 28px 20px 56px; }

.hero { max-width: 720px; margin: 8px auto 28px; text-align: center; }
.eyebrow {
  display: inline-block; margin: 0 0 10px;
  padding: 3px 10px; border-radius: 999px;
  background: var(--accent-soft); color: var(--accent);
  font-size: 12px; font-weight: 700; letter-spacing: .02em;
}
:root[data-theme="dark"] .eyebrow { color: var(--fg); }
.hero h1 {
  margin: 0 0 10px; font-size: clamp(26px, 4.2vw, 38px);
  letter-spacing: -.03em; line-height: 1.2;
}
.hero p { margin: 0 auto 18px; max-width: 560px; color: var(--muted); font-size: 15.5px; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; color: var(--dim); font-size: 12.5px; }
.hero-meta span { padding: 3px 8px; border: 1px solid var(--line); border-radius: 999px; background: var(--panel); }

.section { margin: 0 0 36px; }
.section-title {
  display: flex; align-items: center; gap: 8px;
  margin: 0 0 6px; font-size: 15px; font-weight: 700;
}
.section-title::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.section-sub { margin: 0 0 16px; color: var(--muted); font-size: 13.5px; }

.panel {
  padding: 18px; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--panel); box-shadow: var(--shadow);
}

.presets { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.preset, .chip {
  border: 1px solid var(--line); border-radius: 999px;
  background: var(--panel); color: var(--fg);
  font: inherit; font-size: 13px; font-weight: 600;
  padding: 7px 13px; cursor: pointer;
  transition: background .14s ease, border-color .14s ease, color .14s ease;
}
.preset:hover, .chip:hover { background: var(--panel-2); border-color: var(--line-2); }
.preset.on, .chip.on { background: var(--accent); color: var(--accent-fg); border-color: transparent; }

.q { margin: 0 0 14px; }
.q-label { display: block; margin: 0 0 7px; font-size: 13px; font-weight: 600; color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }

.actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 6px; }
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 9px 16px; border: 0; border-radius: 9px;
  background: var(--accent); color: var(--accent-fg);
  font: inherit; font-size: 14px; font-weight: 600; cursor: pointer;
  transition: filter .15s ease;
}
.btn:hover { filter: brightness(1.08); }
.btn.ghost {
  background: var(--panel); color: var(--fg);
  border: 1px solid var(--line);
}

.picks { display: grid; gap: 14px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pick {
  display: flex; flex-direction: column; gap: 10px;
  padding: 18px; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--panel); box-shadow: var(--shadow);
}
.pick:hover { border-color: var(--line-2); box-shadow: var(--shadow-lift); }
.pick-kicker { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.tag {
  padding: 2px 8px; border-radius: 999px;
  background: var(--accent-soft); color: var(--accent);
  font-size: 11px; font-weight: 700;
}
:root[data-theme="dark"] .tag { color: var(--fg); }
.pick h3 { margin: 0; font-size: 17px; letter-spacing: -.01em; }
.pick h3 a:hover { color: var(--accent); }
.pick .btn { margin-top: 4px; align-self: flex-start; }
.price { font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.price small { font-size: 12.5px; font-weight: 500; color: var(--muted); margin-left: 6px; }
.specs { margin: 0; color: var(--muted); font-size: 13px; }
.why, .give { margin: 0; padding: 10px 12px; border-radius: 10px; font-size: 13px; line-height: 1.55; }
.why { background: var(--good-bg); color: var(--good); }
.give { background: var(--bad-bg); color: var(--bad); }
.why b, .give b { display: block; margin-bottom: 4px; font-size: 11px; letter-spacing: .04em; text-transform: uppercase; }
.why ul, .give ul { margin: 0; padding-left: 16px; }
.dim { display: grid; gap: 6px; }
.dim-row { display: grid; grid-template-columns: 72px 1fr 28px; gap: 8px; align-items: center; font-size: 12px; color: var(--muted); }
.bar { height: 7px; background: var(--panel-2); border-radius: 99px; overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--accent); border-radius: 99px; }

.compare { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.compare th, .compare td { padding: 10px 8px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.compare th { font-size: 12px; color: var(--dim); font-weight: 600; }
.compare td.num { font-variant-numeric: tabular-nums; }
.win-cell { color: var(--good); font-weight: 600; }

.toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.search-row {
  display: flex; align-items: center; gap: 8px; flex: 1 1 240px;
  padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--panel);
}
.search-row input {
  flex: 1; min-width: 0; border: 0; background: transparent; color: var(--fg);
  font: inherit; font-size: 14px; outline: none; padding: 6px 0;
}
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.cat { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.cat th, .cat td { padding: 11px 12px; text-align: left; border-bottom: 1px solid var(--line); white-space: nowrap; }
.cat th { font-size: 12px; color: var(--dim); background: var(--panel-2); }
.cat tr:last-child td { border-bottom: 0; }
.cat tbody tr:hover td { background: var(--panel-2); }
.cat a, .compare a { color: var(--accent); font-weight: 600; }
.cat a:hover, .compare a:hover { text-decoration: underline; }

.pgrid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.pcard {
  display: flex; flex-direction: column; gap: 8px;
  padding: 16px; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--panel); box-shadow: var(--shadow);
  color: inherit;
}
a.pcard { cursor: pointer; }
a.pcard:hover { transform: translateY(-2px); box-shadow: var(--shadow-lift); border-color: var(--line-2); }
.pcard h3 { margin: 0; font-size: 15.5px; }
.pcard p { margin: 0; font-size: 13.5px; color: var(--muted); }
.pcard p a { color: var(--accent); }
.card-go { margin-top: auto; font-size: 13px; font-weight: 600; color: var(--accent); }
.pcard .fav {
  width: 22px; height: 22px; border-radius: 6px; object-fit: contain; background: var(--panel-2);
}
img.fav-letter { display: none; }

.calc-grid { display: grid; gap: 14px; grid-template-columns: 1fr 1.4fr; }
.sliders label { display: block; margin: 0 0 12px; font-size: 13px; color: var(--muted); }
.sliders input[type="range"] { width: 100%; accent-color: var(--accent); }
.storage-cards { display: grid; gap: 8px; }
.scard {
  display: flex; justify-content: space-between; gap: 10px; align-items: baseline;
  padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2);
  color: inherit;
}
a.scard:hover { border-color: var(--line-2); }
.scard.best { border-color: color-mix(in srgb, var(--accent) 50%, var(--line)); background: var(--accent-soft); }
.scard b { font-size: 18px; letter-spacing: -.02em; }
.scard small { color: var(--muted); }

.note {
  margin: 10px 0 0; color: var(--dim); font-size: 12.5px;
}

.coming { display: grid; gap: 10px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.coming .pcard { opacity: .92; }

.footer {
  margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--line);
  display: flex; flex-wrap: wrap; gap: 8px 18px;
  color: var(--dim); font-size: 13px;
}
.footer a { color: var(--muted); }
.footer a:hover { color: var(--accent); text-decoration: underline; }

.empty { padding: 28px; text-align: center; color: var(--muted); }

@media (max-width: 900px) {
  .picks, .coming, .calc-grid { grid-template-columns: 1fr; }
  .top-nav { display: none; }
}
.seo-lead { margin: 0 auto 28px; max-width: 720px; color: var(--muted); font-size: 14.5px; line-height: 1.7; text-align: center; }
.seo-lead a { color: var(--accent); }

.faq { display: grid; gap: 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); overflow: hidden; }
.faq details { border-bottom: 1px solid var(--line); padding: 0; }
.faq details:last-child { border-bottom: 0; }
.faq summary {
  cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 12px;
  padding: 14px 16px; font-weight: 600; font-size: 14.5px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary:after { content: "+"; color: var(--dim); font-weight: 500; }
.faq details[open] summary:after { content: "–"; }
.faq .faq-body { padding: 0 16px 14px; color: var(--muted); font-size: 14.5px; line-height: 1.72; }
.faq .faq-body p { margin: 0 0 10px; }
.faq .faq-body p:last-child { margin: 0; }
.faq a { color: var(--accent); }

.lang-en { display: none; }
:root[data-lang="en"] .lang-en { display: block; }
:root[data-lang="en"] .lang-zh { display: none; }
:root[data-lang="en"] span.lang-en { display: inline; }

body.legal .page {
  max-width: 760px; margin: 0 auto;
  padding: 28px clamp(16px, 4vw, 28px) 44px;
}
.prose h1 {
  margin: 0 0 6px; font-size: clamp(24px, 3.4vw, 30px);
  letter-spacing: -.02em; line-height: 1.25;
}
.prose .updated { margin: 0 0 26px; color: var(--dim); font-size: 13px; }
.prose h2 { margin: 30px 0 8px; font-size: 16px; font-weight: 700; }
.prose p, .prose li { margin: 0 0 12px; color: var(--muted); font-size: 14.5px; line-height: 1.72; }
.prose .lede {
  margin-bottom: 22px; padding: 14px 16px;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--panel); color: var(--fg); font-size: 14.5px;
}
.prose ul { margin: 0 0 12px; padding-left: 22px; }
.prose a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.prose strong { color: var(--fg); }
body.legal .footer { margin-top: 40px; }

@media (max-width: 520px) {
  .wrap { padding: 18px 14px 40px; }
  .hero h1 { font-size: 26px; }
  .topbar { padding: 0 10px; gap: 6px; }
  .topbar a.icon-btn[href*="pocketplay.win"] { display: none; }
  .icon-btn { min-width: 36px; height: 36px; }
}
