:root {
  color-scheme: light;
  --navy-950: oklch(20% 0.055 242);
  --navy-900: oklch(25% 0.062 242);
  --navy-800: oklch(32% 0.07 242);
  --navy-700: oklch(39% 0.072 242);
  --navy-600: oklch(48% 0.075 242);
  --navy-100: oklch(93% 0.018 242);
  --navy-050: oklch(97% 0.008 242);

  --gold-700: oklch(52% 0.11 78);
  --gold-600: oklch(61% 0.115 78);
  --gold-500: oklch(70% 0.11 78);
  --gold-200: oklch(88% 0.055 78);
  --gold-100: oklch(95% 0.025 78);

  --ink-950: oklch(21% 0.026 245);
  --ink-800: oklch(34% 0.023 245);
  --ink-650: oklch(47% 0.02 245);
  --ink-500: oklch(57% 0.018 245);
  --ink-350: oklch(71% 0.014 245);
  --ink-200: oklch(84% 0.01 245);
  --ink-100: oklch(91% 0.008 245);
  --ink-050: oklch(97% 0.006 245);

  --surface-canvas: oklch(96.7% 0.008 82);
  --surface-raised: oklch(99% 0.006 82);
  --surface-soft: oklch(97.5% 0.012 82);
  --surface-strong: oklch(93% 0.013 82);

  --success-700: oklch(47% 0.1 157);
  --success-100: oklch(94% 0.04 157);
  --warning-700: oklch(52% 0.12 60);
  --warning-100: oklch(95% 0.047 78);
  --danger-700: oklch(50% 0.16 25);
  --danger-100: oklch(95% 0.037 25);
  --info-700: oklch(47% 0.12 247);
  --info-100: oklch(94% 0.034 247);

  --font-ui: "Source Han Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-number: "DIN Alternate", "Avenir Next", "Source Han Sans SC", sans-serif;
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.25rem;
  --text-xl: 1.75rem;
  --text-display: 2.25rem;

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-12: 3rem;

  --radius-sm: 0.375rem;
  --radius-md: 0.625rem;
  --radius-lg: 0.875rem;
  --shadow-sm: 0 1px 2px oklch(20% 0.03 242 / 0.05), 0 6px 18px oklch(20% 0.03 242 / 0.035);
  --shadow-md: 0 16px 40px oklch(20% 0.04 242 / 0.12);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-state: cubic-bezier(0.65, 0, 0.35, 1);
  --sidebar-width: 16.75rem;
  --topbar-height: 4.5rem;
  --z-dropdown: 100;
  --z-sticky: 200;
  --z-backdrop: 300;
  --z-drawer: 400;
  --z-toast: 500;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 20rem;
  background: var(--surface-canvas);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(90deg, transparent 0, transparent calc(100% - 1px), var(--ink-100) calc(100% - 1px)) 0 0 / 7.5rem 100%,
    var(--surface-canvas);
  color: var(--ink-950);
  font-family: var(--font-ui);
  font-size: var(--text-base);
  line-height: 1.5;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

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

button,
a,
select,
input[type="checkbox"],
input[type="radio"] {
  -webkit-tap-highlight-color: transparent;
}

button {
  color: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

svg {
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

:focus-visible {
  outline: 2px solid var(--gold-600);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  left: 1rem;
  top: -5rem;
  z-index: calc(var(--z-toast) + 1);
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  background: var(--gold-500);
  color: var(--navy-950);
  font-weight: 700;
  transition: top 150ms var(--ease-out);
}

.skip-link:focus {
  top: 1rem;
}

.app-shell {
  min-height: 100vh;
}

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: var(--z-sticky);
  display: flex;
  width: var(--sidebar-width);
  flex-direction: column;
  overflow-y: auto;
  background:
    radial-gradient(circle at 20% 0, oklch(45% 0.06 242 / 0.28), transparent 24rem),
    var(--navy-950);
  color: oklch(91% 0.015 242);
  transition: transform 300ms var(--ease-out);
}

.sidebar::after {
  position: absolute;
  right: 1.25rem;
  top: 0;
  width: 1px;
  height: 7rem;
  background: linear-gradient(var(--gold-500), transparent);
  content: "";
}

.brand {
  display: flex;
  min-height: var(--topbar-height);
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-6);
  border-bottom: 1px solid oklch(76% 0.02 242 / 0.16);
}

.brand-mark {
  position: relative;
  display: grid;
  width: 2.5rem;
  height: 2.75rem;
  flex: 0 0 auto;
  place-items: center;
  clip-path: polygon(50% 0, 92% 15%, 85% 75%, 50% 100%, 15% 75%, 8% 15%);
  background: var(--gold-500);
  color: var(--navy-950);
}

.brand-mark::after {
  position: absolute;
  inset: 0.25rem;
  border: 1px solid oklch(28% 0.04 242 / 0.4);
  clip-path: inherit;
  content: "";
}

.brand-mark span {
  font-family: "STSong", "Songti SC", serif;
  font-size: 1rem;
  font-weight: 800;
}

.brand-copy {
  display: grid;
  line-height: 1.2;
}

.brand-copy strong {
  color: oklch(98% 0.01 82);
  font-family: "STSong", "Songti SC", serif;
  font-size: 1.1rem;
  letter-spacing: 0.12em;
}

.brand-copy span {
  margin-top: 0.3rem;
  color: oklch(76% 0.02 242);
  font-size: var(--text-xs);
  letter-spacing: 0.22em;
}

.nav-tree {
  display: grid;
  gap: var(--space-6);
  padding: var(--space-6) var(--space-3);
}

.nav-group {
  display: grid;
  gap: var(--space-1);
}

.nav-group-label {
  padding: 0 var(--space-3) var(--space-2);
  color: oklch(68% 0.018 242);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.18em;
}

.nav-item {
  position: relative;
  display: flex;
  min-height: 2.75rem;
  align-items: center;
  gap: var(--space-3);
  padding: 0.65rem var(--space-3);
  border: 0;
  border-radius: var(--radius-sm);
  background: transparent;
  color: oklch(84% 0.016 242);
  cursor: pointer;
  font-size: var(--text-sm);
  text-align: left;
  transition: background 120ms var(--ease-out), color 120ms var(--ease-out), transform 120ms var(--ease-out);
}

.nav-item svg {
  width: 1.15rem;
  height: 1.15rem;
  flex: 0 0 auto;
}

.nav-item .nav-badge {
  margin-left: auto;
  min-width: 1.45rem;
  padding: 0.08rem 0.42rem;
  border-radius: 999px;
  background: oklch(94% 0.03 78 / 0.12);
  color: var(--gold-500);
  font-family: var(--font-number);
  font-size: 0.7rem;
  font-weight: 700;
  text-align: center;
}

.nav-item:hover {
  background: oklch(92% 0.02 242 / 0.08);
  color: oklch(99% 0.01 82);
  transform: translateX(2px);
}

.nav-item.active {
  background: linear-gradient(90deg, oklch(92% 0.03 78 / 0.15), oklch(92% 0.03 78 / 0.035));
  color: var(--gold-500);
  font-weight: 700;
}

.nav-item.active::before {
  position: absolute;
  left: -0.75rem;
  width: 0.2rem;
  height: 1.5rem;
  border-radius: 0 4px 4px 0;
  background: var(--gold-500);
  content: "";
}

.sidebar-foot {
  display: grid;
  gap: var(--space-3);
  margin-top: auto;
  padding: var(--space-6);
  border-top: 1px solid oklch(76% 0.02 242 / 0.14);
}

.security-note {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
}

.security-note div {
  display: grid;
  gap: 0.1rem;
}

.security-note strong {
  color: oklch(94% 0.01 82);
  font-size: var(--text-xs);
}

.security-note span:last-child {
  color: oklch(69% 0.014 242);
  font-size: 0.68rem;
}

.security-dot {
  width: 0.5rem;
  height: 0.5rem;
  margin-top: 0.35rem;
  border-radius: 50%;
  background: var(--success-700);
  box-shadow: 0 0 0 4px oklch(68% 0.1 157 / 0.12);
}

.text-button {
  min-height: 2.5rem;
  border: 0;
  background: transparent;
  color: var(--gold-500);
  cursor: pointer;
  font-size: var(--text-xs);
  font-weight: 700;
  text-align: left;
}

.workspace {
  min-height: 100vh;
  margin-left: var(--sidebar-width);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: var(--z-sticky);
  display: flex;
  height: var(--topbar-height);
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: 0 var(--space-8);
  border-bottom: 1px solid var(--ink-100);
  background: oklch(99% 0.006 82 / 0.94);
  box-shadow: 0 1px 0 oklch(99% 0.006 82 / 0.8);
  backdrop-filter: blur(14px);
}

.topbar-leading,
.topbar-actions,
.breadcrumb,
.role-switcher,
.global-search {
  display: flex;
  align-items: center;
}

.topbar-actions {
  gap: var(--space-3);
}

.breadcrumb {
  gap: var(--space-2);
  color: var(--ink-500);
  font-size: var(--text-sm);
}

.breadcrumb strong {
  color: var(--ink-950);
  font-weight: 700;
}

.breadcrumb-separator {
  color: var(--ink-350);
}

.icon-button {
  position: relative;
  display: grid;
  width: 2.5rem;
  height: 2.5rem;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--ink-650);
  cursor: pointer;
  transition: background 120ms var(--ease-out), color 120ms var(--ease-out), border-color 120ms var(--ease-out), transform 120ms var(--ease-out);
}

