:root {
  --k-color-red: #f52222;
  --k-color-red-soft: #eb503b;
  --k-color-red-critical: #d92323;
  --k-color-text-strong: #09090b;
  --k-color-text: #222222;
  --k-color-text-muted: #696969;
  --k-color-text-disabled: #a1a1aa;
  --k-color-bg: #ffffff;
  --k-color-bg-warm: #fff8f7;
  --k-color-surface-muted: #f4f4f5;
  --k-color-border: #e4e4e7;
  --k-color-success: #2e7d52;
  --k-color-warning: #f7a600;
  --k-color-info: #1778b8;
  --k-color-plan: #1f203f;
  --k-color-dark: #09090b;
  --k-success-bg: #eaf6ef;
  --k-warning-bg: #fff4d6;
  --k-critical-bg: #fff1f0;
  --k-info-bg: #e8f4fb;
  --k-plan-bg: #eef0f7;
  --k-radius-xs: 6px;
  --k-radius-sm: 8px;
  --k-radius-md: 12px;
  --k-radius-lg: 16px;
  --k-radius-pill: 9999px;
  --sidebar-width: 280px;
  font-family: Formular, Inter, Arial, sans-serif;
  color: var(--k-color-text);
  background: var(--k-color-bg-warm);
  font-variant-numeric: tabular-nums;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--k-color-bg-warm);
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--k-color-text);
  background:
    linear-gradient(180deg, rgba(255, 248, 247, 0.92), rgba(255, 255, 255, 0.96) 420px),
    var(--k-color-bg-warm);
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid rgba(245, 34, 34, 0.22);
  outline-offset: 2px;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  overflow-x: clip;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 24px 18px;
  background: #ffffff;
  border-right: 1px solid var(--k-color-border);
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-width: 0;
}

.brand-block {
  display: grid;
  gap: 8px;
  align-content: start;
  justify-items: start;
  min-height: 48px;
}

.brand-logo {
  display: block;
  width: 125px;
  max-width: 100%;
  height: auto;
}

.brand-subtitle {
  color: var(--k-color-text-muted);
  font-size: 12px;
  font-weight: 650;
}

.nav-menu {
  display: grid;
  gap: 8px;
  min-width: 0;
  max-width: 100%;
}

.nav-button {
  width: 100%;
  min-height: 44px;
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 10px;
  align-items: center;
  border: 1px solid transparent;
  border-radius: var(--k-radius-md);
  color: var(--k-color-text-muted);
  background: transparent;
  padding: 8px 10px;
  text-align: left;
  font-size: 14px;
  font-weight: 650;
}

.nav-button:hover {
  background: var(--k-color-surface-muted);
  color: var(--k-color-text);
}

.nav-button.is-active {
  color: var(--k-color-red-critical);
  background: var(--k-critical-bg);
  border-color: rgba(217, 35, 35, 0.18);
}

.nav-icon {
  width: 34px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--k-radius-sm);
  background: #ffffff;
  color: var(--k-color-text-muted);
  font-size: 12px;
  font-weight: 800;
}

.nav-button.is-active .nav-icon {
  background: var(--k-color-red);
  color: #ffffff;
}

.sidebar-note {
  margin-top: auto;
  display: grid;
  gap: 8px;
  padding: 14px;
  border-radius: var(--k-radius-md);
  background: var(--k-color-surface-muted);
  color: var(--k-color-text-muted);
  font-size: 12px;
  line-height: 1.35;
}

.note-label {
  width: fit-content;
  padding: 4px 8px;
  border-radius: var(--k-radius-pill);
  background: #ffffff;
  color: var(--k-color-text);
  font-weight: 700;
}

.main-area {
  min-width: 0;
  width: 100%;
  display: grid;
  grid-template-rows: auto 1fr;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  min-height: 72px;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  padding: 18px 28px;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--k-color-border);
  backdrop-filter: blur(14px);
}

.eyebrow {
  display: none;
}

h1 {
  margin: 0;
  color: var(--k-color-text-strong);
  font-size: 30px;
  line-height: 1.1;
  font-weight: 800;
}

