/* ============================================================
   StepInside × DMC Hub color theme
   Drop-in override — load AFTER the compiled app stylesheet:
     <link rel="stylesheet" href="/stepinside-dmchub-theme.css">
   Maps StepInside's dark-teal + mint palette onto DMC Hub's
   slate + blue system. Only DMC Hub palette values
   are used below. No layout or typography changes.
   DMC Hub tokens referenced:
     bg      #f5f8f8   surfaces #ffffff / #e8f0f2
     ink     #243b49   deep  #1c3557 / #172334 / #294c60
     muted   #50616c   line  #c2d2d8 / #aec8d1
     accent  #1e40af   deep-accent #0a48a9   tint  #eff4ff
   ============================================================ */

/* ---- page root ---- */
:root { color: #f5f8f8; background: #243b49; }
button:focus-visible, a:focus-visible, summary:focus-visible { outline-color: #1e40af; }

/* ---- header / brand ---- */
.game-brand svg { color: #1e40af; }
.game-brand .brand-copy span { color: #aec8d1; }
.private-label { color: #aec8d1; }
.header-controls button { color: #c2d2d8; }
.hub-return { color: #c2d2d8; }

/* ---- headings / overlines ----
   Small accent text on dark uses tint (#eff4ff): saturated blue
   at 11–14px on dark slate falls below 3.5:1, so blue is
   reserved for fills, borders and large graphics. */
.overline { color: #eff4ff; }
.scene-heading p { color: #aec8d1; }
.discovery-pill { color: #d5dde5; border-color: #50616c; }

/* ---- chapter nav ---- */
.scene-nav button { color: #aec8d1; }
.scene-nav button.active { color: #fff; background: #0c51bc; }
.nav-circle { border-color: #50616c; }
.scene-nav .visited .nav-circle { color: #fff; background: #0c51bc; border-color: #1e40af; }
.mobile-chapter-control select { color: #fff; background: #253347; border-color: #50616c; }

/* ---- main play surface ---- */
.play-layout { background: #253347; border-color: #50616c66; }
.discovery-panel { background: #253347; }
.discovery-panel p { color: #c2d2d8; }
.discovery-panel small { color: #aec8d1; }
.discovery-panel summary { color: #eff4ff; }
.discovery-symbol { color: #eff4ff; border-color: #c2d2d8; }
.discovery-dots span { background: #50616c; }
.discovery-dots .complete { background: #0c51bc; }
.scene-caption, .position-art-caption { color: #f5f8f8; background: #253347; }
.room-explorer { background: #253347; }

/* ---- buttons ---- */
.game-button { color: #fff; background: #0c51bc; }
.game-button.secondary { color: #d5dde5; border-color: #50616c; }
.game-button.soft { color: #f5f8f8; background: #294c60; }
.text-button { color: #eff4ff; }

/* ---- hotspots / markers ---- */
.hotspot { color: #fff; background: #0c51bc; }
.hotspot:hover, .hotspot.selected { background: #0a48a9; }
.hotspot.found { background: #0c51bc; }
.hotspot-label { background: #172334; }
.team-marker { color: #fff; background: #0c51bc; }
.team-marker span { background: #172334; }
.anatomy-point { color: #fff; background: #0c51bc; }
.anatomy-point.active, .anatomy-point.seen { background: #0c51bc; }
.anatomy-label { color: #243b49; }
.support-dot { color: #fff; background: #0c51bc; box-shadow: 0 0 0 7px #1e40af33; }
.support-dot.discovered { background: #0c51bc; }
.support-dot > span { color: #243b49; }

/* ---- plan bar / footer ---- */
.plan-bar { color: #c2d2d8; }
.plan-chip { color: #d5dde5; background: #1c3557; }
.scene-footer > span { color: #aec8d1; }
.bottom-links, .bottom-links button { color: #aec8d1; }

/* ---- monitors / feedback (dark) ---- */
.monitor-demo { background: #172334; border-color: #50616c; }
.monitor-head { color: #c2d2d8; }
.monitor-head i { background: #0c51bc; }
.monitor-labels { color: #aec8d1; }
.feedback { color: #eff4ff; border-left-color: #1e40af; }
.route-flow { color: #eff4ff; background: #1c3557; }
.question-button { color: #d5dde5; border-color: #50616c; }
.question-button.selected { color: #fff; background: #0c51bc; border-color: #1e40af; }

/* ---- light scene panels ---- */
.anesthesia-scene, .position-scene, .procedure-scene, .conversation-scene { color: #243b49; background: #f5f8f8; }
.simulation-banner { color: #486777; background: #e8f0f2; }
.anesthesia-path button { color: #50616c; }
.anesthesia-path button:not(:last-child):after { background: #c2d2d8; }
.anesthesia-path button > span { color: #486777; background: #ffffff; border-color: #c2d2d8; }
.anesthesia-path .current > span, .anesthesia-path .past > span { color: #fff; background: #0c51bc; border-color: #1e40af; }
.anesthesia-focus p { color: #50616c; }
.focus-orbit { color: #0a48a9; background: #ffffff; border-color: #c2d2d8; box-shadow: 0 0 0 12px #e8f0f2; }
.orbit-label { background: #0c51bc; }
.patient-notice { color: #0a48a9; background: #eff4ff; }
.sequence-controls .game-button.secondary { color: #0a48a9; border-color: #c2d2d8; }
.diagram-label { color: #486777; }
.position-art-board .diagram-label { background: #e8f0f2; }
.position-illustration { background: #e8f0f2; }
.anatomy-frame { background: #e8f0f2; }
.anatomy-steps { background: #e8f0f2; }
.anatomy-steps button { color: #486777; border-color: #c2d2d8; }
.anatomy-steps .active { color: #fff; background: #0c51bc; border-color: #1e40af; }
.anatomy-explanation { background: #f5f8f8; }
.anatomy-explanation p { color: #50616c; }
.anatomy-comparison { background: #f5f8f8; }
.anatomy-comparison .game-button.secondary { color: #0a48a9; border-color: #c2d2d8; }
.anatomy-comparison small { color: #50616c; }
.anatomy-part-buttons { background: #e8f0f2; }
.anatomy-part-buttons button { color: #486777; background: #ffffff; border-color: #c2d2d8; }
.anatomy-part-buttons .active { color: #fff; background: #0c51bc; border-color: #1e40af; }
.anatomy-footnote { color: #50616c; background: #f5f8f8; }
.anatomy-view-tabs button { color: #486777; background: #ffffff; border-color: #c2d2d8; }
.anatomy-view-tabs .active { color: #fff; background: #0c51bc; border-color: #1e40af; }
.position-choices button { color: #486777; border-color: #c2d2d8; }
.position-choices .chosen { color: #fff; background: #0c51bc; border-color: #1e40af; }
.support-message { color: #0a48a9; background: #eff4ff; }
.slider-box { color: #486777; border-color: #c2d2d8; }
.slider-box [data-slot="slider-track"] { background: #e8f0f2; }
.slider-box [data-slot="slider-range"] { background: #0c51bc; }
.slider-box [data-slot="slider-thumb"] { border-color: #1e40af; }
.procedure-picker { background: #e8f0f2; }
.procedure-select { color: #243b49 !important; }
.conversation-card { color: #243b49; border-color: #c2d2d8; box-shadow: 0 4px #c2d2d8; }
.conversation-card > svg { color: #1e40af; }
.card-number { color: #50616c; }
.card-instruction { color: #50616c; }
.conversation-card.flipped { background: #eff4ff; border-color: #1e40af; box-shadow: 0 4px #1e40af55; }
.conversation-card.flipped .card-number { color: #0a48a9; }
.discovery-passport button { color: #50616c; background: #f5f8f8; border-color: #c2d2d8; }
.discovery-passport .stamped { color: #0a48a9; background: #eff4ff; border-color: #1e40af; }
.setup-chip { color: #0a48a9; background: #eff4ff; }
.access-diagram { background: #e8f0f2; border-color: #c2d2d8; }
.access-diagram span { background: #486777; }
.access-diagram.tubular span:first-child, .access-diagram.tubular span:last-child { background: #c2d2d8; }
.access-diagram.endoscopic span:nth-child(2) { background: #0c51bc; border-color: #1e40af; }
.speech-bubble { color: #243b49; box-shadow: 0 12px 28px #243b4922; }
.speech-bubble span { color: #0a48a9; }
.concern-list button, .mode-buttons button { color: #d5dde5; border-color: #50616c; }
.concern-list .chosen, .mode-buttons .chosen { color: #fff; background: #0c51bc; border-color: #1e40af; }

/* ---- dialogs (light cards) ---- */
.game-dialog { color: #243b49; background: #ffffff; }
.game-dialog p { color: #50616c; }
.game-dialog .overline { color: #1e40af; }
.game-dialog .game-button { color: #fff; background: #0c51bc; }
.game-dialog .text-button { color: #0a48a9; }
.game-dialog .game-button.secondary { color: #0a48a9; border-color: #c2d2d8; }
.game-dialog [data-slot="dialog-description"] { color: #50616c; }
.setup-option { color: #243b49; border-color: #c2d2d8; }
.setup-option:hover { background: #eff4ff; border-color: #1e40af; }
.setup-option small { color: #50616c; }
.question-row { border-color: #c2d2d8; }
.source-list a { color: #0a48a9; }
.pause-circle { color: #0a48a9; border-color: #1e40af; box-shadow: 0 0 0 20px #eff4ff, 0 0 0 40px #eff4ff; }

/* ---- 3D spine scene ---- */
.spine-3d { color: #243b49; background: #f5f8f8; }
.spine-title { color: #c2d2d8; background: #172334; }
.spine-live-dot { background: #0c51bc; box-shadow: 0 0 0 5px #1e40af10; }
.spine-stage { background: radial-gradient(at 50% 44%, #50616c 0%, #1c3557 57%, #172334 100%); }
.spine-stage-note { color: #f5f8f8; }
.spine-camera button { background: #172334db; border-color: #50616c55; }
.spine-camera button:hover { background: #294c60; }
.spine-drag-hint { color: #aec8d1; }
.spine-view-controls { border-bottom-color: #c2d2d8; }
.spine-view-controls button { color: #243b49; border-color: #c2d2d8; }
.spine-view-controls button[aria-pressed="true"] { color: #fff; background: #0c51bc; }
.spine-credits { color: #50616c; border-top-color: #c2d2d8; }
.spine-loading { background: #172334; }
.spine-loading > span { border-color: #50616c; border-top-color: #1e40af; }
.procedure-display-choice { background: #172334; }
.procedure-display-choice button { color: #d5dde5; border-color: #50616c; }
.procedure-display-choice button.active { color: #fff; background: #0c51bc; border-color: #1e40af; }
.spine-scroll-note { color: #50616c; }

/* ---- misc ---- */
.selection-summary > div { border-color: #c2d2d8; }
.reset-journey { border-color: #c2d2d8; }
.skip-link { color: #243b49; }

/* ---- Tailwind color utilities used by the app ---- */
.bg-background { background-color: #243b49; }
.bg-primary { background-color: #1e40af; }
.text-primary { color: #1e40af; }
.text-primary-foreground { color: #ffffff; }
.text-muted-foreground { color: #aec8d1; }
.text-popover-foreground { color: #243b49; }
.border-border { border-color: #50616c; }
.border-input { border-color: #50616c; }
.focus\:bg-accent:focus { background-color: #eff4ff; }
.aria-expanded\:bg-muted[aria-expanded="true"] { background-color: #294c60; }

/* Current interactive controls. Color overrides only; small marker geometry stays intact. */
.experience, .game-header { background-color:#243b49; }
.room-choice, .support-choice {color:#f5f8f8;background:#294c60;border-color:#aec8d1;}
.room-choice.selected, .support-choice.discovered {color:#fff;background:#0c51bc;border-color:#1e40af;}
.room-choice .hotspot-label {background:transparent;color:inherit;}
.team-identities .team-marker {color:#fff;background:#0c51bc;}
.team-identities .team-marker span {color:inherit;background:transparent;}
.game-button.secondary, .game-dialog .game-button.secondary {background:transparent;}
.anatomy-example {color:#50616c;background:#e8f0f2;}
.anatomy-state {color:#0a48a9;background:#eff4ff;}
.spine-view-controls {background:#e8f0f2;}
.spine-view-controls button {background:#fff;}
.spine-view-controls button[aria-pressed="true"] {background:#0c51bc;color:#fff;}
.spine-view-controls [role="switch"] {background:#50616c;}
.spine-view-controls [role="switch"][aria-checked="true"] {background:#0c51bc;}
.spine-view-controls [data-slot="switch-thumb"] {background:#fff;}
.spine-camera button {color:#fff;}
.anatomy-part-buttons button[aria-pressed="true"] {color:#fff;background:#0c51bc;border-color:#1e40af;}
.selection-summary {color:#243b49;}
.game-dialog [data-slot="dialog-title"]:focus-visible {outline-color:#1e40af;}
@media print {html,body,#root,#root>.experience,.print-handout{background:#fff!important;color:#243b49!important;}}

/* Light page shell and reading panels, requested September 21. */
:root, body, .experience {color:#243b49;background:#f5f8f8;}
.game-header {background:#fff;border-bottom-color:#c2d2d8;}
.game-brand {color:#243b49;}
.game-brand .brand-copy span,.header-controls button,.hub-return,.private-label {color:#50616c;}
.overline {color:#0a48a9;}
.scene-heading p,.discovery-pill {color:#50616c;}
.discovery-pill {background:#fff;border-color:#c2d2d8;}
.scene-nav button {color:#50616c;}
.scene-nav button:hover {background:#eff4ff;color:#0a48a9;}
.scene-nav button.active {background:#0c51bc;color:#fff;}
.nav-circle {border-color:#aec8d1;}
.mobile-chapter-control select {color:#243b49;background:#fff;border-color:#c2d2d8;}
.play-layout,.room-explorer,.discovery-panel {color:#243b49;background:#fff;border-color:#c2d2d8;}
.discovery-panel p,.discovery-panel small {color:#50616c;}
.discovery-panel summary,.discovery-symbol {color:#0a48a9;}
.discovery-symbol {border-color:#c2d2d8;}
.discovery-dots span {background:#c2d2d8;}
.discovery-dots .complete {background:#0c51bc;}
.scene-caption,.position-art-caption {background:#e8f0f2;color:#50616c;}
.room-choice,.support-choice {background:#fff;color:#243b49;border-color:#c2d2d8;}
.room-choice.selected,.support-choice.discovered {background:#eff4ff;color:#0a48a9;border-color:#1e40af;}
.text-button,.game-button.secondary {color:#0a48a9;}
.game-button.secondary {border-color:#c2d2d8;}
.plan-bar {color:#50616c;border-color:#c2d2d8;}
.plan-chip {background:#e8f0f2;color:#243b49;}
.scene-footer>span,.bottom-links,.bottom-links button {color:#50616c;}
.question-button {color:#243b49;border-color:#c2d2d8;}
.question-button.selected {color:#0a48a9;background:#eff4ff;border-color:#1e40af;}
.feedback {color:#0a48a9;background:#eff4ff;}
.route-flow {color:#243b49;background:#e8f0f2;}
.concern-list button,.mode-buttons button {color:#243b49;border-color:#c2d2d8;}
.concern-list .chosen,.mode-buttons .chosen {color:#fff;background:#0c51bc;border-color:#1e40af;}
.team-identities .team-marker {color:#0a48a9;background:#eff4ff;}
.bg-background {background-color:#f5f8f8;}
.text-muted-foreground {color:#50616c;}

.scene-caption,.position-art-caption {text-shadow:none;}

/* Design-suite review: legible state colors and calm, consistent feedback. */
:root {--si-action:#0c51bc;--si-action-hover:#0a48a9;--si-focus:#0a48a9;}
.experience {background:linear-gradient(145deg,#eff4ff 0,#f5f8f8 340px,#f5f8f8 100%);}
.anesthesia-path .current,.game-dialog .overline,.text-primary {color:var(--si-action-hover);}
.game-button:not(.secondary):not(.soft):hover {background:var(--si-action-hover);}
button:focus-visible,a:focus-visible,summary:focus-visible,select:focus-visible {outline:3px solid var(--si-focus);outline-offset:3px;}
.spine-credits a {text-decoration:underline;text-underline-offset:3px;}
.spine-credits a[download] {display:inline-flex;align-items:center;min-height:44px;}
.room-choice,.support-choice,.mode-buttons button,.concern-list button,.scene-nav button {transition:background-color 150ms ease-out,border-color 150ms ease-out,color 150ms ease-out;}
@media(prefers-reduced-motion:reduce){.room-choice,.support-choice,.mode-buttons button,.concern-list button,.scene-nav button{transition:none;}}

/* ---- base-theme gap coverage (blue) ----
   The base stylesheet predates the DMC theme; these rules close the
   few selectors the main override does not reach. */
.scene-room { background: #e8f0f2; }
.scene-locator { background: #5c9cf9; box-shadow: 0 0 0 2px #0f172a; }
.image-marker > span { border-color: #5c9cf9; }
.image-marker[aria-pressed='true'] > span { border-color: #0a48a9; }
.experience button.image-marker:focus-visible { outline-color: #0a48a9; }
.model-caption > span { color: #475569; }
.position-art-board .support-dot { box-shadow: 0 0 0 6px #fff6, 0 4px 14px #1e40af30; }
.position-art-board .support-dot > span { background: #ffffff; color: #1e293b; box-shadow: 0 3px 12px #1e40af18; }
