/* Orbitle AI studio — Orbitle palette: monochrome space + the venture's
   spectral accent. Orbitle AI is LIGHT YELLOW (~575nm) in the Orbitle spectrum
   (games red → games-AI orange → MCP yellow → web green → web-AI blue →
   cloud violet; the Orbitle org is white light).
   Professional voice: Starlink / Cursor / Claude.
   Dark is the default; html[data-theme="light"] flips every var below (the
   toggle in the top bar / auth gate sets it and persists in localStorage). */
:root {
  --bg: #050507;
  --bg2: #0a0b0d;
  --panel: rgba(14, 15, 18, .72);
  --panel2: rgba(8, 9, 11, .85);
  --line: rgba(255, 255, 255, .08);
  --line-strong: rgba(255, 255, 255, .16);
  --text: #f5f7fa;
  --muted: #9aa1ab;
  --accent: #fff06e;
  --accent-deep: #e9da55;
  --ok: #6fe08a;
  --danger: #ff5c49;
  --shadow: 0 12px 40px rgba(0, 0, 0, .4);
  /* CTA = the Starlink signature button (white-on-black in dark, inverted in light) */
  --cta-bg: #ffffff;
  --cta-text: #0a0a0a;
  --cta-hover: #e2e5ea;
  --well: rgba(0, 0, 0, .35);           /* input / code sunken wells */
  --cube-a: #ffffff;                    /* avatar gradient (Gold now uses the coin svg) */
  --cube-b: #c8ccd2;
  --moon-spot: #ffffff;
  --moon-hi: #fffef2;
  --moon-mid: #fff7b8;
  --moon-deep: #f5e076;
  --moon-edge: #d9bc35;
  --moon-glow: #fff29d;
  --moon-rim: #ffe988;
  --font-display: 'Geist', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;
  --font-mono: 'Azeret Mono', ui-monospace, monospace; /* truly plain zero — Roboto Mono slashes it */
  color-scheme: dark;
}

/* The white side of the toggle — same monochrome voice, inverted. */
html[data-theme="light"] {
  --bg: #ffffff;
  --bg2: #f5f6f8;
  --panel: rgba(244, 245, 247, .72);
  --panel2: rgba(233, 235, 239, .85);
  --line: rgba(0, 0, 0, .1);
  --line-strong: rgba(0, 0, 0, .2);
  --text: #0a0b0d;
  --muted: #5c6470;
  --accent: #948300;
  --accent-deep: #7a6c00;
  --ok: #157f3d;
  --danger: #d92d20;
  --shadow: 0 12px 40px rgba(0, 0, 0, .12);
  --cta-bg: #0a0b0d;
  --cta-text: #ffffff;
  --cta-hover: #26282e;
  --well: rgba(0, 0, 0, .05);
  --cube-a: #26282e;
  --cube-b: #5c6470;
  --moon-spot: #8f7414;
  --moon-hi: #8f7414;
  --moon-mid: #8f7414;
  --moon-deep: #8f7414;
  --moon-edge: #8f7414;
  --moon-glow: #8f7414;
  --moon-rim: #8f7414;
  color-scheme: light;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  min-height: 100vh;
  padding-bottom: 60px;
  -webkit-font-smoothing: antialiased;
}
#stars { position: fixed; inset: 0; z-index: -2; }
.aurora {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(640px 380px at 50% -8%, color-mix(in srgb, var(--accent) 9%, transparent), transparent 70%),
    radial-gradient(900px 560px at 50% 115%, color-mix(in srgb, var(--text) 3.5%, transparent), transparent 72%);
}

::selection { background: color-mix(in srgb, var(--accent) 26%, transparent); color: var(--text); }

h1, h2, h3 { font-family: var(--font-display); letter-spacing: -0.01em; }
h2 { margin: 0 0 14px; font-size: 20px; font-weight: 600; color: var(--text); display: flex; align-items: center; gap: 10px; }
h3 {
  margin: 20px 0 8px; font-size: 11px; font-weight: 600; color: var(--muted);
  text-transform: uppercase; letter-spacing: .18em;
}
.mono { font-family: var(--font-mono); font-size: 12px; color: var(--muted); }
.hidden { display: none !important; }

/* ═══ THEME TOGGLE ═══ */
.themebtn {
  display: grid; place-items: center; cursor: pointer;
  width: 40px; height: 40px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--panel); color: var(--muted);
  backdrop-filter: blur(12px); transition: border-color .16s, color .16s;
}
.themebtn:hover { border-color: var(--line-strong); color: var(--text); }
.gatetheme { position: absolute; top: 18px; right: 18px; z-index: 45; }

