@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap");

/* Wild West API account pages: sign-in, dashboard and playground. The same
   quiet system as ww.css: one sans, thin rules, one accent, light and dark by
   the visitor's own setting. Loaded last in <head>, so these win. */
:root {
  --bg: #ffffff;
  --surface: #f7f7f8;
  --chip: #f0f0f2;
  --chip-hover: #e8e8ec;
  --ink: #111113;
  --muted: #5f5f67;
  --faint: #8a8a93;
  --line: #e6e6ea;
  --line-soft: #efeff2;
  --accent: #c2410c;
  --accent-ink: #ffffff;
  --accent-soft: #fff1ea;
  --link: #111113;
  --good: #1f8a55;
  --good-soft: #e8f6ee;
  --bad: #c0392b;
  --code-bg: #f6f6f7;
  --wwx: #111113;
  --wwx-btn: #111113;
  --foot-bg: #ffffff;
  --foot-ink: #111113;
  --radius: 8px;
  --pill: 8px;
  --sans: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --display: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --sb-bg: #f7f7f8;
  --sb-edge: #e6e6ea;
  --sb-hover: #ececef;
  --sb-ink: #111113;
  --main-bg: #ffffff;
  --panel: #ffffff;
  --hot: #111113;
  --field: #ffffff;
  --field-line: #d6d6dc;
  --btn-bg: #111113;
  --btn-ink: #ffffff;
  color-scheme: light;
}
html.in-app, html.in-app:root {
  --main-bg: #ffffff; --panel: #ffffff; --surface: #f7f7f8;
  --chip: #f0f0f2; --chip-hover: #e8e8ec; --line: #e6e6ea;
  --sb-bg: #f7f7f8; --sb-edge: #e6e6ea; --sb-hover: #ececef;
}
html:has(#dash:not(.hide)) { --dash-bg: #ffffff; --dash-rail: #f7f7f8; --dash-panel: #ffffff; --dash-panel-2: #f7f7f8; --dash-edge: #e6e6ea; --dash-line: #e6e6ea; }

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0d0d0f; --surface: #141417; --chip: #1b1b1f; --chip-hover: #232328;
    --ink: #ededf0; --muted: #a0a0a8; --faint: #7a7a83;
    --line: #26262b; --line-soft: #1b1b1f;
    --accent: #f08a4b; --accent-ink: #0d0d0f; --accent-soft: #2a1a11;
    --link: #ededf0; --good: #5cc98e; --good-soft: #10241a; --bad: #ff7b6e;
    --code-bg: #141417; --wwx: #ededf0; --wwx-btn: #ededf0;
    --foot-bg: #0d0d0f; --foot-ink: #ededf0;
    --sb-bg: #111114; --sb-edge: #26262b; --sb-hover: #1b1b1f; --sb-ink: #ededf0;
    --main-bg: #0d0d0f; --panel: #141417;
    --hot: #ededf0; --field: #141417; --field-line: #34343a;
    --btn-bg: #ededf0; --btn-ink: #0d0d0f;
    color-scheme: dark;
  }
  html.in-app, html.in-app:root {
    --main-bg: #0d0d0f; --panel: #141417; --surface: #141417;
    --chip: #1b1b1f; --chip-hover: #232328; --line: #26262b;
    --sb-bg: #111114; --sb-edge: #26262b; --sb-hover: #1b1b1f;
  }
  html:has(#dash:not(.hide)) { --dash-bg: #0d0d0f; --dash-rail: #111114; --dash-panel: #141417; --dash-panel-2: #1b1b1f; --dash-edge: #26262b; --dash-line: #26262b; }
}