.topbar-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  gap: 6px;
  padding: 6px 10px;
  border-radius: var(--k-radius-pill);
  border: 1px solid var(--k-color-border);
  background: #ffffff;
  color: var(--k-color-text);
  font-size: 12px;
  font-weight: 650;
  white-space: nowrap;
}

.chip::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: var(--k-radius-pill);
  background: var(--k-color-red);
}

.chip.object-chip {
  min-height: 40px;
  padding: 8px 14px;
  border-color: rgba(245, 34, 34, 0.22);
  background: var(--k-critical-bg);
  color: var(--k-color-text-strong);
  font-size: 16px;
  font-weight: 850;
}

.chip.object-chip::before {
  width: 9px;
  height: 9px;
}

.dashboard-content {
  min-width: 0;
  padding: 24px 28px 36px;
}

.dashboard-content:focus {
  outline: none;
}

h1,
h2,
h3,
p,
.chip,
.kpi-foot,
.signal-title,
.signal-meta,
.status-tile p,
.history-title,
.history-caption,
.readiness-label {
  overflow-wrap: anywhere;
}

.page-grid {
  display: grid;
  gap: 20px;
  min-width: 0;
}

.section-title,
.card-title {
  margin: 0;
  color: var(--k-color-text-strong);
}

.section-note,
.muted {
  color: var(--k-color-text-muted);
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(180px, 1fr));
  gap: 14px;
  min-width: 0;
}

.progress-kpi-row {
  grid-template-columns: repeat(6, minmax(128px, 1fr));
}

.progress-kpi-row .kpi-card,
.execution-kpi-row .kpi-card {
  min-height: 114px;
  padding: 14px;
}

.progress-kpi-row .kpi-value,
.execution-kpi-row .kpi-value {
  font-size: 28px;
}

.progress-kpi-row .kpi-label,
.execution-kpi-row .kpi-label {
  font-size: 12px;
}

.execution-kpi-row {
  grid-template-columns: repeat(4, minmax(170px, 1fr));
}

.kpi-card,
.panel,
.table-panel,
.signal-row,
.readiness-card,
.history-item {
  border: 1px solid rgba(228, 228, 231, 0.88);
  background: #ffffff;
  border-radius: var(--k-radius-lg);
}

.kpi-card {
  min-height: 138px;
  padding: 16px;
  display: grid;
  gap: 10px;
  align-content: space-between;
}

.kpi-label {
  color: var(--k-color-text-muted);
  font-size: 13px;
  line-height: 1.25;
  font-weight: 650;
}

.kpi-value {
  color: var(--k-color-text-strong);
  font-size: 34px;
  line-height: 1;
  font-weight: 800;
}

.kpi-foot {
  color: var(--k-color-text-muted);
  font-size: 12px;
  line-height: 1.35;
}