/* ═══ AUTH GATE ═══ */
.gate {
  position: fixed; inset: 0; z-index: 40; overflow: hidden;
  display: flex; align-items: center; justify-content: center; padding: 20px;
  background: radial-gradient(900px 600px at 50% -10%, color-mix(in srgb, var(--text) 5%, transparent), transparent 65%), var(--bg);
}
.rain { position: absolute; inset: 0; pointer-events: none; }
.rain .drop {
  position: absolute; top: -60px; border-radius: 2px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--text) 50%, transparent), color-mix(in srgb, var(--text) 22%, transparent) 60%, transparent);
  animation: fall linear infinite;
}
@keyframes fall {
  0% { transform: translateY(-8vh); opacity: 0; }
  8% { opacity: .55; }
  92% { opacity: .35; }
  100% { transform: translateY(112vh); opacity: 0; }
}
.gatecard {
  position: relative; width: 400px; max-width: 94vw; text-align: center;
  background: var(--panel); border: 1px solid var(--line); border-radius: 18px;
  padding: 34px 34px 26px; backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  box-shadow: var(--shadow);
}
.gatelogo { width: 104px; height: 104px; }
.gatetitle {
  font-family: var(--font-display); font-size: 32px; font-weight: 700; color: var(--text);
  letter-spacing: .02em; margin-top: 6px;
}
.gatetitle span { color: var(--accent); }
.gatesub { color: var(--muted); font-size: 13px; margin: 6px 0 22px; }
.seg {
  display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px;
  background: var(--panel2); border: 1px solid var(--line); border-radius: 10px;
}
.segbtn {
  font-family: var(--font-body); font-size: 13.5px; font-weight: 600; cursor: pointer;
  padding: 9px 0; border: none; border-radius: 7px; background: transparent; color: var(--muted);
  transition: all .16s;
}
.segbtn.active { background: var(--cta-bg); color: var(--cta-text); }
.gatecard form { text-align: left; }
.autherr {
  margin-top: 12px; font-size: 12.5px; color: var(--danger);
  border: 1px solid color-mix(in srgb, var(--danger) 30%, transparent); background: color-mix(in srgb, var(--danger) 6%, transparent);
  border-radius: 8px; padding: 8px 10px;
}
.gatenote { color: var(--muted); font-size: 12px; margin: 18px 0 0; line-height: 1.6; }
.gatenote b { color: var(--text); font-weight: 600; }

/* "or" divider + Google button (Google's white button stays white in both themes) */
.authdiv {
  display: flex; align-items: center; gap: 12px;
  margin: 16px 0; color: var(--muted); font-size: 11.5px;
  text-transform: uppercase; letter-spacing: .14em;
}
.authdiv::before, .authdiv::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.gbtn {
  display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%;
  font-family: var(--font-body); font-size: 14px; font-weight: 600; cursor: pointer;
  padding: 11px; border-radius: 10px; border: 1px solid var(--line-strong);
  background: #fff; color: #1f2937; text-decoration: none;
  transition: background .14s, transform .12s;
}
.gbtn:hover { background: #e9ecf1; }
.gbtn:active { transform: translateY(1px); }

/* ═══ BRAND (inline SVG voxel SUN — Cloud's sun style — + themed wordmark) ═══ */
.moon-spot { stop-color: var(--moon-spot); }
.moon-hi   { stop-color: var(--moon-hi); }
.moon-mid  { stop-color: var(--moon-mid); }
.moon-deep { stop-color: var(--moon-deep); }
.moon-edge { stop-color: var(--moon-edge); }
.moon-glow { stop-color: var(--moon-glow); }
.moon-spotfill { fill: var(--moon-spot); }
.moon-rim  { stroke: var(--moon-rim); }
.sun-rayfill { fill: var(--moon-deep); }
.sun-raysoft { fill: var(--moon-mid); }
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; }
.brandmark { width: 46px; height: 46px; flex: none; }
.brandtext { display: flex; flex-direction: column; line-height: 1; }
.brandname {
  font-family: var(--font-display); font-size: 21px; font-weight: 700;
  letter-spacing: -0.01em; color: var(--text);
}
.brandsub {
  font-family: var(--font-body); font-size: 9.5px; font-weight: 600;
  letter-spacing: .52em; text-transform: uppercase; color: var(--muted); margin-top: 5px;
}

