/* Snarket. One theme, light: the brand's art is high-key monochrome.
   No accent color. Radius rule: panels 20px, controls 12px, chips 8px.
   Layers: page 0, sticky panel 10, top bar 20, toast 50. */
@font-face { font-family: "Montserrat"; src: url("/fonts/montserrat.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("/fonts/jetbrains-mono.woff2") format("woff2"); font-weight: 400; font-display: swap; }

:root {
  --paper: #f3f4f5;
  --card: #fbfbfc;
  --ink: #0d0e10;
  --body: #2a2d31;
  --muted: #555a61;
  --line: rgb(13 14 16 / .14);
  --line-strong: rgb(13 14 16 / .28);
  --error: #8f1d1d;
  --ok: #1d5a3a;
  --sans: "Montserrat", ui-sans-serif, system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --ease: cubic-bezier(.16, 1, .3, 1);
  --pad: clamp(20px, 5vw, 72px);
  --bar: 72px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--bar) + 16px); }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--sans); font-size: 16px; line-height: 1.6; -webkit-font-smoothing: antialiased; }
a { color: inherit; }
svg { fill: currentColor; }
svg.icon { width: 1.1em; height: 1.1em; flex: none; }
[hidden] { display: none !important; }
.mono { font-family: var(--mono); font-size: 12px; letter-spacing: .26em; text-transform: uppercase; }
.wrap { width: 100%; max-width: 1320px; margin: 0 auto; padding-inline: var(--pad); }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 4px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Top bar: stays put, and takes a frosted backing once the page has scrolled under it. */
.top-mark { position: absolute; top: 0; left: 0; width: 1px; height: 1px; }
.topbar { position: sticky; top: 0; z-index: 20; border-bottom: 1px solid transparent; transition: background .3s, border-color .3s, box-shadow .3s; }
.topbar.stuck { background: rgb(243 244 245 / .78); -webkit-backdrop-filter: blur(18px) saturate(140%); backdrop-filter: blur(18px) saturate(140%); border-bottom-color: var(--line); }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: var(--bar); }
.brand { display: inline-flex; align-items: center; gap: 14px; text-decoration: none; font-weight: 500; font-size: 15px; letter-spacing: .34em; white-space: nowrap; }
.brand svg { width: 20px; height: 35px; fill: var(--ink); }
.nav-links { display: flex; align-items: center; gap: clamp(16px, 2.6vw, 36px); font-size: 14px; font-weight: 500; }
.nav-links a { text-decoration: none; padding: 10px 0; color: var(--muted); transition: color .2s; white-space: nowrap; }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--ink); }
.nav-links a[aria-current="page"] { box-shadow: 0 1px 0 var(--ink); }
.nav-x { display: inline-flex; color: var(--ink) !important; }