.kpi-card.is-critical {
  border-color: rgba(217, 35, 35, 0.22);
  background: linear-gradient(180deg, #ffffff, #fff8f8);
}

.kpi-card.is-warning {
  border-color: rgba(247, 166, 0, 0.28);
  background: linear-gradient(180deg, #ffffff, #fffaf0);
}

.kpi-card.is-success {
  border-color: rgba(46, 125, 82, 0.22);
}

.two-col {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(340px, 0.65fr);
  gap: 16px;
  align-items: start;
  min-width: 0;
}

.panel,
.table-panel {
  padding: 18px;
  min-width: 0;
}

.section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.section-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.ghost-action {
  min-height: 24px;
  border: 0;
  border-radius: var(--k-radius-pill);
  background: var(--k-color-surface-muted);
  color: var(--k-color-text-muted);
  padding: 4px 9px;
  font-size: 12px;
  line-height: 1;
  font-weight: 750;
}

.ghost-action:hover {
  color: var(--k-color-red-critical);
  background: var(--k-critical-bg);
}

.section-title {
  font-size: 19px;
  font-weight: 800;
  line-height: 1.2;
}

.section-note {
  margin: 5px 0 0;
  font-size: 13px;
  line-height: 1.4;
}

.funnel-list {
  display: grid;
  gap: 12px;
}

.funnel-item {
  display: grid;
  grid-template-columns: minmax(150px, 190px) minmax(0, 1fr) 104px;
  gap: 12px;
  align-items: center;
}

.funnel-label {
  color: var(--k-color-text);
  font-size: 13px;
  font-weight: 750;
}

.funnel-track {
  height: 22px;
  border-radius: var(--k-radius-pill);
  background: var(--k-color-surface-muted);
  overflow: hidden;
}

.funnel-fill {
  height: 100%;
  min-width: 3px;
  border-radius: inherit;
  background: var(--bar-color, var(--k-color-plan));
}

.funnel-value {
  color: var(--k-color-text-strong);
  font-size: 13px;
  font-weight: 800;
  text-align: right;
}

.delta-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.delta-tile {
  min-height: 94px;
  padding: 14px;
  border-radius: var(--k-radius-md);
  background: var(--k-color-surface-muted);
  display: grid;
  align-content: space-between;
  gap: 10px;
}

.delta-tile strong {
  color: var(--k-color-text-strong);
  font-size: 24px;
  line-height: 1;
}

.delta-tile span {
  color: var(--k-color-text-muted);
  font-size: 12px;
  line-height: 1.25;
  font-weight: 650;
}

.delta-tile.positive {
  background: var(--k-critical-bg);
}

.delta-tile.positive strong {
  color: var(--k-color-red-critical);
}

.delta-tile.negative {
  background: var(--k-success-bg);
}

.delta-tile.negative strong {
  color: var(--k-color-success);
}

.signal-list {
  display: grid;
  gap: 10px;
}

.signal-row {
  padding: 13px 14px;
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.signal-title {
  margin: 0;
  color: var(--k-color-text-strong);
  font-size: 14px;
  line-height: 1.3;
  font-weight: 750;
}

.signal-meta {
  margin: 7px 0 0;
  color: var(--k-color-text-muted);
  font-size: 12px;
  line-height: 1.35;
}

.badge {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 24px;
  padding: 4px 9px;
  border-radius: var(--k-radius-pill);
  color: var(--badge-text, var(--k-color-text));
  background: var(--badge-bg, var(--k-color-surface-muted));
  font-size: 12px;
  line-height: 1;
  font-weight: 750;
  white-space: nowrap;
}

.badge.critical {
  --badge-bg: var(--k-critical-bg);
  --badge-text: #8f1212;
}

.badge.warning {
  --badge-bg: var(--k-warning-bg);
  --badge-text: #6b4700;
}

.badge.success {
  --badge-bg: var(--k-success-bg);
  --badge-text: #145a36;
}

.badge.info {
  --badge-bg: var(--k-info-bg);
  --badge-text: #0f4f7a;
}

.badge.neutral {
  --badge-bg: var(--k-color-surface-muted);
  --badge-text: #52525b;
}

.badge.compact {
  min-width: 44px;
  justify-content: center;
  padding-inline: 8px;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 14px;
}

.field {
  min-height: 40px;
  border: 1px solid var(--k-color-border);
  border-radius: var(--k-radius-sm);
  background: #ffffff;
  color: var(--k-color-text);
  padding: 8px 10px;
  font-size: 14px;
}

.field.search {
  min-width: 260px;
}

.data-table-wrap {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow: auto;
  border: 1px solid var(--k-color-border);
  border-radius: var(--k-radius-md);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 980px;
  background: #ffffff;
}

.data-table th,
.data-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--k-color-border);
  font-size: 13px;
  line-height: 1.25;
  vertical-align: middle;
}

.data-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--k-color-surface-muted);
  color: var(--k-color-text-muted);
  font-weight: 750;
  text-align: left;
}

.data-table td.num,
.data-table th.num {
  text-align: right;
}

.data-table th.status-col,
.data-table td.status-cell {
  width: 64px;
  min-width: 64px;
  max-width: 72px;
  text-align: center;
  white-space: nowrap;
}

.data-table tbody tr:hover {
  background: var(--k-color-bg-warm);
}

.data-table tbody tr:last-child td {
  border-bottom: 0;
}

