:root {
    --plant-canvas: #f3f5f1;
    --plant-panel: #ffffff;
    --plant-panel-muted: #e9ede7;
    --plant-inset: #eef1ec;
    --plant-ink: #17201b;
    --plant-ink-secondary: #46534b;
    --plant-ink-tertiary: #68746d;
    --plant-ink-muted: #89928c;
    --pipe-green: #245c3a;
    --pipe-green-strong: #19482c;
    --pipe-green-soft: #dce9df;
    --steel-border: rgba(23, 32, 27, .14);
    --steel-border-soft: rgba(23, 32, 27, .08);
    --steel-border-strong: rgba(23, 32, 27, .26);
    --straw-warning: #9a6816;
    --straw-warning-bg: #f5ead2;
    --alarm-danger: #a23d35;
    --alarm-danger-bg: #f5dfdc;
    --flow-success: #2e6844;
    --flow-success-bg: #dcecdf;
    --status-info: #345f76;
    --status-info-bg: #dce9ef;
    --font-display: Bahnschrift, "DIN Alternate", "Arial Narrow", sans-serif;
    --font-body: Aptos, "Segoe UI Variable", "Segoe UI", sans-serif;
    --text-caption: 12px;
    --text-body: 14px;
    --text-label: 14px;
    --text-h3: 17px;
    --text-h2: 20px;
    --text-h1: 24px;
    --text-display: 32px;
    --space-1: 4px;
    --space-2: 8px;
    --space-3: 12px;
    --space-4: 16px;
    --space-5: 20px;
    --space-6: 24px;
    --space-8: 32px;
    --space-10: 40px;
    --space-12: 48px;
    --space-16: 64px;
    --radius-control: 4px;
    --radius-panel: 6px;
    --radius-dialog: 8px;
    color-scheme: light;
}

/* Analýza plynu — laboratorní výsledky a konfigurovatelné provozní limity. */
.gas-workspace { display: grid; gap: var(--space-5); }
.gas-workspace > .page-heading { margin-bottom: 0; }
.gas-heading-actions { display: flex; justify-content: flex-end; gap: var(--space-3); flex-wrap: wrap; }
.gas-commandbar { min-height: 68px; display: grid; grid-template-columns: 240px minmax(0, 1fr); border: 1px solid var(--steel-border); border-radius: var(--radius-panel); background: var(--plant-panel); overflow: hidden; }
.gas-year-nav { display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; gap: var(--space-2); padding: var(--space-3); border-right: 1px solid var(--steel-border); background: var(--plant-panel-muted); }
.gas-year-nav .button { width: 44px; min-height: 44px; padding: 0; font-size: 20px; }
.gas-year-nav > div { display: grid; justify-items: center; gap: 1px; }
.gas-year-nav span { color: var(--plant-ink-tertiary); font-size: 10px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.gas-year-nav strong { font-family: var(--font-display); font-size: var(--text-h3); font-variant-numeric: tabular-nums; }
.gas-legend { display: flex; align-items: center; justify-content: flex-end; gap: var(--space-5); padding: var(--space-3) var(--space-5); }
.gas-legend > span { display: inline-flex; align-items: center; gap: var(--space-2); color: var(--plant-ink-secondary); font-size: var(--text-caption); font-weight: 650; white-space: nowrap; }
.gas-legend small { max-width: 280px; color: var(--plant-ink-tertiary); }
.gas-node { width: 9px; height: 9px; border-radius: 50%; background: var(--plant-ink-muted); }
.gas-node--success { background: var(--flow-success); }.gas-node--warning { background: var(--straw-warning); }.gas-node--danger { background: var(--alarm-danger); }
.gas-state { min-height: 160px; display: grid; place-items: center; color: var(--plant-ink-secondary); }
.gas-table-panel { min-width: 0; overflow: hidden; }
.gas-table-heading { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); padding: var(--space-4) var(--space-5); border-bottom: 1px solid var(--steel-border-soft); }
.gas-table-heading h2 { margin: 2px 0 0; }.gas-table-heading > span { color: var(--plant-ink-tertiary); font-size: var(--text-caption); font-weight: 650; }
.gas-table-scroll { max-width: 100%; overflow: auto; outline: none; }.gas-table-scroll:focus-visible { box-shadow: inset 0 0 0 3px rgba(36, 92, 58, .22); }
.gas-table { min-width: 960px; font-variant-numeric: tabular-nums; }
.gas-table th small { display: block; margin-top: 2px; font-size: 10px; font-weight: 600; letter-spacing: 0; text-transform: none; }
.gas-table th:nth-child(n+3), .gas-table .gas-value { text-align: right; }
.gas-table td { height: 52px; }.gas-table .gas-date { white-space: nowrap; }.gas-table .gas-date strong { color: var(--plant-ink); }
.gas-value { position: relative; min-width: 88px; border-left: 1px solid var(--steel-border-soft); color: var(--plant-ink); outline: none; }
.gas-value::before { content: ""; position: absolute; left: 0; top: 13px; bottom: 13px; width: 3px; background: transparent; }
.gas-value.is-success { background: color-mix(in srgb, var(--flow-success-bg) 72%, var(--plant-panel)); color: var(--pipe-green-strong); }.gas-value.is-success::before { background: var(--flow-success); }
.gas-value.is-warning { background: color-mix(in srgb, var(--straw-warning-bg) 72%, var(--plant-panel)); color: #714b10; }.gas-value.is-warning::before { background: var(--straw-warning); }
.gas-value.is-danger { background: color-mix(in srgb, var(--alarm-danger-bg) 72%, var(--plant-panel)); color: #812f29; }.gas-value.is-danger::before { background: var(--alarm-danger); }
.gas-value:focus-visible { box-shadow: inset 0 0 0 2px currentColor; }.gas-value strong { font-weight: 750; }.gas-missing { color: var(--plant-ink-muted); }
.gas-note { min-width: 220px; max-width: 360px; color: var(--plant-ink-secondary); white-space: normal; overflow-wrap: anywhere; }
.gas-empty { min-height: 200px; display: flex; align-items: center; justify-content: center; gap: var(--space-4); color: var(--plant-ink-secondary); }
.gas-empty__mark { width: 44px; height: 40px; display: grid; place-items: center; border: 1px solid var(--steel-border); background: var(--plant-inset); color: var(--pipe-green); font-family: var(--font-display); font-size: 12px; font-weight: 700; }
.gas-empty > div { display: grid; gap: 2px; }.gas-empty strong { color: var(--plant-ink); }.gas-empty small { color: var(--plant-ink-tertiary); }
.gas-entry-dialog { width: min(100%, 760px); }.gas-date-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-4); }
.gas-metric-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-4); padding: var(--space-4); border: 1px solid var(--steel-border-soft); background: var(--plant-panel-muted); }
.gas-metric-field { margin: 0; }.gas-metric-field label { display: flex; justify-content: space-between; gap: var(--space-2); }.gas-metric-field label small { color: var(--plant-ink-tertiary); font-weight: 500; }
.gas-metric-field input { text-align: right; font-variant-numeric: tabular-nums; }
.gas-settings-dialog { width: min(1120px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); }
.gas-settings-body { min-height: 0; overflow: hidden; display: grid; grid-template-columns: 260px minmax(0, 1fr); }
.gas-metric-list { min-height: 0; overflow-y: auto; padding: var(--space-3); border-right: 1px solid var(--steel-border); background: var(--plant-panel-muted); }
.gas-metric-list button { width: 100%; min-height: 56px; display: grid; grid-template-columns: 48px 1fr auto; align-items: center; gap: var(--space-2); padding: var(--space-2) var(--space-3); border: 0; border-left: 3px solid transparent; background: transparent; color: var(--plant-ink-secondary); text-align: left; cursor: pointer; }
.gas-metric-list button:hover { background: var(--plant-panel); }.gas-metric-list button.is-selected { border-left-color: var(--pipe-green); background: var(--pipe-green-soft); color: var(--plant-ink); }
.gas-metric-list button strong { color: var(--plant-ink); font-family: var(--font-display); }.gas-metric-list button span { overflow: hidden; text-overflow: ellipsis; }.gas-metric-list button small { color: var(--plant-ink-tertiary); font-size: 10px; text-transform: uppercase; }
.gas-metric-list .gas-add-metric { grid-template-columns: 1fr; min-height: 44px; margin-top: var(--space-3); border: 1px dashed var(--steel-border-strong); color: var(--pipe-green); text-align: center; }
.gas-settings-editor { min-height: 0; overflow-y: auto; display: grid; align-content: start; gap: var(--space-5); padding: var(--space-5); }
.gas-definition-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.4fr; gap: var(--space-4); }.gas-definition-grid .field { margin: 0; }
.gas-active-toggle { min-height: 44px; display: flex; align-items: center; gap: var(--space-3); padding: var(--space-2) var(--space-3); border: 1px solid var(--steel-border-soft); background: var(--plant-panel-muted); font-weight: 650; }
.gas-active-toggle input { width: 20px; height: 20px; accent-color: var(--pipe-green); }
.gas-comparison-config { display: grid; grid-template-columns: minmax(240px, 360px) 1fr; align-items: end; gap: var(--space-4); padding: var(--space-4); border-left: 3px solid var(--status-info); background: var(--status-info-bg); }.gas-comparison-config .field { margin: 0; }.gas-comparison-config p { margin: 0 0 var(--space-2); color: var(--plant-ink-secondary); }
.gas-range-editor { display: grid; gap: var(--space-3); padding-top: var(--space-4); border-top: 1px solid var(--steel-border); }.gas-range-editor > header { display: flex; align-items: start; justify-content: space-between; gap: var(--space-4); }.gas-range-editor h3 { margin: 0; }.gas-range-editor p { margin: 2px 0 0; color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.gas-range-row { display: grid; grid-template-columns: 1fr 1fr 1.2fr 40px; align-items: end; gap: var(--space-3); padding: var(--space-3); border: 1px solid var(--steel-border-soft); background: var(--plant-panel-muted); }.gas-range-row .field { margin: 0; }.gas-range-remove { width: 40px; min-height: 42px; padding: 0; color: var(--alarm-danger); font-size: 20px; }
.gas-range-empty { min-height: 72px; display: grid; place-items: center; border: 1px dashed var(--steel-border); color: var(--plant-ink-tertiary); }

@media (max-width: 980px) {
    .gas-commandbar { grid-template-columns: 220px minmax(0, 1fr); }.gas-legend { justify-content: flex-start; flex-wrap: wrap; gap: var(--space-3) var(--space-4); }.gas-legend small { width: 100%; max-width: none; }
    .gas-metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }.gas-settings-body { grid-template-columns: 220px minmax(0, 1fr); }.gas-definition-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
    .gas-heading-actions { width: 100%; display: grid; grid-template-columns: 1fr; }.gas-heading-actions .button { width: 100%; }
    .gas-commandbar { grid-template-columns: 1fr; }.gas-year-nav { border-right: 0; border-bottom: 1px solid var(--steel-border); }.gas-legend { padding: var(--space-3); }
    .gas-table-heading { padding: var(--space-4); }.gas-empty { align-items: flex-start; padding: var(--space-6) var(--space-4); }
    .gas-date-grid, .gas-metric-grid { grid-template-columns: 1fr; }.gas-metric-grid { padding: var(--space-3); }
    .gas-settings-dialog { width: 100%; max-width: none; }.gas-settings-body { grid-template-columns: 1fr; overflow-y: auto; }.gas-metric-list { max-height: 184px; border-right: 0; border-bottom: 1px solid var(--steel-border); }.gas-settings-editor { overflow: visible; padding: var(--space-4); }
    .gas-definition-grid, .gas-comparison-config { grid-template-columns: 1fr; }.gas-range-editor > header { align-items: stretch; flex-direction: column; }.gas-range-editor > header .button { width: 100%; }.gas-range-row { grid-template-columns: 1fr 1fr; }.gas-range-row .field:nth-child(3) { grid-column: 1 / -1; }.gas-range-remove { grid-column: 2; justify-self: end; }
}

h1:focus {
    outline: none;
}

*, *::before, *::after { box-sizing: border-box; }

html {
    min-height: 100%;
    max-width: 100%;
    overflow-x: clip;
    background: var(--plant-canvas);
    font-family: var(--font-body);
    font-size: 14px;
    color: var(--plant-ink);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

body {
    min-height: 100vh;
    max-width: 100%;
    overflow-x: clip;
    margin: 0;
    background: var(--plant-canvas);
    color: var(--plant-ink);
    font-family: var(--font-body);
    font-size: var(--text-body);
    line-height: 1.5;
}

a { color: var(--pipe-green); text-underline-offset: 3px; }
a:hover { color: var(--pipe-green-strong); }

button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }

h1, h2, h3, h4 {
    margin: 0;
    color: var(--plant-ink);
    font-family: var(--font-display);
    font-weight: 650;
    letter-spacing: -.018em;
    line-height: 1.18;
    text-wrap: balance;
}

h1 { font-size: var(--text-h1); }
h2 { font-size: var(--text-h2); }
h3 { font-size: var(--text-h3); }
p { text-wrap: pretty; }

:focus-visible {
    outline: 2px solid var(--pipe-green);
    outline-offset: 2px;
}

::selection { background: var(--pipe-green-soft); color: var(--pipe-green-strong); }

.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

.eyebrow {
    color: var(--pipe-green);
    font-family: var(--font-display);
    font-size: var(--text-caption);
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.page-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: var(--space-6);
    margin-bottom: var(--space-6);
}

.page-heading > div:first-child { max-width: 760px; }
.page-heading h1 { margin-top: var(--space-1); font-size: 28px; }
.page-heading p { margin: var(--space-2) 0 0; color: var(--plant-ink-secondary); }
.page-heading--dashboard { margin-bottom: var(--space-8); }

.time-block {
    display: grid;
    min-width: 148px;
    gap: 2px;
    padding-left: var(--space-4);
    border-left: 2px solid var(--pipe-green);
    text-align: right;
}

.time-block span { color: var(--plant-ink-tertiary); font-size: var(--text-caption); text-transform: capitalize; }
.time-block strong { font-family: var(--font-display); font-size: 18px; font-variant-numeric: tabular-nums; }

.panel {
    padding: var(--space-6);
    border: 1px solid var(--steel-border);
    border-radius: var(--radius-panel);
    background: var(--plant-panel);
}

.panel--flush { padding: 0; overflow: hidden; }

.section-heading {
    display: flex;
    justify-content: space-between;
    gap: var(--space-4);
    margin-bottom: var(--space-5);
}

