/* Tare - design system. Dark, pixel-grid, big display type, tilted stamps. No charts. */

:root {
  --bg: #050505;
  --bg-2: #0b0b0b;
  --surface: #141414;
  --surface-2: #1b1b1b;
  --border: #2a2a2a;
  --border-2: #3a3a3a;
  --text: #f6f6f4;
  --muted: #9b9b97;
  --faint: #6b6b67;
  --orange: #f97316;
  --orange-deep: #c2410c;
  --blue: #1d9bf0;
  --blue-soft: #56b4ec;
  --blue-deep: #3b6db3;
  --ok: #22c55e;
  --bad: #f97316;
  --warn: #eab308;
  --radius: 22px;
  --radius-sm: 14px;
  --pill: 999px;
  --gutter: clamp(16px, 4vw, 40px);
  --max: 1180px;
  --display: "Outfit", system-ui, sans-serif;
  --body: "Inter", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  color-scheme: dark;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 110px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; }
code, kbd, pre { font-family: var(--mono); font-size: 0.88em; }
::selection { background: var(--orange); color: #000; }

:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 8px; }

.skip {
  position: absolute; left: -999px; top: 8px; z-index: 100;
  background: var(--text); color: #000; padding: 10px 16px; border-radius: var(--pill);
}
.skip:focus { left: 16px; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- pixel grid background ---------- */
.pixels {
  position: relative;
  isolation: isolate;
  background-color: var(--bg);
  background-image: conic-gradient(from 90deg at 2px 2px, var(--bg) 90deg, #101010 0);
  background-size: 14px 14px;
  overflow-x: clip; /* random sprinkles near the edge must never widen the page */
}
.pixels::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(ellipse at 50% 40%, transparent 30%, var(--bg) 85%);
}
.sprinkle {
  position: absolute; width: 10px; height: 10px; z-index: -1; pointer-events: none;
  opacity: 0.75; animation: twinkle 5s ease-in-out infinite;
}
@keyframes twinkle { 0%, 100% { opacity: 0.15; } 50% { opacity: 0.8; } }

/* ---------- nav ---------- */
.nav {
  position: relative; top: 12px; z-index: 50;
  margin: 12px auto 0; width: calc(100% - 2 * var(--gutter)); max-width: var(--max);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 12px 14px 12px 22px;
  background: rgba(20, 20, 20, 0.82);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-2); border-radius: var(--radius);
}
.brand {
  display: inline-flex; align-items: center; gap: 10px; text-decoration: none;
  font-family: var(--display); font-weight: 800; font-size: 26px; letter-spacing: -0.02em;
}
.brand svg { width: 30px; height: 30px; }
.nav-links { display: none; align-items: center; gap: 4px; }
.nav-links a {
  text-decoration: none; color: var(--muted); font-weight: 500; font-size: 15px;
  padding: 9px 14px; border-radius: var(--pill); transition: color .15s, background .15s;
}
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--text); background: var(--surface-2); }
.nav-cta { display: none; }
.menu-btn {
  display: inline-grid; place-items: center; width: 46px; height: 46px; border: 0;
  background: transparent; border-radius: 12px; cursor: pointer;
}
.menu-btn svg { width: 30px; height: 30px; }
.menu-btn .close { display: none; }
.nav.open .menu-btn .open { display: none; }
.nav.open .menu-btn .close { display: block; }

