/* SiliconDoctor V10: one presentation system, independent of legacy page styles. */
:root {
  color-scheme: light;
  --sd-bg:#f6f5f1; --sd-surface:#fff; --sd-ink:#242b29; --sd-muted:#5b6661;
  --sd-accent:#176352; --sd-accent-soft:#eaf3ee; --sd-line:#d8ded8;
  --sd-danger:#a02a30; --sd-danger-soft:#fceef0; --sd-warning:#79530b;
  --sd-warning-soft:#fff4d9; --sd-success:#176352; --sd-pending:#5b6661;
  --sd-unverified:#79530b; --sd-stale:#79530b; --sd-offline:#5b6661;
  --sd-focus:#176352; --sd-disabled:#e6e8e3; --sd-radius:14px;
  --sd-space-1:4px; --sd-space-2:8px; --sd-space-3:12px; --sd-space-4:16px;
  --sd-space-5:24px; --sd-space-6:32px; --sd-space-7:48px; --sd-space-8:64px;
  --sd-text-sm:.875rem; --sd-text:1rem; --sd-title:clamp(2rem,5vw,3.8rem);
  --sd-font:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  --sd-mono:ui-monospace,SFMono-Regular,Consolas,monospace;
  --sd-shadow:0 16px 48px #242b291a; --sd-motion:160ms;
  --sd-safe-top:env(safe-area-inset-top,0px); --sd-safe-bottom:env(safe-area-inset-bottom,0px);
  --sd-density:24px; --sd-nav-width:230px;
}
* { box-sizing:border-box; }
html { font:100%/1.6 var(--sd-font); background:var(--sd-bg); color:var(--sd-ink); }
body { margin:0; min-width:0; }
button,input,select,textarea { font:inherit; color:inherit; }
button,a,input,select,textarea,summary { touch-action:manipulation; }
button,.button,.case-button,.case-link,.action,.top-action,.rail-action,.mini-action {
  min-height:44px; border:1px solid var(--sd-line); border-radius:9px;
  background:var(--sd-surface); padding:9px 16px; font-size:.9375rem;
  cursor:pointer; text-decoration:none; display:inline-flex; gap:8px; align-items:center; justify-content:center;
}
button:hover,a.button:hover,.case-button:hover,.action:hover { background:var(--sd-accent-soft); }
button:disabled { background:var(--sd-disabled); color:var(--sd-muted); cursor:not-allowed; }
.primary,.success,.accent,.send,.v10-home-primary { background:var(--sd-accent); color:white; border-color:var(--sd-accent); }
.primary:hover,.send:hover,.v10-home-primary:hover { background:#124e41; color:white; }
.danger,.danger-zone { color:var(--sd-danger); }
a { color:var(--sd-accent); text-underline-offset:4px; }
a:hover { text-decoration-thickness:2px; }
:focus-visible { outline:3px solid var(--sd-focus); outline-offset:3px; }
h1,h2,h3,h4,p { margin:0 0 16px; }
h1 { font-size:var(--sd-title); line-height:1.12; letter-spacing:-.045em; font-weight:550; }
h2 { font-size:1.5rem; line-height:1.3; letter-spacing:-.025em; font-weight:550; }
h3 { font-size:1.1rem; font-weight:600; }
h4 { font-size:1rem; }
p { max-width:72ch; }
small,.help,.muted,.legend,.sub,.learning-muted { color:var(--sd-muted); font-size:var(--sd-text-sm); }
[hidden],.hidden { display:none!important; }
.v10-skip,.skip,.skip-link,.v10-product-skip { position:fixed; top:8px; left:8px; transform:translateY(-150%); z-index:2000; background:white; padding:12px; }
.v10-skip:focus,.skip:focus,.skip-link:focus,.v10-product-skip:focus { transform:none; }
.v10-top { padding:16px clamp(16px,4vw,48px); padding-top:calc(16px + var(--sd-safe-top)); display:flex; align-items:center; gap:24px; border-bottom:1px solid var(--sd-line); min-height:76px; }
.v10-brand { font-size:1.15rem; font-weight:650; text-decoration:none; color:var(--sd-ink); white-space:nowrap; display:flex; gap:10px; align-items:center; }
.v10-symbol { font-size:1.4rem; color:var(--sd-accent); }
.v10-navigation { display:flex; gap:4px; margin-left:auto; align-items:center; }
.v10-navigation a { text-decoration:none; padding:10px 14px; border-radius:8px; color:var(--sd-muted); min-height:44px; }
.v10-navigation a[aria-current=page] { color:var(--sd-accent); background:var(--sd-accent-soft); }
.v10-nav-mobile { display:none; margin-left:auto; position:relative; }
.v10-nav-mobile summary { list-style:none; cursor:pointer; padding:10px; }
.v10-nav-mobile[open] .v10-navigation { position:absolute; right:0; z-index:100; width:210px; padding:12px; background:white; box-shadow:var(--sd-shadow); flex-direction:column; align-items:stretch; border:1px solid var(--sd-line); border-radius:12px; }
.v10-preferences { margin-left:auto; }
.v10-preferences summary { cursor:pointer; font-size:.875rem; padding:10px; }
.v10-preferences[open] .v10-mode-picker { position:absolute; right:16px; z-index:105; background:white; padding:12px; border:1px solid var(--sd-line); border-radius:12px; box-shadow:var(--sd-shadow); }
.v10-mode-picker { display:flex; flex-wrap:wrap; gap:8px; align-items:center; }
.v10-mode-picker button[aria-pressed=true] { background:var(--sd-accent-soft); color:var(--sd-accent); }
.v10-page { width:min(1280px,100%); margin:0 auto; padding:clamp(24px,5vw,64px) clamp(16px,4vw,48px); }
.v10-page.narrow { max-width:900px; }
.v10-breadcrumb { display:flex; flex-wrap:wrap; gap:10px; margin-bottom:24px; font-size:.875rem; color:var(--sd-muted); }
.v10-page-heading { display:flex; flex-wrap:wrap; gap:24px; justify-content:space-between; align-items:flex-end; margin-bottom:36px; }
.v10-page-heading p { margin:12px 0 0; color:var(--sd-muted); }
.eyebrow,.learning-kicker,.control-kicker,.sheet-kicker,.v10-home-step { font-size:.75rem; letter-spacing:.12em; text-transform:uppercase; color:var(--sd-muted); font-weight:650; }
.v10-home { max-width:960px; padding-top:clamp(64px,12vh,140px); }
.v10-home h1 { max-width:15ch; margin-bottom:24px; }
.v10-home .lead { font-size:1.15rem; color:var(--sd-muted); margin-bottom:36px; }
.v10-home-primary { display:inline-flex; padding:16px 24px; border-radius:12px; text-decoration:none; font-weight:600; min-height:56px; }
.v10-choice-list { margin-top:40px; border-top:1px solid var(--sd-line); }
.v10-choice { display:flex; gap:24px; justify-content:space-between; align-items:center; padding:24px 0; border-bottom:1px solid var(--sd-line); text-decoration:none; color:var(--sd-ink); }
.v10-choice h2 { margin:0 0 5px; font-size:1.2rem; }
.v10-choice p { margin:0; color:var(--sd-muted); }
.v10-choice .arrow { color:var(--sd-accent); font-size:1.4rem; }
.v10-depth-nav { display:flex; gap:4px; flex-wrap:wrap; min-width:0; margin-bottom:24px; padding-bottom:12px; border-bottom:1px solid var(--sd-line); }
.v10-depth-nav button { background:transparent; border-color:transparent; padding:8px 12px; }
.v10-depth-nav button[aria-pressed=true] { background:var(--sd-accent-soft); color:var(--sd-accent); }
.v10-section { padding:var(--sd-density) 0; border-bottom:1px solid var(--sd-line); min-width:0; }
.v10-section:last-child { border-bottom:0; }
.v10-section-header { display:flex; align-items:center; gap:16px; flex-wrap:wrap; justify-content:space-between; margin-bottom:18px; }
.v10-section-header h2,.v10-section-header h3 { margin:0; }
.v10-actions,.action-row,.row,.dialog-actions,.sheet-actions,.prompt-actions,.trainer-toolbar,.rail-action-row { display:flex; flex-wrap:wrap; gap:12px; align-items:center; }
.v10-status,.status-chip,.console-chip,.mode-pill { border-radius:20px; padding:4px 10px; background:var(--sd-accent-soft); font-size:.8125rem; color:var(--sd-accent); display:inline-flex; align-items:center; gap:6px; }
.v10-alert,.notice,.notice-box,.cost-guard-alert,.error-box.show,.case-refresh-error,.v10-status-banner { padding:16px; border-radius:10px; background:var(--sd-warning-soft); color:var(--sd-warning); margin:12px 0; overflow-wrap:anywhere; }
.notice.danger,.v10-alert[data-severity=error],.cost-guard-alert,.error-box.show { background:var(--sd-danger-soft); color:var(--sd-danger); }
.notice.info,.notice-box { background:var(--sd-accent-soft); color:var(--sd-accent); }
.error-box:not(.show):empty,#page-error:empty,#detail-error:empty,#approval-error:empty { display:none; }
.empty,.empty-state,.empty-box,.loading,.loading-line { padding:24px 0; color:var(--sd-muted); }
input:not([type=checkbox]):not([type=radio]),select,textarea { border:1px solid var(--sd-line); border-radius:9px; background:white; width:100%; padding:12px; min-height:44px; }
input[type=checkbox],input[type=radio] { width:20px; height:20px; accent-color:var(--sd-accent); }
textarea { min-height:110px; resize:vertical; }
label { display:block; }
.field label { margin-bottom:8px; font-weight:550; }
.form-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:24px; }
.field.full { grid-column:1/-1; }
.checks { display:flex; flex-wrap:wrap; gap:16px; }
.checks label { display:flex; align-items:center; gap:8px; }
.table-wrap,.learning-table-wrap,.v10-table { overflow-x:auto; max-width:100%; }
table { width:100%; border-collapse:collapse; text-align:left; font-size:.875rem; }
th { color:var(--sd-muted); font-weight:550; background:var(--sd-bg); }
th,td { padding:14px; border-bottom:1px solid var(--sd-line); vertical-align:top; }
td { overflow-wrap:anywhere; }
code,pre,.code-id,.json-area { font-family:var(--sd-mono); font-size:.8125rem; }
pre { overflow:auto; white-space:pre-wrap; overflow-wrap:anywhere; padding:20px; background:var(--sd-surface); border-radius:10px; }
.code-id { color:var(--sd-muted); overflow-wrap:anywhere; }
dialog { border:1px solid var(--sd-line); border-radius:var(--sd-radius); padding:24px; background:var(--sd-surface); color:var(--sd-ink); width:min(680px,calc(100vw - 24px)); max-height:calc(100dvh - 32px); overflow:auto; box-shadow:var(--sd-shadow); }
dialog::backdrop { background:#18251d66; }
.dialog-head,.modal-head,.sheet-head { display:flex; flex-wrap:wrap; align-items:center; gap:16px; justify-content:space-between; margin-bottom:20px; }
.dialog-body,.modal-body,.sheet-body { min-width:0; }
.dialog-actions { margin-top:24px; justify-content:flex-end; }
.modal,.drawer { display:none; position:fixed; inset:0; z-index:150; background:#18251d66; padding:16px; align-items:center; justify-content:center; }
.modal.show,.drawer.show { display:flex; }
.sheet,.modal-card { width:min(760px,100%); max-height:calc(var(--v10-viewport-height,100dvh) - 32px); overflow:auto; padding:24px; background:white; border-radius:14px; box-shadow:var(--sd-shadow); }
.v10-interview-page { height:calc(min(var(--v10-viewport-height,100dvh),100dvh) - var(--v10-top-height,77px)); display:grid; grid-template-rows:auto minmax(0,1fr); overflow:hidden; }
.v10-interview-heading { flex-wrap:wrap; padding:16px clamp(16px,4vw,48px); display:flex; justify-content:space-between; align-items:center; gap:12px; border-bottom:1px solid var(--sd-line); }
.v10-interview-heading h1 { font-size:1.25rem; letter-spacing:-.02em; margin:0; }
.v10-interview-heading .v10-actions { gap:6px; }
.v10-interview-heading .v10-status { max-width:200px; }
.v10-interview-grid { display:grid; grid-template-columns:minmax(0,1fr); min-height:0; }
.v10-interview-grid[data-context-open=true] { grid-template-columns:minmax(0,1fr) minmax(300px,390px); }
.v10-conversation { display:grid; grid-template-rows:minmax(0,1fr) auto; min-height:0; min-width:0; background:var(--sd-surface); }
.v10-safety-strip { padding:8px clamp(16px,4vw,48px); font-size:.875rem; border-bottom:1px solid var(--sd-line); }
.v10-safety-strip[data-urgent=true] { background:var(--sd-danger-soft); color:var(--sd-danger); }
.chat-scroll { overflow-y:auto; overscroll-behavior:contain; min-height:0; padding:32px clamp(16px,5vw,64px); scroll-padding:24px; }
.msg { width:min(100%,740px); margin:0 auto 28px; overflow-wrap:anywhere; }
.msg-meta { font-size:.75rem; letter-spacing:.06em; color:var(--sd-muted); margin-bottom:8px; }
.provider-badge { display:none; }
.msg-bubble { line-height:1.7; white-space:pre-wrap; }
.msg.user .msg-bubble { background:var(--sd-bg); padding:16px 20px; border-radius:12px; }
.msg.user { max-width:640px; margin-left:auto; }
.msg.ai .msg-bubble { font-size:1.0625rem; }
.msg.system .msg-bubble,.system-bubble { font-size:.875rem; color:var(--sd-muted); }
.msg .turn-summary { display:none; }
.msg .diagnosis-card { white-space:normal; }
.composer-shell { border-top:1px solid var(--sd-line); padding:16px clamp(16px,4vw,48px); padding-bottom:calc(16px + var(--sd-safe-bottom)); background:white; }
.composer { display:flex; align-items:flex-end; gap:8px; max-width:800px; margin:auto; }
.composer textarea { flex:1; min-height:50px; max-height:clamp(50px,24dvh,180px); resize:none; height:50px; }
.composer .send,.sd-microphone { width:50px; height:50px; min-width:50px; padding:10px; }
.composer-hint { max-width:800px; margin:8px auto 0; color:var(--sd-muted); font-size:.75rem; }
.v10-context { overflow:auto; min-width:0; container-type:inline-size; border-left:1px solid var(--sd-line); padding:clamp(16px,3vw,24px); background:var(--sd-bg); }
.v10-context .v10-section-header { gap:12px; align-items:center; margin-bottom:16px; }
.v10-context .v10-section-header h2 { font-size:1.15rem; flex:1; }
.v10-context .v10-section-header button { font-size:.875rem; padding:8px 10px; }
.v10-context .v10-depth-nav { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:4px; margin-bottom:16px; padding-bottom:12px; }
.v10-context .v10-depth-nav button { padding:10px 4px; min-width:0; overflow-wrap:anywhere; font-size:.875rem; }
@container (min-width:420px) { .v10-context .v10-depth-nav { grid-template-columns:repeat(4,minmax(0,1fr)); } }
.v10-context section { min-width:0; }
.v10-context pre { max-width:100%; }
.v10-context .v10-fact button { max-width:100%; }

.v10-fact,.fact-row,.mobile-fact { padding:16px 0; border-bottom:1px solid var(--sd-line); }
.fact-id,.mobile-fact-id { color:var(--sd-accent); font-family:var(--sd-mono); font-size:.8rem; }
.fact-meta,.mobile-fact-meta { display:flex; flex-wrap:wrap; gap:8px; color:var(--sd-muted); font-size:.75rem; }
.diff-row,.final-row { padding:16px 0; border-bottom:1px solid var(--sd-line); }
.diff-row-head { display:flex; justify-content:space-between; gap:12px; }
.diff-evidence { font-size:.875rem; margin-top:8px; }
.mnm { border-left:3px solid var(--sd-danger); padding-left:12px; }
.v10-spend { min-width:70px; font-variant-numeric:tabular-nums; }
.v10-budget-ring { width:16px; height:16px; border-radius:50%; background:var(--sd-line); position:relative; }
.v10-budget-ring::after { content:''; position:absolute; inset:4px; border-radius:50%; background:white; }
.v10-spend-detail p { margin:8px 0; }
.v10-workspace { display:grid; grid-template-columns:210px minmax(0,1fr); min-height:calc(100dvh - 77px); }
.v10-workspace-nav { padding:32px 20px; border-right:1px solid var(--sd-line); }
.v10-workspace-nav button { display:flex; width:100%; justify-content:flex-start; border:0; background:transparent; margin-bottom:4px; }
.v10-workspace-nav button[aria-current=page] { background:var(--sd-accent-soft); color:var(--sd-accent); }
.v10-workspace-body { padding:32px clamp(16px,4vw,48px); min-width:0; }
.view { display:none; }
.view.active { display:block; }
.v10-metrics,.metric-grid,.identity-card,.status-panel,.score-grid,.detail-summary { display:grid; grid-template-columns:repeat(auto-fit,minmax(140px,1fr)); gap:24px; padding:20px 0; }
.metric .k,.score-label { color:var(--sd-muted); font-size:.8125rem; display:block; }
.metric .v,.score-value { font-size:1.65rem; font-weight:550; display:block; }
.charts { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:24px; }
.chart canvas { width:100%; height:140px; }
.chart h3 { font-size:.875rem; }
.console-head { display:flex; align-items:center; flex-wrap:wrap; gap:12px; margin-bottom:20px; }
.console-live { display:flex; flex-wrap:wrap; gap:6px; }
.console-title { font-size:1.15rem; }
.spacer,.case-spacer { flex:1; }
.terminal { font-family:var(--sd-mono); font-size:.8125rem; overflow:auto; background:white; padding:20px; min-height:300px; max-height:65vh; border:1px solid var(--sd-line); border-radius:12px; }
.log-line { white-space:pre-wrap; overflow-wrap:anywhere; padding:5px 0; }
.log-line.error,.error { color:var(--sd-danger); }
.log-line.warn,.warn { color:var(--sd-warning); }
.log-line.selected-exception { background:var(--sd-warning-soft); }
.learning-tabs { display:flex; flex-wrap:wrap; gap:8px; margin:24px 0; }
.learning-tabs button.active { background:var(--sd-accent-soft); color:var(--sd-accent); }
.learning-panel { display:none; }
.learning-panel.active { display:block; }
.learning-panel-head { display:flex; justify-content:space-between; gap:24px; margin-bottom:24px; }
.learning-entry,.trainer-detail,.learning-block,.trainer-mode-card,.section { padding:24px 0; border-bottom:1px solid var(--sd-line); }
.trainer-mode-card { display:flex; flex-wrap:wrap; gap:24px; align-items:center; }
.trainer-mode-copy { flex:1; min-width:220px; }
.trainer-switch { display:flex; gap:12px; align-items:center; }
.trainer-switch i { display:none; }
.recovery-summary { display:flex; flex-wrap:wrap; gap:24px; margin:24px 0; }
.recovery-summary span,.recovery-summary b { display:block; }
.recovery-summary span { color:var(--sd-muted); font-size:.75rem; }
.schematic-moves { white-space:nowrap; }
.schematic-moves button { padding:8px; margin:3px; }
.schematic-id { font-family:var(--sd-mono); font-size:.75rem; color:var(--sd-muted); }
.v10-case-grid { display:block; }
.v10-case-item { padding:24px 0; border-bottom:1px solid var(--sd-line); }
.v10-case-heading,.v10-case-footer,.v10-case-actions { display:flex; align-items:center; gap:16px; justify-content:space-between; }
.v10-case-heading h3 { font-size:1.2rem; margin:0; }
.v10-case-kicker,.v10-case-subtitle,.v10-case-metadata { margin:0; color:var(--sd-muted); font-size:.8125rem; }
.v10-case-diagnosis { margin:12px 0; font-size:.875rem; }
.v10-case-diagnosis span { margin-right:12px; color:var(--sd-muted); }
.v10-case-metadata span { display:block; }
.v10-searchbar { display:flex; gap:24px; align-items:flex-end; margin:24px 0; }
.v10-searchbar label:first-child { flex:1; }
.v10-searchbar input[type=search] { margin-top:8px; }
.v10-archive { display:flex; gap:8px; align-items:center; min-height:44px; }
.v10-list-head { display:flex; justify-content:space-between; }
.case-card { padding:24px 0; border-bottom:1px solid var(--sd-line); }
.case-card-head { display:flex; align-items:center; gap:16px; margin-bottom:16px; }
.case-card-head h2 { margin:0; }
.case-card-body { min-width:0; }
.case-compose { margin-top:20px; }
.intake-chat { max-height:55vh; overflow-y:auto; padding:20px 0; }
.intake-message,.chat-message,.timeline-event,.event-card,.section-block { padding:16px 0; border-bottom:1px solid var(--sd-line); }
.tool-stack { display:flex; flex-wrap:wrap; gap:12px; }
.tool-output { overflow-wrap:anywhere; }
.choice-card { color:var(--sd-ink); display:flex; gap:20px; text-align:left; padding:28px 0; border:0; border-bottom:1px solid var(--sd-line); background:transparent; width:100%; text-decoration:none; justify-content:flex-start; }
.choice-card p { margin:8px 0; }
.choice-card h2 { margin:0; }
.department-chips { display:flex; flex-wrap:wrap; gap:8px; margin-top:12px; }
.department-other { display:flex; gap:8px; margin-top:12px; }
.mode-banner { display:flex; gap:16px; flex-wrap:wrap; padding:16px; background:var(--sd-accent-soft); border-radius:12px; }
.footer-actions { display:flex; flex-wrap:wrap; gap:12px; padding:20px 0; align-items:center; }
.review-nav { display:flex; flex-wrap:wrap; gap:8px; margin:24px 0; }
.review-section,.proposal-card { padding:24px 0; border-bottom:1px solid var(--sd-line); }
.mobile-action-toast { position:fixed; bottom:20px; left:50%; transform:translateX(-50%); padding:12px 20px; background:var(--sd-ink); color:white; border-radius:10px; display:none; z-index:500; width:max-content; max-width:calc(100vw - 32px); }
.mobile-action-toast.show { display:block; }
.footer-note { font-size:.8125rem; color:var(--sd-muted); padding:32px 0; }
html[data-v10-presentation=professional] { --sd-density:16px; }
html[data-v10-presentation=professional] .chat-scroll { padding-top:20px; }
html[data-v10-presentation=professional] .msg { margin-bottom:20px; }
html[data-v10-presentation=professional] td,html[data-v10-presentation=professional] th { padding:10px; }
@media(min-width:1440px) { .v10-page { max-width:1440px; } .v10-interview-grid[data-context-open=true] { grid-template-columns:minmax(0,1fr) 440px; } }
@media(max-width:1023px) { .v10-navigation { gap:0; } .v10-navigation a { padding:10px; } .v10-workspace { grid-template-columns:170px minmax(0,1fr); } }
/* Six destinations need the existing menu at tablet widths; do not widen the page. */
@media(min-width:768px) and (max-width:1023px) {
  .v10-top>.v10-navigation { display:none; }
  .v10-nav-mobile { display:block; }
  .v10-preferences { margin:0; }
}
@media(max-width:767px) {
  .v10-top { padding:12px 16px; padding-top:calc(12px + var(--sd-safe-top)); gap:12px; min-height:64px; }
  .v10-top>.v10-navigation { display:none; } .v10-nav-mobile { display:block; } .v10-preferences { margin:0; }
  .v10-page { padding:32px 16px; } .v10-home { padding-top:64px; }
  .v10-page-heading { margin-bottom:24px; }
  .v10-interview-heading { flex-wrap:wrap; padding:12px 16px; flex-wrap:wrap; }
  .v10-interview-heading h1 { font-size:1.05rem; }
  .v10-interview-heading .v10-actions { margin-left:auto; }
  .v10-interview-heading button { padding:8px; min-width:44px; }
  .v10-interview-grid[data-context-open=true] { grid-template-columns:minmax(0,1fr); }
  .v10-interview-grid[data-context-open=true]>.v10-conversation { display:none; }
  .v10-context { border-left:0; }
  .chat-scroll { padding:24px 16px; } .composer-shell { padding:12px 16px; padding-bottom:calc(12px + var(--sd-safe-bottom)); }
  .composer { gap:6px; } .composer .send,.sd-microphone { width:44px; min-width:44px; height:48px; }
  .composer-hint { font-size:.75rem; }
  .v10-workspace { display:block; }
  .v10-workspace-nav { display:flex; gap:4px; padding:12px 16px; border-right:0; border-bottom:1px solid var(--sd-line); overflow-x:auto; }
  .v10-workspace-nav button { width:auto; white-space:nowrap; padding:8px 12px; margin:0; }
  .v10-workspace-body { padding:24px 16px; }
  .charts { grid-template-columns:1fr; }
  .v10-searchbar,.v10-case-footer { flex-direction:column; align-items:stretch; gap:12px; }
  .v10-case-heading { align-items:flex-start; }
  .v10-case-actions { justify-content:flex-start; flex-wrap:wrap; }
  .form-grid { grid-template-columns:minmax(0,1fr); gap:20px; }
  .learning-panel-head { display:block; } .v10-choice { gap:12px; }
  .sheet,.modal-card { padding:20px; }
}
@media(max-width:359px) { .v10-brand { font-size:1rem; } .v10-preferences summary { padding:8px 4px; } .v10-interview-heading { gap:8px; } .v10-interview-heading .v10-status { font-size:.75rem; } }
@media(prefers-reduced-motion:reduce) { *,*::before,*::after { scroll-behavior:auto!important; transition:none!important; animation:none!important; } }
@media print { .v10-top,.composer-shell,.v10-actions,.v10-depth-nav,.v10-workspace-nav { display:none; } .v10-interview-page { height:auto; overflow:visible; } .chat-scroll { overflow:visible; } }

/* Shared conversation and review components, including dynamically mounted automation. */
.v10-interview-heading .v10-safety-strip { flex:1 0 100%; padding:8px 0 0; border:0; }
.v10-conversation:has(>.pb-status.show) { grid-template-rows:auto minmax(0,1fr) auto; }
.chat-bubble { line-height:1.7; margin:0 0 24px; overflow-wrap:anywhere; }
.chat-bubble.user { background:var(--sd-bg); padding:16px 20px; border-radius:12px; }
.chat-bubble.system { font-size:.875rem; color:var(--sd-muted); }
.review-section { display:none; }
.review-section.active { display:block; }
.edit-controls,.edit-banner { display:none; }
.editing .edit-controls,.editing .edit-banner { display:block; }
.editing .compare-readonly { display:none; }
.compare,.field-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:24px; }
.compare.stacked { grid-template-columns:minmax(0,1fr); }
.compare-pane { min-width:0; }
.edit-field { margin-bottom:16px; }
.edit-field.full { grid-column:1/-1; }
.execution-flow { display:flex; flex-wrap:wrap; align-items:center; gap:8px; }
.flow-node { padding:8px 12px; border-radius:8px; background:var(--sd-accent-soft); font-size:.875rem; }
.exception-card { padding:20px 0; border-bottom:1px solid var(--sd-line); }
.exception-card-head,.exception-meta { display:flex; justify-content:space-between; flex-wrap:wrap; gap:12px; }
.exception-meta { font-family:var(--sd-mono); font-size:.75rem; color:var(--sd-muted); }
@media(max-width:767px) { .compare,.field-grid { grid-template-columns:minmax(0,1fr); } }

.v10-case-incomplete { border-inline-start:3px solid var(--sd-warning); padding-inline-start:16px; }
.config-compare { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:24px; }
.exception-nav { display:flex; flex-wrap:wrap; gap:8px; padding:16px 0; }
.approval-workflow:disabled { color:var(--sd-muted); background:var(--sd-disabled); }
@media(max-width:767px) { .config-compare { grid-template-columns:minmax(0,1fr); } }
@media(any-pointer:coarse) { button,.button,.case-button,.action { min-height:48px; } }
/* Reserve shell space before JavaScript mounts navigation; avoid header layout shift. */
[data-v10-shell] { min-height:var(--v10-top-height,76px); }
.composer textarea { min-width:0; }
.composer .sd-microphone.sd-recording { width:80px; min-width:80px; padding:6px; gap:4px; }
@media(max-width:767px) { [data-v10-shell] { min-height:var(--v10-top-height,64px); } }
.sd-audio-state { display:flex; flex-wrap:wrap; align-items:center; gap:8px; max-width:800px; margin:8px auto 0; color:var(--sd-muted); font-size:.8125rem; }
.sd-audio-state button { min-height:40px; padding:6px 12px; }

.v10-login-error { min-height:1.5em; color:var(--sd-danger); }
#sd-admin-login { max-width:440px; }

/* Reserve conversation space when the device keyboard reduces usable height. */
@media (max-width:760px), (max-height:550px) {
  body[data-v10-destination=interview] .v10-top { padding:6px 16px; min-height:56px; }
  body[data-v10-destination=interview] .v10-top>.v10-navigation { display:none; }
  body[data-v10-destination=interview] .v10-nav-mobile { display:block; }
  .v10-interview-heading { padding:6px 16px; gap:6px; flex-wrap:wrap; }
  .v10-interview-heading>div:first-child { flex:1; min-width:72px; }
  .v10-interview-heading h1 { font-size:1rem; margin:0; }
  .v10-interview-heading [data-v10-case-context] { font-size:.75rem; line-height:1.3; }
  .v10-interview-heading #v10-connection[data-idle=true] { display:none; }
  .v10-interview-heading .v10-actions { gap:4px; }
  .v10-interview-heading .v10-actions button { padding:6px 8px; font-size:.875rem; }
  .v10-interview-heading .v10-safety-strip { padding:0; font-size:.8125rem; line-height:1.3; }
  .composer-shell { padding-top:8px; padding-bottom:calc(8px + var(--sd-safe-bottom)); }
  .composer-shell>label { margin:0 0 4px; font-size:.75rem; }
  .composer-hint { margin-top:4px; }
}
@media (max-width:340px) {
  .v10-interview-heading { padding-inline:8px; }
  .v10-interview-heading [data-v10-case-context] { max-width:90px; display:block; }
}

@media (max-width:760px) {
  .v10-case-item { padding:16px 0; }
  .v10-case-heading { flex-wrap:wrap; align-items:flex-start; gap:8px; }
  .v10-case-heading>div { flex:1 1 100%; }
  .v10-case-heading h3 { font-size:1.1rem; }
  .v10-case-footer { gap:12px; }
}

.v10-case-identity { display:flex; align-items:center; gap:12px; flex-wrap:wrap; margin:4px 0; }

.v10-schematic-sequence { list-style:none; padding:0; margin:24px 0; }
.v10-schematic-step { display:grid; grid-template-columns:32px minmax(0,1fr) auto; gap:16px; padding:20px 0; border-bottom:1px solid var(--sd-line); }
.v10-schematic-number { color:var(--sd-muted); font-variant-numeric:tabular-nums; }
.v10-schematic-body>div { margin:8px 0; }
.v10-schematic-body .help { margin:8px 0; }
.v10-schematic-body details { margin:8px 0; }
@media(max-width:600px) { .v10-schematic-step { grid-template-columns:24px minmax(0,1fr); gap:8px; } .v10-schematic-step .schematic-moves { grid-column:2; } }

/* On a short visual viewport, keep safety and the response controls reachable.
   Navigation remains available through the composer tools dialog. */
.v10-compact-tools { display:none; }
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] [data-v10-shell] { display:none; }
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .v10-interview-heading { padding:4px 12px; gap:2px; }
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .v10-interview-heading h1,
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .v10-interview-heading>.v10-actions { display:none; }
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .v10-interview-heading [data-v10-case-context] { display:block; line-height:1.2; max-width:95vw; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .composer-shell { padding:6px 12px; }
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .composer-shell>label { position:absolute; width:1px; height:1px; padding:0; overflow:hidden; clip-path:inset(50%); }
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .composer-hint { display:none; }
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .composer textarea { min-height:44px; height:44px; max-height:clamp(44px,24dvh,80px); }
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .v10-compact-tools { display:inline-flex; width:44px; min-width:44px; padding:6px; }
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .composer .send,
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .composer .sd-microphone { width:44px; height:44px; min-width:44px; }

:root[data-v10-ultra-short-viewport=true] body[data-v10-destination=interview] .v10-interview-heading>div:first-child { display:none; }
:root[data-v10-ultra-short-viewport=true] body[data-v10-destination=interview] .v10-interview-heading { padding:1px 6px; }
:root[data-v10-ultra-short-viewport=true] body[data-v10-destination=interview] .composer-shell { padding:1px 6px; }

/* Interview focus: edge swipe or accessible handle reveals the full controls. */
body[data-v10-chat-focus=true] .v10-interview-heading{display:none!important}
body[data-v10-chat-focus=true] .v10-interview-page{grid-template-rows:minmax(0,1fr)}
.v10-conversation{position:relative;grid-template-rows:auto auto auto minmax(0,1fr) auto}
#v10-chat-controls{position:absolute;top:0;left:auto;right:8px;transform:none;z-index:3;min-height:44px;min-width:64px;padding:0 16px;border:0;background:linear-gradient(#fff,#ffffffa8);color:var(--sd-accent);border-radius:0 0 18px 18px;font-size:24px;touch-action:none}
body[data-v10-chat-focus=true] .chat-scroll{padding-top:12px;padding-bottom:12px}
body[data-v10-chat-focus=true] .msg{margin-bottom:16px}
body[data-v10-chat-focus=true] .msg:last-child{margin-bottom:0}
body[data-v10-chat-focus=true] .msg-meta{margin-bottom:4px}
body[data-v10-chat-focus=true] .msg.user .msg-bubble{padding-block:10px}
.v10-chat-notice,.v10-chat-safety{padding:8px 76px 8px 16px;font-size:.8125rem;line-height:1.4;background:var(--sd-bg);color:var(--sd-ink)}
.v10-chat-safety,.v10-chat-notice[data-review=true]{background:var(--sd-danger-soft);color:var(--sd-danger)}
.v10-chat-notice[hidden],.v10-chat-safety[hidden]{display:none}
body[data-v10-chat-focus=true] .composer-shell>label,body[data-v10-chat-focus=true] .composer-hint{display:none}
body[data-v10-chat-focus=true] .composer-shell{padding-top:6px;padding-bottom:calc(6px + var(--sd-safe-bottom))}
/* Explicit reveal remains usable even after the on-screen keyboard shrinks the viewport. */
body[data-v10-chat-focus=false] [data-v10-shell]{display:block!important}
body[data-v10-chat-focus=false] .v10-interview-heading>div:first-child,
body[data-v10-chat-focus=false] .v10-interview-heading h1{display:block!important}
body[data-v10-chat-focus=false] .v10-interview-heading>.v10-actions{display:flex!important}
body[data-v10-destination=interview]{overscroll-behavior-y:none}
.v10-conversation>.v10-chat-bar{grid-row:1}
.v10-conversation>.v10-chat-notice{grid-row:2}
.v10-conversation>.v10-chat-safety{grid-row:3}
.v10-conversation>.chat-scroll{grid-row:4}
.v10-conversation>.composer-shell{grid-row:5}

/* Keep only essential status and cost while the interview controls are collapsed. */
.v10-chat-bar{display:flex;align-items:center;gap:8px;min-height:44px;padding:0 8px;border-bottom:1px solid var(--sd-line)}
.v10-chat-bar[hidden]{display:none}
.v10-chat-bar>.v10-actions{display:flex;flex:1;min-width:0;gap:8px}
.v10-chat-bar .v10-status{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:.75rem}
.v10-chat-bar .v10-actions>[data-v10-context],.v10-chat-bar .v10-actions>[data-open-layer]{display:inline-flex}
.v10-chat-bar :is(button,#v10-chat-controls){position:static;transform:none;min-height:44px;height:44px;padding:4px 8px;border:0;background:transparent}
.v10-chat-bar #v10-chat-controls{min-width:44px;font-size:20px}

/* One brand and one set of primary links; secondary work stays inside Menu. */
.v10-top{display:grid;grid-template-columns:auto 1fr auto;gap:16px;min-height:64px;padding:8px clamp(16px,4vw,48px)}
.v10-top>.v10-navigation{display:flex!important;margin-left:auto}
.v10-top>.v10-nav-mobile{display:block!important;margin-left:0}
.v10-nav-mobile summary{min-height:44px;display:flex;align-items:center;padding:0 10px}
.v10-menu-links{position:absolute;right:0;top:100%;z-index:105;width:min(270px,calc(100vw - 32px));padding:8px;background:var(--sd-surface,#fff);border:1px solid var(--sd-line);border-radius:12px;box-shadow:var(--sd-shadow)}
.v10-nav-mobile[open]>.v10-menu-links{display:grid}
.v10-nav-mobile:not([open])>.v10-menu-links{display:none}
.v10-menu-links>a{display:block;padding:10px 12px;min-height:44px;text-decoration:none;border-radius:8px}
.v10-menu-links>a:hover{background:var(--sd-accent-soft)}
.v10-menu-links .v10-preferences{margin:0}
.v10-menu-links .v10-preferences[open] .v10-mode-picker{position:static;box-shadow:none;display:flex;gap:8px;flex-wrap:wrap;padding:8px}
.v10-home{padding-top:clamp(24px,5vh,56px)}
.v10-home .lead{margin-bottom:24px}.v10-home .v10-choice-list{margin-top:28px}
@media(max-width:767px){
 .v10-top,body[data-v10-destination=interview] .v10-top{grid-template-columns:minmax(0,1fr) auto;gap:0 8px;padding:0 16px;min-height:0}
 .v10-top>.v10-brand{grid-column:1;grid-row:1;min-height:44px}
 .v10-top>.v10-nav-mobile{grid-column:2;grid-row:1}
 .v10-top>.v10-navigation{grid-column:1/-1;grid-row:2;margin:0;gap:4px}
 .v10-top>.v10-navigation>a{flex:1;text-align:center;padding:8px;min-height:44px}
}
.v10-menu-links{max-height:calc(100dvh - 96px);overflow-y:auto;overscroll-behavior:contain}
.v10-top{padding-top:calc(8px + var(--sd-safe-top))}
@media(max-width:767px){.v10-top,body[data-v10-destination=interview] .v10-top{padding-top:var(--sd-safe-top)}}
@media print{.v10-top{display:none!important}}

/* Personal workspace and cases-first home. */
.sd-account-control{display:flex;align-items:center;gap:10px;min-width:0;margin-left:auto;font-size:.85rem}
.sd-account-name{max-width:150px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:var(--sd-muted)}
.sd-signin-link{white-space:nowrap;font-weight:600;font-size:.85rem;min-height:40px;padding:8px 12px;border:1px solid var(--sd-line);border-radius:24px;text-decoration:none}
.sd-case-home{max-width:1240px;padding-top:44px}.sd-case-home h1{margin:8px 0 12px}/* Keep the search controls below the independently scrollable case list. */
.sd-case-home .v10-searchbar{display:grid;grid-template-columns:minmax(0,2fr) repeat(2,minmax(0,1fr));gap:16px;align-items:start;margin:24px 0 0;padding:20px;background:var(--sd-surface);border:1px solid var(--sd-line);border-radius:16px}
.sd-case-home .v10-searchbar label,.sd-case-home .v10-searchbar label:first-child{display:flex;flex-direction:column;gap:6px;min-width:0;width:100%;margin:0;text-align:start}
.sd-case-home .v10-searchbar input[type=search],.sd-case-home .v10-searchbar select{width:100%;min-width:0;margin:0}
.sd-case-home .v10-searchbar .v10-archive{grid-column:1/-1;flex-direction:row;align-items:center;justify-content:flex-start;gap:10px;min-height:44px}
.sd-case-home .v10-archive input{flex:0 0 20px;margin:0}
.sd-case-home #case-table-host:has(article[data-case-id]){max-height:65vh;max-height:min(65svh,48rem);overflow-y:auto;overflow-x:hidden;scrollbar-gutter:stable;padding:3px}
.sd-case-home #case-table-host .sd-hospital-unit:first-child{margin-top:0}
@media(min-width:640px) and (max-width:1023px){.sd-case-home .v10-searchbar{grid-template-columns:repeat(2,minmax(0,1fr))}.sd-case-home .v10-searchbar label:first-child{grid-column:1/-1}}
@media(max-width:639px){.sd-case-home .v10-searchbar{grid-template-columns:minmax(0,1fr);gap:12px;padding:16px}}
.sd-case-home .v10-list-head{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin-top:28px}.sd-view-toggle{margin-left:auto;display:flex;gap:4px}.sd-view-toggle button[aria-pressed=true]{background:var(--sd-accent-soft);border-color:var(--sd-accent);color:var(--sd-accent)}
[data-case-layout=cards] .v10-case-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}[data-case-layout=cards] .v10-case-item{padding:24px;background:white;border:1px solid var(--sd-line);border-radius:18px;box-shadow:0 4px 18px #143c2f05;min-width:0;display:flex;flex-direction:column;gap:12px}[data-case-layout=cards] .v10-case-footer{margin-top:auto;flex-wrap:wrap}[data-case-layout=cards] .v10-case-heading h3{font-size:1.18rem;margin:0 0 8px}.sd-setting-badge{display:inline-flex;align-self:flex-start;justify-self:start;font-size:.75rem;letter-spacing:.02em;font-weight:650;padding:5px 10px;background:#eef1ee;color:#4a6056;border-radius:7px;width:fit-content}.sd-setting-badge[data-setting=ICU]{background:#f6e8e5;color:#8b4237}.sd-setting-badge[data-setting=WARD]{background:#e8f2ee;color:#245b47}.sd-setting-badge[data-setting=EMERGENCY]{background:#fbefd9;color:#866016}.sd-empty-cases{text-align:center;padding:48px 24px;border:1px dashed #b7c9bf;border-radius:20px;margin:24px 0;background:linear-gradient(135deg,#f0f6f1,#fff)}.sd-empty-cases p{color:var(--sd-muted);margin:12px auto 24px;max-width:420px}.sd-empty-symbol{display:inline-grid;place-items:center;border-radius:50%;background:#e3eee5;width:64px;height:64px;font-size:36px;color:var(--sd-accent);margin-bottom:16px}.sd-home-intro{border-top:1px solid var(--sd-line);margin-top:52px;padding-top:40px}.sd-home-intro h2{margin:12px 0}.sd-home-intro .lead{color:var(--sd-muted);max-width:540px}.sd-home-intro .v10-home-primary{gap:40px;margin:12px 0 24px}.sd-signin-panel{margin:36px auto;background:#fff;border:1px solid var(--sd-line);border-radius:24px;padding:40px;max-width:600px}.sd-account-emblem{font-size:44px;color:var(--sd-accent)}#google-signin-button{margin:28px 0}#signin-status{color:var(--sd-muted)}
@media(max-width:767px){.sd-account-control{gap:6px}.sd-account-name{max-width:80px;font-size:.75rem}.sd-signin-link{padding:8px;font-size:.75rem}.sd-case-home{padding-top:28px}[data-case-layout=cards] .v10-case-grid{grid-template-columns:1fr}.sd-signin-panel{padding:24px;margin-top:12px}.sd-case-home .v10-page-heading{align-items:start;flex-wrap:wrap}.sd-case-home .v10-searchbar{padding:16px}.sd-case-home .v10-list-head h2{font-size:1rem}.sd-view-toggle{margin-left:0}.sd-account-name{display:none}.v10-top .v10-brand{font-size:1rem}}
/* Exact named hospital units own their case layout. */
.sd-case-home .v10-case-grid{display:block!important}.sd-hospital-unit{margin:32px 0 40px}.sd-unit-heading{display:flex;gap:14px;align-items:center;flex-wrap:wrap;padding:18px 0;border-bottom:1px solid var(--sd-line);margin-bottom:18px}.sd-unit-heading h2{margin:0;flex:1;font-size:1.3rem;color:var(--sd-accent);overflow-wrap:anywhere}.sd-unit-heading .button{font-size:.85rem}.sd-unit-cases{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}.sd-unit-cases article[hidden],.sd-hospital-unit[hidden]{display:none!important}.sd-case-unit{font-size:.8rem;color:var(--sd-muted);margin:0}.sd-case-home .sd-unit-cases .v10-case-heading h3{overflow-wrap:anywhere}
@media(max-width:767px){.sd-unit-cases{grid-template-columns:1fr}.sd-unit-heading h2{flex-basis:100%}.sd-unit-heading .button{margin-left:auto}.sd-account-name{display:block;max-width:68px}.v10-top{gap:6px}.sd-account-control{gap:4px}}
@media(max-width:1023px){body:not([data-v10-destination=interview]) .v10-top{flex-wrap:wrap}body:not([data-v10-destination=interview]) .v10-top>.v10-navigation{display:flex;order:5;flex-basis:100%;justify-content:center;margin:4px 0 -4px;gap:6px}body:not([data-v10-destination=interview]) .v10-top>.v10-navigation a{flex:1;text-align:center;padding:8px;min-height:40px}}
@media(max-width:359px){.sd-account-name{display:none}.v10-top{padding-left:12px;padding-right:12px}}

.v10-nav-mobile{display:block;margin-left:0}
@media(max-width:359px){.sd-account-control[data-signed-in=true] .sd-account-name{display:block;max-width:52px}.v10-top:has(.sd-account-control[data-signed-in=true]) .v10-brand span:last-child{font-size:.86rem}}

.case-secondary-actions{position:relative}.case-secondary-actions>summary{list-style:none;cursor:pointer;min-width:44px;min-height:44px;display:grid;place-items:center;border:1px solid #d9dfda;border-radius:12px;font-size:24px}
.case-secondary-actions>div{position:fixed;z-index:30;width:min(244px,calc(100vw - 32px));max-height:min(360px,calc(100dvh - 32px));overflow:auto;padding:8px;background:var(--surface,#fff);border:1px solid #d9dfda;border-radius:12px;box-shadow:0 6px 18px #0002;white-space:normal;word-break:normal;overflow-wrap:break-word}
.case-secondary-actions>div .case-button{display:block;width:100%;min-height:44px;text-align:left;padding:10px 12px;white-space:normal}
.v10-case-setting-inline{display:none}

/* List is a real compact row at phone widths too. The unit header owns location;
 * identity/assessment stay left, Open/menu right, without a second card shell. */
[data-case-layout=list] .sd-unit-cases{display:block}
[data-case-layout=list] .v10-case-item{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:6px 12px;align-items:center;padding:14px 0;margin:0;border:0;border-bottom:1px solid var(--sd-line);border-radius:0;background:transparent;box-shadow:none}
[data-case-layout=list] .sd-setting-badge{display:none}
[data-case-layout=list] .v10-case-heading{grid-column:1;grid-row:1;min-width:0}
[data-case-layout=list] .v10-case-heading h3{font-size:17px;margin:0 0 4px}
[data-case-layout=list] .v10-case-setting-inline{display:inline-flex;font-size:12px;font-weight:600}
[data-case-layout=list] .v10-case-kicker{font-size:12px;margin:4px 0}
[data-case-layout=list] .v10-case-diagnosis{grid-column:1;grid-row:2;line-height:1.4;font-size:12px}
[data-case-layout=list] .v10-case-diagnosis>span,[data-case-layout=list] .v10-case-metadata{display:none}
[data-case-layout=list] .v10-case-footer{grid-column:2;grid-row:1/span 2;margin:0;align-self:center}
[data-case-layout=list] .v10-case-actions{align-items:center}
[data-case-layout=list] .v10-case-identity{flex-wrap:wrap;font-size:12px}
@media(max-width:359px){[data-case-layout=list] .v10-case-item{gap:6px}[data-case-layout=list] .v10-case-actions{gap:4px}[data-case-layout=list] .v10-case-actions .case-button{font-size:13px;padding:6px}}

/* Daily diagnostic export fits beside existing console actions and wraps on phones. */
.server-report-day{display:inline-flex;align-items:center;gap:6px;font-size:.8125rem;min-width:0}
.server-report-day input{min-height:40px;max-width:160px;padding:6px;border:1px solid var(--sd-line,#d8ded8);border-radius:10px;background:var(--sd-surface,#fff);color:inherit}
.server-report-download{min-width:64px;min-height:44px;white-space:nowrap}
.server-report-status{font-size:.8125rem;max-width:28rem;overflow-wrap:anywhere}

/* One viewport owner: the shell and composer stay anchored while only chat scrolls.
   visualViewport offset follows Android keyboard panning, including desktop-site mode. */
body[data-v10-destination=interview][data-workspace=interview]{position:fixed;inset:auto 0 auto;top:var(--v10-viewport-top,0px);height:var(--v10-viewport-height,100dvh);display:flex;flex-direction:column;overflow:hidden}
.sd-case-home [data-case-layout=cards] .v10-case-item{padding:16px;gap:8px}
.sd-case-home [data-case-layout=cards] .v10-case-heading h3{margin:0 0 4px;font-size:1.1rem}
.sd-case-home .v10-case-diagnosis{display:flex;flex-wrap:wrap;gap:4px 8px;margin:0;font-size:.75rem}
.sd-case-home .v10-case-diagnosis span{margin:0}
.sd-case-home .v10-case-footer{gap:8px;align-items:stretch;flex-direction:column}
.sd-case-home .v10-case-metadata .code-id{display:none}
.sd-case-home .v10-case-actions{gap:8px;flex-wrap:nowrap}
.sd-case-home .v10-case-actions .case-button{flex:0 1 auto;min-width:0;padding:8px}
body[data-v10-destination=interview] [data-v10-shell]{flex:none;min-height:0;display:block!important}
body[data-v10-destination=interview] .v10-interview-page{flex:1;min-height:0;height:auto;margin:0}
body[data-v10-destination=interview] .v10-interview-grid,.v10-conversation{min-height:0;overflow:hidden}
body[data-v10-destination=interview] .chat-scroll{padding:16px clamp(12px,3vw,32px);scroll-behavior:auto;overflow-anchor:none}
body[data-v10-destination=interview] .msg{margin-bottom:16px}
body[data-v10-destination=interview] .msg-bubble{line-height:1.5}
body[data-v10-destination=interview] .composer-shell{position:relative;padding:8px clamp(12px,3vw,32px);padding-bottom:calc(8px + var(--sd-safe-bottom));flex:none}
body[data-v10-destination=interview] .composer{max-width:900px;align-items:center}
body[data-v10-destination=interview] .composer textarea{min-width:0;width:0;font-size:16px;max-height:min(120px,25vh)}
body[data-v10-destination=interview] .v10-chat-bar{gap:4px;min-height:44px;padding:0 8px}
body[data-v10-destination=interview] #v10-chat-controls{position:static;transform:none;min-width:44px;border-radius:4px;background:transparent;touch-action:manipulation}
body[data-v10-destination=interview] .v10-chat-bar .v10-actions{gap:4px}
.v10-top{grid-template-columns:auto minmax(0,1fr) auto auto}
.sd-account-name{white-space:normal;overflow:visible;text-overflow:clip;overflow-wrap:anywhere;max-width:240px;line-height:1.35}
.sd-account-control{flex-wrap:wrap}.sd-signin-link{flex-shrink:0}
.sd-menu-account{padding:8px 12px;margin:0;white-space:normal;overflow-wrap:anywhere;font-size:.875rem}
.v10-menu-primary{display:none!important}
@media(max-width:1023px){
 body[data-v10-chat-focus=true] .v10-menu-primary{display:block!important}
 .v10-top,body[data-v10-destination=interview] .v10-top{grid-template-columns:minmax(0,1fr) auto;gap:0 8px;padding-block:0}
 .v10-top>.v10-brand{grid-column:1;grid-row:1;min-height:44px}
 .v10-top>.v10-nav-mobile{grid-column:2;grid-row:1}
 .v10-top>.v10-navigation{grid-column:1/-1;grid-row:2;margin:0}
 .v10-top>.sd-account-control{grid-column:1/-1;grid-row:3;margin:0;width:100%;padding:2px 0 6px;justify-content:space-between;flex-wrap:nowrap}
 .v10-top .sd-account-name,.sd-account-control[data-signed-in=true] .sd-account-name{display:block;max-width:none;flex:1;font-size:.8125rem}
 .v10-top .sd-signin-link{min-height:36px;padding:4px 10px;font-size:.8125rem}
 body[data-v10-chat-focus=true] .v10-top>.v10-navigation{display:none!important}
 body[data-v10-destination=interview] .v10-top{padding-inline:12px}
 body[data-v10-destination=interview] .v10-chat-bar .v10-status{max-width:120px}
}
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .v10-top>.v10-navigation,
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .sd-account-control{display:none!important}
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .v10-top{padding-block:0;min-height:44px}
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .v10-brand{font-size:1rem}
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .v10-top>.v10-navigation{display:none!important}
:root[data-v10-short-viewport=true] body[data-v10-destination=interview] .v10-menu-primary{display:block!important}
:root[data-v10-ultra-short-viewport=true] body[data-v10-destination=interview] [data-v10-shell]{display:none!important}
/* Landscape IME can leave only ~70px. Reserve the answer row first; secondary
   status/cost waits until the keyboard closes. Safety/recovery text stays scrollable. */
:root[data-v10-ultra-short-viewport=true] body[data-v10-destination=interview] .v10-chat-bar{display:none!important}
:root[data-v10-ultra-short-viewport=true] body[data-v10-destination=interview] .v10-conversation{grid-template-rows:0 minmax(0,auto) minmax(0,auto) minmax(0,1fr) auto}
:root[data-v10-ultra-short-viewport=true] body[data-v10-destination=interview] :is(.v10-chat-notice,.v10-chat-safety){min-height:0;max-height:max(0px,calc((var(--v10-viewport-height) - 50px)/2));padding:0 6px;overflow:auto}
:root[data-v10-ultra-short-viewport=true] body[data-v10-destination=interview] .chat-scroll{padding:0 6px}
:root[data-v10-ultra-short-viewport=true] body[data-v10-destination=interview] .composer :is(button,.sd-microphone){height:44px;min-height:44px}
/* Release notices are overlays, never another row that displaces the answer field. */
.ui-update-notice{position:fixed;top:4px;right:8px;z-index:2000;display:flex;align-items:center;gap:8px;max-width:calc(100vw - 16px);padding:6px 10px;background:var(--sd-ink);color:white;border-radius:8px;font-size:.8125rem}
.ui-update-notice button{min-height:36px;padding:4px 10px}

.v10-menu-links .ui-update-notice{position:static;max-width:100%;flex-wrap:wrap;box-sizing:border-box;margin:4px 0}

/* Structured server diagnostics: restrained semantic colour, readable on phones. */
#server-terminal .log-line{padding:12px;border-bottom:1px solid var(--sd-line);border-left:3px solid transparent;white-space:normal;}
#server-terminal .log-line.error{border-left-color:var(--sd-danger);background:color-mix(in srgb,var(--sd-danger) 3%,white);}
#server-terminal .log-line.warn{border-left-color:var(--sd-warning);}
.log-heading{display:flex;align-items:baseline;gap:10px;flex-wrap:wrap;line-height:1.6;}
.log-time{color:var(--sd-muted);font-size:.75rem;}.log-severity{font-size:.65rem;letter-spacing:.06em;font-weight:700;}.log-event{font-weight:600;overflow-wrap:anywhere;}
.log-metadata{display:flex;flex-wrap:wrap;gap:8px 20px;margin:8px 0 0;color:var(--sd-ink);font-size:.75rem;}
.log-metadata>div{min-width:0;max-width:100%;}.log-metadata dt{color:var(--sd-muted);font-size:.65rem;}.log-metadata dd{margin:2px 0 0;overflow-wrap:anywhere;}
.console-diagnostics{margin-top:18px;}.console-diagnostics summary{font-weight:600;cursor:pointer;}

/* Interview entry exposes two direct actions, with distinct touch targets. */
.v10-interview-actions{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,240px),1fr));gap:14px;margin:24px 0;max-width:720px}
.v10-interview-actions .v10-home-primary{justify-content:center;align-items:center;margin:0}

/* Selected tabs describe the current destination; other tabs remain one tap away. */
.v10-navigation a[aria-current="page"]{pointer-events:none;cursor:default}

/* Secondary navigation is grouped; primary pages remain in the header. */
.v10-menu-links{width:min(440px,calc(100vw - 24px));gap:8px;grid-template-columns:repeat(auto-fit,minmax(170px,1fr));max-height:calc(100dvh - 100px);overflow:auto;overscroll-behavior:contain}
.v10-menu-group{min-width:0;padding:6px;border-radius:8px}.v10-menu-group h2{font-size:.7rem;text-transform:uppercase;letter-spacing:.06em;color:var(--sd-muted);margin:4px 10px 8px}
.v10-menu-group>a,.v10-menu-group>button{display:block;width:100%;padding:10px 12px;min-height:44px;border:0;text-align:left;text-decoration:none;border-radius:8px;background:transparent;color:var(--sd-ink)}
.v10-menu-group>a:hover,.v10-menu-group>button:hover{background:var(--sd-accent-soft)}
.v10-menu-group:has(>#v10-empty-case-archive[hidden]){display:none}.ui-update-notice{grid-column:1/-1}
@media(max-width:380px){.v10-menu-links{grid-template-columns:1fr}}

/* Confirmed actions paint locally before network synchronization. */
@media(prefers-reduced-motion:no-preference){button,a.button{transition:transform 120ms ease,background-color 120ms ease}button:active,a.button:active{transform:scale(.98)}::view-transition-old(root),::view-transition-new(root){animation-duration:150ms}}

/* More specific forms grouped under their broader diagnosis (SDV10UI.groupedDiagnoses). */
.dx-forms{margin:2px 0 8px 14px;padding-left:10px;border-left:2px solid currentColor;border-left-color:color-mix(in srgb,currentColor 25%,transparent)}
.dx-forms>summary{cursor:pointer;font-size:.9em;opacity:.8;padding:4px 0}