.section-heading h2 { margin-top: var(--space-1); }
.section-heading p { margin: var(--space-1) 0 0; color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.section-heading--padded { padding: var(--space-5) var(--space-6) 0; }

.content-grid { display: grid; gap: var(--space-6); align-items: start; }
.content-standard, .content-wide, .content-workspace { width: 100%; min-width: 0; }
.content-grid--narrow { grid-template-columns: minmax(0, 680px) minmax(240px, 320px); }
.content-grid--form { grid-template-columns: minmax(0, 780px) minmax(240px, 320px); }

.dashboard-layout { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(280px, .8fr); gap: var(--space-6); margin-top: var(--space-6); }
.operations-status { position: relative; min-height: 176px; display: grid; grid-template-columns: 88px minmax(0, 1fr) auto; align-items: center; gap: var(--space-6); padding: var(--space-6); border: 1px solid var(--steel-border-strong); border-radius: var(--radius-panel); background: var(--plant-panel); }
.operations-status h2 { margin: var(--space-1) 0 var(--space-2); font-size: 22px; }
.operations-status p { max-width: 720px; margin: 0; color: var(--plant-ink-secondary); }
.operations-status__flow { position: relative; width: 72px; height: 112px; display: flex; flex-direction: column; align-items: center; justify-content: space-between; }
.operations-status__flow::before { content: ""; position: absolute; inset: 5px auto; width: 2px; background: var(--pipe-green); }
.operations-status__flow span { z-index: 1; width: 12px; height: 12px; border: 2px solid var(--pipe-green); background: var(--plant-panel); }
.operations-status__flow i { z-index: 1; width: 8px; height: 8px; border-radius: 50%; background: var(--pipe-green); box-shadow: 0 0 0 4px var(--pipe-green-soft); }

.task-list { display: grid; }
.task-link { min-height: 68px; display: grid; grid-template-columns: 36px minmax(0, 1fr) 24px; align-items: center; gap: var(--space-3); padding: var(--space-3) 0; border-top: 1px solid var(--steel-border-soft); color: var(--plant-ink); text-decoration: none; }
.task-link:first-child { border-top: 0; }
.task-link:hover strong { color: var(--pipe-green); }
.task-link > span:nth-child(2) { display: grid; gap: 2px; }
.task-link strong { font-weight: 650; transition: color 140ms ease-out; }
.task-link small { color: var(--plant-ink-tertiary); }
.task-link__index { color: var(--plant-ink-muted); font-family: var(--font-display); font-size: var(--text-caption); font-variant-numeric: tabular-nums; }
.system-panel h2 { margin: var(--space-1) 0 var(--space-4); }
.check-list { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.check-list li { display: grid; grid-template-columns: 10px 1fr; align-items: start; gap: var(--space-3); padding: var(--space-3) 0; border-top: 1px solid var(--steel-border-soft); }
.check-list li span:last-child { display: grid; gap: 2px; color: var(--plant-ink-secondary); }
.check-list strong { color: var(--plant-ink); font-size: var(--text-caption); font-weight: 650; }

.button {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    padding: var(--space-2) var(--space-4);
    border: 1px solid transparent;
    border-radius: var(--radius-control);
    font-size: var(--text-label);
    font-weight: 650;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 140ms ease-out, border-color 140ms ease-out, color 140ms ease-out, transform 120ms ease-out;
}

.button:active:not(:disabled) { transform: scale(.98); }
.button:disabled { cursor: not-allowed; opacity: .52; }
.button--primary { border-color: var(--pipe-green); background: var(--pipe-green); color: #fff; }
.button--primary:hover { border-color: var(--pipe-green-strong); background: var(--pipe-green-strong); color: #fff; }
.button--secondary { border-color: var(--steel-border); background: var(--plant-panel); color: var(--plant-ink); }
.button--secondary:hover { border-color: var(--steel-border-strong); background: var(--plant-panel-muted); color: var(--plant-ink); }
.button--quiet { min-height: 36px; padding: var(--space-1) var(--space-3); border-color: transparent; background: transparent; color: var(--pipe-green); }
.button--quiet:hover { background: var(--pipe-green-soft); color: var(--pipe-green-strong); }
.button--danger-outline { border-color: color-mix(in srgb, var(--alarm-danger) 50%, transparent); background: var(--plant-panel); color: var(--alarm-danger); }
.button--danger-outline:hover { background: var(--alarm-danger-bg); color: var(--alarm-danger); }
.button--danger { border-color: var(--alarm-danger); background: var(--alarm-danger); color: #fff; }
.button--danger:hover { border-color: color-mix(in srgb, var(--alarm-danger) 82%, #000); background: color-mix(in srgb, var(--alarm-danger) 82%, #000); }
.button--small { min-height: 36px; padding: var(--space-1) var(--space-3); font-size: var(--text-caption); }
.button--block { width: 100%; }
.button-row, .form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3); }
.form-actions { margin-top: var(--space-5); padding-top: var(--space-5); border-top: 1px solid var(--steel-border-soft); }

.form-stack { display: grid; gap: var(--space-4); }
.field { display: grid; gap: var(--space-2); }
.field label { color: var(--plant-ink); font-size: var(--text-label); font-weight: 650; }
.field-help { color: var(--plant-ink-tertiary); font-size: var(--text-caption); line-height: 1.45; }
.field-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-4); }
.field--inline { display: flex; align-items: center; gap: var(--space-3); }
.field--inline label { white-space: nowrap; }

input:not([type="checkbox"]):not([type="radio"]), textarea, select, .form-control {
    width: 100%;
    min-height: 42px;
    padding: 9px 12px;
    border: 1px solid var(--steel-border);
    border-radius: var(--radius-control);
    background: var(--plant-inset);
    color: var(--plant-ink);
    line-height: 1.35;
    transition: border-color 140ms ease-out, box-shadow 140ms ease-out, background-color 140ms ease-out;
}

textarea { resize: vertical; min-height: 112px; }
input::placeholder, textarea::placeholder { color: var(--plant-ink-muted); }
input:not([type="checkbox"]):not([type="radio"]):focus, textarea:focus, select:focus, .form-control:focus { outline: 0; border-color: var(--pipe-green); background: var(--plant-panel); box-shadow: 0 0 0 3px rgba(36, 92, 58, .18); }
input:disabled, textarea:disabled, select:disabled { cursor: not-allowed; opacity: .6; }

input[type="checkbox"], input[type="radio"] { width: 18px; height: 18px; margin: 0; accent-color: var(--pipe-green); }
.check-row { min-height: 44px; display: flex; align-items: center; gap: var(--space-3); color: var(--plant-ink-secondary); cursor: pointer; }
.password-field { position: relative; }
.password-field input { padding-right: 88px; }
.password-toggle { position: absolute; top: 3px; right: 3px; min-height: 36px; padding: 0 var(--space-3); border: 0; border-left: 1px solid var(--steel-border-soft); background: transparent; color: var(--pipe-green); font-size: var(--text-caption); font-weight: 650; cursor: pointer; }

.form-section { display: grid; gap: var(--space-4); padding: var(--space-6) 0; border-top: 1px solid var(--steel-border-soft); }
.form-section:first-of-type { padding-top: 0; border-top: 0; }
.form-section > header { display: grid; grid-template-columns: 32px 1fr; gap: var(--space-3); }
.form-section > header > span:last-child { display: grid; gap: 2px; }
.form-section header strong { font-family: var(--font-display); font-size: var(--text-h3); }
.form-section header small { color: var(--plant-ink-tertiary); }
.section-index { color: var(--pipe-green); font-family: var(--font-display); font-size: var(--text-caption); font-weight: 700; }

.choice-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-3); }
.choice-card { min-height: 64px; display: flex; align-items: flex-start; gap: var(--space-3); padding: var(--space-3); border: 1px solid var(--steel-border); border-radius: var(--radius-control); background: var(--plant-panel); cursor: pointer; transition: border-color 140ms ease-out, background-color 140ms ease-out; }
.choice-card:hover { border-color: var(--steel-border-strong); background: var(--plant-panel-muted); }
.choice-card:has(input:checked) { border-color: color-mix(in srgb, var(--pipe-green) 48%, transparent); background: var(--pipe-green-soft); }
.choice-card > span { display: grid; gap: 2px; }
.choice-card strong { font-weight: 650; }
.choice-card small { color: var(--plant-ink-tertiary); }

.validation-message, .validation-summary, .validation-summary-errors { color: var(--alarm-danger); font-size: var(--text-caption); }
.validation-summary ul, .validation-summary-errors ul { margin: var(--space-2) 0 0; padding-left: var(--space-5); }
.invalid { border-color: var(--alarm-danger) !important; }
.valid.modified:not([type="checkbox"]) { border-color: var(--flow-success); }

.alert { margin-bottom: var(--space-5); padding: var(--space-3) var(--space-4); border: 1px solid; border-radius: var(--radius-control); line-height: 1.45; }
.alert ul { margin: var(--space-2) 0 0; padding-left: var(--space-5); }
.alert--danger, .alert-danger { border-color: color-mix(in srgb, var(--alarm-danger) 34%, transparent); background: var(--alarm-danger-bg); color: var(--alarm-danger); }
.alert--success, .alert-success { border-color: color-mix(in srgb, var(--flow-success) 34%, transparent); background: var(--flow-success-bg); color: var(--flow-success); }
.alert--info, .alert-info { border-color: color-mix(in srgb, var(--status-info) 34%, transparent); background: var(--status-info-bg); color: var(--status-info); }

.callout { padding: var(--space-4); border-left: 3px solid; border-radius: 0 var(--radius-control) var(--radius-control) 0; }
.callout strong { display: block; margin-bottom: var(--space-1); font-family: var(--font-display); }
.callout p { margin: 0; color: inherit; line-height: 1.5; }
.callout--warning { border-color: var(--straw-warning); background: var(--straw-warning-bg); color: #6e4a10; }
.callout--info { border-color: var(--status-info); background: var(--status-info-bg); color: #274858; }
.callout.compact { margin: var(--space-4) 0; padding: var(--space-3); }

.status-label { display: inline-flex; align-items: center; gap: var(--space-2); min-height: 30px; padding: var(--space-1) var(--space-3); border: 1px solid; border-radius: var(--radius-control); font-size: var(--text-caption); font-weight: 650; white-space: nowrap; }
.status-label--success { border-color: color-mix(in srgb, var(--flow-success) 28%, transparent); background: var(--flow-success-bg); color: var(--flow-success); }
.status-label--danger { border-color: color-mix(in srgb, var(--alarm-danger) 28%, transparent); background: var(--alarm-danger-bg); color: var(--alarm-danger); }
.status-label--info { border-color: color-mix(in srgb, var(--status-info) 28%, transparent); background: var(--status-info-bg); color: var(--status-info); }
.status-label--muted { border-color: var(--steel-border); background: var(--plant-panel-muted); color: var(--plant-ink-tertiary); }
.status-node { width: 8px; height: 8px; display: inline-block; border-radius: 50%; flex: 0 0 auto; }
.status-node--ok { background: var(--flow-success); box-shadow: 0 0 0 3px var(--flow-success-bg); }
.status-node--danger { background: var(--alarm-danger); box-shadow: 0 0 0 3px var(--alarm-danger-bg); }
.status-node--wait { background: var(--status-info); box-shadow: 0 0 0 3px var(--status-info-bg); }
.status-node--off { background: var(--plant-ink-muted); box-shadow: 0 0 0 3px var(--plant-panel-muted); }
.status-copy { display: flex; align-items: center; gap: var(--space-2); color: var(--plant-ink-secondary); }

.state-panel, .empty-state { padding: var(--space-8); border: 1px solid var(--steel-border); border-radius: var(--radius-panel); background: var(--plant-panel); color: var(--plant-ink-secondary); text-align: center; }
.empty-state { min-height: 260px; display: grid; place-content: center; justify-items: center; gap: var(--space-2); }
.empty-state--embedded { min-height: 220px; border: 0; border-top: 1px solid var(--steel-border-soft); border-radius: 0; }
.empty-state__mark { width: 42px; height: 36px; display: grid; place-items: center; margin-bottom: var(--space-2); border: 1px solid var(--steel-border); border-radius: var(--radius-control); background: var(--plant-panel-muted); color: var(--plant-ink-tertiary); font-family: var(--font-display); font-size: var(--text-caption); font-weight: 700; }
.empty-state p { max-width: 480px; margin: 0; color: var(--plant-ink-tertiary); }

.table-wrap { width: 100%; overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; color: var(--plant-ink-secondary); }
.data-table th { padding: var(--space-3) var(--space-4); border-bottom: 1px solid var(--steel-border); background: var(--plant-panel-muted); color: var(--plant-ink-tertiary); font-size: var(--text-caption); font-weight: 700; letter-spacing: .06em; text-align: left; text-transform: uppercase; white-space: nowrap; }
.data-table td { min-height: 48px; padding: var(--space-3) var(--space-4); border-bottom: 1px solid var(--steel-border-soft); vertical-align: middle; }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover { background: color-mix(in srgb, var(--plant-panel-muted) 45%, transparent); }
.tabular { font-variant-numeric: tabular-nums; white-space: nowrap; }
.technical-value { max-width: 170px; overflow: hidden; text-overflow: ellipsis; color: var(--plant-ink-tertiary); font-family: ui-monospace, "Cascadia Mono", monospace; font-size: 12px; white-space: nowrap; }
.audit-metadata { max-width: 300px; color: var(--plant-ink-tertiary); font-family: ui-monospace, "Cascadia Mono", monospace; font-size: 12px; overflow-wrap: anywhere; }
.identity-cell { display: flex; align-items: center; gap: var(--space-3); min-width: 220px; }
.identity-cell__avatar { width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid var(--steel-border); border-radius: 50%; background: var(--plant-panel-muted); color: var(--plant-ink-secondary); font-family: var(--font-display); font-size: 11px; font-weight: 700; }
.identity-cell > span:last-child { display: grid; gap: 1px; }
.identity-cell strong { color: var(--plant-ink); font-weight: 650; }
.identity-cell small, .table-note { color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.table-note { display: block; margin-top: var(--space-1); }
.role-list { max-width: 240px; }
.row-actions { display: flex; justify-content: flex-end; gap: var(--space-1); }
.pagination { min-height: 60px; display: flex; align-items: center; justify-content: flex-end; gap: var(--space-3); padding: var(--space-3) var(--space-4); border-top: 1px solid var(--steel-border); color: var(--plant-ink-tertiary); font-size: var(--text-caption); }

.filter-bar { min-height: 64px; display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); margin-bottom: var(--space-4); padding: var(--space-3) var(--space-4); border: 1px solid var(--steel-border); border-radius: var(--radius-panel); background: var(--plant-panel); }
.filter-bar select { min-width: 220px; }
.filter-bar__count { color: var(--plant-ink-tertiary); font-size: var(--text-caption); font-variant-numeric: tabular-nums; }

.detail-list { display: grid; max-width: 760px; padding-block: 0; }
.detail-list > div { min-height: 60px; display: grid; grid-template-columns: 180px 1fr; align-items: center; gap: var(--space-4); border-top: 1px solid var(--steel-border-soft); }
.detail-list > div:first-child { border-top: 0; }
.detail-list span { color: var(--plant-ink-tertiary); }
.detail-list strong { display: flex; align-items: center; gap: var(--space-2); color: var(--plant-ink); font-weight: 650; }

.message-panel { width: min(100%, 560px); position: relative; z-index: 1; padding: var(--space-8); border: 1px solid var(--steel-border-strong); border-radius: var(--radius-dialog); background: var(--plant-panel); }
.message-panel__code { margin-bottom: var(--space-6); color: var(--plant-ink-muted); font-family: var(--font-display); font-size: 42px; font-weight: 700; line-height: 1; }
.message-panel h1 { margin: var(--space-1) 0 var(--space-3); }
.message-panel p { margin: 0 0 var(--space-6); color: var(--plant-ink-secondary); }

.admin-detail-grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: var(--space-6); align-items: start; }
.admin-detail-main, .admin-detail-aside { display: grid; gap: var(--space-5); }
.permission-list { max-height: 360px; overflow-y: auto; margin: var(--space-4) 0 0; padding: 0; list-style: none; }
.permission-list li { padding: var(--space-2) 0; border-top: 1px solid var(--steel-border-soft); color: var(--plant-ink-secondary); font-family: ui-monospace, "Cascadia Mono", monospace; font-size: 12px; }

.records-layout { display: grid; grid-template-columns: minmax(300px, 380px) minmax(0, 1fr); gap: var(--space-6); align-items: start; }
.record-form-panel form { display: grid; gap: var(--space-4); }
.records-table-panel { min-width: 0; }
.dashboard-metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: var(--space-3); margin-bottom: var(--space-5); }
.metric-card { display: grid; align-content: space-between; gap: var(--space-2); min-height: 132px; padding: var(--space-4); border: 1px solid var(--steel-border); border-top: 3px solid var(--pipe-green); border-radius: var(--radius-panel); background: var(--plant-panel); color: var(--plant-ink); text-decoration: none; }
.metric-card:hover { border-color: var(--steel-border-strong); background: color-mix(in srgb, var(--pipe-green-soft) 30%, var(--plant-panel)); color: var(--plant-ink); }
.metric-card span, .metric-card small { color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.metric-card strong { font-family: var(--font-display); font-size: 26px; line-height: 1.12; font-variant-numeric: tabular-nums; }
.metric-card .metric-card__text { font-size: var(--text-h3); line-height: 1.3; }
.metric-card.is-warning { border-top-color: var(--straw-warning); }
.metric-card.is-danger { border-top-color: var(--alarm-danger); }
.metric-card.is-calm { border-top-color: var(--flow-success); }
.system-strip { min-height: 52px; display: flex; align-items: center; gap: var(--space-3); margin-top: var(--space-6); padding: var(--space-3) var(--space-4); border-top: 1px solid var(--steel-border-soft); color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.system-strip strong { color: var(--plant-ink-secondary); }

/* Workforce planning: dense monthly control-room matrices. */
.workforce-heading { align-items: center; }
.month-toolbar { display: flex; align-items: center; gap: var(--space-2); padding: var(--space-2); border: 1px solid var(--steel-border); border-radius: var(--radius-panel); background: var(--plant-panel); }
.month-toolbar__step { width: 42px; height: 42px; display: grid; place-items: center; border: 1px solid var(--steel-border-soft); border-radius: var(--radius-control); background: var(--plant-inset); color: var(--pipe-green); font-size: 20px; cursor: pointer; }
.month-toolbar__step:hover { border-color: var(--steel-border-strong); background: var(--pipe-green-soft); }
.month-toolbar__current { min-width: 184px; display: grid; gap: 1px; padding-inline: var(--space-2); text-align: center; }
.month-toolbar__current span { color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.month-toolbar__current strong { font-family: var(--font-display); font-size: var(--text-h3); text-transform: capitalize; }

.schedule-heading { margin-bottom: var(--space-4); }
.schedule-commandbar { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: var(--space-4); margin-bottom: var(--space-4); padding: var(--space-3); border: 1px solid var(--steel-border); border-radius: var(--radius-panel); background: var(--plant-panel); }
.schedule-view-modes { display: inline-flex; padding: 3px; border: 1px solid var(--steel-border); border-radius: var(--radius-control); background: var(--plant-inset); }
.schedule-view-modes button { min-height: 44px; padding: var(--space-2) var(--space-4); border: 0; border-radius: 2px; background: transparent; color: var(--plant-ink-secondary); font-weight: 650; cursor: pointer; }
.schedule-view-modes button:hover { background: color-mix(in srgb, var(--pipe-green-soft) 48%, transparent); color: var(--plant-ink); }
.schedule-view-modes button.is-active { background: var(--plant-panel); color: var(--pipe-green-strong); box-shadow: inset 0 -3px 0 var(--pipe-green); }
.schedule-view-modes button:focus-visible, .period-step:focus-visible, .density-toggle:focus-within { position: relative; z-index: 2; outline: 0; box-shadow: 0 0 0 3px rgba(36, 92, 58, .22); }
.schedule-period-navigation { min-width: 0; display: grid; grid-template-columns: auto minmax(180px, 1fr) auto auto; align-items: center; gap: var(--space-2); }
.period-step { min-height: 44px; display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2); padding: var(--space-2) var(--space-3); border: 1px solid var(--steel-border-soft); border-radius: var(--radius-control); background: var(--plant-inset); color: var(--plant-ink-secondary); font-weight: 650; cursor: pointer; }
.period-step:hover { border-color: var(--steel-border-strong); background: var(--pipe-green-soft); color: var(--pipe-green-strong); }
.period-title { min-width: 0; color: var(--plant-ink); font-family: var(--font-display); font-size: var(--text-h3); font-variant-numeric: tabular-nums; text-align: center; text-transform: capitalize; }
.period-today { min-height: 44px; white-space: nowrap; }
.density-toggle { min-height: 44px; display: inline-flex; align-items: center; gap: var(--space-2); padding: 0 var(--space-3); border: 1px solid var(--steel-border-soft); border-radius: var(--radius-control); background: var(--plant-panel); color: var(--plant-ink-secondary); font-weight: 650; cursor: pointer; }
.density-toggle input { width: 20px; height: 20px; accent-color: var(--pipe-green); }
.schedule-evaluation-toggle { min-height: 44px; white-space: nowrap; }
.schedule-evaluation-toggle.is-active { border-color: var(--pipe-green); background: var(--pipe-green-soft); color: var(--pipe-green-strong); }

.matrix-legend { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-5); margin: calc(-1 * var(--space-2)) 0 var(--space-4); padding: var(--space-3) var(--space-4); border-block: 1px solid var(--steel-border-soft); color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.matrix-legend > span { display: inline-flex; align-items: center; gap: var(--space-2); }
.matrix-actions { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); margin: calc(-1 * var(--space-2)) 0 var(--space-4); }
.matrix-filter-group { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-5); }
.view-switch { display: inline-flex; padding: 3px; border: 1px solid var(--steel-border); border-radius: var(--radius-control); background: var(--plant-inset); }
.view-switch button { min-height: 36px; padding: var(--space-1) var(--space-3); border: 0; border-radius: 2px; background: transparent; color: var(--plant-ink-tertiary); font-size: var(--text-caption); font-weight: 650; cursor: pointer; }
.view-switch button.is-active { background: var(--plant-panel); color: var(--pipe-green-strong); box-shadow: inset 0 -2px 0 var(--pipe-green); }
.view-switch button:disabled { cursor: not-allowed; opacity: .52; }
.shift-mark { min-width: 24px; height: 24px; display: inline-grid; place-items: center; border: 1px solid color-mix(in srgb, var(--pipe-green) 34%, transparent); border-radius: 3px; background: var(--pipe-green-soft); color: var(--pipe-green-strong); font-family: var(--font-display); font-size: 12px; font-style: normal; font-weight: 700; line-height: 1; }
.absence-key, .conflict-key, .missing-key, .plan-key, .attendance-value, .holiday-key, .coverage-key { min-width: 28px; min-height: 24px; display: inline-grid; place-items: center; padding-inline: 5px; border: 1px solid; border-radius: 3px; font-family: var(--font-display); font-size: 10px; font-style: normal; font-weight: 700; line-height: 1; }
.holiday-key { border-color: color-mix(in srgb, var(--straw-warning) 50%, transparent); background: var(--straw-warning-bg); color: #6e4a10; }
.coverage-key { border-color: var(--steel-border); background: var(--plant-inset); color: var(--plant-ink-secondary); }
.absence-key--approved { border-color: color-mix(in srgb, var(--status-info) 34%, transparent); background: var(--status-info-bg); color: var(--status-info); }
.absence-key--pending { border-color: color-mix(in srgb, var(--straw-warning) 34%, transparent); background: var(--straw-warning-bg); color: var(--straw-warning); }
.conflict-key { border-color: var(--alarm-danger); background: var(--alarm-danger-bg); color: var(--alarm-danger); }
.missing-key { border-style: dashed; border-color: var(--steel-border-strong); background: var(--plant-inset); color: var(--plant-ink-muted); }
.plan-key { border-color: var(--steel-border); background: var(--plant-panel-muted); color: var(--plant-ink-secondary); }
.attendance-value { color: var(--plant-ink); font-size: 12px; font-variant-numeric: tabular-nums; }

.workforce-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--space-4); align-items: start; }
.workforce-layout:not(.has-inspector) .matrix-editor { display: none; }
.workforce-layout.has-inspector { grid-template-columns: minmax(0, 1fr) clamp(360px, 24vw, 420px); }
.matrix-panel { min-width: 0; overflow: hidden; border: 1px solid var(--steel-border); border-radius: var(--radius-panel); background: var(--plant-panel); }
.matrix-scroll { max-height: calc(100vh - 238px); overflow: auto; overscroll-behavior: contain; scrollbar-gutter: stable; }
.workforce-matrix { width: 100%; min-width: max-content; border-collapse: separate; border-spacing: 0; color: var(--plant-ink-secondary); }
.workforce-matrix th, .workforce-matrix td { border-right: 1px solid var(--steel-border-soft); border-bottom: 1px solid var(--steel-border-soft); }
.workforce-matrix tr > :last-child { border-right: 0; }
.workforce-matrix thead th { position: sticky; top: 0; z-index: 6; min-width: 148px; height: 76px; padding: 6px 10px; background: var(--plant-panel-muted); color: var(--plant-ink); text-align: left; vertical-align: middle; }
.workforce-matrix thead th > small { display: block; max-width: 164px; overflow: hidden; margin-top: 2px; color: var(--plant-ink-tertiary); font-weight: 400; }
.employee-summary { display: grid !important; gap: 1px; font-size: 11px; line-height: 1.2; white-space: normal !important; }
.employee-summary b { color: var(--plant-ink-secondary); font-weight: 700; }
.employee-column-name { display: block; max-width: 164px; overflow: hidden; font-family: var(--font-display); font-size: var(--text-label); font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.workforce-matrix .matrix-day-column { position: sticky; left: 0; z-index: 5; width: 196px; min-width: 196px; max-width: 196px; padding: 2px 8px; background: var(--plant-panel); }
.workforce-matrix thead .matrix-day-column { z-index: 8; background: var(--plant-panel-muted); color: var(--plant-ink-tertiary); font-size: var(--text-caption); letter-spacing: .06em; text-transform: uppercase; }
.workforce-matrix tbody .matrix-day-column { height: 40px; text-align: left; }
.day-heading { display: flex; align-items: center; gap: 5px; min-width: 0; line-height: 1; }
.day-number { display: inline-block; min-width: 26px; color: var(--plant-ink); font-family: var(--font-display); font-size: 16px; line-height: 1; font-variant-numeric: tabular-nums; }
.day-name { color: var(--plant-ink-tertiary); font-size: 11px; text-transform: uppercase; }
.day-note-indicator { display: inline; margin-left: 5px; color: var(--straw-warning); font-size: 11px; font-weight: 650; white-space: nowrap; }
.holiday-badge { padding: 1px 4px; border: 1px solid color-mix(in srgb, var(--straw-warning) 45%, transparent); border-radius: 3px; background: var(--straw-warning-bg); color: #765116; font-size: 11px; font-weight: 700; text-transform: none; }
.holiday-label, .coverage-label { display: block; max-width: 180px; overflow: hidden; margin-top: 1px; font-size: 11px; font-weight: 650; line-height: 1.2; text-overflow: ellipsis; white-space: nowrap; }
.holiday-label { color: #765116; }
.coverage-label { color: var(--plant-ink-tertiary); }
.coverage-label.is-low { color: var(--alarm-danger); }
.coverage-label.is-complete { color: var(--pipe-green-strong); }
.coverage-label.is-high { color: var(--status-info); }
.workforce-matrix tbody tr.is-weekend > th, .workforce-matrix tbody tr.is-weekend > td { background: color-mix(in srgb, var(--plant-panel-muted) 62%, var(--plant-panel)); }
.workforce-matrix tbody tr.is-weekend .matrix-cell-button { background: color-mix(in srgb, var(--plant-panel-muted) 48%, var(--plant-panel)); }
.workforce-matrix tbody tr.is-holiday > .matrix-day-column { box-shadow: inset 3px 0 0 var(--straw-warning); }
.workforce-matrix tbody tr.is-undercovered > .matrix-day-column { border-right-color: color-mix(in srgb, var(--alarm-danger) 45%, var(--steel-border-soft)); }
.schedule-matrix--employees .matrix-day-column { width: 180px; min-width: 180px; max-width: 180px; }
.schedule-matrix--employees thead th.is-weekend { background: var(--plant-panel-muted); }
.schedule-matrix--employees thead th.is-holiday { box-shadow: inset 0 3px 0 var(--straw-warning); }
.schedule-matrix--employees thead th.is-undercovered small:last-child { color: var(--alarm-danger); }
.schedule-matrix .matrix-day-column { width: 216px; min-width: 216px; max-width: 216px; }
.schedule-matrix .day-date { color: var(--plant-ink); font-family: var(--font-display); font-size: 16px; font-weight: 700; font-variant-numeric: tabular-nums; }
.schedule-matrix .day-name { min-width: 22px; font-size: 12px; font-weight: 700; }
.today-badge { padding: 2px 5px; border: 1px solid var(--pipe-green); border-radius: 3px; background: var(--pipe-green-soft); color: var(--pipe-green-strong); font-size: 11px; font-weight: 750; }
.coverage-block { display: grid; gap: 1px; margin-top: 4px; color: var(--plant-ink-secondary); font-size: 12px; font-weight: 650; line-height: 1.25; }
.coverage-block strong { color: var(--alarm-danger); font-weight: 750; }
.coverage-block.is-complete { color: var(--pipe-green-strong); }
.coverage-block.is-high { color: var(--status-info); }
.schedule-matrix tbody tr.is-today > .matrix-day-column { box-shadow: inset 4px 0 0 var(--pipe-green); }
.schedule-matrix tbody tr.is-today > td { border-top: 1px solid color-mix(in srgb, var(--pipe-green) 38%, transparent); border-bottom-color: color-mix(in srgb, var(--pipe-green) 38%, transparent); }
.schedule-matrix--week { font-size: 15px; }
.schedule-matrix--week thead th { height: 72px; min-width: 164px; }
.schedule-matrix--week tbody .matrix-day-column { height: 72px; padding: var(--space-2) var(--space-3); }
.schedule-matrix--week .matrix-cell { min-width: 164px; height: 72px; }
.schedule-matrix--week .matrix-cell-button { min-height: 71px; gap: var(--space-1); padding: var(--space-2) var(--space-3); }
.schedule-matrix--week .shift-mark { min-width: 30px; height: 30px; font-size: 14px; }
.schedule-matrix--week .absence-band { font-size: 12px; }
.schedule-matrix--week .absence-band strong { font-size: 12px; }
.schedule-matrix--month { font-size: 13px; }
.schedule-matrix--month .matrix-day-column { width: 196px; min-width: 196px; max-width: 196px; }
.schedule-matrix--month .coverage-block { font-size: 11px; }
.schedule-matrix--month .coverage-block strong { display: inline; }
.schedule-matrix--month.density-comfortable { font-size: 15px; }
.schedule-matrix--month.density-comfortable tbody .matrix-day-column, .schedule-matrix--month.density-comfortable .matrix-cell { height: 56px; }
.schedule-matrix--month.density-comfortable .matrix-cell-button { min-height: 55px; padding: var(--space-2); }
.schedule-matrix--week.density-comfortable { font-size: 16px; }
.schedule-matrix--week.density-comfortable thead th { min-width: 176px; height: 80px; }
.schedule-matrix--week.density-comfortable tbody .matrix-day-column, .schedule-matrix--week.density-comfortable .matrix-cell { height: 84px; }
.schedule-matrix--week.density-comfortable .matrix-cell-button { min-height: 83px; padding: var(--space-3); }
.schedule-matrix--week.density-comfortable .employee-column-name { font-size: 16px; }
.schedule-matrix--week.density-comfortable .note-indicator { font-size: 0; }
.schedule-matrix--week.density-comfortable .note-indicator::after { content: "Pozn."; font-size: 11px; }
.matrix-cell { min-width: 148px; height: 40px; padding: 0; vertical-align: stretch; }
.matrix-cell-button { width: 100%; min-height: 39px; display: grid; align-content: center; justify-items: start; gap: 2px; padding: 3px 8px; border: 0; background: var(--plant-panel); color: var(--plant-ink); text-align: left; cursor: pointer; transition: background-color 120ms ease-out, box-shadow 120ms ease-out; }
.matrix-cell-button:hover { background: color-mix(in srgb, var(--pipe-green-soft) 42%, var(--plant-panel)); }
.matrix-cell-button:focus-visible { position: relative; z-index: 4; outline: 0; box-shadow: inset 0 0 0 2px var(--pipe-green); }
.matrix-cell-button.is-selected { position: relative; z-index: 3; box-shadow: inset 0 0 0 2px var(--pipe-green); }
.matrix-cell-button.has-approved-absence { background: color-mix(in srgb, var(--status-info-bg) 72%, var(--plant-panel)); }
.matrix-cell-button.has-pending-absence { background: color-mix(in srgb, var(--straw-warning-bg) 62%, var(--plant-panel)); }
.matrix-cell.has-conflict { box-shadow: inset 3px 0 0 var(--alarm-danger); }
.shift-stack { display: flex; flex-wrap: wrap; gap: 3px; }
.absence-band { max-width: 100%; display: flex; align-items: center; gap: 5px; padding: 2px 5px; border-left: 2px solid; font-size: 10px; line-height: 1.2; }
.absence-band strong { font-family: var(--font-display); font-size: 10px; }
.absence-band small { overflow: hidden; color: inherit; text-overflow: ellipsis; white-space: nowrap; }
.absence-band--approved { border-color: var(--status-info); background: var(--status-info-bg); color: var(--status-info); }
.absence-band--pending { border-color: var(--straw-warning); background: var(--straw-warning-bg); color: #6e4a10; }
.cell-conflict { display: inline-flex; align-items: center; gap: 4px; color: var(--alarm-danger); font-size: 10px; font-weight: 650; }
.cell-conflict b { width: 16px; height: 16px; display: inline-grid; place-items: center; border: 1px solid var(--alarm-danger); border-radius: 50%; }
.cell-empty { color: var(--plant-ink-muted); font-family: var(--font-display); }
.note-indicator { display: inline-flex; align-items: center; gap: 3px; color: var(--status-info); font-size: 9px; font-weight: 700; }
.note-detail { margin-top: var(--space-3); border: 1px solid var(--steel-border-soft); border-radius: var(--radius-control); background: var(--plant-inset); }
.note-detail summary { padding: var(--space-3); color: var(--plant-ink-secondary); font-size: var(--text-caption); font-weight: 700; cursor: pointer; }
.note-detail > p, .note-detail__item { margin: 0; padding: 0 var(--space-3) var(--space-3); color: var(--plant-ink-secondary); font-size: var(--text-caption); }
.note-detail__item { display: grid; grid-template-columns: 1fr auto; gap: 2px var(--space-2); }
.note-detail__item p { grid-column: 1 / -1; margin: 0; white-space: pre-wrap; }

.matrix-editor { position: sticky; top: 88px; max-height: calc(100vh - 112px); overflow-y: auto; padding: var(--space-5); }
.matrix-editor .section-heading { margin-bottom: var(--space-4); }
.editor-close { width: 40px; height: 40px; display: grid; place-items: center; flex: 0 0 auto; border: 1px solid var(--steel-border-soft); border-radius: var(--radius-control); background: var(--plant-inset); color: var(--plant-ink-secondary); font-size: 20px; cursor: pointer; }
.editor-close:hover { border-color: var(--steel-border-strong); background: var(--plant-panel-muted); }
.editor-empty { min-height: 300px; display: grid; align-content: center; justify-items: center; gap: var(--space-2); text-align: center; }
.editor-empty h2 { margin-top: var(--space-3); }
.editor-empty p { max-width: 260px; margin: 0; color: var(--plant-ink-tertiary); }
.process-mini-line { position: relative; width: 96px; display: flex; justify-content: space-between; }
.process-mini-line::before { content: ""; position: absolute; top: 5px; right: 5px; left: 5px; height: 1px; background: var(--pipe-green); }
.process-mini-line i { position: relative; width: 11px; height: 11px; border: 2px solid var(--pipe-green); background: var(--plant-panel); }
.process-mini-line i:nth-child(2) { border-radius: 50%; background: var(--pipe-green-soft); }
.editor-section { display: grid; gap: var(--space-3); padding-top: var(--space-5); border-top: 1px solid var(--steel-border-soft); margin-top: var(--space-5); }
.editor-section h3 { font-size: var(--text-h3); }
.editor-absence-list { display: grid; gap: var(--space-2); }
.absence-summary { display: flex; justify-content: space-between; gap: var(--space-2); padding: var(--space-2) var(--space-3); border-left: 3px solid; font-size: var(--text-caption); }
.absence-summary.is-approved { border-color: var(--status-info); background: var(--status-info-bg); color: var(--status-info); }
.absence-summary.is-pending { border-color: var(--straw-warning); background: var(--straw-warning-bg); color: #6e4a10; }
.shift-choice-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-2); }
.shift-choice { min-height: 72px; display: grid; place-items: center; gap: 3px; padding: var(--space-2); border: 1px solid var(--steel-border); border-radius: var(--radius-control); background: var(--plant-inset); cursor: pointer; }
.shift-choice input { position: absolute; opacity: 0; pointer-events: none; }
.shift-choice > span:last-child { color: var(--plant-ink-tertiary); font-size: 10px; }
.shift-choice:has(input:checked) { border-color: var(--pipe-green); background: var(--pipe-green-soft); box-shadow: inset 0 -2px 0 var(--pipe-green); }
.shift-choice:focus-within { box-shadow: 0 0 0 3px rgba(36, 92, 58, .18); }

.attendance-cell { justify-items: center; text-align: center; }
.attendance-cell.is-missing { background: var(--plant-inset); box-shadow: inset 3px 0 0 color-mix(in srgb, var(--straw-warning) 58%, transparent); }
.attendance-cell.is-future, .attendance-cell.is-weekend-empty, .attendance-cell.is-holiday-empty { color: var(--plant-ink-muted); }
.attendance-cell.is-holiday-empty { box-shadow: inset 0 2px 0 var(--straw-warning); }
.attendance-cell.status-approved, .attendance-cell.status-locked { box-shadow: inset 0 -2px 0 var(--pipe-green); }
.attendance-cell.status-rejected { box-shadow: inset 3px 0 0 var(--alarm-danger); }
.worked-time { font-family: var(--font-display); font-size: 15px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.record-status, .missing-label, .empty-state-label { color: var(--plant-ink-tertiary); font-size: 11px; }
.missing-primary { color: #765116; font-size: 12px; }
.missing-label { color: var(--straw-warning); font-weight: 650; opacity: 0; transform: translateY(2px); transition: opacity 120ms ease-out, transform 120ms ease-out; }
.empty-state-label { opacity: 0; transition: opacity 120ms ease-out; }
.attendance-cell:hover .empty-state-label, .attendance-cell:focus-visible .empty-state-label { opacity: 1; }
.attendance-cell:hover .missing-label, .attendance-cell:focus-visible .missing-label, .attendance-cell.is-selected .missing-label { opacity: 1; transform: none; }
.editor-shortcuts { display: grid; gap: 2px; padding: 8px; border-left: 2px solid var(--steel-border-strong); background: var(--plant-inset); color: var(--plant-ink-tertiary); font-size: 11px; }
.button-row { display: flex; flex-wrap: wrap; gap: 6px; }
.absence-summary-strip { display: flex; align-items: center; gap: 8px; margin-bottom: var(--space-3); padding: 8px 10px; border: 1px solid var(--steel-border-soft); border-radius: var(--radius-control); background: var(--plant-panel); }
.absence-summary-strip > span { display: inline-flex; align-items: center; gap: 6px; color: var(--plant-ink-secondary); font-size: 12px; }
.absence-summary-strip > span b { min-width: 22px; height: 22px; display: inline-grid; place-items: center; border: 1px solid var(--steel-border-soft); border-radius: 3px; background: var(--plant-inset); color: var(--plant-ink); font-family: var(--font-display); }
.absence-summary-strip > span.is-pending b { border-color: color-mix(in srgb, var(--straw-warning) 42%, transparent); background: var(--straw-warning-bg); color: #765116; }
.absence-summary-strip > button { margin-left: auto; }
.context-absence-action { margin-top: var(--space-3); }
.drawer-layer { position: fixed; inset: 0; height: 100dvh; overflow: hidden; z-index: 100; display: grid; justify-items: end; }
.drawer-backdrop { position: absolute; inset: 0; width: 100%; border: 0; background: rgba(23, 49, 40, .28); cursor: default; }
.absence-drawer { position: relative; width: clamp(380px, 30vw, 440px); height: 100dvh; max-height: 100dvh; min-height: 0; overflow: hidden; display: grid; grid-template-rows: auto minmax(0, 1fr); border-left: 1px solid var(--steel-border); background: var(--plant-panel); box-shadow: -12px 0 30px rgba(23, 49, 40, .12); }
.drawer-header { display: flex; justify-content: space-between; gap: var(--space-3); padding: var(--space-5); border-bottom: 1px solid var(--steel-border-soft); }
.drawer-header h2 { margin-top: 2px; font-size: var(--text-h2); }
.drawer-header p { margin: 3px 0 0; color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.drawer-content { min-height: 0; overflow-y: auto; display: grid; align-content: start; gap: var(--space-4); padding: var(--space-5); }
.drawer-workflow { display: grid; gap: 2px; padding: 10px 12px; border-left: 2px solid var(--pipe-green); background: var(--pipe-green-soft); font-size: 11px; }
.drawer-workflow span { color: var(--plant-ink-tertiary); text-transform: uppercase; letter-spacing: .06em; }
.drawer-actions { position: sticky; bottom: -20px; display: grid; gap: 8px; margin: 4px -20px -20px; padding: 16px 20px 20px; border-top: 1px solid var(--steel-border-soft); background: var(--plant-panel); }
.absence-filters { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-3); }
.absence-filters .field:last-child { grid-column: 1 / -1; }
.absence-drawer-list { display: grid; gap: 8px; }
.absence-drawer-list article { display: grid; gap: 4px; padding: 12px; border: 1px solid var(--steel-border-soft); border-radius: var(--radius-control); background: var(--plant-inset); }
.absence-drawer-list article > div:first-child { display: flex; align-items: center; gap: 8px; }
.absence-drawer-list p { margin: 0; color: var(--plant-ink-secondary); font-size: 12px; }
.absence-drawer-list small { color: var(--plant-ink-tertiary); }
body.has-drawer { overflow: hidden; }
.impersonation-dialog-layer { position: fixed; inset: 0; z-index: 110; display: grid; place-items: center; padding: var(--space-4); }
.impersonation-dialog-backdrop { position: absolute; inset: 0; width: 100%; border: 0; background: rgba(23, 32, 27, .34); cursor: default; }
.impersonation-dialog { position: relative; width: min(100%, 520px); max-height: calc(100dvh - 32px); overflow-y: auto; display: grid; gap: var(--space-5); padding: var(--space-6); border: 1px solid var(--steel-border-strong); border-radius: var(--radius-dialog); background: var(--plant-panel); }
.impersonation-dialog h2 { margin-top: var(--space-1); }
.impersonation-dialog p { margin: var(--space-2) 0 0; color: var(--plant-ink-secondary); }
.impersonation-dialog__mark { position: relative; width: 72px; display: flex; justify-content: space-between; }
.impersonation-dialog__mark::before { content: ""; position: absolute; top: 6px; right: 6px; left: 6px; height: 2px; background: var(--status-info); }
.impersonation-dialog__mark i { position: relative; width: 13px; height: 13px; border: 2px solid var(--status-info); background: var(--plant-panel); }
.impersonation-dialog__mark i:nth-child(2) { border-radius: 50%; background: var(--status-info-bg); }
.impersonation-dialog__identity { margin: 0; border-block: 1px solid var(--steel-border-soft); }
.impersonation-dialog__identity > div { min-height: 44px; display: grid; grid-template-columns: 96px minmax(0, 1fr); align-items: center; gap: var(--space-3); padding: var(--space-2) 0; border-top: 1px solid var(--steel-border-soft); }
.impersonation-dialog__identity > div:first-child { border-top: 0; }
.impersonation-dialog__identity dt { color: var(--plant-ink-tertiary); font-size: var(--text-caption); font-weight: 650; }
.impersonation-dialog__identity dd { min-width: 0; margin: 0; overflow-wrap: anywhere; color: var(--plant-ink); font-weight: 650; }
.impersonation-dialog__actions { display: flex; flex-wrap: wrap; gap: var(--space-3); }
.destructive-dialog { border-top: 4px solid var(--alarm-danger); }
.destructive-dialog__mark { width: 44px; height: 44px; display: grid; place-items: center; border: 2px solid var(--alarm-danger); border-radius: 50%; background: var(--alarm-danger-bg); color: var(--alarm-danger); font-family: var(--font-display); font-size: var(--text-h2); font-weight: 750; }
.employee-create-drawer { width: clamp(400px, 32vw, 440px); }
.account-create-toggle { min-height: 44px; padding: var(--space-3); border: 1px solid var(--steel-border); border-radius: var(--radius-control); background: var(--pipe-green-soft); }
.employee-create-panel { margin-bottom: var(--space-4); }
.employee-admin-list { display: grid; }
.employee-admin-row { display: grid; grid-template-columns: 1fr 1fr minmax(240px, 1.2fr) auto auto; align-items: end; gap: 12px; padding: 12px 16px; border-top: 1px solid var(--steel-border-soft); }
.workforce-matrix tfoot th, .workforce-matrix tfoot td { position: sticky; bottom: 0; z-index: 5; height: 62px; padding: var(--space-2); border-top: 1px solid var(--steel-border-strong); background: var(--plant-panel-muted); }
.workforce-matrix tfoot .matrix-day-column { z-index: 7; }
.month-total { display: grid; gap: 1px; }
.month-total strong { color: var(--plant-ink); font-family: var(--font-display); font-size: 17px; font-variant-numeric: tabular-nums; }
.month-total span, .month-total small { color: var(--plant-ink-tertiary); font-size: 10px; }
.duration-fields { display: grid; grid-template-columns: 1fr 12px 1fr; align-items: end; gap: var(--space-2); }
.duration-fields > span { padding-bottom: 12px; color: var(--plant-ink-tertiary); font-family: var(--font-display); font-size: 20px; }
.plan-suggestion { width: 100%; display: grid; grid-template-columns: 1fr auto; gap: 2px var(--space-2); padding: var(--space-3); border: 1px solid color-mix(in srgb, var(--status-info) 28%, transparent); border-radius: var(--radius-control); background: var(--status-info-bg); color: var(--status-info); text-align: left; cursor: pointer; }
.plan-suggestion span { font-size: var(--text-caption); }
.plan-suggestion strong { grid-row: 1 / 3; grid-column: 2; align-self: center; font-family: var(--font-display); font-size: 20px; }
.plan-suggestion small { font-weight: 650; }

.absence-workbench { display: grid; grid-template-columns: minmax(340px, .9fr) minmax(0, 1.1fr); gap: var(--space-4); margin-top: var(--space-6); align-items: start; }
.absence-form { display: grid; gap: var(--space-4); }
.absence-rows { display: grid; }
.absence-row { min-height: 68px; display: grid; grid-template-columns: auto minmax(160px, 1fr) auto auto; align-items: center; gap: var(--space-3); padding: var(--space-3) var(--space-4); border-top: 1px solid var(--steel-border-soft); }
.absence-row > span:nth-child(2) { display: grid; gap: 2px; }
.absence-row small { color: var(--plant-ink-tertiary); }
.absence-row__status { color: var(--plant-ink-secondary); font-size: var(--text-caption); font-weight: 650; }

.report-toolbar { display: flex; align-items: end; gap: var(--space-4); margin-bottom: var(--space-4); padding: var(--space-4); }
.report-toolbar .field { min-width: 190px; }
.export-dialog { position: relative; margin-left: auto; }
.export-dialog summary { list-style: none; cursor: pointer; }
.export-dialog > div { position: absolute; z-index: 20; right: 0; width: 260px; display: grid; gap: var(--space-2); margin-top: var(--space-2); padding: var(--space-4); border: 1px solid var(--steel-border-strong); border-radius: var(--radius-panel); background: var(--plant-panel); }
.export-dialog span { color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.export-dialog a { padding: var(--space-2); border-top: 1px solid var(--steel-border-soft); color: var(--pipe-green); font-weight: 700; }
.report-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-3); margin-bottom: var(--space-4); }
.report-kpis > div { min-height: 112px; display: grid; align-content: center; gap: 3px; padding: var(--space-4); border: 1px solid var(--steel-border); border-top: 3px solid var(--pipe-green); border-radius: var(--radius-panel); background: var(--plant-panel); }
.report-kpis span, .report-kpis small { color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.report-kpis strong { font-family: var(--font-display); font-size: 26px; font-variant-numeric: tabular-nums; }
.report-kpis .is-negative { border-top-color: var(--straw-warning); }
.report-kpis .is-negative strong, .report-table .is-negative { color: var(--alarm-danger); }
.report-chart { min-height: 360px; display: grid; align-content: start; gap: var(--space-4); margin-bottom: var(--space-4); padding: var(--space-6); }
.chart-legend { display: flex; gap: var(--space-4); color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.chart-legend span { display: flex; align-items: center; gap: var(--space-2); }
.chart-swatch { width: 20px; height: 7px; background: var(--pipe-green); }
.chart-swatch--actual { background: var(--status-info); }
.bar-row { display: grid; grid-template-columns: minmax(160px, 220px) minmax(260px, 1fr) 150px; align-items: center; gap: var(--space-4); min-height: 58px; }
.bar-row > strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar-row > span { color: var(--plant-ink-tertiary); font-size: var(--text-caption); font-variant-numeric: tabular-nums; }
.bar-track { position: relative; height: 42px; border-left: 1px solid var(--steel-border-strong); background: repeating-linear-gradient(90deg, transparent 0, transparent 24.8%, var(--steel-border-soft) 25%); }
.bar { position: absolute; left: 0; height: 15px; min-width: 2px; }
.bar--plan { top: 3px; background: var(--pipe-green); }
.bar--actual { bottom: 3px; background: var(--status-info); }
.report-table-panel { overflow: hidden; }
.numeric-cell { text-align: right !important; font-variant-numeric: tabular-nums; white-space: nowrap; }
.record-type { display: inline-flex; min-height: 28px; align-items: center; padding: 2px var(--space-2); border-left: 2px solid var(--pipe-green); background: var(--pipe-green-soft); color: var(--pipe-green-strong); font-size: var(--text-caption); font-weight: 650; }

.blazor-error-boundary { padding: var(--space-4); border: 1px solid var(--alarm-danger); border-radius: var(--radius-control); background: var(--alarm-danger-bg); color: var(--alarm-danger); }
.darker-border-checkbox.form-check-input { border-color: var(--steel-border-strong); }

/* Development work reports: account-based time ledger, separate from workforce coverage. */
.development-toolbar { display: flex; align-items: end; flex-wrap: wrap; gap: var(--space-3); margin-bottom: var(--space-4); padding: var(--space-3) var(--space-4); }
.development-toolbar .field { min-width: 190px; flex: 1 1 190px; }
.development-add { min-height: 44px; margin-left: auto; }
.development-hero { display: grid; grid-template-columns: minmax(260px, .42fr) minmax(0, 1.58fr); gap: var(--space-4); margin-bottom: var(--space-4); }
.development-month-total, .annual-capacity { border: 1px solid var(--steel-border); border-radius: var(--radius-panel); background: var(--plant-panel); }
.development-month-total { display: grid; align-content: space-between; gap: var(--space-3); padding: var(--space-5); border-top: 3px solid var(--pipe-green); }
.development-month-total > span { color: var(--plant-ink-tertiary); font-size: var(--text-caption); font-weight: 650; }
.development-month-total > strong { font-family: var(--font-display); font-size: 30px; font-variant-numeric: tabular-nums; }
.development-month-total > div { display: flex; flex-wrap: wrap; gap: var(--space-4); color: var(--plant-ink-secondary); }
.development-month-total b, .annual-capacity b { color: var(--plant-ink); font-variant-numeric: tabular-nums; }
.annual-capacity { display: grid; gap: var(--space-4); padding: var(--space-5); border-left: 4px solid var(--flow-success); }
.annual-capacity.is-warning { border-left-color: var(--straw-warning); }
.annual-capacity.is-danger, .annual-capacity.is-exhausted { border-left-color: var(--alarm-danger); }
.annual-capacity__heading { display: flex; justify-content: space-between; gap: var(--space-4); }
.annual-capacity__heading > div { display: grid; gap: 2px; }
.annual-capacity__heading span { color: var(--plant-ink-tertiary); }
.annual-capacity__heading strong { font-family: var(--font-display); font-size: var(--text-h2); font-variant-numeric: tabular-nums; }
.annual-capacity progress { width: 100%; height: 16px; overflow: hidden; border: 0; border-radius: 3px; background: var(--plant-inset); accent-color: var(--pipe-green); }
.annual-capacity.is-warning progress { accent-color: var(--straw-warning); }
.annual-capacity.is-danger progress, .annual-capacity.is-exhausted progress { accent-color: var(--alarm-danger); }
.annual-capacity progress::-webkit-progress-bar { background: var(--plant-inset); }
.annual-capacity progress::-webkit-progress-value { background: currentColor; }
.annual-capacity__values { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-3); color: var(--plant-ink-secondary); }
.development-chart-grid { display: grid; grid-template-columns: .72fr 1.28fr; gap: var(--space-4); margin-bottom: var(--space-4); }
.development-chart-grid .panel { padding: var(--space-5); }
.split-bars { min-height: 48px; display: flex; overflow: hidden; margin: var(--space-4) 0; border: 1px solid var(--steel-border); border-radius: var(--radius-control); background: var(--plant-inset); }
.split-bars > div { min-width: 0; display: grid; place-items: center; color: white; font-weight: 750; }
.split-bars__excel { background: var(--pipe-green); }
.split-bars__web { background: var(--status-info); }
.development-swatch--excel { background: var(--pipe-green); }.development-swatch--web { background: var(--status-info); }
.project-bar-row { display: grid; grid-template-columns: minmax(130px, .55fr) minmax(160px, 1fr) 86px; align-items: center; gap: var(--space-3); min-height: 40px; }
.project-bar-row > strong { overflow: hidden; color: var(--plant-ink-secondary); font-size: var(--text-caption); text-overflow: ellipsis; white-space: nowrap; }
.project-bar-row > span { text-align: right; font-variant-numeric: tabular-nums; }
.project-bar-track { height: 18px; display: flex; overflow: hidden; background: var(--plant-inset); }
.project-bar-excel { background: var(--pipe-green); }.project-bar-web { background: var(--status-info); }
.development-table-panel { margin-bottom: var(--space-4); }
.development-summary-inline { display: flex; flex-wrap: wrap; gap: var(--space-4); color: var(--plant-ink-secondary); font-size: var(--text-caption); }
.development-table td { min-width: 88px; }.development-table td:nth-last-child(3) { min-width: 180px; }
.status-node { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.status-node::before { content: ""; width: 8px; height: 8px; border: 2px solid currentColor; border-radius: 50%; }
.status-draft { color: var(--plant-ink-tertiary); }.status-submitted { color: var(--straw-warning); }.status-approved,.status-locked { color: var(--flow-success); }.status-rejected { color: var(--alarm-danger); }
.development-export-row { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: var(--space-2); padding: var(--space-3) 0; }
.development-export-row > span { margin-right: auto; color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.work-entry-drawer { width: clamp(400px, 32vw, 460px); }
.development-settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); margin-bottom: var(--space-4); }
.development-settings-grid .panel { display: grid; align-content: start; gap: var(--space-3); }
.development-admin-list { margin-bottom: var(--space-4); }
.development-admin-row { display: grid; grid-template-columns: minmax(220px,1fr) 180px auto auto; align-items: end; gap: var(--space-3); padding: var(--space-3) var(--space-4); border-top: 1px solid var(--steel-border-soft); }
.development-admin-row > div:first-child { display: grid; }.development-admin-row small { color: var(--plant-ink-tertiary); }
.development-project-admin-row { display: grid; grid-template-columns: 140px minmax(220px,1fr) 160px auto auto; align-items: end; gap: var(--space-3); padding: var(--space-3) var(--space-4); border-top: 1px solid var(--steel-border-soft); }
.stage-viewbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: var(--space-3); margin-bottom: var(--space-3); }
.stage-commandbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: var(--space-3); margin-bottom: var(--space-3); padding: var(--space-2); }
.stage-project-switch { display: inline-flex; flex-wrap: wrap; gap: var(--space-1); padding: var(--space-1); border: 1px solid var(--steel-border); border-radius: var(--radius-panel); background: var(--plant-inset); }
.stage-project-switch button { min-width: 96px; min-height: 44px; padding: 0 var(--space-4); border: 0; border-radius: var(--radius-control); background: transparent; color: var(--plant-ink-secondary); font-weight: 700; }
.stage-project-switch button:hover { background: var(--plant-panel); color: var(--plant-ink); }.stage-project-switch button.is-active { background: var(--pipe-green); color: white; }.stage-project-switch button:focus-visible { box-shadow: var(--focus-ring); }
.stage-roadmap-block { margin-bottom: var(--space-6); }.stage-roadmap-heading { display: flex; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; gap: var(--space-4); margin-bottom: var(--space-3); }.stage-roadmap-heading p { margin: var(--space-1) 0 0; color: var(--plant-ink-tertiary); }.stage-roadmap-actions { display: flex; align-items: center; flex-wrap: wrap; gap: var(--space-2); }
.stage-viewbar p { display: flex; align-items: center; gap: var(--space-2); margin: 0; color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.process-node { width: 10px; height: 10px; border: 2px solid var(--pipe-green); border-radius: 50%; background: var(--plant-panel); }
.stage-roadmap { overflow: hidden; border: 1px solid var(--steel-border); border-radius: var(--radius-panel); background: var(--plant-panel); }
.stage-roadmap > header { display: flex; align-items: flex-end; justify-content: space-between; gap: var(--space-3); padding: var(--space-4) var(--space-5); border-bottom: 1px solid var(--steel-border-soft); }
.stage-roadmap > header > span { color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.stage-roadmap__scroll { overflow-x: auto; padding: var(--space-6) var(--space-5) var(--space-5); outline: none; scrollbar-color: var(--steel-border-strong) var(--plant-inset); }
.stage-roadmap__scroll:focus-visible { box-shadow: inset 0 0 0 3px rgba(36, 92, 58, .22); }
.stage-timeline { display: flex; align-items: flex-start; min-width: max-content; margin: 0; padding: 0; list-style: none; }
.stage-point { position: relative; width: 284px; padding-right: var(--space-4); }
.stage-point__rail { position: relative; display: flex; align-items: center; height: 40px; margin-bottom: var(--space-3); }
.stage-point__rail::after { content: ""; position: absolute; left: 40px; right: 0; top: 19px; height: 2px; background: var(--steel-border-strong); }
.stage-point__rail > span { position: relative; z-index: 1; display: grid; place-items: center; width: 40px; height: 40px; border: 2px solid var(--plant-ink-tertiary); border-radius: 50%; background: var(--plant-panel); color: var(--plant-ink); font-family: var(--font-display); font-weight: 700; font-variant-numeric: tabular-nums; }
.stage-point > article { display: grid; align-content: start; gap: var(--space-3); min-height: 276px; padding: var(--space-4); border: 1px solid var(--steel-border); border-radius: var(--radius-panel); background: var(--plant-panel); }
.stage-point > article > header, .stage-point > article > footer, .stage-detail-actions { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: var(--space-2); }
.stage-point__identity { display: flex; align-items: center; gap: var(--space-2); }.stage-drag-handle { display: grid; place-items: center; width: 40px; height: 40px; border: 1px solid var(--steel-border); border-radius: var(--radius-control); background: var(--plant-inset); color: var(--plant-ink-tertiary); font-size: 22px; cursor: grab; }.stage-drag-handle:hover { border-color: var(--pipe-green); color: var(--pipe-green); }.stage-drag-handle:active { cursor: grabbing; }.stage-drag-handle:focus-visible { box-shadow: var(--focus-ring); }
.stage-point h3 { min-height: 42px; font-size: var(--text-h3); line-height: 1.25; text-wrap: balance; }.stage-point h3 a { color: var(--plant-ink); text-decoration: none; }.stage-point h3 a:hover { color: var(--pipe-green); text-decoration: underline; }
.stage-point__meta { display: grid; gap: var(--space-2); color: var(--plant-ink-secondary); font-size: var(--text-caption); }.stage-point__meta span { display: flex; align-items: center; min-height: 24px; padding-left: var(--space-2); border-left: 2px solid var(--steel-border-strong); }
.stage-point__facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-2) var(--space-3); margin: 0; }.stage-point__facts div { min-width: 0; }.stage-point__facts dt { color: var(--plant-ink-tertiary); font-size: 11px; font-weight: 600; }.stage-point__facts dd { margin: 2px 0 0; overflow-wrap: anywhere; color: var(--plant-ink); font-size: var(--text-caption); font-weight: 650; font-variant-numeric: tabular-nums; }
.stage-artifact-summary { margin: 0; padding: var(--space-2); border-left: 2px solid var(--status-info); background: var(--status-info-bg); color: var(--status-info); font-size: var(--text-caption); font-weight: 650; }
.stage-point__warning { display: flex; align-items: center; gap: var(--space-2); margin: 0; color: var(--straw-warning); font-size: var(--text-caption); font-weight: 650; }.stage-point__warning strong { display: grid; place-items: center; width: 20px; height: 20px; border: 1px solid currentColor; border-radius: 50%; }
.stage-point > article > footer { margin-top: auto; padding-top: var(--space-2); border-top: 1px solid var(--steel-border-soft); }
.stage-action-trigger { display: grid; place-items: center; width: 44px; height: 40px; margin-left: auto; border: 1px solid var(--steel-border); border-radius: var(--radius-control); background: var(--plant-panel); color: var(--plant-ink); font-weight: 800; letter-spacing: .08em; cursor: pointer; }
.stage-action-trigger:hover { background: var(--plant-inset); }.stage-action-trigger:focus-visible { box-shadow: var(--focus-ring); }
.stage-action-menu { position: relative; margin-left: auto; }.stage-action-menu > summary { display: grid; place-items: center; width: 44px; height: 40px; border: 1px solid var(--steel-border); border-radius: var(--radius-control); background: var(--plant-panel); color: var(--plant-ink); font-weight: 800; letter-spacing: .08em; cursor: pointer; list-style: none; }.stage-action-menu > summary::-webkit-details-marker { display: none; }.stage-action-menu > summary:hover { background: var(--plant-inset); }.stage-action-menu > summary:focus-visible { box-shadow: var(--focus-ring); }.stage-action-menu[open] > summary { border-color: var(--pipe-green); background: var(--pipe-green-soft); color: var(--pipe-green-strong); }
.stage-action-menu > div { position: absolute; z-index: 20; right: 0; bottom: calc(100% + 6px); display: grid; min-width: 210px; padding: var(--space-1); border: 1px solid var(--steel-border-strong); border-radius: var(--radius-panel); background: var(--plant-panel); }.stage-table .stage-action-menu > div { top: calc(100% + 6px); bottom: auto; }.stage-action-menu button { min-height: 40px; padding: 0 var(--space-3); border: 0; border-radius: var(--radius-control); background: transparent; color: var(--plant-ink); text-align: left; }.stage-action-menu button:hover { background: var(--plant-inset); }.stage-action-menu button:disabled { color: var(--plant-ink-muted); }.stage-action-menu__danger { margin-top: var(--space-1); padding-top: var(--space-1); border-top: 1px solid var(--steel-border-soft); }.stage-action-menu__danger button { width: 100%; color: var(--alarm-danger); }
.stage-point .stage-action-menu[open] { width: 100%; }.stage-point .stage-action-menu > div { position: static; min-width: 0; margin-top: var(--space-1); border-color: var(--steel-border); background: var(--plant-inset); }.stage-point .stage-action-menu > summary { margin-left: auto; }
.stage-point[draggable="true"] > article { cursor: grab; }.stage-point[draggable="true"]:active > article { cursor: grabbing; }
.stage-point--inprogress .stage-point__rail > span { border-color: var(--pipe-green); background: var(--pipe-green-soft); color: var(--pipe-green-strong); }
.stage-point--completed .stage-point__rail > span { border-color: var(--flow-success); background: var(--flow-success-bg); color: var(--flow-success); }
.stage-point--onhold .stage-point__rail > span { border-color: var(--straw-warning); background: var(--straw-warning-bg); color: var(--straw-warning); }
.stage-point--cancelled { opacity: .68; }.stage-point--cancelled h3 { text-decoration: line-through; }.stage-point.is-archived > article { background: color-mix(in srgb, var(--plant-panel-muted) 48%, var(--plant-panel)); }
.stage-point--add { width: 220px; }.stage-point--add .stage-point__rail::after { display: none; }.stage-point--add button { display: grid; width: 100%; min-height: 116px; place-content: center; gap: var(--space-1); border: 1px dashed var(--steel-border-strong); border-radius: var(--radius-panel); background: var(--plant-inset); color: var(--pipe-green-strong); text-align: center; }.stage-point--add button:hover { border-color: var(--pipe-green); background: var(--pipe-green-soft); }.stage-point--add small { color: var(--plant-ink-tertiary); }
.stage-code { color: var(--plant-ink-tertiary); font-family: var(--font-display); font-size: var(--text-caption); font-weight: 700; letter-spacing: .08em; }
.stage-status-badge { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-1); min-width: 108px; min-height: 32px; padding: var(--space-1) var(--space-2); border: 1px solid currentColor; border-radius: var(--radius-control); font-size: var(--text-caption); font-weight: 700; line-height: 1.2; white-space: nowrap; }
.stage-status-badge > span { width: 16px; text-align: center; font-size: 13px; }
.stage-hours { display: grid; grid-template-columns: repeat(3, 1fr); border-block: 1px solid var(--steel-border-soft); }
.stage-hours span { display: grid; gap: var(--space-1); padding: var(--space-3); border-left: 1px solid var(--steel-border-soft); }.stage-hours span:first-child { border-left: 0; }
.stage-hours small, .stage-summary-grid span, .stage-summary-grid small { color: var(--plant-ink-tertiary); font-size: var(--text-caption); }.stage-hours strong, .stage-summary-grid strong { font-family: var(--font-display); font-size: var(--text-h3); font-variant-numeric: tabular-nums; }
.stage-facts, .stage-detail-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-3); }.stage-facts div, .stage-detail-facts div { min-width: 0; }.stage-facts dt, .stage-detail-facts dt { color: var(--plant-ink-tertiary); font-size: var(--text-caption); }.stage-facts dd, .stage-detail-facts dd { margin: var(--space-1) 0 0; color: var(--plant-ink); font-weight: 600; overflow-wrap: anywhere; }
.stage-warning { display: flex; align-items: center; gap: var(--space-2); padding: var(--space-2) var(--space-3); background: var(--straw-warning-bg); color: var(--straw-warning); font-size: var(--text-caption); font-weight: 650; }.stage-warning span { display: grid; place-items: center; width: 20px; height: 20px; border: 1px solid currentColor; border-radius: 50%; }
.stage-archive-label { color: var(--plant-ink-tertiary); font-size: var(--text-caption); font-weight: 650; }.stage-archive-toggle { min-height: 42px; margin-bottom: 1px; }
.stage-status-inprogress { color: var(--flow-success); background: var(--flow-success-bg); }.stage-status-planned { color: var(--status-info); background: var(--status-info-bg); }.stage-status-completed { color: var(--pipe-green); background: var(--pipe-green-soft); }.stage-status-onhold { color: var(--straw-warning); background: var(--straw-warning-bg); }.stage-status-cancelled { color: var(--alarm-danger); background: var(--alarm-danger-bg); }
.stage-table-panel { margin-top: var(--space-3); }.stage-table { min-width: 1180px; }.stage-table td { vertical-align: middle; }.stage-table .stage-status-badge { min-width: 116px; }
.stage-editor-drawer { width: min(440px, 100vw); }.stage-project-picker { display: grid; gap: var(--space-2); padding: var(--space-3); border: 1px solid var(--steel-border); border-radius: var(--radius-control); }.stage-project-picker legend { padding: 0 var(--space-1); font-weight: 650; }
.stage-modal-layer { position: fixed; inset: 0; z-index: 120; display: grid; place-items: center; padding: var(--space-4); }
.stage-modal-backdrop { position: absolute; inset: 0; width: 100%; border: 0; background: rgba(23, 32, 27, .38); cursor: default; }
.stage-modal { position: relative; width: min(100%, 560px); max-height: calc(100dvh - 32px); overflow: hidden; display: grid; grid-template-rows: auto minmax(0, 1fr) auto; border: 1px solid var(--steel-border-strong); border-radius: var(--radius-dialog); background: var(--plant-panel); box-shadow: 0 18px 48px rgba(23, 49, 40, .18); animation: stage-modal-in 180ms cubic-bezier(.23,1,.32,1); }
.stage-editor-modal { width: min(100%, 720px); }.stage-modal__header { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--space-4); padding: var(--space-5); border-bottom: 1px solid var(--steel-border-soft); }.stage-modal__header h2 { margin-top: var(--space-1); }.stage-modal__header p { margin: var(--space-1) 0 0; color: var(--plant-ink-secondary); }
.stage-modal__body { min-height: 0; overflow-y: auto; display: grid; align-content: start; gap: var(--space-4); padding: var(--space-5); }.stage-modal__actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: var(--space-3); padding: var(--space-4) var(--space-5); border-top: 1px solid var(--steel-border-soft); background: var(--plant-panel); }
.stage-action-dialog { width: min(100%, 520px); }.stage-action-dialog__list { min-height: 0; overflow-y: auto; display: grid; gap: var(--space-2); padding: var(--space-4); }.stage-action-dialog__list button { min-height: 60px; display: grid; gap: 2px; align-content: center; padding: var(--space-3); border: 1px solid transparent; border-radius: var(--radius-control); background: var(--plant-inset); color: var(--plant-ink); text-align: left; cursor: pointer; }.stage-action-dialog__list button:hover { border-color: var(--steel-border-strong); background: var(--plant-panel-muted); }.stage-action-dialog__list button:focus-visible { box-shadow: var(--focus-ring); }.stage-action-dialog__list button:disabled { cursor: not-allowed; opacity: .48; }.stage-action-dialog__list span { color: var(--plant-ink-tertiary); font-size: var(--text-caption); }.stage-action-dialog__list .is-danger { background: var(--alarm-danger-bg); color: var(--alarm-danger); }.stage-action-dialog__list .is-danger span { color: currentColor; opacity: .78; }
.stage-confirm-dialog { grid-template-rows: auto; gap: var(--space-4); padding: var(--space-6); }.stage-confirm-dialog h2 { text-wrap: balance; }.stage-confirm-dialog p { margin: 0; color: var(--plant-ink-secondary); text-wrap: pretty; }.stage-confirm-dialog .stage-modal__actions { justify-content: flex-start; padding: var(--space-4) 0 0; }
.stage-modal-form { min-height: 0; display: grid; grid-template-rows: minmax(0, 1fr) auto; overflow: hidden; }
.development-settings-row { min-height: 72px; display: grid; grid-template-columns: minmax(240px, 1fr) auto minmax(110px, auto) auto; align-items: center; gap: var(--space-4); padding: var(--space-3) var(--space-4); border-top: 1px solid var(--steel-border-soft); }.development-settings-row > div:first-child { min-width: 0; display: grid; gap: 2px; }.development-settings-row small { color: var(--plant-ink-tertiary); overflow-wrap: anywhere; }.status-label { display: inline-flex; align-items: center; min-height: 30px; padding: var(--space-1) var(--space-2); border: 1px solid currentColor; border-radius: var(--radius-control); font-size: var(--text-caption); font-weight: 700; }.status-label--active { color: var(--flow-success); background: var(--flow-success-bg); }.status-label--inactive { color: var(--plant-ink-tertiary); background: var(--plant-inset); }
.dashboard-layout--single { grid-template-columns: minmax(0, 1fr); }.system-status-panel { padding: var(--space-5); }.system-status-panel .check-list { max-width: 720px; }
@keyframes stage-modal-in { from { opacity: 0; transform: translateY(8px) scale(.98); } to { opacity: 1; transform: translateY(0) scale(1); } }
.stage-detail-workspace { scroll-behavior: smooth; }.stage-detail-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--space-5); margin-bottom: var(--space-4); }.stage-detail-heading h1 { margin-top: var(--space-2); }.stage-detail-heading p { max-width: 720px; color: var(--plant-ink-secondary); }.back-link { display: inline-block; margin-bottom: var(--space-3); color: var(--plant-ink-secondary); }
.stage-detail-actions { justify-content: flex-end; align-items: center; max-width: 520px; }.stage-section-nav { position: sticky; top: 64px; z-index: 4; display: flex; flex-wrap: wrap; gap: var(--space-1); margin-bottom: var(--space-4); padding: var(--space-2); border: 1px solid var(--steel-border); background: var(--plant-panel); }.stage-section-nav a { min-height: 40px; display: inline-flex; align-items: center; padding: 0 var(--space-3); color: var(--plant-ink-secondary); text-decoration: none; }.stage-section-nav a:hover { background: var(--pipe-green-soft); color: var(--pipe-green-strong); }
.stage-detail-section { margin-bottom: var(--space-5); scroll-margin-top: 128px; }.stage-summary-grid { display: grid; grid-template-columns: 1.4fr repeat(5, 1fr); margin-bottom: var(--space-4); border: 1px solid var(--steel-border); background: var(--plant-panel); }.stage-summary-grid > div { display: grid; align-content: center; gap: var(--space-1); min-height: 116px; padding: var(--space-4); border-left: 1px solid var(--steel-border-soft); }.stage-summary-grid > div:first-child { border-left: 0; border-top: 3px solid var(--pipe-green); }.stage-summary-primary strong { font-size: 28px; }
.stage-detail-facts { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: var(--space-4); padding: var(--space-4); border: 1px solid var(--steel-border); background: var(--plant-panel); }
.stage-work-timeline { padding: 0 var(--space-4) var(--space-4); }.stage-work-timeline article { display: grid; grid-template-columns: 120px 1fr; gap: var(--space-4); padding: var(--space-3) 0; border-top: 1px solid var(--steel-border-soft); }.stage-work-timeline time { color: var(--plant-ink-tertiary); font-variant-numeric: tabular-nums; }.stage-work-timeline p { margin: var(--space-1) 0; }.stage-work-timeline small { color: var(--plant-ink-tertiary); }
.stage-subpoint-roadmap { display: grid; margin: 0; padding: 0 var(--space-4) var(--space-5); list-style: none; }.stage-subpoint-roadmap > li { display: grid; grid-template-columns: 48px minmax(0,1fr); min-height: 104px; }.stage-subpoint-roadmap > li.is-inactive { opacity: .64; }.stage-subpoint-rail { position: relative; display: flex; justify-content: center; }.stage-subpoint-rail::after { content: ""; position: absolute; top: 40px; bottom: 0; width: 2px; background: var(--steel-border); }.stage-subpoint-roadmap > li:last-child .stage-subpoint-rail::after { display: none; }.stage-subpoint-rail > span { z-index: 1; display: grid; place-items: center; width: 36px; height: 36px; border: 2px solid var(--pipe-green); border-radius: 50%; background: var(--plant-panel); color: var(--pipe-green-strong); font: 700 var(--text-label)/1 var(--font-display); font-variant-numeric: tabular-nums; }.stage-subpoint-roadmap article { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: var(--space-4); margin: 0 0 var(--space-4) var(--space-2); padding: var(--space-3) var(--space-4); border: 1px solid var(--steel-border); border-radius: var(--radius-panel); background: var(--plant-panel); }.stage-subpoint-copy h3 { margin: var(--space-1) 0; font-size: var(--text-h3); }.stage-subpoint-copy p { margin: var(--space-1) 0 0; color: var(--plant-ink-secondary); }.stage-subpoint-meta { display: flex; flex-wrap: wrap; gap: var(--space-2); color: var(--plant-ink-tertiary); font-size: var(--text-caption); }.stage-subpoint-actions { display: flex; align-items: center; gap: var(--space-1); }.stage-subpoint-actions .button { min-width: 40px; }.stage-artifact-empty-action { display: flex; justify-content: flex-end; margin: calc(var(--space-2) * -1) 0 var(--space-5); }.stage-artifact-empty-action .button { min-width: 160px; }
.stage-chart-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-4); }.stage-chart-grid > .panel { min-width: 0; padding: var(--space-5); }.stage-chart-grid h3 { margin-bottom: var(--space-4); }
.stage-person-row { display: grid; grid-template-columns: minmax(140px, 1fr) auto auto auto; gap: var(--space-3); align-items: center; min-height: 44px; border-top: 1px solid var(--steel-border-soft); }.stage-person-row span { color: var(--plant-ink-secondary); font-size: var(--text-caption); }.stage-person-row b { font-variant-numeric: tabular-nums; }
.stage-entry-filters { margin: 0; border: 0; border-top: 1px solid var(--steel-border-soft); border-radius: 0; }.stage-entry-filters .field { min-width: 150px; }
.stage-history { padding: 0 var(--space-4) var(--space-4); }.stage-history article { display: flex; align-items: center; gap: var(--space-3); min-height: 48px; border-top: 1px solid var(--steel-border-soft); }.stage-history article > div { display: grid; }.stage-history small { color: var(--plant-ink-tertiary); }
.stage-artifact-list { display: grid; padding: 0 var(--space-4) var(--space-4); }.stage-artifact-list > article { display: grid; grid-template-columns: 44px minmax(0,1fr) auto; align-items: center; gap: var(--space-3); min-height: 84px; padding: var(--space-3) 0; border-top: 1px solid var(--steel-border-soft); }.stage-artifact-icon { display: grid; place-items: center; width: 40px; height: 40px; border: 1px solid var(--steel-border); border-radius: var(--radius-control); background: var(--plant-inset); color: var(--pipe-green-strong); font-family: var(--font-display); font-weight: 750; }.stage-artifact-list h3 { margin: 2px 0; font-size: var(--text-label); }.stage-artifact-list p { margin: 2px 0; color: var(--plant-ink-secondary); }.stage-artifact-list span,.stage-artifact-list small { color: var(--plant-ink-tertiary); font-size: var(--text-caption); }.stage-artifact-actions { display: flex; align-items: center; gap: var(--space-2); }.artifact-no-access { max-width: 220px; padding: var(--space-2); border: 1px solid var(--steel-border); background: var(--plant-inset); color: var(--plant-ink-tertiary); text-align: center; }
.inline-rejection { display: grid; gap: var(--space-2); min-width: 260px; margin-top: var(--space-2); }
.annual-capacity--standalone { margin-bottom: var(--space-4); }
.annual-chart { display: grid; gap: var(--space-2); }
.annual-month-row { display: grid; grid-template-columns: 110px minmax(240px,1fr) 140px; align-items: center; gap: var(--space-3); min-height: 40px; }
.annual-month-row > strong { text-transform: capitalize; }.annual-month-row > span { text-align: right; font-variant-numeric: tabular-nums; }.annual-month-row small { display: block; color: var(--plant-ink-tertiary); }
.annual-month-track { position: relative; height: 18px; background: var(--plant-inset); }
.annual-month-value { display: block; height: 100%; background: var(--status-info); }
.annual-cumulative { position: absolute; top: -4px; width: 3px; height: 26px; background: var(--pipe-green); }
.muted-copy { color: var(--plant-ink-tertiary); }