/* ═══ TOP BAR ═══ */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 26px 8px; gap: 14px; flex-wrap: wrap;
}
.topbar-right { display: flex; gap: 10px; align-items: center; }

.credchip {
  display: inline-flex; align-items: center; gap: 9px; cursor: pointer;
  font-family: var(--font-display); font-size: 15px; font-weight: 700; letter-spacing: -0.01em; color: var(--text);
  padding: 7px 8px 7px 13px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--panel); backdrop-filter: blur(12px);
  transition: border-color .16s;
}
.credchip:hover { border-color: var(--line-strong); }
.credchip .topup {
  font-family: var(--font-body); font-size: 11.5px; font-weight: 600; color: var(--cta-text);
  padding: 4px 10px; border-radius: 999px; background: var(--cta-bg);
}
.credchip .topup:hover { background: var(--cta-hover); }
.cube {
  width: 12px; height: 12px; display: inline-block;
  background: url(/brand/orbitle-gold.svg) center / contain no-repeat;
}
.cube.big { width: 20px; height: 20px; }
.credchip.pulse .cube { animation: pulse .5s; }
@keyframes pulse { 50% { transform: scale(1.45); } }

.usermenu { position: relative; }
.userbtn {
  cursor: pointer; border: 1px solid var(--line); background: var(--panel); border-radius: 999px;
  padding: 4px; display: flex; backdrop-filter: blur(12px);
}
.userbtn:hover { border-color: var(--line-strong); }
.avatar {
  width: 32px; height: 32px; border-radius: 999px; display: grid; place-items: center;
  font-family: var(--font-display); font-weight: 700; font-size: 15px; color: var(--cta-text);
  background: linear-gradient(160deg, var(--cube-a), var(--cube-b));
}
.dropdown {
  position: absolute; right: 0; top: 48px; width: 300px; z-index: 30;
  background: var(--panel2); border: 1px solid var(--line); border-radius: 14px;
  padding: 14px; backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}
.uemail { font-size: 13px; color: var(--text); word-break: break-all; margin-bottom: 12px; }
.ukey { border-top: 1px solid var(--line); padding-top: 12px; margin-bottom: 12px; }
.klabel { font-size: 10px; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); display: block; margin-bottom: 6px; }
.ukey code {
  display: block; font-family: var(--font-mono); font-size: 11px; color: var(--accent); word-break: break-all;
  background: var(--well); border: 1px solid var(--line); border-radius: 7px; padding: 7px 9px;
}
.ukey code.masked { letter-spacing: 2px; color: var(--muted); }
.krow { display: flex; gap: 6px; margin-top: 8px; }

/* ═══ TABS ═══ */
.tabs {
  display: inline-flex; gap: 2px; padding: 4px; margin: 14px 26px;
  background: var(--panel2); border: 1px solid var(--line); border-radius: 999px;
  backdrop-filter: blur(12px); flex-wrap: wrap;
}
.tab {
  font-family: var(--font-body); font-size: 13.5px; font-weight: 500; cursor: pointer;
  padding: 8px 18px; border: none; border-radius: 999px; background: transparent; color: var(--muted);
  transition: all .16s;
}
.tab:hover { color: var(--text); }
.tab.active { background: var(--cta-bg); color: var(--cta-text); font-weight: 600; }

