/* Investigation remains the parent; evidence is a view of its existing draft. */
body:has(.investigation-layout){background:#f7f7f2}
.finder.investigation-layout{max-width:1440px;padding-top:28px}
.investigation-layout>h1{font-size:clamp(2rem,4vw,3.5rem);margin:12px 0;letter-spacing:-.045em}
.investigation-breadcrumb{font-size:.82rem;color:#53606b;letter-spacing:.035em;border-top:1px solid #dce0e3;padding-top:24px}
.investigation-save{font-size:.85rem;color:#425a48;overflow-wrap:anywhere}
.investigation-layout .guided-nav{display:flex;border-bottom:1px solid #cbd2dc;gap:24px;margin-bottom:0}
.investigation-layout .guided-nav button{border:0;border-radius:0;background:transparent;padding:16px 4px;color:#526074;border-bottom:3px solid transparent}
.investigation-layout .guided-nav button[aria-current]{color:#254bdf;border-bottom-color:#254bdf;background:transparent;font-weight:700}
.investigation-desk{display:grid;grid-template-columns:minmax(190px,.9fr) minmax(0,2fr) minmax(210px,1fr);align-items:start;gap:18px;margin:22px 0}
.investigation-changes,.investigation-selected,.investigation-desk .workspace-next-action{min-width:0;border:1px solid #dce0e3;border-radius:12px;background:#fff;padding:20px;margin:0;overflow-wrap:anywhere}
.investigation-desk h2{font-size:1.15rem;line-height:1.4;margin:0 0 14px;letter-spacing:-.02em}
.investigation-desk h3{font-size:1.2rem;line-height:1.5}
.investigation-desk p{font-size:.9rem;line-height:1.6}
.investigation-count,.investigation-location{color:#586575;font-size:.8rem!important}
.investigation-event-list{display:grid;gap:9px;max-height:600px;overflow:auto}
.investigation-event-list button{display:block;text-align:start;white-space:normal;font:inherit;font-size:.85rem;border:1px solid #dce0e3;border-radius:8px;background:#fff;color:#253247;padding:13px;width:100%;cursor:pointer;line-height:1.5}
.investigation-event-list button[aria-pressed=true]{border-color:#254bdf;background:#f0f3ff;box-shadow:inset 3px 0 #254bdf}
.investigation-event-kind{display:block;color:#254bdf;font-size:.72rem;font-weight:700;margin-bottom:6px}
.investigation-eyebrow{color:#254bdf;font-size:.7rem!important;letter-spacing:.1em;font-weight:700;margin:0 0 14px}
.investigation-selected blockquote{margin:16px 0;border-left:3px solid #254bdf;background:#f5f6fa;padding:14px 18px;font-size:.95rem;white-space:pre-wrap}
.investigation-selected details{margin:20px 0;font-size:.85rem;border-top:1px solid #e1e5e9;padding-top:14px}
.investigation-selected summary{cursor:pointer;font-weight:600}
.investigation-decision{border-top:1px solid #dce0e3;margin-top:24px;padding-top:24px}
.investigation-desk .workspace-next-action{border-top:4px solid #254bdf}
.investigation-desk .text-action{display:inline-block;padding:12px 0;line-height:1.5}
.investigation-desk[data-stage="0"],.investigation-desk[data-stage="3"]{grid-template-columns:1fr}
.investigation-desk[data-stage="0"]>.investigation-changes,.investigation-desk[data-stage="0"]>.investigation-selected,.investigation-desk[data-stage="3"]>.investigation-changes,.investigation-desk[data-stage="3"]>.investigation-selected{display:none}
.investigation-layout>#team-onboarding{margin-bottom:12px}
.investigation-layout>.review-handoff{margin:16px 0}
@media(max-width:1000px){.investigation-desk{grid-template-columns:minmax(180px,.8fr) minmax(0,1.6fr)}.investigation-desk>.workspace-next-action{grid-column:1/-1}}
@media(max-width:740px){.finder.investigation-layout{padding:22px 18px}.investigation-layout .guided-nav{display:grid;grid-template-columns:1fr 1fr;gap:4px 14px}.investigation-desk{display:flex;flex-direction:column;gap:14px}.investigation-desk>*{width:100%;box-sizing:border-box}.investigation-changes,.investigation-selected,.investigation-desk .workspace-next-action{padding:18px}.investigation-event-list{max-height:210px}.investigation-desk h2{font-size:1.12rem}.investigation-desk blockquote{margin-inline:0}.investigation-save{line-height:1.6}}
/* Functional dependency workspace: selected event, affected work, review action. */
.investigation-desk[data-stage="0"],.investigation-desk[data-stage="3"]{grid-template-columns:minmax(190px,.9fr) minmax(0,2fr) minmax(210px,1fr)}
.investigation-desk[data-stage="0"]>.investigation-changes,.investigation-desk[data-stage="0"]>.investigation-selected,.investigation-desk[data-stage="3"]>.investigation-changes,.investigation-desk[data-stage="3"]>.investigation-selected{display:block}
.dependency-banner{border:1px solid #cbd8d2;background:#eff5ef;border-radius:10px;padding:16px 20px;margin:20px 0}.dependency-banner.has-alert{background:#fff2d6;border-color:#e5bd65}.dependency-banner p{margin:6px 0;font-size:.88rem}.dependency-banner a{font-size:.85rem}
.dependency-comparison{display:grid;grid-template-columns:1fr 1fr;gap:12px}.dependency-comparison section{min-width:0;background:#f5f6fa;padding:14px;border-radius:8px;font-size:.85rem}.dependency-comparison section+section{background:#eef2ff}.dependency-comparison blockquote{padding:0;border:0;background:transparent;margin:12px 0;font-size:.88rem}
.dependency-graph{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:18px 0}.dependency-node{border:1px solid #ced8eb;border-top:3px solid #254bdf;border-radius:8px;padding:14px;min-width:0;background:#f4f6fc}.dependency-node strong,.dependency-node small{display:block}.dependency-node small{margin-top:10px}.dependency-node.paused{background:#fff0f0;border-color:#df9c9c}.dependency-node.at-risk{background:#fff5de;border-color:#dab556}
.dependency-badge{display:inline-block;padding:3px 8px;margin:8px 0;font-size:.75rem;border-radius:20px;background:#e8edf7;color:#233c70}.dependency-badge.paused{background:#ffe1e1;color:#8d2020}.dependency-badge.at-risk{background:#ffe9ae;color:#684809}.dependency-badge.completed{background:#e4f2e6;color:#245c34}
.dependency-secondary{border:1px solid #dce0e3;background:white;border-radius:10px;padding:18px;margin:12px 0}.dependency-secondary>summary{cursor:pointer;font-weight:600;min-height:26px}.dependency-secondary form{max-width:650px;padding:20px 0}.dependency-secondary label,.dependency-resolution label{display:block;margin:14px 0;font-size:.85rem}.dependency-secondary input,.dependency-secondary select,.dependency-resolution textarea{box-sizing:border-box;display:block;width:100%;margin-top:6px;font:inherit;padding:10px;border:1px solid #aab6c5;border-radius:6px;background:white;color:#1e293b}.dependency-resolution input[type=checkbox]{margin-right:8px}.dependency-resolution textarea{min-height:74px}.dependency-resolution h3{font-size:1rem}.dependency-resolution[hidden]{display:none}.dependency-resolution{border-top:1px solid #dce0e3;margin-top:20px;padding-top:16px}.dependency-feedback{color:#713d10}.dependency-task{padding:18px 0;border-top:1px solid #dce0e3}.dependency-task button{margin:8px 8px 0 0}.dependency-task input{max-width:600px}.investigation-desk .workspace-next-action>a{display:block;font-size:.85rem;margin-top:14px}.dependency-secondary button,.dependency-resolution button{min-height:44px;cursor:pointer}.dependency-secondary button:disabled{opacity:.5;cursor:not-allowed}
@media(max-width:1000px){.investigation-desk[data-stage="0"],.investigation-desk[data-stage="3"]{grid-template-columns:minmax(180px,.8fr) minmax(0,1.6fr)}}
@media(max-width:740px){.dependency-comparison,.dependency-graph{grid-template-columns:1fr}.dependency-secondary{padding:16px}.investigation-desk>.investigation-changes{order:0}.investigation-desk>.investigation-selected{order:1}.investigation-desk>.workspace-next-action{order:2}.dependency-banner{padding:14px}.dependency-resolution textarea{font-size:16px}.dependency-secondary input,.dependency-secondary select{font-size:16px}}
body:has(.investigation-layout) .astra-language-bar{padding:6px 30px;gap:12px}body:has(.investigation-layout) .astra-language-bar label{width:auto;display:inline;margin:0}body:has(.investigation-layout) .astra-language-bar select{width:auto;display:inline-block;min-width:120px;min-height:34px}body:has(.investigation-layout) .astra-language-bar p{max-width:none;font-size:11px}
.finder.investigation-layout>.investigation-header{position:relative;top:auto;padding:10px 16px;margin:10px 0 16px;border:1px solid #dce0e3;border-radius:8px;box-shadow:none;background:#fff;display:flex;align-items:start;justify-content:space-between;gap:18px}.investigation-header details{flex:1;font-size:.85rem}.investigation-header summary{cursor:pointer;font-weight:600;padding:8px 0}.investigation-header .investigation-actions{margin:0}.investigation-layout>.document-lede{font-size:1rem;margin:12px 0;max-width:100%}.investigation-layout>.guided-intro{display:none}.investigation-layout>.beta-flag{font-size:.7rem;margin:8px 0}.investigation-layout>.investigation-breadcrumb{border:0;padding:0;margin:8px 0}.investigation-layout>p:has(>a[href="/monitoring.html"]){display:none}.finder.investigation-layout>h1{font-size:2.2rem;line-height:1.15;margin:10px 0}.program-page .document-body.finder>.investigation-desk{padding:0;border:0;background:transparent;border-radius:0}.investigation-layout .investigation-selected p{max-width:100%}.investigation-layout .guided-nav{margin-top:12px}.investigation-layout .investigation-selected section{margin:0;border:0}.investigation-layout .dependency-banner{margin:16px 0}.investigation-layout .investigation-desk{margin:16px 0}html:has(.investigation-layout){scroll-padding-top:24px}
@media(max-width:740px){.finder.investigation-layout>.investigation-header{display:block}.investigation-header .investigation-actions{margin-top:8px}body:has(.investigation-layout) .astra-language-bar{padding:6px 18px}body:has(.investigation-layout) .astra-language-bar p{flex-basis:100%}.finder.investigation-layout>h1{font-size:1.9rem}}
/* Reveal only the tools needed for the current step. */
.investigation-layout .investigation-desk.focused-step{display:block}.investigation-desk.focused-step>.investigation-changes,.investigation-desk.focused-step>.investigation-selected{display:none!important}.investigation-desk.focused-step>.workspace-next-action{max-width:none;padding:14px 18px}.investigation-desk.focused-step .dependency-resolution{display:none}.dependency-banner[hidden],.investigation-extra[hidden]{display:none!important}
.investigation-extra{border:1px solid #dce0e3;border-radius:10px;background:white;padding:16px;margin:16px 0}.investigation-extra>summary{font-weight:600;cursor:pointer;min-height:28px}.workspace-view-options{font-size:.82rem}.workspace-view-options summary{cursor:pointer}.workspace-view-options button{margin-top:12px}.guided-tools{margin:8px 0 16px}.guided-status{font-size:.8rem}.investigation-layout .workspace-next-action h2{font-size:.8rem;text-transform:uppercase;letter-spacing:.08em;color:#254bdf;margin-bottom:10px}.investigation-layout .workspace-next-action>.text-action{display:inline-block;background:#254bdf;color:white;padding:10px 16px;border-radius:7px;text-decoration:none;font-weight:600}.investigation-layout .workspace-next-action.reviewing-change>strong,.investigation-layout .workspace-next-action.reviewing-change>p:not(.dependency-feedback),.investigation-layout .workspace-next-action.reviewing-change>.text-action{display:none}.investigation-layout .workspace-next-action.reviewing-change .dependency-resolution{border-top:0;margin-top:0;padding-top:0}.investigation-layout .guided-controls{justify-content:flex-end}.investigation-layout .guided-controls .secondary{margin-right:auto}

/* Apply the supplied palette to the existing workspace without moving live forms. */
body:has(.investigation-layout){background:var(--astra-bg);color:var(--astra-text)}
.investigation-layout .guided-nav{gap:.5rem;overflow-x:auto;border-color:var(--astra-border)}
.investigation-layout .guided-nav button{white-space:nowrap;border-radius:9999px;padding:.6rem 1rem;min-height:44px;color:var(--astra-text-secondary);border:0;margin-block:8px}
.investigation-layout .guided-nav button[aria-current]{background:var(--astra-accent);color:white;border:0}
.investigation-layout :is(.investigation-changes,.investigation-selected,.workspace-next-action){border-color:var(--astra-border);background:var(--astra-surface);box-shadow:var(--astra-shadow)}
.investigation-layout .workspace-next-action{border-top-color:var(--astra-accent)}
.investigation-layout .workspace-next-action h2{color:var(--astra-accent)}
.investigation-layout .workspace-next-action>.text-action{background:var(--astra-accent)}
.investigation-layout .workspace-next-action>.text-action:hover{background:var(--astra-accent-hover)}
.investigation-layout .guided-nav button:focus-visible{outline:3px solid var(--astra-accent);outline-offset:2px}
@media(max-width:1024px){.investigation-layout .guided-nav{display:flex;flex-wrap:nowrap}.investigation-layout .guided-nav button{flex:none}}
/* Live shell: existing stage forms retain IDs, state and event listeners. */
body.astra-shell-page{margin:0;overflow:hidden}
.astra-shell-page .astra-app{font-family:inherit}
.astra-shell-page .astra-header{position:relative;padding:0 1.25rem;min-height:64px;max-width:none;border-bottom:1px solid var(--astra-border)}
.astra-shell-page .astra-header .masthead-inner{width:100%;max-width:none;display:flex;align-items:center;gap:12px;padding:8px 0;flex-wrap:wrap}
.astra-shell-page .astra-header .brand{margin-inline-end:auto;flex-shrink:0}
.astra-shell-page .astra-header .status-badge{max-width:240px;overflow-wrap:anywhere}
.astra-shell-page .astra-header .workspace-nav{display:none;position:absolute;top:100%;inset-inline-end:16px;background:white;border:1px solid var(--astra-border);padding:18px;box-shadow:var(--astra-shadow);z-index:60}
.astra-shell-page .astra-header .workspace-nav.menu-open{display:flex;flex-wrap:wrap}
.astra-shell-page .astra-header .nav-toggle{display:block}
.astra-shell-page .main-canvas.finder{width:100%;max-width:none;margin:0;padding:24px;scroll-padding-block:20px}
.astra-shell-page .stage-rail button{width:100%;text-align:start;background:transparent;border:0;font:inherit}
.astra-shell-page .stage-rail button.active{background:#eff6ff;color:var(--astra-accent)}
.astra-shell-page .decision-summary{margin:0;border-radius:0;font-size:.9rem}
.astra-shell-page .summary-content{display:flex;flex-direction:column;gap:24px}
.astra-shell-page .summary-content p{margin:.5rem 0;white-space:pre-wrap;overflow-wrap:anywhere}
.astra-shell-page .summary-section{padding:0;margin:0;border:0}
.astra-shell-page .btn-primary,.astra-shell-page .btn-secondary{display:inline-block;min-height:44px;padding:10px 14px;border-radius:8px;font:inherit;cursor:pointer;border:1px solid var(--astra-accent);text-decoration:none}
.astra-shell-page .btn-primary{background:var(--astra-accent);color:white}
.astra-shell-page .btn-secondary{background:white;color:var(--astra-accent)}
.astra-shell-page .btn-primary:disabled{background:#e5e7eb;color:#4a4a4a;border-color:#d1d5db;cursor:not-allowed}
.astra-shell-page .investigation-desk{display:block!important}
.astra-shell-page .investigation-desk>*{margin-bottom:16px}
.astra-shell-page .stage-progress button{background:transparent;border:0;font:inherit}
.astra-shell-page .stage-progress button[aria-current]{background:var(--astra-accent);color:white}
@media(min-width:1025px){.astra-shell-page .decision-summary>summary{display:none}}
@media(max-width:1024px){
 .astra-shell-page .astra-header{padding:0 12px}
 .astra-shell-page .astra-header .status-badge{order:4;max-width:none;width:100%;font-size:.7rem}
 .astra-shell-page .main-canvas.finder{padding:18px}
 .astra-shell-page .decision-summary .summary-content{padding:12px 0 24px}
 .astra-shell-page .mobile-summary-bar{gap:12px;list-style:none}
 .astra-shell-page .mobile-summary-bar::after{content:'⌃';font-size:1.25rem}
 .astra-shell-page details[open]>.mobile-summary-bar::after{content:'⌄'}
 .astra-shell-page .summary-meta{font-size:.7rem;max-width:45%}
 .astra-shell-page .astra-app.summary-open{padding-bottom:calc(40dvh + env(safe-area-inset-bottom,0px))}
 .astra-shell-page .astra-app.summary-open>.decision-summary{height:40dvh}
 .astra-shell-page .stage-progress{padding:.5rem .75rem}
}
@media print{body.astra-shell-page{overflow:visible}.astra-shell-page .astra-header,.astra-shell-page .decision-summary{position:static}.astra-shell-page .main-canvas.finder{overflow:visible}}
.outcome-workspace{margin-top:28px;border-top:1px solid var(--astra-border);padding-top:24px}
.outcome-workspace .outcome-form[hidden]{display:none}
.outcome-workspace .outcome-form{padding:20px;background:var(--astra-surface);border:1px solid var(--astra-border);border-radius:12px;margin:16px 0}
.outcome-workspace label{display:block;margin:14px 0 6px;font-weight:600}
.outcome-workspace :is(input,textarea,select){width:100%;max-width:100%;box-sizing:border-box;font:inherit;font-size:16px;padding:10px;border:1px solid #aab6c5;border-radius:6px}
.outcome-workspace button{margin:8px 8px 8px 0}
.outcome-workspace pre{white-space:pre-wrap;overflow-wrap:anywhere;font-size:.8rem}
.outcome-record,.learning-status{padding:18px;border:1px solid var(--astra-border);border-radius:10px;margin-block:16px;background:white}
.outcome-workspace [hidden]{display:none!important}
@media(max-width:1024px){.astra-shell-page .astra-app>.stage-progress{display:flex;grid-template-columns:none;gap:8px;overflow-x:auto;min-width:0}.astra-shell-page .stage-progress>button{flex:0 0 auto;width:auto;white-space:nowrap;overflow-wrap:normal;word-break:normal;padding:10px 14px;margin:0}}
.astra-shell-page .masthead-inner .astra-language-bar{order:2;padding:0;gap:6px;margin-inline-start:auto}
.astra-shell-page .masthead-inner .astra-language-bar select{min-width:100px;max-width:140px;font-size:12px}
.astra-shell-page .masthead-inner .astra-language-bar label{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
.astra-shell-page #connect-stage{padding-top:20px}
.astra-shell-page #connect-stage>textarea{width:100%;min-height:100px;box-sizing:border-box}
@media(max-width:1024px){.astra-shell-page .masthead-inner .astra-language-bar{order:3}.astra-shell-page .masthead-inner .astra-language-bar p{flex-basis:auto}}

/* Author display rules must not override the map's collapsed state. */
#investigation-decision-map[hidden]{display:none!important}

.decision-cycle{margin:1.2rem 0;padding:1rem 1.2rem;border:1px solid #b6c6de;border-left:4px solid #3045d4;border-radius:8px;background:#f7f9ff}.decision-cycle h2{margin:0 0 .5rem}.decision-cycle pre{white-space:pre-wrap;overflow-wrap:anywhere;max-height:24rem;overflow:auto}.decision-cycle-form{display:grid;gap:.8rem;max-width:44rem}.decision-cycle-form label{display:grid;gap:.35rem}.decision-cycle-form input[type=checkbox]{width:auto;justify-self:start}.decision-cycle-form button{justify-self:start}.decision-cycle a{display:inline-block;margin:.25rem 0}.decision-cycle details{margin:.6rem 0}

#discovery-trace label{display:block;margin:1rem 0}#discovery-trace textarea{display:block;width:100%;box-sizing:border-box}#discovery-trace input:not([type=checkbox]),#discovery-trace select{max-width:100%;box-sizing:border-box}#discovery-trace button{margin:.4rem .5rem .4rem 0;min-height:44px}#discovery-trace pre,#discovery-trace p,#discovery-trace summary{overflow-wrap:anywhere;white-space:pre-wrap}#discovery-trace details{margin:.8rem 0}#discovery-trace [hidden]{display:none!important}
#discovery-trace{padding:1.4rem;min-width:0}#discovery-trace>h2{margin-top:0}@media(max-width:600px){#discovery-trace{padding:1rem}}