@media (max-width: 1100px) {
    .development-hero, .development-chart-grid, .development-settings-grid, .stage-chart-grid { grid-template-columns: 1fr; }
    .stage-summary-grid { grid-template-columns: repeat(3, 1fr); }.stage-summary-grid > div:nth-child(4) { border-left: 0; }.stage-detail-facts { grid-template-columns: repeat(2, 1fr); }
    .development-admin-row, .development-project-admin-row { grid-template-columns: 1fr 1fr; }
    .stage-viewbar { align-items: flex-start; flex-direction: column; }
    .schedule-commandbar { grid-template-columns: 1fr; align-items: stretch; }
    .schedule-view-modes { justify-self: start; }
    .schedule-period-navigation { grid-template-columns: auto minmax(160px, 1fr) auto auto; }
    .content-grid--narrow, .content-grid--form, .dashboard-layout, .admin-detail-grid, .records-layout { grid-template-columns: 1fr; }
    .dashboard-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .admin-detail-aside { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .workforce-layout, .absence-workbench { grid-template-columns: 1fr; }
    .bar-row { grid-template-columns: 120px minmax(160px, 1fr) 80px; }
    .report-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .matrix-editor { position: static; max-height: none; }
    .matrix-scroll { max-height: 68vh; }
}

@media (max-width: 640px) {
    .stage-modal-layer { align-items: end; padding: 0; }
    .stage-modal { width: 100%; max-height: 100dvh; min-height: 100dvh; border: 0; border-radius: 0; }
    .stage-modal__header, .stage-modal__body { padding: var(--space-4); }
    .stage-modal__actions { padding: var(--space-3) var(--space-4) var(--space-4); }
    .stage-modal__actions .button { flex: 1 1 100%; min-height: 44px; }
    .development-settings-row { grid-template-columns: 1fr; align-items: start; }.development-settings-row .row-actions { width: 100%; }.development-settings-row .row-actions .button { flex: 1; }
}

@media (prefers-reduced-motion: reduce) { .stage-modal { animation: none; } }

@media (min-width: 2400px) {
    :root {
        --text-caption: 13px;
        --text-body: 15px;
        --text-label: 15px;
        --text-h3: 18px;
        --text-h2: 22px;
        --text-h1: 26px;
    }
    .page-heading h1 { font-size: 30px; }
    .panel { padding: var(--space-8); }
    .workforce-matrix thead th, .matrix-cell { min-width: 160px; }
}

@media (max-width: 720px) {
    .development-toolbar { align-items: stretch; padding: var(--space-3); }
    .development-toolbar .field, .development-add { width: 100%; min-width: 0; margin-left: 0; }
    .development-month-total, .annual-capacity { padding: var(--space-4); }
    .annual-capacity__heading, .annual-capacity__values { align-items: flex-start; flex-direction: column; }
    .project-bar-row { grid-template-columns: 1fr 76px; }
    .project-bar-row > strong { grid-column: 1 / -1; }
    .work-entry-drawer { width: 100vw; max-width: none; border-left: 0; }
    .development-admin-row, .development-project-admin-row { grid-template-columns: 1fr; align-items: stretch; }
    .stage-roadmap > header { align-items: flex-start; flex-direction: column; padding: var(--space-4); }
    .stage-roadmap__scroll { overflow-x: visible; padding: var(--space-4); }
    .stage-timeline { display: grid; min-width: 0; }
    .stage-point { display: grid; grid-template-columns: 40px minmax(0, 1fr); width: 100%; padding: 0 0 var(--space-4); }
    .stage-point__rail { align-items: flex-start; height: 100%; margin: 0; }
    .stage-point__rail::after { left: 19px; right: auto; top: 40px; bottom: 0; width: 2px; height: auto; }
    .stage-point > article { min-height: 0; }
    .stage-point--add { width: 100%; }.stage-point--add button { min-height: 96px; }
    .stage-detail-heading { display: grid; }.stage-detail-actions { justify-content: flex-start; }.stage-summary-grid { grid-template-columns: repeat(2, 1fr); }.stage-summary-grid > div:nth-child(odd) { border-left: 0; }.stage-detail-facts { grid-template-columns: 1fr; }.stage-work-timeline article { grid-template-columns: 1fr; gap: var(--space-1); }.stage-person-row { grid-template-columns: 1fr 1fr; padding: var(--space-2) 0; }
    .stage-commandbar,.stage-roadmap-heading { align-items: stretch; flex-direction: column; }.stage-project-switch { width: 100%; }.stage-project-switch button { min-width: 120px; flex: 1 1 auto; }.stage-roadmap-actions > .button,.stage-roadmap-actions > details { flex: 1 1 100%; }.stage-roadmap-actions > details > summary { width: 100%; }.stage-artifact-list > article { grid-template-columns: 40px minmax(0,1fr); }.stage-artifact-actions { grid-column: 1 / -1; justify-content: flex-end; }
    .annual-month-row { grid-template-columns: 72px minmax(120px, 1fr); }
    .annual-month-row > span { grid-column: 1 / -1; text-align: left; }
    .schedule-commandbar { padding: var(--space-2); }
    .schedule-view-modes { width: 100%; }
    .schedule-view-modes button { min-width: 0; flex: 1 1 0; padding-inline: var(--space-2); }
    .schedule-period-navigation { grid-template-columns: 1fr 1fr; }
    .schedule-period-navigation .period-title { grid-column: 1 / -1; grid-row: 1; min-height: 44px; display: grid; place-items: center; }
    .schedule-period-navigation .period-today { grid-column: 1 / -1; }
    .schedule-legend { max-height: 96px; overflow-y: auto; }
    .impersonation-dialog-layer { align-items: end; padding: 0; }
    .impersonation-dialog { width: 100%; max-height: 100dvh; min-height: 100dvh; align-content: start; padding: var(--space-5) var(--space-4); border: 0; border-radius: 0; }
    .impersonation-dialog__actions { margin-top: auto; }
    .impersonation-dialog__actions .button { width: 100%; min-height: 44px; }
    .absence-summary-strip { overflow-x: auto; align-items: stretch; }
    .absence-summary-strip > span { flex: 0 0 auto; }
    .absence-summary-strip > button { flex: 0 0 auto; margin-left: 0; }
    .absence-drawer { width: 100vw; max-width: none; border-left: 0; }
    .drawer-header, .drawer-content { padding: 16px; }
    .drawer-actions { margin-right: -16px; margin-bottom: -16px; margin-left: -16px; padding: 12px 16px 16px; }
    .employee-admin-row { grid-template-columns: 1fr; align-items: stretch; }
    .dashboard-metrics { grid-template-columns: 1fr; }
    .report-toolbar { align-items: stretch; flex-direction: column; }
    .report-kpis { grid-template-columns: 1fr; }
    .export-dialog { margin-left: 0; }
    .bar-row { grid-template-columns: 1fr 64px; }
    .bar-row > strong { grid-column: 1 / -1; }
    .page-heading { align-items: flex-start; flex-direction: column; }
    .page-heading h1 { font-size: var(--text-h1); }
    .time-block { min-width: 0; padding-left: 0; border-left: 0; text-align: left; }
    .operations-status { grid-template-columns: 42px 1fr; min-height: 0; }
    .operations-status__flow { width: 32px; height: 100px; }
    .operations-status > .status-label { grid-column: 2; justify-self: start; }
    .field-grid, .choice-grid, .admin-detail-aside { grid-template-columns: 1fr; }
    .panel { padding: var(--space-5) var(--space-4); }
    .panel--flush { padding: 0; }
    .filter-bar { align-items: stretch; flex-direction: column; }
    .field--inline { align-items: stretch; flex-direction: column; gap: var(--space-2); }
    .filter-bar select { min-width: 0; }
    .detail-list > div { grid-template-columns: 1fr; gap: var(--space-1); padding: var(--space-3) 0; }
    .row-actions { justify-content: flex-start; }
    .workforce-heading { align-items: stretch; }
    .month-toolbar { width: 100%; flex-wrap: wrap; }
    .month-toolbar__current { min-width: 0; flex: 1; }
    .month-toolbar .button { width: 100%; }
    .matrix-legend { margin-top: 0; }
    .matrix-actions { align-items: stretch; flex-direction: column; }
    .matrix-filter-group { align-items: stretch; flex-direction: column; gap: 0; }
    .view-switch { align-self: flex-start; }
    .matrix-scroll { max-height: none; overflow: visible; }
    .workforce-matrix { min-width: 0; display: block; }
    .workforce-matrix thead { display: none; }
    .workforce-matrix tbody { display: grid; gap: var(--space-3); padding: var(--space-3); }
    .workforce-matrix tbody tr { display: grid; overflow: hidden; border: 1px solid var(--steel-border); border-radius: var(--radius-control); background: var(--plant-panel); }
    .workforce-matrix tbody .matrix-day-column { position: static; width: auto; min-width: 0; max-width: none; height: auto; padding: var(--space-3); border-right: 0; background: var(--plant-panel-muted); }
    .schedule-matrix--week tbody .matrix-day-column, .schedule-matrix--week.density-comfortable tbody .matrix-day-column { height: auto; min-height: 84px; }
    .workforce-matrix tbody .matrix-cell { min-width: 0; height: auto; display: grid; grid-template-columns: minmax(112px, .42fr) 1fr; align-items: stretch; border-right: 0; }
    .workforce-matrix tbody .matrix-cell::before { content: attr(data-employee); display: flex; align-items: center; padding: var(--space-2) var(--space-3); border-right: 1px solid var(--steel-border-soft); color: var(--plant-ink-secondary); font-size: var(--text-caption); font-weight: 650; }
    .matrix-cell-button { min-height: 64px; }
    .workforce-matrix tfoot { position: static; display: block; }
    .workforce-matrix tfoot tr { display: grid; gap: var(--space-2); padding: var(--space-3); }
    .workforce-matrix tfoot .matrix-day-column { position: static; width: auto; min-width: 0; max-width: none; height: auto; }
    .workforce-matrix tfoot td { position: static; min-height: 64px; display: grid; grid-template-columns: minmax(112px, .42fr) 1fr; align-items: center; padding: 0; border: 1px solid var(--steel-border-soft); }
    .workforce-matrix tfoot td::before { content: attr(data-employee); padding: var(--space-3); color: var(--plant-ink-secondary); font-size: var(--text-caption); font-weight: 650; }
    .workforce-matrix tfoot .month-total { padding: var(--space-3); border-left: 1px solid var(--steel-border-soft); }
    .absence-row { grid-template-columns: auto 1fr; }
    .absence-row__status, .absence-row .row-actions { grid-column: 2; }
}

@media (max-width: 720px) {
    .stage-subpoint-roadmap { padding-inline: var(--space-3); }
    .stage-subpoint-roadmap > li { grid-template-columns: 40px minmax(0,1fr); }
    .stage-subpoint-roadmap article { grid-template-columns: 1fr; margin-left: var(--space-1); padding: var(--space-3); }
    .stage-subpoint-actions { justify-content: flex-end; }
    .stage-artifact-empty-action { justify-content: stretch; margin-top: 0; }
    .stage-artifact-empty-action .button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
    .button:active:not(:disabled) { transform: none; }
}

/* Dávkování — denní zápis a měsíční matice provozních evidencí. */
.operational-workspace { display: grid; gap: var(--space-5); }
.operational-workspace > .page-heading { margin-bottom: 0; }
.hygiene-threshold { min-width: 184px; display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 0 var(--space-3); padding-left: var(--space-4); border-left: 2px solid var(--pipe-green); }
.hygiene-threshold span, .hygiene-threshold small { color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.hygiene-threshold strong { grid-row: 1 / 3; grid-column: 2; color: var(--pipe-green); font-family: var(--font-display); font-size: var(--text-display); line-height: 1; font-variant-numeric: tabular-nums; }
.operational-commandbar { display: grid; grid-template-columns: 220px minmax(0, 1fr); align-items: stretch; border: 1px solid var(--steel-border); border-radius: var(--radius-panel); background: var(--plant-panel); overflow: hidden; }
.operational-month-nav { display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; gap: var(--space-2); padding: var(--space-3); border-right: 1px solid var(--steel-border); background: var(--plant-panel-muted); }
.operational-month-nav strong { text-align: center; text-transform: capitalize; font-family: var(--font-display); font-size: var(--text-label); }
.operational-month-nav .button { width: 44px; min-height: 44px; padding: 0; }
.operational-day-list { display: flex; min-width: 0; overflow-x: auto; scrollbar-width: thin; }
.operational-day { min-width: 52px; min-height: 64px; display: grid; place-content: center; gap: 1px; border: 0; border-right: 1px solid var(--steel-border-soft); background: transparent; color: var(--plant-ink-secondary); cursor: pointer; transition: background-color 140ms ease-out, color 140ms ease-out; }
.operational-day:hover { background: var(--plant-panel-muted); color: var(--plant-ink); }
.operational-day.is-selected { background: var(--pipe-green); color: #fff; }
.operational-day span { font-size: 10px; text-transform: uppercase; }
.operational-day strong { font-family: var(--font-display); font-size: 17px; font-variant-numeric: tabular-nums; }
.operational-selected-day { min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); padding: var(--space-3) var(--space-4); border-left: 3px solid var(--pipe-green); background: var(--pipe-green-soft); color: var(--pipe-green-strong); }
.operational-selected-day__summary { min-width: 0; display: grid; gap: 2px; }
.operational-selected-day span, .operational-selected-day small { font-size: var(--text-caption); }
.operational-selected-day strong { text-transform: capitalize; font-family: var(--font-display); font-size: var(--text-h3); }
.operational-selected-day small { font-variant-numeric: tabular-nums; }
.operational-day-actions { flex: 0 0 auto; display: flex; align-items: center; gap: var(--space-2); }
.operational-day-actions .button { min-height: 44px; }
.operational-heading-actions { display: flex; align-items: center; justify-content: flex-end; gap: var(--space-3); flex-wrap: wrap; }
.dosing-view-switch { margin-bottom: var(--space-3); }
.dosing-view-switch button { min-width: 112px; min-height: 42px; font-size: var(--text-body); }
.operational-commandbar.is-monthly { grid-template-columns: minmax(280px, 360px) 1fr; }
.dosing-month-context { min-height: 52px; display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); padding: var(--space-2) var(--space-4); color: var(--plant-ink-secondary); }
.dosing-month-context span { font-size: var(--text-caption); font-weight: 650; text-transform: uppercase; letter-spacing: .06em; }
.dosing-month-context strong { color: var(--plant-ink); font-variant-numeric: tabular-nums; }
.hygiene-cycle-summary { margin-bottom: var(--space-5); border: 1px solid var(--steel-border); background: var(--plant-panel); }
.hygiene-cycle-summary header { display: flex; align-items: center; justify-content: space-between; gap: var(--space-6); padding: var(--space-4) var(--space-5); border-bottom: 1px solid var(--steel-border-soft); }
.hygiene-cycle-summary h2 { margin: 0; }
.hygiene-cycle-summary header p { max-width: 720px; margin: var(--space-1) 0 0; color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.hygiene-cycle-actions { display: grid; justify-items: end; gap: var(--space-2); min-width: min(100%, 320px); }
.hygiene-recalculate { min-height: 44px; }
.hygiene-recalculate > span { margin-right: var(--space-2); font-size: 17px; line-height: 1; }
.hygiene-cycle-status { min-height: 44px; display: flex; align-items: center; gap: var(--space-2); padding: var(--space-2) var(--space-3); border-left: 3px solid var(--straw-warning); background: var(--straw-warning-bg); color: var(--plant-ink-secondary); }
.hygiene-cycle-status.is-ready { border-left-color: var(--flow-success); background: var(--flow-success-bg); color: var(--pipe-green-strong); }
.hygiene-cycle-status span { width: 24px; height: 24px; display: grid; place-items: center; border: 1px solid currentColor; font-weight: 700; }
.hygiene-cycle-status strong { max-width: 320px; font-size: var(--text-caption); }
.hygiene-cycle-values { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.hygiene-cycle-values > div { min-height: 72px; display: grid; align-content: center; gap: 2px; padding: var(--space-3) var(--space-5); border-right: 1px solid var(--steel-border-soft); }
.hygiene-cycle-values > div:last-child { border-right: 0; }
.hygiene-cycle-values span { color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.hygiene-cycle-values strong { color: var(--plant-ink); font-family: var(--font-display); font-size: var(--text-h3); font-variant-numeric: tabular-nums; }
.hygiene-cycle-summary progress { display: block; width: 100%; height: 8px; border: 0; border-radius: 0; background: var(--plant-inset); accent-color: var(--pipe-green); }
.hygiene-cycle-summary progress::-webkit-progress-bar { background: var(--plant-inset); }
.hygiene-cycle-summary progress::-webkit-progress-value { background: var(--pipe-green); }
.operational-input-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-5); align-items: start; }
.operational-input-grid > .operational-table-panel:nth-child(3) { grid-column: 1 / -1; }
.operational-table-panel { min-width: 0; }
.operational-section-heading { align-items: start; margin-bottom: var(--space-4); }
.operational-type-band { min-height: 36px; display: flex; align-items: center; justify-content: space-between; padding: var(--space-2) var(--space-4); border-top: 1px solid var(--steel-border); border-bottom: 1px solid var(--steel-border-soft); background: var(--plant-inset); }
.operational-type-band span { color: var(--plant-ink); font-family: var(--font-display); font-size: var(--text-caption); font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.operational-type-band small { color: var(--plant-ink-muted); font-size: var(--text-caption); }
.operational-table th { background: var(--plant-panel); }
.operational-table td:first-child strong { color: var(--plant-ink); font-weight: 650; }
.operational-table td:first-child { min-width: 172px; }
.operational-code { display: inline-flex; min-height: 28px; align-items: center; padding: 0 var(--space-2); border: 1px solid var(--steel-border); border-radius: var(--radius-control); background: var(--plant-inset); color: var(--plant-ink-secondary); font-family: ui-monospace, "Cascadia Mono", monospace; font-size: 11px; font-weight: 700; letter-spacing: .04em; }
.material-type { display: inline-flex; align-items: center; gap: var(--space-2); color: var(--plant-ink-secondary); font-size: var(--text-caption); font-weight: 650; white-space: nowrap; }
.material-type::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--plant-ink-muted); }
.material-type--solid::before { border-radius: 2px; background: var(--straw-warning); }
.material-type--liquid::before { background: var(--status-info); }
.material-type--automatic::before { background: var(--pipe-green); box-shadow: 0 0 0 3px var(--pipe-green-soft); }
.operational-value-cell { width: 132px; }
.operational-value-cell input { min-width: 104px; max-width: 132px; text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }
.operational-supplier-cell { min-width: 190px; }
.operational-supplier-cell select { min-width: 176px; }
.operational-delete { color: var(--alarm-danger); }
.operational-empty { min-height: 116px; display: flex; align-items: center; justify-content: center; gap: var(--space-3); padding: var(--space-5); color: var(--plant-ink-secondary); }
.operational-empty > span { width: 38px; height: 34px; display: grid; place-items: center; border: 1px solid var(--steel-border); background: var(--plant-inset); color: var(--plant-ink-muted); font-family: var(--font-display); font-size: 11px; font-weight: 700; }
.operational-empty > div { display: grid; gap: 2px; }
.operational-empty small { color: var(--plant-ink-tertiary); }
.operational-entry-dialog { max-width: 620px; }
.operational-confirm-dialog { max-width: 520px; }
.supplier-dialog { max-width: 680px; }
.supplier-dialog__body { display: grid; gap: var(--space-5); }
.supplier-create-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: var(--space-3); }
.supplier-create-row .field { margin: 0; }
.supplier-list { display: grid; border-top: 1px solid var(--steel-border); }
.supplier-list__item { min-height: 60px; display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); padding: var(--space-2) 0; border-bottom: 1px solid var(--steel-border-soft); }
.supplier-list__item > div { display: flex; align-items: center; gap: var(--space-3); min-width: 0; }
.supplier-list__item > .supplier-list__actions { justify-content: flex-end; flex-wrap: wrap; }
.supplier-list__item strong { overflow-wrap: anywhere; }
.operational-definition-dialog { width: min(760px, calc(100vw - 32px)); max-width: 760px; }
.definition-explainer { display: flex; align-items: flex-start; gap: var(--space-3); padding: var(--space-3) var(--space-4); border: 1px solid var(--steel-border); background: var(--plant-panel-muted); border-radius: var(--radius-panel); }
.definition-explainer > span { color: var(--pipe-green); font-size: 20px; font-weight: 700; line-height: 1.2; }
.definition-explainer p { margin: 0; color: var(--plant-ink-secondary); }
.definition-year-nav { display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; gap: var(--space-3); padding: var(--space-2); border: 1px solid var(--steel-border); background: var(--plant-panel); }
.definition-year-nav > div { display: grid; justify-items: center; gap: var(--space-1); }
.definition-year-nav span { color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.definition-year-nav strong { font-size: 20px; font-variant-numeric: tabular-nums; }
.supplier-list__item.definition-list__item > div:first-child { display: grid; align-items: start; gap: var(--space-1); min-width: 0; }
.definition-list__context { color: var(--plant-ink-tertiary); font-size: 12px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.definition-list__item small { color: var(--plant-ink-tertiary); }
.definition-visibility-body { display: grid; gap: var(--space-5); }
.visibility-quick-actions, .visibility-date-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-2); }
.visibility-date-setting { display: grid; gap: var(--space-3); padding-top: var(--space-4); border-top: 1px solid var(--steel-border-soft); }
.visibility-date-setting p { margin: 0; color: var(--plant-ink-tertiary); font-size: var(--text-caption); }
.supplier-status { display: inline-flex; align-items: center; gap: var(--space-2); color: var(--plant-ink-secondary); font-size: var(--text-caption); font-weight: 650; white-space: nowrap; }
.supplier-status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--plant-ink-muted); }
.supplier-status.is-active::before { background: var(--flow-success); }
.supplier-status.is-inactive::before { border: 1px solid var(--steel-border-strong); background: transparent; }
.dosing-month-sections { display: grid; gap: var(--space-5); }
.dosing-month-matrix { max-width: 100%; max-height: 66vh; overflow: auto; outline: none; }
.dosing-month-matrix:focus-visible { box-shadow: inset 0 0 0 3px rgba(36, 92, 58, .22); }
.dosing-month-matrix table { min-width: 2240px; width: 100%; border-collapse: separate; border-spacing: 0; font-size: var(--text-caption); font-variant-numeric: tabular-nums; }
.dosing-month-matrix th, .dosing-month-matrix td { height: 44px; padding: var(--space-2); border-right: 1px solid var(--steel-border-soft); border-bottom: 1px solid var(--steel-border-soft); background: var(--plant-panel); text-align: right; white-space: nowrap; }
.dosing-month-matrix thead th { position: sticky; top: 0; z-index: 4; height: 52px; background: var(--plant-panel-muted); color: var(--plant-ink-tertiary); text-align: center; }
.dosing-month-matrix thead th span, .dosing-month-matrix thead th strong { display: block; }
.dosing-month-matrix thead th span { font-size: 10px; font-weight: 650; text-transform: uppercase; }
.dosing-month-matrix thead th strong { margin-top: 2px; color: var(--plant-ink); font-size: var(--text-body); }
.dosing-month-matrix thead th.has-hygiene-event { min-width: 72px; height: 64px; box-shadow: inset 0 -3px 0 var(--straw-warning); background: var(--straw-warning-bg); }
.dosing-month-matrix thead th.has-hygiene-event small { display: block; margin-top: 2px; color: var(--straw-warning); font-size: 10px; font-weight: 750; text-transform: none; white-space: nowrap; }
.dosing-month-matrix .dosing-month-item { position: sticky; left: 0; z-index: 2; width: 196px; min-width: 196px; max-width: 196px; text-align: left; }
.dosing-month-matrix .dosing-month-supplier { position: sticky; left: 196px; z-index: 2; width: 180px; min-width: 180px; max-width: 180px; text-align: left; }
.dosing-month-matrix thead .dosing-month-item, .dosing-month-matrix thead .dosing-month-supplier { z-index: 6; background: var(--plant-panel-muted); }
.dosing-month-matrix tbody .dosing-month-item, .dosing-month-matrix tbody .dosing-month-supplier { background: var(--plant-panel); }
.dosing-month-matrix .dosing-month-item strong, .dosing-month-matrix .dosing-month-item small { display: block; overflow: hidden; text-overflow: ellipsis; }
.dosing-month-matrix .dosing-month-item strong { color: var(--plant-ink); font-size: var(--text-body); }
.dosing-month-matrix .dosing-month-item small { margin-top: 2px; color: var(--plant-ink-tertiary); font-weight: 500; }
.dosing-month-matrix .is-weekend { background: var(--plant-inset); }
.dosing-month-hygiene-events th, .dosing-month-hygiene-events td { background: var(--straw-warning-bg); }
.dosing-month-hygiene-events .dosing-month-item, .dosing-month-hygiene-events .dosing-month-supplier { background: var(--straw-warning-bg) !important; }
.dosing-month-hygiene-events .has-hygiene-event { box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--straw-warning) 42%, transparent); background: color-mix(in srgb, var(--straw-warning-bg) 70%, var(--plant-panel)); text-align: center; }
.hygiene-event-key { display: inline-flex; align-items: center; gap: var(--space-2); color: var(--straw-warning); font-size: var(--text-caption); font-weight: 700; white-space: nowrap; }
.hygiene-event-key > span, .hygiene-event-count > span { width: 20px; height: 20px; display: inline-grid; place-items: center; border: 1px solid currentColor; font-size: 12px; line-height: 1; }
.hygiene-event-count { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-1); color: var(--straw-warning); font-size: var(--text-body); font-variant-numeric: tabular-nums; white-space: nowrap; }
.dosing-month-matrix .dosing-month-total { position: sticky; right: 0; z-index: 3; min-width: 84px; border-left: 1px solid var(--steel-border); background: var(--pipe-green-soft); color: var(--pipe-green-strong); }
.dosing-month-matrix thead .dosing-month-total { z-index: 6; background: var(--pipe-green-soft); }

