:root {
  color-scheme: light;
  --bg: #f3f5f7;
  --bg-muted: #eef2f0;
  --panel: rgba(255, 255, 255, 0.96);
  --panel-strong: #ffffff;
  --surface-card: rgba(255, 255, 255, 0.96);
  --surface-card-strong: #ffffff;
  --surface-card-subtle: #f6f8f9;
  --surface-soft: #f7f9fa;
  --surface-strong: #ffffff;
  --line: #d8e0e6;
  --line-strong: #c4cfd7;
  --text: #17212b;
  --muted: #66727f;
  --brand: #1e4f47;
  --brand-strong: #163c36;
  --brand-soft: rgba(30, 79, 71, 0.08);
  --accent: #b97333;
  --accent-soft: #f7ece1;
  --gold: #c4964f;
  --danger: #b8472f;
  --danger-soft: #f8e7e3;
  --warning: #9a6700;
  --success: #21633c;
  --success-soft: #e7f3eb;
  --body-bg:
    radial-gradient(circle at top left, rgba(30, 79, 71, 0.05), transparent 24%),
    linear-gradient(180deg, #f7f9fb 0%, #f3f5f7 100%);
  --hero-bg: linear-gradient(135deg, rgba(22, 60, 54, 0.98), rgba(30, 79, 71, 0.96));
  --hero-copy: #52606d;
  --sidebar-bg:
    linear-gradient(180deg, rgba(246, 248, 249, 0.98), rgba(242, 245, 246, 0.98)),
    rgba(244, 247, 248, 0.98);
  --sidebar-line: rgba(23, 33, 43, 0.08);
  --sidebar-card: rgba(255, 255, 255, 0.68);
  --sidebar-text: #17322d;
  --sidebar-hover-bg: rgba(30, 79, 71, 0.08);
  --sidebar-hover-line: rgba(30, 79, 71, 0.16);
  --sidebar-kicker-bg: rgba(30, 79, 71, 0.1);
  --sidebar-kicker-text: rgba(22, 60, 54, 0.76);
  --ghost-bg: #ffffff;
  --ghost-line: #d8e0e6;
  --input-bg: #ffffff;
  --input-focus-bg: #ffffff;
  --empty-bg: #f8fafb;
  --copy-strong: #3b4652;
  --shadow: 0 18px 36px rgba(18, 31, 39, 0.06);
  --shadow-soft: 0 8px 18px rgba(18, 31, 39, 0.04);
  --radius-xl: 20px;
  --radius-lg: 16px;
  --radius-md: 12px;
  --radius-sm: 10px;
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0d1419;
  --bg-muted: #131d24;
  --panel: rgba(18, 27, 33, 0.92);
  --panel-strong: #15212a;
  --surface-card: rgba(18, 27, 33, 0.92);
  --surface-card-strong: #15212a;
  --surface-card-subtle: #101a21;
  --surface-soft: #111b22;
  --surface-strong: #16232b;
  --line: rgba(197, 214, 223, 0.12);
  --line-strong: rgba(197, 214, 223, 0.22);
  --text: #e7eef2;
  --muted: #95a6b2;
  --brand: #9ac4ba;
  --brand-strong: #cfe3dc;
  --brand-soft: rgba(154, 196, 186, 0.12);
  --accent: #d28a48;
  --accent-soft: rgba(210, 138, 72, 0.14);
  --gold: #e2b76b;
  --danger: #ef8a73;
  --danger-soft: rgba(239, 138, 115, 0.12);
  --warning: #e2b76b;
  --success: #7fcb9d;
  --success-soft: rgba(127, 203, 157, 0.12);
  --body-bg:
    radial-gradient(circle at top left, rgba(210, 138, 72, 0.08), transparent 24%),
    linear-gradient(180deg, #0d1419 0%, #111b22 100%);
  --hero-bg: linear-gradient(135deg, rgba(18, 40, 37, 0.98), rgba(25, 56, 50, 0.96));
  --hero-copy: rgba(207, 220, 228, 0.82);
  --sidebar-bg:
    linear-gradient(180deg, rgba(12, 21, 27, 0.98), rgba(10, 17, 22, 0.98)),
    rgba(10, 17, 22, 0.98);
  --sidebar-line: rgba(255, 255, 255, 0.08);
  --sidebar-card: rgba(255, 255, 255, 0.02);
  --sidebar-text: #dfe8ec;
  --sidebar-hover-bg: rgba(154, 196, 186, 0.08);
  --sidebar-hover-line: rgba(154, 196, 186, 0.18);
  --sidebar-kicker-bg: rgba(154, 196, 186, 0.08);
  --sidebar-kicker-text: rgba(231, 238, 242, 0.8);
  --ghost-bg: rgba(255, 255, 255, 0.03);
  --ghost-line: rgba(255, 255, 255, 0.12);
  --input-bg: #121c23;
  --input-focus-bg: #16242d;
  --empty-bg: #111b22;
  --copy-strong: #c4d0d7;
  --shadow: 0 20px 40px rgba(0, 0, 0, 0.26);
  --shadow-soft: 0 10px 24px rgba(0, 0, 0, 0.18);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "IBM Plex Sans", "Noto Sans SC", sans-serif;
  color: var(--text);
  background: var(--body-bg);
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

button:disabled,
input:disabled,
select:disabled,
textarea:disabled {
  cursor: not-allowed;
  opacity: 0.62;
}

h1,
h2,
h3,
h4,
h5,
p {
  margin: 0;
}

.eyebrow {
  margin-bottom: 0.45rem;
  color: inherit;
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.74;
}

.muted,
label,
.metric-label,
.metric-note {
  color: var(--muted);
}

.is-hidden {
  display: none !important;
}

.empty-state {
  margin-top: 0.85rem;
  padding: 1rem 1.05rem;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-md);
  color: var(--muted);
  background: var(--empty-bg);
  font-size: 0.9rem;
  line-height: 1.65;
}

.panel-description {
  display: block;
  margin-top: 0.34rem;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.55;
}

.chip,
.status-pill,
.risk-pill,
.mini-pill,
.panel-tag {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
}

.status-pill,
.risk-pill,
.mini-pill {
  min-height: 26px;
  padding: 0.15rem 0.62rem;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 600;
}

.status-pill {
  background: var(--brand-soft);
  color: var(--brand);
}

.status-pill.overdue,
.risk-pill.high {
  background: var(--danger-soft);
  color: var(--danger);
}

.status-pill.review,
.risk-pill.medium {
  background: rgba(196, 150, 79, 0.14);
  color: var(--warning);
}

.status-pill.done,
.risk-pill.low {
  background: var(--success-soft);
  color: var(--success);
}

.chip {
  gap: 0.35rem;
  padding: 0.28rem 0.68rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-soft);
  color: var(--copy-strong);
  font-size: 0.76rem;
}

.chip-button {
  cursor: pointer;
  appearance: none;
}
