:root {
  --brand-blue: #0A84FF;
  --approval-green: #30D158;
  --ink: #0A0A0A;
  --muted: #5F6875;
  --soft-text: #7B8490;
  --line: #E1E6EC;
  --line-strong: #CAD2DC;
  --surface: #FFFFFF;
  --surface-soft: #F7F9FC;
  --surface-blue: #F3F8FF;
  --surface-green: #F2FBF5;
  --surface-risk: #FFF7F2;
  --risk: #C95816;
  --risk-line: #EEB68F;
  --shadow: 0 8px 22px rgba(10, 35, 66, 0.05);
  --radius: 14px;
  --font: Inter, "SF Pro Display", "Noto Sans TC", "PingFang TC", system-ui, -apple-system, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  background: #FFFFFF;
  color: var(--ink);
  font-family: var(--font);
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background: #FFFFFF;
  color: var(--ink);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
}

button,
a {
  font: inherit;
}

button {
  color: inherit;
}

button:focus-visible,
a:focus-visible {
  outline: 3px solid rgba(10, 132, 255, 0.32);
  outline-offset: 2px;
}

.skip-link {
  position: fixed;
  top: -100px;
  left: 16px;
  z-index: 100;
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--ink);
  color: #FFFFFF;
  text-decoration: none;
}

.skip-link:focus {
  top: 16px;
}

.experience-label {
  position: sticky;
  top: 0;
  z-index: 200;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--line);
  background: #F7F9FC;
  color: #576171;
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0.04em;
}

.app-frame {
  min-height: calc(100vh - 28px);
  background: #FFFFFF;
}

.topbar {
  min-height: 82px;
  display: grid;
  grid-template-columns: 218px 1fr auto;
  align-items: center;
  gap: 22px;
  padding: 10px 24px 10px 18px;
  border-bottom: 1px solid var(--line);
  background: #FFFFFF;
}

.brand-lockup {
  width: 190px;
  height: 60px;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.brand-lockup img {
  width: 190px;
  height: 60px;
  object-fit: contain;
}

.page-heading {
  min-width: 0;
}

.page-heading h1,
.panel h2,
.inspector h2,
.mobile-sheet h2 {
  margin: 0;
  color: var(--ink);
}

.page-heading h1 {
  font-size: 22px;
  font-weight: 720;
  letter-spacing: -0.025em;
}

.eyebrow,
.section-kicker {
  margin: 0 0 4px;
  color: var(--soft-text);
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 18px;
}

.identity-block {
  display: flex;
  align-items: center;
  gap: 10px;
}

.identity-block strong,
.identity-block small {
  display: block;
  white-space: nowrap;
}

.identity-block strong {
  font-size: 13px;
}

.identity-block small {
  margin-top: 2px;
  color: var(--soft-text);
  font-size: 10px;
}

.identity-avatar,
.person-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border: 1px solid #CFE3FA;
  background: #EAF4FF;
  color: #0069CF;
  font-weight: 760;
}

.identity-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  font-size: 13px;
}

.attention-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 11px;
  border: 1px solid var(--risk-line);
  border-radius: 999px;
  background: var(--surface-risk);
  color: #A24612;
  font-size: 11px;
  font-weight: 750;
  white-space: nowrap;
}

.status-mark {
  width: 8px;
  height: 8px;
  border: 2px solid #A24612;
  border-radius: 50%;
  background: #FFFFFF;
}

.app-layout {
  min-height: calc(100vh - 110px);
  display: grid;
  grid-template-columns: 176px minmax(0, 1fr);
}

.side-nav {
  position: relative;
  padding: 22px 12px;
  border-right: 1px solid var(--line);
  background: #FBFCFE;
}

.nav-section-label {
  margin: 0 10px 8px;
  color: #939AA4;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.nav-section-label:not(:first-child) {
  margin-top: 24px;
}

.nav-item {
  min-height: 40px;
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 3px 0;
  padding: 8px 10px;
  border: 1px solid transparent;
  border-radius: 9px;
  color: #55606E;
  font-size: 11px;
  font-weight: 650;
  text-decoration: none;
}

.nav-item:hover {
  background: #F2F6FA;
  color: var(--ink);
}

.nav-item.is-active {
  border-color: #CCE4FF;
  background: #ECF5FF;
  color: #0067CE;
}