.data-table tfoot td {
  padding: 11px 12px;
  border-top: 1px solid var(--k-color-border);
  background: var(--k-color-surface-muted);
  color: var(--k-color-text-strong);
  font-size: 13px;
  font-weight: 800;
}

.wbs-code {
  color: var(--k-color-text-muted);
  font-size: 12px;
  font-weight: 800;
}

.wbs-name {
  color: var(--k-color-text-strong);
  font-weight: 750;
}

.num.positive,
.metric-positive {
  color: var(--k-color-red-critical);
  font-weight: 800;
}

.num.negative,
.metric-negative {
  color: var(--k-color-success);
  font-weight: 800;
}

.num.warning,
.metric-warning {
  color: #8a5a00;
  font-weight: 800;
}

.bar-cell {
  min-width: 150px;
}

.mini-bar {
  height: 8px;
  border-radius: var(--k-radius-pill);
  background: var(--k-color-surface-muted);
  overflow: hidden;
}

.mini-bar > span {
  display: block;
  width: var(--value, 0%);
  height: 100%;
  border-radius: inherit;
  background: var(--bar-color, var(--k-color-info));
}

.readiness-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(170px, 1fr));
  gap: 14px;
  min-width: 0;
}

.readiness-card {
  padding: 15px;
  display: grid;
  gap: 8px;
}

.readiness-value {
  color: var(--k-color-text-strong);
  font-size: 28px;
  font-weight: 800;
  line-height: 1;
}

.readiness-label {
  color: var(--k-color-text-muted);
  font-size: 13px;
  line-height: 1.3;
  font-weight: 650;
}

.timeline {
  display: grid;
  gap: 12px;
}

.history-item {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 14px;
}

.history-date {
  color: var(--k-color-text-muted);
  font-size: 12px;
  font-weight: 800;
}

.history-title {
  color: var(--k-color-text-strong);
  font-size: 14px;
  font-weight: 800;
}

.history-caption {
  margin-top: 4px;
  color: var(--k-color-text-muted);
  font-size: 12px;
  line-height: 1.35;
}

.status-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  min-width: 0;
}

.cover-kpi-row .status-tile {
  min-height: 118px;
}

.status-tile {
  min-height: 126px;
  display: grid;
  gap: 8px;
  align-content: space-between;
  padding: 16px;
  border: 1px solid var(--tile-border, var(--k-color-border));
  border-radius: var(--k-radius-sm);
  background: var(--tile-bg, #ffffff);
}

.status-tile span {
  color: var(--k-color-text-muted);
  font-size: 13px;
  font-weight: 750;
}

.status-tile strong {
  color: var(--tile-color, var(--k-color-text-strong));
  font-size: 34px;
  line-height: 1;
  font-weight: 850;
}

.status-tile p {
  margin: 0;
  color: var(--k-color-text-muted);
  font-size: 12px;
  line-height: 1.35;
}

.status-tile.critical {
  --tile-bg: var(--k-critical-bg);
  --tile-border: rgba(217, 35, 35, 0.2);
  --tile-color: var(--k-color-red-critical);
}

.status-tile.warning {
  --tile-bg: var(--k-warning-bg);
  --tile-border: rgba(247, 166, 0, 0.24);
  --tile-color: #8a5a00;
}

.status-tile.success {
  --tile-bg: var(--k-success-bg);
  --tile-border: rgba(46, 125, 82, 0.2);
  --tile-color: var(--k-color-success);
}

.status-tile.info {
  --tile-bg: var(--k-info-bg);
  --tile-border: rgba(23, 120, 184, 0.2);
  --tile-color: var(--k-color-info);
}

.bim-panel {
  min-width: 0;
  padding: 18px;
  border: 1px solid rgba(228, 228, 231, 0.88);
  border-radius: var(--k-radius-sm);
  background: #ffffff;
}

.bim-panel.is-cover {
  align-self: stretch;
  display: grid;
  grid-template-rows: auto 1fr auto;
}

.bim-viewport {
  position: relative;
  min-height: 260px;
  border: 1px solid var(--k-color-border);
  border-radius: var(--k-radius-sm);
  background: #f8fafc;
  overflow: hidden;
}

.bim-image {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 260px;
  object-fit: contain;
  object-position: center;
}

.cover-workspace {
  display: grid;
  grid-template-columns: minmax(420px, 0.46fr) minmax(0, 1fr);
  gap: 16px;
  align-items: stretch;
  min-width: 0;
}

.budget-filter-panel {
  min-width: 0;
  padding: 18px;
  border: 1px solid rgba(228, 228, 231, 0.88);
  border-radius: var(--k-radius-sm);
  background: #ffffff;
}

.budget-table-wrap {
  max-height: 430px;
  overflow: auto;
  border: 1px solid var(--k-color-border);
  border-radius: var(--k-radius-md);
}

.budget-filter-table {
  width: 100%;
  border-collapse: collapse;
  background: #ffffff;
}

.budget-filter-table th,
.budget-filter-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--k-color-border);
  font-size: 12px;
  line-height: 1.25;
  vertical-align: middle;
}

