:root {
  color-scheme: light;
  --canvas: oklch(97.2666% 0.001711 247.839);
  --surface: oklch(100.0000% 0.000000 0.000);
  --surface-soft: oklch(98.1639% 0.001707 247.839);
  --ink: oklch(27.3525% 0.010323 242.074);
  --muted: oklch(53.1664% 0.021432 243.243);
  --faint: oklch(54.5159% 0.020182 240.266);
  --line: oklch(93.2587% 0.005189 247.880);
  --line-strong: oklch(89.5157% 0.008737 247.923);
  --sidebar: oklch(28.1281% 0.009017 234.026);
  --sidebar-muted: oklch(75.0283% 0.011694 243.705);
  --accent: oklch(45% 0.12 3.4);
  --accent-hover: oklch(39.4275% 0.111714 7.621);
  --accent-soft: oklch(95.4483% 0.011095 3.498);
  --success: oklch(50.6387% 0.075930 168.411);
  --success-soft: oklch(96.1999% 0.011584 162.049);
  --warning: oklch(53% 0.105631 73.039);
  --warning-soft: oklch(96.6076% 0.018764 83.064);
  --danger: oklch(50.9377% 0.137303 20.591);
  --danger-soft: oklch(95.9886% 0.014278 6.706);
  --radius: 9px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  --main-gutter: 32px;
  --topbar-gutter-left: 32px;
  --topbar-gutter-right: 32px;
  --topbar-height: 63px;
  --sidebar-gutter: 14px;
  --footer-gutter: 32px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 100%;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  color: var(--ink);
  background: var(--canvas);
}
* { box-sizing: border-box; }
body { margin: 0; }
button, input, textarea, select { font: inherit; }
button, a, input, textarea, select { -webkit-tap-highlight-color: oklch(0% 0 0 / 0); }
button { cursor: pointer; }
button:disabled { cursor: default; opacity: .55; }
button:disabled:hover { transform: none; }
a { color: inherit; text-decoration: none; }
input, textarea, select { color: var(--ink); }
input[type="checkbox"] { accent-color: var(--accent); width: 16px; height: 16px; flex: 0 0 16px; margin: 0; cursor: pointer; }
input[type="checkbox"]:disabled { opacity: .65; cursor: default; }
textarea { resize: vertical; min-height: 80px; }
input:disabled { background: oklch(95.9910% 0.002532 228.784); color: var(--muted); }
input::placeholder, textarea::placeholder { color: var(--muted); }
button, a, input, textarea, select { outline-offset: 3px; }
:focus-visible { outline: 2px solid var(--accent); }
p, h1, h2, h3, dl { margin: 0; }
h1 { font-size: 1.625rem; line-height: 1.28; letter-spacing: -.7px; font-weight: 650; }
h2 { font-size: 1rem; font-weight: 650; line-height: 1.4; letter-spacing: -.15px; }
h3 { font-size: 0.875rem; line-height: 1.5; font-weight: 650; }
small { font-size: 0.75rem; }
.icon { display: inline-block; flex: 0 0 auto; vertical-align: middle; }
.sr-only { position: absolute; height: 1px; width: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
[hidden] { display: none !important; }
.skip-link { position: fixed; z-index: 100; top: -60px; left: 16px; padding: 10px 16px; border-radius: 6px; background: var(--accent); color: oklch(100% 0 0); }
.skip-link:focus { top: 12px; }
.muted { color: var(--muted); }
.text-danger { color: var(--danger) !important; }
.text-success { color: var(--success) !important; }
.eyebrow { font-size: 0.75rem; font-weight: 600; letter-spacing: .7px; text-transform: uppercase; color: var(--muted); }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 37px; padding: 8px 13px; border: 1px solid var(--line-strong); border-radius: 6px; background: var(--surface); color: var(--ink); font-size: 0.75rem; font-weight: 600; line-height: 1.5; white-space: nowrap; transition: background-color 150ms, border-color 150ms, box-shadow 150ms; }
.button:hover:not(:disabled) { background: oklch(96.9671% 0.001713 247.839); border-color: oklch(84.1572% 0.011365 243.679); }
.button:active:not(:disabled) { background: oklch(95.0413% 0.004201 236.498); }
.button.primary { background: var(--accent); border-color: var(--accent); color: oklch(100.0000% 0.000000 0.000); }
.button.primary:hover:not(:disabled) { background: var(--accent-hover); border-color: var(--accent-hover); }
.button.primary:active:not(:disabled) { background: oklch(35.4238% 0.099207 6.581); }
.button.small { min-height: 31px; padding: 5px 10px; font-size: 0.75rem; }
.icon-button { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; padding: 6px; border: 0; border-radius: 6px; background: oklch(0% 0 0 / 0); color: var(--muted); transition: background-color 150ms, color 150ms; }
.icon-button:hover { color: var(--ink); background: oklch(95.3424% 0.004197 236.498); }
.text-button, .text-link { display: inline-flex; align-items: center; gap: 5px; border: 0; padding: 4px 0; background: oklch(0% 0 0 / 0); color: var(--accent); font-size: 0.75rem; font-weight: 600; line-height: 1.5; }
.text-button:hover, .text-link:hover { color: var(--accent-hover); text-decoration: underline; text-underline-offset: 3px; }
.brand-mark { display: inline-flex; justify-content: center; align-items: center; flex: 0 0 auto; width: 34px; height: 34px; border-radius: 9px; background: var(--accent); color: oklch(100% 0 0); font-size: 1.5625rem; line-height: 1; font-weight: 700; letter-spacing: -2px; padding-right: 2px; }
.boot-state { display: flex; align-items: center; gap: 12px; min-height: 100vh; justify-content: center; color: var(--muted); }
.noscript { text-align: center; padding: 24px; }
.connection-screen { display: grid; place-items: center; min-height: 100vh; padding: 24px; }
.connection-screen .empty-state { background: oklch(100% 0 0); border: 1px solid var(--line); border-radius: var(--radius); max-width: 600px; }
.workspace { min-height: 100vh; }
.sidebar { position: fixed; top: 0; left: 0; bottom: 0; z-index: 30; width: 230px; background: var(--sidebar); color: oklch(94.3916% 0.005906 239.822); padding: 27px 14px 0; display: flex; flex-direction: column; }
.brand { display: flex; align-items: center; gap: 10px; padding: 0 11px 31px; }
.brand-name { font-size: 1.0625rem; line-height: 1.35; font-weight: 650; letter-spacing: -.3px; }
.brand-name small { display: block; color: var(--sidebar-muted); font-size: 0.75rem; font-weight: 400; margin-top: 2px; letter-spacing: .05px; }
.nav-caption { display: block; color: oklch(63.4520% 0.016769 241.916); font-size: 0.75rem; letter-spacing: .7px; text-transform: uppercase; font-weight: 600; padding: 0 13px 11px; }
.sidebar nav { display: flex; flex-direction: column; gap: 4px; }
.nav-item { display: flex; align-items: center; gap: 11px; min-height: 41px; padding: 9px 12px; border: 1px solid oklch(0% 0 0 / 0); border-radius: 6px; color: oklch(79.7828% 0.011517 243.691); font-size: 0.75rem; transition: background-color 150ms, color 150ms; }
.nav-item .icon { opacity: .85; }
.nav-item:hover { color: oklch(100.0000% 0.000000 0.000); background: oklch(32.8735% 0.010858 236.930); }
.sidebar :focus-visible { outline-color: oklch(75.9144% 0.065334 357.352); }
.nav-item.selected { background: oklch(32.6630% 0.018549 336.902); color: oklch(93.6618% 0.019646 349.074); border-color: oklch(42.4528% 0.060670 356.491); }
.nav-item.selected .icon { color: oklch(76.9629% 0.083571 2.818); opacity: 1; }
.nav-item .nav-count { margin-left: auto; padding: 1px 5px; font-size: 0.75rem; border-radius: 4px; background: oklch(39.7656% 0.066775 5.198); color: oklch(91.8813% 0.042971 7.230); font-variant-numeric: tabular-nums; }
.sidebar-bottom { margin-top: auto; padding-top: 24px; }
.access-caption { display: flex; gap: 7px; align-items: center; color: oklch(67.9172% 0.018153 236.831); padding: 0 12px 15px; font-size: 0.75rem; }
.user-profile { display: flex; align-items: center; gap: 9px; padding: 18px 3px 20px; border-top: 1px solid oklch(37.0335% 0.011577 232.698); }
.avatar { display: flex; align-items: center; justify-content: center; width: 33px; height: 33px; border-radius: 50%; background: oklch(42.9998% 0.014291 240.209); font-size: 0.75rem; color: oklch(95.1455% 0.007593 228.855); font-weight: 600; flex: 0 0 auto; }
.avatar.light { color: oklch(52.2382% 0.019166 274.556); background: oklch(94.4229% 0.005342 286.297); }
.avatar.large { width: 60px; height: 60px; font-size: 1.25rem; }
.profile-name { min-width: 0; font-size: 0.75rem; line-height: 1.4; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex: 1; }
.profile-name small { display: block; color: var(--sidebar-muted); font-size: 0.75rem; margin-top: 3px; }
.sidebar-logout { width: 27px; height: 29px; flex: 0 0 27px; color: oklch(71.2918% 0.015292 238.107); overflow: hidden; font-size: 0; }
.sidebar-logout:hover { background: oklch(37.7454% 0.013597 235.204); color: oklch(100.0000% 0.000000 0.000); }
.workspace-body { margin-left: 230px; }
.topbar { height: 63px; padding: 0 32px; border-bottom: 1px solid var(--line); background: var(--surface); display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.topbar-start, .topbar-end { display: flex; align-items: center; gap: 11px; }
.topbar-start { color: var(--faint); font-size: 0.75rem; }
.breadcrumb-label { color: var(--muted); }
.breadcrumb-current { color: var(--ink); font-weight: 500; }
.today-label { font-size: 0.75rem; color: var(--muted); padding-right: 8px; }
.topbar-avatar { display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); font-size: 0.75rem; font-weight: 650; }
.mobile-menu { display: none; }
.notification-anchor { position: relative; }
.notification-button { position: relative; }
.notification-dot { position: absolute; top: 5px; right: 6px; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 2px oklch(100% 0 0); }
.notification-panel { position: absolute; z-index: 40; right: -35px; top: 43px; width: min(390px, calc(100vw - 32px)); border: 1px solid var(--line-strong); border-radius: var(--radius); background: oklch(100% 0 0); box-shadow: 0 10px 40px oklch(26.9937% 0.011889 214.544 / 0.121569); }
.notification-panel .panel-heading { padding: 16px; }
.notification-panel .small-empty { padding: 25px 18px; }
.notification-list { max-height: 450px; overflow-y: auto; }
.notification-item { display: flex; flex-direction: column; align-items: flex-start; text-align: left; padding: 15px 20px; width: 100%; border: none; border-top: 1px solid var(--line); background: oklch(100% 0 0); }
.notification-item:hover { background: oklch(97.8650% 0.001709 247.839); }
.notification-item.unread { background: oklch(97.8326% 0.006910 354.792); border: 1px solid oklch(86.0210% 0.039303 353.349); padding: 14px 19px; }
.notification-item strong { font-size: 0.75rem; }
.notification-item span { color: var(--muted); font-size: 0.75rem; margin-top: 4px; white-space: pre-wrap; }
.notification-item small { color: var(--faint); font-size: 0.75rem; margin-top: 8px; }
.main { max-width: 1700px; margin: 0 auto; padding: 30px 32px 45px; min-height: calc(100vh - 110px); }
.main:focus { outline: none; }
.page-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 25px; }
.page-heading p { font-size: 0.75rem; color: var(--muted); margin-top: 7px; }
.heading-actions { display: flex; gap: 9px; align-items: center; flex-wrap: wrap; }
.workspace-footer { display: flex; justify-content: space-between; padding: 12px 32px 19px; color: oklch(68.5224% 0.013819 244.340); font-size: 0.75rem; }
.metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 15px; margin-bottom: 24px; }
.metric { display: flex; flex-direction: column; background: oklch(100% 0 0); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px 17px; transition: border-color 150ms; }
.metric:hover { border-color: oklch(80.6484% 0.012265 239.948); }
.metric-label { display: flex; align-items: center; justify-content: space-between; gap: 7px; color: var(--muted); font-size: 0.75rem; }
.metric-label .icon { color: oklch(67.8225% 0.015718 244.815); }
.metric strong { display: block; font-size: 1.9375rem; font-weight: 650; line-height: 1.35; letter-spacing: -1px; margin: 8px 0 5px; font-variant-numeric: tabular-nums; }
.metric > span { font-size: 0.75rem; color: oklch(65.2235% 0.017016 248.089); }
.metric-warning { border-color: oklch(91.2054% 0.019072 5.324); }
.metric-warning strong, .metric-warning .icon { color: var(--danger); }
.overview-grid { display: grid; grid-template-columns: minmax(0, 1fr) 310px; align-items: start; gap: 20px; }
.panel { background: oklch(100% 0 0); border: 1px solid var(--line); border-radius: var(--radius); min-width: 0; overflow: hidden; }
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 19px 22px; border-bottom: 1px solid var(--line); }
.panel-heading p { color: var(--muted); font-size: 0.75rem; margin-top: 4px; }
.panel-heading h2 { font-size: 0.875rem; }
.panel-heading .text-link { font-size: 0.75rem; }
.count-label, .inline-count { display: inline-flex; justify-content: center; align-items: center; padding: 1px 6px; border-radius: 4px; background: oklch(96.0194% 0.003434 247.859); color: oklch(61.1453% 0.018037 245.236); font-size: 0.75rem; line-height: 1.5; font-weight: 500; }
.inline-count { margin-left: 5px; vertical-align: middle; }
.attention-preview-list { padding: 0 17px; }
.attention-preview-item { display: flex; gap: 10px; align-items: flex-start; padding: 17px 0; border-bottom: 1px solid var(--line); }
.attention-preview-item:last-child { border: none; }
.attention-preview-item:hover strong { color: var(--accent); }
.attention-preview-item > .icon { margin-top: 5px; color: var(--faint); }
.attention-symbol { display: flex; justify-content: center; align-items: center; color: var(--danger); background: var(--danger-soft); width: 27px; height: 27px; border-radius: 6px; flex: 0 0 27px; }
.attention-preview-item > div { min-width: 0; flex: 1; }
.attention-preview-item strong { display: block; font-size: 0.75rem; }
.attention-preview-item div > span { display: block; color: var(--muted); font-size: 0.75rem; margin-top: 2px; }
.attention-preview-item p { color: oklch(57.1246% 0.016397 244.883); font-size: 0.75rem; margin-top: 7px; overflow-wrap: anywhere; }
.attention-preview-item small { display: block; color: var(--faint); font-size: 0.75rem; margin-top: 9px; }
.attention-preview-footer { display: flex; align-items: center; justify-content: space-between; padding: 13px 19px; border-top: 1px solid var(--line); color: var(--accent); font-size: 0.75rem; font-weight: 600; }
.attention-preview-footer:hover { background: oklch(98.0539% 0.005928 350.795); }
.calm-state { display: flex; flex-direction: column; align-items: center; padding: 36px 22px; text-align: center; }
.calm-state > span { display: flex; align-items: center; justify-content: center; width: 47px; height: 47px; border-radius: 50%; background: var(--success-soft); color: var(--success); margin-bottom: 13px; }
.calm-state strong { font-size: 0.8125rem; }
.calm-state p { color: var(--muted); font-size: 0.75rem; margin-top: 7px; max-width: 240px; }
.workflow-note { display: flex; gap: 11px; margin-top: 22px; background: oklch(95.6432% 0.004194 236.498); border-radius: 7px; padding: 15px 18px; color: oklch(56.7378% 0.018371 245.271); font-size: 0.75rem; line-height: 1.65; }
.workflow-note > .icon { margin-top: 2px; color: oklch(65.5657% 0.023027 241.534); }
.workflow-note strong { font-weight: 600; color: oklch(50.4850% 0.024245 237.180); }
.onboarding { display: grid; grid-template-columns: 1.1fr 1fr; gap: 55px; border: 1px solid var(--line); border-radius: var(--radius); background: oklch(100% 0 0); padding: 44px 46px; }
.onboarding-content .eyebrow { color: var(--accent); }
.onboarding-content h2 { font-size: 1.4375rem; line-height: 1.4; letter-spacing: -.5px; margin-top: 13px; max-width: 390px; }
.onboarding-content p { color: var(--muted); font-size: 0.75rem; line-height: 1.75; margin: 14px 0 22px; max-width: 460px; }
.onboarding-steps { position: relative; display: flex; flex-direction: column; justify-content: center; gap: 23px; }
.onboarding-steps::before { content: ""; position: absolute; width: 1px; background: var(--line); left: 18px; top: 37px; bottom: 38px; }
.onboarding-step { display: flex; align-items: flex-start; gap: 17px; position: relative; }
.onboarding-number { display: flex; align-items: center; justify-content: center; width: 37px; height: 37px; flex: 0 0 37px; border: 1px solid var(--line); background: oklch(100% 0 0); border-radius: 50%; font-size: 0.75rem; color: oklch(65.7719% 0.016622 241.900); }
.onboarding-number.complete { background: var(--success-soft); color: var(--success); border-color: oklch(91.7823% 0.023340 161.710); }
.onboarding-step:first-child .onboarding-number:not(.complete) { background: var(--accent-soft); border-color: oklch(90.1310% 0.024909 355.372); color: var(--accent); }
.onboarding-step strong { font-size: 0.75rem; display: block; margin-top: 2px; }
.onboarding-step p { color: var(--muted); font-size: 0.75rem; line-height: 1.6; margin-top: 4px; }
.empty-state { padding: 46px 25px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.empty-icon { display: flex; align-items: center; justify-content: center; width: 54px; height: 54px; color: oklch(68.2775% 0.019123 240.132); background: oklch(96.2441% 0.004188 236.497); border-radius: 12px; margin-bottom: 15px; }
.empty-state h3 { font-size: 0.9375rem; }
.empty-state p { margin: 7px 0 19px; max-width: 390px; font-size: 0.75rem; line-height: 1.7; color: var(--muted); }
.small-empty { padding: 15px 0; font-size: 0.75rem; color: var(--muted); line-height: 1.7; }
.filters { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; margin-bottom: 19px; }
.search-field { display: flex; align-items: center; gap: 7px; border: 1px solid var(--line-strong); border-radius: 6px; background: oklch(100% 0 0); padding-left: 10px; width: 260px; color: var(--faint); }
.search-field input { width: 100%; min-width: 0; padding: 9px 10px 9px 0; border: none; background: oklch(0% 0 0 / 0); font-size: 0.75rem; height: 36px; }
.search-field:focus-within { border-color: var(--accent); outline: 2px solid var(--accent-soft); }
.search-field input:focus { outline: none; }
.filter-select select { font-size: 0.75rem; max-width: 200px; height: 37px; padding: 7px 28px 7px 11px; border: 1px solid var(--line-strong); border-radius: 6px; background-color: oklch(100% 0 0); cursor: pointer; }
.check-option { display: flex; align-items: center; gap: 8px; font-size: 0.75rem; color: var(--muted); min-height: 20px; }
.archive-filter { padding: 0 6px; }
.table-scroll { position: relative; width: 100%; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; border-spacing: 0; text-align: left; font-size: 0.75rem; }
thead { background: oklch(98.7609% 0.001705 247.839); }
th { font-weight: 500; color: oklch(60.8091% 0.018062 245.239); font-size: 0.75rem; letter-spacing: .05px; white-space: nowrap; padding: 12px 17px; border-bottom: 1px solid var(--line); }
td { padding: 17px; border-bottom: 1px solid oklch(95.3424% 0.004197 236.498); vertical-align: middle; }
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover { background: oklch(99.1348% 0.001318 286.376); }
th:first-child, td:first-child { padding-left: 22px; }
th:last-child, td:last-child { padding-right: 22px; }
.project-table td:first-child { min-width: 195px; }
.project-table td:nth-child(2) { min-width: 170px; }
.object-link { display: inline-flex; gap: 7px; align-items: center; font-weight: 600; font-size: 0.75rem; line-height: 1.5; }
.object-link:hover, td > a:not(.button):hover { color: var(--accent); }
.table-secondary { display: block; color: oklch(66.2136% 0.016953 248.084); font-size: 0.75rem; margin-top: 4px; font-weight: 400; line-height: 1.5; }
.current-stage-name { font-size: 0.75rem; }
.manager-cell { display: block; max-width: 135px; font-size: 0.75rem; line-height: 1.5; }
.priority-indicator { color: var(--accent); font-size: 0.9375rem; }
.table-open { position: relative; width: 25px; height: 29px; }
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 7px; background: oklch(96.0194% 0.003434 247.859); color: oklch(61.7377% 0.018777 242.598); font-size: 0.75rem; line-height: 1.5; font-weight: 500; border-radius: 4px; white-space: nowrap; }
.status-dot { width: 4px; height: 4px; flex: 0 0 4px; background: currentColor; border-radius: 50%; }
.badge-progress { background: var(--accent-soft); color: var(--accent); }
.badge-waiting { background: var(--warning-soft); color: var(--warning); }
.badge-blocked { background: var(--danger-soft); color: var(--danger); }
.badge-done { background: var(--success-soft); color: var(--success); }
.project-status-group { display: inline-flex; flex-direction: column; align-items: flex-start; gap: 5px; }
.government-indicator { display: inline-flex; align-items: center; gap: 3px; color: oklch(65.9758% 0.013200 248.028); font-size: 0.75rem; white-space: nowrap; line-height: 1.5; font-weight: 400; }
.heading-actions .government-indicator { font-size: 0.75rem; }
.mini-pipeline { display: flex; align-items: center; gap: 4px; width: max-content; }
.mini-step { width: 20px; height: 21px; display: flex; align-items: center; justify-content: center; font-size: 0.75rem; font-variant-numeric: tabular-nums; background: oklch(96.0194% 0.003434 247.859); color: oklch(74.2203% 0.016138 241.851); border: 1px solid oklch(94.0610% 0.005083 228.821); border-radius: 3px; transition: border-color 150ms; }
.mini-step:hover { border-color: var(--accent); }
.mini-pipeline.compact { gap: 3px; }
.mini-pipeline.compact .mini-step { width: 16px; height: 19px; font-size: 0.75rem; }
.mini-step.step-done { background: oklch(95.2242% 0.012493 164.795); color: oklch(56.2525% 0.066832 167.147); border-color: oklch(91.8820% 0.021712 163.029); }
.mini-step.step-progress { background: oklch(92.0375% 0.018162 351.175); color: oklch(52.7689% 0.093003 358.825); border-color: oklch(80.6767% 0.046518 357.277); }
.mini-step.step-waiting { background: oklch(95.1111% 0.026912 85.665); color: oklch(62.7549% 0.095003 80.703); border-color: oklch(90.6436% 0.046146 87.756); }
.mini-step.step-blocked { background: oklch(93.7951% 0.021104 6.622); color: oklch(56.7337% 0.126475 12.389); border-color: oklch(86.4473% 0.044203 3.845); }
.pipeline-legend { display: flex; gap: 11px; align-items: center; font-size: 0.75rem; color: oklch(65.1449% 0.017759 245.209); }
.pipeline-legend > span { display: flex; gap: 5px; align-items: center; }
.legend-dot { display: inline-block; width: 6px; height: 6px; border-radius: 2px; background: oklch(80.6031% 0.014039 241.001); }
.legend-dot.done { background: oklch(67.5691% 0.054476 163.998); }
.legend-dot.progress { background: oklch(62.0668% 0.093052 358.992); }
.legend-dot.waiting { background: oklch(72.3156% 0.087784 80.860); }
.pagination { display: flex; align-items: center; justify-content: space-between; border-top: 1px solid var(--line); padding: 13px 21px; color: var(--muted); font-size: 0.75rem; }
.pagination > div { display: flex; align-items: center; gap: 14px; }
.customer-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 17px; }
.customer-card { background: oklch(100% 0 0); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; align-self: start; }
.customer-card.expanded { grid-column: 1 / -1; border-color: oklch(83.8941% 0.024329 354.394); }
.customer-summary { display: flex; align-items: center; gap: 13px; width: 100%; background: oklch(100% 0 0); border: none; padding: 22px; text-align: left; }
.customer-summary:hover { background: oklch(98.6908% 0.002489 345.211); }
.customer-monogram { display: flex; align-items: center; justify-content: center; width: 43px; height: 43px; border-radius: 9px; border: 1px solid oklch(90.9624% 0.016259 347.663); background: oklch(97.4558% 0.005937 350.796); color: var(--accent); font-weight: 650; font-size: 0.875rem; flex: 0 0 43px; }
.customer-identity { flex: 1; min-width: 0; }
.customer-identity h2 { font-size: 0.875rem; overflow-wrap: anywhere; }
.customer-identity > span { display: block; color: var(--muted); font-size: 0.75rem; margin-top: 4px; }
.customer-summary-stats { display: flex; gap: 14px; align-items: center; }
.customer-progress-label { text-align: right; font-variant-numeric: tabular-nums; font-size: 1.125rem; line-height: 1.3; font-weight: 600; }
.customer-progress-label small { display: block; font-size: 0.75rem; color: var(--faint); font-weight: 400; margin-top: 4px; }
.customer-alert { display: inline-flex; gap: 3px; align-items: center; color: var(--danger); font-size: 0.75rem; }
.customer-no-alert { color: oklch(72.7455% 0.024662 161.490); }
.expand-chevron { display: flex; color: oklch(68.8032% 0.015663 244.810); transition: transform 150ms; }
.expanded .expand-chevron { transform: rotate(180deg); }
.customer-preview { border-top: 1px solid oklch(96.0194% 0.003434 247.859); margin: 0 22px; padding: 7px 0 14px; }
.customer-preview > a { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 0; font-size: 0.75rem; }
.customer-preview > a:hover > span:first-child { color: var(--accent); }
.customer-preview > .muted { display: block; font-size: 0.75rem; padding: 8px 0; }
.customer-preview > .text-button { font-size: 0.75rem; margin-top: 4px; }
.customer-card.expanded .customer-preview { display: none; }
.customer-contact { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 22px; background: oklch(98.7609% 0.001705 247.839); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); font-size: 0.75rem; color: var(--muted); }
.customer-contact > span, .customer-contact > div { display: flex; align-items: center; gap: 12px; }
.customer-contact > div { flex-wrap: wrap; max-width: 100%; }
.customer-contact a:hover { color: var(--accent); }
.customer-notes { font-size: 0.75rem; color: var(--muted); padding: 14px 22px; border-top: 1px solid var(--line); white-space: pre-wrap; }
.customer-notes strong { font-weight: 500; color: oklch(55.0201% 0.018510 245.286); }
.reason-cell { min-width: 190px; max-width: 400px; overflow-wrap: anywhere; line-height: 1.6; }
.document-link { display: flex; gap: 9px; align-items: center; font-size: 0.75rem; min-width: 180px; }
.document-link > .icon { color: oklch(69.8640% 0.020846 240.866); }
.document-link small { display: block; color: var(--faint); margin-top: 4px; font-size: 0.75rem; }
.user-cell { display: flex; gap: 10px; align-items: center; white-space: nowrap; }
.user-cell strong { font-weight: 500; }
.settings-grid { display: grid; grid-template-columns: minmax(220px, 330px) minmax(300px, 600px); gap: 22px; align-items: start; }
.profile-details { padding: 26px 24px; }
.profile-details h3 { margin-top: 15px; font-size: 1rem; }
.profile-details > p { font-size: 0.75rem; color: var(--muted); margin-top: 4px; }
.profile-details dl { margin-top: 24px; }
.profile-details dl > div { margin-top: 16px; }
dt { color: var(--muted); font-size: 0.75rem; }
dd { margin: 3px 0 0; font-size: 0.75rem; }
.settings-form { display: flex; flex-direction: column; gap: 19px; padding: 25px; }
.settings-form > .button { align-self: flex-start; margin-top: 4px; }
.back-link { display: inline-flex; gap: 6px; align-items: center; color: oklch(61.7377% 0.018777 242.598); font-size: 0.75rem; margin-bottom: 17px; }
.back-link:hover { color: var(--accent); }
.project-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 24px; }
.project-heading .eyebrow { font-size: 0.75rem; letter-spacing: .5px; }
.project-heading .eyebrow > span { color: oklch(79.0760% 0.012324 239.953); margin: 0 4px; }
.project-heading h1 { margin-top: 6px; font-size: 1.625rem; overflow-wrap: anywhere; }
.project-address { display: flex; align-items: center; gap: 5px; margin-top: 7px; font-size: 0.75rem; color: oklch(65.6940% 0.017447 239.250); }
.priority-label { color: var(--accent); font-size: 0.75rem; }
.project-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 22px 0 23px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); gap: 20px; }
.project-facts > div > span { display: block; font-size: 0.75rem; color: oklch(66.2136% 0.016953 248.084); margin-bottom: 6px; }
.project-facts strong { display: block; font-size: 0.75rem; font-weight: 500; font-variant-numeric: tabular-nums; line-height: 1.5; }
.project-facts strong small { display: block; font-size: 0.75rem; font-weight: 400; color: var(--muted); margin-top: 2px; }
.report-sent-mark { display: inline-flex; align-items: center; gap: 3px; margin-left: 6px; color: var(--success); font-size: 0.75rem; }
.project-fact-progress strong { display: flex; gap: 13px; align-items: center; }
.progress-track { appearance: none; border: none; height: 4px; background: oklch(92.9560% 0.005193 247.880); border-radius: 2px; flex: 1; max-width: 120px; color: var(--accent); }
.progress-track::-webkit-progress-bar { background: oklch(92.9560% 0.005193 247.880); border-radius: 2px; }
.progress-track::-webkit-progress-value { background: var(--accent); border-radius: 2px; }
.progress-track::-moz-progress-bar { background: var(--accent); border-radius: 2px; }
.tabs { display: flex; gap: 27px; margin-bottom: 24px; border-bottom: 1px solid var(--line); }
.tab { display: inline-flex; align-items: center; gap: 6px; padding: 17px 0 13px; border: none; border-bottom: 2px solid oklch(0% 0 0 / 0); background: oklch(0% 0 0 / 0); font-size: 0.75rem; font-weight: 500; color: oklch(64.7359% 0.018562 242.575); white-space: nowrap; }
.tab:hover { color: var(--ink); }
.tab.active { color: var(--accent); border-bottom-color: var(--accent); }
.tab > span { display: inline-flex; align-items: center; justify-content: center; padding: 1px 5px; border-radius: 4px; font-size: 0.75rem; color: var(--faint); background: oklch(94.3628% 0.005079 228.820); }
.tab.active > span { color: var(--accent); background: oklch(91.5946% 0.020201 354.023); }
.project-map-layout { display: grid; grid-template-columns: 335px minmax(0, 1fr); gap: 24px; align-items: start; }
.stage-map { min-width: 0; }
.map-heading { display: flex; align-items: center; justify-content: space-between; margin: 0 0 14px; }
.map-heading h2 { font-size: 0.8125rem; }
.map-heading > span { color: var(--faint); font-size: 0.75rem; }
.stage-card { position: relative; display: flex; align-items: center; gap: 11px; width: 100%; padding: 14px 13px; margin-bottom: 8px; text-align: left; background: oklch(100% 0 0); border: 1px solid var(--line); border-radius: 7px; transition: border-color 150ms, background-color 150ms; }
.stage-card:hover { border-color: oklch(83.2247% 0.011397 243.682); }
.stage-card.selected { background: oklch(98.0539% 0.005928 350.795); border-color: oklch(72.4327% 0.062739 356.136); }
.stage-number { width: 28px; height: 28px; flex: 0 0 28px; display: flex; align-items: center; justify-content: center; border-radius: 50%; background: oklch(96.5914% 0.002528 228.784); color: oklch(73.2259% 0.015193 238.096); font-size: 0.75rem; font-variant-numeric: tabular-nums; }
.stage-card-content { display: block; flex: 1; min-width: 0; }
.stage-card-content > strong { display: block; font-weight: 500; font-size: 0.75rem; color: oklch(53.4770% 0.020274 240.279); }
.stage-card-content > span { display: block; font-size: 0.75rem; color: oklch(73.0138% 0.015435 244.791); margin-top: 3px; }
.stage-card > .icon { color: oklch(75.6665% 0.011669 243.703); }
.stage-state-dot { width: 5px; height: 5px; border-radius: 50%; background: oklch(84.3915% 0.012128 239.936); flex: 0 0 5px; }
.stage-done .stage-number { background: oklch(96.0757% 0.009104 161.351); color: oklch(60.6004% 0.051310 162.678); }
.stage-done .stage-card-content > strong { color: oklch(50.6849% 0.031446 159.997); }
.stage-done .stage-state-dot { background: oklch(68.4601% 0.056838 160.477); }
.stage-progress .stage-number { background: oklch(92.9467% 0.018116 351.169); color: var(--accent); }
.stage-progress .stage-card-content > strong, .stage-card.selected .stage-card-content > strong { color: var(--ink); font-weight: 600; }
.stage-progress .stage-state-dot { background: var(--accent); }
.stage-waiting .stage-number { color: oklch(61.1809% 0.089080 81.163); background: oklch(95.6810% 0.020011 84.590); }
.stage-waiting .stage-state-dot { background: oklch(69.6421% 0.089133 79.269); }
.stage-blocked .stage-number { color: var(--danger); background: var(--danger-soft); }
.stage-blocked .stage-state-dot { background: var(--danger); }
.stage-card-content > .stage-card-reason { color: var(--danger); font-size: 0.75rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 210px; margin-top: 6px; }
.parallel-divider { position: relative; height: 29px; display: flex; align-items: center; justify-content: center; margin: 12px 0 6px; }
.parallel-divider::before { content: ""; position: absolute; top: 50%; left: 0; right: 0; height: 1px; border-top: 1px dashed oklch(86.5559% 0.012053 239.930); }
.parallel-divider > span { position: relative; background: var(--canvas); padding: 0 10px; color: oklch(66.6822% 0.017385 239.243); font-size: 0.75rem; text-transform: uppercase; letter-spacing: .6px; }
.stage-detail { scroll-margin-top: 20px; }
.stage-detail-header { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 23px 25px 20px; }
.stage-detail-header .eyebrow { font-size: 0.75rem; letter-spacing: .6px; margin-bottom: 5px; color: oklch(62.5457% 0.037153 349.686); }
.stage-detail-header h2 { font-size: 1.1875rem; }
.stage-info-note { font-size: 0.75rem; line-height: 1.65; background: oklch(97.7894% 0.002520 228.784); border-top: 1px solid oklch(95.3424% 0.004197 236.498); border-bottom: 1px solid oklch(95.3424% 0.004197 236.498); color: oklch(61.2897% 0.018602 236.888); padding: 13px 25px; }
.blocker-note { display: flex; align-items: flex-start; gap: 9px; background: oklch(96.7011% 0.011920 10.991); border: 1px solid oklch(91.3475% 0.024788 5.125); border-radius: 6px; padding: 13px 15px; color: oklch(50.8711% 0.109860 13.455); font-size: 0.75rem; line-height: 1.65; }
.blocker-note strong { display: block; font-size: 0.75rem; font-weight: 600; }
.blocker-note p { margin-top: 3px; white-space: pre-wrap; overflow-wrap: anywhere; }
.stage-detail > .blocker-note { margin: 17px 25px 0; }
.stage-settings { padding: 18px 25px 19px; border-bottom: 1px solid var(--line); }
.stage-settings .form-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 13px; }
.stage-settings .field { gap: 5px; }
.stage-settings .field > span { font-size: 0.75rem; color: oklch(62.2518% 0.020393 237.972); font-weight: 400; }
.stage-settings input, .stage-settings select { font-size: 0.75rem; height: 33px; padding: 5px 8px; }
.stage-settings .field:has(textarea) { grid-column: 1 / -1; }
.stage-settings textarea { min-height: 58px; font-size: 0.75rem; padding: 7px 9px; }
.stage-settings small { font-size: 0.75rem; }
.stage-settings-footer { display: flex; align-items: center; justify-content: space-between; margin-top: 14px; }
.stage-settings-footer > span { color: var(--faint); font-size: 0.75rem; }
.client-stage-meta { display: flex; gap: 40px; padding: 0 25px 22px; border-bottom: 1px solid var(--line); }
.client-stage-meta dt { font-size: 0.75rem; }
.client-stage-meta dd { font-size: 0.75rem; }
.stage-section { padding: 23px 25px 20px; border-bottom: 1px solid var(--line); }
.stage-section:last-child { border-bottom: none; }
.section-heading { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 15px; }
.section-heading h3 { font-size: 0.75rem; }
.section-heading > span { color: var(--faint); font-size: 0.75rem; }
.task-list { display: flex; flex-direction: column; gap: 13px; }
.task-item { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; }
.task-item > input { margin-top: 2px; width: 15px; height: 15px; flex-basis: 15px; }
.task-item > span { display: block; min-width: 0; }
.task-item strong { font-size: 0.75rem; font-weight: 400; }
.task-item small { display: block; font-size: 0.75rem; color: oklch(71.4003% 0.016897 154.337); margin-top: 3px; }
.task-item.complete strong { color: oklch(59.7267% 0.023993 158.179); }
.section-hint { color: oklch(68.3987% 0.016464 241.883); font-size: 0.75rem; line-height: 1.7; margin-top: 15px; }
.file-list { display: flex; flex-direction: column; }
.panel > .file-list { padding: 4px 22px; }
.panel > .small-empty { padding: 22px; }
.file-item { display: flex; align-items: center; gap: 11px; padding: 12px 0; border-bottom: 1px solid oklch(95.3424% 0.004197 236.498); }
.file-item:last-child { border-bottom: none; }
.file-item:hover .file-name { color: var(--accent); }
.file-icon { display: flex; align-items: center; justify-content: center; width: 31px; height: 35px; border-radius: 5px; background: oklch(96.2726% 0.005147 247.877); color: oklch(67.9077% 0.020990 240.882); flex: 0 0 auto; }
.file-name { font-size: 0.75rem; font-weight: 500; flex: 1; min-width: 0; overflow-wrap: anywhere; }
.file-name small { display: block; font-size: 0.75rem; color: oklch(69.5818% 0.019035 240.122); font-weight: 400; margin-top: 4px; }
.file-item > .icon { color: oklch(70.4799% 0.019800 237.899); }
.comments { display: flex; flex-direction: column; gap: 20px; margin-bottom: 22px; }
.comment { display: flex; align-items: flex-start; gap: 10px; }
.comment > .avatar { width: 26px; height: 26px; font-size: 0.75rem; }
.comment-content { min-width: 0; flex: 1; }
.comment-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; line-height: 1.5; }
.comment-meta strong { font-size: 0.75rem; font-weight: 600; }
.comment-meta > span { font-size: 0.75rem; color: oklch(71.3243% 0.016296 241.866); }
.comment-content p { font-size: 0.75rem; margin-top: 4px; line-height: 1.75; white-space: pre-wrap; overflow-wrap: anywhere; color: oklch(55.4717% 0.020955 238.052); }
.comment.internal { background: oklch(97.0997% 0.003977 286.325); border: 1px solid oklch(95.0545% 0.006669 286.272); border-radius: 6px; padding: 11px; }
.comment-meta > .internal-label { color: oklch(61.3402% 0.033071 291.649); background: oklch(93.2119% 0.012228 296.342); padding: 1px 5px; border-radius: 3px; font-size: 0.75rem; }
.comment-form textarea { width: 100%; border: 1px solid var(--line-strong); border-radius: 6px; padding: 11px 12px; font-size: 0.75rem; min-height: 85px; }
.comment-controls { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 9px; }
.comment-controls select { border: 0; background: oklch(0% 0 0 / 0); color: var(--muted); font-size: 0.75rem; max-width: 190px; padding: 5px 3px; }
.comment-visibility { font-size: 0.75rem; color: var(--faint); }
.government-status-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 15px 22px; background: oklch(98.7609% 0.001705 247.839); border-bottom: 1px solid var(--line); font-size: 0.75rem; color: oklch(62.3291% 0.019547 240.181); }
.government-status-row > span { display: flex; align-items: center; gap: 7px; }
.request-list { padding: 7px 24px 15px; }
.request-card { padding: 23px 0; border-bottom: 1px solid var(--line); }
.request-card:last-child { border: 0; }
.request-card-heading { display: flex; align-items: flex-start; gap: 13px; }
.request-symbol { display: flex; align-items: center; justify-content: center; width: 39px; height: 39px; flex: 0 0 39px; background: oklch(96.2441% 0.004188 236.497); color: oklch(68.0497% 0.021691 234.023); border-radius: 7px; }
.request-card-heading > div { flex: 1; min-width: 0; }
.request-card-heading h3 { font-size: 0.8125rem; }
.request-card-heading p { font-size: 0.75rem; color: var(--muted); margin-top: 4px; overflow-wrap: anywhere; }
.request-card-heading > .badge { margin-top: 5px; }
.request-dates { display: flex; gap: 45px; margin: 15px 0 0 52px; }
.request-dates dt { font-size: 0.75rem; }
.request-dates dd { font-size: 0.75rem; }
.request-response { margin: 16px 0 0 52px; padding: 13px 15px; background: oklch(97.7894% 0.002520 228.784); border-radius: 6px; }
.request-response strong { display: block; color: oklch(61.2468% 0.020472 237.982); font-size: 0.75rem; font-weight: 500; }
.request-response p { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 0.75rem; color: oklch(54.3963% 0.022974 238.990); line-height: 1.75; margin-top: 5px; }
.activity-list { list-style: none; padding: 10px 25px 23px; margin: 0; }
.activity-list li { display: flex; gap: 16px; position: relative; padding: 13px 0 20px; }
.activity-list li::after { content: ""; position: absolute; left: 4px; top: 27px; bottom: -11px; width: 1px; background: oklch(94.0898% 0.005911 239.823); }
.activity-list li:last-child::after { display: none; }
.activity-dot { width: 9px; height: 9px; flex: 0 0 9px; border-radius: 50%; border: 2px solid oklch(100% 0 0); box-shadow: 0 0 0 1px oklch(88.9833% 0.011072 234.834); background: oklch(74.6221% 0.021318 238.777); margin-top: 5px; }
.activity-list p { font-size: 0.75rem; line-height: 1.6; color: oklch(50.7599% 0.025103 235.438); white-space: pre-wrap; overflow-wrap: anywhere; }
.activity-list div > span { display: block; font-size: 0.75rem; color: oklch(70.0278% 0.016370 241.874); margin-top: 5px; }
.inline-note { background: oklch(97.2191% 0.003423 247.858); border: 1px solid oklch(93.4854% 0.005920 239.823); border-radius: 6px; font-size: 0.75rem; color: oklch(61.0666% 0.018827 242.604); line-height: 1.7; padding: 13px 15px; }
.project-heading + .inline-note { margin-bottom: 18px; }
.field { display: flex; flex-direction: column; gap: 7px; font-size: 0.75rem; }
.field > span { font-weight: 500; }
.field input, .field textarea, .field select { display: block; width: 100%; min-width: 0; padding: 9px 11px; border: 1px solid var(--line-strong); border-radius: 6px; background-color: oklch(100% 0 0); font-size: 0.75rem; }
.field input, .field select { height: 39px; }
.field textarea { line-height: 1.65; }
.field input:focus, .field select:focus, .field textarea:focus, .comment-form textarea:focus { border-color: oklch(67.2368% 0.070753 356.333); outline: 2px solid oklch(91.7060% 0.021734 351.932); outline-offset: 0; }
.field input[type="file"] { height: auto; min-height: 65px; padding: 12px; font-size: 0.75rem; }
.field input[type="file"]::file-selector-button { background: oklch(96.3197% 0.003431 247.859); border: 1px solid oklch(90.0509% 0.009439 242.849); border-radius: 4px; padding: 6px 9px; font: inherit; cursor: pointer; margin-right: 10px; }
.field small { color: var(--faint); font-size: 0.75rem; line-height: 1.65; font-weight: 400; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 17px; }
.form-error { color: var(--danger); background: var(--danger-soft); border: 1px solid oklch(89.3367% 0.030278 359.567); padding: 10px 13px; border-radius: 5px; font-size: 0.75rem; line-height: 1.7; white-space: pre-wrap; margin-top: 12px; }
.form-dialog { position: fixed; padding: 0; border: 1px solid oklch(90.6314% 0.008490 236.570); border-radius: 12px; width: min(490px, calc(100vw - 32px)); max-height: calc(100dvh - 60px); color: var(--ink); box-shadow: 0 25px 95px oklch(21.1185% 0.040132 264.039 / 0.239216); background: oklch(100% 0 0); overflow-y: auto; }
.form-dialog.wide { width: min(660px, calc(100vw - 32px)); }
.form-dialog::backdrop { background: oklch(26.9831% 0.023633 241.130 / 0.329412); backdrop-filter: blur(2px); }
.dialog-header { padding: 24px 25px 20px; display: flex; justify-content: space-between; gap: 17px; border-bottom: 1px solid var(--line); }
.dialog-header h2 { font-size: 1.1875rem; }
.dialog-header p { color: var(--muted); font-size: 0.75rem; margin-top: 7px; line-height: 1.7; max-width: 52ch; }
.dialog-header > .icon-button { flex: 0 0 28px; width: 28px; height: 28px; }
.dialog-body { display: flex; flex-direction: column; gap: 18px; padding: 23px 25px; }
.dialog-footer { display: flex; align-items: center; justify-content: flex-end; gap: 9px; position: sticky; bottom: 0; padding: 17px 25px; background: oklch(100% 0 0); border-top: 1px solid var(--line); }
.client-customer-field .section-hint { margin-top: 8px; }
.toasts { position: fixed; bottom: 25px; left: 50%; transform: translate(-50%, 10px); z-index: 100; display: flex; gap: 10px; align-items: center; max-width: min(580px, calc(100vw - 30px)); padding: 13px 18px; border-radius: 8px; background: oklch(33.0710% 0.020221 165.390); box-shadow: 0 8px 30px oklch(30.0771% 0.018463 161.216 / 0.141176); color: oklch(100% 0 0); font-size: 0.75rem; opacity: 0; visibility: hidden; transition: opacity 180ms, transform 180ms, visibility 180ms; }
.toasts.visible { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.toasts.error { background: oklch(42.0611% 0.095643 11.151); }
.skeleton-group { display: flex; flex-direction: column; gap: 15px; padding: 4px 0; }
.skeleton { background: oklch(94.3916% 0.005906 239.822); border-radius: 6px; animation: skeleton-pulse 1.2s ease-in-out infinite alternate; }
.skeleton-title { width: 250px; height: 31px; }
.skeleton-line { width: 380px; max-width: 80%; height: 14px; margin-bottom: 15px; }
.skeleton-card { height: 130px; background: oklch(95.3424% 0.004197 236.498); }
@keyframes skeleton-pulse { from { opacity: .6; } to { opacity: 1; } }
.auth-layout { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); min-height: 100vh; background: oklch(100% 0 0); }
.auth-intro { background: oklch(28.1281% 0.009017 234.026); padding: 45px 65px 32px; display: flex; flex-direction: column; color: oklch(96.8913% 0.002526 228.784); }
.auth-brand { display: inline-flex; align-items: center; gap: 11px; font-size: 1.25rem; font-weight: 600; }
.auth-brand .brand-mark { width: 39px; height: 39px; font-size: 1.75rem; }
.auth-story { margin: auto 0; padding: 70px 0; }
.auth-story .eyebrow { color: oklch(72.9806% 0.031255 350.836); font-size: 0.75rem; letter-spacing: 1px; line-height: 1.7; }
.auth-story h1 { font-size: 2.6875rem; line-height: 1.3; font-weight: 550; letter-spacing: -1.4px; margin: 20px 0 23px; }
.auth-description { color: oklch(72.4619% 0.017874 236.799); font-size: 0.8125rem; line-height: 1.9; max-width: 420px; }
.auth-track { display: flex; align-items: center; margin: 36px 0; max-width: 220px; }
.auth-track-dot { width: 23px; height: 23px; flex: 0 0 23px; border: 1px solid oklch(48.6838% 0.017878 242.059); border-radius: 50%; display: flex; align-items: center; justify-content: center; background: oklch(34.7255% 0.015033 240.362); }
.auth-track-dot.complete { color: oklch(74.5595% 0.045867 160.589); background: oklch(37.8348% 0.029487 161.627); border-color: oklch(51.1137% 0.041461 159.458); }
.auth-track-dot.active { border-color: oklch(60.3253% 0.116975 0.936); background: oklch(39.3154% 0.052169 353.448); box-shadow: inset 0 0 0 6px oklch(31.5684% 0.011878 314.644); }
.auth-track-line { flex: 1; height: 1px; background: oklch(46.9230% 0.039240 344.046); }
.auth-track-line.muted { background: oklch(43.5600% 0.019235 239.521); }
.auth-points { display: flex; flex-direction: column; gap: 11px; color: oklch(72.9045% 0.015209 238.098); font-size: 0.75rem; }
.auth-points > span { display: flex; align-items: center; gap: 9px; }
.auth-points .icon { color: oklch(65.7222% 0.061985 352.382); }
.auth-footnote { color: oklch(63.2528% 0.020316 237.962); font-size: 0.75rem; }
.auth-form-section { display: flex; align-items: center; justify-content: center; padding: 50px 55px; }
.auth-form-wrap { width: 100%; max-width: 370px; }
.auth-form-wrap .eyebrow { font-size: 0.75rem; color: var(--accent); }
.auth-form-wrap h2 { font-size: 1.6875rem; letter-spacing: -.6px; margin-top: 9px; font-weight: 600; }
.auth-form-wrap > .muted { margin-top: 10px; font-size: 0.75rem; line-height: 1.8; }
.auth-form { margin-top: 29px; display: flex; flex-direction: column; gap: 18px; }
.auth-form .field > span { font-size: 0.75rem; }
.auth-form .field input { height: 43px; }
.auth-form .check-option { margin-top: -4px; font-size: 0.75rem; }
.auth-submit { width: 100%; justify-content: space-between; padding: 11px 15px; min-height: 44px; margin-top: 4px; }
.auth-form .form-error { margin-top: 0; }
.auth-support { display: flex; align-items: flex-start; justify-content: center; gap: 6px; text-align: center; margin-top: 22px; font-size: 0.75rem; color: oklch(71.0458% 0.014481 241.042); line-height: 1.7; }
.auth-support .icon { margin-top: 2px; }
.auth-mobile-brand { display: none; }
.metric > span, .onboarding-number, th, .table-secondary, .badge-pending,
.government-indicator, .count-label, .inline-count, .stage-card-content > span,
.stage-number, .stage-settings .field > span, .stage-info-note,
.section-hint, .task-item small, .file-name small, .comment-meta > span,
.comment-content p, .government-status-row, .request-response strong,
.activity-list div > span, .project-facts > div > span,
.project-address, .project-heading .eyebrow, .auth-support {
  color: var(--muted);
}
.mini-step.step-pending { color: var(--muted); }
@media (min-width: 1600px) {
  .overview-grid { grid-template-columns: minmax(0, 1fr) 335px; }
  .project-map-layout { grid-template-columns: 355px minmax(0, 1fr); gap: 32px; }
  .stage-detail-header, .stage-section { padding-left: 30px; padding-right: 30px; }
}
@media (max-width: 1280px) {
  .sidebar { width: 210px; padding-left: 10px; padding-right: 10px; }
  .workspace-body { margin-left: 210px; }
  .main { padding-left: 25px; padding-right: 25px; }
  .topbar { padding: 0 25px; }
  .metric { padding-left: 15px; padding-right: 15px; }
  .metric > span { font-size: 0.75rem; }
  .overview-grid { grid-template-columns: minmax(0, 1fr); }
  .attention-preview-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
  .attention-preview-item { border: none; }
  .attention-preview-item:nth-child(n + 4) { display: none; }
  .calm-state { flex-direction: row; text-align: left; gap: 12px; padding: 22px; }
  .calm-state > span { width: 35px; height: 35px; flex: 0 0 35px; margin: 0; }
  .calm-state p { max-width: none; margin: 0 0 0 auto; }
  .customer-summary { padding: 18px; gap: 10px; }
  .customer-summary-stats { gap: 8px; }
  .customer-progress-label { font-size: 1rem; }
  .customer-progress-label small { max-width: 70px; }
  .customer-identity h2 { font-size: 0.8125rem; }
  .project-map-layout { grid-template-columns: 290px minmax(0, 1fr); gap: 18px; }
  .stage-card { padding: 13px 10px; gap: 9px; }
  .stage-card-content > strong { font-size: 0.75rem; }
  .stage-number { width: 26px; height: 26px; flex-basis: 26px; }
  .stage-detail-header, .stage-section, .stage-settings { padding-left: 20px; padding-right: 20px; }
  .stage-settings .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stage-settings .field:nth-child(3) { grid-column: 1 / -1; }
  .stage-detail-header h2 { font-size: 1.0625rem; }
  .project-facts { grid-template-columns: repeat(3, 1fr); row-gap: 17px; }
  .auth-intro { padding-left: 50px; padding-right: 40px; }
}
@media (max-width: 1000px) {
  .customer-grid { grid-template-columns: 1fr; }
  .metrics { grid-template-columns: repeat(2, 1fr); }
  .metric > span { font-size: 0.75rem; }
  .onboarding { gap: 35px; padding: 30px; }
  .onboarding-content h2 { font-size: 1.3125rem; }
  .page-heading { align-items: flex-start; }
  .heading-actions { justify-content: flex-end; }
  .project-map-layout { grid-template-columns: 245px minmax(0, 1fr); }
  .stage-card .stage-state-dot { display: none; }
  .stage-card { padding: 12px 9px; }
  .stage-card-content > strong { font-size: 0.75rem; }
  .stage-card-content > span { font-size: 0.75rem; }
  .stage-number { width: 22px; height: 22px; flex-basis: 22px; font-size: 0.75rem; }
  .stage-detail-header { align-items: flex-start; }
  .stage-detail-header > .badge { font-size: 0.75rem; margin-top: 4px; }
  .stage-detail-header h2 { font-size: 0.9375rem; }
  .stage-detail-header .eyebrow { font-size: 0.75rem; }
  .stage-settings, .stage-section, .stage-detail-header { padding-left: 15px; padding-right: 15px; }
  .stage-info-note { padding: 12px 15px; font-size: 0.75rem; }
  .stage-detail > .blocker-note { margin-left: 15px; margin-right: 15px; }
  .stage-settings-footer > span { max-width: 120px; }
  .settings-grid { grid-template-columns: 1fr; max-width: 640px; }
  .profile-details { display: grid; grid-template-columns: 60px 1fr; column-gap: 18px; }
  .profile-details > .avatar { grid-row: 1 / 3; }
  .profile-details h3 { margin-top: 5px; }
  .profile-details dl { grid-column: 1 / -1; display: flex; gap: 25px; flex-wrap: wrap; margin-top: 10px; }
  .auth-story h1 { font-size: 2.25rem; }
  .auth-intro { padding-left: 35px; padding-right: 30px; }
  .auth-form-section { padding-left: 35px; padding-right: 35px; }
}
@media (max-width: 850px) {
  .sidebar { width: 225px; transform: translateX(-100%); transition: transform 180ms; box-shadow: 0 0 40px oklch(19.8331% 0.043024 262.971 / 0.101961); }
  .menu-open .sidebar { transform: translateX(0); }
  .sidebar-overlay { position: fixed; inset: 0; z-index: 25; background: oklch(26.0295% 0.031288 241.848 / 0.466667); border: 0; }
  .workspace-body { margin-left: 0; }
  .mobile-menu { display: inline-flex; }
  .topbar { padding-left: 17px; padding-right: 22px; }
  .main { padding: 26px 22px 35px; }
  .topbar-start { gap: 9px; }
  .project-map-layout { grid-template-columns: 290px minmax(0, 1fr); }
  .stage-card .stage-state-dot { display: block; }
  .stage-card-content > strong { font-size: 0.75rem; }
  .stage-number { width: 26px; height: 26px; flex-basis: 26px; }
  .stage-card-content > span { font-size: 0.75rem; }
  .page-heading h1, .project-heading h1 { font-size: 1.5rem; }
  .auth-layout { grid-template-columns: .95fr 1fr; }
  .auth-story h1 { font-size: 2rem; }
  .auth-intro { padding: 35px 27px; }
  .auth-form-section { padding: 35px 28px; }
  .auth-form-wrap h2 { font-size: 1.5rem; }
}
@media (max-width: 700px) {
  .main { padding-left: 18px; padding-right: 18px; }
  .topbar { height: 58px; padding-right: 18px; padding-left: 11px; }
  .topbar-end { gap: 6px; }
  .today-label { display: none; }
  .breadcrumb-label { display: none; }
  .topbar-start > .icon { display: none; }
  .page-heading { flex-direction: column; gap: 15px; margin-bottom: 21px; }
  .heading-actions { justify-content: flex-start; }
  .metrics { gap: 10px; margin-bottom: 18px; }
  .metric { padding: 14px; }
  .metric-label { font-size: 0.75rem; }
  .metric strong { font-size: 1.75rem; margin-top: 6px; }
  .metric > span { font-size: 0.75rem; }
  .metric-label > .icon { width: 15px; height: 15px; }
  .overview-grid { gap: 17px; }
  .panel-heading { padding: 16px 17px; }
  .panel-heading p { font-size: 0.75rem; }
  .panel-heading h2 { font-size: 0.8125rem; }
  .panel-heading .text-link { font-size: 0.75rem; }
  .attention-preview-list { grid-template-columns: 1fr; gap: 0; }
  .attention-preview-item { border-bottom: 1px solid var(--line); }
  .attention-preview-item:nth-child(n + 4) { display: flex; }
  .calm-state { align-items: flex-start; flex-wrap: wrap; gap: 10px; padding: 20px; }
  .calm-state strong { margin-top: 7px; }
  .calm-state p { flex-basis: 100%; margin-left: 45px; font-size: 0.75rem; }
  .workflow-note { padding: 13px; font-size: 0.75rem; }
  .workflow-note > .icon { width: 16px; height: 16px; }
  .onboarding { grid-template-columns: 1fr; gap: 25px; padding: 27px; }
  .onboarding-content h2 { font-size: 1.375rem; margin-top: 10px; }
  .onboarding-content p { font-size: 0.75rem; margin-bottom: 18px; }
  .onboarding-steps { border-top: 1px solid var(--line); padding-top: 23px; gap: 20px; }
  .onboarding-steps::before { top: 52px; bottom: 30px; }
  .filters { gap: 8px; margin-bottom: 17px; }
  .search-field { width: 100%; }
  .filter-select { flex: 1 1 130px; }
  .filter-select select { width: 100%; max-width: none; }
  .archive-filter { margin-left: 3px; }
  .customer-summary { padding: 18px 16px; }
  .customer-preview { margin-left: 16px; margin-right: 16px; }
  .customer-progress-label small { display: none; }
  .customer-progress-label { font-size: 0.9375rem; }
  .customer-no-alert { display: none; }
  .customer-summary-stats { gap: 10px; }
  .customer-contact { align-items: flex-start; flex-direction: column; padding: 13px 16px; }
  .customer-contact > span { flex-wrap: wrap; gap: 8px; }
  .customer-contact > div { gap: 7px; }
  .pipeline-legend { display: none; }
  .project-heading { align-items: flex-start; flex-direction: column; gap: 17px; }
  .project-facts { grid-template-columns: 1fr 1fr; gap: 17px; padding: 20px 0; }
  .project-facts > div > span { font-size: 0.75rem; }
  .project-facts strong { font-size: 0.75rem; }
  .project-facts strong small { font-size: 0.75rem; }
  .project-fact-progress { grid-column: 1 / -1; }
  .project-fact-progress strong .progress-track { max-width: 160px; }
  .tabs { gap: 22px; overflow-x: auto; margin-bottom: 20px; }
  .tab { font-size: 0.75rem; padding-top: 15px; }
  .project-map-layout { grid-template-columns: 1fr; gap: 20px; }
  .stage-map { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
  .map-heading, .parallel-divider { grid-column: 1 / -1; }
  .map-heading { margin-bottom: 5px; }
  .stage-card { margin: 0; padding: 11px 9px; gap: 7px; align-items: flex-start; min-height: 65px; }
  .stage-number { width: 21px; height: 21px; flex-basis: 21px; font-size: 0.75rem; }
  .stage-card-content > strong { font-size: 0.75rem; line-height: 1.4; margin-top: 2px; }
  .stage-card-content > span { font-size: 0.75rem; margin-top: 5px; }
  .stage-card > .icon, .stage-card .stage-state-dot { display: none; }
  .stage-card-content > .stage-card-reason { max-width: 125px; font-size: 0.75rem; }
  .parallel-divider { margin: 9px 0 0; height: 22px; }
  .parallel-divider + .stage-card { grid-column: 1 / -1; }
  .stage-detail-header, .stage-section, .stage-settings { padding-left: 20px; padding-right: 20px; }
  .stage-detail-header h2 { font-size: 1.125rem; }
  .stage-detail-header .eyebrow { font-size: 0.75rem; }
  .stage-detail-header > .badge { font-size: 0.75rem; }
  .stage-settings .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stage-info-note { padding-left: 20px; padding-right: 20px; }
  .stage-detail > .blocker-note { margin-left: 20px; margin-right: 20px; }
  .stage-settings-footer > span { max-width: none; }
  .task-item strong, .comment-content p { font-size: 0.75rem; }
  .task-list { gap: 15px; }
  .government-status-row { align-items: flex-start; flex-direction: column; padding: 15px 17px; gap: 8px; }
  .request-list { padding-left: 17px; padding-right: 17px; }
  .request-card-heading { flex-wrap: wrap; gap: 10px; }
  .request-card-heading > div { flex-basis: calc(100% - 50px); }
  .request-card-heading > .badge { margin-left: 49px; }
  .request-card-heading > .icon-button { margin-left: auto; margin-top: -2px; }
  .request-dates { margin-left: 49px; gap: 20px; }
  .request-dates dd { font-size: 0.75rem; }
  .request-response { margin-left: 0; }
  .workspace-footer { padding-left: 18px; padding-right: 18px; font-size: 0.75rem; gap: 18px; }
  .workspace-footer > span:last-child { text-align: right; max-width: 200px; }
  .auth-layout { display: block; background: oklch(100% 0 0); min-height: 100dvh; }
  .auth-intro { display: none; }
  .auth-form-section { min-height: 100dvh; padding: 35px 30px; }
  .auth-mobile-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 45px; font-size: 1.25rem; font-weight: 600; }
  .auth-form-wrap h2 { font-size: 1.625rem; }
  .form-dialog { max-height: calc(100dvh - 30px); width: calc(100vw - 24px); border-radius: 9px; }
  .form-dialog.wide { width: calc(100vw - 24px); }
  .dialog-header, .dialog-body { padding-left: 20px; padding-right: 20px; }
  .dialog-header h2 { font-size: 1.125rem; }
  .dialog-footer { padding-left: 20px; padding-right: 20px; }
  .toasts { font-size: 0.75rem; bottom: 17px; padding: 12px 14px; width: max-content; }
}
@media (max-width: 380px) {
  .main { padding-left: 13px; padding-right: 13px; }
  .customer-progress-label { display: none; }
  .form-grid { grid-template-columns: 1fr; }
  .metric-label { font-size: 0.75rem; }
  .metric { padding: 12px; }
  .metric > span { font-size: 0.75rem; }
  .onboarding { padding: 22px; }
  .stage-card-content > strong { font-size: 0.75rem; }
  .stage-number { width: 19px; height: 19px; flex-basis: 19px; }
  .stage-detail-header, .stage-section, .stage-settings { padding-left: 16px; padding-right: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* Readable product typography follows browser text-size and user zoom. */
.button, .button.small, .text-button, .text-link, .nav-item,
.filter-select select, .search-field input, .check-option,
table, .object-link, .current-stage-name, .customer-preview > a,
.field, .field > span, .field input, .field textarea, .field select,
.stage-settings .field > span, .stage-settings input, .stage-settings select,
.stage-settings textarea, .task-item strong, .tab, .section-heading h3,
.stage-card-content > strong, .map-heading h2, .comment-controls select,
.auth-form .field > span, .auth-form .check-option,
.customer-identity h2, .onboarding-step strong, .request-card-heading h3,
.profile-name, .file-name, .document-link, .notification-item strong,
.project-facts strong, .client-stage-meta dd, .request-dates dd,
.comment-meta strong, .auth-points, .toasts {
  font-size: 0.875rem;
}
.badge, .stage-detail-header > .badge { font-size: 0.75rem; }
.stage-card-content > span, .stage-card-content > .stage-card-reason,
.stage-settings small, .stage-card-status { font-size: 0.75rem; }
.stage-card-status { font-weight: 600; }
.task-item small, .table-secondary, .government-indicator,
.heading-actions .government-indicator, .manager-cell { font-size: 0.75rem; }
.page-heading p, .panel-heading p, .onboarding-content p,
.empty-state p, .workflow-note, .stage-info-note, .blocker-note,
.comment-content p, .request-card-heading p, .request-response p,
.customer-notes, .auth-description, .auth-form-wrap > .muted,
.small-empty, .inline-note, .attention-preview-item p,
.onboarding-step p, .calm-state p, .dialog-header p,
.activity-list p, .form-error, .notification-item span {
  font-size: 1rem;
}
.comment-form textarea { font-size: 1rem; }
.field input, .field select { height: auto; min-height: 2.5rem; }
.stage-settings input, .stage-settings select { height: auto; min-height: 2.25rem; }
.auth-form .field input { height: auto; min-height: 2.75rem; }
.workspace-footer, .pipeline-legend, .attention-preview-item p,
.stage-card-content > .stage-card-reason, .request-card-heading p,
.workflow-note, .back-link, .tab, .parallel-divider > span,
.task-item.complete strong {
  color: var(--muted);
}
.nav-caption, .auth-footnote { color: var(--sidebar-muted); }
.stage-detail-header .eyebrow { color: var(--accent); }
.comment-meta > .internal-label { color: oklch(47% 0.033071 291.649); }
.mini-step.step-done { color: var(--success); }
.mini-step.step-progress { color: var(--accent); }
.mini-step.step-waiting { color: oklch(49.2039% 0.098185 73.473); }
.mini-step.step-blocked { color: oklch(47.6159% 0.126347 14.337); }
@media (max-width: 700px) {
  .stage-map { grid-template-columns: 1fr; gap: 8px; }
  .stage-card { padding: 14px 13px; min-height: 70px; align-items: center; gap: 11px; }
  .stage-number { width: 28px; height: 28px; flex-basis: 28px; }
  .stage-card-content > .stage-card-reason { max-width: none; white-space: normal; }
  .stage-card > .icon { display: inline-block; }
  .stage-card .stage-state-dot { display: block; }
  .metrics { grid-template-columns: 1fr 1fr; }
  .metric-label { font-size: 0.875rem; }
  .metric > span { font-size: 0.75rem; }
  .metric-label > .icon { display: none; }
  .button { min-height: 2.625rem; }
  .button.small { min-height: 2.375rem; }
  .field input, .field select, .field textarea,
  .stage-settings input, .stage-settings select, .stage-settings textarea,
  .filter-select select, .search-field input { font-size: 1rem; }
  .filter-select select, .search-field input { height: auto; min-height: 2.5rem; }
}

.photo-report .panel-heading { align-items: flex-start; flex-wrap: wrap; }
.photo-report .panel-heading > div { flex: 1 1 250px; min-width: 0; }
.photo-report h2 { overflow-wrap: anywhere; }
.photo-toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: 13px; padding: 18px 22px 0; }
.photo-toolbar > span { font-size: 0.75rem; color: var(--muted); }
.photo-nda-note { display: flex; align-items: flex-start; flex-wrap: wrap; gap: 10px; padding: 18px 22px; background: var(--surface-soft); border-bottom: 1px solid var(--line); color: var(--muted); }
.photo-nda-note > .icon { margin-top: 4px; }
.photo-nda-note p { flex: 1 1 230px; font-size: 1rem; line-height: 1.7; }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr)); gap: 20px; padding: 22px; }
.photo-card { margin: 0; min-width: 0; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; align-self: start; background: var(--surface); }
.photo-thumbnail { position: relative; display: block; padding: 0; width: 100%; aspect-ratio: 4 / 3; overflow: hidden; border: 0; background: var(--canvas); cursor: zoom-in; }
.photo-thumbnail:hover { box-shadow: inset 0 0 0 2px var(--accent); }
.photo-thumbnail:focus-visible { outline-offset: -4px; outline-width: 3px; }
.photo-thumbnail img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-watermark { position: absolute; bottom: 11px; left: 11px; right: 11px; width: fit-content; max-width: calc(100% - 22px); padding: 4px 7px; border-radius: 4px; color: oklch(100% 0 0); background: oklch(20% 0.008 243 / 0.78); font-size: 0.75rem; line-height: 1.5; pointer-events: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.photo-card figcaption { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 16px; min-width: 0; }
.photo-zone { font-size: 0.75rem; color: var(--accent); background: var(--accent-soft); padding: 2px 7px; border-radius: 4px; }
.photo-caption { font-size: 1rem; font-weight: 500; line-height: 1.55; overflow-wrap: anywhere; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }
.photo-meta { font-size: 0.75rem; color: var(--muted); line-height: 1.65; overflow-wrap: anywhere; }
.photo-load-error { position: absolute; inset: 0; display: grid; place-items: center; padding: 25px; font-size: 0.875rem; text-align: center; color: var(--muted); background: var(--canvas); }
.photo-viewer { padding: 0; width: min(1100px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface); color: var(--ink); overflow: auto; }
.photo-viewer::backdrop { background: oklch(23% 0.008 243 / 0.76); }
.photo-viewer-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 18px 22px; }
.photo-viewer-header > div { min-width: 0; }
.photo-viewer-header h2 { font-size: 1.125rem; overflow-wrap: anywhere; }
.photo-viewer-header p { margin-top: 5px; color: var(--muted); font-size: 0.75rem; }
.photo-viewer-header > .icon-button { flex: 0 0 34px; }
.photo-viewer-image { position: relative; display: flex; align-items: center; justify-content: center; min-height: 160px; background: oklch(25% 0.01 243); }
.photo-viewer-image img { display: block; width: 100%; height: auto; max-height: 62dvh; object-fit: contain; }
.photo-viewer-image .photo-load-error { color: oklch(100% 0 0); background: oklch(25% 0.01 243); }
.photo-viewer-footer { display: flex; align-items: flex-start; flex-wrap: wrap; justify-content: space-between; gap: 20px; padding: 19px 22px; }
.photo-viewer-footer > div:first-child { flex: 1 1 350px; min-width: 0; }
.photo-viewer-caption { font-size: 1rem; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.7; max-height: 8rem; overflow: auto; margin-bottom: 7px; }
.photo-viewer-controls { display: flex; gap: 9px; align-items: center; flex-wrap: wrap; }
.photo-upload-progress { border: 1px solid var(--line); border-radius: 7px; padding: 14px; background: var(--surface-soft); }
.photo-progress-heading { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.photo-progress-heading strong { font-size: 0.875rem; font-weight: 500; }
.photo-progress-heading > span { font-size: 0.75rem; color: var(--muted); }
.photo-upload-progress progress { width: 100%; height: 5px; appearance: none; border: 0; background: var(--line); color: var(--accent); border-radius: 3px; display: block; }
.photo-upload-progress progress::-webkit-progress-bar { background: var(--line); border-radius: 3px; }
.photo-upload-progress progress::-webkit-progress-value { background: var(--accent); border-radius: 3px; }
.photo-upload-progress progress::-moz-progress-bar { background: var(--accent); border-radius: 3px; }
.photo-upload-progress p { margin-top: 10px; color: var(--muted); font-size: 0.875rem; line-height: 1.7; overflow-wrap: anywhere; }
.photo-upload-queue { max-height: 270px; overflow-y: auto; }
.photo-queue-item { display: flex; align-items: flex-start; flex-wrap: wrap; gap: 9px 14px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.photo-queue-item:last-child { border: 0; }
.photo-queue-item > div { flex: 1 1 240px; min-width: 0; }
.photo-queue-item strong { display: block; font-size: 0.875rem; font-weight: 500; overflow-wrap: anywhere; }
.photo-queue-item span { display: block; font-size: 0.75rem; color: var(--muted); margin-top: 4px; }
.photo-queue-item p { font-size: 1rem; line-height: 1.65; color: var(--danger); margin-top: 7px; overflow-wrap: anywhere; }
.photo-queue-item p.photo-preview-warning { color: var(--muted); font-size: 0.875rem; }
.photo-queue-item.status-done > div > span { color: var(--success); }
.photo-queue-item.status-error > div > span, .photo-queue-item.status-uncertain > div > span { color: var(--danger); }
.photo-stop { margin-right: auto; }
@media (max-width: 700px) {
  .photo-grid { gap: 17px; padding: 18px; }
  .photo-toolbar, .photo-nda-note { padding-left: 18px; padding-right: 18px; }
  .photo-toolbar .filter-select { flex: 1 1 100%; }
  .photo-viewer { width: calc(100vw - 20px); max-height: calc(100dvh - 20px); }
  .photo-viewer-header, .photo-viewer-footer { padding: 16px; }
  .photo-viewer-image img { max-height: 55dvh; }
  .photo-viewer-controls { width: 100%; justify-content: space-between; }
  .photo-viewer-controls > .button { flex: 1 1 0; }
  .photo-queue-item > div { flex-basis: 100%; }
}

/* Keep small screens and touch input usable without clipping page overflow. */
.boot-state, .connection-screen, .workspace, .auth-layout { min-height: 100dvh; }
.main { min-height: calc(100dvh - 110px - var(--safe-top) - var(--safe-bottom)); padding-left: max(var(--main-gutter), var(--safe-left)); padding-right: max(var(--main-gutter), var(--safe-right)); }
.topbar { height: auto; min-height: calc(var(--topbar-height) + var(--safe-top)); padding-top: var(--safe-top); padding-left: max(var(--topbar-gutter-left), var(--safe-left)); padding-right: max(var(--topbar-gutter-right), var(--safe-right)); }
.workspace-footer { padding-left: max(var(--footer-gutter), var(--safe-left)); padding-right: max(var(--footer-gutter), var(--safe-right)); padding-bottom: max(19px, var(--safe-bottom)); }
body.drawer-open { overflow: hidden; overscroll-behavior: none; }
.sidebar { max-height: 100dvh; overflow-y: auto; overscroll-behavior-y: contain; padding-top: max(27px, var(--safe-top)); padding-left: max(var(--sidebar-gutter), var(--safe-left)); padding-right: max(var(--sidebar-gutter), var(--safe-right)); padding-bottom: var(--safe-bottom); }
.brand-name { min-width: 0; overflow-wrap: anywhere; }
.sidebar nav, .sidebar-bottom { flex-shrink: 0; }
.sidebar-drawer-close { display: none; }
.sidebar-overlay { touch-action: none; }
.field, .form-grid > *, .project-facts > div,
.project-heading > div:first-child, .stage-detail-header > div,
.dialog-header > div, .customer-contact > span, .customer-contact > div,
.customer-preview > a > span:first-child { min-width: 0; }
.field > span, .project-facts strong, .project-address,
.stage-detail-header h2, .dialog-header h2,
.project-heading .eyebrow, .client-stage-meta dd, .request-dates dd,
.customer-notes, .customer-contact a, .customer-preview > a > span:first-child {
  overflow-wrap: anywhere;
}
.customer-preview > a > span:first-child { flex: 1; }
.customer-preview > a > .badge { flex-shrink: 0; }
.dialog-footer, .comment-controls, .stage-settings-footer,
.panel-heading, .stage-detail-header { flex-wrap: wrap; }
.dialog-footer > .button { white-space: normal; text-align: center; }
.comment-controls select { max-width: 100%; min-width: 0; }
.notification-panel {
  display: flex;
  flex-direction: column;
  max-height: calc(100vh - 82px - var(--safe-top) - var(--safe-bottom));
  max-height: calc(100dvh - 82px - var(--safe-top) - var(--safe-bottom));
  overflow-y: auto;
}
.notification-panel .panel-heading { flex-shrink: 0; flex-wrap: wrap; }
.notification-list { flex: 1; min-height: 0; overscroll-behavior-y: contain; }
.notification-panel .small-empty { min-height: 0; overflow-y: auto; }
.form-dialog {
  max-width: calc(100vw - 24px - var(--safe-left) - var(--safe-right));
  max-height: calc(100vh - 30px - var(--safe-top) - var(--safe-bottom));
  max-height: calc(100dvh - 30px - var(--safe-top) - var(--safe-bottom));
  overscroll-behavior-y: contain;
}
.photo-viewer {
  max-width: calc(100vw - 20px - var(--safe-left) - var(--safe-right));
  max-height: calc(100vh - 30px - var(--safe-top) - var(--safe-bottom));
  max-height: calc(100dvh - 30px - var(--safe-top) - var(--safe-bottom));
  overscroll-behavior-y: contain;
}
.toasts { overflow-wrap: anywhere; bottom: calc(25px + var(--safe-bottom)); max-width: min(580px, calc(100vw - 30px - var(--safe-left) - var(--safe-right))); }

@media (max-width: 850px), (pointer: coarse) {
  .button, .button.small, .text-button, .text-link, .back-link,
  .object-link, .tab, .nav-item, .check-option, .task-item {
    min-height: 44px;
    min-width: 44px;
  }
  .icon-button, .sidebar-logout, .table-open,
  .dialog-header > .icon-button, .photo-viewer-header > .icon-button {
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
    flex: 0 0 44px;
  }
  .mini-step, .mini-pipeline.compact .mini-step { width: 44px; height: 44px; min-width: 44px; min-height: 44px; flex: 0 0 44px; }
  .field input, .field select, .field textarea,
  .field input[type="file"],
  .stage-settings input, .stage-settings select, .stage-settings textarea,
  .filter-select select, .search-field input, .comment-controls select {
    font-size: 1rem;
    min-height: 44px;
  }
  .tab { flex-shrink: 0; }
  .tabs { overflow-x: auto; }
  .client-stage-meta, .request-dates { flex-wrap: wrap; gap: 16px 24px; }
  .comment-controls { gap: 10px; }
  .comment-controls select { flex: 1 1 170px; }
  .comment-controls > .button { margin-left: auto; }
  .photo-viewer-controls > .button { flex: 1 1 120px; }
}
@media (max-width: 1280px) {
  :root { --main-gutter: 25px; --topbar-gutter-left: 25px; --topbar-gutter-right: 25px; --sidebar-gutter: 10px; }
}
@media (max-width: 850px) {
  :root { --main-gutter: 22px; --topbar-gutter-left: 17px; --topbar-gutter-right: 22px; }
  .sidebar { padding-top: max(14px, var(--safe-top)); padding-left: max(10px, var(--safe-left)); padding-right: max(10px, var(--safe-right)); padding-bottom: var(--safe-bottom); }
  .sidebar-drawer-close { display: inline-flex; align-self: flex-end; flex-shrink: 0; margin-bottom: 10px; }
  .topbar-start { min-width: 0; }
  .topbar-end { flex-shrink: 0; }
  .breadcrumb-current { min-width: 0; overflow-wrap: anywhere; }
  .auth-intro, .auth-form-section { padding-top: max(35px, var(--safe-top)); padding-bottom: max(35px, var(--safe-bottom)); }
}
@media (max-width: 700px) {
  :root { --main-gutter: 18px; --topbar-gutter-left: 11px; --topbar-gutter-right: 18px; --topbar-height: 58px; --footer-gutter: 18px; }
  .auth-form-section { padding-left: max(30px, var(--safe-left)); padding-right: max(30px, var(--safe-right)); }
  .toasts { bottom: calc(17px + var(--safe-bottom)); }
}
@media (max-width: 380px) {
  :root { --main-gutter: 13px; }
  .stage-settings .form-grid { grid-template-columns: 1fr; }
}