.nav-icon {
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line-strong);
  border-radius: 7px;
  background: #FFFFFF;
  font-size: 8px;
  font-weight: 800;
}

.nav-item.is-active .nav-icon {
  border-color: #8FC7FF;
  color: #0067CE;
}

.nav-boundary {
  position: absolute;
  right: 12px;
  bottom: 18px;
  left: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #FFFFFF;
}

.nav-boundary span,
.nav-boundary strong {
  display: block;
}

.nav-boundary span {
  color: var(--soft-text);
  font-size: 9px;
}

.nav-boundary strong {
  margin-top: 4px;
  font-size: 10px;
}

.main-content {
  min-width: 0;
  padding: 14px 16px 18px;
  background: #FFFFFF;
}

.process-strip {
  min-height: 58px;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  align-items: center;
  margin: 0 0 14px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #FFFFFF;
  box-shadow: 0 3px 10px rgba(10, 35, 66, 0.03);
  list-style: none;
  overflow: hidden;
}

.process-strip li {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 10px;
}

.process-strip li + li {
  border-left: 1px solid var(--line);
}

.process-strip strong,
.process-strip small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.process-strip strong {
  font-size: 10px;
}

.process-strip small {
  margin-top: 2px;
  color: var(--soft-text);
  font-size: 8px;
}

.step-index {
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: #FFFFFF;
  color: #687280;
  font-size: 8px;
  font-weight: 800;
}

.process-strip .is-complete .step-index {
  border-color: #A7E6BA;
  background: var(--surface-green);
  color: #147A34;
}

.process-strip .is-current {
  background: var(--surface-risk);
}

.process-strip .is-current .step-index {
  border-color: var(--risk);
  background: var(--risk);
  color: #FFFFFF;
}

.workspace-grid {
  display: grid;
  grid-template-columns: minmax(238px, 0.82fr) minmax(500px, 1.82fr) minmax(296px, 0.98fr);
  align-items: start;
  gap: 14px;
}

.panel {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.panel-heading,
.summary-heading,
.record-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.panel h2 {
  font-size: 15px;
  font-weight: 720;
  letter-spacing: -0.02em;
}

.flow-pane {
  padding: 16px;
}

.flow-id,
.authority-badge,
.exception-count,
.record-state {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  padding: 5px 8px;
  border-radius: 999px;
  white-space: nowrap;
  font-size: 8px;
  font-weight: 750;
}

.flow-id {
  border: 1px solid var(--line);
  background: var(--surface-soft);
  color: #697482;
}

.flow-timeline {
  position: relative;
  display: grid;
  gap: 7px;
  margin-top: 13px;
}

.flow-timeline::before {
  position: absolute;
  top: 24px;
  bottom: 24px;
  left: 18px;
  width: 1px;
  background: var(--line-strong);
  content: "";
}

.flow-node {
  position: relative;
  z-index: 1;
  width: 100%;
  min-height: 58px;
  display: grid;
  grid-template-columns: 15px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 9px 9px 9px 11px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #FFFFFF;
  text-align: left;
}

button.flow-node {
  cursor: pointer;
  transition: border-color 150ms ease, background 150ms ease;
}

button.flow-node:hover,
button.flow-node.is-selected {
  border-color: #8FC7FF;
  background: #F7FBFF;
}

.flow-node.is-current {
  border-color: var(--risk-line);
  background: var(--surface-risk);
}

.flow-node.is-waiting {
  background: #FAFBFC;
}

.node-marker {
  width: 13px;
  height: 13px;
  border: 3px solid #FFFFFF;
  border-radius: 50%;
  background: var(--line-strong);
  box-shadow: 0 0 0 1px var(--line-strong);
}

.flow-node.is-done .node-marker {
  background: var(--approval-green);
  box-shadow: 0 0 0 1px #69CE86;
}

.flow-node.is-current .node-marker {
  background: var(--risk);
  box-shadow: 0 0 0 1px var(--risk);
}

.flow-node strong,
.flow-node small {
  display: block;
}

.flow-node strong {
  font-size: 10px;
}

.flow-node small {
  margin-top: 3px;
  color: var(--soft-text);
  font-size: 8px;
}

.node-state {
  color: #6F7985;
  font-size: 8px;
  font-weight: 750;
}

.is-done .node-state {
  color: #147A34;
}

.is-current .node-state {
  color: #A24612;
}

.lane-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  margin-top: 12px;
}