.budget-filter-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--k-color-surface-muted);
  color: var(--k-color-text-muted);
  font-weight: 800;
  text-align: left;
}

.budget-filter-table th.num,
.budget-filter-table td.num {
  text-align: right;
  white-space: nowrap;
}

.budget-filter-row {
  cursor: pointer;
}

.budget-filter-row:hover {
  background: var(--k-color-bg-warm);
}

.budget-filter-row:focus-visible {
  outline: 3px solid rgba(245, 34, 34, 0.2);
  outline-offset: -3px;
}

.budget-filter-row.is-selected {
  background: var(--k-critical-bg);
}

.budget-filter-row.is-selected .wbs-name {
  color: var(--k-color-red-critical);
}

.bim-filter-overlay {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 16px;
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border: 1px solid rgba(217, 35, 35, 0.2);
  border-radius: var(--k-radius-sm);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 16px 34px rgba(9, 9, 11, 0.12);
  backdrop-filter: blur(12px);
}

.bim-filter-overlay span {
  color: var(--k-color-text-muted);
  font-size: 12px;
  font-weight: 700;
}

.bim-filter-overlay strong {
  color: var(--k-color-red-critical);
  font-size: 15px;
  line-height: 1.25;
}

.bim-legend,
.chart-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  align-items: center;
  margin-top: 14px;
  color: var(--k-color-text-muted);
  font-size: 12px;
  font-weight: 750;
}

.bim-legend span,
.chart-legend span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  white-space: nowrap;
}

.bim-legend i,
.chart-legend i {
  width: 10px;
  height: 10px;
  border-radius: var(--k-radius-pill);
  display: inline-block;
}

.execution-filter-panel {
  display: grid;
  grid-template-columns: minmax(360px, 1fr) minmax(320px, 0.75fr);
  gap: 18px;
  align-items: end;
  padding: 18px;
  border: 1px solid rgba(228, 228, 231, 0.88);
  border-radius: var(--k-radius-lg);
  background: #ffffff;
}

.filter-group {
  display: grid;
  gap: 9px;
  min-width: 0;
}

.filter-label {
  color: var(--k-color-text-muted);
  font-size: 13px;
  font-weight: 750;
}

.segmented-control {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  min-height: 54px;
  padding: 5px;
  border: 1px solid var(--k-color-border);
  border-radius: var(--k-radius-lg);
  background: #fafafa;
}

.segmented-control button {
  min-width: 0;
  border: 0;
  border-radius: var(--k-radius-md);
  background: transparent;
  color: var(--k-color-text);
  font-size: 14px;
  font-weight: 750;
}

.segmented-control button.is-active {
  background: #ffffff;
  color: var(--k-color-red-critical);
  box-shadow: 0 8px 18px rgba(9, 9, 11, 0.1);
}

.date-range-control {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.date-range-control label {
  display: grid;
  gap: 5px;
  min-width: 0;
  color: var(--k-color-text-muted);
  font-size: 12px;
  font-weight: 700;
}

.date-range-control input {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--k-color-border);
  border-radius: var(--k-radius-md);
  background: #fafafa;
  color: var(--k-color-text);
  padding: 9px 12px;
  font-size: 14px;
  font-weight: 700;
}