html, body { background: var(--bg); color: var(--ink); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
html:has(#dash:not(.hide)) body, html:has(#dash:not(.hide)) .sheet { background: var(--dash-bg); }
::selection { background: var(--accent-soft); }

/* The mark, swapped in by the script. */
svg.mark-svg { visibility: hidden; }
.ww-mk { display: block; flex: none; color: var(--ink); }
.ww-mk .ww-hole { fill: var(--bg); }

/* Type: one face, plain weights, no posters. */
h1, h2, h3, h4, .logo, .rail-logo, .co-brand, .intro-name, .choose-h { font-family: var(--sans) !important; letter-spacing: -0.02em !important; }
h1, .auth-card h1, .gate h1, .intro-name { font-weight: 600 !important; }
.auth-card h1, .gate h1 { font-size: 26px !important; line-height: 1.2 !important; }
.intro-name { font-size: clamp(26px, 3.6vw, 36px) !important; line-height: 1.15 !important; }
.logo { font-size: 15px; font-weight: 600 !important; gap: 9px; }

/* Nothing that belongs to the other storefront, and no sign-in but the emailed code. */
footer.ed-foot, .foot-spacer, #oauth, #orEmail, .oauth-btn, .gs-sec, .rate,
a[href^="/guides"], a[href^="/for/"], a[href^="/compare"], a[href^="/learn"], a[href^="/plans"], a[href^="/blog"], a[href^="/alternatives/"], a[href="/llms.txt"] { display: none !important; }
html.reveal footer.site-foot { display: none !important; }

/* The word that glowed is plain accent type: no gradient, no motion. */
.xpl { background: none !important; color: var(--accent) !important; -webkit-text-fill-color: var(--accent) !important; filter: none !important; animation: none !important; }
.typing { filter: grayscale(1); }

/* Buttons: solid ink, small radius, no gradients or glow. */
.btn, .auth-card .btn, .signin .signin-card .btn, .dash-main .btn:not(.ghost):not(.danger), .bug-send,
.send, .composer-row .send:not(:disabled):not(.stop) {
  background: var(--btn-bg) !important; color: var(--btn-ink) !important; border: 1px solid var(--btn-bg) !important;
  box-shadow: none !important; border-radius: 8px !important; font-family: var(--sans) !important; font-weight: 500 !important;
}
.btn:hover, .auth-card .btn:hover, .dash-main .btn:not(.ghost):hover, .composer-row .send:not(:disabled):not(.stop):hover { opacity: .88; }
.btn.ghost, .dash-main .btn.ghost { background: transparent !important; color: var(--ink) !important; border: 1px solid var(--line) !important; }
.btn.danger { border-radius: 8px !important; }
.avatar { background: var(--chip) !important; color: var(--ink) !important; }
.rail-nav .tab[aria-current] { color: var(--ink); background: var(--chip); }

/* Fields and cards: thin borders, small corners. */
input, select, textarea { font-family: var(--sans); }
.auth-card input[type="email"], .otp input, .dash-main input, .dash-main select { border-radius: 8px !important; }
.auth-card input[type="email"]:focus, .otp input:focus, .composer:focus-within {
  border-color: var(--accent) !important; box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 16%, transparent) !important;
}
.otp input { caret-color: var(--accent); }
.auth-mark .ww-mk { width: 36px; height: 36px; }
.card, .dash-main .card { border-radius: 8px; border: 1px solid var(--line); background: var(--dash-panel, var(--surface)); box-shadow: none; }
.composer { border-radius: 12px !important; }
.md .md-code .tok-k { color: var(--accent); }

/* The connect card the skin adds to Get Started. */
.ww-connect { border: 1px solid var(--line); border-radius: 8px; background: var(--dash-panel, var(--surface)); padding: 20px; margin: 20px 0 0; }
.ww-connect h4 { font-weight: 600; font-size: 16px; margin: 0 0 8px; }
.ww-connect p { color: var(--muted); margin: 0 0 12px; }
.ww-connect ol { margin: 0 0 12px; padding-left: 1.2em; color: var(--ink); }
.ww-connect li { margin: 0 0 6px; }
.ww-connect code { font-family: var(--mono); background: var(--chip); border-radius: 4px; padding: 1px 6px; overflow-wrap: anywhere; }
.ww-connect a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }

/* The refund line on the dashboard. */
.ww-refund { border: 1px solid var(--line); border-radius: 8px; background: var(--surface); padding: 12px 14px; margin: 16px 0 0; font-size: 14px; color: var(--muted); }
.ww-refund strong { color: var(--ink); font-weight: 600; }
.ww-refund a { color: var(--ink); }

/* A small footer for the signed-out pages. */
.ww-foot { border-top: 1px solid var(--line); padding: 20px 16px 26px; text-align: center; font: 400 13px/1.6 var(--sans); color: var(--faint); }
.ww-foot a { color: var(--muted); margin: 0 8px; }

