:root {
  color-scheme: dark;
  --canvas: #0b0e14;
  --surface: #121722;
  --surface-raised: #181f2c;
  --text: #e6eaf2;
  --muted: #adb7c7;
  --gold: #c99d4e;
  --gold-light: #edc781;
  --line: #344055;
  --danger: #ffb4a9;
  --success: #a9d7c1;
  --focus: #f4d9a6;
  --radius: 10px;
}
* { box-sizing: border-box; }
html { background: var(--canvas); font-size: 16px; }
body { margin: 0; color: var(--text); background: var(--canvas); font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; line-height: 1.6; }
a { color: var(--gold-light); text-underline-offset: .22em; overflow-wrap: anywhere; }
a:hover { color: #fff1d7; }
button, input, select, textarea { font: inherit; }
button, a, input, select, textarea, summary { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }
h1, h2, h3, p, ul, ol, dl { margin-top: 0; }
h1, h2 { font-family: Georgia, "Times New Roman", serif; font-weight: 400; line-height: 1.18; }
h1 { margin-bottom: .65rem; font-size: clamp(2rem, 4vw, 3rem); letter-spacing: -.025em; }
h2 { margin-bottom: 1rem; font-size: 1.55rem; }
h3 { margin-bottom: .5rem; font-size: 1rem; }
p:last-child, ul:last-child, ol:last-child, dl:last-child { margin-bottom: 0; }
code { font-size: .9em; overflow-wrap: anywhere; }
.skip-link { position: absolute; left: 1rem; top: -6rem; z-index: 20; padding: .7rem 1rem; color: var(--canvas); background: var(--focus); }
.skip-link:focus { top: 1rem; }
.site-header { border-bottom: 1px solid var(--line); }
.site-header__inner { max-width: 1280px; min-height: 84px; margin: auto; padding: 1rem 2rem; display: flex; align-items: center; gap: 1.5rem; }
.brand { font-family: Georgia, "Times New Roman", serif; font-size: 1.65rem; line-height: 1; letter-spacing: .16em; color: var(--text); text-decoration: none; }
.brand__mark { color: var(--gold); }
.environment-label { font-size: .875rem; color: var(--muted); border-left: 1px solid var(--line); padding-left: 1.5rem; }
.account-menu { margin-left: auto; display: flex; gap: 1rem; align-items: center; font-size: .875rem; }
.account-menu form { margin: 0; }
.account-name { overflow-wrap: anywhere; }
.workspace-nav { border-bottom: 1px solid var(--line); }
.workspace-nav__inner { max-width: 1280px; margin: auto; padding: .65rem 2rem; display: flex; align-items: center; gap: 1.5rem; flex-wrap: wrap; }
.workspace-nav a { font-size: .875rem; text-decoration: none; padding: .4rem 0; }
.workspace-nav a[aria-current="page"] { color: var(--text); border-bottom: 2px solid var(--gold); }
.organization-label { margin-left: auto; font-size: .875rem; color: var(--muted); }
.page { width: min(100%, 1280px); min-height: 70vh; margin: auto; padding: 2.5rem 2rem 4rem; }
.page--narrow { max-width: 640px; }
.page-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 1.5rem; margin-bottom: 2rem; }
.eyebrow { color: var(--gold); font-size: .875rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; margin-bottom: .7rem; }
.page-intro { max-width: 70ch; color: var(--muted); }
.stack { display: grid; gap: 1.25rem; }
.stack--compact { gap: .65rem; }
.grid { display: grid; gap: 1.5rem; }
.grid--two { grid-template-columns: minmax(0, 1.5fr) minmax(280px, 1fr); align-items: start; }
.panel { border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); padding: 1.5rem; min-width: 0; }
.panel--accent { border-top: 3px solid var(--gold); }
.panel + .panel { margin-top: 1.5rem; }
.stack > .panel + .panel, .grid > .panel + .panel { margin-top: 0; }
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.panel-heading h2, .panel-heading h3 { margin: 0; }
.muted, .help-text, .caption { color: var(--muted); }
.help-text, .caption { font-size: .875rem; }
.caption { margin-top: 1rem; }
.form-field { display: grid; gap: .45rem; }
label { display: block; font-weight: 600; }
input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]), select, textarea { width: 100%; min-height: 46px; border: 1px solid #6b788d; border-radius: 5px; background: var(--canvas); color: var(--text); padding: .65rem .8rem; }
textarea { min-height: 160px; resize: vertical; }
input[type="checkbox"], input[type="radio"] { width: 1.2rem; height: 1.2rem; accent-color: var(--gold); vertical-align: middle; }
input[readonly], textarea[readonly] { background: var(--surface-raised); }
.form-field--error input, .form-field--error select, .form-field--error textarea { border-color: var(--danger); }
.errorlist { list-style: none; margin: 0; padding: 0; color: var(--danger); font-size: .875rem; }
.error-summary { border-left: 4px solid var(--danger); padding: 1rem 1.25rem; background: #291d23; margin-bottom: 1.5rem; }
.error-summary h3, .error-summary a { color: var(--danger); }
.form-actions, .action-row { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; min-height: 46px; padding: .65rem 1rem; border: 1px solid var(--line); border-radius: 5px; background: var(--surface-raised); color: var(--text); text-decoration: none; font-weight: 600; cursor: pointer; }
.button:hover { border-color: var(--gold); color: var(--text); }
.button--primary { border-color: var(--gold); background: var(--gold); color: var(--canvas); }
.button--primary:hover { background: var(--gold-light); color: var(--canvas); }
.button--quiet { background: transparent; }
.button--small { font-size: .875rem; min-height: 42px; padding: .4rem .75rem; }
.button:disabled { opacity: .6; cursor: not-allowed; }
.notice { border-left: 3px solid var(--gold); background: var(--surface-raised); border-radius: 3px; padding: .85rem 1rem; margin-bottom: 1.25rem; overflow-wrap: anywhere; }
.notice--error { border-color: var(--danger); }
.notice--success { border-color: var(--success); }
.status { display: inline-flex; align-items: center; padding: .18rem .6rem; border: 1px solid var(--line); border-radius: 4px; background: var(--surface-raised); font-size: .875rem; line-height: 1.5; white-space: normal; }
.status--mock { color: var(--gold-light); border-color: #766039; }
.status--published { color: var(--success); border-color: #426454; }
.status--warning { color: var(--gold-light); }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; }
caption { text-align: left; color: var(--muted); padding-bottom: .75rem; font-size: .875rem; }
th { color: var(--muted); font-size: .875rem; font-weight: 600; }
th, td { padding: 1rem .75rem; vertical-align: top; border-bottom: 1px solid var(--line); }
th:first-child, td:first-child { padding-left: 0; }
tbody tr:last-child td { border-bottom: 0; }
.empty-state { padding: 2rem 1rem; text-align: center; color: var(--muted); }
.meta-list { display: grid; gap: .7rem; margin: 0; }
.meta-list > div { display: grid; grid-template-columns: minmax(90px, .5fr) minmax(0, 1fr); gap: 1rem; }
dt { color: var(--muted); font-size: .875rem; }
dd { margin: 0; overflow-wrap: anywhere; }
.message { padding: 1.2rem 0; border-bottom: 1px solid var(--line); }
.message:first-child { padding-top: 0; }
.message:last-child { padding-bottom: 0; border: 0; }
.message__header { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; margin-bottom: .65rem; font-size: .875rem; color: var(--muted); }
.preserve-text { white-space: pre-wrap; overflow-wrap: anywhere; margin: 0; }
.source-item { padding: 1rem 0; border-bottom: 1px solid var(--line); }
.source-item:first-child { padding-top: 0; }
.source-item:last-child { padding-bottom: 0; border: 0; }
.source-item h3 { overflow-wrap: anywhere; }
.source-preview { margin-top: 1.25rem; }
.workspace-links { display: flex; flex-wrap: wrap; gap: .75rem; }
.internal-note { border-left: 3px solid #77859b; padding-left: 1rem; }
.review-copy { background: var(--canvas); border: 1px solid var(--line); padding: 1rem; border-radius: 5px; }
.review-copy, .case-summary { margin-top: 1rem; margin-bottom: 1.5rem; }
.local-delivery { margin-top: 1rem; padding: 1rem; border: 1px dashed var(--gold); border-radius: 5px; background: var(--canvas); }
.verification-code { font-size: 1.65rem; font-weight: 600; letter-spacing: .16em; color: var(--gold-light); overflow-wrap: anywhere; }
.visually-hidden { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.section-divider { border: 0; border-top: 1px solid var(--line); margin: 1.5rem 0; }
details { border: 1px solid var(--line); padding: 1rem; border-radius: 5px; }
summary { cursor: pointer; font-weight: 600; }
details[open] summary { margin-bottom: 1rem; }
.site-footer { max-width: 1280px; margin: auto; padding: 1.5rem 2rem; border-top: 1px solid var(--line); font-size: .875rem; color: var(--muted); }
.identity-content form { display: grid; gap: 1rem; margin-top: 1.25rem; }
.identity-content form > p { margin-bottom: 0; }
.identity-content form label { margin-bottom: .4rem; }
.identity-content .helptext { display: block; margin-top: .4rem; color: var(--muted); font-size: .875rem; }
.identity-content button { min-height: 46px; padding: .65rem 1rem; border: 1px solid var(--gold); border-radius: 5px; background: var(--gold); color: var(--canvas); font-weight: 600; cursor: pointer; }
.identity-content button:hover { background: var(--gold-light); }
.identity-content button:disabled { opacity: .6; cursor: not-allowed; }
.identity-content img { max-width: 100%; height: auto; background: #fff; }
.identity-content svg { max-width: 100%; height: auto; }
.identity-content pre { max-width: 100%; white-space: pre-wrap; overflow-wrap: anywhere; }
.identity-content td, .identity-content th, .identity-content li { overflow-wrap: anywhere; }
.identity-content fieldset { min-width: 0; margin: 0; padding: 1rem; border: 1px solid var(--line); }
@media (max-width: 760px) {
  .site-header__inner { flex-wrap: wrap; gap: .9rem; padding: 1rem 1.25rem; }
  .environment-label { border: 0; padding: 0; font-size: .875rem; }
  .account-menu { width: 100%; justify-content: space-between; }
  .workspace-nav__inner { padding: .6rem 1.25rem; gap: 1rem; }
  .organization-label { margin-left: 0; width: 100%; }
  .page { padding: 2rem 1.25rem 3rem; }
  .page-heading { flex-direction: column; gap: 1rem; }
  .grid--two { grid-template-columns: minmax(0, 1fr); }
  .panel { padding: 1.1rem; }
  .meta-list > div { grid-template-columns: 1fr; gap: .15rem; }
  .message__header { flex-wrap: wrap; gap: .25rem; }
  .site-footer { padding: 1.25rem; }
}
@media (prefers-reduced-motion: no-preference) {
  .button { transition: background-color .15s, border-color .15s; }
}
@media print {
  body { color: #111; background: #fff; }
  .site-header, .workspace-nav, .site-footer, .form-actions, .account-menu { display: none; }
  .page { width: 100%; padding: 0; }
  .panel, .review-copy { color: #111; background: #fff; border-color: #555; break-inside: avoid; }
  a, .muted, .caption, .help-text, dt { color: #333; }
}