.execution-layout {
  display: grid;
  grid-template-columns: minmax(600px, 0.56fr) minmax(360px, 0.44fr);
  gap: 16px;
  align-items: stretch;
  min-width: 0;
}

.execution-table {
  min-width: 0;
}

.execution-table th,
.execution-table td {
  padding: 8px 10px;
  font-size: 12px;
}

.execution-table .badge {
  padding-inline: 7px;
  font-size: 11px;
}

.execution-visual-panel {
  display: grid;
  grid-template-rows: auto minmax(360px, 1fr) auto;
}

.execution-viewport {
  min-height: 360px;
}

.execution-viewport .bim-image {
  min-height: 360px;
}

.execution-period-overlay {
  left: 18px;
  right: auto;
  bottom: 18px;
  width: min(360px, calc(100% - 36px));
}

.readiness-board {
  display: grid;
  gap: 8px;
}

.readiness-board-head,
.readiness-lane {
  display: grid;
  grid-template-columns: minmax(230px, 1.35fr) minmax(150px, 0.8fr) minmax(130px, 0.7fr) minmax(145px, 0.8fr) minmax(220px, 1fr) minmax(120px, 0.62fr);
  gap: 12px;
  align-items: center;
}

.readiness-board-head {
  padding: 0 12px;
  color: var(--k-color-text-muted);
  font-size: 12px;
  font-weight: 800;
}

.readiness-lane {
  padding: 12px;
  border: 1px solid var(--k-color-border);
  border-radius: var(--k-radius-md);
  background: #ffffff;
}