.icon-button svg {
  width: 1.25rem;
  height: 1.25rem;
}

.icon-button:hover {
  border-color: var(--ink-100);
  background: var(--surface-strong);
  color: var(--navy-800);
}

.icon-button:active {
  transform: scale(0.96);
}

.menu-toggle {
  display: none;
}

.global-search {
  width: clamp(12rem, 22vw, 20rem);
  min-height: 2.5rem;
  gap: var(--space-2);
  padding: 0 var(--space-3);
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-sm);
  background: var(--surface-soft);
  color: var(--ink-500);
}

.global-search svg {
  width: 1rem;
  height: 1rem;
}

.global-search input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink-950);
  font-size: var(--text-sm);
}

.global-search input::placeholder {
  color: var(--ink-500);
}

kbd {
  padding: 0.1rem 0.4rem;
  border: 1px solid var(--ink-100);
  border-radius: 0.25rem;
  background: var(--surface-raised);
  color: var(--ink-500);
  font-family: var(--font-number);
  font-size: 0.65rem;
  white-space: nowrap;
}

.notification-count {
  position: absolute;
  right: 0.1rem;
  top: 0.05rem;
  display: grid;
  min-width: 1.05rem;
  height: 1.05rem;
  place-items: center;
  border: 2px solid var(--surface-raised);
  border-radius: 999px;
  background: var(--danger-700);
  color: oklch(98% 0.01 82);
  font-family: var(--font-number);
  font-size: 0.6rem;
  font-weight: 800;
}

.role-switcher {
  position: relative;
  gap: var(--space-2);
  min-width: 12.5rem;
  padding: 0.35rem 0.5rem;
  border-left: 1px solid var(--ink-100);
  cursor: pointer;
}

.role-avatar {
  display: grid;
  width: 2.25rem;
  height: 2.25rem;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 50%;
  background: var(--navy-100);
  color: var(--navy-800);
  font-family: "STSong", "Songti SC", serif;
  font-size: var(--text-sm);
  font-weight: 800;
}

.role-copy {
  display: grid;
  min-width: 0;
}

.role-copy small {
  color: var(--ink-500);
  font-size: 0.65rem;
}

.role-copy select {
  max-width: 9rem;
  padding: 0;
  border: 0;
  outline: 0;
  appearance: none;
  background: transparent;
  color: var(--ink-950);
  cursor: pointer;
  font-size: var(--text-xs);
  font-weight: 700;
}

.role-switcher > svg {
  width: 1rem;
  height: 1rem;
  margin-left: auto;
  color: var(--ink-500);
}

#main-content {
  min-height: calc(100vh - var(--topbar-height));
}

.app-view {
  width: min(100%, 100rem);
  margin: 0 auto;
  padding: var(--space-8);
  animation: page-enter 450ms var(--ease-out) both;
}

@keyframes page-enter {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.page-head {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-6);
  margin-bottom: var(--space-8);
  padding-left: var(--space-6);
}

.page-head::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0.25rem;
  background: linear-gradient(var(--gold-500), var(--gold-700));
  content: "";
}

.page-head-copy {
  display: grid;
  gap: var(--space-2);
}

.page-head h1,
.drawer-header h2,
.dialog-head h2 {
  margin: 0;
  color: var(--navy-950);
  font-family: "STSong", "Songti SC", serif;
  font-weight: 800;
  letter-spacing: -0.025em;
}

.page-head h1 {
  font-size: var(--text-xl);
}

.page-head p {
  max-width: 62ch;
  margin: 0;
  color: var(--ink-650);
  font-size: var(--text-sm);
}

.eyebrow {
  color: var(--gold-700);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.page-actions,
.inline-actions,
.button-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
}