/* ═══ LAYOUT / CARDS ═══ */
main { padding: 6px 26px; max-width: 1200px; margin: 0 auto; }
.panel { display: none; }
.panel.active { display: block; animation: rise .22s ease; }
@keyframes rise { from { opacity: 0; transform: translateY(6px); } }
.cols { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
@media (max-width: 900px) { .cols { grid-template-columns: 1fr; } }

.card {
  background: var(--panel); border: 1px solid var(--line); border-radius: 16px;
  padding: 22px 24px; backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
}
.card.out { min-height: 320px; display: flex; flex-direction: column; justify-content: center; }
.placeholder { color: var(--muted); text-align: center; font-size: 13.5px; line-height: 1.7; }

/* ═══ FORMS ═══ */
label { display: block; font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin: 14px 0 0; }
textarea, input, select {
  width: 100%; margin-top: 6px; font-family: var(--font-body); font-size: 14px;
  color: var(--text); background: var(--well); border: 1px solid var(--line);
  border-radius: 9px; padding: 10px 12px; outline: none; resize: vertical;
  transition: border-color .15s, box-shadow .15s;
}
textarea::placeholder, input::placeholder { color: color-mix(in srgb, var(--muted) 55%, transparent); }
textarea:focus, input:focus, select:focus { border-color: color-mix(in srgb, var(--accent) 55%, transparent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 10%, transparent); }
.row { display: flex; gap: 12px; }
.row label { flex: 1; }
.check { display: flex; align-items: center; gap: 8px; margin-top: 30px; }
.check input { width: auto; margin: 0; }

.go {
  margin-top: 18px; width: 100%; cursor: pointer;
  font-family: var(--font-body); font-size: 14.5px; font-weight: 600;
  padding: 12px; border: none; border-radius: 10px;
  background: var(--cta-bg); color: var(--cta-text);
  transition: background .14s, transform .12s;
}
.go:hover { background: var(--cta-hover); }
.go:active { transform: translateY(1px); }
.go:disabled { background: color-mix(in srgb, var(--cta-bg) 25%, transparent); color: color-mix(in srgb, var(--cta-text) 70%, transparent); cursor: wait; transform: none; }
.hint { font-size: 12px; color: var(--muted); margin: 10px 0 0; line-height: 1.55; }
.hint.center { text-align: center; margin: 10px 0 24px; }

.cost {
  display: inline-flex; align-items: center; gap: 5px;
  font-family: var(--font-display); font-size: 10.5px; font-weight: 500; color: var(--text);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, var(--line)); border-radius: 999px; padding: 2.5px 9px;
  letter-spacing: .04em; white-space: nowrap;
}
.cost::before {
  content: ''; width: 10px; height: 10px; flex: none;
  background: url(/brand/orbitle-gold.svg) center / contain no-repeat;
}
.editrow {
  margin-top: 12px; font-size: 12px; color: var(--accent);
  border: 1px dashed color-mix(in srgb, var(--text) 30%, transparent); border-radius: 8px; padding: 7px 10px;
  display: flex; align-items: center; gap: 8px;
}
.mini {
  font-family: var(--font-body); font-size: 12px; font-weight: 500; cursor: pointer; color: var(--text);
  background: transparent; border: 1px solid var(--line); border-radius: 7px; padding: 4px 10px;
  text-decoration: none; display: inline-flex; align-items: center; gap: 4px;
  transition: all .14s;
}
.mini:hover { border-color: var(--line-strong); }
.mini.wide { width: 100%; justify-content: center; padding: 8px; }

