:root {
  color: #10233d;
  background: #f4f7fb;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  --ink: #102b3f;
  --muted: #5c6f86;
  --line: #dce5eb;
  --paper: #fff;
  --navy: #071a2b;
  --blue: #087f9c;
  --teal: #12a6c7;
  --teal-dark: #087f9c;
  --amber: #986000;
  --red: #b52b39;
  --shadow: 0 18px 48px rgba(21, 45, 77, .08);
}
* { box-sizing: border-box; }
.account-shell .account-header { display: flex; align-items: center; gap: 2rem; padding: 1rem clamp(1rem, 4vw, 4rem); color: white; background: var(--navy); border-bottom: 3px solid var(--teal); }
.account-header .brand-logo { width: 180px; height: 62px; object-fit: contain; }
.account-header h1 { margin: 0; font-size: clamp(1.4rem, 3vw, 2rem); color: white; }
.account-header .eyebrow { color: #96dce9; }
.account-header > .button { margin-left: auto; color: white; border-color: #668096; }
#application-shell.account-shell > main.account-main { max-width: 1680px; margin: 0 auto; padding: 1.5rem clamp(1rem, 3vw, 3rem) 3rem; }
.account-filters { display: flex; flex-wrap: wrap; gap: 1rem; align-items: end; padding: 1.2rem; }
.account-filters label { display: grid; flex: 1; min-width: 180px; gap: .4rem; }
.account-filters select, .account-search input, .account-correction input { width: 100%; padding: .75rem; color: var(--ink); background: white; border: 1px solid var(--line); border-radius: .6rem; }
.account-status { margin: 1rem 0; min-height: 2.4rem; }
.account-tabs { display: flex; gap: .5rem; margin: 1.5rem 0; border-bottom: 1px solid var(--line); }
.account-tabs button { min-height: 48px; padding: .9rem 1.5rem; color: var(--muted); background: transparent; border: 0; border-bottom: 3px solid transparent; font-weight: 700; }
.account-tabs button[aria-selected="true"] { color: var(--teal-dark); border-bottom-color: var(--teal-dark); }
.account-search { display: grid; gap: .5rem; max-width: 360px; margin-bottom: 1.2rem; }
.account-board { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; align-items: start; margin-bottom: 1rem; }
.account-column { min-width: 0; padding: 1rem; background: #eaf0f5; border: 1px solid var(--line); border-radius: 1rem; }
.account-column h2 { margin: 0 0 1rem; font-size: 1rem; }
.account-column-in_progress { border-top: 3px solid var(--blue); }
.account-column-completed { border-top: 3px solid #368374; }
.account-task { padding: 1.1rem; margin-bottom: .8rem; background: var(--paper); border: 1px solid var(--line); border-radius: .8rem; box-shadow: 0 3px 12px rgba(21,45,77,.04); }
.account-task:last-child { margin-bottom: 0; }
.account-task h3 { margin: 0 0 .7rem; font-size: 1.1rem; }
.account-task p { font-size: .85rem; line-height: 1.5; margin: .4rem 0; }
.account-task .button { width: 100%; margin-top: .7rem; }
.account-statistics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.account-metric { padding: 1.3rem; }
.account-metric strong { font-size: 2.5rem; font-variant-numeric: tabular-nums; }
.account-correction { max-width: 720px; margin-top: 1.5rem; padding: 1.5rem; }
.account-correction label { display: grid; gap: .4rem; margin: 1rem 0; }
.account-panel .agent-chat { max-width: 1000px; margin: 0 auto; }
@media (max-width: 760px) {
  .account-shell .account-header { gap: 1rem; flex-wrap: wrap; }
  .account-header .brand-logo { width: 130px; height: 48px; }
  .account-board { grid-template-columns: 1fr; }
  .account-statistics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .account-tabs button { padding: .8rem 1rem; }
}
[hidden] { display: none !important; }
body { margin: 0; min-width: 320px; background: linear-gradient(180deg, #eef4fa 0, #f7f9fc 420px); color: var(--ink); }
body, button, input, select, code, td, dd { overflow-wrap: anywhere; }
button, input, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .45; }
a { color: inherit; }
:focus-visible { outline: 3px solid #fff; outline-offset: 2px; box-shadow: 0 0 0 6px #005fcc; }
.skip-link { position: fixed; left: 1rem; top: -5rem; z-index: 100; padding: .8rem 1rem; border-radius: .5rem; background: #fff; }
.skip-link:focus { top: 1rem; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.shell-header { position: sticky; top: 0; z-index: 20; min-height: 78px; padding: 0 clamp(1rem, 4vw, 4.5rem); display: grid; grid-template-columns: minmax(150px, .8fr) minmax(0, 2fr) minmax(110px, .6fr); align-items: center; gap: 2rem; color: #fff; background: radial-gradient(circle at 88% -110%, rgba(18,166,199,.25), transparent 31rem), var(--navy); border-bottom: 1px solid rgba(140,206,230,.16); box-shadow: 0 6px 22px rgba(7,26,43,.12); }
.brand { display: inline-flex; align-items: center; gap: .75rem; text-decoration: none; justify-self: start; }
nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; gap: clamp(.5rem, 2vw, 1.75rem); }
.nav-step { display: flex; min-width: 0; min-height: 48px; gap: .6rem; align-items: center; justify-content: center; padding: .85rem 1.2rem; border: 1px solid transparent; border-radius: 999px; background: transparent; color: #c4d5e3; font-weight: 650; line-height: 1.4; }
.nav-step span { font-size: .68rem; color: #6ed0e5; }
.nav-step.is-active { color: #9beaf6; border-color: rgba(110,208,229,.65); background: transparent; }
.nav-step:not(:disabled):hover { border-color: rgba(110,208,229,.4); }
.connection { justify-self: end; display: flex; align-items: center; gap: .6rem; color: #c4d5e3; font-size: .75rem; }
.connection span { width: .55rem; height: .55rem; border-radius: 50%; background: var(--teal); box-shadow: 0 0 0 .25rem rgba(0,168,149,.13); }
main { min-height: calc(100vh - 130px); }
.screen { max-width: 1640px; margin: 0 auto; padding: 2rem clamp(1rem, 3vw, 3rem) 3rem; }
#screen-plano { max-width: none; }
.screen[hidden] { display: none !important; }
.section-header { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(270px, .65fr); gap: 3rem; align-items: end; margin-bottom: 2.2rem; }
.hero-grid { display: block; margin-bottom: 1.5rem; }
#screen-plano > .section-header { grid-template-columns: 1fr; }
#scenario-refine-button { justify-self: start; }
.eyebrow, .step-label { margin: 0 0 .7rem; color: var(--teal-dark); font-weight: 800; font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; }
h1 { margin: 0; max-width: 840px; color: var(--navy); font-size: clamp(1.8rem, 3vw, 2.6rem); line-height: 1.15; letter-spacing: -.035em; }
.lead { max-width: 780px; margin: .65rem 0 0; color: var(--muted); font-size: 1rem; line-height: 1.6; }
h2 { margin: 0; font-size: 1.25rem; letter-spacing: -.02em; }
.brand-logo { display: block; width: 182px; height: 64px; object-fit: contain; object-position: left center; }
.deployment-logo { display: block; max-width: 140px; max-height: 38px; object-fit: contain; padding: 4px 6px; border-radius: 4px; background: #fff; }
.maestro-avatar { width: 110px; height: 110px; object-fit: contain; justify-self: end; padding: 14px; border-radius: 24px; background: var(--navy); }
.sample-notice { margin: 0 0 1.25rem; }
.workspace-grid { display: grid; gap: 1.25rem; }
.result-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 1.25rem; align-items: start; }
.panel { min-width: 0; background: var(--paper); border: 1px solid var(--line); border-radius: .85rem; padding: clamp(1rem, 1.6vw, 1.5rem); }
.landing-action { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.35fr); align-items: center; gap: clamp(1rem, 3vw, 3rem); }
.landing-illustration { display: block; width: 100%; max-width: 380px; max-height: 220px; object-fit: contain; justify-self: center; }
.landing-action-content { padding: .5rem 0; }
.landing-action-content p { max-width: 600px; margin: .65rem 0 1.3rem; color: var(--muted); line-height: 1.55; }
.recent-plans-panel { margin-top: 1.25rem; }
.recent-plans-panel h2 { margin-bottom: 1rem; }
#recent-plans { list-style: none; margin: 0; padding: 0; }
#recent-plans-status { color: var(--muted); line-height: 1.5; }
.recent-plan-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .8rem 0; border-bottom: 1px solid var(--line); }
.recent-plan-row:last-child { border-bottom: 0; }
@media (max-width: 700px) {
  .landing-action { grid-template-columns: 1fr; }
  .landing-illustration { max-height: 180px; }
  .recent-plan-row { flex-wrap: wrap; }
}
.panel-heading { display: flex; align-items: start; justify-content: space-between; gap: 1rem; margin-bottom: 1.25rem; }
.calendar-panel .status-pill, .upload-panel .status-pill { flex-shrink: 0; white-space: nowrap; }
.status-pill { display: inline-flex; padding: .36rem .65rem; border-radius: 999px; color: var(--amber); background: #fff3d4; font-weight: 750; font-size: .7rem; }
.status-pill.neutral { color: #42617f; background: #edf3f8; }
.status-pill.success { color: #006f61; background: #daf5ef; }
.drop-zone { min-height: 190px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .45rem; border: 1.5px dashed #8fa7bf; border-radius: .8rem; color: var(--muted); background: #f8fbfe; text-align: center; transition: border-color .18s, background .18s; }
.drop-zone.is-over { border-color: var(--teal); background: #eafaf7; }
.drop-zone:focus-within { outline: 3px solid #fff; outline-offset: 2px; box-shadow: 0 0 0 6px #005fcc; border-color: var(--teal); }
.drop-zone input { position: absolute; width: 1px; height: 1px; clip: rect(0,0,0,0); }
.drop-zone strong { color: var(--navy); font-size: 1rem; }
.drop-zone span:last-child { font-size: .78rem; }
.upload-icon { display: grid; place-items: center; width: 2.7rem; height: 2.7rem; border-radius: 50%; background: #e8f0fb; color: var(--blue); font-size: 1.35rem; }
.button-row { display: flex; flex-wrap: wrap; gap: .65rem; margin-top: 1rem; }
.button { border: 1px solid transparent; border-radius: .58rem; padding: .76rem 1rem; font-weight: 750; transition: transform .12s, background .15s; }
.button:not(:disabled):active { transform: translateY(1px); }
.button.primary { background: var(--navy); color: #fff; }
.button.primary:hover { background: #1b4777; }
.button.secondary { color: var(--navy); border-color: #a9bbcf; background: #fff; }
.button.ghost { color: var(--muted); background: transparent; }
.button.danger { color: var(--red); border-color: #efb8bd; background: #fff; }
.button.full { width: 100%; margin-top: 1.25rem; display: flex; justify-content: space-between; }
.notice { padding: .65rem .8rem; border-radius: .45rem; font-size: .76rem; }
.notice.warning { color: #754a00; background: #fff6df; }
.preview-summary, .metric-strip { display: flex; flex-wrap: wrap; gap: .6rem; margin-bottom: .8rem; }
.preview-summary span, .metric-strip div { padding: .55rem .7rem; border-radius: .45rem; background: #edf3f8; font-size: .72rem; }
.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .78rem; }
caption { text-align: left; padding: 0 0 .6rem; color: var(--muted); font-size: .7rem; }
th { padding: .72rem .65rem; color: #425b73; background: #edf3f8; text-align: left; white-space: nowrap; }
td { padding: .72rem .65rem; border-bottom: 1px solid #e7edf4; vertical-align: top; }
tbody tr:hover { background: #f8fbfe; }
.field-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: .85rem; }
.planning-mode-field { margin: 1.2rem 0 .8rem; }
.duration-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); margin: 1rem 0; }
.staffing-grid input { min-width: 4rem; max-width: 8rem; }
.staffing-grid th small { display: block; font-weight: 400; color: var(--muted); }
.staffing-grid tfoot { font-weight: 700; }
.team-editor { margin: 1.25rem 0; }
.team-editor > p { color: var(--muted); }
label > span { display: block; margin-bottom: .32rem; color: #425b73; font-size: .76rem; font-weight: 700; }
input, select { width: 100%; min-width: 0; max-width: 100%; min-height: 43px; border: 1px solid #aabccc; border-radius: .5rem; padding: .65rem .75rem; color: var(--ink); background: #fff; }
.calendar-line { display: grid; grid-template-columns: 1fr 2rem 1fr; align-items: center; gap: .5rem; margin: 1.2rem 0; }
.calendar-line div { padding: .8rem; border-radius: .5rem; background: #edf3f8; }
.calendar-line span { display: block; color: var(--muted); font-size: .68rem; }
.calendar-line i { height: 1px; background: #9bb0c5; }
.client-departure-controls { margin-bottom: 1.2rem; }
.client-departure-controls label + label { display: block; margin-top: .85rem; }
.client-departure-option { display: flex; align-items: center; gap: .65rem; }
.client-departure-option input { width: 1.1rem; min-height: 1.1rem; margin: 0; }
.client-departure-option span { margin: 0; }
.client-departure-controls small { display: block; margin-top: .35rem; color: var(--muted); font-size: .7rem; }
details { border-top: 1px solid var(--line); padding-top: 1rem; }
summary { color: var(--navy); font-size: .8rem; font-weight: 750; cursor: pointer; }
details ul { padding-left: 1.2rem; color: var(--muted); font-size: .77rem; line-height: 1.55; }
.run-panel, .authoritative { margin-top: 1.25rem; padding: 1.1rem 1.3rem; display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; background: var(--navy); border-radius: 1rem; color: #fff; }
.run-panel > div:first-child { display: flex; align-items: center; gap: 1rem; }
.run-panel h2, .run-panel p { margin: 0; }
.run-panel p { margin-top: .25rem; color: #b9cbe0; font-size: .8rem; }
.spinner { width: 2rem; height: 2rem; border: 3px solid rgba(255,255,255,.22); border-top-color: #fff; border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.run-time { text-align: right; }
.run-time span, .run-time small { display: block; color: #b9cbe0; font-size: .67rem; }
.run-time strong { display: block; font-size: 1.3rem; font-variant-numeric: tabular-nums; }
.authoritative { background: #e8f8f4; color: var(--ink); border: 1px solid #93d6ca; }
.authoritative p:not(.step-label) { max-width: 520px; margin: .45rem 0 0; color: #425b73; font-size: .76rem; }
.attempt-actions { margin-top: 1.25rem; border-color: #efb8bd; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.attempt-actions p:not(.step-label) { margin: .45rem 0 0; color: var(--muted); font-size: .78rem; }
.section-header h1 { font-size: clamp(1.8rem, 3vw, 2.6rem); }
.kpi-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; margin-bottom: 1.25rem; }
.kpi { min-width: 0; padding: 1.4rem; border-radius: 1rem; border: 1px solid var(--line); background: #fff; box-shadow: var(--shadow); }
.shift-kpi-heading { display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin-bottom: 1.3rem; padding-bottom: .85rem; border-bottom: 1px solid var(--line); }
.shift-kpi-heading h2 { color: var(--navy); font-size: 1.15rem; }
.shift-kpi-window { color: var(--muted); font-size: .8rem; white-space: nowrap; font-variant-numeric: tabular-nums; }
.shift-kpi-values { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.35rem 1rem; margin: 0; }
.shift-kpi-values dt { color: var(--muted); font-size: .74rem; }
.shift-kpi-values dd { margin: 0; }
.shift-kpi-values strong { display: block; margin: .45rem 0 .3rem; color: var(--navy); font-size: clamp(1.45rem, 2vw, 1.8rem); letter-spacing: -.03em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.shift-kpi-values small { display: block; color: #62798f; font-size: .68rem; line-height: 1.45; }
.result-grid { margin-bottom: 1.25rem; }
.context-note { margin: 1rem 0 0; color: var(--muted); font-size: .75rem; }
.completion-progress { width: 100%; height: 18px; margin: 2rem 0 .6rem; border: 0; border-radius: 999px; overflow: hidden; background: #e4ebf3; }
.completion-progress::-webkit-progress-bar { background: #e4ebf3; }
.completion-progress::-webkit-progress-value { background: linear-gradient(90deg, var(--teal), var(--blue)); }
.completion-progress::-moz-progress-bar { background: var(--teal-dark); }
#completion-caption { color: var(--muted); font-size: .74rem; }
.detail-list { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.35fr); gap: .55rem 1rem; margin: 1rem 0 0; font-size: .76rem; }
.detail-list div { display: contents; }
.detail-list dt { color: var(--muted); }
.detail-list dd { margin: 0; font-weight: 750; text-align: right; overflow-wrap: anywhere; }
.filter-row { display: grid; grid-template-columns: repeat(5, minmax(120px, 1fr)); gap: .8rem; margin-bottom: 1rem; }
.timeline { padding: .9rem; margin-bottom: 1rem; border-radius: .55rem; background: #edf3f8; }
.timeline-controls { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin-bottom: .8rem; }
.timeline-legend { display: flex; flex-wrap: wrap; gap: .7rem 1.2rem; margin: .8rem 0 1rem; font-size: .72rem; color: var(--muted); }
.timeline-legend span { display: inline-flex; align-items: center; gap: .4rem; }
.timeline-legend i { display: inline-block; width: .7rem; height: .7rem; border-radius: 2px; }
.timeline-legend i[data-kind="work"] { background: #154875; }
.timeline-legend i[data-kind="congestion"] { background: var(--amber); }
.timeline-legend i[data-kind="transport"] { background: var(--teal); }
.timeline-legend i[data-kind="empty"] { background: #dfe8f2; border: 1px solid #c7d4e2; }
.timeline-axis, .timeline-lane { display: grid; grid-template-columns: minmax(0, 24%) minmax(0, 1fr); column-gap: .75rem; align-items: center; }
.timeline-axis { margin-bottom: .7rem; color: var(--muted); font-size: .68rem; }
.timeline-axis > div { position: relative; height: 1.3rem; }
.timeline-axis > div > span { position: absolute; transform: translateX(-50%); white-space: nowrap; }
.timeline-axis > div > span:first-child { transform: none; }
.timeline-axis > div > span:last-child { transform: translateX(-100%); }
.timeline-lane { min-height: 32px; margin: .35rem 0; }
.timeline-resource { font-size: .7rem; font-weight: 650; overflow-wrap: anywhere; }
.timeline-rail { position: relative; min-height: 26px; border-radius: 3px; background: repeating-linear-gradient(to right, transparent 0, transparent calc(12.5% - 1px), #c7d4e2 calc(12.5% - 1px), #c7d4e2 12.5%), #dfe8f2; }
.timeline-event { display: block; position: absolute; top: 2px; height: 22px; border-radius: 2px; background: #154875; }
.timeline-event[data-kind="congestion"] { background: var(--amber); }
.timeline-event[data-kind="transport"] { background: var(--teal); }
.event-detail-heading { display: flex; align-items: center; justify-content: space-between; gap: 1rem; border-top: 1px solid var(--line); margin-top: 1.5rem; padding-top: 1rem; }
.event-detail-heading h3 { margin: 0; font-size: .95rem; }
@media (max-width: 700px) { .timeline-controls { grid-template-columns: 1fr; } .timeline-axis > div > span:nth-child(even) { visibility: hidden; } }

.row-plan-card { margin-top: 1.25rem; }
.completion-entities { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; margin-top: 1.25rem; }
.entity-card { min-width: 0; }
.entity-card .panel-heading { align-items: center; }
.entity-card td:first-child, .entity-card td:nth-child(2) { max-width: 16rem; }
.downloads { margin-top: 1.25rem; display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }
.downloads p:not(.step-label) { margin-bottom: 0; color: var(--muted); font-size: .8rem; }
.maestro-header { align-items: center; }
.explanation-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }
.explanation-lead { grid-column: 1 / -1; padding: 2rem; border-radius: 1rem; color: #fff; background: var(--navy); }
.explanation-lead h2 { font-size: 2rem; }
.explanation-lead p:last-child { max-width: 900px; color: #c7d5e5; line-height: 1.6; }
.explanation-card { position: relative; min-height: 220px; }
.explanation-card h2 { padding-right: 3rem; }
.explanation-card ul { padding-left: 1.15rem; color: var(--muted); line-height: 1.65; }
.card-index { position: absolute; top: 1.2rem; right: 1.2rem; color: #52677d; font-size: .7rem; font-weight: 800; }
.validation-seal { margin-top: 1rem; display: flex; align-items: center; gap: 1rem; padding: 1.2rem 1.4rem; border: 1px solid #93d6ca; border-radius: .8rem; background: #e8f8f4; }
.validation-seal > span { display: grid; place-items: center; width: 2.3rem; height: 2.3rem; border-radius: 50%; background: var(--teal-dark); color: #fff; }
.validation-seal p { margin: .25rem 0 0; color: var(--muted); font-size: .8rem; }
.toast { position: fixed; z-index: 50; right: 1rem; bottom: 1rem; max-width: min(430px, calc(100vw - 2rem)); display: flex; gap: 1rem; align-items: start; padding: 1rem 1.1rem; border-radius: .7rem; color: #fff; background: #9d2531; box-shadow: 0 18px 60px rgba(50,0,0,.25); }
.toast p { margin: 0; line-height: 1.45; }
.toast button { border: 0; color: #fff; background: transparent; font-size: 1.2rem; }
footer { min-height: 52px; padding: 0 clamp(1rem,4vw,4.5rem); display: flex; align-items: center; justify-content: space-between; border-top: 1px solid var(--line); color: var(--muted); font-size: .7rem; }
@media (max-width: 980px) {
  .shell-header { grid-template-columns: 1fr auto; }
  .shell-header nav { order: 3; grid-column: 1 / -1; justify-content: center; overflow-x: auto; }
  .connection { grid-column: 2; grid-row: 1; }
  .hero-grid, .section-header, .workspace-grid, .result-grid, .completion-entities { grid-template-columns: 1fr; }
  .kpi-grid { grid-template-columns: repeat(2, 1fr); }
  .filter-row { grid-template-columns: repeat(2, minmax(130px, 1fr)); }
}
@media (max-width: 620px) {
  .shell-header { padding: .8rem 1rem 0; }
  .connection { display: none; }
  .nav-step { padding: .6rem .35rem; gap: .35rem; font-size: .72rem; }
  .screen { padding-top: 2.2rem; }
  h1 { font-size: 2.45rem; }
  .run-panel, .authoritative, .attempt-actions, .downloads { align-items: stretch; flex-direction: column; }
  .run-time { text-align: left; }
  .kpi-grid, .explanation-grid { grid-template-columns: 1fr; }
  .explanation-lead { grid-column: auto; }
  .filter-row { grid-template-columns: 1fr; }
  footer { align-items: start; gap: .3rem; flex-direction: column; padding-top: 1rem; padding-bottom: 1rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

.agent-chat { margin-bottom: 1.3rem; }
.agent-history { min-height: 220px; max-height: min(60vh, 640px); overflow-y: auto; padding: .25rem .4rem .8rem 0; scroll-behavior: smooth; }
.agent-empty { display: grid; align-content: center; min-height: 210px; max-width: 650px; margin: 0 auto; padding: 1.4rem; text-align: center; }
.agent-empty h3 { margin: 0 0 .65rem; color: var(--navy); font-size: 1.4rem; }
.agent-empty p { margin: 0; color: var(--muted); line-height: 1.6; }
.agent-exchange { display: grid; grid-template-columns: minmax(0, 1fr); gap: .85rem; margin-bottom: 1.5rem; }
.agent-message { max-width: 92%; padding: 1rem 1.2rem; border-radius: 1rem; }
.agent-message.user { justify-self: end; color: var(--navy); background: #edf3f8; }
.agent-message.maestro { justify-self: start; width: 100%; border: 1px solid var(--line); background: #fff; }
.agent-speaker { font-size: .72rem; color: var(--teal-dark); font-weight: 750; }
.agent-message p { margin: .5rem 0 0; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.65; font-size: .88rem; }
.agent-message .agent-job-state { color: var(--muted); font-size: .72rem; }
.agent-message .agent-progress { min-height: 1.65em; color: var(--teal-dark); }
.agent-message.maestro, .agent-answer { min-width: 0; }
.agent-answer-table-scroll { max-width: 100%; margin-top: .85rem; overflow-x: auto; border: 1px solid var(--line); border-radius: .65rem; overscroll-behavior-x: contain; }
.agent-answer-table-scroll:focus-visible { outline: 2px solid var(--teal-dark); outline-offset: 3px; }
.agent-answer-table { width: 100%; min-width: 420px; border-collapse: collapse; font-size: .82rem; line-height: 1.5; font-variant-numeric: tabular-nums; }
.agent-answer-table th, .agent-answer-table td { padding: .65rem .75rem; border-bottom: 1px solid var(--line); text-align: left; overflow-wrap: anywhere; }
.agent-answer-table th { background: #edf4f7; color: var(--navy); font-weight: 650; }
.agent-answer-table tbody tr:nth-child(even) { background: #f8fafc; }
.agent-answer-table tbody tr:last-child td { border-bottom: 0; }
.agent-answer-table [data-align="right"] { text-align: right; }
.agent-answer-table [data-align="center"] { text-align: center; }
.native-task-cache-status { margin: .6rem 0; font-size: .75rem; color: var(--muted); }
.native-task-cache-status[data-state="failed"] { color: #99511e; }
.agent-proposal { margin-top: 1.1rem; padding-top: 1rem; border-top: 1px solid var(--line); }
.agent-proposal h3 { margin: 0; font-size: 1rem; }
.agent-changes { padding-left: 1.15rem; line-height: 1.65; font-size: .82rem; }
.agent-proposal caption { padding-top: .6rem; }
.agent-proposal tbody th { white-space: normal; font-size: .74rem; background: #f7f9fc; }
.agent-proposal .button { margin-top: .8rem; }
.agent-composer { padding-top: 1rem; border-top: 1px solid var(--line); }
.agent-composer-top, .agent-composer-actions { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.agent-mode { display: inline-flex; gap: .3rem; padding: .3rem; border: 1px solid var(--line); border-radius: 999px; background: #f4f7fb; }
.agent-mode button { padding: .65rem 1.15rem; border: 0; border-radius: 999px; color: var(--muted); background: transparent; font: inherit; font-weight: 700; font-size: .8rem; white-space: nowrap; overflow-wrap: normal; }
.agent-mode button[aria-pressed="true"] { color: #fff; background: var(--navy); }
.help-mode { max-width: 100%; flex-wrap: wrap; }
.agent-keyboard-hint { color: var(--muted); font-size: .68rem; }
.agent-composer .context-note { margin: .85rem 0 .65rem; line-height: 1.5; }
.agent-composer textarea { display: block; width: 100%; min-height: 96px; resize: vertical; padding: .9rem 1rem; border: 1px solid #aabccc; border-radius: .8rem; background: #fff; color: var(--ink); font: inherit; font-size: .88rem; line-height: 1.55; overflow-wrap: anywhere; }
.agent-composer textarea:disabled { background: #f7f9fc; }
.agent-composer-actions > p, .agent-composer-status { margin: .75rem 0 0; color: var(--muted); font-size: .76rem; line-height: 1.5; }
.agent-composer-actions > p[data-state="error"], .agent-composer-status[data-state="error"] { color: var(--red); }
.agent-plan-summary { margin-top: 1.5rem; border-top: 0; }
.agent-plan-summary > summary { margin-bottom: 1rem; }
@media (max-width: 620px) {
  .agent-message { max-width: 100%; padding: .85rem; }
  .agent-composer-top, .agent-composer-actions { align-items: stretch; flex-direction: column; gap: .5rem; }
  .agent-keyboard-hint { display: none; }
  .agent-mode { align-self: start; }
  .agent-mode button { padding: .6rem .85rem; }
  .agent-composer-actions .button-row { justify-content: flex-end; }
}

.agent-proposal table { margin-bottom: .9rem; }
.agent-area-goal, .agent-removal-impact { margin: 1.1rem 0; padding-top: .85rem; border-top: 1px solid var(--line); }
.agent-area-goal h4, .agent-removal-impact h4 { margin: 0 0 .7rem; color: var(--navy); font-size: .9rem; }
.agent-message .agent-removal-warning { font-weight: 650; line-height: 1.6; margin-top: 1rem; }
.agent-message > .button.secondary { margin-top: .85rem; }

.agent-report { margin-top: 1rem; padding: 1rem; border: 1px solid var(--line); border-radius: .8rem; background: #f7f9fc; }
.agent-report h3 { margin: 0; color: var(--navy); font-size: 1rem; overflow-wrap: anywhere; }
.agent-report .button-row { margin-top: .8rem; flex-wrap: wrap; }
.agent-report .button { margin-top: 0; }

.scenario-generate { margin-top: .7rem; }
.scenario-comparison { margin-top: 1.5rem; }
.scenario-comparison td { white-space: normal; min-width: 7rem; }
.scenario-comparison td:first-child { font-weight: 650; min-width: 12rem; }
.scenario-comparison .context-note { line-height: 1.6; }

.scenario-comparison th { white-space: normal; }
.scenario-comparison th:nth-child(2) { min-width: 10rem; max-width: 14rem; }
.scenario-comparison .button { white-space: nowrap; }
/* Allocated nonproductive time is separate from physical resource activity. */
.timeline-legend i[data-kind="pause"], .timeline-event[data-kind="pause"] { background: #8a62ad; }
.timeline-legend i[data-kind="idle"], .timeline-event[data-kind="idle"] { background: #dfe8f2; border: 1px solid #c7d4e2; }

/* Entrada follows the same order as the work: file, day, hours, people. */
.upload-panel { display: grid; grid-template-columns: minmax(160px, .7fr) minmax(260px, 1.4fr) auto; gap: .8rem 1.25rem; align-items: center; }
.upload-panel .panel-heading, .upload-panel .button-row { margin: 0; }
.upload-panel .panel-heading { align-items: center; }
.upload-panel .step-label { margin-bottom: .35rem; }
.upload-panel .drop-zone { min-height: 76px; padding: .7rem 1rem; display: grid; grid-template-columns: auto 1fr; gap: .15rem .75rem; text-align: left; }
.upload-panel .upload-icon { grid-row: span 2; }
.upload-panel .drop-zone strong, .upload-panel .drop-zone span:last-child { justify-self: start; margin: 0; }
.upload-panel .notice, .upload-preview { grid-column: 1 / -1; margin: 0; }
.upload-panel .notice { padding: .5rem .7rem; }
.upload-preview > summary { padding-bottom: .6rem; }
.calendar-panel { min-width: 0; }
.progressive-entry { margin-bottom: 1.25rem; }
.progressive-entry fieldset { border: 0; padding: 0; margin: 1.25rem 0 0; }
.progressive-entry legend { font-weight: 700; margin-bottom: .6rem; }
.progressive-options { display: flex; flex-wrap: wrap; gap: .65rem; }
.progressive-options label { display: flex; align-items: center; gap: .55rem; border: 1px solid var(--line); border-radius: .6rem; padding: .7rem 1rem; cursor: pointer; }
.progressive-options input { flex: none; width: 1.1rem; height: 1.1rem; min-height: 1.1rem; margin: 0; accent-color: var(--teal-dark); }
.progressive-entry > label { display: grid; gap: .4rem; margin-top: 1rem; }
[data-progressive-planner="true"] .settings-grid { grid-template-columns: minmax(0, 1fr); }

[data-picking-active="true"] .calendar-panel > :not(#picking-planner) { display: none !important; }
[data-picking-active="true"] #screen-plano > :not(#native-plan-workspace) { display: none !important; }
[data-picking-active="true"] #native-plan-workspace { display: block; }
.native-step-card { display: grid; gap: .75rem; padding-top: 1rem; border-top: 1px solid var(--line); }
.native-step-card h3 { margin-top: .3rem; }
.native-step-card > label { display: grid; gap: .4rem; margin: 1rem 0; }
.native-step-card .button-row { margin: .35rem 0 0; }
.native-review-actions { flex-wrap: nowrap; }
.native-review-actions > .button { flex: 1 1 0; min-width: 0; max-width: 10rem; }
.native-second-shift { display: flex !important; align-items: center; gap: .5rem; }
.native-second-shift input { width: auto; min-height: auto; }
#picking-steps .field-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 18rem));
  align-items: start;
  justify-content: start;
}
#picking-steps .field-grid > label { display: grid; gap: .4rem; min-width: 0; align-content: start; }
#picking-steps input:not([type="checkbox"], [type="radio"]),
#picking-steps select { width: min(100%, 18rem); justify-self: start; }
#picking-steps input[type="number"] { width: min(100%, 7rem); }
#picking-steps input[type="color"] { width: min(100%, 5rem); padding: .35rem; }
#picking-steps input[type="date"] { width: min(100%, 12rem); }
#picking-steps input[type="time"] { width: min(100%, 9rem); }
#picking-steps select { width: min(100%, 22rem); }
#picking-steps .agent-answer-table time { white-space: nowrap; }
#picking-steps .agent-answer-table-scroll { width: fit-content; max-width: 100%; }
#picking-steps .agent-answer-table { width: auto; min-width: 0; }
#picking-steps .agent-answer-table th { white-space: nowrap; }
#picking-steps .agent-answer-table tbody th { background: #e2f1ed; }
.native-packing-fields { display: flex; flex-wrap: wrap; align-items: end; gap: .75rem; }
.native-packing-fields > .field-grid { flex: 0 1 37rem; min-width: 0; max-width: 100%; }
.native-packing-help { position: relative; display: inline-flex; align-self: end; margin-bottom: .5rem; }
.native-packing-help > button {
  width: 1.75rem; height: 1.75rem; border: 1px solid var(--teal-dark);
  border-radius: 50%; background: white; color: var(--teal-dark);
  font: inherit; font-weight: 650; cursor: help;
}
.native-packing-help > button:focus-visible { outline: 3px solid var(--teal-dark); outline-offset: 3px; }
.native-packing-tooltip {
  position: absolute; z-index: 2; bottom: calc(100% + .5rem); left: 0;
  width: min(22rem, 65vw); padding: .75rem; border: 1px solid var(--line);
  border-radius: .65rem; background: white; color: var(--navy);
  box-shadow: 0 .35rem 1rem #07233218; font-size: .85rem; line-height: 1.5;
}
.native-plan-narrative, .native-gantt-panel { margin-top: 1.25rem; }
#picking-download-status:empty { display: none; }
.native-narrative-section + .native-narrative-section { border-top: 1px solid var(--line); margin-top: 1.25rem; padding-top: .5rem; }
.native-narrative-section li { margin-bottom: .6rem; line-height: 1.55; }
.native-gantt-legend { display: flex; flex-wrap: wrap; gap: .5rem 1rem; margin: 1rem 0 1.5rem; font-size: .75rem; }
.native-gantt-legend span::before { content: ""; display: inline-block; width: .65rem; height: .65rem; border-radius: .15rem; margin-right: .35rem; background: var(--activity-color); }
.native-gantt-legend [data-kind="picking"], .native-timeline-event[data-kind="picking"] { --activity-color: #176d79; }
.native-gantt-legend [data-kind="walking"], .native-timeline-event[data-kind="walking"] { --activity-color: #5a9fa9; }
.native-gantt-legend [data-kind="waiting"], .native-timeline-event[data-kind="waiting"] { --activity-color: #b78330; }
.native-gantt-legend [data-kind="congestion"], .native-timeline-event[data-kind="congestion"] { --activity-color: #be5b47; }
.native-gantt-legend [data-kind="transport"], .native-timeline-event[data-kind="transport"] { --activity-color: #4e6ca5; }
.native-gantt-legend [data-kind="relocation"], .native-timeline-event[data-kind="relocation"] { --activity-color: #7d61a4; }
.native-gantt-legend [data-kind="pause"], .native-timeline-event[data-kind="pause"] { --activity-color: #9aab93; }
.native-gantt-legend [data-kind="idle"], .native-timeline-event[data-kind="idle"] { --activity-color: #dfe6e9; }
.native-timeline { overflow-x: auto; }
.native-timeline .area-gantt { min-width: 620px; }
.native-timeline-rail { position: relative; display: block; height: 1.5rem; overflow: hidden; }
.native-timeline-event { position: absolute; top: .12rem; bottom: .12rem; display: block; background: var(--activity-color); border-radius: 2px; min-width: 1px; }
.native-shift-select { display: grid; gap: .4rem; max-width: 24rem; }
.native-comparison { width: 100%; font-size: .82rem; margin: 1rem 0; }
.native-comparison th, .native-comparison td { padding: .6rem .4rem; text-align: left; border-bottom: 1px solid var(--line); }
.picking-planner { display: grid; gap: 1rem; }
.picking-planner[hidden] { display: none; }
.picking-planner h2, .picking-planner h3, .picking-planner p { margin: 0; }
.picking-setup { display: grid; gap: .45rem; }
.picking-metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: .8rem; margin: 1rem 0; }
.picking-metric { display: grid; align-content: start; gap: .35rem; padding: .85rem; border: 1px solid var(--line); border-radius: 12px; }
.picking-metric span { font-size: .85rem; }
.picking-metric strong { font-size: 1.05rem; font-variant-numeric: tabular-nums; }
#picking-result-body { display: grid; gap: .8rem; }
#picking-downloads { margin-top: 1rem; }
.settings-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.25rem; align-items: start; }
.settings-card { min-height: 320px; border-top: 3px solid #087f9c; }
.settings-card h2 { font-size: 1.1rem; line-height: 1.35; }
.settings-help { min-height: 3rem; margin: .6rem 0 1rem; color: var(--muted); font-size: .85rem; line-height: 1.5; }
.settings-icon { display: grid; place-items: center; width: 2.5rem; height: 2.5rem; margin-bottom: 1rem; border-radius: .6rem; color: #087f9c; background: #edf7fa; }
.settings-card .planning-mode-field { margin-top: 0; }
.settings-card .calendar-line { grid-template-columns: 1fr 1fr; margin: 1rem 0 0; }
.settings-card .calendar-line i { display: none; }
.settings-card .calendar-line div { padding: .6rem; }
.settings-card .context-note { line-height: 1.55; }
.settings-card .staffing-grid th, .settings-card .staffing-grid td { padding: .5rem .3rem; }
.settings-card .staffing-grid input { min-width: 0; padding: .5rem; }
.advanced-settings { margin-top: 1.25rem; padding: 1rem 1.25rem; background: #f8fafc; }
.advanced-settings > summary { font-size: .85rem; }
.advanced-settings > .client-departure-controls { margin-top: 1rem; }
.generate-bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 1.5rem; }
.generate-bar p { margin: 0; font-weight: 650; }
.generate-bar p span { display: block; margin-top: .25rem; color: var(--muted); font-size: .85rem; font-weight: 400; }

/* The plan and its conversation are one workspace. */
#screen-plano > .section-header { margin-bottom: .5rem; }
.plan-toolbar { margin-bottom: 1.25rem; }
.plan-toolbar .button-row { margin-top: .5rem; }
.plan-workspace { display: grid; grid-template-columns: minmax(0, 1fr) minmax(330px, 390px); gap: 1.25rem; align-items: start; }
.plan-main { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.25rem; }
.plan-main > .team-editor { margin: 0; }
.area-plan-panel .timeline { padding: 0; margin-bottom: 0; background: transparent; }
.area-gantt { padding: 1rem; border: 1px solid var(--line); border-radius: .65rem; background: #f8fafc; }
.area-gantt + .area-gantt { margin-top: .8rem; }
.area-gantt-heading { margin: 0; font-size: .95rem; color: var(--navy); }
.area-gantt .context-note { margin: .3rem 0 1rem; }
.area-gantt .timeline-axis { font-size: .64rem; }
.work-orders-panel > .panel-heading { align-items: center; margin-bottom: .4rem; }
.work-orders-panel > .panel-heading select { font-size: .8rem; }
.work-order-status { color: var(--navy); font-size: .85rem; font-weight: 650; }
.work-order-list { margin: 0; padding: 0; list-style: none; }
.work-order-list > li { display: grid; grid-template-columns: 2rem minmax(0, 1fr) auto; gap: .75rem; align-items: center; padding: 1rem 0; border-bottom: 1px solid var(--line); }
.queue-rank { display: grid; place-items: center; width: 1.8rem; height: 1.8rem; border-radius: 50%; background: #eaf3f8; color: #087f9c; font-size: .8rem; font-weight: 750; }
.queue-description, .work-order-list small { display: block; margin-top: .25rem; color: var(--muted); font-size: .75rem; line-height: 1.45; }
.work-order-list strong { font-size: .95rem; }
.work-order-list .button { font-size: .8rem; }
.work-order-list > .queue-empty { display: block; padding: 1.25rem 0; color: var(--muted); line-height: 1.6; }
.queue-pagination { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem; margin-top: .65rem; }
.queue-pagination .button { font-size: .8rem; }
.work-order-confirmation { margin-top: 1rem; padding: 1rem; border: 1px solid #70b9c9; border-radius: .6rem; background: #eff9fc; }
.work-order-confirmation h3 { margin: 0; font-size: 1rem; }
.work-order-confirmation p { font-size: .85rem; line-height: 1.6; }
.plan-details { padding: 1rem 0 0; }
.plan-details > summary { margin-bottom: 1rem; font-size: .9rem; }
.plan-details > .panel, .plan-details > .result-grid, .plan-details > .completion-entities { margin-bottom: 1.25rem; }
.plan-details .result-grid, .plan-details .kpi-grid { grid-template-columns: 1fr; }
.maestro-dock { min-width: 0; position: sticky; top: 98px; }
.maestro-dock .agent-chat { display: flex; flex-direction: column; height: calc(100dvh - 120px); min-height: 540px; max-height: 940px; margin-bottom: 0; }
.maestro-dock .panel-heading { margin-bottom: .7rem; }
.maestro-dock .panel-heading .status-pill { display: none; }
.maestro-dock .agent-history { flex: 1; min-height: 160px; max-height: none; }
.maestro-dock .agent-message { max-width: 100%; padding: .85rem; }
.maestro-dock .agent-composer { flex-shrink: 0; }
.maestro-dock .agent-composer textarea { min-height: 90px; }
.maestro-dock .agent-composer-top, .maestro-dock .agent-composer-actions { flex-wrap: wrap; gap: .5rem; }
.maestro-dock .agent-keyboard-hint { display: none; }
.maestro-dock .agent-mode { max-width: 100%; flex-wrap: wrap; }

@media (max-width: 1180px) {
  .upload-panel { grid-template-columns: minmax(140px, .7fr) minmax(260px, 1.3fr); }
  .upload-panel > .button-row { grid-column: 1 / -1; }
  .settings-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .settings-card:last-child { grid-column: 1 / -1; }
  .plan-workspace { grid-template-columns: minmax(0, 1fr) minmax(310px, 350px); gap: 1rem; }
}
@media (max-width: 980px) {
  .plan-workspace { grid-template-columns: minmax(0, 1fr); }
  .maestro-dock { position: static; }
  .maestro-dock .agent-chat { height: auto; min-height: 0; max-height: none; }
  .maestro-dock .agent-history { min-height: 160px; max-height: 420px; }
}
@media (max-width: 620px) {
  .screen { padding-top: 1.5rem; }
  .upload-panel, .settings-grid { grid-template-columns: minmax(0, 1fr); }
  .settings-card { min-height: 0; }
  .settings-help { min-height: 0; }
  .generate-bar { align-items: stretch; flex-direction: column; }
  .generate-bar .button { width: 100%; }
  .work-order-list > li { grid-template-columns: 1.8rem minmax(0, 1fr); gap: .5rem; }
  .work-order-list > li > .button, .work-order-list > li > .status-pill { grid-column: 2; justify-self: start; }
  .area-gantt { padding: .75rem; }
  .timeline-axis, .timeline-lane { column-gap: .4rem; }
  .work-orders-panel > .panel-heading { flex-wrap: wrap; }
}

/* Approved vertical workspace and expandable area spans. */

:root{--shell-sidebar-width:112px}
.shell-sidebar{position:fixed;inset:0 auto 0 0;z-index:40;width:var(--shell-sidebar-width);height:100dvh;min-width:0;display:flex;flex-direction:column;align-items:center;padding:14px 10px;color:rgba(255,255,255,.68);background:var(--navy);border-right:1px solid rgba(140,206,230,.16);box-shadow:4px 0 18px rgba(0,0,0,.18);overflow-y:auto}
.sidebar-brand{display:grid;width:54px;height:54px;flex:none;place-items:center;padding:7px;border-radius:17px;background:linear-gradient(145deg,#071a2b,#0d2c47);box-shadow:0 9px 20px rgba(7,26,43,.22)}
.sidebar-symbol{display:block;width:100%;height:100%;object-fit:contain}
.shell-sidebar nav{display:flex;flex-direction:column;gap:7px;min-width:0;width:100%;margin-top:26px}
.shell-sidebar .nav-step{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;width:100%;min-height:58px;padding:8px 4px;border-radius:14px;border:0;text-align:center;font-weight:700;color:rgba(255,255,255,.68);background:transparent;transition:color .18s ease,background .18s ease}
.shell-sidebar .nav-step::before{position:absolute;top:15px;bottom:15px;left:-10px;width:3px;border-radius:0 6px 6px 0;background:#12a6c7;content:"";opacity:0;transform:scaleY(.5);transition:opacity .18s ease,transform .18s ease}
.shell-sidebar .nav-step .sidebar-tab-label{font-size:10px;line-height:1.45;color:inherit;letter-spacing:.01em;white-space:normal}
.shell-sidebar .sidebar-icon{display:block;flex:none;width:20px;height:20px}
.shell-sidebar .nav-step.is-active{color:#9beaf6;background:rgba(18,166,199,.18)}
.shell-sidebar .nav-step.is-active::before{opacity:1;transform:scaleY(1)}
.shell-sidebar .nav-step:not(:disabled):hover{color:#fff;background:rgba(18,166,199,.14)}
:is(body,#application-shell)>.shell-header,:is(body,#application-shell)>main,:is(body,#application-shell)>footer{margin-left:var(--shell-sidebar-width);min-width:0}
.shell-header{grid-template-columns:1fr auto;gap:1rem;min-height:78px;padding:.65rem clamp(.75rem,2.5vw,2rem)}
.sidebar-footer{flex:none;width:100%;margin-top:auto;text-align:center}
.daily-token-usage{width:100%;min-width:0;padding-top:24px;padding-bottom:4px;color:#e8f3fa;text-align:center}
.daily-token-heading{display:flex;flex-direction:column;gap:.3rem;align-items:center;font-size:.75rem;font-weight:600;line-height:1.4}
.daily-token-heading>span{max-width:100%;color:#b7cddd;white-space:normal}
.daily-token-indicator{position:relative;display:grid;place-items:center;width:40px;height:40px;margin:.5rem auto 0}
.daily-token-meter{position:absolute;inset:0}
.daily-token-ring{display:block;width:100%;height:100%;transform:rotate(-90deg)}
.daily-token-ring circle{fill:none;stroke-width:3;stroke-linecap:butt}
.daily-token-track{stroke:rgba(214,231,244,.2)}
.daily-token-remaining{stroke:#66dfc3}
.daily-token-summary{font-size:.5625rem;font-weight:600;font-variant-numeric:tabular-nums;line-height:1}
.daily-token-usage[data-state="unavailable"] .daily-token-summary{color:#f6d99c}
.application-version{display:block;margin:.5rem 0 .25rem;color:#9bb3c5;font-size:.625rem;line-height:1.4}
.help-panel{max-width:48rem}
.terms-of-use{max-width:30rem}
.terms-of-use summary{cursor:pointer;color:var(--ink);text-decoration:underline;text-underline-offset:.2em}
.terms-of-use summary:hover{color:var(--teal-dark)}
.terms-of-use p{margin:.5rem 0 .3rem;font-size:.75rem;line-height:1.5}
@media(max-width:1050px){.shell-header .connection{display:none}}
:is(body,#application-shell)>main{min-height:calc(100dvh - 208px)}
:is(body,#application-shell)>footer{gap:.5rem;flex-wrap:wrap}
@media(max-width:920px){:root{--shell-sidebar-width:104px}}
@media(max-width:620px){:root{--shell-sidebar-width:88px}.shell-sidebar{padding:14px 6px}.sidebar-brand{width:46px;height:46px;padding:5px;border-radius:14px}.shell-sidebar nav{margin-top:20px}.shell-sidebar .nav-step::before{left:-6px}.shell-header{padding:.4rem .75rem}.shell-header .brand-logo{width:142px;height:54px}.shell-header .connection{display:none}.screen{padding-left:.75rem;padding-right:.75rem}:is(body,#application-shell)>footer{padding-left:.75rem;padding-right:.75rem}.timeline-axis{grid-template-columns:minmax(72px,30%) minmax(0,1fr)}}


.plan-workspace { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); }
.plan-toolbar { display: flex; flex-wrap: wrap; gap: .65rem; margin-bottom: 1rem; }
#screen-plano > .section-header { margin-bottom: .5rem; }
.second-shift-option { display: flex; align-items: center; gap: .6rem; }
.second-shift-option input { width: 1.1rem; min-height: 1.1rem; margin: 0; }
.second-shift-option span { margin: 0; }
.area-gantt > summary { cursor: pointer; list-style: none; }
.area-gantt > summary::-webkit-details-marker { display: none; }
.area-gantt > summary:focus-visible { outline-color: var(--blue); }
.area-gantt-heading { display: grid; grid-template-columns: minmax(80px, 24%) minmax(0, 1fr); align-items: center; gap: .65rem; }
.area-gantt-heading > span:first-child::before { content: '▸ '; color: var(--teal-dark); }
.area-gantt[open] > .area-gantt-heading > span:first-child::before { content: '▾ '; }
.area-summary-rail { position: relative; display: block; min-width: 0; height: 38px; border-radius: .4rem; background: #edf3f6; }
.area-summary-bar { position: absolute; top: 6px; height: 26px; background: #c6eaf0; border-radius: .3rem; overflow: hidden; text-align: center; color: #174357; font-size: .7rem; line-height: 26px; white-space: nowrap; }
.area-empty { padding: .5rem; font-size: .7rem; font-weight: 400; }
.timeline-legend i[data-kind="area"] { background: #c6eaf0; }
.work-order-list > li { grid-template-columns: minmax(0, 1fr) auto auto; }
.task-state { padding: .3rem .5rem; border-radius: .35rem; font-size: .72rem; color: #52677d; background: #edf2f6; }
.task-state[data-state="in_progress"] { color: #17617c; background: #e4f4fa; }
.task-state[data-state="completed"] { color: #216342; background: #e6f6ee; }
.maestro-dock .agent-composer textarea { min-height: 110px; }
@media (max-width: 980px) { .plan-workspace { grid-template-columns: minmax(0, 1fr); } .maestro-dock { position: static; } }
.daily-plan-only .plan-workspace { grid-template-columns: minmax(0, 1fr); }
@media (max-width: 620px) { .work-order-list > li { grid-template-columns: minmax(0, 1fr) auto; } .work-order-list > li > .task-state { grid-column: 1; grid-row: 2; justify-self: start; } .work-order-list > li > .button { grid-column: 2; grid-row: 1 / span 2; } }

/* Whole-shipment demand selection stays independent from available staffing. */
.demand-areas { min-width: 0; margin: 1rem 0; padding: .9rem; border: 1px solid var(--line); border-radius: .55rem; }
.demand-areas legend { padding: 0 .3rem; color: var(--navy); font-size: .85rem; font-weight: 650; }
.area-selection { display: flex; flex-wrap: wrap; gap: .45rem; }
.area-selection label { display: flex; align-items: center; gap: .45rem; min-height: 44px; padding: .35rem .65rem; border: 1px solid var(--line); border-radius: .4rem; background: #fff; cursor: pointer; }
.area-selection input { width: 1.05rem; height: 1.05rem; margin: 0; accent-color: var(--teal-dark); }
.area-selection span { font-size: .8rem; }
.scope-preview { margin-bottom: 1rem; padding: .9rem; border: 1px solid var(--line); border-radius: .55rem; background: #f4f8fb; }
.scope-preview h3 { margin: 0 0 .5rem; font-size: .85rem; }
.scope-preview p { font-size: .78rem; line-height: 1.5; overflow-wrap: anywhere; }
.scope-preview-counts p { margin: .4rem 0; }
.plan-demand-scope { margin: 0 0 1rem; line-height: 1.6; overflow-wrap: anywhere; }

/* The native hidden shell prevents any application flash before startup. */
.startup-screen { position: fixed; inset: 0; z-index: 100; display: grid; min-height: 100dvh; place-items: center; padding: 2rem 1.5rem; background: var(--navy); color: #e3f1f7; opacity: 1; transition: opacity 280ms ease, display 280ms allow-discrete; }
.startup-screen[hidden] { opacity: 0; pointer-events: none; }
.startup-card { display: grid; justify-items: center; width: 100%; max-width: 24rem; text-align: center; }
.startup-logo { display: block; width: min(16rem, 100%); height: auto; animation: startup-breathe 2.8s ease-in-out infinite; }
.startup-tangram { display: block; width: min(21rem, 100%); height: auto; margin-top: 1.5rem; }
.startup-piece { transform-box: view-box; transform-origin: 0 0; transform: var(--pose-a); stroke: var(--navy); stroke-width: 1.5; stroke-linejoin: round; animation: startup-assemble 12s cubic-bezier(.45, 0, .2, 1) -2.1s infinite; }
.startup-large-a { fill: var(--teal); --pose-a: translate(160px, 110px) rotate(225deg); --pose-b: translate(160px, 132px) rotate(180deg); --pose-c: translate(138px, 132px) rotate(180deg); }
.startup-large-b { fill: #4c9fd5; --pose-a: translate(160px, 110px) rotate(315deg); --pose-b: translate(160px, 132px) rotate(270deg); --pose-c: translate(226px, 132px) rotate(180deg); }
.startup-medium { fill: #8bd9e6; --pose-a: translate(97.774603255584px, 110px) rotate(45deg); --pose-b: translate(160px, 132px) rotate(0deg); --pose-c: translate(182px, 132px) rotate(0deg); }
.startup-square { fill: #5099b6; --pose-a: translate(191.112698372208px, 141.112698372208px) rotate(135deg); --pose-b: translate(72px, 132px) rotate(0deg); --pose-c: translate(138px, 132px) rotate(0deg); }
.startup-parallelogram { fill: #087f9c; --pose-a: translate(97.774603255584px, 47.774603255584px) rotate(45deg); --pose-b: translate(116px, 132px) rotate(0deg); --pose-c: translate(50px, 132px) rotate(0deg); }
.startup-small-a { fill: #a9deed; --pose-a: translate(160px, 110px) rotate(135deg); --pose-b: translate(116px, 176px) rotate(270deg); --pose-c: translate(138px, 132px) rotate(90deg); }
.startup-small-b { fill: #48b8d0; --pose-a: translate(191.112698372208px, 141.112698372208px) rotate(45deg); --pose-b: translate(248px, 176px) rotate(180deg); --pose-c: translate(182px, 176px) rotate(270deg); }
.startup-card p { margin: 1.5rem 0 .75rem; line-height: 1.6; }
.startup-retry { display: none; color: #a5bdce; font-size: .875rem; text-underline-offset: .2em; }
.startup-screen[data-state="error"] .startup-retry { display: inline; }
.startup-screen[data-state="error"] .startup-tangram { display: none; }
.startup-screen[data-state="error"] .startup-logo { animation: none; opacity: 1; }
.startup-screen[data-state="error"] .startup-piece { animation: none; }
@keyframes startup-breathe { 0%, 100% { opacity: .3; } 50% { opacity: 1; } }
@keyframes startup-assemble {
  0%, 18%, 100% { transform: var(--pose-a); }
  33%, 51% { transform: var(--pose-b); }
  66%, 84% { transform: var(--pose-c); }
}
@media (prefers-reduced-motion: reduce) {
  .startup-screen { transition: none; }
  .startup-logo, .startup-piece { animation: none; }
  .startup-logo { opacity: 1; }
}

/* The summary can load while the checked plan remains ready to use. */
.daily-summary-loading { display: flex; align-items: center; gap: .65rem; margin: 0; padding: .65rem .8rem; border: 1px solid var(--line); border-radius: .7rem; background: #f7fafb; }
.daily-summary-spinner { flex: 0 0 auto; width: 1.2rem; height: 1.2rem; margin-top: .1rem; border: 2px solid var(--line); border-top-color: var(--teal-dark); border-radius: 50%; animation: daily-summary-spin .9s linear infinite; }
.daily-summary-loading-copy { min-width: 0; }
.daily-summary-loading-status { margin: 0; color: var(--navy); font-weight: 400; }
.daily-summary-loading-detail { display: none; }
.native-plan-narrative[aria-busy="true"] { margin-top: .4rem; }
#picking-result.summary-pending { padding: .65rem .85rem; }
.summary-pending .native-plan-narrative { margin: 0; }
.summary-pending .daily-summary-loading { padding: 0; border: 0; background: none; }
@keyframes daily-summary-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .daily-summary-spinner { animation: none; }
}

/* Compact forecast facts; the independent Explain answer follows these cards. */
.picking-briefing { display: grid; gap: 1rem; margin-top: 1.1rem; min-width: 0; }
.briefing-forecast { margin: 0; color: var(--teal-dark); font-size: .78rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.briefing-areas { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,230px),1fr)); gap: .85rem; list-style: none; padding: 0; margin: 0; min-width: 0; }
.briefing-area-card { display: grid; align-content: start; gap: .7rem; padding: 1rem; background: #f7fafb; border: 1px solid var(--line); border-radius: 12px; min-width: 0; overflow-wrap: anywhere; }
.briefing-area-card p { margin: 0; }
.briefing-area-label { font-size: .95rem; }
.briefing-clock-row { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 1rem; }
.briefing-clock-row p { display: grid; gap: .3rem; min-width: 0; }
.briefing-clock-row p:last-child { text-align: right; }
.briefing-clock-row span { color: var(--muted); font-size: .72rem; }
.briefing-clock-row strong { font-size: .96rem; font-variant-numeric: tabular-nums; }
.briefing-target-rail { height: 2px; position: relative; background: #9dbdc5; margin: .15rem .25rem; }
.briefing-target-rail::before,.briefing-target-rail::after { content: ""; position: absolute; width: .45rem; height: .45rem; border-radius: 50%; background: #167486; top: -.15rem; }
.briefing-target-rail::before { left: -.2rem; }
.briefing-target-rail::after { right: -.2rem; }
.briefing-fronts { font-size: .82rem; font-weight: 700; }
.briefing-target { font-size: .85rem; line-height: 1.5; }
.briefing-target.unknown { color: #79571c; }
.picking-briefing .briefing-context { margin: 0; color: var(--muted); font-size: .76rem; line-height: 1.5; overflow-wrap: anywhere; }
.briefing-moments { margin: .35rem 0 0; padding: 0 0 0 1rem; list-style: none; border-left: 1px solid #ccdbe0; min-width: 0; }
.briefing-moment { position: relative; display: grid; grid-template-columns: minmax(0,8.5rem) minmax(0,1fr); gap: .65rem; padding: 0 0 1.1rem .3rem; min-width: 0; overflow-wrap: anywhere; }
.briefing-moment:last-child { padding-bottom: .15rem; }
.briefing-moment::before { content: ""; position: absolute; width: .5rem; height: .5rem; border-radius: 50%; left: -1.28rem; top: .32rem; background: #b7822c; border: 2px solid #fff; }
.briefing-moment[data-kind="truck"]::before { background: #4b719d; }
.briefing-moment-clock { margin: 0; color: #596d82; font-size: .75rem; font-variant-numeric: tabular-nums; line-height: 1.5; }
.briefing-moment-body { display: grid; gap: .3rem; min-width: 0; }
.briefing-moment-body strong { font-size: .84rem; }
.briefing-moment-body > p { margin: 0; font-size: .8rem; line-height: 1.5; }
.daily-summary-directives { padding-left: 1.2rem; margin: 1.1rem 0 0; }
.daily-summary-directives li { padding-left: .15rem; margin-bottom: .75rem; }
.daily-summary-directives p { margin: 0; line-height: 1.6; overflow-wrap: anywhere; }
@media (max-width: 520px) {
  .briefing-moment { grid-template-columns: minmax(0,1fr); gap: .3rem; }
  .briefing-moment-clock { font-weight: 700; }
}

/* Intraday work is a table and a timeline sharing the same exact clock scale. */
.native-gantt-panel { position: relative; min-width: 0; overflow: hidden; }
.native-gantt-panel > h2 { margin-bottom: .4rem; font-size: 1.25rem; letter-spacing: -.025em; }
.native-gantt-panel > .context-note { max-width: 65rem; margin-bottom: .7rem; }
.native-gantt-panel .native-gantt-toolbar { display: flex; flex-wrap: wrap; align-items: end; gap: .7rem; margin-top: 1.15rem; padding: .85rem; border: 1px solid #e0e6ee; border-radius: .7rem; background: #f7f9fc; }
.native-gantt-panel .native-shift-select { flex: 1 1 10rem; min-width: 0; max-width: none; gap: .3rem; font-size: .72rem; font-weight: 650; color: #53647a; }
.native-gantt-panel .native-shift-select select { width: 100%; min-width: 0; min-height: 2.35rem; padding: .4rem .65rem; border: 1px solid #d8e0eb; border-radius: .45rem; background: white; color: #24394f; font: inherit; font-size: .8rem; }
.native-gantt-panel .native-gantt-window { margin: .8rem 0 .65rem; font-size: .76rem; font-weight: 650; color: #3c526b; font-variant-numeric: tabular-nums; }
.native-gantt-panel .native-gantt-legend { gap: .4rem .8rem; margin: 0 0 .85rem; font-size: .67rem; color: #53647a; }
.native-gantt-panel .native-gantt-legend span { display: inline-flex; align-items: center; }
.native-gantt-panel .native-gantt-legend span::before { width: .55rem; height: .55rem; border-radius: .18rem; }
.native-gantt-panel .native-gantt-legend [data-kind="picking"], .native-gantt-panel .native-timeline-event[data-kind="picking"] { --activity-color: #2e9d8a; }
.native-gantt-panel .native-gantt-legend [data-kind="walking"], .native-gantt-panel .native-timeline-event[data-kind="walking"] { --activity-color: #69a9d7; }
.native-gantt-panel .native-gantt-legend [data-kind="waiting"], .native-gantt-panel .native-timeline-event[data-kind="waiting"] { --activity-color: #e2b25c; }
.native-gantt-panel .native-gantt-legend [data-kind="congestion"], .native-gantt-panel .native-timeline-event[data-kind="congestion"] { --activity-color: #d97776; }
.native-gantt-panel .native-gantt-legend [data-kind="transport"], .native-gantt-panel .native-timeline-event[data-kind="transport"] { --activity-color: #6f8fc9; }
.native-gantt-panel .native-gantt-legend [data-kind="relocation"], .native-gantt-panel .native-timeline-event[data-kind="relocation"] { --activity-color: #a18cce; }
.native-gantt-panel .native-gantt-legend [data-kind="pause"], .native-gantt-panel .native-timeline-event[data-kind="pause"] { --activity-color: #a9b89f; }
.native-gantt-panel .native-gantt-legend [data-kind="idle"] { --activity-color: #e7ecf2; }
.native-gantt-panel .native-timeline { --gantt-label-width: 176px; position: relative; max-width: 100%; max-height: 620px; overflow: auto; overscroll-behavior: contain; scrollbar-gutter: stable; border: 1px solid #dce4ee; border-radius: .65rem; background: white; scrollbar-color: #c2cedc #f4f7fa; scrollbar-width: thin; }
.native-gantt-panel .native-gantt-canvas { width: 100%; }
.native-gantt-panel .native-gantt-axis, .native-gantt-panel .timeline-lane { display: grid; grid-template-columns: var(--gantt-label-width) minmax(0,1fr); column-gap: 0; margin: 0; }
.native-gantt-panel .native-gantt-axis { position: sticky; top: 0; z-index: 5; min-height: 42px; border-bottom: 1px solid #dce4ee; background: #f7f9fc; color: #5b6e85; font-size: .66rem; font-weight: 650; }
.native-gantt-panel .native-gantt-axis > .native-gantt-axis-label { position: sticky; left: 0; z-index: 7; align-self: stretch; display: flex; align-items: center; padding: 0 .8rem; border-right: 1px solid #dce4ee; background: #f7f9fc; font-size: .72rem; }
.native-gantt-panel .native-gantt-axis > .native-gantt-axis-times { height: 42px; background: transparent; }
.native-gantt-panel .native-gantt-axis-times > span { top: 12px; padding: 0 3px; background: #f7f9fc; font-variant-numeric: tabular-nums; }
.native-gantt-panel .native-gantt-axis-times > span:first-of-type { transform: none; }
.native-gantt-panel .native-gantt-axis .native-gantt-axis-times > span { visibility: visible; }
.native-gantt-panel .native-gantt-axis-times > span[data-initial-end] { transform: translateX(-100%); }
.native-gantt-panel .area-gantt { min-width: 0; margin: 0; padding: 0; border: 0; border-radius: 0; background: white; }
.native-gantt-panel .area-gantt + .area-gantt { border-top: 1px solid #dce4ee; }
.native-gantt-panel .area-gantt-heading { display: flex; align-items: center; gap: .65rem; min-height: 45px; padding: .5rem .8rem; background: #eef3f9; font-size: .83rem; }
.native-gantt-panel .native-area-name { position: sticky; left: .8rem; z-index: 2; min-width: 130px; background: #eef3f9; }
.native-gantt-panel .native-area-count { padding: .18rem .5rem; border: 1px solid #d9e3f0; border-radius: 1rem; background: #f8fafd; color: #66788e; font-size: .66rem; font-weight: 500; }
.native-gantt-panel .timeline-lane { min-height: 54px; border-bottom: 1px solid #edf1f6; align-items: stretch; }
.native-gantt-panel .timeline-lane:nth-of-type(2n) { background: #fcfdfe; }
.native-gantt-panel .timeline-lane > .timeline-resource { position: sticky; left: 0; z-index: 3; display: flex; flex-direction: column; justify-content: center; gap: .15rem; min-width: 0; padding: .55rem .8rem; border-right: 1px solid #dce4ee; background: white; box-shadow: 2px 0 3px #24415c04; }
.native-gantt-panel .timeline-resource strong { overflow: hidden; color: #30455e; font-size: .73rem; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.native-gantt-panel .timeline-resource small { overflow: hidden; color: #8a98a9; font-size: .6rem; font-weight: 400; text-overflow: ellipsis; white-space: nowrap; }
.native-gantt-panel .native-timeline-rail { height: 54px; min-height: 54px; border-radius: 0; background: transparent; }
.native-gantt-panel .native-timeline-event { top: 12px; bottom: 12px; height: 30px; min-width: 0; border: 0; border-radius: 6px; box-shadow: inset 0 -1px 0 #00000010; cursor: default; font-style: normal; }
.native-gantt-panel .native-timeline-event.native-release-unverified { box-shadow: inset 0 0 0 2px #a74700; outline: 1px dashed #a74700; }
.native-gantt-panel .native-timeline-event > span { display: block; overflow: hidden; padding: 0 .55rem; color: white; font-size: .65rem; font-weight: 600; line-height: 30px; text-overflow: ellipsis; white-space: nowrap; }
.native-gantt-panel .native-timeline-event[data-kind="idle"] { background: #f4f6f9; box-shadow: none; border: 1px dashed #e2e8ef; border-radius: 3px; }
.native-gantt-panel .native-timeline-event:hover { filter: brightness(1.06); }
.native-gantt-panel .native-timeline-event:focus-visible { z-index: 2; outline: 2px solid #234f8d; outline-offset: 2px; }
.native-gantt-panel .native-area-actions { position: sticky; left: 0; width: fit-content; max-width: 100%; padding: .65rem .8rem; }
.native-gantt-panel .native-area-actions .button { min-height: 30px; padding: .35rem .6rem; font-size: .67rem; }
.native-gantt-panel .native-area-empty { padding: .8rem; font-size: .75rem; }
.native-gantt-panel .native-gantt-tooltip { position: absolute; z-index: 20; width: max-content; max-width: min(320px,calc(100% - 16px)); padding: .65rem .8rem; border: 1px solid #d9e3ef; border-radius: .6rem; background: #fff; box-shadow: 0 7px 25px #24415c25; color: #30455e; font-size: .73rem; line-height: 1.45; overflow-wrap: anywhere; pointer-events: none; }
.native-gantt-panel .native-gantt-tooltip[hidden] { display: none; }
.native-gantt-panel .native-gantt-tooltip p { margin: .3rem 0 0; color: #6b7c90; font-size: .67rem; }
@media(max-width:620px) { .native-gantt-panel .native-gantt-toolbar { gap: .55rem; padding: .65rem; } .native-gantt-panel .native-shift-select:first-child { flex-basis: 100%; } .native-gantt-panel .native-gantt-legend { gap: .3rem .65rem; } .native-gantt-panel .native-timeline { max-height: 540px; } }

.native-gantt-panel .native-gantt-grid-line { position: absolute; top: 0; bottom: 0; width: 1px; background: #e8edf4; pointer-events: none; }
.native-gantt-panel .native-late-window { position: absolute; top: 0; bottom: 0; background: #7a818d30; border-left: 1px dashed #7a818d; border-right: 1px dashed #7a818d; pointer-events: none; }
.native-gantt-panel .native-late-legend::before { background: #bfc3ca; border: 1px dashed #7a818d; }
.native-gantt-panel .native-gantt-legend [data-kind="packing"], .native-gantt-panel .native-timeline-event[data-kind="packing"] { --activity-color: #7363ad; }
@media(max-width:620px) {
  .native-gantt-panel .native-timeline { --gantt-label-width: 112px; }
  .native-gantt-panel .native-gantt-axis, .native-gantt-panel .native-gantt-axis > .native-gantt-axis-times { min-height: 54px; height: 54px; }
  .native-gantt-panel .native-gantt-axis .native-gantt-axis-times > span { top: 21px; font-size: 10px; transform: translateX(-50%) rotate(-90deg); }
  .native-gantt-panel .native-gantt-axis-times > span:first-of-type { margin-left: 7px; }
  .native-gantt-panel .native-gantt-axis-times > span[data-initial-end], .native-gantt-panel .native-gantt-axis-times > span:last-of-type { margin-left: -7px; }
}
.native-gantt-panel .timeline-lane:hover, .native-gantt-panel .timeline-lane:focus-within { background: #f1f6fd; }
.native-gantt-panel .timeline-lane:hover > .timeline-resource, .native-gantt-panel .timeline-lane:focus-within > .timeline-resource { background: #f1f6fd; }
#native-plan-workspace:not(.daily-plan-only) > .plan-workspace { grid-template-columns: minmax(0,3fr) minmax(380px,2fr); }
@media(max-width:1180px) { #native-plan-workspace:not(.daily-plan-only) > .plan-workspace { grid-template-columns: minmax(0,1fr); } #native-plan-workspace .maestro-dock { position: static; } }

/* Read-only materials for one assigned cart trip; the plan remains untouched. */
.native-gantt-panel button.native-timeline-event { appearance: none; margin: 0; padding: 0; text-align: left; cursor: pointer; }
.native-gantt-panel .native-gantt-legend [data-kind="cart_cycle"], .native-gantt-panel .native-timeline-event[data-kind="cart_cycle"] { --activity-color: #188f83; }
.native-gantt-panel .native-timeline-event > .native-cycle-pause { position: absolute; top: 0; height: 100%; padding: 0; background: repeating-linear-gradient(135deg,#a9b89f 0 4px,#d8e0d2 4px 8px); opacity: .9; }
.native-gantt-panel .native-timeline-event.native-priority-task,
.native-gantt-panel .native-timeline-event.native-priority-task > span { color: var(--priority-text-color, #10233d); }
.native-picking-backlog { margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid #dce4ee; }
.native-backlog-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: .65rem; }
.native-backlog-card { padding: .85rem; border: 1px solid #cbd5e1; border-radius: .5rem; background: #e2e8f0; color: #10233d; overflow-wrap: anywhere; }
.native-backlog-card p { margin: .35rem 0 0; }
.native-gantt-legend [data-priority-degree]:not(.native-priority-task)::before { display: none; }
.estimated-resource-bar.native-priority-task { background: var(--activity-color); }
.estimated-resource-bar.native-priority-task.unfinished { background: repeating-linear-gradient(135deg,var(--activity-color) 0 5px,#ffffff80 5px 10px); }
.native-task-breakdown { margin-bottom: 1.25rem; }
.native-task-breakdown h3 { margin-top: 0; }
.native-transport-panel [data-phase="empty_move"] { opacity: .55; }
.native-gantt-panel .native-task-dialog { width: min(880px,calc(100vw - 32px)); max-width: none; max-height: 90dvh; margin: auto; padding: 0; overflow: hidden; border: 1px solid #d5e0eb; border-radius: 14px; color: #30455e; background: #fff; box-shadow: 0 24px 80px #16304740; }
.native-gantt-panel .native-task-dialog[open] { display: flex; flex-direction: column; }
.native-gantt-panel .native-task-dialog::backdrop { background: #16304780; }
.native-gantt-panel .native-task-header { display: flex; flex: 0 0 auto; align-items: start; justify-content: space-between; gap: 1rem; padding: 1.1rem 1.25rem; border-bottom: 1px solid #e1e8f0; background: #f7f9fc; }
.native-gantt-panel .native-task-header > div { min-width: 0; overflow-wrap: anywhere; }
.native-gantt-panel .native-task-header h2 { margin: 0 0 .35rem; color: #24394f; font-size: 1.1rem; }
.native-gantt-panel .native-task-header p { margin: 0; color: #66788e; font-size: .78rem; }
.native-gantt-panel .native-task-header > button { flex: 0 0 auto; min-height: 36px; padding: .4rem .65rem; font-size: .75rem; }
.native-gantt-panel .native-task-body { min-height: 0; padding: 1.1rem 1.25rem 1.25rem; overflow: auto; overscroll-behavior: contain; overflow-wrap: anywhere; }
.native-gantt-panel .native-task-body > p { margin: 0 0 .8rem; line-height: 1.5; }
.native-gantt-panel .native-task-total { color: #167c6f; font-size: 1.25rem; font-weight: 750; font-variant-numeric: tabular-nums; }
.native-gantt-panel .native-task-lists { color: #40566e; font-size: .78rem; }
.native-gantt-panel .native-task-note { padding: .7rem .8rem; border-radius: .5rem; color: #725722; background: #faf5e9; font-size: .74rem; }
.native-gantt-panel .native-task-loading { padding: .2rem 0; color: #536d85; font-size: .85rem; }
.native-gantt-panel .native-task-loading::before { content: ""; display: inline-block; width: .9rem; height: .9rem; margin-right: .5rem; vertical-align: -.15rem; border: 2px solid #d9e5eb; border-top-color: #167c6f; border-radius: 50%; animation: daily-summary-spin .9s linear infinite; }
.native-gantt-panel .native-task-error { color: #975046; font-size: .8rem; }
.native-gantt-panel .native-task-rua { min-width: 0; margin-top: 1.3rem; }
.native-gantt-panel .native-task-rua h3 { margin: 0 0 .2rem; font-size: .92rem; }
.native-gantt-panel .native-task-rua-total { margin: 0 0 .6rem; color: #6a7c90; font-size: .73rem; font-variant-numeric: tabular-nums; }
.native-gantt-panel .native-task-table { width: 100%; table-layout: fixed; border-collapse: collapse; font-size: .76rem; }
.native-gantt-panel .native-task-table th, .native-gantt-panel .native-task-table td { padding: .65rem .7rem; border-bottom: 1px solid #e7edf3; text-align: left; vertical-align: top; overflow-wrap: anywhere; }
.native-gantt-panel .native-task-table th { color: #536c83; background: #f1f5f9; font-size: .7rem; font-weight: 650; }
.native-gantt-panel .native-task-table th:last-child, .native-gantt-panel .native-task-table td.native-task-pieces { width: 5.7rem; text-align: right; font-variant-numeric: tabular-nums; }
@media(max-width:620px) { .native-gantt-panel .native-task-dialog { width: calc(100vw - 20px); } .native-gantt-panel .native-task-header, .native-gantt-panel .native-task-body { padding: .9rem; } .native-gantt-panel .native-task-table th, .native-gantt-panel .native-task-table td { padding: .55rem .35rem; } .native-gantt-panel .native-task-table th:last-child, .native-gantt-panel .native-task-table td.native-task-pieces { width: 4.5rem; } }
@media(prefers-reduced-motion:reduce) { .native-gantt-panel .native-task-loading::before { animation: none; } }


/* Planning shell and measured lifecycle feedback. */
.shell-header { min-height: 72px; grid-template-columns: minmax(0,1fr) auto minmax(0,1fr); gap: 28px; padding: 0 28px; background: radial-gradient(circle at 88% -110%, rgba(21,167,207,.32), transparent 31rem), var(--navy); border-bottom: 1px solid rgba(140,206,230,.16); box-shadow: 0 6px 22px rgba(7,26,43,.15); }
.shell-header .brand { min-width: 0; max-width: 100%; }
.shell-header .brand-logo { width: 178px; max-width: 100%; height: auto; max-height: 51px; object-fit: contain; object-position: left center; }
.shell-product-title { min-width: 0; color: #6ed0e5; text-align: center; font-size: 10px; font-weight: 800; line-height: 1.45; letter-spacing: .17em; text-transform: uppercase; }
.profile-indicator { display: grid; justify-self: end; place-items: center; width: 34px; height: 34px; border: 1px solid rgba(114,205,228,.38); border-radius: 50%; color: #e5f9fd; background: rgba(18,166,199,.16); font-size: 11px; font-weight: 800; }
.user-profile { display: block; }
[data-maestro-chat-enabled="false"] .maestro-dock:not(#native-plan-chat),
[data-native-agent-enabled="false"] #native-plan-chat { display: none; }
[data-maestro-chat-enabled="false"] #screen-plano > .plan-workspace,
[data-native-agent-enabled="false"] #native-plan-workspace:not(.daily-plan-only) > .plan-workspace { grid-template-columns: minmax(0, 1fr); }
.picking-progress-region { margin: 1rem 0; padding: .8rem 1rem; border: 1px solid #bdd9d2; border-radius: .65rem; background: #f5faf8; }
.picking-progress-region p { margin: 0 0 .6rem; color: var(--ink); font-size: .875rem; line-height: 1.5; }
.picking-progress-region progress { display: block; width: 100%; height: .5rem; overflow: hidden; border: 0; border-radius: 999px; background: #dce8ee; accent-color: var(--teal-dark); }
.picking-progress-stages { display: flex; flex-wrap: wrap; gap: .35rem 1rem; padding: 0; margin: .6rem 0 0; list-style: none; color: var(--ink); font-size: .72rem; }
.picking-progress-stages li { display: inline-flex; align-items: center; gap: .35rem; }
.picking-progress-stages li::before { content: ""; width: .4rem; height: .4rem; flex: none; border-radius: 50%; background: #c8d9d4; }
.picking-progress-stages li[data-complete="true"]::before { background: var(--teal-dark); }
.picking-progress-stages li[aria-current="step"] { color: var(--teal-dark); font-weight: 700; }
.picking-progress-stages li[aria-current="step"]::before { background: var(--teal-dark); box-shadow: 0 0 0 3px #d8ece5; }
.plan-approval { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 20px; padding: 18px 22px; border: 1px solid #e1cba3; border-left: 4px solid #c88a20; border-radius: 12px; background: #fffaf0; }
.plan-approval[hidden] { display: none; }
.plan-approval h2 { margin: 0 0 6px; font-size: 1.1rem; }
.plan-approval .context-note { margin: 5px 0 0; }
.plan-approval .step-label { margin: 0 0 6px; }
.plan-approval[data-approval-state="confirmed_current"] { border-color: #b8d9cb; border-left-color: #258766; background: #f1faf5; }
.plan-approval[data-approval-state="confirmed_superseded"] { border-color: #cfdae4; border-left-color: #8097aa; background: #f5f8fb; }
@media (max-width: 700px) {
  .plan-approval { align-items: stretch; flex-direction: column; gap: 14px; }
}
.picking-progress-region progress::-webkit-progress-bar { border-radius: 999px; background: #dce8ee; }
.picking-progress-region progress::-webkit-progress-value { border-radius: 999px; background: var(--teal-dark); transition: width .25s ease-out; }
.picking-progress-region progress::-moz-progress-bar { border-radius: 999px; background: var(--teal-dark); transition: width .25s ease-out; }
.picking-progress-region progress:not([value])::-webkit-progress-bar { background: linear-gradient(90deg, #dce8ee 20%, #4b9b8e 50%, #dce8ee 80%); background-size: 200% 100%; animation: picking-progress-active 1.5s linear infinite; }
@keyframes picking-progress-active { to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) {
  .picking-progress-region progress { transition-duration: 0s !important; }
  .picking-progress-region progress::-webkit-progress-value { transition: none; }
  .picking-progress-region progress::-moz-progress-bar { transition: none; }
  .picking-progress-region progress:not([value])::-webkit-progress-bar { animation: none; }
}
.picking-progress-region[data-state="completed"] { border-color: #afd4c6; background: #f1f9f5; }
.picking-progress-region[data-state="failed"] { border-color: #dfc0ae; background: #fff6ee; }
.picking-progress-region[data-state="failed"] p { margin-bottom: 0; }
@media (max-width: 1180px) {
  .shell-header .brand-logo { width: 158px; }
}
@media (max-width: 920px) {
  .shell-header { padding-right: 20px; padding-left: 20px; }
}
@media (max-width: 880px) {
  .shell-header { grid-template-columns: minmax(0,1fr) auto; gap: 10px; }
  .shell-header .brand { grid-column: 1; grid-row: 1; }
  .shell-product-title { grid-column: 1 / -1; grid-row: 2; }
  .profile-indicator { grid-column: 2; grid-row: 1; }
}
@media (max-width: 700px) {
  .shell-header { min-height: 62px; padding-right: 15px; padding-left: 15px; }
  .shell-header .brand-logo { width: 142px; }
}
@media (max-width: 620px) {
  .picking-progress-region { padding: .8rem; }
}

.native-estimated-resources { margin: 1rem 0; padding: .85rem; border: 1px solid #dce4ee; border-radius: .65rem; background: #f7f9fc; }
.native-estimated-resources h3, .native-estimated-resources h4 { margin: 0 0 .4rem; }
.native-estimated-resources .context-note { margin: .35rem 0 .7rem; }
.estimated-resource-group + .estimated-resource-group { margin-top: 1rem; }
.estimated-resource-row { display: grid; grid-template-columns: minmax(110px, 176px) minmax(0, 1fr); align-items: center; gap: .5rem; min-height: 30px; font-size: .72rem; }
.estimated-resource-rail { position: relative; height: 20px; background: #e7ecf2; border-radius: .25rem; }
.estimated-resource-bar { position: absolute; top: 2px; bottom: 2px; min-width: 2px; border-radius: .2rem; background: #526d9a; }
.estimated-resource-bar.unfinished { background: repeating-linear-gradient(135deg, #a16e28 0 5px, #d5ab6d 5px 10px); }
.estimated-resource-bar:focus-visible { outline: 2px solid #234f8d; outline-offset: 2px; }

.picking-completion-forecast { margin-top: 1rem; }
.picking-completion-metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr)); gap: .75rem; margin: 1rem 0; }
.native-gantt-legend .native-forecast-legend::before { background: #7a818d30; border: 1px dashed #7a818d; }