.button {
  display: inline-flex;
  min-height: 2.75rem;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 0.65rem 1rem;
  border: 1px solid var(--ink-200);
  border-radius: var(--radius-sm);
  background: var(--surface-raised);
  color: var(--ink-800);
  cursor: pointer;
  font-size: var(--text-sm);
  font-weight: 700;
  transition: transform 120ms var(--ease-out), box-shadow 120ms var(--ease-out), background 120ms var(--ease-out), border-color 120ms var(--ease-out);
}

.button svg {
  width: 1rem;
  height: 1rem;
}

.button:hover {
  border-color: var(--navy-600);
  background: var(--navy-050);
  box-shadow: var(--shadow-sm);
  transform: translateY(-1px);
}

.button:active {
  transform: translateY(0) scale(0.99);
}

.button.primary {
  border-color: var(--navy-900);
  background: var(--navy-900);
  color: oklch(97% 0.01 82);
  box-shadow: 0 5px 14px oklch(24% 0.06 242 / 0.16);
}

.button.primary:hover {
  background: var(--navy-800);
}

.button.gold {
  border-color: var(--gold-600);
  background: var(--gold-500);
  color: var(--navy-950);
}

.button.danger {
  border-color: var(--danger-700);
  background: var(--danger-700);
  color: oklch(98% 0.01 82);
}

.button.ghost {
  border-color: transparent;
  background: transparent;
  box-shadow: none;
  color: var(--navy-700);
}

.button.small {
  min-height: 2.1rem;
  padding: 0.35rem 0.65rem;
  font-size: var(--text-xs);
}

.button:disabled,
.icon-button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}

.metric-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(10rem, 1fr));
  margin-bottom: var(--space-8);
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-md);
  background: var(--surface-raised);
  box-shadow: var(--shadow-sm);
}

.metric {
  position: relative;
  min-width: 0;
  padding: var(--space-6);
  border-right: 1px solid var(--ink-100);
  cursor: pointer;
  transition: background 150ms var(--ease-out);
}

.metric:last-child {
  border-right: 0;
}

.metric:hover {
  background: var(--gold-100);
}

.metric-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  color: var(--ink-650);
  font-size: var(--text-xs);
}

.metric-label svg {
  width: 1rem;
  height: 1rem;
  color: var(--gold-700);
}

.metric-value {
  margin-top: var(--space-2);
  color: var(--navy-950);
  font-family: var(--font-number);
  font-size: 1.85rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.04em;
}

.metric-unit {
  margin-left: 0.2rem;
  color: var(--ink-500);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0;
}

.metric-trend {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  margin-top: var(--space-2);
  color: var(--success-700);
  font-family: var(--font-number);
  font-size: 0.7rem;
}

.metric-trend.warning {
  color: var(--danger-700);
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(19rem, 0.8fr);
  grid-template-areas:
    "journey tasks"
    "portfolio tasks"
    "projects projects";
  gap: var(--space-6);
}

.panel {
  min-width: 0;
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-md);
  background: var(--surface-raised);
  box-shadow: var(--shadow-sm);
}

.panel.flat {
  border-radius: 0;
  box-shadow: none;
}

.panel-head {
  display: flex;
  min-height: 4rem;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: 0 var(--space-6);
  border-bottom: 1px solid var(--ink-100);
}

.panel-title {
  display: grid;
  gap: 0.15rem;
}

.panel-title h2,
.panel-title h3 {
  margin: 0;
  color: var(--navy-950);
  font-size: var(--text-base);
}

.panel-title span {
  color: var(--ink-500);
  font-size: 0.68rem;
}

.panel-body {
  padding: var(--space-6);
}

.journey-panel {
  grid-area: journey;
}

.tasks-panel {
  grid-area: tasks;
}

.portfolio-panel {
  grid-area: portfolio;
}

.projects-panel {
  grid-area: projects;
}

.journey-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--space-6);
  overflow: hidden;
  padding: var(--space-6);
  background:
    linear-gradient(115deg, var(--navy-950), var(--navy-800));
  color: oklch(96% 0.01 82);
}

.journey-hero::after {
  position: absolute;
  right: -4rem;
  top: -8rem;
  width: 20rem;
  height: 20rem;
  border: 1px solid oklch(82% 0.05 78 / 0.2);
  border-radius: 50%;
  box-shadow: 0 0 0 3rem oklch(82% 0.05 78 / 0.04), 0 0 0 7rem oklch(82% 0.05 78 / 0.035);
  content: "";
}

.journey-copy,
.journey-number {
  position: relative;
  z-index: 1;
}

.journey-copy h3 {
  margin: var(--space-1) 0 0;
  font-family: "STSong", "Songti SC", serif;
  font-size: var(--text-lg);
}

.journey-copy p {
  max-width: 50ch;
  margin: var(--space-2) 0 0;
  color: oklch(79% 0.018 242);
  font-size: var(--text-xs);
}

.journey-number {
  align-self: center;
  color: var(--gold-500);
  font-family: var(--font-number);
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.journey-flow {
  display: grid;
  grid-template-columns: repeat(7, minmax(5.5rem, 1fr));
  padding: var(--space-6);
  overflow-x: auto;
}

.journey-step {
  position: relative;
  display: grid;
  min-width: 5.5rem;
  justify-items: center;
  gap: var(--space-2);
  text-align: center;
}

.journey-step:not(:last-child)::after {
  position: absolute;
  left: calc(50% + 1.1rem);
  right: calc(-50% + 1.1rem);
  top: 1.05rem;
  height: 1px;
  background: var(--ink-200);
  content: "";
}

.journey-step.done:not(:last-child)::after {
  background: var(--success-700);
}

.step-node {
  position: relative;
  z-index: 1;
  display: grid;
  width: 2.2rem;
  height: 2.2rem;
  place-items: center;
  border: 1px solid var(--ink-200);
  border-radius: 50%;
  background: var(--surface-raised);
  color: var(--ink-500);
  font-family: var(--font-number);
  font-size: var(--text-xs);
  font-weight: 800;
}

.journey-step.done .step-node {
  border-color: var(--success-700);
  background: var(--success-100);
  color: var(--success-700);
}

.journey-step.current .step-node {
  border-color: var(--gold-600);
  background: var(--gold-500);
  color: var(--navy-950);
  box-shadow: 0 0 0 5px var(--gold-100);
}

.journey-step strong {
  color: var(--ink-800);
  font-size: var(--text-xs);
}

.journey-step span {
  color: var(--ink-500);
  font-size: 0.65rem;
}

.task-list,
.activity-list,
.document-list,
.notice-list {
  display: grid;
}

.task-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: start;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-6);
  border-bottom: 1px solid var(--ink-100);
  cursor: pointer;
  transition: background 120ms var(--ease-out);
}

