/* Cogworks is the customer workspace: warm paper, machined brass, clear account data. */
:root {
  --ink-0: #eee9df;
  --ink-1: #f8f4eb;
  --ink-2: #fffcf6;
  --ink-3: #d8cec0;
  --text-hi: #1b2729;
  --text-mid: #3e4b4a;
  --text-low: #66716f;
  --accent: #c49455;
  --accent-hi: #e0b575;
  --accent-dim: rgba(196,148,85,.15);
  --on-accent: #192123;
  --brass: var(--accent);
  --brass-hi: var(--accent-hi);
  --brass-dim: var(--accent-dim);
  --good: #3f7e62;
  --warn: #a35835;
  --radius: 4px;
  --font-head: "Barlow Condensed", "Arial Narrow", sans-serif;
  --font-body: "DM Sans", "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", Consolas, monospace;
  --font-serif: "Libre Baskerville", Georgia, serif;
}
html { scroll-behavior: smooth; }
body { background: var(--ink-0); color: var(--text-mid); font-size: 15px; }
::selection { background: var(--accent); color: var(--on-accent); }
:focus-visible { outline: 2px solid #a16e35; outline-offset: 3px; }
a { color: #86582c; }
a:hover { color: #5d3e22; }
.skip-link { position: fixed; z-index: 1002; top: -60px; left: 10px; background: #fff; color: #172226; padding: 9px 14px; }
.skip-link:focus { top: 10px; }
h1,h2,h3 { letter-spacing: .005em; }
.shell { grid-template-columns: 254px minmax(0,1fr); }
.side {
  position: sticky; top: 0; height: 100vh; padding: 24px 17px 20px;
  background: #172125; border-right: 1px solid #53605d; color: #d8ded6;
  overflow-y: auto; scrollbar-width: thin;
}
.brand { gap: 8px; padding: 0 3px 21px; border-bottom: 1px solid rgba(215,167,101,.22); }
.brand:hover { color: #fff; }
.cogworks-art { display: block; width: 60px; height: 60px; flex: none; line-height: 0; }
.cogworks-art svg { display: block; width: 100%; height: 100%; }
.brand-copy { display: grid; gap: 2px; min-width: 0; }
.brand .brand-copy strong { color: #f7ecda; font: 700 1.75rem/.9 var(--font-head); letter-spacing: .075em; }
.brand .brand-copy small { color: #d8aa6c; font: 500 .53rem/1.4 var(--font-mono); letter-spacing: .1em; white-space: nowrap; }
.side-kicker { margin: 18px 11px 6px; color: #bc966a; font: 500 .58rem/1.5 var(--font-mono); letter-spacing: .16em; }
.side nav { gap: 3px; }
.nav-label { display: block; color: #b5a28d; margin: 20px 10px 4px; padding-top: 15px; border-top: 1px solid rgba(217,194,159,.13); font: 600 .61rem var(--font-mono); letter-spacing: .15em; }
.nav-label:first-child { margin-top: 7px; border-top: 0; padding-top: 0; }
.side nav a { color: #c7cfca; padding: 10px 12px; border-radius: 3px; border-left: 2px solid transparent; font-size: .91rem; }
.side nav a:hover { color: #fff; background: rgba(215,167,101,.1); }
.side nav a.on { color: #f1c88f; background: rgba(215,167,101,.14); border-left-color: #d7a765; font-weight: 700; }
.side-foot { border-top: 1px solid rgba(217,194,159,.18); padding: 16px 9px 0; gap: 3px; }
.side-foot-label { color: #b5a28d; font: 600 .6rem var(--font-mono); letter-spacing: .14em; }
.side-foot .who { font-weight: 700; color: #f3eee2; }
.side-email { color: #9ea9a4; font-size: .76rem; overflow-wrap: anywhere; }
.side-foot a { color: #e0b575; margin-top: 8px; font-size: .83rem; }
.main {
  max-width: none; min-width: 0; padding: 0 clamp(28px,4vw,68px) 90px;
  background: radial-gradient(660px 500px at 100% 0%, rgba(196,148,85,.11), transparent 70%),
    repeating-linear-gradient(90deg, transparent 0 139px, rgba(42,55,51,.025) 139px 140px);
}
.workspace-top { display: flex; justify-content: space-between; gap: 14px; padding: 22px 0 18px; border-bottom: 1px solid #cfc4b3; color: #806b55; font: 600 .64rem/1.4 var(--font-mono); letter-spacing: .14em; }
.workspace-top i { font-style: normal; color: #b98c52; margin-inline: 7px; }
.page-top { margin: 35px 0 26px; }
.page-top h1 { color: #1d2a2a; font: 700 clamp(2.9rem,4.5vw,4.6rem)/.95 var(--font-head); text-transform: uppercase; }
.page-top p { color: #53605e; font-size: .96rem; margin-top: 11px; }
.page-top .eyebrow { margin: 0 0 11px; }
.eyebrow { color: #9b6c39; font: 600 .64rem/1.4 var(--font-mono); letter-spacing: .16em; }
.hero-dot { color: #c99656; }
.overview-hero { position: relative; overflow: hidden; padding: clamp(31px,3.5vw,52px); background: #1c292b; border: 1px solid #465552; border-top: 3px solid #d2a265; color: #d7dcd5; }
.overview-hero::before { content: ""; position: absolute; width: 420px; height: 420px; border: 1px solid rgba(215,167,101,.23); border-radius: 50%; top: -210px; right: -65px; box-shadow: 0 0 0 29px rgba(215,167,101,.025), inset 0 0 0 26px rgba(215,167,101,.025); pointer-events: none; }
.overview-hero > * { position: relative; z-index: 1; }
.overview-hero h1 { color: #f6ead7; font-size: clamp(3.4rem,5.5vw,5.5rem); max-width: 790px; }
.overview-hero .hero-lede { max-width: 610px; color: #c2cbc5; font-size: 1.02rem; line-height: 1.65; }
.overview-hero .eyebrow { color: #e0b575; }
.overview-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 17px; margin-top: 23px; color: #cbd2c9; font: 500 .67rem/1.6 var(--font-mono); text-transform: uppercase; letter-spacing: .03em; }
.overview-meta > span:not(.chip) { border-left: 1px solid rgba(215,167,101,.35); padding-left: 16px; }
.overview-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.overview-actions .btn-quiet { border-color: #87918a; color: #f2e8d8; }
.overview-actions .btn-quiet:hover { color: #fff; background: rgba(255,255,255,.08); border-color: #d2a265; }
.tiles { gap: 12px; margin-bottom: 32px; }
.overview-tiles { grid-template-columns: repeat(4,minmax(0,1fr)); }
.tile { min-width: 0; border-radius: 3px; border: 1px solid #d8cec0; border-top: 3px solid #c69659; background: #fffdf7; padding: 20px 21px; box-shadow: 0 8px 22px rgba(42,37,30,.045); }
.tile-link { color: inherit; display: block; transition: transform .16s, border-color .16s; }
.tile-link:hover { text-decoration: none; transform: translateY(-2px); border-color: #b58242; }
.tile-n { color: #1e2b2b; font: 700 clamp(1.9rem,2.6vw,2.7rem)/1 var(--font-head); }
.tile-denom { color: #77807a; font-size: .55em; }
.tile-l { color: #67716d; font-size: .78rem; margin-top: 8px; }
.section-heading,.panel-heading { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: 18px; }
.section-heading h2,.panel-heading h2 { color: #202d2d; font: 700 clamp(2rem,3vw,3rem)/1 var(--font-head); text-transform: uppercase; margin: 6px 0 0; }
.section-heading > p { max-width: 320px; color: #68726c; font-size: .86rem; }
.next-section { margin: 48px 0 38px; }
.action-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; }
.action-card { position: relative; display: flex; flex-direction: column; min-height: 205px; background: #fcf9f2; border: 1px solid #d6cbb9; padding: 22px 22px 26px; color: #2e3a38; transition: transform .16s, border-color .16s, box-shadow .16s; }
.action-card::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 2px; background: #c69659; }
.action-card:hover { color: #2e3a38; text-decoration: none; transform: translateY(-3px); border-color: #bc8a4f; box-shadow: 0 13px 24px rgba(49,40,27,.09); }
.action-card > span { color: #956a3e; font: 600 .62rem var(--font-mono); letter-spacing: .1em; }
.action-card strong { color: #1d2b2b; font: 700 1.75rem/1 var(--font-head); text-transform: uppercase; margin-top: 16px; }
.action-card p { font-size: .84rem; line-height: 1.6; margin-top: 8px; max-width: 240px; }
.action-card b { position: absolute; right: 21px; bottom: 18px; color: #a67842; font-size: 1.4rem; font-weight: 400; }
.panel { background: #fffdf7; border: 1px solid #d8cec0; border-radius: 3px; box-shadow: 0 8px 24px rgba(42,37,30,.045); padding: 24px 26px; }
.panel h2 { color: #22302f; font: 700 1.72rem/1.05 var(--font-head); text-transform: uppercase; margin-bottom: 12px; }
.panel-heading { border-bottom: 1px solid #ded5c7; padding-bottom: 16px; }
.panel-heading h2 { margin: 4px 0 0; }
.panel-heading a { font: 600 .7rem var(--font-mono); text-transform: uppercase; white-space: nowrap; }
.panel > p { line-height: 1.7; }
.panel .empty { color: #67716e; }
table { font-size: .86rem; }
th { color: #7c6852; font: 600 .65rem var(--font-mono); border-bottom-color: #d1c6b5; }
td { border-bottom-color: #e7e0d3; }
tr:hover td { background: rgba(196,148,85,.055); }
.muted { color: #69736e; }
.chip { border-radius: 3px; font: 600 .65rem/1.5 var(--font-mono); }
.chip-mid { color: #875c2e; border-color: #c79b61; background: #f6ead8; }
.chip-ok { color: #3d765e; border-color: #7bac92; background: #edf6ef; }
.chip-warn { color: #a04e33; border-color: #cc9273; background: #fff0e7; }
.chip-off { color: #64716d; border-color: #cfd8d0; background: #f4f5f1; }
.btn,.btn-mini,.mbtn { border-radius: 3px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: #d4a365; border-color: #b78346; color: #1b2525; font: 700 .95rem var(--font-head); text-transform: uppercase; letter-spacing: .06em; padding: 11px 17px; text-decoration: none; }
.btn:hover { background: #e6ba7c; border-color: #c39256; color: #1b2525; text-decoration: none; }
.btn-quiet { background: transparent; color: #5f4d39; border-color: #b9a88e; }
.btn-quiet:hover { background: #f1e8d9; color: #2b332f; }
.btn-mini { color: #6c4b2b; border-color: #c39153; }
.flash { border-radius: 3px; }
.plan-hero { border-top: 3px solid #c69659; }
.plan-hero-price { padding: 18px 22px; background: #f3e9d8; border: 1px solid #dfcaaa; text-align: left; min-width: 205px; }
.plan-amount { color: #1e2c2b; font-size: 2.55rem; }
.plan-amount span { display: block; font: 600 .72rem var(--font-mono); color: #776c5c; margin-top: 5px; }
.plan-includes li::before { border-radius: 3px; }
.addon-card { background: #fbf8f0; border-color: #d9cdbc; padding: 21px; }
.addon-on { border-color: #b98c57; background: linear-gradient(180deg, rgba(215,167,101,.14), transparent 55%), #fbf8f0; }
.addon-head h3 { color: #1f2c2c; font: 700 1.35rem var(--font-head); text-transform: uppercase; }
.addon-price { color: #8d5d2e; font: 700 1.25rem var(--font-head); }
.addon-price span { display: block; font: 500 .68rem var(--font-mono); white-space: normal; }
.addon-desc { color: #58635f; }
.addon-foot { flex-wrap: wrap; }
select,.stack-form input[type="text"],.stack-form textarea { border-radius: 3px; border-color: #c9beae; background: #fffdf8; color: #26302f; }
.stack-form input:focus,.stack-form textarea:focus,select:focus { outline: 2px solid #c69659; outline-offset: 1px; }
.modal-content { border-radius: 4px; }
.modal-title { font-size: 1.3rem; text-transform: uppercase; }
.mbtn { font: 700 .86rem var(--font-head); text-transform: uppercase; }
.account-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 15px; }
.account-record { min-width: 0; }
.account-record h2 { margin-top: 7px; overflow-wrap: anywhere; }
.organization-topline { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.organization-topline .eyebrow { margin: 0; }
.organization-topline .chip { flex: none; }
.detail-list { display: grid; margin-top: 22px; }
.detail-list > div { display: flex; justify-content: space-between; gap: 15px; border-top: 1px solid #e5ddcf; padding: 13px 0; }
.detail-list dt { color: #727b73; font-size: .82rem; }
.detail-list dd { color: #263330; font-weight: 600; text-align: right; overflow-wrap: anywhere; }
.organization-heading { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.organization-name-trigger { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; border: 0; padding: 0; background: none; color: var(--text-hi); font: inherit; text-align: left; cursor: text; overflow-wrap: anywhere; }
.organization-name-trigger:hover span { text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 4px; }
.organization-name-trigger:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.organization-pencil { width: 17px; height: 17px; flex: none; color: var(--accent); opacity: 0; transition: opacity .15s; }
.organization-name-trigger:hover .organization-pencil, .organization-name-trigger:focus-visible .organization-pencil { opacity: 1; }
.organization-name-trigger[hidden], .organization-name-input[hidden] { display: none; }
.organization-name-input { width: min(100%, 32ch); min-width: 8ch; padding: 2px 7px; border: 1px solid var(--accent); background: var(--ink-0); color: var(--text-hi); font: inherit; }
.organization-name-input:focus { outline: 2px solid var(--accent); outline-offset: 2px; }
.organization-save-state { display: block; margin-top: 3px; color: var(--text-low); font: 600 .7rem var(--font-mono); }
.organization-save-state:empty { display: none; }
.organization-save-state.ok { color: var(--good); }
.organization-save-state.err { color: var(--warn); }
@media (hover: none) { .organization-pencil { opacity: 1; } }
.overview-hero h1 { overflow-wrap: anywhere; }
.account-help { display: flex; justify-content: space-between; align-items: center; gap: 25px; margin-top: 24px; padding: 28px 32px; background: #1e2a2c; color: #d9ded5; }
.account-help h2 { color: #f7eddd; font: 700 2.4rem var(--font-head); text-transform: uppercase; }
.account-help p:not(.eyebrow) { max-width: 600px; font-size: .88rem; }
.account-help .eyebrow { color: #d7a765; }
.account-help .btn { white-space: nowrap; }
.auth-body { position: relative; background: radial-gradient(560px 510px at 50% 45%, rgba(215,167,101,.13), transparent 70%), repeating-linear-gradient(90deg, transparent 0 119px, rgba(255,255,255,.018) 119px 120px), #11191c; }
.auth-body::before { content: ""; position: fixed; width: min(620px,95vw); aspect-ratio: 1; top: 50%; left: 50%; transform: translate(-50%,-50%); border: 1px solid rgba(215,167,101,.16); border-radius: 50%; box-shadow: 0 0 0 33px rgba(215,167,101,.025); pointer-events: none; }
.auth-card { position: relative; width: min(440px,100%); background: #202a2d; border-color: rgba(215,167,101,.48); border-radius: 4px; }
.auth-head { padding: 26px 30px 23px; border-bottom-color: #40504d; }
.auth-art { display: block; width: 105px; height: 105px; margin: 0 auto 8px; line-height: 0; }
.auth-art svg { display: block; width: 100%; height: 100%; }
.auth-kicker { color: #d7a765; font: 600 .6rem var(--font-mono); letter-spacing: .12em; margin-bottom: 7px; }
.auth-card h1 { color: #f4ead8; font: 700 3.35rem/.95 var(--font-head); letter-spacing: .07em; }
.auth-sub { color: #c5ceca; font-size: .85rem; }
.auth-main { padding: 26px 30px 30px; }
.auth-label { color: #c7cdc3; font: 600 .67rem var(--font-mono); letter-spacing: .09em; }
.auth-card input[type="email"],.auth-card input[type="text"] { background: #151e21; border-color: #5d6862; color: #f2ebda; border-radius: 3px; padding: 12px; }
.auth-card button { border-radius: 3px; background: #d7a765; color: #182123; font: 700 1.05rem var(--font-head); text-transform: uppercase; letter-spacing: .07em; padding: 11px; }
.auth-card button:hover:not(:disabled) { background: #f1c88f; }
.auth-hint,.auth-back { color: #b6c0b9; }
.auth-hint strong { color: #f3e9d6; }
.auth-dev { border-radius: 3px; color: #e9d8b7; }
@media (max-width: 1140px) { .overview-tiles { grid-template-columns: repeat(2,minmax(0,1fr)); } .action-card { min-height: 225px; } }
@media (max-width: 850px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: relative; height: auto; padding: 12px 18px; flex-direction: row; flex-wrap: wrap; align-items: center; }
  .brand { border: 0; padding: 0; }
  .side-kicker,.side-foot-label,.side-email { display: none; }
  .side nav { display: flex; flex-wrap: wrap; gap: 4px; order: 3; flex: 1 1 100%; }
  .nav-label { display: none; }
  .side nav a { padding: 7px 9px; }
  .side-foot { border: 0; margin-left: auto; padding: 0; }
  .main { padding-inline: 22px; }
  .action-grid { grid-template-columns: 1fr; }
  .action-card { min-height: 145px; }
  .account-grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) { .workspace-top span:last-child { display: none; } .overview-hero { padding: 26px; } .overview-meta > span:not(.chip) { padding-left: 0; border: 0; } .overview-tiles { grid-template-columns: 1fr 1fr; } .section-heading,.panel-heading,.account-help { align-items: start; flex-direction: column; } .panel { padding: 20px; } }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *,*::before,*::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }

/* Cog Machina night palette, shared with The Dynamo. */
:root {
  --ink-0: #10171a;
  --ink-1: #151e22;
  --ink-2: #202a2d;
  --ink-3: #3a484b;
  --text-hi: #f5ead8;
  --text-mid: #c4c9c4;
  --text-low: #929d9b;
  --accent: #d7a765;
  --accent-hi: #f1c88f;
  --accent-dim: rgba(215,167,101,.14);
  --on-accent: #171b1d;
  --brass: var(--accent);
  --brass-hi: var(--accent-hi);
  --brass-dim: var(--accent-dim);
  --good: #94bc9b;
  --warn: #d79067;
}
body { background: var(--ink-0); color: var(--text-mid); }
a { color: var(--accent-hi); }
a:hover { color: #ffe2a7; }
.side { background: #151c20; border-right-color: #354043; }
.main {
  background: radial-gradient(660px 500px at 100% 0, rgba(215,167,101,.06), transparent 70%),
    repeating-linear-gradient(90deg, transparent 0 139px, rgba(255,255,255,.012) 139px 140px), var(--ink-0);
}
.workspace-top { border-bottom-color: rgba(215,167,101,.22); color: #b6a38a; }
.workspace-top i { color: var(--accent); }
.page-top h1, .section-heading h2, .panel-heading h2 { color: var(--text-hi); }
.page-top p, .section-heading > p { color: var(--text-low); }
.eyebrow { color: var(--accent); }
.overview-hero { background: #1b2528; border-color: #465250; border-top-color: var(--accent); }
.overview-hero h1 { color: var(--text-hi); }
.overview-hero .hero-lede { color: #c4ccc5; }
.overview-meta { color: #c8cec6; }
.overview-meta > span:not(.chip) { border-left-color: rgba(215,167,101,.35); }
.tile, .panel, .action-card { background: var(--ink-2); border-color: var(--ink-3); box-shadow: 0 10px 30px rgba(0,0,0,.075); }
.tile { border-top-color: var(--accent); }
.tile-link { color: var(--text-mid); }
.tile-link:hover { border-color: var(--accent); color: var(--text-mid); }
.tile-n, .action-card strong, .panel h2, .addon-head h3, .detail-list dd { color: var(--text-hi); }
.tile-denom, .tile-l, .action-card p, .panel .empty, .muted { color: var(--text-low); }
.action-card::before { background: var(--accent); }
.action-card > span, .action-card b { color: var(--accent); }
.action-card:hover { color: var(--text-mid); border-color: var(--accent); box-shadow: 0 13px 24px rgba(0,0,0,.17); }
.panel-heading { border-bottom-color: rgba(215,167,101,.2); }
.panel-heading a { color: var(--accent-hi); }
th { color: #c1a67f; border-bottom-color: #52605e; }
td { border-bottom-color: #3b4746; }
tr:hover td { background: rgba(215,167,101,.045); }
.chip-mid { color: #e5bd82; border-color: #a88154; background: rgba(215,167,101,.14); }
.chip-ok { color: #a1cbaa; border-color: #60856b; background: rgba(104,154,118,.13); }
.chip-warn { color: #ecae89; border-color: #a87859; background: rgba(208,134,89,.14); }
.chip-off { color: #a1aaa4; border-color: #58635e; background: #283135; }
.btn { background: var(--accent); border-color: #b8894e; color: var(--on-accent); }
.btn:hover { background: var(--accent-hi); border-color: var(--accent-hi); color: var(--on-accent); }
.btn-quiet { background: transparent; color: #e1c397; border-color: #7b7668; }
.btn-quiet:hover { background: rgba(215,167,101,.1); color: #ffe2a7; border-color: var(--accent); }
.btn-mini { color: var(--accent-hi); border-color: var(--accent); }
.plan-hero { border-top-color: var(--accent); }
.plan-hero-price { background: #283235; border-color: #675943; }
.plan-amount { color: var(--text-hi); }
.plan-amount span { color: var(--text-low); }
.addon-card { background: #192226; border-color: #465250; }
.addon-on { border-color: var(--accent); background: linear-gradient(180deg, rgba(215,167,101,.1), transparent 55%), #192226; }
.addon-price { color: var(--accent-hi); }
.addon-price span, .addon-desc { color: #adb8b3; }
select, .stack-form input[type="text"], .stack-form textarea { background: #151e22; border-color: #586663; color: var(--text-hi); }
select:focus, .stack-form input:focus, .stack-form textarea:focus { outline-color: var(--accent); }
.detail-list > div { border-top-color: #45514e; }
.detail-list dt { color: var(--text-low); }
.account-help { background: #253033; border: 1px solid #465250; }
.account-help h2 { color: var(--text-hi); }
.account-help .eyebrow { color: var(--accent); }
.modal-content { background: var(--ink-2); color: var(--text-mid); }