.lane-card {
  min-height: 74px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #FFFFFF;
  text-align: left;
  cursor: pointer;
}

.lane-card:hover,
.lane-card.is-selected {
  border-color: #8FC7FF;
}

.lane-card span,
.lane-card strong {
  display: block;
}

.lane-card span {
  font-size: 8px;
  font-weight: 750;
}

.lane-card strong {
  margin-top: 5px;
  font-size: 9px;
  line-height: 1.45;
}

.lane-card.normal {
  border-color: #BDEBCB;
  background: var(--surface-green);
}

.lane-card.normal span {
  color: #147A34;
}

.lane-card.exception {
  border-color: var(--risk-line);
  background: var(--surface-risk);
}

.lane-card.exception span {
  color: #A24612;
}

.main-column,
.decision-rail {
  display: grid;
  gap: 12px;
}

.work-summary {
  padding: 15px 17px;
}

.synthetic-note {
  margin: 4px 0 0;
  color: var(--soft-text);
  font-size: 9px;
}

.amount-block {
  text-align: right;
}

.amount-block span,
.amount-block strong,
.amount-block small {
  display: block;
}

.amount-block span {
  color: var(--soft-text);
  font-size: 8px;
}

.amount-block strong {
  margin-top: 2px;
  font-size: 20px;
  letter-spacing: -0.03em;
}

.amount-block small {
  margin-top: 2px;
  color: var(--soft-text);
  font-size: 8px;
}

.context-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin-top: 12px;
}

.context-card {
  position: relative;
  min-height: 94px;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #FFFFFF;
  text-align: left;
  cursor: pointer;
}

.context-card:hover,
.context-card.is-selected {
  border-color: #8FC7FF;
  background: #F7FBFF;
}

.context-card.current-data {
  border-left: 3px solid var(--brand-blue);
}

.context-card.history-context {
  border-left: 3px solid #6A7A8C;
  background: #FAFBFC;
}

.context-label,
.context-card strong,
.context-card small,
.context-card .inspect-hint {
  display: block;
}

.context-label {
  color: var(--soft-text);
  font-size: 8px;
  font-weight: 750;
}

.context-card strong {
  margin-top: 4px;
  font-size: 11px;
}

.context-card small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 8px;
  line-height: 1.45;
}

.context-card .inspect-hint {
  margin-top: 7px;
  color: #1668B3;
  font-size: 8px;
  font-weight: 750;
}

.exception-card {
  padding: 15px 17px 12px;
}

.exception-count {
  border: 1px solid var(--risk-line);
  background: var(--surface-risk);
  color: #A24612;
}

.exception-table {
  margin-top: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}

.exception-row {
  width: 100%;
  min-height: 47px;
  display: grid;
  grid-template-columns: 1.15fr 1.1fr 1.05fr 0.74fr;
  align-items: center;
  padding: 0 10px;
  border: 0;
  border-top: 1px solid var(--line);
  background: #FFFFFF;
  color: #3F4854;
  font-size: 8px;
  text-align: left;
}

.exception-row > * {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.exception-row.table-head {
  min-height: 34px;
  border-top: 0;
  background: #F6F8FA;
  color: #75808C;
  font-size: 8px;
  font-weight: 750;
}

button.exception-row {
  cursor: pointer;
  transition: background 150ms ease, box-shadow 150ms ease;
}

button.exception-row:hover,
button.exception-row.is-selected {
  background: var(--surface-risk);
  box-shadow: inset 3px 0 0 var(--risk);
}

.exception-row strong {
  color: var(--ink);
  font-size: 9px;
}

.evidence-link {
  color: #1668B3;
  font-weight: 750;
}

.next-action-card {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) minmax(190px, 0.72fr);
  align-items: center;
  gap: 12px;
  padding: 13px 15px;
  border-color: #CFE3FA;
  background: #F7FBFF;
  box-shadow: none;
}

.recommendation-mark {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #8FC7FF;
  border-radius: 9px;
  background: #FFFFFF;
  color: #0069CF;
  font-size: 9px;
  font-weight: 850;
}