.task-item:last-child {
  border-bottom: 0;
}

.task-item:hover {
  background: var(--navy-050);
}

.task-priority {
  width: 0.45rem;
  height: 0.45rem;
  margin-top: 0.45rem;
  border-radius: 50%;
  background: var(--warning-700);
}

.task-priority.high {
  background: var(--danger-700);
  box-shadow: 0 0 0 4px var(--danger-100);
}

.task-content {
  min-width: 0;
}

.task-content strong {
  display: block;
  overflow: hidden;
  color: var(--ink-950);
  font-size: var(--text-sm);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-content p {
  margin: 0.25rem 0 0;
  color: var(--ink-500);
  font-size: var(--text-xs);
}

.task-time {
  color: var(--ink-500);
  font-family: var(--font-number);
  font-size: 0.68rem;
  white-space: nowrap;
}

.portfolio-layout {
  display: grid;
  grid-template-columns: minmax(16rem, 0.75fr) minmax(0, 1.4fr);
  align-items: center;
  gap: var(--space-8);
}

.portfolio-chart {
  display: flex;
  align-items: center;
  gap: var(--space-6);
}

.donut {
  position: relative;
  display: grid;
  width: 9rem;
  height: 9rem;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(var(--navy-700) 0 42%, var(--gold-500) 42% 66%, var(--success-700) 66% 84%, var(--ink-200) 84% 100%);
}

.donut::after {
  position: absolute;
  inset: 1.2rem;
  border-radius: 50%;
  background: var(--surface-raised);
  content: "";
}

.donut-center {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
}

.donut-center strong {
  color: var(--navy-950);
  font-family: var(--font-number);
  font-size: 1.25rem;
}

.donut-center span {
  color: var(--ink-500);
  font-size: 0.65rem;
}

.legend {
  display: grid;
  gap: var(--space-2);
}

.legend-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--space-2);
  color: var(--ink-650);
  font-size: var(--text-xs);
}

.legend-swatch {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 2px;
}

.legend-item strong {
  color: var(--ink-800);
  font-family: var(--font-number);
}

.trend-chart {
  min-width: 0;
}

.trend-chart svg {
  width: 100%;
  height: 10rem;
  overflow: visible;
}

.chart-grid-line {
  stroke: var(--ink-100);
  stroke-width: 1;
}

.chart-area {
  fill: oklch(45% 0.07 242 / 0.08);
  stroke: none;
}

.chart-line {
  fill: none;
  stroke: var(--navy-700);
  stroke-width: 3;
}

.chart-dot {
  fill: var(--surface-raised);
  stroke: var(--gold-700);
  stroke-width: 2.5;
}

.chart-labels {
  display: flex;
  justify-content: space-between;
  color: var(--ink-500);
  font-family: var(--font-number);
  font-size: 0.65rem;
}

.table-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-6);
  border-bottom: 1px solid var(--ink-100);
}

.filter-tabs {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  overflow-x: auto;
}

.filter-tab {
  min-height: 2.25rem;
  padding: 0.35rem 0.75rem;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--ink-650);
  cursor: pointer;
  font-size: var(--text-xs);
  white-space: nowrap;
}

.filter-tab:hover,
.filter-tab.active {
  border-color: var(--navy-100);
  background: var(--navy-100);
  color: var(--navy-800);
  font-weight: 700;
}

.filter-tab span {
  margin-left: var(--space-1);
  color: var(--ink-500);
  font-family: var(--font-number);
}

.compact-search {
  display: flex;
  min-height: 2.25rem;
  align-items: center;
  gap: var(--space-2);
  padding: 0 var(--space-3);
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-sm);
  background: var(--surface-raised);
}

.compact-search svg {
  width: 0.9rem;
  height: 0.9rem;
  color: var(--ink-500);
}

.compact-search input {
  width: 13rem;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink-950);
  font-size: var(--text-xs);
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
}

.data-table th,
.data-table td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--ink-100);
  text-align: left;
  vertical-align: middle;
  white-space: nowrap;
}

.data-table th {
  background: var(--surface-soft);
  color: var(--ink-650);
  font-size: 0.7rem;
  font-weight: 700;
}

.data-table td {
  color: var(--ink-800);
  font-size: var(--text-xs);
}

.data-table tbody tr {
  cursor: pointer;
  transition: background 120ms var(--ease-out);
}

.data-table tbody tr:hover {
  background: var(--navy-050);
}

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

.project-cell {
  display: grid;
  gap: 0.15rem;
  min-width: 12rem;
}

.project-cell strong {
  color: var(--ink-950);
  font-size: var(--text-sm);
}

.project-cell span {
  color: var(--ink-500);
  font-family: var(--font-number);
  font-size: 0.67rem;
}

.money {
  color: var(--navy-950);
  font-family: var(--font-number);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.badge,
.status-chip,
.tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 700;
  white-space: nowrap;
}

.badge,
.status-chip {
  min-height: 1.55rem;
  padding: 0.2rem 0.55rem;
}

.status-chip::before {
  width: 0.35rem;
  height: 0.35rem;
  border-radius: 50%;
  background: currentColor;
  content: "";
}

.status-chip.success,
.badge.success {
  background: var(--success-100);
  color: var(--success-700);
}

.status-chip.warning,
.badge.warning {
  background: var(--warning-100);
  color: var(--warning-700);
}

.status-chip.danger,
.badge.danger {
  background: var(--danger-100);
  color: var(--danger-700);
}

.status-chip.info,
.badge.info {
  background: var(--info-100);
  color: var(--info-700);
}

.status-chip.neutral,
.badge.neutral {
  background: var(--surface-strong);
  color: var(--ink-650);
}

.table-link {
  border: 0;
  background: transparent;
  color: var(--navy-700);
  cursor: pointer;
  font-size: var(--text-xs);
  font-weight: 700;
}

.empty-state {
  display: grid;
  min-height: 16rem;
  place-items: center;
  padding: var(--space-8);
  text-align: center;
}

.empty-state-inner {
  display: grid;
  max-width: 28rem;
  justify-items: center;
  gap: var(--space-3);
}

.empty-state-icon {
  display: grid;
  width: 3.5rem;
  height: 3.5rem;
  place-items: center;
  border-radius: 50%;
  background: var(--navy-100);
  color: var(--navy-700);
}

.empty-state-icon svg {
  width: 1.5rem;
  height: 1.5rem;
}