.mobile-menu {
  display: none; position: absolute; left: -1px; right: -1px; top: calc(100% + 8px);
  padding: 14px; background: #141414; border: 1px solid var(--border-2);
  border-radius: var(--radius); flex-direction: column; gap: 10px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6);
}
.nav.open { box-shadow: 0 0 0 100vmax rgba(0, 0, 0, 0.65); } /* dims the page behind the menu */
.nav.open .mobile-menu { display: flex; }
.mobile-menu a:not(.btn) {
  text-align: center; text-decoration: none; font-weight: 600; font-size: 18px;
  padding: 15px; border-radius: var(--pill); background: var(--surface-2);
  transition: background .15s;
}
.mobile-menu a:not(.btn):hover, .mobile-menu a:not(.btn):active { background: #242424; }
.mobile-menu .menu-actions { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; padding-top: 16px; border-top: 1px solid var(--border); }
.mobile-menu .btn { width: 100%; padding: 16px; font-size: 18px; }
html.menu-open { overflow: hidden; }

/* The full desktop menu needs about 1,100 px for the landing page's seven links and the button;
   below that the menu button is used, so labels never wrap onto two lines. */
.nav-links a, .nav-cta { white-space: nowrap; }
@media (min-width: 1140px) {
  .nav-links, .nav-cta { display: flex; }
  .menu-btn, .mobile-menu, .nav.open .mobile-menu { display: none; }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 15px 28px; border-radius: var(--pill); border: 1px solid transparent;
  font-weight: 600; font-size: 17px; text-decoration: none; cursor: pointer;
  transition: transform .15s ease, background .15s, border-color .15s, opacity .15s;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn[disabled] { opacity: 0.45; cursor: not-allowed; transform: none; }
.btn svg { width: 18px; height: 18px; }
.btn-orange { background: var(--orange); color: #111; }
.btn-blue { background: var(--blue); color: #061019; }
.btn-white { background: var(--text); color: #111; }
.btn-ghost { background: transparent; border-color: var(--border-2); color: var(--text); }
.btn-ghost:hover { border-color: var(--muted); }
.btn-sm { padding: 10px 18px; font-size: 15px; }
.btn-lg { padding: 18px 40px; font-size: 19px; }

/* ---------- type ---------- */
.display {
  font-family: var(--display); font-weight: 800; letter-spacing: -0.035em; line-height: 0.95;
  margin: 0;
}
h1, h2, h3 { font-family: var(--display); font-weight: 800; letter-spacing: -0.03em; margin: 0; }
h2 { font-size: clamp(38px, 6.4vw, 72px); line-height: 1; }
h3 { font-size: clamp(22px, 2.6vw, 28px); line-height: 1.15; letter-spacing: -0.02em; }
.lede { color: var(--muted); font-size: clamp(17px, 1.6vw, 20px); line-height: 1.75; max-width: 62ch; }
.lede strong { color: var(--text); font-weight: 600; }
.dim { color: var(--muted); }
.faint { color: var(--faint); }

.label {
  display: inline-block; font-family: var(--mono); font-size: 14px; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--orange); margin-bottom: 22px;
}
.label::before { content: "[ "; }
.label::after { content: " ]"; }

.stamp {
  display: inline-block; color: #050505; padding: 0.02em 0.18em 0.08em;
  transform: rotate(-4deg); line-height: 1; white-space: nowrap;
}
.stamp-blue { background: var(--blue); }
.stamp-orange { background: var(--orange); transform: rotate(3deg); }
.grey { color: #9a9a9a; }

.hl { padding: 0 2px; font-weight: 600; color: var(--text); }
.hl-o { background: linear-gradient(transparent 58%, rgba(194, 65, 12, 0.9) 58%); }
.hl-b { background: linear-gradient(transparent 58%, rgba(29, 110, 180, 0.9) 58%); }
.u { text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 6px; font-weight: 600; color: var(--text); }

.swatches { display: flex; gap: 8px; margin: 28px 0; }
.swatches i { display: block; width: 74px; height: 40px; border-radius: 10px; }

/* ---------- sections ---------- */
section { padding: clamp(80px, 11vw, 140px) 0; }
header[data-nav] { position: sticky; top: 0; z-index: 50; height: 0; overflow: visible; }
header[data-nav] + main, header[data-nav] + .app-shell { padding-top: 96px; }
header[data-nav] + main > .hero:first-child { margin-top: -96px; }
.section-head { max-width: 860px; margin-bottom: clamp(40px, 6vw, 64px); }
.section-head .lede { margin-top: 24px; }

/* hero */
.hero { padding: calc(96px + clamp(70px, 12vw, 150px)) 0 clamp(70px, 10vw, 120px); text-align: center; overflow: hidden; }
.hero .display { font-size: clamp(64px, 13vw, 168px); }
.hero .display .line { display: block; }
.hero .display .stamp { font-size: 0.78em; margin-top: 0.08em; }
.hero .lede { margin: 40px auto 0; text-align: center; }
.hero-cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-top: 40px; }
.hero-facts {
  list-style: none; padding: 0; margin: 40px 0 0; display: flex; flex-wrap: wrap;
  justify-content: center; gap: 12px 30px; color: var(--muted); font-size: 16px;
}
.hero-facts li { display: inline-flex; align-items: center; gap: 10px; }
.hero-facts svg { width: 20px; height: 20px; color: var(--text); }

/* problem */
.problem .display { font-size: clamp(44px, 7.4vw, 92px); line-height: 1; }
.problem .display .stamp { margin: 0.06em 0; }

/* steps */
.steps { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 720px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1080px) { .steps { grid-template-columns: repeat(4, 1fr); } }
.step {
  position: relative; padding: 30px 26px 28px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--border); overflow: hidden;
}
.step .n {
  font-family: var(--display); font-weight: 800; font-size: 72px; line-height: 1;
  letter-spacing: -0.05em; color: #262626;
}
.step h3 { margin: 18px 0 10px; }
.step p { margin: 0; color: var(--muted); font-size: 16px; }
.step .who {
  display: inline-block; margin-top: 18px; font-family: var(--mono); font-size: 12px;
  letter-spacing: 0.1em; text-transform: uppercase; padding: 6px 10px; border-radius: 8px;
}
.who-kite { background: rgba(249, 115, 22, 0.14); color: var(--orange); }
.who-serv { background: rgba(29, 155, 240, 0.14); color: var(--blue-soft); }
.who-code { background: rgba(246, 246, 244, 0.1); color: var(--text); }
.step-bar { position: absolute; left: 0; top: 0; height: 5px; width: 100%; }

/* roles */
.roles { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 900px) { .roles { grid-template-columns: repeat(3, 1fr); } }
.role {
  border-radius: var(--radius); padding: 30px 26px; color: #0a0a0a; min-height: 100%;
  display: flex; flex-direction: column; gap: 14px;
}
.role h3 { font-size: clamp(30px, 3.4vw, 40px); }
.role .tag { font-family: var(--mono); font-size: 13px; letter-spacing: 0.12em; text-transform: uppercase; opacity: 0.75; }
.role ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-weight: 500; }
.role li { display: flex; gap: 10px; align-items: baseline; }
.role li::before { font-weight: 800; }
.role .can li::before { content: "+"; }
.role .cannot li::before { content: "×"; }
.role .cannot { opacity: 0.72; padding-top: 12px; border-top: 1px solid rgba(0, 0, 0, 0.18); }
.role-serv { background: var(--blue); }
.role-code { background: var(--text); }
.role-kite { background: var(--orange); }

/* not a spending policy */
.versus { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 860px) { .versus { grid-template-columns: 1fr 1fr; } }
.versus-card { border-radius: var(--radius); padding: 30px 28px; display: flex; flex-direction: column; gap: 18px; }
.versus-card .tag { font-family: var(--mono); font-size: 13px; letter-spacing: 0.12em; text-transform: uppercase; }
.versus-card h3 { font-size: clamp(28px, 3.2vw, 38px); }
.versus-card dl { margin: 0; display: grid; gap: 0; }
.versus-card dl div { display: grid; grid-template-columns: 150px 1fr; gap: 12px; padding: 14px 0; border-top: 1px solid; }
.versus-card dt { font-family: var(--mono); font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; padding-top: 3px; }
.versus-card dd { margin: 0; font-weight: 600; }
.versus-policy { background: var(--surface); border: 1px solid var(--border); }
.versus-policy .tag, .versus-policy dt { color: var(--faint); }
.versus-policy dd { color: var(--muted); }
.versus-policy dl div { border-color: var(--border); }
.versus-tare { background: var(--blue); color: #061019; }
.versus-tare .tag, .versus-tare dt { color: rgba(6, 16, 25, 0.7); }
.versus-tare dl div { border-color: rgba(6, 16, 25, 0.2); }
@media (max-width: 520px) { .versus-card dl div { grid-template-columns: 1fr; gap: 4px; } }

/* demo receipts */
.demo { display: grid; gap: 14px; }
.demo-row {
  display: grid; gap: 16px 20px; align-items: center;
  grid-template-columns: 1fr 1fr; padding: 22px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--border);
}
.demo-row .step-n { grid-column: 1 / -1; }
.demo-row .kv:last-child { grid-column: 1 / -1; }
@media (min-width: 1100px) {
  .demo-row { grid-template-columns: 70px 1.3fr 1fr 1fr 1fr 1.2fr; padding: 24px 26px; }
  .demo-row .step-n, .demo-row .kv:last-child { grid-column: auto; }
}
.demo-row .step-n { font-family: var(--display); font-weight: 800; font-size: 40px; color: #2d2d2d; line-height: 1; }
.kv { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.kv span:first-child { font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.kv span:last-child { font-weight: 600; overflow-wrap: anywhere; }
.big-num { font-family: var(--display); font-weight: 800; font-size: 30px; letter-spacing: -0.02em; }

/* status chips */
.chip {
  display: inline-flex; align-items: center; gap: 8px; width: fit-content; white-space: nowrap; flex: none;
  padding: 6px 13px; border-radius: var(--pill); font-weight: 600; font-size: 14px;
  border: 1px solid currentColor;
}
.chip::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.demo-row .chip { white-space: normal; flex: initial; }
.tone-ok { color: var(--ok); }
.tone-bad { color: var(--bad); }
.tone-warn { color: var(--warn); }
.tone-muted { color: var(--muted); }

/* guarantees */
.guarantees { display: grid; gap: 0; grid-template-columns: 1fr; border-top: 1px solid var(--border); }
@media (min-width: 860px) { .guarantees { grid-template-columns: 1fr 1fr; column-gap: 48px; } }
.guarantee { display: grid; grid-template-columns: 56px 1fr; gap: 16px; padding: 28px 0; border-bottom: 1px solid var(--border); }
.guarantee .ico {
  width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center;
  background: var(--surface-2); border: 1px solid var(--border-2);
}
.guarantee .ico svg { width: 26px; height: 26px; }
.guarantee h3 { font-size: 22px; margin-bottom: 6px; }
.guarantee p { margin: 0; color: var(--muted); font-size: 16px; }

/* faq */
.faq { border-top: 1px solid var(--border); max-width: 900px; }
.faq details { border-bottom: 1px solid var(--border); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 20px;
  align-items: center; padding: 28px 0; font-weight: 600; font-size: clamp(19px, 2vw, 22px);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary svg { width: 22px; height: 22px; flex: none; transition: transform .2s; }
.faq details[open] summary svg { transform: rotate(180deg); }
.faq .answer { padding: 0 0 28px; color: var(--muted); max-width: 70ch; }
.faq .answer p { margin: 0 0 14px; }

/* cta band */
.together { text-align: center; }
.together h2 { font-size: clamp(48px, 9vw, 110px); }
.circles { display: flex; justify-content: center; margin: 44px 0 46px; }
.circles i {
  width: clamp(76px, 15vw, 150px); aspect-ratio: 1; border-radius: 50%; margin-left: -22px;
  border: 4px solid var(--bg); display: grid; place-items: center; font-style: normal;
  font-family: var(--display); font-weight: 800; color: #0a0a0a; font-size: clamp(14px, 2vw, 20px);
}
.circles i:first-child { margin-left: 0; }

/* orange band */
.band { background: var(--orange); color: #0a0a0a; }
.band .label { color: #0a0a0a; }
.band h2 { color: #0a0a0a; }
.band .lede { color: rgba(10, 10, 10, 0.78); }
.band .lede strong { color: #0a0a0a; }
.band pre {
  margin: 28px 0 0; background: #0a0a0a; color: var(--text); border-radius: var(--radius-sm);
  padding: 22px 24px; overflow-x: auto; font-size: 15px; line-height: 1.8;
}
.band pre .c { color: var(--faint); }

/* footer */
.footer { padding: 70px 0 0; border-top: 1px solid var(--border); overflow: hidden; }
.footer-grid { display: grid; gap: 40px; grid-template-columns: 1fr; }
@media (min-width: 760px) { .footer-grid { grid-template-columns: 1.5fr 1fr 1fr; } }
.footer h4 { margin: 0 0 16px; font-family: var(--mono); font-size: 12px; letter-spacing: 0.14em; color: var(--faint); text-transform: uppercase; font-weight: 500; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.footer a { text-decoration: none; font-weight: 500; }
.footer a:hover { color: var(--orange); }
.footer .small { color: var(--faint); font-size: 14px; margin-top: 40px; }
.footer-word {
  font-family: var(--display); font-weight: 800; letter-spacing: -0.06em; line-height: 0.8;
  font-size: clamp(120px, 30vw, 380px); margin: 50px 0 -0.12em; white-space: nowrap;
}
.footer-word span { color: var(--orange); }

/* ---------- app (console) ---------- */
.app-main { padding-top: 48px; padding-bottom: 100px; }
.app-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 32px; }
.app-hero {
  display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 18px;
  padding: clamp(26px, 5vw, 44px); margin-bottom: 20px; border-radius: var(--radius);
  border: 1px solid var(--border); overflow: hidden;
}
.app-hero .label { margin-bottom: 14px; }
.app-hero .display { font-size: clamp(42px, 7vw, 72px); line-height: 1.02; }
.app-hero .display .stamp { font-size: 0.8em; }
.app-hero p { margin: 14px 0 0; color: var(--muted); }
.app-main > .label { display: block; margin: 8px 0 14px; }
.app-head h1 { font-size: clamp(40px, 6vw, 64px); line-height: 1; }
.mode {
  display: inline-flex; align-items: center; gap: 10px; padding: 9px 16px; border-radius: var(--pill);
  border: 1px solid var(--border-2); background: var(--surface); font-weight: 600; font-size: 14px;
}
.mode .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--faint); }
.mode.live .dot { background: var(--ok); box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.2); }
.mode.published .dot { background: var(--blue); }

.notice {
  display: flex; gap: 14px; align-items: flex-start; padding: 18px 20px; margin-bottom: 28px;
  border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border-2);
  color: var(--muted); font-size: 15px;
}
.notice svg { width: 22px; height: 22px; flex: none; color: var(--blue); margin-top: 2px; }
.notice strong { color: var(--text); }

.stats { display: grid; gap: 12px; grid-template-columns: repeat(2, 1fr); margin-bottom: 28px; }
@media (min-width: 860px) { .stats { grid-template-columns: repeat(4, 1fr); } }
.stat { position: relative; overflow: hidden; padding: 22px 20px 18px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); }
.stat::before { content: ""; position: absolute; left: 0; top: 0; right: 0; height: 4px; }
.stat-kpass::before { background: var(--orange); }
.stat-receipts::before { background: var(--text); }
.stat-held::before { background: var(--orange-deep); }
.stat-disputes::before { background: var(--blue); }
.stat .k { font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.stat .v { font-family: var(--display); font-weight: 800; font-size: 40px; line-height: 1.1; letter-spacing: -0.03em; }
.stat .s { font-size: 13px; color: var(--muted); }

.sellers { display: grid; gap: 14px; grid-template-columns: 1fr; margin-bottom: 40px; }
@media (min-width: 860px) { .sellers { grid-template-columns: 1fr 1fr; } }
.seller {
  position: relative; overflow: hidden;
  padding: 24px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 14px;
}
.seller-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.seller-name { font-family: var(--display); font-weight: 800; font-size: 28px; letter-spacing: -0.02em; }
.seller .origin { font-family: var(--mono); font-size: 13px; color: var(--muted); overflow-wrap: anywhere; }
.seller .prose { margin: 0; padding: 14px 16px; border-radius: 12px; background: var(--bg-2); border: 1px dashed var(--border-2); color: var(--muted); font-size: 15px; }
.seller .prose::before { content: "promise: "; font-family: var(--mono); font-size: 12px; color: var(--faint); }
.seller-actions { display: flex; gap: 10px 14px; flex-wrap: wrap; align-items: center; }
.seller::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 5px; }
.seller-a::before { background: var(--orange); }
.seller-b::before { background: var(--blue); }
.seller .price { font-size: 13px; }
.seller .local-note { margin: 0; font-size: 14px; color: var(--muted); display: flex; gap: 8px; align-items: center; }
.seller .local-note svg { width: 16px; height: 16px; flex: none; }
@media (max-width: 859px) {
  .seller-actions .btn { width: 100%; }
  .seller .price { width: 100%; text-align: center; }
}

/* sellers page */
.seller.profile { gap: 16px; }
.record-banner { display: flex; flex-direction: column; gap: 2px; padding: 14px 16px; border-radius: 14px; font-size: 15px; }
.record-banner strong { font-weight: 700; }
.record-banner span { color: var(--muted); }
.record-banner a { color: var(--text); font-weight: 600; text-underline-offset: 3px; }
.record-banner.ok { background: rgba(34, 197, 94, 0.1); border: 1px solid rgba(34, 197, 94, 0.35); }
.record-banner.ok strong { color: var(--ok); }
.record-banner.bad { background: rgba(249, 115, 22, 0.1); border: 1px solid rgba(249, 115, 22, 0.4); }
.record-banner.bad strong { color: var(--orange); }
.record-banner.tone-muted-bg { background: var(--bg-2); border: 1px dashed var(--border-2); }
.track { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.track .t { display: flex; flex-direction: column; align-items: center; padding: 12px 6px; border-radius: 12px; background: var(--bg-2); border: 1px solid var(--border); }
.track .n { font-family: var(--display); font-weight: 800; font-size: 30px; line-height: 1.05; }
.track .l { font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--faint); }
.track .t-ok .n { color: var(--ok); }
.track .t-bad .n { color: var(--orange); }
.track .t-muted .n { color: var(--muted); }
.track .t-zero .n { color: #3d3d3a; }
.last-check { display: flex; flex-direction: column; gap: 4px; padding: 14px 16px; border-radius: 14px; border: 1px solid var(--border); text-decoration: none; color: inherit; transition: border-color .15s, background .15s; }
a.last-check:hover, a.last-check:active { border-color: var(--border-2); background: var(--surface-2); }
.last-check .k { font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.lc-nums { display: flex; align-items: center; gap: 12px; }
.lc-nums .big { font-family: var(--display); font-weight: 800; font-size: 38px; line-height: 1.05; letter-spacing: -0.03em; }
.lc-nums .arrow { color: var(--faint); font-size: 24px; }
.last-check .sub { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
.last-check .sub .chip { padding: 3px 10px; font-size: 13px; }
.conn { border-top: 1px solid var(--border); padding-top: 4px; }
.conn summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; padding: 10px 0; font-weight: 600; font-size: 15px; color: var(--muted); }
.conn summary::-webkit-details-marker { display: none; }
.conn summary svg { width: 18px; height: 18px; transition: transform .2s; }
.conn[open] summary svg { transform: rotate(180deg); }
.conn .facts { padding: 6px 0 4px; }
.setup { display: grid; gap: 12px; grid-template-columns: 1fr; margin-top: 4px; }
@media (min-width: 860px) { .setup { grid-template-columns: repeat(3, 1fr); } }
.setup-item { display: flex; gap: 14px; padding: 18px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); }
.setup-item .ico { width: 44px; height: 44px; flex: none; display: grid; place-items: center; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--border-2); }
.setup-item .ico svg { width: 22px; height: 22px; }
.setup-item strong { display: block; margin-bottom: 4px; }
.setup-item p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.55; }

/* receipt cards (mobile; always for the preview) */
.rcards { display: grid; gap: 12px; }
.rcard {
  position: relative; display: flex; flex-direction: column; gap: 14px; overflow: hidden;
  padding: 20px 20px 18px 24px; border-radius: var(--radius); background: var(--surface);
  border: 1px solid var(--border); text-decoration: none; color: inherit; transition: border-color .15s, background .15s;
}
a.rcard:hover, a.rcard:active { border-color: var(--border-2); background: var(--surface-2); }
.rcard::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 5px; background: var(--faint); }
.rcard.bar-ok::before { background: var(--ok); }
.rcard.bar-bad::before { background: var(--orange); }
.rcard.bar-warn::before { background: var(--warn); }
.rcard-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.rcard-seller { font-family: var(--display); font-weight: 800; font-size: 24px; letter-spacing: -0.02em; }
.rcard-nums { display: flex; align-items: flex-start; gap: 16px; }
.rcard-nums > div { display: flex; flex-direction: column; }
.rcard .k { font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.rcard .big { font-family: var(--display); font-weight: 800; font-size: 44px; line-height: 1; letter-spacing: -0.03em; }
.rcard .sub { font-size: 13px; color: var(--muted); margin-top: 4px; }
.rcard-arrow { font-size: 28px; line-height: 1; color: var(--faint); padding-top: 26px; }
.rcard-note { margin: 0; color: var(--muted); font-size: 15px; }
.rcard-foot { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding-top: 14px; border-top: 1px solid var(--border); font-size: 14px; }
.rcard-foot > div { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.rcard.is-preview { border-style: dashed; }
.preview-head { margin-bottom: 14px; }
.preview-head h3 { margin-bottom: 6px; }
.preview-head p { margin: 0; color: var(--muted); font-size: 15px; max-width: 60ch; }
@media (min-width: 860px) {
  .rcards:not(.always) { display: none; }
  .rcards.always { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 859px) { .desktop-only { display: none; } }

.table-wrap { border-radius: var(--radius); border: 1px solid var(--border); overflow: hidden; background: var(--surface); }
table.receipts { width: 100%; border-collapse: collapse; font-size: 15px; }
.receipts th {
  text-align: left; font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--faint); font-weight: 500; padding: 16px 18px; border-bottom: 1px solid var(--border); background: var(--bg-2);
}
.receipts td { padding: 18px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.receipts tr:last-child td { border-bottom: 0; }
.receipts tbody tr { transition: background .15s; }
.receipts tbody tr:hover { background: var(--surface-2); }
.receipts a.row-link { text-decoration: none; font-weight: 600; }
.receipts a.row-link:hover { color: var(--orange); }
.hash { font-family: var(--mono); font-size: 13px; overflow-wrap: anywhere; }
@media (min-width: 860px) {
  .receipts td .hash { white-space: nowrap; }
  .receipts td .faint.hash { display: block; max-width: 230px; overflow: hidden; text-overflow: ellipsis; }
  .receipts td[data-k="Seller record"] { white-space: nowrap; }
}
.num { font-family: var(--display); font-weight: 800; font-size: 20px; }
.failed-list { display: flex; flex-wrap: wrap; gap: 6px; }
.rule-tag { font-family: var(--mono); font-size: 12px; padding: 3px 8px; border-radius: 6px; background: rgba(249, 115, 22, 0.14); color: var(--orange); }


.empty { padding: 56px 24px; text-align: center; color: var(--muted); }
.empty.card { padding: 48px 24px; }
.empty h3 { color: var(--text); margin-bottom: 10px; }

.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 140%); z-index: 80;
  width: min(560px, calc(100% - 32px)); padding: 16px 20px; border-radius: var(--radius-sm);
  background: var(--surface-2); border: 1px solid var(--border-2); box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
  transition: transform .25s ease; font-size: 15px;
}
.toast.show { transform: translate(-50%, 0); }

/* receipt detail */
.detail-grid { display: grid; gap: 16px; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 960px) { .detail-grid { grid-template-columns: 1.4fr 1fr; } }
.card { padding: 26px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border); }
.card h2 { font-size: 26px; margin-bottom: 18px; letter-spacing: -0.02em; }
.rules { width: 100%; border-collapse: collapse; font-size: 15px; }
.rules th { text-align: left; font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); font-weight: 500; padding: 0 10px 12px 0; }
.rules td { padding: 14px 10px 14px 0; border-top: 1px solid var(--border); vertical-align: top; }
.res { font-weight: 700; }
.res-pass { color: var(--ok); }
.res-fail { color: var(--orange); }
.res-none { color: var(--faint); font-weight: 500; }
dl.facts { margin: 0; display: grid; gap: 16px; }
dl.facts dt { font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
dl.facts dd { margin: 4px 0 0; overflow-wrap: anywhere; }
.copy {
  margin-left: 8px; border: 1px solid var(--border-2); background: transparent; border-radius: 8px;
  font-size: 12px; padding: 2px 8px; cursor: pointer; color: var(--muted);
}
.copy:hover { color: var(--text); }
.verdict-hero { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; margin-bottom: 28px; }
.verdict-hero .display { font-size: clamp(44px, 7vw, 80px); }
.back { display: inline-flex; gap: 8px; align-items: center; color: var(--muted); text-decoration: none; margin-bottom: 26px; font-weight: 500; }
.back:hover { color: var(--text); }
.back svg { width: 18px; height: 18px; }

/* docs */
.docs { display: grid; gap: 40px; grid-template-columns: 1fr; padding-top: 48px; padding-bottom: 100px; }
@media (min-width: 980px) { .docs { grid-template-columns: 240px 1fr; } }
.toc { position: sticky; top: 110px; align-self: start; display: none; }
@media (min-width: 980px) { .toc { display: block; } }
.toc a { display: block; text-decoration: none; color: var(--muted); padding: 7px 0; font-weight: 500; }
.toc a:hover { color: var(--text); }
.prose-doc { max-width: 780px; min-width: 0; }
.prose-doc h1 { font-size: clamp(44px, 6vw, 68px); line-height: 1; margin-bottom: 20px; }
.prose-doc h2 { font-size: clamp(30px, 3.6vw, 40px); margin: 64px 0 16px; padding-top: 8px; }
.prose-doc p, .prose-doc li { color: #c9c9c5; }
.prose-doc pre {
  background: var(--bg-2); border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 18px 20px; overflow-x: auto; line-height: 1.75; color: var(--text);
}
.prose-doc :not(pre) > code { background: var(--surface-2); padding: 2px 6px; border-radius: 6px; color: var(--text); }
.prose-doc table { width: 100%; border-collapse: collapse; font-size: 15px; }
.prose-doc th, .prose-doc td { text-align: left; padding: 12px 14px 12px 0; border-bottom: 1px solid var(--border); vertical-align: top; }
.prose-doc th { font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); font-weight: 500; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* check a seller */
.check-form { display: grid; gap: 8px; margin-bottom: 18px; }
.check-form .k { font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.check-row { display: flex; gap: 10px; }
.check-row input {
  flex: 1; min-width: 0; padding: 14px 18px; border-radius: var(--pill); border: 1px solid var(--border-2);
  background: var(--surface); color: var(--text); font: 500 16px var(--mono);
}
.check-row input:focus { outline: 2px solid var(--blue); outline-offset: 2px; }
.check-result { display: flex; flex-direction: column; gap: 16px; margin-bottom: 8px; }
.check-result .seller-name { font-size: 18px; overflow-wrap: anywhere; }
.badge-box { display: flex; flex-direction: column; gap: 10px; padding: 14px 16px; border-radius: 14px; border: 1px dashed var(--border-2); }
.badge-box .k { font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.badge-box img { width: auto; }
.badge-box code { font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }
.rec-list { display: grid; gap: 8px; }
.rec-row {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 16px;
  border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); text-decoration: none;
}
.rec-row:hover { border-color: var(--border-2); }
@media (max-width: 520px) { .check-row { flex-direction: column; } .check-row .btn { width: 100%; } }

/* the promise, word for word */
.promise-card { margin-bottom: 16px; }
.promise { margin: 0 0 14px; }
.promise figcaption { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; margin-bottom: 8px; }
.promise figcaption .k { font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--orange); }
.promise figcaption .faint { font-size: 13px; }
.promise blockquote, .promise-inline {
  margin: 0; padding: 14px 18px; border-left: 4px solid var(--orange); border-radius: 0 12px 12px 0;
  background: var(--bg-2); font-size: 17px; line-height: 1.5; color: var(--text);
}
.promise-inline { font-size: 15px; margin-bottom: 12px; }

/* one-line punchline under a lede */
.lede.punch { margin-top: 18px; font-size: clamp(19px, 2vw, 24px); line-height: 1.4; }

/* receipt notes: how the receipt was read */
ul.notes { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; }
ul.notes li { line-height: 1.5; overflow-wrap: anywhere; }
ul.notes .k { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-right: 6px; }

/* docs: code wraps only when it would overflow its line (identifiers stay whole); hashes may break
   anywhere. Section headings clear the sticky header when reached from a link. */
.prose-doc code { overflow-wrap: break-word; word-break: normal; }
.prose-doc .hash { overflow-wrap: anywhere; }
.prose-doc h2[id] { scroll-margin-top: 120px; }

/* docs tables on phones: each row becomes a card; the first cell is its title, every other cell
   carries its column name (data-label) above it. */
@media (max-width: 720px) {
  .doc-table, .doc-table tbody, .doc-table tr, .doc-table td { display: block; width: 100%; }
  .doc-table thead { display: none; }
  .doc-table tr { padding: 14px 0; border-bottom: 1px solid var(--border); }
  .doc-table td { padding: 0; border: 0; }
  .doc-table td + td { margin-top: 8px; }
  .doc-table td:first-child { font-weight: 600; color: var(--text); }
  .doc-table td:first-child code { white-space: normal; overflow-wrap: anywhere; }
  .doc-table td[data-label]:not(:first-child):not([data-label=""])::before {
    content: attr(data-label); display: block; margin-bottom: 2px;
    font-family: var(--mono); font-size: 11px; letter-spacing: .08em;
    text-transform: uppercase; color: var(--muted);
  }
}

/* docs: the long table of contents scrolls on desktop; phones get a collapsible menu instead */
.toc { max-height: calc(100vh - 140px); overflow-y: auto; }
.toc-mobile { margin: 8px 0 28px; border: 1px solid var(--border); border-radius: 14px; padding: 4px 16px; }
.toc-mobile summary { cursor: pointer; padding: 12px 0; font-weight: 600; }
.toc-mobile nav { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 16px; padding: 0 0 14px; }
.toc-mobile a { color: var(--muted); text-decoration: none; padding: 6px 0; }
.toc-mobile a:hover { color: var(--text); }
@media (min-width: 980px) { .toc-mobile { display: none; } }
/* short names in a docs table's first column never break at "-" or ":" on wide screens */
@media (min-width: 721px) { .prose-doc code.nw { white-space: nowrap; } }
/* narrow phones: code blocks scroll inside themselves, and grid children may shrink below their content */
pre { max-width: 100%; }
.band .wrap, .detail-grid > * { min-width: 0; }

/* SERV's plain-English dispute explanation */
.explain-card { border-color: rgba(29, 155, 240, .35); margin-bottom: 16px; }
.explain { font-size: 19px; line-height: 1.6; color: var(--text); max-width: 75ch; }
.explain-note { font-size: 13px; margin-top: 12px; }
.explain-inline { font-size: 15px; margin: 0 0 12px; }