/* ═══ CHIPS ═══ */
.chips { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.chipbtn {
  font-family: var(--font-body); font-size: 12.5px; font-weight: 500; cursor: pointer;
  padding: 6px 13px; border: 1px solid var(--line); border-radius: 999px;
  background: transparent; color: var(--muted); transition: all .14s;
  display: inline-flex; align-items: center; gap: 7px;
}
.chipbtn:hover { color: var(--text); border-color: var(--line-strong); }
.chipbtn.active { background: var(--cta-bg); color: var(--cta-text); border-color: transparent; font-weight: 600; }
.chipbtn.active .cost { color: color-mix(in srgb, var(--cta-text) 70%, transparent); border-color: color-mix(in srgb, var(--cta-text) 25%, transparent); }

/* ═══ RESULTS ═══ */
.result img, .result video { width: 100%; border: 1px solid var(--line); border-radius: 10px; display: block; background: #000; }
.result audio { width: 100%; margin-top: 4px; }
.result .meta { font-size: 12px; color: var(--muted); margin: 10px 0; line-height: 1.6; word-break: break-word; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.busy { text-align: center; color: var(--muted); font-size: 13.5px; line-height: 2; }
.blocks { display: flex; gap: 6px; justify-content: center; margin: 14px 0; }
.blocks span {
  width: 11px; height: 11px; border-radius: 3px;
  background: var(--text); opacity: .8;
  animation: hop 1s infinite;
}
.blocks span:nth-child(2) { animation-delay: .15s; }
.blocks span:nth-child(3) { animation-delay: .3s; }
.blocks span:nth-child(4) { animation-delay: .45s; }
@keyframes hop { 0%, 60%, 100% { transform: translateY(0); opacity: .35; } 30% { transform: translateY(-9px); opacity: .95; } }

/* ═══ LIBRARY ═══ */
.libhead { display: flex; justify-content: space-between; align-items: center; gap: 14px; flex-wrap: wrap; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(235px, 1fr)); gap: 14px; margin-top: 16px; }
.asset {
  background: var(--panel2); border: 1px solid var(--line); border-radius: 12px;
  padding: 10px; display: flex; flex-direction: column; gap: 8px;
  transition: border-color .18s, box-shadow .22s;
}
.asset:hover {
  border-color: color-mix(in srgb, var(--accent) 38%, transparent);
  box-shadow: 0 0 36px -14px color-mix(in srgb, var(--accent) 45%, transparent);
}
.asset img, .asset video { width: 100%; aspect-ratio: 1/1; object-fit: cover; border-radius: 8px; background: #000; }
.asset video { aspect-ratio: 16/9; }
.asset audio { width: 100%; }
.asset .cap { font-size: 12px; color: var(--text); line-height: 1.45; min-height: 34px; }
.asset .foot { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.badge {
  font-family: var(--font-mono); font-size: 9.5px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase;
  padding: 3px 8px; border-radius: 5px; color: var(--muted);
  border: 1px solid var(--line-strong);
}
.asset .when { font-size: 11px; color: var(--muted); margin-left: auto; }

/* ═══ CREDITS ═══ */
.balhero {
  display: flex; justify-content: space-between; align-items: center; gap: 26px;
  flex-wrap: wrap; margin-bottom: 22px;
}
.ballabel { font-size: 10.5px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
.balnum {
  display: flex; align-items: center; gap: 14px;
  font-family: var(--font-display); font-size: 52px; font-weight: 700; color: var(--text);
  margin: 6px 0; letter-spacing: -0.02em;
}
.balshare { font-size: 12.5px; color: var(--muted); max-width: 420px; line-height: 1.6; }
.balshare b { color: var(--text); font-weight: 600; }
.costs { border-collapse: collapse; font-size: 12.5px; font-family: var(--font-display); }
.costs td { padding: 5px 12px; color: var(--muted); border-bottom: 1px solid var(--line); }
.costs td:last-child { color: var(--text); text-align: right; }
.costs tr:last-child td { border-bottom: none; }

.secttitle { margin: 0 0 14px; }
.packs { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 16px; }
.pack {
  position: relative; text-align: center; padding: 28px 20px 22px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 16px;
  backdrop-filter: blur(12px); transition: border-color .18s, box-shadow .22s;
}
.pack:hover {
  border-color: color-mix(in srgb, var(--accent) 40%, transparent);
  box-shadow: 0 0 40px -14px color-mix(in srgb, var(--accent) 50%, transparent);
}
.pack.featured { border-color: color-mix(in srgb, var(--accent) 55%, transparent); }
.pack .tag {
  position: absolute; top: -11px; left: 50%; transform: translateX(-50%);
  font-size: 10px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  color: var(--cta-text); background: var(--cta-bg); padding: 4px 12px; border-radius: 999px;
}
.pack .pname { font-family: var(--font-display); font-size: 16px; font-weight: 600; color: var(--text); }
.pack .pcred {
  font-family: var(--font-display); font-size: 38px; font-weight: 700; color: var(--text);
  margin: 8px 0 2px; letter-spacing: -0.02em;
}
.pack .punit { font-size: 10.5px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
.pack .pblurb { font-size: 12px; color: var(--muted); margin: 12px 0 16px; line-height: 1.5; min-height: 36px; }
.pack .go { margin-top: 0; }

.txs { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.txs td { padding: 9px 10px; border-bottom: 1px solid var(--line); color: var(--muted); }
.txs tr:last-child td { border-bottom: none; }
.txs .amt { text-align: right; font-weight: 700; font-family: var(--font-display); white-space: nowrap; }
.txs .amt.pos { color: var(--ok); }
.txs .amt.neg { color: var(--danger); }
.txs .bal { text-align: right; color: var(--muted); font-family: var(--font-display); white-space: nowrap; }
.txs .note { color: var(--text); }

/* ═══ CONNECT ═══ */
#panel-connect .cols {
  display: block;
  max-width: 800px;
  margin-inline: auto;
}
#panel-connect .card + .card { margin-top: 18px; }
#panel-connect h2 { margin-bottom: 6px; }
#panel-connect h3 { margin-top: 26px; }
.tablewrap { overflow-x: auto; margin: 8px 0; }
.tablewrap .api { min-width: 520px; }
.lead { font-size: 13.5px; color: var(--muted); line-height: 1.65; margin: 2px 0 6px; }
.lead b { color: var(--text); font-weight: 600; }
.stepp { font-size: 12.5px; color: var(--muted); line-height: 1.6; margin: 6px 0 0; }
.stepp b { color: var(--text); font-weight: 600; }
.stepn {
  display: inline-grid; place-items: center; width: 18px; height: 18px; margin-right: 7px;
  border: 1px solid color-mix(in srgb, var(--accent) 45%, var(--line)); border-radius: 999px;
  font-family: var(--font-mono); font-size: 10px; color: var(--accent); letter-spacing: 0;
  vertical-align: -4px;
}
.codebox {
  position: relative; background: var(--well); border: 1px solid var(--line); border-radius: 10px;
  padding: 11px 44px 11px 13px; font-size: 11.5px; margin: 8px 0;
}
.codebox code { color: var(--accent); font-family: var(--font-mono); line-height: 1.7; white-space: pre; display: block; overflow-x: auto; }
.codebox code.wrap { white-space: pre-wrap; word-break: break-all; overflow-x: visible; }
.codebox.block { padding: 13px 44px 13px 13px; }
.copybtn { position: absolute; top: 7px; right: 7px; background: var(--panel2); }
.toolgrid {
  display: grid; grid-template-columns: 200px 1fr; gap: 10px 14px;
  margin: 10px 0 4px; font-size: 12.5px; align-items: baseline;
}
.toolgrid > code {
  font-family: var(--font-mono); font-size: 11.5px; color: var(--accent);
  white-space: normal; word-break: break-word;
}
.toolgrid > span { color: var(--muted); line-height: 1.55; }
.toolgrid .toolcost {
  display: inline-flex; align-items: center; gap: 4px; font-style: normal; white-space: nowrap;
  font-family: var(--font-display); font-size: 10px; color: var(--text);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, var(--line)); border-radius: 999px;
  padding: 1.5px 7px; margin-left: 8px; vertical-align: 1px;
}
.toolgrid .toolcost::before {
  content: ''; width: 9px; height: 9px; flex: none;
  background: url(/brand/orbitle-gold.svg) center / contain no-repeat;
}
.api { width: 100%; border-collapse: collapse; font-size: 12px; }
.api td { border: none; border-bottom: 1px solid var(--line); padding: 8px 10px 8px 0; color: var(--muted); font-family: var(--font-mono); font-size: 11.5px; }
.api tr:last-child td { border-bottom: none; }
.api td:first-child {
  width: 52px; padding-right: 10px;
}
.api td:first-child:not(.apiauth) {
  color: var(--text); font-weight: 600; font-size: 10px; letter-spacing: .08em;
}
.api td:nth-child(2) { color: var(--text); white-space: nowrap; padding-right: 14px; }
.api .apiauth { color: var(--muted); font-family: var(--font-body); font-size: 12px; }
.api .apiauth b { color: var(--accent); font-family: var(--font-mono); font-weight: 500; font-size: 11.5px; }
.provrow { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; }
.pill {
  font-size: 12px; padding: 6px 12px; border: 1px solid var(--line);
  background: var(--panel2); border-radius: 999px; display: inline-flex; align-items: center; gap: 7px;
  color: var(--muted);
}
.pill .dot { width: 7px; height: 7px; background: #777; display: inline-block; border-radius: 999px; }
.pill.ok .dot { background: var(--ok); }
.pill.bad .dot { background: var(--danger); }

/* ═══ TOAST ═══ */
#toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(120px);
  background: var(--bg2); color: var(--text); border: 1px solid var(--line-strong); border-radius: 11px;
  padding: 12px 22px; font-size: 13.5px;
  box-shadow: var(--shadow); transition: transform .25s;
  z-index: 60; max-width: 82vw;
}
#toast.show { transform: translateX(-50%) translateY(0); }
#toast.err { border-color: color-mix(in srgb, var(--danger) 50%, transparent); }

/* ═══ CONNECT — small screens (kept last: overrides the base rules above) ═══ */
@media (max-width: 640px) {
  .toolgrid { grid-template-columns: 1fr; gap: 4px 0; }
  .toolgrid > code { margin-top: 14px; }
  .toolgrid > code:first-child { margin-top: 0; }
  .codebox { font-size: 11px; }
}

/* Light mode logo is FLAT: no glow halo, no surface highlights, no gradient
 * (all --moon-* stops collapse to one bronze above; the sun's rays inherit the
 * same collapse via --moon-deep/--moon-mid). Dark mode keeps its glow. */
html[data-theme="light"] .brandmark circle[fill="url(#mGlow)"],
html[data-theme="light"] .gatelogo circle[fill="url(#gGlow)"],
html[data-theme="light"] .brandmark .moon-spotfill,
html[data-theme="light"] .gatelogo .moon-spotfill {
  display: none;
}