.empty-state h3,
.empty-state p {
  margin: 0;
}

.empty-state p {
  color: var(--ink-500);
  font-size: var(--text-sm);
}

.filters-panel {
  margin-bottom: var(--space-6);
  padding: var(--space-4) var(--space-6);
}

.filter-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(10rem, 1fr)) auto;
  align-items: end;
  gap: var(--space-4);
}

.field {
  display: grid;
  gap: var(--space-2);
}

.field label,
.field-label {
  color: var(--ink-650);
  font-size: var(--text-xs);
  font-weight: 700;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 2.75rem;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--ink-200);
  border-radius: var(--radius-sm);
  outline: 0;
  background: var(--surface-raised);
  color: var(--ink-950);
  font-size: var(--text-sm);
  transition: border-color 120ms var(--ease-out), box-shadow 120ms var(--ease-out);
}

.field textarea {
  min-height: 6rem;
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--navy-600);
  box-shadow: 0 0 0 3px var(--navy-100);
}

.field small {
  color: var(--ink-500);
  font-size: 0.68rem;
}

.field-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-4);
}

.required::after {
  margin-left: 0.2rem;
  color: var(--danger-700);
  content: "*";
}

.form-section {
  padding: var(--space-6);
  border-bottom: 1px solid var(--ink-100);
}

.form-section:last-child {
  border-bottom: 0;
}

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

.section-heading h2,
.section-heading h3 {
  margin: 0;
  color: var(--navy-950);
  font-size: var(--text-base);
}

.section-heading p {
  margin: 0.25rem 0 0;
  color: var(--ink-500);
  font-size: var(--text-xs);
}

.upload-zone {
  display: grid;
  min-height: 7rem;
  place-items: center;
  padding: var(--space-4);
  border: 1px dashed var(--ink-200);
  border-radius: var(--radius-sm);
  background: var(--surface-soft);
  color: var(--ink-500);
  cursor: pointer;
  text-align: center;
  transition: border-color 120ms var(--ease-out), background 120ms var(--ease-out);
}

.upload-zone:hover {
  border-color: var(--navy-600);
  background: var(--navy-050);
}

.upload-zone svg {
  width: 1.6rem;
  height: 1.6rem;
  margin: 0 auto var(--space-2);
  color: var(--navy-700);
}

.upload-zone strong {
  display: block;
  color: var(--ink-800);
  font-size: var(--text-sm);
}

.upload-zone span {
  font-size: var(--text-xs);
}

.material-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: var(--space-3);
}

.material-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--space-3);
  min-height: 4.5rem;
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-sm);
  background: var(--surface-raised);
}

.file-icon {
  display: grid;
  width: 2.25rem;
  height: 2.5rem;
  place-items: center;
  border: 1px solid var(--navy-100);
  border-radius: 0.3rem;
  background: var(--navy-050);
  color: var(--navy-700);
}

.file-icon svg {
  width: 1rem;
  height: 1rem;
}

.file-info {
  display: grid;
  min-width: 0;
  gap: 0.15rem;
}

.file-info strong {
  overflow: hidden;
  color: var(--ink-800);
  font-size: var(--text-xs);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-info span {
  color: var(--ink-500);
  font-size: 0.65rem;
}

.check-control {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  cursor: pointer;
  font-size: var(--text-xs);
}

.check-control input {
  width: 1rem;
  height: 1rem;
  accent-color: var(--navy-700);
}

.project-identity {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--space-6);
  margin-bottom: var(--space-6);
  overflow: hidden;
  padding: var(--space-6) var(--space-8);
  border-radius: var(--radius-md);
  background: linear-gradient(112deg, var(--navy-950), var(--navy-800));
  color: oklch(95% 0.01 82);
  box-shadow: var(--shadow-md);
}

.project-identity::after {
  position: absolute;
  right: 8%;
  top: -7rem;
  width: 18rem;
  height: 18rem;
  border: 1px solid oklch(84% 0.06 78 / 0.16);
  transform: rotate(45deg);
  content: "";
}

.project-title-wrap,
.project-summary {
  position: relative;
  z-index: 1;
}

.project-title-wrap {
  display: grid;
  gap: var(--space-2);
}

.project-title-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3);
}

.project-title-line h1 {
  margin: 0;
  color: oklch(98% 0.01 82);
  font-family: "STSong", "Songti SC", serif;
  font-size: var(--text-xl);
}

.project-title-wrap p {
  margin: 0;
  color: oklch(78% 0.02 242);
  font-family: var(--font-number);
  font-size: var(--text-xs);
}

.project-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-6);
  margin-top: var(--space-3);
}

.project-meta-item {
  display: grid;
  gap: 0.1rem;
}

.project-meta-item span {
  color: oklch(70% 0.018 242);
  font-size: 0.66rem;
}

.project-meta-item strong {
  color: oklch(94% 0.01 82);
  font-family: var(--font-number);
  font-size: var(--text-sm);
}

.project-summary {
  display: grid;
  align-content: center;
  justify-items: end;
  gap: var(--space-2);
  text-align: right;
}

.project-summary strong {
  color: var(--gold-500);
  font-family: var(--font-number);
  font-size: 2rem;
  letter-spacing: -0.04em;
}

.project-summary span {
  color: oklch(76% 0.018 242);
  font-size: var(--text-xs);
}

.project-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 19rem;
  gap: var(--space-6);
  align-items: start;
}

.process-rail {
  position: sticky;
  top: calc(var(--topbar-height) + var(--space-6));
}

.vertical-timeline {
  display: grid;
  padding: var(--space-4) var(--space-6);
}

.timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--space-3);
  padding: var(--space-3) 0;
}

.timeline-item:not(:last-child)::before {
  position: absolute;
  left: 0.52rem;
  top: 2rem;
  bottom: -0.4rem;
  width: 1px;
  background: var(--ink-200);
  content: "";
}

.timeline-dot {
  position: relative;
  z-index: 1;
  width: 1.1rem;
  height: 1.1rem;
  margin-top: 0.15rem;
  border: 2px solid var(--ink-200);
  border-radius: 50%;
  background: var(--surface-raised);
}

.timeline-item.done .timeline-dot {
  border-color: var(--success-700);
  background: var(--success-700);
  box-shadow: inset 0 0 0 3px var(--surface-raised);
}

.timeline-item.current .timeline-dot {
  border-color: var(--gold-600);
  background: var(--gold-500);
  box-shadow: 0 0 0 4px var(--gold-100);
}

.timeline-copy {
  display: grid;
  gap: 0.15rem;
}

.timeline-copy strong {
  color: var(--ink-800);
  font-size: var(--text-xs);
}