@media (max-width: 1050px) {
    .operational-input-grid { grid-template-columns: 1fr; }
    .operational-commandbar.is-monthly { grid-template-columns: 1fr; }
    .dosing-month-context { border-top: 1px solid var(--steel-border-soft); }
    .hygiene-cycle-summary header { align-items: stretch; flex-direction: column; }
    .hygiene-cycle-actions { justify-items: stretch; width: 100%; }
    .hygiene-recalculate { width: 100%; }
    .hygiene-cycle-values { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .hygiene-cycle-values > div:nth-child(2) { border-right: 0; }
    .hygiene-cycle-values > div:nth-child(-n+2) { border-bottom: 1px solid var(--steel-border-soft); }
}

@media (max-width: 720px) {
    .operational-heading-actions { width: 100%; align-items: stretch; flex-direction: column-reverse; }
    .operational-heading-actions .button { width: 100%; }
    .dosing-view-switch { width: 100%; }
    .dosing-view-switch button { flex: 1; }
    .hygiene-threshold { width: 100%; }
    .operational-commandbar { grid-template-columns: 1fr; }
    .operational-month-nav { border-right: 0; border-bottom: 1px solid var(--steel-border); }
    .operational-selected-day { align-items: stretch; flex-direction: column; gap: var(--space-3); }
    .operational-day-actions { display: grid; grid-template-columns: 1fr; }
    .operational-day-actions .button { width: 100%; }
    .supplier-create-row { grid-template-columns: 1fr; }
    .supplier-create-row .button { width: 100%; }
    .supplier-list__item { align-items: stretch; flex-direction: column; }
    .supplier-list__item .button, .supplier-list__actions { width: 100%; }
    .supplier-list__actions { display: grid !important; grid-template-columns: 1fr; }
    .operational-definition-dialog { width: 100%; max-width: none; }
    .visibility-quick-actions, .visibility-date-actions { grid-template-columns: 1fr; }
    .operational-table .row-actions { flex-direction: column; align-items: stretch; }
    .dosing-month-matrix { max-height: 72vh; }
    .hygiene-cycle-summary header { padding: var(--space-4); }
    .hygiene-cycle-values { grid-template-columns: 1fr; }
    .hygiene-cycle-values > div { min-height: 60px; padding: var(--space-3) var(--space-4); border-right: 0; border-bottom: 1px solid var(--steel-border-soft); }
    .hygiene-cycle-values > div:last-child { border-bottom: 0; }
    .dosing-month-matrix .dosing-month-item { width: 156px; min-width: 156px; max-width: 156px; }
    .dosing-month-matrix .dosing-month-supplier { left: 156px; width: 144px; min-width: 144px; max-width: 144px; }
}