/* The dashboard's own fixed dark greys, mapped onto this palette. */
.rail-nav .tab, .rail-foot, .rail-menu a, .rail-menu button, .gs-ic svg, .topup-presets button, .co-back { color: var(--muted) !important; }
.rail-nav .tab:hover, .rail-menu a:hover, .rail-menu button:hover { color: var(--ink) !important; background: var(--chip) !important; }
.rail-nav .tab[aria-current], .rail-more:hover, .tip .r .tsw, .top-row .sw, .co-back:hover { background: var(--chip) !important; color: var(--ink) !important; }
.chart .grid line { stroke: var(--line) !important; }
.credit-bar .track, .top-row .bar, .coin-x { background: var(--chip) !important; }
.sel, .seg { background-color: var(--dash-panel, var(--bg)) !important; color: var(--ink) !important; }
.gs-ic, .gs-ic.logo, .co-bar { background: var(--chip) !important; }
.icon-btn:hover, .dash-main .topup-pay.crypto:not(.solo):hover { background: var(--chip-hover) !important; color: var(--ink) !important; }
.seg button[aria-pressed="true"] { background: var(--bg) !important; color: var(--ink) !important; box-shadow: 0 0 0 1px var(--line) !important; }
.credit-bar .track i { background: var(--ink) !important; }
.credit-bar .track i + i { background: var(--faint) !important; }
.credit-bar .dot { background: var(--ink) !important; }
.credit-bar .legend span + span .dot { background: var(--faint) !important; }
.heat .c, .heat-legend .c { background: var(--chip) !important; }
.heat .c.l1, .heat-legend .c.l1 { background: color-mix(in srgb, var(--accent) 25%, var(--bg)) !important; }
.heat .c.l2, .heat-legend .c.l2 { background: color-mix(in srgb, var(--accent) 50%, var(--bg)) !important; }
.heat .c.l3, .heat-legend .c.l3 { background: color-mix(in srgb, var(--accent) 75%, var(--bg)) !important; }
.heat .c.l4, .heat-legend .c.l4 { background: var(--accent) !important; }
.tip, .rail-menu { background: var(--bg) !important; border-color: var(--line) !important; color: var(--ink); box-shadow: 0 8px 30px rgba(0, 0, 0, .12) !important; }
.tip .t { border-color: var(--line) !important; }

/* Out of credit in the playground: a plain card, not red text. */
.msg-error.ww-credit { display: block !important; color: var(--ink) !important; background: var(--surface) !important; border: 1px solid var(--line) !important; border-radius: 10px !important; padding: 16px 18px !important; max-width: 460px; font: 400 14px/1.5 var(--sans) !important; }
.ww-credit strong { display: block; font-size: 15px; font-weight: 600; margin: 0 0 4px; }
.ww-credit p { margin: 0 0 10px; color: var(--muted); }
.ww-credit .ww-bal { color: var(--ink); font-variant-numeric: tabular-nums; }
.ww-credit .btn { display: inline-flex; padding: 9px 14px !important; text-decoration: none; }

/* Playground settings: system prompt, temperature, max tokens. */
.ww-pg-toggle { position: fixed; top: 10px; right: 14px; z-index: 60; font: 500 13px/1 var(--sans); color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 8px 11px; cursor: pointer; }
.ww-pg-toggle:hover { background: var(--chip); }
.ww-pg { position: fixed; top: 48px; right: 14px; z-index: 60; width: min(340px, calc(100vw - 28px)); background: var(--bg); color: var(--ink); border: 1px solid var(--line); border-radius: 10px; padding: 16px; box-shadow: 0 8px 30px rgba(0, 0, 0, .12); font: 400 14px/1.5 var(--sans); }
.ww-pg[hidden] { display: none; }
.ww-pg h3 { margin: 0 0 10px; font-size: 14px; font-weight: 600; }
.ww-pg label { display: block; font-size: 12px; color: var(--muted); margin: 10px 0 4px; }
.ww-pg textarea, .ww-pg input[type="number"] { width: 100%; box-sizing: border-box; font: 400 13px/1.45 var(--sans); color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; }
.ww-pg textarea { min-height: 96px; resize: vertical; }
.ww-pg .row { display: flex; align-items: center; gap: 10px; }
.ww-pg input[type="range"] { flex: 1; accent-color: var(--accent); }
.ww-pg output { min-width: 2.6em; text-align: right; font-variant-numeric: tabular-nums; }
.ww-pg .note { font-size: 12px; color: var(--faint); margin: 10px 0 0; }
.ww-pg .reset { margin-top: 10px; font: 500 12px/1 var(--sans); background: none; border: 1px solid var(--line); border-radius: 6px; color: var(--muted); padding: 6px 9px; cursor: pointer; }
@media (max-width: 760px) { .ww-pg-toggle { top: auto; bottom: 86px; } .ww-pg { top: auto; bottom: 126px; } }