.readiness-work-cell,
.readiness-meter-cell,
.readiness-schedule-cell,
.procurement-stack {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.schedule-range {
  color: var(--k-color-text-strong);
  font-size: 13px;
  font-weight: 800;
}

.readiness-scale-cell {
  align-self: stretch;
  align-content: start;
  grid-template-rows: 28px auto auto;
}

.scale-caption {
  min-width: 0;
  color: var(--k-color-text);
  font-size: 12px;
  line-height: 1.25;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.progress-meter {
  --meter-color: var(--k-color-surface-muted);
  --pill-bg: #ffffff;
  --pill-text: var(--k-color-text);
  position: relative;
  height: 8px;
  margin-top: 10px;
  border-radius: var(--k-radius-pill);
  background: var(--k-color-surface-muted);
}

.progress-meter-fill {
  display: block;
  width: var(--value, 0%);
  height: 100%;
  min-width: 2px;
  max-width: 100%;
  border-radius: inherit;
  background: var(--meter-color);
}

.progress-meter-pill {
  position: absolute;
  top: 50%;
  left: var(--pill, 0%);
  transform: translate(-50%, -50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 22px;
  padding: 0 7px;
  border: 2px solid #ffffff;
  border-radius: var(--k-radius-pill);
  background: var(--pill-bg);
  color: var(--pill-text);
  box-shadow: 0 4px 10px rgba(9, 9, 11, 0.12);
  font-size: 11px;
  line-height: 1;
  font-weight: 850;
  white-space: nowrap;
}

.progress-meter.plan {
  --meter-color: var(--k-color-plan);
  --pill-bg: #ffffff;
  --pill-text: var(--k-color-plan);
}

.progress-meter.success {
  --meter-color: var(--k-color-success);
  --pill-bg: var(--k-success-bg);
  --pill-text: #145a36;
}

.progress-meter.warning {
  --meter-color: var(--k-color-warning);
  --pill-bg: var(--k-warning-bg);
  --pill-text: #6b4700;
}

.progress-meter.critical {
  --meter-color: var(--k-color-red-critical);
  --pill-bg: var(--k-critical-bg);
  --pill-text: #8f1212;
}

.progress-meter.info {
  --meter-color: var(--k-color-info);
  --pill-bg: var(--k-info-bg);
  --pill-text: #0f4f7a;
}

.progress-meter.neutral {
  --meter-color: var(--k-color-text-disabled);
  --pill-bg: var(--k-color-surface-muted);
  --pill-text: #52525b;
}

.procurement-chip {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  color: var(--k-color-text-muted);
  font-size: 12px;
  line-height: 1.25;
  font-weight: 700;
}

.procurement-chip-list {
  display: grid;
  gap: 5px;
}

.readiness-support-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 16px;
  min-width: 0;
}

.readiness-support-table {
  min-width: 720px;
}

.chart-panel {
  display: grid;
  gap: 0;
}

.chart-shell {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  margin-top: 12px;
  overflow: auto;
  border: 1px solid var(--k-color-border);
  border-radius: var(--k-radius-md);
  background: #ffffff;
}

.line-chart {
  display: block;
  width: 100%;
  min-width: 820px;
  height: auto;
}

.empty-chart {
  min-height: 220px;
  display: grid;
  place-items: center;
  margin-top: 12px;
  border: 1px dashed var(--k-color-border);
  border-radius: var(--k-radius-md);
  color: var(--k-color-text-muted);
  background: #ffffff;
  font-size: 14px;
  font-weight: 650;
}

.load-state,
.error-state {
  min-height: 360px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 14px;
  color: var(--k-color-text-muted);
}

.load-dot {
  width: 28px;
  height: 28px;
  border: 4px solid var(--k-color-border);
  border-top-color: var(--k-color-red);
  border-radius: var(--k-radius-pill);
  animation: spin 0.9s linear infinite;
}

.error-state {
  text-align: center;
  padding: 28px;
  border: 1px solid rgba(217, 35, 35, 0.2);
  border-radius: var(--k-radius-lg);
  background: #ffffff;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@media (max-width: 1220px) {
  .metric-grid {
    grid-template-columns: repeat(2, minmax(220px, 1fr));
  }

  .progress-kpi-row {
    grid-template-columns: repeat(3, minmax(180px, 1fr));
  }

  .execution-filter-panel,
  .execution-layout,
  .readiness-support-grid {
    grid-template-columns: 1fr;
  }

  .readiness-board {
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .readiness-board-head,
  .readiness-lane {
    min-width: 1080px;
  }

  .cover-workspace {
    grid-template-columns: 1fr;
  }

  .status-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .two-col {
    grid-template-columns: 1fr;
  }

  .readiness-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 860px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
    width: 100%;
    max-width: 100vw;
    overflow: hidden;
    padding: 14px 16px;
    border-right: 0;
    border-bottom: 1px solid var(--k-color-border);
  }

  .nav-menu {
    display: flex;
    gap: 8px;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .nav-button {
    width: auto;
    min-width: 164px;
  }

  .sidebar-note {
    display: none;
  }

  .topbar {
    position: static;
    align-items: flex-start;
    flex-direction: column;
    padding: 16px;
  }

  .topbar-meta {
    justify-content: flex-start;
  }

  h1 {
    font-size: 26px;
  }

  .dashboard-content {
    padding: 16px;
  }

  .section-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .metric-grid,
  .readiness-grid,
  .status-grid {
    grid-template-columns: 1fr;
  }

  .progress-kpi-row,
  .execution-kpi-row {
    grid-template-columns: 1fr;
  }

  .execution-filter-panel {
    padding: 14px;
  }

  .segmented-control,
  .date-range-control {
    grid-template-columns: 1fr;
  }

  .funnel-item {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .funnel-value {
    text-align: left;
  }

  .delta-grid {
    grid-template-columns: 1fr;
  }

  .history-item,
  .signal-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .nav-button {
    min-width: 170px;
    grid-template-columns: 28px 1fr;
    font-size: 13px;
  }

  .nav-icon {
    width: 28px;
  }

  .kpi-value {
    font-size: 30px;
  }

  .status-tile strong {
    font-size: 30px;
  }

  .bim-panel {
    padding: 14px;
  }

  .bim-viewport,
  .bim-image {
    min-height: 230px;
  }

  .field.search {
    min-width: 100%;
  }

  .toolbar {
    align-items: stretch;
  }

  .toolbar .field {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