.next-action-copy h2 {
  font-size: 12px;
}

.next-action-copy p:not(.section-kicker) {
  margin: 5px 0 0;
  color: #53677D;
  font-size: 8px;
  line-height: 1.5;
}

.action-owner {
  display: grid;
  gap: 5px;
  margin: 0;
}

.action-owner div {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 6px;
}

.action-owner dt,
.action-owner dd {
  margin: 0;
  font-size: 8px;
}

.action-owner dt {
  color: var(--soft-text);
}

.action-owner dd {
  color: #2D455C;
  font-weight: 700;
}

.suggestion-boundary {
  grid-column: 2 / -1;
  padding-top: 8px;
  border-top: 1px solid #CFE3FA;
  color: #1668B3;
  font-size: 8px;
  font-weight: 750;
}

.decision-panel,
.execution-record,
.result-policy {
  padding: 14px;
}

.authority-badge {
  border: 1px solid #CFE3FA;
  background: var(--surface-blue);
  color: #1668B3;
}

.decision-options {
  display: grid;
  gap: 7px;
  margin-top: 11px;
}

.decision-option {
  position: relative;
  min-height: 48px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #FFFFFF;
  text-align: left;
  cursor: pointer;
}

.decision-option:disabled,
.decision-option.is-locked {
  cursor: not-allowed;
  border-color: var(--line);
  background: var(--surface-soft);
  color: var(--muted);
  box-shadow: none;
}

.decision-option:disabled:hover,
.decision-option.is-locked:hover {
  border-color: var(--line);
  background: var(--surface-soft);
  transform: none;
}

.locked-label {
  position: absolute;
  top: 11px;
  right: 12px;
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-muted);
  font-size: 10px;
  font-style: normal;
  font-weight: 750;
  letter-spacing: 0.05em;
}

.decision-option:hover,
.decision-option.is-selected {
  border-color: #8FC7FF;
  background: #F7FBFF;
}

.decision-option.is-chosen {
  border-color: #BDEBCB;
  background: var(--surface-green);
}

.decision-option strong,
.decision-option small {
  display: block;
}

.decision-option strong {
  font-size: 10px;
}

.decision-option small {
  margin-top: 3px;
  color: var(--soft-text);
  font-size: 8px;
}

.chosen-label {
  position: absolute;
  top: 9px;
  right: 9px;
  color: #147A34;
  font-size: 8px;
  font-weight: 800;
}

.named-decision {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 10px;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #FFFFFF;
}

.person-avatar {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  font-size: 11px;
}

.named-decision small,
.named-decision strong,
.named-decision em {
  display: block;
}

.named-decision small {
  color: var(--soft-text);
  font-size: 7px;
}

.named-decision strong {
  margin-top: 2px;
  font-size: 9px;
}

.named-decision em {
  margin-top: 2px;
  color: #6F7985;
  font-size: 7px;
  font-style: normal;
}

.decision-boundary {
  margin-top: 9px;
  padding: 8px 10px;
  border-left: 3px solid var(--brand-blue);
  background: var(--surface-blue);
}

.decision-boundary strong,
.decision-boundary span {
  display: block;
}

.decision-boundary strong {
  color: #125D9F;
  font-size: 9px;
}

.decision-boundary span {
  margin-top: 2px;
  color: #587086;
  font-size: 8px;
}

.record-state {
  border: 1px solid #BDEBCB;
  background: var(--surface-green);
  color: #147A34;
}

.record-id {
  display: block;
  margin: 10px 0;
  color: #147A34;
  font-size: 14px;
  letter-spacing: 0.02em;
}

.record-details {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin: 0 0 10px;
}

.record-details div {
  min-width: 0;
  padding: 7px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface-soft);
}

.record-details dt,
.record-details dd {
  margin: 0;
}

.record-details dt {
  color: var(--soft-text);
  font-size: 7px;
}