.timeline-item.current .timeline-copy strong {
  color: var(--gold-700);
}

.timeline-copy span {
  color: var(--ink-500);
  font-size: 0.65rem;
}

.tab-list {
  display: flex;
  gap: var(--space-1);
  overflow-x: auto;
  padding: 0 var(--space-6);
  border-bottom: 1px solid var(--ink-100);
}

.tab-button {
  position: relative;
  min-height: 3.25rem;
  padding: 0 var(--space-3);
  border: 0;
  background: transparent;
  color: var(--ink-650);
  cursor: pointer;
  font-size: var(--text-sm);
  white-space: nowrap;
}

.tab-button.active {
  color: var(--navy-800);
  font-weight: 700;
}

.tab-button.active::after {
  position: absolute;
  right: var(--space-3);
  bottom: -1px;
  left: var(--space-3);
  height: 2px;
  background: var(--gold-600);
  content: "";
}

.tab-panel {
  padding: var(--space-6);
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
}

.info-item {
  display: grid;
  min-height: 4.75rem;
  align-content: start;
  gap: 0.3rem;
  padding: var(--space-4);
  border-right: 1px solid var(--ink-100);
  border-bottom: 1px solid var(--ink-100);
}

.info-item:nth-child(3n) {
  border-right: 0;
}

.info-item span {
  color: var(--ink-500);
  font-size: 0.68rem;
}

.info-item strong {
  color: var(--ink-800);
  font-size: var(--text-sm);
  font-weight: 600;
}

.approval-record {
  display: grid;
  grid-template-columns: 8rem 1px minmax(0, 1fr) auto;
  gap: var(--space-4);
  padding: var(--space-4) 0;
  border-bottom: 1px solid var(--ink-100);
}

.approval-record:last-child {
  border-bottom: 0;
}

.approval-time {
  color: var(--ink-500);
  font-family: var(--font-number);
  font-size: var(--text-xs);
}

.approval-line {
  background: var(--ink-100);
}

.approval-copy {
  display: grid;
  gap: 0.3rem;
}

.approval-copy strong {
  color: var(--ink-800);
  font-size: var(--text-sm);
}

.approval-copy span,
.approval-copy p {
  margin: 0;
  color: var(--ink-500);
  font-size: var(--text-xs);
}

.split-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(18rem, 0.65fr);
  gap: var(--space-6);
  align-items: start;
}

.summary-stack {
  display: grid;
  gap: var(--space-4);
}

.summary-block {
  padding: var(--space-4);
  border-bottom: 1px solid var(--ink-100);
}

.summary-block:last-child {
  border-bottom: 0;
}

.summary-block span {
  color: var(--ink-500);
  font-size: 0.68rem;
}

.summary-block strong {
  display: block;
  margin-top: var(--space-1);
  color: var(--ink-800);
  font-size: var(--text-sm);
}

.summary-block p {
  margin: var(--space-1) 0 0;
  color: var(--ink-650);
  font-size: var(--text-xs);
}

.risk-banner {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--space-4);
  margin-bottom: var(--space-6);
  padding: var(--space-4) var(--space-6);
  border: 1px solid var(--warning-700);
  border-radius: var(--radius-sm);
  background: var(--warning-100);
}

.risk-icon {
  display: grid;
  width: 2.5rem;
  height: 2.5rem;
  place-items: center;
  border-radius: 50%;
  background: var(--warning-700);
  color: oklch(98% 0.01 82);
}

.risk-icon svg {
  width: 1.25rem;
  height: 1.25rem;
}

.risk-banner strong {
  color: var(--warning-700);
  font-size: var(--text-sm);
}

.risk-banner p {
  margin: 0.2rem 0 0;
  color: var(--ink-650);
  font-size: var(--text-xs);
}

.stage-board {
  display: grid;
  grid-template-columns: repeat(4, minmax(14rem, 1fr));
  gap: var(--space-4);
  overflow-x: auto;
  align-items: start;
}

.stage-column {
  min-width: 14rem;
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-md);
  background: var(--surface-soft);
}

.stage-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-4);
  border-bottom: 1px solid var(--ink-100);
}

.stage-head strong {
  font-size: var(--text-sm);
}

.stage-head span {
  color: var(--ink-500);
  font-family: var(--font-number);
  font-size: var(--text-xs);
}

.stage-items {
  display: grid;
  gap: var(--space-3);
  padding: var(--space-3);
}

.stage-card {
  display: grid;
  gap: var(--space-3);
  padding: var(--space-4);
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-sm);
  background: var(--surface-raised);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: transform 150ms var(--ease-out), border-color 150ms var(--ease-out);
}

.stage-card:hover {
  border-color: var(--navy-600);
  transform: translateY(-2px);
}

.stage-card strong {
  color: var(--ink-950);
  font-size: var(--text-sm);
}

.stage-card p {
  margin: 0;
  color: var(--ink-500);
  font-size: var(--text-xs);
}

.stage-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding-top: var(--space-2);
  border-top: 1px solid var(--ink-100);
  color: var(--ink-500);
  font-size: 0.68rem;
}

.stage-assignee {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.mini-avatar {
  display: grid;
  width: 1.45rem;
  height: 1.45rem;
  place-items: center;
  border-radius: 50%;
  background: var(--navy-100);
  color: var(--navy-800);
  font-size: 0.62rem;
  font-weight: 800;
}

.contract-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 22rem;
  gap: var(--space-6);
}

.contract-preview {
  min-height: 42rem;
  padding: var(--space-8) clamp(1.5rem, 6vw, 5rem);
  border: 1px solid var(--ink-100);
  background:
    linear-gradient(var(--ink-100), var(--ink-100)) 2.2rem 0 / 1px 100% no-repeat,
    var(--surface-raised);
  box-shadow: var(--shadow-sm);
}

.contract-preview h2 {
  margin: var(--space-6) 0 var(--space-8);
  color: var(--ink-950);
  font-family: "STSong", "Songti SC", serif;
  font-size: 1.5rem;
  text-align: center;
}

.contract-preview p {
  margin: 0 0 var(--space-4);
  color: var(--ink-800);
  font-family: "STSong", "Songti SC", serif;
  font-size: var(--text-sm);
  line-height: 2;
  text-indent: 2em;
}

.contract-highlight {
  padding: 0.1rem 0.2rem;
  background: var(--gold-100);
  color: var(--gold-700);
  font-weight: 700;
}