/* Who is logged in, and the menu under it. */
.user { position: relative; display: flex; align-items: center; min-width: 76px; justify-content: flex-end; }
.user .btn.small { height: 36px; color: #f6f7f8; padding: 0 16px; }
.user-toggle { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--line-strong); background: rgb(255 255 255 / .7); color: var(--ink); font: inherit; font-size: 13px; cursor: pointer; transition: border-color .2s, background .2s; }
.user-toggle:hover, .user-toggle[aria-expanded="true"] { border-color: var(--ink); background: #fff; }
.user-toggle svg { width: 12px; height: 12px; transition: transform .25s var(--ease); }
.user-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
.user-addr { font-family: var(--mono); font-size: 12.5px; white-space: nowrap; }
.user-addr.tiny { display: none; }
/* Real state: a wallet is logged in. */
.user-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ink); }
.user-menu { position: absolute; top: calc(100% + 10px); right: 0; z-index: 30; min-width: 220px; padding: 6px; border-radius: 14px; border: 1px solid var(--line); background: #fff; box-shadow: 0 24px 60px -20px rgb(40 46 56 / .35); animation: menu .18s var(--ease); }
@keyframes menu { from { opacity: 0; transform: translateY(-6px); } }
.user-head { display: grid; gap: 2px; padding: 10px 12px 12px; margin-bottom: 6px; border-bottom: 1px solid var(--line); font-size: 12.5px; color: var(--muted); }
.user-head strong { font-weight: 400; color: var(--ink); }
.user-menu [role="menuitem"] { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border: 0; border-radius: 9px; background: none; color: var(--ink) !important; font: inherit; font-size: 14px; font-weight: 500; text-align: left; text-decoration: none; cursor: pointer; }
.user-menu [role="menuitem"]:hover, .user-menu [role="menuitem"]:focus-visible { background: rgb(13 14 16 / .06); outline: none; }
.user-menu [role="menuitem"] svg { width: 16px; height: 16px; color: var(--muted); }

/* Type */
h1, h2, h3 { margin: 0; letter-spacing: -.02em; }
.display { font-weight: 300; font-size: clamp(2.3rem, 4.1vw, 3.9rem); line-height: 1.08; letter-spacing: -.022em; }
.display strong, .title strong { font-weight: 500; }
.title { font-weight: 300; font-size: clamp(1.9rem, 3.4vw, 2.9rem); line-height: 1.12; }
.lede { margin: 0; max-width: 54ch; font-size: clamp(1rem, 1.25vw, 1.15rem); color: var(--body); }
.eyebrow { margin: 0 0 26px; color: var(--muted); }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; height: 50px; padding: 0 22px; border: 1px solid var(--ink); border-radius: 12px; background: var(--ink); color: #f6f7f8; font: inherit; font-weight: 500; font-size: 15px; white-space: nowrap; text-decoration: none; cursor: pointer; transition: transform .2s var(--ease), background .2s, border-color .2s; }
.btn svg { transition: transform .3s var(--ease); }
.btn:hover { background: #26282c; }
.btn:hover svg { transform: translateX(3px); }
.btn:active { transform: scale(.985); }
.btn[disabled] { cursor: not-allowed; background: #4a4d52; border-color: #4a4d52; }
.btn[aria-busy="true"] { cursor: progress; }
.btn.block { width: 100%; }
.btn.ghost { background: rgb(255 255 255 / .6); color: var(--ink); border-color: var(--line-strong); }
.btn.ghost:hover { background: #fff; border-color: var(--ink); }
.btn.small { height: 38px; padding: 0 14px; font-size: 13.5px; border-radius: 10px; }
.link { display: inline-flex; align-items: center; gap: 8px; font-weight: 500; text-underline-offset: 4px; }

/* Panels and forms */
.panel { position: relative; padding: 30px 28px; border-radius: 20px; border: 1px solid var(--line); background: var(--card); }
/* Frosted glass, over a picture only: an approximation built on backdrop-filter. */
.glass { border-color: rgb(255 255 255 / .75); background: linear-gradient(160deg, rgb(255 255 255 / .72), rgb(255 255 255 / .42)); -webkit-backdrop-filter: blur(22px) saturate(120%); backdrop-filter: blur(22px) saturate(120%); box-shadow: inset 0 1px 0 rgb(255 255 255 / .9), 0 1px 0 rgb(40 46 56 / .06), 0 30px 70px -24px rgb(40 46 56 / .32); }
.panel h2, .panel h3 { font-size: 1.25rem; font-weight: 500; letter-spacing: -.01em; line-height: 1.25; }
.field { display: flex; flex-direction: column; gap: 8px; margin-bottom: 18px; }
label, .label { font-size: 13px; font-weight: 500; }
label span { font-weight: 400; color: var(--muted); }
input[type="text"], input[type="email"], input[type="password"], textarea, select { width: 100%; min-height: 48px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line-strong); background: #fff; color: var(--ink); font: inherit; font-size: 15px; transition: border-color .2s, box-shadow .2s; }
textarea { resize: vertical; line-height: 1.5; }
input::placeholder, textarea::placeholder { color: #6b7077; }
input:hover, textarea:hover, select:hover { border-color: rgb(13 14 16 / .5); }
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgb(13 14 16 / .14); }
[aria-invalid="true"] { border-color: var(--error) !important; }
.code-input { font-family: var(--mono) !important; font-size: 13px !important; }
.help { font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.err { font-size: 13px; color: var(--error); line-height: 1.45; }
.err:empty { display: none; }
.note { margin: 14px 0 0; font-size: 12.5px; color: var(--muted); line-height: 1.5; }

.chip { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 8px; border-radius: 8px; border: 1px solid var(--line); font-size: 12px; color: var(--muted); white-space: nowrap; }
.code { font-family: var(--mono); font-size: 12.5px; line-height: 1.6; word-break: break-all; }
pre.block { margin: 0; padding: 18px 20px; border-radius: 12px; background: var(--ink); color: #e9ebee; font-family: var(--mono); font-size: 12.5px; line-height: 1.7; overflow-x: auto; }
.callout { display: flex; gap: 12px; padding: 14px 16px; border-radius: 12px; border: 1px solid var(--line); background: #fff; font-size: 13.5px; line-height: 1.5; color: var(--body); }
.callout svg { width: 18px; height: 18px; flex: none; margin-top: 2px; }

/* Segmented choice (amounts, filters) */
.seg { display: flex; flex-wrap: wrap; gap: 8px; }
.seg button { height: 40px; padding: 0 16px; border-radius: 12px; border: 1px solid var(--line-strong); background: #fff; color: var(--ink); font: inherit; font-size: 14px; font-weight: 500; cursor: pointer; transition: background .2s, color .2s, border-color .2s, transform .2s var(--ease); }
.seg button:hover { border-color: var(--ink); }
.seg button:active { transform: scale(.97); }
.seg button[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #f6f7f8; }

/* Steps of a running action */
.steps { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 10px; font-size: 13.5px; color: var(--muted); }
.steps li { display: flex; align-items: center; gap: 10px; }
.steps li::before { content: ""; width: 8px; height: 8px; border-radius: 50%; border: 1px solid var(--line-strong); flex: none; }
.steps li[data-state="doing"] { color: var(--ink); }
.steps li[data-state="doing"]::before { border-color: var(--ink); background: var(--ink); animation: pulse 1.1s ease-in-out infinite; }
.steps li[data-state="done"] { color: var(--body); }
.steps li[data-state="done"]::before { border-color: var(--ink); background: var(--ink); }
@keyframes pulse { 50% { opacity: .25; } }

/* A skeleton line while data loads */
.skel { display: block; height: 14px; border-radius: 6px; background: linear-gradient(90deg, rgb(13 14 16 / .07), rgb(13 14 16 / .13), rgb(13 14 16 / .07)); background-size: 200% 100%; animation: shimmer 1.4s linear infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }

.page-head { padding-block: clamp(36px, 6vw, 72px) clamp(28px, 4vw, 44px); }
.page-head .lede { margin-top: 18px; }
main { min-height: 60dvh; }

footer { margin-top: clamp(64px, 9vw, 120px); border-top: 1px solid var(--line); overflow: hidden; }
.foot { display: grid; grid-template-columns: minmax(0, 1.7fr) repeat(4, minmax(0, 1fr)); gap: 40px 32px; padding-block: clamp(44px, 6vw, 72px) clamp(36px, 5vw, 56px); }
.foot-brand p { margin: 18px 0 0; max-width: 32ch; font-size: 14px; line-height: 1.55; color: var(--muted); }
.foot-col { display: grid; gap: 10px; align-content: start; font-size: 14px; }
.foot-col h2 { margin-bottom: 6px; font-size: 13px; font-weight: 500; letter-spacing: 0; color: var(--muted); }
.foot-col a { text-decoration: none; color: var(--body); justify-self: start; transition: color .2s; }
.foot-col a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.foot-base { display: flex; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap; padding-block: 20px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
/* The name, as wide as the page, sinking out of the bottom edge. */
.foot-word { container-type: inline-size; padding-inline: var(--pad); max-width: 1320px; margin: clamp(12px, 3vw, 36px) auto 0; pointer-events: none; user-select: none; }
.foot-word span { display: block; font-weight: 500; font-size: 20.9cqw; line-height: .74; letter-spacing: -.02em; white-space: nowrap; text-align: center; color: var(--ink); margin-bottom: -.13em; -webkit-mask-image: linear-gradient(180deg, #000 10%, rgb(0 0 0 / .12) 92%); mask-image: linear-gradient(180deg, #000 10%, rgb(0 0 0 / .12) 92%); }

.toast { position: fixed; left: 50%; bottom: 28px; z-index: 50; transform: translate(-50%, 20px); padding: 12px 18px; border-radius: 12px; background: var(--ink); color: #f6f7f8; font-size: 14px; opacity: 0; pointer-events: none; transition: opacity .3s, transform .3s var(--ease); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (prefers-reduced-motion: no-preference) {
  .rise { opacity: 0; transform: translateY(18px); animation: rise .9s var(--ease) forwards; animation-delay: calc(var(--i, 0) * 90ms + 120ms); }
  @keyframes rise { to { opacity: 1; transform: none; } }
  .js .reveal { opacity: 0; transform: translateY(22px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: calc(var(--i, 0) * 70ms); }
  .js .reveal.in { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .user-menu { animation: none; }
  .skel, .steps li[data-state="doing"]::before { animation: none; }
}
@media (prefers-reduced-transparency: reduce) {
  .glass { background: var(--card); -webkit-backdrop-filter: none; backdrop-filter: none; }
  .topbar.stuck { background: var(--paper); -webkit-backdrop-filter: none; backdrop-filter: none; }
}
@media (max-width: 640px) {
  .brand { letter-spacing: .26em; font-size: 14px; gap: 10px; }
  .nav-links { gap: 12px; font-size: 13.5px; }
  .user { min-width: 0; }
  .user-toggle { padding: 0 9px; gap: 6px; }
  /* The bar has no room for a whole address on a phone: the menu shows it. */
  .user-addr { display: none; }
  .user-addr.tiny { display: inline; }
  .user .btn.small { padding: 0 12px; }
  .nav-x { display: none; }
  /* Four links and the wordmark do not fit a phone: the mark alone stands for it. */
  .nav .brand span { display: none; }
  .panel { padding: 24px 20px; }
}

/* ---------- Marketplace ---------- */
.page-head.split { display: flex; align-items: flex-end; justify-content: space-between; gap: 28px; flex-wrap: wrap; }
.search { position: relative; width: min(100%, 320px); }
.search svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.search input { padding-left: 42px; }

/* Categories: the live one sells, the planned ones say what is coming. */
.cats { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 28px; scrollbar-width: none; }
.cats::-webkit-scrollbar { display: none; }
.cat { flex: none; display: grid; gap: 2px; min-width: 168px; padding: 14px 18px; text-align: left; border-radius: 12px; border: 1px solid var(--line-strong); background: #fff; color: var(--ink); font: inherit; cursor: pointer; transition: background .2s, color .2s, border-color .2s, transform .2s var(--ease); }
.cat:hover { border-color: var(--ink); }
.cat:active { transform: scale(.98); }
/* What an AI does with the category: think, create, know, run. */
.cat-need { font-family: var(--mono); font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.cat[aria-pressed="true"] .cat-need { color: #b3b8bf; }
.cat-name { font-weight: 500; font-size: 15px; }
.cat-count { font-size: 12.5px; color: var(--muted); }
.cat[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #f6f7f8; }
.cat[aria-pressed="true"] .cat-count { color: #b3b8bf; }

.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-bottom: 22px; }
.toolbar-end { display: flex; align-items: center; gap: 16px; }
.toolbar select { width: auto; min-height: 40px; padding: 8px 12px; font-size: 14px; }

.grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px 20px; }
.card a { display: block; text-decoration: none; }
.card-img { aspect-ratio: 1; border-radius: 16px; overflow: hidden; background: #e6e8ea; }
.card-img.skel { height: auto; }
/* An item's picture: the maker's logo, set in the glass panel. */
.art { position: relative; width: 100%; height: 100%; }
.art-bg { width: 100%; height: 100%; object-fit: cover; display: block; }
.art-logo { position: absolute; left: 50%; top: 48.5%; width: 30%; height: auto; transform: translate(-50%, -50%); opacity: .88; }
.card-img .art { transition: transform .7s var(--ease); }
.card a:hover .card-img .art { transform: scale(1.05); }
.card-body { padding: 14px 2px 0; }
.card-top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.card-top h3 { font-size: 1.05rem; font-weight: 500; letter-spacing: -.01em; }
.card-price { font-family: var(--mono); font-size: 15px; }
.card-sub { display: flex; justify-content: space-between; gap: 12px; margin-top: 2px; font-size: 12.5px; color: var(--muted); }
.card-meta { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 12px; }
.empty { padding: 28px 0; color: var(--muted); font-size: 14.5px; }
.empty.wide { grid-column: 1 / -1; }

.planned { display: grid; grid-template-columns: minmax(0, 420px) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: center; padding-block: 12px 24px; }
.planned-img { aspect-ratio: 1; border-radius: 20px; overflow: hidden; background: #e6e8ea; }
.planned-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.planned .title { margin: 16px 0 14px; }
.planned .btn { margin-top: 26px; }

/* ---------- Item ---------- */
.crumbs { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding-block: 28px 24px; font-size: 13.5px; color: var(--muted); }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--ink); }
.crumbs [aria-current] { color: var(--ink); }
.product { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.product-img { position: sticky; top: calc(var(--bar) + 20px); aspect-ratio: 1; border-radius: 20px; overflow: hidden; background: #e6e8ea; }
.product-img.skel { height: auto; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px; }
.maker { margin: 8px 0 18px; font-size: 14px; color: var(--muted); }
.prices { display: flex; gap: 40px; margin: 26px 0; padding-block: 20px; border-block: 1px solid var(--line); }
.prices dt { font-size: 12.5px; color: var(--muted); }
.prices dd { margin: 4px 0 0; font-size: 14px; color: var(--muted); }
.prices dd b { font-family: var(--mono); font-weight: 400; font-size: 1.5rem; color: var(--ink); margin-right: 4px; }
.buy-box h2 { margin-bottom: 18px; }
.buy-box .label { display: block; margin-bottom: 10px; }
.estimate { min-height: 3.1em; margin: 14px 0 20px; font-size: 13.5px; line-height: 1.55; color: var(--body); }
.crowd[data-alone="true"] { color: var(--error); }
.done-mark { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--ink); color: #f6f7f8; margin-bottom: 20px; }
.done-mark svg { width: 22px; height: 22px; }
.done-text { margin: 10px 0 16px; font-size: 14px; color: var(--body); }
.credit-line { padding: 14px 16px; border-radius: 12px; border: 1px solid var(--line); background: #fff; user-select: all; }
.done-actions { display: flex; gap: 10px; flex-wrap: wrap; margin: 14px 0 20px; }
.small-link { font-size: 13.5px; margin-bottom: 18px; }
.link.plain { display: flex; margin: 16px auto 0; border: 0; background: none; font: inherit; font-size: 14px; color: var(--muted); cursor: pointer; text-decoration: underline; }
.banner { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 28px; }
.sec-title { font-size: 1.45rem; font-weight: 500; padding-bottom: 14px; margin-bottom: 6px; border-bottom: 1px solid var(--line); }
.product-more { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); margin-top: clamp(56px, 8vw, 96px); align-items: start; }
.specs { margin: 0; }
.specs > div { display: grid; grid-template-columns: 11em minmax(0, 1fr); gap: 16px; padding: 13px 0; font-size: 14.5px; }
.specs > div + div { border-top: 1px solid var(--line); }
.specs dt { color: var(--muted); }
.specs dd { margin: 0; }
.after { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 16px; counter-reset: after; }
.after li { display: grid; grid-template-columns: 26px minmax(0, 1fr); column-gap: 12px; counter-increment: after; }
.after li::before { content: counter(after); grid-row: span 2; display: grid; place-items: center; width: 26px; height: 26px; border-radius: 8px; border: 1px solid var(--line-strong); font-family: var(--mono); font-size: 12px; }
.after b { font-weight: 500; }
.after span { font-size: 14px; color: var(--muted); line-height: 1.55; }
.more { margin-top: clamp(56px, 8vw, 96px); }
.more .grid { margin-top: 22px; }

/* ---------- Dashboard ---------- */
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 0 0 clamp(28px, 4vw, 44px); border-block: 1px solid var(--line); }
.stats > div { padding: 24px 28px 24px 0; }
.stats > div + div { padding-left: 28px; border-left: 1px solid var(--line); }
.stats dt { font-size: 13px; color: var(--muted); }
.stats dd { margin: 8px 0 6px; font-family: var(--mono); font-size: clamp(1.7rem, 3vw, 2.3rem); line-height: 1; letter-spacing: -.02em; }
.stats span { font-size: 13px; color: var(--muted); }
.stats span b { font-weight: 500; color: var(--body); }
.welcome { display: flex; align-items: center; justify-content: space-between; gap: 28px; flex-wrap: wrap; margin-bottom: clamp(28px, 4vw, 44px); padding: clamp(28px, 4vw, 48px); border-radius: 20px; background: #e9ebed; }
.welcome .lede { margin-top: 12px; }
.tabs { display: flex; gap: 28px; overflow-x: auto; border-bottom: 1px solid var(--line); margin-bottom: 8px; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { flex: none; padding: 14px 0; border: 0; border-bottom: 2px solid transparent; margin-bottom: -1px; background: none; font: inherit; font-size: 15px; font-weight: 500; color: var(--muted); cursor: pointer; transition: color .2s, border-color .2s; }
.tabs button:hover { color: var(--ink); }
.tabs button[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--ink); }
.tab-note { margin: 18px 0 4px; font-size: 13.5px; color: var(--muted); }
.item.has-thumb { grid-template-columns: 72px minmax(0, 1fr) auto; }
.thumb { display: block; width: 72px; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: #e6e8ea; }
.thumb .art-logo { width: 40%; }
.history-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 10px; }
.history-bar .tab-note { margin: 18px 0; }
.history { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.history th { text-align: left; font-size: 13px; font-weight: 500; color: var(--muted); padding: 10px 20px 10px 0; border-bottom: 1px solid var(--line-strong); }
.history td { padding: 14px 20px 14px 0; vertical-align: top; border-bottom: 1px solid var(--line); }
.history td:first-child { white-space: nowrap; color: var(--muted); font-size: 13.5px; }
.history td strong { display: block; font-weight: 500; }
.history td span { display: block; font-size: 13px; color: var(--muted); }
.history .num { text-align: right; padding-right: 0; font-family: var(--mono); font-size: 13.5px; white-space: nowrap; }
#try-form { margin-top: 18px; }

.stack { display: grid; gap: clamp(40px, 6vw, 72px); }
.sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.sec-head h2 { font-size: 1.45rem; font-weight: 500; }
.sec-head p { margin: 0; font-size: 13.5px; color: var(--muted); }
.items { list-style: none; margin: 0; padding: 0; }
.item { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 20px; align-items: start; padding: 22px 0; border-bottom: 1px solid var(--line); }
.item-title { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.item-title strong { font-size: 1.3rem; font-weight: 500; }
.item-code { margin: 8px 0 6px; color: var(--body); }
.item-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.item-actions .btn.ghost { width: 38px; padding: 0; }
.item[data-status="redeemed"] .item-title strong, .item[data-status="redeemed"] .item-code { color: var(--muted); }
.inline-form { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: start; margin-top: 22px; }
.inline-form .field { margin: 0; }
.inline-form .btn { margin-top: 29px; }
.two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); align-items: start; }
.redeem-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 14px; }
.icon-btn { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--line); background: #fff; cursor: pointer; }
.icon-btn:hover { border-color: var(--ink); }
.usage { margin-top: 10px; font-size: 13px; }
.usage summary { cursor: pointer; color: var(--muted); }
.usage table { width: 100%; margin-top: 10px; border-collapse: collapse; font-size: 12.5px; }
.usage th { text-align: left; font-weight: 500; color: var(--muted); padding: 6px 12px 6px 0; }
.usage td { padding: 6px 12px 6px 0; font-family: var(--mono); border-top: 1px solid var(--line); }
.answer { white-space: pre-wrap; font-size: 15px; line-height: 1.65; color: var(--ink); }
.answer-meta { display: flex; gap: 18px; flex-wrap: wrap; align-items: center; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
#try-out { margin-top: 22px; padding: 22px; border-radius: 12px; border: 1px solid var(--line); background: #fff; }

/* ---------- Docs ---------- */
.docs { display: grid; grid-template-columns: 200px minmax(0, 720px); gap: clamp(28px, 6vw, 96px); align-items: start; }
.toc { position: sticky; top: calc(var(--bar) + 20px); display: grid; gap: 10px; font-size: 14px; }
.toc a { text-decoration: none; color: var(--muted); }
.toc a:hover { color: var(--ink); }
.prose { display: grid; gap: 56px; }
.prose section { display: grid; gap: 16px; }
.prose h2 { font-size: 1.6rem; font-weight: 500; }
.prose h3 { font-size: 1.05rem; font-weight: 500; margin-top: 10px; }
.prose p, .prose li { margin: 0; color: var(--body); }
.prose ul, .prose ol { margin: 0; padding-left: 20px; display: grid; gap: 8px; }
.prose code { font-family: var(--mono); font-size: .88em; padding: 2px 6px; border-radius: 6px; background: rgb(13 14 16 / .07); }
.prose pre code { padding: 0; background: none; font-size: inherit; }
.api { margin: 0; display: grid; gap: 18px; }
.api dt { font-family: var(--mono); font-size: 13.5px; }
.api dd { margin: 4px 0 0; color: var(--body); font-size: 14.5px; }

@media (max-width: 1100px) {
  .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 980px) {
  .product, .product-more, .planned { grid-template-columns: minmax(0, 1fr); }
  .product-img { position: static; max-width: 520px; }
  .planned-img { max-width: 420px; }
  .two { grid-template-columns: minmax(0, 1fr); }
  .docs { grid-template-columns: minmax(0, 1fr); }
  .toc { position: static; grid-auto-flow: column; justify-content: start; gap: 18px; overflow-x: auto; padding-bottom: 6px; white-space: nowrap; }
}
@media (max-width: 760px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 14px; }
  .stats { grid-template-columns: minmax(0, 1fr); }
  .stats > div + div { padding-left: 0; border-left: 0; border-top: 1px solid var(--line); }
  .toolbar-end { width: 100%; justify-content: space-between; }
  .card-sub span:last-child { display: none; }
}
@media (max-width: 640px) {
  .item, .item.has-thumb { grid-template-columns: minmax(0, 1fr); }
  .item.has-thumb .thumb { width: 64px; }
  .specs > div { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .prices { gap: 28px; }
  .item-actions { justify-content: flex-start; }
  .inline-form { grid-template-columns: minmax(0, 1fr); }
  .inline-form .btn { margin-top: 0; }
}

.crowd[data-alone="true"] { color: var(--error); }

/* ---------- Privacy ---------- */
.banner-img { border-radius: 20px; overflow: hidden; aspect-ratio: 2048 / 700; background: #e6e8ea; }
.banner-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.explain { display: grid; gap: clamp(64px, 9vw, 120px); margin-top: clamp(48px, 7vw, 88px); }
.explain .title { max-width: 22ch; }
.explain .sub { margin: 18px 0 0; max-width: 62ch; color: var(--body); }

/* Two acts with nothing between them. */
.acts { display: grid; grid-template-columns: minmax(0, 1fr) 150px minmax(0, 1fr); align-items: stretch; margin-top: clamp(32px, 4vw, 52px); }
.act h3 { display: flex; align-items: center; gap: 10px; font-size: 1.1rem; font-weight: 500; margin-bottom: 4px; }
.act h3 svg { width: 20px; height: 20px; }
.act > p { margin: 0 0 20px; font-size: 13.5px; color: var(--muted); }
.act ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; counter-reset: act; }
.act li { display: grid; grid-template-columns: 26px minmax(0, 1fr); gap: 12px; font-size: 14.5px; line-height: 1.5; counter-increment: act; }
.act li::before { content: counter(act); display: grid; place-items: center; width: 26px; height: 26px; border-radius: 8px; border: 1px solid var(--line-strong); font-family: var(--mono); font-size: 12px; }
.act.dark { background: var(--ink); border-color: var(--ink); color: #f1f2f4; }
.act.dark > p { color: #b3b8bf; }
.act.dark li::before { border-color: rgb(255 255 255 / .35); }
.gap { display: grid; place-items: center; text-align: center; padding: 0 14px; font-size: 13px; line-height: 1.45; color: var(--muted); background: repeating-linear-gradient(90deg, var(--line-strong) 0 6px, transparent 6px 14px) center / 100% 1px no-repeat; }
.gap span { background: var(--paper); padding: 10px 8px; }

.parts { margin: clamp(28px, 4vw, 44px) 0 0; }
.parts > div { display: grid; grid-template-columns: 13em minmax(0, 1fr); gap: 28px; padding: 22px 0; }
.parts > div + div { border-top: 1px solid var(--line); }
.parts dt { font-weight: 500; }
.parts dt code { display: block; margin-top: 6px; font-family: var(--mono); font-size: 12px; font-weight: 400; color: var(--muted); }
.parts dd { margin: 0; color: var(--body); max-width: 64ch; }

.sees { width: 100%; margin-top: clamp(28px, 4vw, 44px); border-collapse: collapse; font-size: 14.5px; }
.sees th, .sees td { text-align: left; vertical-align: top; padding: 16px 20px 16px 0; }
.sees thead th { font-size: 13px; font-weight: 500; color: var(--muted); border-bottom: 1px solid var(--line-strong); }
.sees tbody th { font-weight: 500; width: 24%; }
.sees tbody tr + tr th, .sees tbody tr + tr td { border-top: 1px solid var(--line); }
.sees td { color: var(--body); }
.sees td b { font-weight: 500; color: var(--ink); }
.table-scroll { overflow-x: auto; }

.live { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(24px, 5vw, 72px); align-items: start; margin-top: clamp(28px, 4vw, 44px); }
.stat b { display: block; font-family: var(--mono); font-weight: 400; font-size: clamp(2.4rem, 5vw, 3.6rem); line-height: 1; letter-spacing: -.02em; }
.stat span { display: block; margin-top: 10px; font-size: 14px; color: var(--muted); }
.live dl { margin: 0; display: grid; gap: 18px; }
.live dt { font-size: 13px; color: var(--muted); }
.live dd { margin: 4px 0 0; }
.crowds { display: flex; flex-wrap: wrap; gap: 8px; }

.pair { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; margin-top: clamp(28px, 4vw, 44px); }
.pair h3 { font-size: 1.1rem; font-weight: 500; margin-bottom: 16px; }
.pair ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.pair li b { display: block; font-weight: 500; }
.pair li span { display: block; margin-top: 2px; font-size: 14px; color: var(--muted); line-height: 1.55; }

@media (max-width: 900px) {
  .acts { grid-template-columns: minmax(0, 1fr); }
  .gap { padding: 22px 0; background: repeating-linear-gradient(0deg, var(--line-strong) 0 6px, transparent 6px 14px) center / 1px 100% no-repeat; }
  .live, .pair { grid-template-columns: minmax(0, 1fr); }
  .parts > div { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .sees { min-width: 680px; }
  .banner-img { border-radius: 14px; }
}

@media (max-width: 900px) {
  .foot { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .foot-brand { grid-column: 1 / -1; }
}

.answer-img { display: block; max-width: 100%; max-height: 520px; border-radius: 12px; }

.results { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.results li a { font-weight: 500; text-underline-offset: 4px; word-break: break-word; }
.results li span { display: block; margin-top: 3px; font-size: 13.5px; color: var(--muted); line-height: 1.5; }
.answer + .results { margin-top: 18px; }
.page-text { margin-top: 10px; max-height: 420px; overflow-y: auto; font-size: 14px; }