.record-details dd {
  margin-top: 3px;
  overflow: hidden;
  font-size: 8px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.record-link {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  border: 1px dashed var(--line-strong);
  border-radius: 8px;
  background: #FFFFFF;
  color: #1D67A7;
  font-size: 9px;
  font-weight: 750;
  cursor: pointer;
}

.record-link:hover,
.record-link.is-selected {
  border-color: var(--brand-blue);
  background: var(--surface-blue);
}

.result-policy h2 {
  margin-bottom: 9px;
  font-size: 12px;
}

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

.result-row {
  width: 100%;
  display: grid;
  grid-template-columns: 10px 1fr;
  align-items: center;
  gap: 8px;
  padding: 7px 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #FFFFFF;
  text-align: left;
  cursor: pointer;
}

.result-row:hover,
.result-row.is-selected {
  border-color: #8FC7FF;
  background: #F7FBFF;
}

.result-dot {
  width: 8px;
  height: 8px;
  border: 2px solid currentColor;
  border-radius: 50%;
  background: #FFFFFF;
}

.result-dot.done {
  color: #147A34;
  background: var(--approval-green);
}

.result-dot.failed {
  color: #A24612;
}

.result-dot.unknown {
  color: #6D7784;
  border-style: dashed;
}

.result-row strong,
.result-row small {
  display: block;
}

.result-row strong {
  font-size: 9px;
}

.result-row small {
  margin-top: 2px;
  color: var(--soft-text);
  font-size: 7px;
}

.inspector {
  padding: 12px 14px;
  border: 1px solid #CFE3FA;
  border-radius: 12px;
  background: #F7FBFF;
}

.inspector-label {
  display: block;
  margin-bottom: 5px;
  color: #0069CF;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.inspector h2 {
  font-size: 11px;
  line-height: 1.35;
}

.inspector p {
  margin: 5px 0;
  color: #53677D;
  font-size: 8px;
  line-height: 1.5;
}

.inspector small {
  color: #748392;
  font-size: 7px;
}

.mobile-sheet {
  display: none;
}

@media (max-width: 1320px) {
  .topbar {
    grid-template-columns: 190px 1fr auto;
    padding-right: 16px;
  }

  .identity-block {
    display: none;
  }

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

  .side-nav {
    display: none;
  }

  .workspace-grid {
    grid-template-columns: minmax(0, 1fr) 310px;
  }

  .flow-pane {
    grid-column: 1 / -1;
  }

  .flow-timeline {
    grid-template-columns: repeat(6, 1fr);
  }

  .flow-timeline::before {
    display: none;
  }

  .flow-node {
    min-height: 76px;
    grid-template-columns: 12px 1fr;
  }

  .flow-node .node-state {
    grid-column: 2;
  }

  .lane-split {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 760px) {
  body {
    padding-bottom: 210px;
  }

  .experience-label {
    min-height: 24px;
    height: auto;
    padding: 5px 12px;
    justify-content: flex-start;
    font-size: 8px;
    line-height: 1.35;
    white-space: normal;
  }

  .topbar {
    min-height: 72px;
    grid-template-columns: 132px minmax(0, 1fr);
    gap: 10px;
    padding: 6px 12px;
  }

  .brand-lockup,
  .brand-lockup img {
    width: 132px;
    height: 42px;
  }

  .page-heading {
    text-align: right;
  }

  .page-heading .eyebrow {
    font-size: 8px;
  }

  .page-heading h1 {
    font-size: 15px;
  }

  .topbar-actions {
    grid-column: 1 / -1;
    justify-content: flex-end;
    margin-top: -2px;
  }

  .attention-status {
    padding: 5px 8px;
    font-size: 9px;
  }

  .main-content {
    padding: 10px 10px 20px;
  }

  .process-strip {
    min-height: 50px;
    grid-template-columns: repeat(6, minmax(92px, 1fr));
    overflow-x: auto;
    scroll-snap-type: x proximity;
  }

  .process-strip li {
    min-width: 96px;
    gap: 6px;
    padding: 8px;
    scroll-snap-align: start;
  }

  .step-index {
    width: 21px;
    height: 21px;
    font-size: 8px;
  }

  .process-strip strong {
    font-size: 9px;
  }

  .process-strip small {
    display: none;
  }

  .workspace-grid {
    display: block;
  }

  .flow-pane,
  .main-column > *,
  .decision-rail > * {
    margin-bottom: 10px;
  }

  .flow-pane,
  .work-summary,
  .exception-card {
    padding: 12px;
  }

  .flow-timeline {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
  }

  .flow-node {
    min-width: 230px;
    min-height: 72px;
    scroll-snap-align: start;
  }

  .lane-split {
    grid-template-columns: 1fr 1fr;
  }

  .lane-card {
    min-height: 68px;
  }

  .summary-heading {
    display: block;
  }

  .amount-block {
    margin-top: 12px;
    padding-top: 10px;
    border-top: 1px solid var(--line);
    text-align: left;
  }

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

  .exception-row {
    grid-template-columns: 1.2fr 1fr 0.7fr;
  }

  .exception-row > :nth-child(3) {
    display: none;
  }

  .next-action-card {
    grid-template-columns: 36px 1fr;
  }

  .action-owner,
  .suggestion-boundary {
    grid-column: 1 / -1;
  }

  .action-owner {
    padding-top: 9px;
    border-top: 1px solid #CFE3FA;
  }

  .decision-rail {
    display: block;
  }

  .inspector {
    display: none;
  }

  .mobile-sheet {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 50;
    min-height: 190px;
    display: block;
    padding: 10px 18px calc(18px + env(safe-area-inset-bottom));
    border: 1px solid #CFE3FA;
    border-bottom: 0;
    border-radius: 18px 18px 0 0;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 -12px 34px rgba(10, 35, 66, 0.11);
  }

  .sheet-handle {
    width: 38px;
    height: 4px;
    margin: 0 auto 10px;
    border-radius: 4px;
    background: #D8DEE6;
  }

  .mobile-sheet h2 {
    font-size: 14px;
    line-height: 1.35;
  }

  .mobile-sheet p {
    margin: 7px 0;
    color: #53677D;
    font-size: 11px;
    line-height: 1.55;
  }

  .mobile-sheet small {
    color: #748392;
    font-size: 9px;
  }
}

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

@media (min-width: 1600px) {
  .topbar {
    min-height: 88px;
  }

  .page-heading h1 {
    font-size: 26px;
  }

  .eyebrow,
  .section-kicker {
    font-size: 11px;
  }

  .identity-block strong {
    font-size: 15px;
  }

  .identity-block small,
  .attention-status {
    font-size: 11px;
  }

  .nav-item {
    font-size: 12px;
  }

  .process-strip {
    min-height: 64px;
  }

  .process-strip strong {
    font-size: 12px;
  }

  .process-strip small {
    font-size: 9px;
  }

  .panel h2 {
    font-size: 17px;
  }

  .flow-pane {
    padding: 18px;
  }

  .flow-id,
  .authority-badge,
  .exception-count,
  .record-state {
    font-size: 9px;
  }

  .flow-node {
    min-height: 64px;
  }

  .flow-node strong {
    font-size: 11px;
  }

  .flow-node small,
  .node-state {
    font-size: 9px;
  }

  .lane-card {
    min-height: 80px;
  }

  .lane-card span {
    font-size: 9px;
  }

  .lane-card strong {
    font-size: 10px;
  }

  .synthetic-note {
    font-size: 10px;
  }

  .amount-block span,
  .amount-block small {
    font-size: 9px;
  }

  .amount-block strong {
    font-size: 24px;
  }

  .context-card {
    min-height: 102px;
  }

  .context-label,
  .context-card small,
  .context-card .inspect-hint {
    font-size: 9px;
  }

  .context-card strong {
    font-size: 12px;
  }

  .exception-row {
    min-height: 50px;
    font-size: 9px;
  }

  .exception-row.table-head {
    font-size: 9px;
  }

  .exception-row strong {
    font-size: 10px;
  }

  .next-action-copy h2 {
    font-size: 14px;
  }

  .next-action-copy p:not(.section-kicker),
  .action-owner dt,
  .action-owner dd,
  .suggestion-boundary {
    font-size: 9px;
  }

  .decision-option {
    min-height: 54px;
  }

  .decision-option strong {
    font-size: 12px;
  }

  .decision-option small,
  .named-decision em,
  .decision-boundary span {
    font-size: 9px;
  }

  .named-decision strong,
  .decision-boundary strong {
    font-size: 10px;
  }

  .record-details dt {
    font-size: 8px;
  }

  .record-details dd,
  .record-link {
    font-size: 9px;
  }

  .result-policy h2 {
    font-size: 14px;
  }

  .result-row strong {
    font-size: 10px;
  }

  .result-row small {
    font-size: 8px;
  }
}
