/* straddleking.com: one stylesheet for the public pages (body.public) and the client / admin apps (body.app). 5 Dec 2026.
   Dark theme close to the console. Phones first (360-430 px), works on desktop. Green = profit, red = loss, always with a sign.
   No external fonts. The CSP allows no inline styles: use these classes. */
:root {
  --bg: #0d1117;
  --panel: #161b22;
  --panel-2: #1c2330;
  --line: #2a3442;
  --text: #e6edf3;
  --muted: #8d99a8;
  --accent: #e3b341;
  --accent-ink: #1a1405;
  --profit: #3fb950;
  --loss: #f85149;
  --warn: #d29922;
  --radius: 10px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", Arial, sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.55 var(--font); }
a { color: var(--accent); }
h1, h2, h3 { line-height: 1.25; margin: 0 0 .5em; }
h1 { font-size: 1.6rem; }
h2 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
.muted { color: var(--muted); }
.positive { color: var(--profit); }
.negative { color: var(--loss); }
.hidden { display: none !important; }

.button, button {
  display: inline-flex; align-items: center; justify-content: center; gap: .4em;
  min-height: 44px; padding: 0 18px; border-radius: var(--radius); border: 1px solid var(--accent);
  background: var(--accent); color: var(--accent-ink); font: 600 15px/1 var(--font); text-decoration: none; cursor: pointer;
}
.button.secondary, button.secondary { background: transparent; color: var(--accent); }
button.quiet { background: transparent; border-color: var(--line); color: var(--text); }
button.danger, button.armed { background: var(--loss); border-color: var(--loss); color: #fff; }
button:disabled { opacity: .6; cursor: wait; }

/* ---------- public pages ---------- */
/* "Emerald Desk" (the owner's choice of five samples, 5 Dec 2026): charcoal with emerald and gold, and the owner's crown logo
   (public/logo.png; a vector stand-in until that file is there). The theme applies to public pages only (body.public); the client
   and admin apps keep their own colours. Home-page parts are scoped under main.home so they never clash with the apps. */
body.public {
  --bg: #0c0f0e; --panel: #121716; --panel-2: #171e1c; --line: #24302d; --text: #e9f1ee; --muted: #8fa29c;
  --accent: #2fd58a; --accent-ink: #04170e; --gold: #e8b84a; --blue: #2d9be8; --logo-navy: #0b1c31;   /* the background of public/logo.png, so the image blends into its panel */
  --gutter: max(16px, calc((100% - 1108px) / 2));
}
.draft-strip { margin: 0; padding: 6px 16px; background: var(--warn); color: #1d1300; font-size: 14px; text-align: center; }
.ticker { overflow: hidden; white-space: nowrap; padding: 8px var(--gutter); background: #08130f; border-bottom: 1px solid var(--line);
  color: var(--muted); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; }
.ticker span { margin-right: 30px; }
.ticker span::before { content: "\25CF\00A0"; color: var(--accent); }
.ticker span.plain::before { content: none; }
.site-header {
  position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 16px; min-height: 68px;
  padding: 8px var(--gutter); background: rgba(12, 15, 14, .94); border-bottom: 1px solid var(--line);
}
.brand-mark { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; min-width: 0; }
/* The crown from logo.png: the image is shown larger and moved so only its crown shows in the badge. */
.logo-badge { position: relative; flex: none; width: 52px; height: 38px; border-radius: 10px; overflow: hidden; background: var(--logo-navy); }
.logo-badge img { position: absolute; width: 140%; max-width: none; left: -20%; top: -6%; }
.logo-badge.drawn { display: grid; place-items: center; }
.logo-badge .logo-svg { width: 44px; height: 29px; }
.logo-word { font: 800 19px/1 var(--font); letter-spacing: .07em; white-space: nowrap; }
.w-a { color: var(--blue); }
.w-b { color: #fff; }
.w-c { color: #e0a93b; }
.wordmark { color: var(--text); font-weight: 800; font-size: 1.2rem; letter-spacing: .01em; text-decoration: none; }
.wordmark::first-letter { color: var(--accent); }
.site-nav { display: none; gap: 22px; margin-left: auto; font-size: 15px; }
.site-nav a { color: var(--muted); text-decoration: none; }
.site-nav a:hover { color: var(--text); }
.site-nav a[aria-current="page"] { color: var(--accent); }
.login-link { margin-left: auto; color: var(--text); font-size: 15px; font-weight: 600; text-decoration: none; white-space: nowrap; }
.login-link:hover { color: var(--accent); }
.start-button { min-height: 40px; padding: 0 16px; border-radius: 12px; white-space: nowrap; }
.page { max-width: 880px; margin: 0 auto; padding: 24px 16px 40px; }
.lead { font-size: 1.08rem; color: #c9d4df; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.card p { margin: 0; color: #c9d4df; }
.cards { display: grid; gap: 12px; margin-bottom: 20px; }
.risk { border: 1px solid var(--warn); border-left-width: 4px; border-radius: var(--radius); padding: 14px 16px; margin: 20px 0; background: rgba(210, 153, 34, .07); }
.risk ul { margin: 0; padding-left: 1.2em; }
.steps { list-style: none; counter-reset: step; padding: 0; margin: 0 0 20px; }
.steps li { counter-increment: step; position: relative; padding: 0 0 14px 48px; }
.steps li::before {
  content: counter(step); position: absolute; left: 0; top: 0; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; background: var(--panel-2); border: 1px solid var(--accent); color: var(--accent); font-weight: 700;
}
.steps p { margin: 0; color: #c9d4df; }
.contact-list { list-style: none; padding: 0; margin: 0 0 20px; display: grid; gap: 10px; }
.contact-list li { display: grid; gap: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; }
.contact-list .label { color: var(--muted); font-size: 14px; }
.contact-list .button { justify-self: start; }
.draft-note { display: inline-block; padding: 4px 10px; border-radius: 6px; background: rgba(210, 153, 34, .15); color: var(--warn); font-size: 14px; }
.site-footer { border-top: 1px solid var(--line); padding: 28px var(--gutter) 36px; font-size: 14px; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-bottom: 12px; }
.site-footer nav a { color: var(--text); text-decoration: none; }
.site-footer nav[aria-label="Policies"] a { color: var(--muted); }
.site-footer .notice { color: var(--muted); max-width: 820px; }

/* home page (main.home) */
.home-wrap { padding: 0 var(--gutter); }
.home h1 { font-size: clamp(32px, 5vw, 56px); line-height: 1.06; margin: 0 0 18px; letter-spacing: -.8px; }
.home h1 .em { color: var(--accent); }
.home h2 { font-size: clamp(26px, 3.4vw, 38px); line-height: 1.14; margin: 0 0 12px; letter-spacing: -.4px; }
.home h3 { margin: 0 0 6px; font-size: 18px; }
.home .lead { color: var(--muted); font-size: 18px; max-width: 540px; margin: 0 0 28px; }
.home .button { min-height: 46px; padding: 0 20px; border-radius: 12px; font-weight: 700; }
.home .sub { color: var(--muted); max-width: 620px; margin: 0 0 32px; }
.home-hero .home-hero-grid { display: grid; gap: 40px; padding-top: 56px; padding-bottom: 56px; }
.hero-chip { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 18px; padding: 5px 12px; border-radius: 99px; font-size: 13px;
  color: var(--accent); border: 1px solid rgba(47, 213, 138, .27); background: rgba(47, 213, 138, .07); }
.hero-chip::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 10px var(--accent); }
.home-brand { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 8px 8px 22px;
  border-radius: 24px; border: 1px solid var(--line); overflow: hidden; background: var(--logo-navy); box-shadow: 0 30px 80px rgba(0, 0, 0, .55); }
.logo-full { display: block; width: 100%; max-width: 520px; height: auto; }
.logo-drawn { display: flex; flex-direction: column; align-items: center; gap: 8px; padding-top: 12px; }
.logo-drawn .logo-svg { width: min(300px, 70vw); height: auto; }
.logo-big-word { font: 900 clamp(34px, 5vw, 54px)/1 var(--font); letter-spacing: .06em; }
.logo-big-word .w-a, .logo-big-word .w-b { font: inherit; }
.logo-big-king { font: 900 clamp(30px, 4.4vw, 46px)/1 var(--font); letter-spacing: .1em; color: #e0a93b; }
.hero-login { margin: 16px 0 0; color: var(--muted); font-size: 15px; }
.home-brand .tagline { margin: 16px 0 0; color: #9fb0c8; font-size: 13px; letter-spacing: .2em; text-transform: uppercase; }
.home-section { padding: 64px 0; }
.promise-grid { display: grid; gap: 34px; }
.pillars { display: grid; gap: 14px; }
.pillar { padding: 22px; border-radius: 16px; background: var(--panel); border: 1px solid var(--line); border-top: 3px solid var(--accent); }
.pillar.gold { border-top-color: var(--gold); }
.pillar.blue { border-top-color: var(--blue); }
.pillar p { margin: 0; color: var(--muted); }
.pillar.no { border-top-color: var(--warn); }
.straight { background: #0e1312; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.home-cta { display: flex; flex-wrap: wrap; gap: 14px 28px; justify-content: space-between; align-items: center; padding: 28px 24px;
  border-radius: 20px; border: 1px solid rgba(47, 213, 138, .3); background: linear-gradient(135deg, rgba(47, 213, 138, .12), rgba(45, 155, 232, .08)); }
.home-cta h2 { margin: 0 0 6px; }
.home-cta p { margin: 0; color: var(--muted); max-width: 560px; }
.home-cta .actions { margin: 0; }
.desk { background: var(--panel); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; box-shadow: 0 30px 80px rgba(0, 0, 0, .5); }
.desk-bar { display: flex; gap: 6px; align-items: center; padding: 12px 14px; border-bottom: 1px solid var(--line); background: var(--panel-2); }
.desk-bar i { width: 10px; height: 10px; border-radius: 50%; background: #2a3633; }
.desk-bar span { margin-left: auto; font-size: 12px; color: var(--muted); }
.desk-body { padding: 18px; display: grid; gap: 12px; }
.desk-line { display: grid; grid-template-columns: 96px 1fr 84px; gap: 12px; align-items: center; font-size: 13px; color: var(--muted); }
.track { height: 8px; border-radius: 6px; background: linear-gradient(90deg, #19a86a, var(--accent)); }
.state { font-size: 11px; text-align: right; color: var(--accent); }
.desk svg { display: block; width: 100%; height: auto; }
.desk-cap { margin: 0; padding: 0 18px 16px; font-size: 12px; color: var(--muted); }
.flow { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.flow li { padding: 20px 16px; border-radius: 14px; background: var(--panel); border: 1px solid var(--line); }
.flow b { display: inline-grid; place-items: center; width: 30px; height: 30px; margin-bottom: 10px; border-radius: 8px;
  background: rgba(47, 213, 138, .12); color: var(--accent); font-size: 14px; }
.flow h3 { font-size: 16px; margin-bottom: 4px; }
.flow p { margin: 0; color: var(--muted); font-size: 14px; }
.home-clients { padding: 64px 0; background: linear-gradient(180deg, #0f1714, var(--bg)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.clients-head { display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; align-items: flex-end; margin-bottom: 26px; }
.clients-head .sub { margin-bottom: 0; }
.clients-head .actions { margin: 0; }
.apps { display: grid; gap: 16px; }
.app { display: flex; flex-direction: column; gap: 10px; padding: 20px; border-radius: 18px; background: var(--panel); border: 1px solid var(--line); }
.app h3 { margin: 0; }
.app p { margin: 0; color: var(--muted); font-size: 14px; }
.mini { margin-top: auto; display: grid; gap: 9px; padding: 14px; border-radius: 12px; background: var(--bg); border: 1px solid var(--line); font-size: 12px; color: var(--muted); }
.mini .r { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.mini .tag { padding: 2px 8px; border-radius: 99px; font-size: 10px; border: 1px solid var(--line); }
.mini .tag.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.mini .tag.warn { color: var(--gold); border-color: rgba(232, 184, 74, .35); }
.mini .sk { height: 8px; border-radius: 6px; background: linear-gradient(90deg, #1e2826, #2b3935, #1e2826); }
.mini .w50 { width: 50px; } .mini .w60 { width: 60px; } .mini .w70 { width: 70px; } .mini .w80 { width: 80px; }
.mini .paid { color: var(--accent); }
.paybtn { display: block; text-align: center; padding: 8px; border-radius: 8px; background: var(--accent); color: var(--accent-ink); font-weight: 700; }
.small-print { margin: 16px 0 0; font-size: 13px; }
.home .risk { margin: 0; padding: 22px 24px; border-radius: 16px; }
.home .risk h2 { font-size: 22px; }
.home .risk p { margin: 0; color: var(--muted); }

@media (max-width: 420px) {
  .site-header { gap: 10px; }
  .brand-mark { gap: 7px; }
  .logo-badge { width: 44px; height: 32px; }
  .logo-badge .logo-svg { width: 38px; height: 25px; }
  .logo-word { font-size: 15px; letter-spacing: .04em; }
  .login-link { font-size: 14px; }
  .start-button { padding: 0 12px; font-size: 14px; }
}
@media (max-width: 380px) {
  .site-header { gap: 8px; }
  .logo-word { font-size: 13px; letter-spacing: .03em; }
  .start-button { padding: 0 10px; }
}
@media (min-width: 720px) {
  .site-nav { display: flex; }
  .login-link { margin-left: 0; }
  .pillars.row { grid-template-columns: repeat(3, 1fr); }
  .cards { grid-template-columns: repeat(2, 1fr); }
  .apps { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 920px) {
  .home-hero .home-hero-grid { grid-template-columns: 1fr 1fr; align-items: center; padding-top: 72px; padding-bottom: 72px; }
  .promise-grid { grid-template-columns: 1.05fr .95fr; align-items: center; }
  .flow { grid-template-columns: repeat(5, 1fr); }
}

/* ---------- apps (client and admin) ---------- */
body.app { padding-bottom: 72px; }
.topbar { display: flex; align-items: center; gap: 12px; padding: 10px 16px; border-bottom: 1px solid var(--line); background: var(--panel); }
.topbar .who { margin-left: auto; color: var(--muted); font-size: 14px; text-align: right; }
.strip { padding: 6px 16px; font-size: 14px; border-bottom: 1px solid var(--line); }
.strip.test { background: rgba(210, 153, 34, .14); color: var(--warn); }
.strip.off { background: var(--panel-2); color: var(--muted); }
.strip.live { background: rgba(63, 185, 80, .12); color: var(--profit); }
.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 5; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr;
  background: var(--panel); border-top: 1px solid var(--line);
}
.tabs button {
  min-height: 56px; border: 0; border-radius: 0; background: transparent; color: var(--muted); font-weight: 600; font-size: 13px; padding: 0 4px;
}
.tabs button[aria-selected="true"] { color: var(--accent); box-shadow: inset 0 2px 0 var(--accent); }
.view { max-width: 880px; margin: 0 auto; padding: 16px; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin-bottom: 14px; }
.panel h2 { margin-bottom: .6em; }
.narrow { max-width: 420px; margin: 32px auto; padding: 0 16px; }
.narrow .wordmark { display: inline-block; margin-bottom: 16px; }
form.stack { display: grid; gap: 12px; }
label { display: grid; gap: 6px; font-size: 14px; color: var(--muted); }
input[type="text"], input[type="email"], input[type="password"], input[type="tel"], input[type="date"], input[type="number"], input[type="search"], select, textarea {
  width: 100%; min-height: 44px; padding: 10px 12px; border-radius: 8px; border: 1px solid var(--line);
  background: var(--bg); color: var(--text); font: 16px var(--font);
}
input:focus, select:focus, textarea:focus, button:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.check { display: flex; gap: 10px; align-items: flex-start; color: var(--text); font-size: 15px; }
.check input { width: 22px; height: 22px; margin-top: 2px; flex: none; }
.consent-text { background: var(--panel-2); border-radius: 8px; padding: 12px; margin: 0; }
.message { min-height: 1.4em; margin: 0; font-size: 14px; }
.message.error { color: var(--loss); }
.message.ok { color: var(--profit); }
.message.warn { color: var(--warn); }
.secret { font: 600 18px/1.6 ui-monospace, "Cascadia Mono", Consolas, monospace; letter-spacing: .06em; background: var(--bg); border: 1px dashed var(--accent);
  border-radius: 8px; padding: 10px 12px; word-break: break-all; user-select: all; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; margin: 0; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; word-break: break-word; }
.badge { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 12px; font-weight: 700; border: 1px solid var(--line); color: var(--muted); }
.badge.active { color: var(--profit); border-color: var(--profit); }
.badge.invited { color: var(--warn); border-color: var(--warn); }
.badge.closed { color: var(--muted); }
.badge.paused { color: #79c0ff; border-color: #79c0ff; }
.list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.list li { background: var(--panel-2); border-radius: 8px; padding: 12px; display: grid; gap: 4px; }
.list .row, .total-card .row { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.stat { background: var(--panel-2); border-radius: 8px; padding: 12px; }
.stat strong { display: block; font-size: 1.4rem; }
.coming { color: var(--muted); }
textarea { resize: vertical; }
h3 { font-size: 1rem; margin: .6em 0 .2em; }
.hint { margin: -6px 0 0; font-size: 13px; }
.back { margin: 0 0 10px; }
.row-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 10px; }
.row-head h1 { margin: 0; }
.list.spaced { margin-top: 12px; }
.row-link { display: grid; gap: 4px; color: inherit; text-decoration: none; }
.row-link:hover strong, .row-link:focus-visible strong { color: var(--accent); }
.actions.small button { min-height: 40px; padding: 0 12px; font-size: 14px; }
.list .actions.small { margin-top: 6px; }
.secret.link { font: 500 14px/1.5 ui-monospace, "Cascadia Mono", Consolas, monospace; letter-spacing: 0; margin: 0; }
.invite { display: grid; gap: 10px; margin: 12px 0; padding-top: 12px; border-top: 1px solid var(--line); }
.invite p { margin: 0; }
.account-form { margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line); }
.account-form h3 { margin: 0; }
fieldset.card-edit { display: grid; gap: 10px; margin: 0; padding: 12px; border: 1px solid var(--line); border-radius: 8px; min-width: 0; }
fieldset.card-edit legend { padding: 0 6px; color: var(--muted); font-size: 14px; }
fieldset.card-edit p { margin: 0; }
.preview { border: 1px dashed var(--line); border-radius: 8px; padding: 12px; }
.preview .cards { margin: 0; }
.preview p { margin: 0; color: #c9d4df; }

/* ---------- P&L (step 3) ---------- */
.small { font-size: 13px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.chip { min-height: 40px; padding: 0 14px; border-radius: 999px; background: transparent; border-color: var(--line); color: var(--text); font-weight: 600; }
.chip[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.period { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.period strong { flex: 1; text-align: center; font-size: 1.05rem; }
.arrow { min-width: 48px; padding: 0; font-size: 22px; line-height: 1; }
.custom-range { display: grid; gap: 10px; margin-bottom: 12px; }
.total-card { background: var(--panel-2); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 14px; display: grid; gap: 6px; }
.total-card p { margin: 0; }
.total-card .kv { margin: 4px 0; }
.big { font-size: 2rem; font-weight: 800; line-height: 1.15; font-variant-numeric: tabular-nums; }
.badges { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.note-line { color: var(--warn); font-size: 14px; }
.empty { padding: 12px 0; }
.list .row span, .total-card .row span { font-variant-numeric: tabular-nums; white-space: nowrap; }
.row-button { display: grid; gap: 4px; width: 100%; min-height: 0; padding: 0; border: 0; background: transparent; color: inherit; font: inherit; text-align: left; justify-content: stretch; }
.row-button:hover strong { color: var(--accent); }
button.link { min-height: 0; padding: 0; border: 0; background: none; color: var(--accent); font: inherit; text-decoration: underline; }
.strip.viewing { margin: -16px -16px 12px; background: rgba(121, 192, 255, .12); color: #79c0ff; border-radius: 0; }
.field-row { display: grid; gap: 12px; }
.net-line { margin: 0; font-weight: 700; min-height: 1.4em; }
.map-grid { display: grid; gap: 10px; }
.upload-step { display: grid; gap: 12px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.upload-step p, .upload-step h3 { margin: 0; }
.refused { margin: 8px 0 0; padding-left: 1.2em; color: var(--loss); font-size: 14px; }
details summary { cursor: pointer; color: var(--accent); }
.table-wrap { overflow-x: auto; max-width: 100%; }
.upload-step > * { min-width: 0; }      /* a wide preview table scrolls inside its box, never widens the page */
.preview-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.preview-table th, .preview-table td { padding: 6px 8px; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; }
.preview-table .num { text-align: right; font-variant-numeric: tabular-nums; }
.small-card { gap: 4px; }
/* Our accounts (step 4): one card per shared account, a running-net chart, a short table. */
.risk.notice { margin: 0 0 14px; }
.perf-card { border-top: 1px solid var(--line); padding-top: 14px; margin-top: 14px; display: grid; gap: 10px; min-width: 0; }
.perf-card:first-child { border-top: 0; margin-top: 0; padding-top: 0; }
.perf-card h2 { margin: 0; }
.perf-card .total-card { margin-bottom: 0; }
.chart { display: block; width: 100%; height: auto; color: var(--muted); }
.chart.positive { color: var(--profit); }
.chart.negative { color: var(--loss); }
.chart-zero { stroke: var(--line); stroke-width: 1; stroke-dasharray: 4 4; }
.chart-line { fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.chart-dot { fill: currentColor; }
.chart-text { fill: var(--muted); font: 11px var(--font); }
.perf-table td:last-child { white-space: normal; }
.pnl-body { min-width: 0; }
/* Bills (step 5): fee plans, drafts, the bill itself (screen and print). */
.stack-block { display: grid; gap: 12px; min-width: 0; }
.spaced-top { margin-top: 12px; }
.spaced-bottom { margin-bottom: 12px; }
.arrow:disabled { opacity: .3; cursor: default; }
.badge.overdue { color: var(--loss); border-color: var(--loss); }
.result { margin-top: 8px; }
.skipped, .warnings, .notes { margin: 6px 0 0; padding-left: 1.2em; font-size: 14px; }
.skipped, .notes { color: var(--muted); }
.skipped strong { color: var(--text); }
.warnings { color: var(--warn); }
.draft { border-top: 1px solid var(--line); padding-top: 14px; margin-top: 14px; display: grid; gap: 10px; min-width: 0; }
.draft:first-of-type { border-top: 0; margin-top: 0; padding-top: 0; }
.draft .row-head { margin: 0; }
.draft h3, .draft p, .draft ul { margin: 0; }
.invoice { display: grid; gap: 14px; min-width: 0; }
.invoice p { margin: 0; }
.invoice-head { display: grid; gap: 12px; }
.invoice-seller { font-weight: 800; font-size: 1.15rem; }
.invoice-title h2 { margin: 0; font-size: 1.2rem; text-transform: uppercase; letter-spacing: .08em; color: var(--accent); }
.invoice-facts { font-size: 15px; }
.invoice-lines { width: 100%; border-collapse: collapse; font-size: 15px; }
.invoice-lines th, .invoice-lines td { padding: 8px 6px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.invoice-lines thead th { color: var(--muted); font-size: 13px; font-weight: 600; }
.invoice-lines .num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.invoice-lines tfoot th { border-bottom: 0; font-size: 1.05rem; }
.line-basis { display: block; color: var(--muted); font-size: 13px; margin-top: 2px; }
.invoice-note { color: var(--muted); font-size: 14px; }
.bill-panel .actions { margin-top: 16px; }
/* Payments (step 6) */
.pay { display: grid; gap: 10px; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.pay p { margin: 0; }
.link-box { display: grid; gap: 10px; margin-bottom: 14px; }
.link-box p, .link-box .secret.link { margin: 0; }
.pay .button { justify-self: start; font-size: 17px; min-height: 50px; padding: 0 26px; }
.direct { margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line); }
.direct h3 { margin: 0; }
.problems { border-color: var(--loss); }
.problems li { border-left: 3px solid var(--loss); }
@media (min-width: 520px) {
  .invoice-head { grid-template-columns: 1fr auto; }
  .invoice-title { text-align: right; }
}
/* Printing a bill (Print / Save as PDF): black on white, only the bill. */
@media print {
  :root { color-scheme: light; }
  body, body.app { background: #fff; color: #000; padding: 0; font-size: 12pt; }
  .topbar, .tabs, .strip, .back, .no-print { display: none !important; }
  .view { max-width: none; padding: 0; }
  .panel { border: 0; padding: 0; margin: 0; background: #fff; }
  .invoice, .invoice * { color: #000 !important; }
  .invoice-lines th, .invoice-lines td { border-color: #999; }
  a { color: #000; text-decoration: none; }
}

@media (min-width: 520px) {
  .field-row { grid-template-columns: 1fr 1fr; }
  .map-grid { grid-template-columns: 1fr 1fr; }
  .custom-range { grid-template-columns: 1fr 1fr auto; align-items: end; }
  .custom-range .message { grid-column: 1 / -1; }
}

@media (min-width: 720px) {
  body.app { padding-bottom: 0; }
  .tabs { position: static; display: flex; justify-content: center; gap: 4px; border-top: 0; border-bottom: 1px solid var(--line); }
  .tabs button { flex: none; min-height: 48px; padding: 0 16px; font-size: 14px; }
  .tabs button[aria-selected="true"] { box-shadow: inset 0 -2px 0 var(--accent); }
  .stats { grid-template-columns: repeat(4, 1fr); }
}