.seal-placeholder {
  display: grid;
  width: 7rem;
  height: 7rem;
  margin: var(--space-8) 0 0 auto;
  place-items: center;
  border: 3px double var(--danger-700);
  border-radius: 50%;
  color: var(--danger-700);
  font-family: "STSong", "Songti SC", serif;
  font-size: var(--text-xs);
  font-weight: 800;
  transform: rotate(-8deg);
}

.report-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--space-6);
}

.report-grid .span-8 { grid-column: span 8; }
.report-grid .span-4 { grid-column: span 4; }
.report-grid .span-6 { grid-column: span 6; }
.report-grid .span-12 { grid-column: 1 / -1; }

.bar-chart {
  display: grid;
  gap: var(--space-3);
}

.bar-row {
  display: grid;
  grid-template-columns: 7rem minmax(0, 1fr) 4rem;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--text-xs);
}

.bar-label {
  overflow: hidden;
  color: var(--ink-650);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bar-track {
  height: 0.5rem;
  overflow: hidden;
  border-radius: 999px;
  background: var(--surface-strong);
}

.bar-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--navy-700), var(--navy-600));
  transform-origin: left;
  animation: bar-grow 650ms var(--ease-out) both;
}

@keyframes bar-grow {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}

.bar-value {
  color: var(--ink-800);
  font-family: var(--font-number);
  font-weight: 700;
  text-align: right;
}

.report-downloads {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
  gap: var(--space-3);
}

.report-file {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4);
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: border-color 120ms var(--ease-out), background 120ms var(--ease-out);
}

.report-file:hover {
  border-color: var(--navy-600);
  background: var(--navy-050);
}

.notification-panel,
.detail-drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: var(--z-drawer);
  height: 100vh;
  border-left: 1px solid var(--ink-100);
  background: var(--surface-raised);
  box-shadow: var(--shadow-md);
  transform: translateX(105%);
  transition: transform 300ms var(--ease-out);
}

.notification-panel.open,
.detail-drawer.open {
  transform: translateX(0);
}

.notification-panel {
  top: var(--topbar-height);
  width: min(23rem, 100vw);
  height: calc(100vh - var(--topbar-height));
  z-index: var(--z-dropdown);
}

.detail-drawer {
  width: min(34rem, 100vw);
  overflow-y: auto;
}

.drawer-header,
.dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-6);
  border-bottom: 1px solid var(--ink-100);
}

.drawer-header h2,
.dialog-head h2 {
  margin-top: 0.15rem;
  font-size: var(--text-lg);
}

.drawer-body {
  padding: var(--space-6);
}

.drawer-amount {
  margin-bottom: var(--space-6);
  padding: var(--space-6);
  background: var(--navy-950);
  color: oklch(95% 0.01 82);
}

.drawer-amount span {
  color: oklch(72% 0.018 242);
  font-size: var(--text-xs);
}

.drawer-amount strong {
  display: block;
  margin-top: var(--space-1);
  color: var(--gold-500);
  font-family: var(--font-number);
  font-size: 2rem;
}

.notification-head {
  display: flex;
  min-height: 4rem;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space-6);
  border-bottom: 1px solid var(--ink-100);
}

.notification-head h2 {
  margin: 0;
  font-size: var(--text-base);
}

.notice-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--space-3);
  padding: var(--space-4) var(--space-6);
  border-bottom: 1px solid var(--ink-100);
}

.notice-symbol {
  display: grid;
  width: 2rem;
  height: 2rem;
  place-items: center;
  border-radius: 50%;
  background: var(--navy-100);
  color: var(--navy-700);
}

.notice-symbol svg {
  width: 0.95rem;
  height: 0.95rem;
}

.notice-copy strong {
  display: block;
  color: var(--ink-800);
  font-size: var(--text-xs);
}

.notice-copy p {
  margin: 0.2rem 0;
  color: var(--ink-500);
  font-size: 0.68rem;
}

.notice-copy time {
  color: var(--ink-350);
  font-family: var(--font-number);
  font-size: 0.62rem;
}

.action-dialog {
  width: min(38rem, calc(100vw - 2rem));
  max-height: calc(100vh - 2rem);
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-md);
  background: var(--surface-raised);
  color: var(--ink-950);
  box-shadow: var(--shadow-md);
}

.action-dialog::backdrop {
  background: oklch(15% 0.025 242 / 0.48);
  backdrop-filter: blur(2px);
}

.dialog-body {
  max-height: calc(100vh - 13rem);
  overflow-y: auto;
  padding: var(--space-6);
}

.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: var(--space-2);
  padding: var(--space-4) var(--space-6);
  border-top: 1px solid var(--ink-100);
  background: var(--surface-soft);
}

.decision-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-3);
  margin-bottom: var(--space-6);
}

.decision-option {
  position: relative;
}

.decision-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.decision-option label {
  display: grid;
  min-height: 5rem;
  align-content: center;
  justify-items: center;
  gap: var(--space-1);
  border: 1px solid var(--ink-200);
  border-radius: var(--radius-sm);
  background: var(--surface-raised);
  cursor: pointer;
  font-size: var(--text-xs);
  font-weight: 700;
  text-align: center;
}

.decision-option input:checked + label {
  border-color: var(--navy-700);
  background: var(--navy-100);
  color: var(--navy-800);
  box-shadow: 0 0 0 2px var(--navy-100);
}

.decision-option label svg {
  width: 1.15rem;
  height: 1.15rem;
}

.command-palette {
  position: fixed;
  inset: 0;
  z-index: var(--z-drawer);
  display: grid;
  visibility: hidden;
  place-items: start center;
  padding-top: min(15vh, 8rem);
  background: oklch(15% 0.025 242 / 0.45);
  opacity: 0;
  transition: opacity 180ms var(--ease-out), visibility 180ms;
}

.command-palette.open {
  visibility: visible;
  opacity: 1;
}

.command-box {
  width: min(40rem, calc(100vw - 2rem));
  overflow: hidden;
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-md);
  background: var(--surface-raised);
  box-shadow: var(--shadow-md);
  transform: translateY(-8px);
  transition: transform 220ms var(--ease-out);
}

.command-palette.open .command-box {
  transform: translateY(0);
}

.command-input-wrap {
  display: flex;
  min-height: 4rem;
  align-items: center;
  gap: var(--space-3);
  padding: 0 var(--space-4);
  border-bottom: 1px solid var(--ink-100);
}

.command-input-wrap svg {
  width: 1.25rem;
  height: 1.25rem;
  color: var(--navy-700);
}

.command-input-wrap input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink-950);
  font-size: var(--text-base);
}

.command-results {
  max-height: 24rem;
  overflow-y: auto;
  padding: var(--space-2);
}

.command-result {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--space-3);
  width: 100%;
  min-height: 3.25rem;
  padding: var(--space-2) var(--space-3);
  border: 0;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--ink-800);
  cursor: pointer;
  text-align: left;
}

.command-result:hover,
.command-result:focus-visible {
  background: var(--navy-100);
}

.command-result-icon {
  display: grid;
  width: 2rem;
  height: 2rem;
  place-items: center;
  border-radius: var(--radius-sm);
  background: var(--surface-strong);
  color: var(--navy-700);
}

.command-result-icon svg {
  width: 1rem;
  height: 1rem;
}

.command-result-copy {
  display: grid;
}

.command-result-copy strong {
  font-size: var(--text-sm);
}

.command-result-copy span {
  color: var(--ink-500);
  font-size: 0.68rem;
}

.command-result em {
  color: var(--ink-500);
  font-family: var(--font-number);
  font-size: 0.65rem;
  font-style: normal;
}

.toast-region {
  position: fixed;
  right: var(--space-6);
  bottom: var(--space-6);
  z-index: var(--z-toast);
  display: grid;
  width: min(23rem, calc(100vw - 2rem));
  gap: var(--space-2);
}

.toast {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4);
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-sm);
  background: var(--surface-raised);
  box-shadow: var(--shadow-md);
  animation: toast-in 300ms var(--ease-out) both;
}

@keyframes toast-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.toast-symbol {
  display: grid;
  width: 1.75rem;
  height: 1.75rem;
  place-items: center;
  border-radius: 50%;
  background: var(--success-100);
  color: var(--success-700);
}

.toast-symbol svg {
  width: 0.95rem;
  height: 0.95rem;
}

.toast strong {
  display: block;
  font-size: var(--text-sm);
}

.toast span {
  color: var(--ink-500);
  font-size: 0.68rem;
}

.mobile-backdrop {
  position: fixed;
  inset: 0;
  z-index: calc(var(--z-sticky) - 1);
  display: none;
  background: oklch(15% 0.025 242 / 0.45);
}

.mobile-only {
  display: none;
}

@media (max-width: 80rem) {
  .metric-strip {
    grid-template-columns: repeat(3, 1fr);
  }

  .metric:nth-child(3) {
    border-right: 0;
  }

  .metric:nth-child(n + 4) {
    border-top: 1px solid var(--ink-100);
  }

  .dashboard-grid {
    grid-template-columns: minmax(0, 1fr) 20rem;
  }

  .portfolio-layout {
    grid-template-columns: 1fr;
  }

  .filter-form {
    grid-template-columns: repeat(2, minmax(12rem, 1fr));
  }

  .report-grid .span-8,
  .report-grid .span-4,
  .report-grid .span-6 {
    grid-column: span 6;
  }
}

@media (max-width: 64rem) {
  .sidebar {
    transform: translateX(-105%);
  }

  .app-shell.menu-open .sidebar {
    transform: translateX(0);
  }

  .app-shell.menu-open .mobile-backdrop {
    display: block;
  }

  .workspace {
    margin-left: 0;
  }

  .menu-toggle {
    display: grid;
  }

  .global-search {
    display: none;
  }

  .dashboard-grid {
    grid-template-columns: 1fr;
    grid-template-areas:
      "journey"
      "tasks"
      "portfolio"
      "projects";
  }

  .project-workspace,
  .contract-layout,
  .split-layout {
    grid-template-columns: 1fr;
  }

  .process-rail {
    position: static;
  }

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

  .info-item:nth-child(3n) {
    border-right: 1px solid var(--ink-100);
  }

  .info-item:nth-child(2n) {
    border-right: 0;
  }
}

@media (max-width: 48rem) {
  :root {
    --topbar-height: 4rem;
  }

  .topbar {
    padding: 0 var(--space-3);
  }

  .app-view {
    padding: var(--space-4);
  }

  .page-head {
    align-items: flex-start;
    flex-direction: column;
    margin-bottom: var(--space-6);
  }

  .page-head h1 {
    font-size: var(--text-lg);
  }

  .breadcrumb span:first-child,
  .breadcrumb-separator {
    display: none;
  }

  .role-switcher {
    min-width: 0;
    border-left: 0;
  }

  .role-copy small,
  .role-switcher > svg {
    display: none;
  }

  .role-copy select {
    width: 6.5rem;
  }

  .notification-button {
    display: none;
  }

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

  .metric {
    padding: var(--space-4);
  }

  .metric:nth-child(2n) {
    border-right: 0;
  }

  .metric:nth-child(3) {
    border-right: 1px solid var(--ink-100);
  }

  .metric:nth-child(n + 3) {
    border-top: 1px solid var(--ink-100);
  }

  .metric-value {
    font-size: 1.45rem;
  }

  .metric:last-child {
    grid-column: 1 / -1;
  }

  .journey-hero,
  .project-identity {
    grid-template-columns: 1fr;
    padding: var(--space-6);
  }

  .journey-number {
    justify-self: start;
  }

  .project-summary {
    justify-items: start;
    text-align: left;
  }

  .panel-head,
  .table-toolbar {
    align-items: flex-start;
    flex-direction: column;
    padding: var(--space-4);
  }

  .panel-body,
  .tab-panel {
    padding: var(--space-4);
  }

  .portfolio-chart {
    align-items: flex-start;
    flex-direction: column;
  }

  .filter-form,
  .field-row,
  .info-grid {
    grid-template-columns: 1fr;
  }

  .info-item,
  .info-item:nth-child(3n),
  .info-item:nth-child(2n) {
    border-right: 0;
  }

  .compact-search,
  .compact-search input {
    width: 100%;
  }

  .approval-record {
    grid-template-columns: 1fr auto;
  }

  .approval-line {
    display: none;
  }

  .approval-copy {
    grid-column: 1 / -1;
  }

  .decision-options {
    grid-template-columns: 1fr;
  }

  .report-grid .span-8,
  .report-grid .span-4,
  .report-grid .span-6,
  .report-grid .span-12 {
    grid-column: 1 / -1;
  }

  .bar-row {
    grid-template-columns: 5.5rem minmax(0, 1fr) 3.5rem;
  }

  .dialog-actions {
    align-items: stretch;
    flex-direction: column-reverse;
  }

  .dialog-actions .button {
    width: 100%;
  }

  .toast-region {
    right: 1rem;
    bottom: max(1rem, env(safe-area-inset-bottom));
  }
}

@media (pointer: coarse) {
  .button,
  .filter-tab,
  .tab-button,
  .nav-item,
  .table-link {
    min-height: 2.75rem;
  }
}

@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;
  }
}
