.demo {
  --demo-bg: #0b1b2e;
  --demo-panel: #102238;
  --demo-line: #34506a;
  --demo-text: #edf5fd;
  --demo-soft: #b7c9da;
  --demo-muted: #9ab0c6;
  --demo-accent: #85c4ff;
  color: var(--demo-text);
  background: var(--demo-bg);
  border: 1px solid var(--demo-line);
  border-radius: 6px;
  overflow: hidden;
  font-size: .875rem;
  line-height: 1.6;
  color-scheme: dark;
}
.demo button, .demo select, .demo textarea { font: inherit; }
.demo button { cursor: pointer; }
.demo button:focus-visible, .demo select:focus-visible, .demo textarea:focus-visible { outline: 3px solid #a5d3ff; outline-offset: 3px; }
.demo [hidden] { display: none !important; }
.demo-toolbar { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; padding: 16px 20px; border-bottom: 1px solid var(--demo-line); }
.demo-brand { display: flex; align-items: center; gap: 10px; }
.demo-brand > span { display: grid; line-height: 1.35; }
.demo-brand strong { font-size: 1rem; }
.demo-brand small { color: var(--demo-muted); font-size: .8125rem; }
.demo-badge { display: inline-block; padding: 3px 8px; color: var(--demo-accent); border: 1px solid #476f94; border-radius: 3px; font-size: .75rem; white-space: nowrap; }
.demo-controls { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.demo-controls label { color: var(--demo-soft); }
.demo select { min-height: 42px; min-width: 0; max-width: 100%; color: var(--demo-text); background: var(--demo-panel); border: 1px solid #567591; border-radius: 4px; padding: 8px 28px 8px 10px; }
.demo-icon-button { display: grid; place-items: center; width: 42px; height: 42px; flex: 0 0 auto; border: 1px solid #567591; border-radius: 4px; color: var(--demo-soft); background: transparent; }
.demo-icon-button svg { width: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.demo-icon-button:hover { background: var(--demo-panel); color: #fff; }
.demo-briefing { display: grid; grid-template-columns: minmax(180px, .6fr) minmax(0, 1.4fr); gap: 24px; padding: 18px 20px; background: #102238; border-bottom: 1px solid var(--demo-line); }
.demo-briefing > div { display: grid; gap: 4px; }
.demo-briefing strong { color: var(--demo-text); font-weight: 700; }
.demo-briefing span { color: var(--demo-muted); font-size: .8125rem; }
.demo-briefing p { margin: 0; color: var(--demo-soft); }
.demo-navigation { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0 20px; padding: 0 20px; border-bottom: 1px solid var(--demo-line); }
.demo-navigation > div, .demo-case-tabs { display: flex; flex-wrap: wrap; max-width: 100%; }
.demo-navigation button, .demo-case-tabs button { min-height: 48px; border: 0; border-bottom: 2px solid transparent; color: var(--demo-muted); background: transparent; padding: 12px 14px; font-weight: 650; }
.demo-navigation button:first-child { padding-left: 0; }
.demo-navigation button[aria-selected="true"], .demo-case-tabs button[aria-selected="true"] { color: #f7fbff; border-color: #69b6ff; }
.demo-navigation button:hover, .demo-case-tabs button:hover { color: #fff; background: #152d47; }
.demo-navigation > span { color: var(--demo-soft); font-size: .875rem; padding-block: 8px; }
.demo-investigations { display: grid; grid-template-columns: 245px minmax(0, 1fr); }
.demo-queue { border-right: 1px solid var(--demo-line); background: #0d1e32; }
.demo-queue-heading { padding: 20px 18px 14px; }
.demo-queue-heading h3 { margin: 0; font-size: .9375rem; }
.demo-queue-heading > span { color: var(--demo-muted); font-size: .8125rem; }
.demo-alert { width: 100%; display: grid; gap: 8px; padding: 18px; color: var(--demo-soft); text-align: left; border: 0; border-top: 1px solid var(--demo-line); border-left: 3px solid transparent; background: transparent; }
.demo-alert:last-child { border-bottom: 1px solid var(--demo-line); }
.demo-alert[aria-pressed="true"] { border-left-color: #77bfff; background: #17324d; }
.demo-alert:hover { background: #162d46; }
.demo-alert strong { color: var(--demo-text); font-size: .9375rem; line-height: 1.5; }
.demo-alert small, .demo-alert-id { font-size: .8125rem; color: var(--demo-muted); }
.demo-alert-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.demo-alert-top > span:last-child { text-align: right; font-size: .875rem; max-width: 114px; }
.demo-severity { padding: 3px 7px; border: 1px solid; border-radius: 3px; font-size: .875rem; font-weight: 750; line-height: 1.5; }
.demo-severity-high { color: #ffc1c9; background: #472733; border-color: #a96375; }
.demo-severity-medium { color: #ffcf92; background: #392e23; border-color: #9a754a; }
.demo-queue-note { margin: 20px 18px; color: var(--demo-muted); font-size: .8125rem; }
.demo-case { min-width: 0; }
.demo-case-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 24px 24px 0; }
.demo-case-heading > div > span { color: var(--demo-muted); font: .75rem/1.6 ui-monospace, monospace; }
.demo-case-heading h3 { margin: 6px 0 0; color: #f3f8fd; font-size: 1.375rem; line-height: 1.4; }
.demo-case-heading > .demo-severity { flex: 0 0 auto; margin-top: 4px; }
.demo-case-summary { margin: 12px 24px 18px; color: var(--demo-soft); }
.demo-entity-strip { margin: 0 24px 20px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.demo-entity-strip dt { color: var(--demo-muted); font-size: .75rem; }
.demo-entity-strip dd { margin: 3px 0 0; color: var(--demo-text); font-family: ui-monospace, monospace; font-size: .8125rem; overflow-wrap: anywhere; }
.demo-case-tabs { padding: 0 10px; border-block: 1px solid var(--demo-line); background: #0d1e32; }
.demo-evidence { display: grid; grid-template-columns: 230px minmax(0, 1fr); }
.demo-timeline-wrap { min-width: 0; border-right: 1px solid var(--demo-line); }
.demo-panel-title { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 20px 18px 14px; }
.demo-panel-title h4 { margin: 0; font-size: .9375rem; }
.demo-panel-title > span { color: var(--demo-muted); font-size: .75rem; white-space: nowrap; }
.demo-timeline { margin: 0; padding: 0 0 20px; list-style: none; }
.demo-timeline button { width: 100%; display: grid; grid-template-columns: 1fr; gap: 5px; padding: 14px 18px; text-align: left; border: 0; border-left: 3px solid transparent; color: var(--demo-soft); background: transparent; }
.demo-timeline button[aria-pressed="true"] { border-left-color: #77bfff; background: #17324d; }
.demo-timeline button:hover { background: #142b44; }
.demo-timeline time { font: .75rem/1.5 ui-monospace, monospace; color: var(--demo-accent); }
.demo-timeline button > span { display: grid; gap: 3px; }
.demo-timeline small { color: var(--demo-muted); font-size: .75rem; }
.demo-timeline strong { color: var(--demo-text); font-size: .875rem; font-weight: 600; line-height: 1.45; }
.demo-timeline em { color: var(--demo-soft); font-size: .8125rem; font-style: normal; }
.demo-inspector { padding: 22px; min-width: 0; }
.demo-inspector-heading > span { color: var(--demo-accent); font: .75rem/1.5 ui-monospace, monospace; }
.demo-inspector-heading h4 { margin: 6px 0; font-size: 1.125rem; line-height: 1.5; }
.demo-inspector-heading p { margin: 0 0 18px; color: var(--demo-muted); font-size: .8125rem; }
.demo-fields { margin: 0; border-top: 1px solid var(--demo-line); }
.demo-fields > div { display: grid; grid-template-columns: minmax(95px, .4fr) minmax(0, .6fr); gap: 16px; padding: 11px 0; border-bottom: 1px solid var(--demo-line); }
.demo-fields dt { color: var(--demo-muted); font-size: .875rem; }
.demo-fields dd { margin: 0; color: var(--demo-text); font: .875rem/1.7 ui-monospace, monospace; overflow-wrap: anywhere; }
.demo-limit { margin-top: 20px; color: var(--demo-soft); }
.demo-limit strong { font-size: .8125rem; color: #cbdced; }
.demo-limit p { margin: 5px 0 0; font-size: .875rem; }
.demo-coach { margin: 20px 0 0; padding: 14px 16px; border-left: 2px solid var(--demo-accent); background: #142d47; }
.demo-coach strong { color: var(--demo-accent); font-size: .8125rem; }
.demo-coach p { margin: 6px 0 0; color: var(--demo-soft); }
.demo-hint { margin-top: 20px; border-block: 1px solid var(--demo-line); }
.demo-hint summary { padding: 14px 0; color: var(--demo-accent); cursor: pointer; }
.demo-hint p { margin: 0 0 14px; color: var(--demo-soft); }
.demo-guidance-note { color: var(--demo-muted); margin: 20px 0 0; font-size: .8125rem; }
.demo-button { min-height: 42px; padding: 10px 14px; color: var(--demo-text); background: #182f46; border: 1px solid #567591; border-radius: 4px; font-size: .875rem; font-weight: 650; line-height: 1.5; }
.demo-button:hover { background: #244462; border-color: #9acbfa; }
.demo-button[aria-pressed="true"] { border-color: #a0cbef; background: #25415b; }
.demo-button-primary { background: #1166bf; color: #fff; border-color: #559ee5; }
.demo-button-primary:hover { background: #155ca1; }
.demo-evidence-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.demo-context, .demo-notes { padding: 0 24px 24px; }
.demo-context .demo-panel-title, .demo-notes .demo-panel-title { padding-inline: 0; }
.demo-context-list { margin: 0; border-top: 1px solid var(--demo-line); }
.demo-context-list > div { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 24px; padding: 18px 0; border-bottom: 1px solid var(--demo-line); }
.demo-context-list dt { color: var(--demo-text); font-weight: 650; }
.demo-context-list dd { margin: 0; color: var(--demo-soft); }
.demo-correlation { margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--demo-line); }
.demo-correlation h4 { font-size: .9375rem; margin: 0 0 10px; }
.demo-correlation ul { color: var(--demo-soft); padding-left: 20px; margin: 0; }
.demo-correlation p { color: var(--demo-muted); margin-bottom: 0; }
.demo-pinned { padding: 14px 16px; border: 1px solid var(--demo-line); background: #102238; margin-bottom: 20px; }
.demo-pinned strong { font-size: .875rem; }
.demo-pinned p { color: var(--demo-muted); font-size: .8125rem; margin: 6px 0 0; }
.demo-pinned ul { margin: 8px 0 0; padding-left: 20px; color: var(--demo-soft); }
.demo-pinned li span { color: var(--demo-accent); font: .75rem ui-monospace, monospace; }
.demo-notes label { display: block; color: var(--demo-text); font-size: .875rem; font-weight: 600; margin-bottom: 8px; }
.demo textarea { display: block; width: 100%; min-height: 138px; padding: 12px; color: var(--demo-text); border: 1px solid #567591; border-radius: 4px; background: #0d1e32; resize: vertical; }
.demo textarea::placeholder { color: #a9bed1; }
.demo-notes form > p { color: var(--demo-muted); font-size: .8125rem; margin: 8px 0 20px; }
.demo-decision-row { display: flex; align-items: end; gap: 14px; flex-wrap: wrap; }
.demo-decision-row > div { flex: 1; min-width: min(260px, 100%); }
.demo-decision-row select { width: 100%; }
.demo-result { margin-top: 24px; padding: 20px; border-left: 3px solid #82c6ff; background: #172f49; color: var(--demo-soft); }
.demo-result strong { color: var(--demo-text); }
.demo-result p { margin: 8px 0 14px; }
.demo-result small { display: block; color: var(--demo-muted); font-size: .8125rem; }
.demo-result .demo-button { margin-top: 16px; }
.demo-organisation, .demo-history { padding: 28px; }
.demo-view-heading { display: flex; align-items: flex-start; gap: 24px; justify-content: space-between; margin-bottom: 24px; }
.demo-view-heading > div > span { color: var(--demo-accent); font-size: .8125rem; }
.demo-view-heading h3 { margin: 8px 0 12px; font-size: 1.375rem; line-height: 1.4; }
.demo-view-heading p { max-width: 750px; color: var(--demo-soft); margin: 0; }
.demo-org-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-block: 1px solid var(--demo-line); margin-bottom: 24px; }
.demo-org-summary > div { padding: 18px 22px; border-right: 1px solid var(--demo-line); }
.demo-org-summary > div:first-child { padding-left: 0; }
.demo-org-summary > div:last-child { border-right: 0; }
.demo-org-summary p { margin: 6px 0 0; color: var(--demo-muted); }
.demo-table-wrap { width: 100%; overflow-x: auto; }
.demo-table { width: 100%; border-collapse: collapse; text-align: left; }
.demo-table caption { text-align: left; padding-bottom: 12px; color: var(--demo-soft); }
.demo-table th, .demo-table td { vertical-align: top; padding: 16px 14px; border-block: 1px solid var(--demo-line); font-weight: 400; }
.demo-table thead th { color: var(--demo-muted); font-size: .8125rem; background: #102238; }
.demo-table tbody th { color: var(--demo-text); font-weight: 600; }
.demo-table td { color: var(--demo-soft); }
.demo-table small { display: block; color: var(--demo-muted); font-size: .8125rem; margin-top: 4px; }
.demo-text-button { color: var(--demo-accent); padding: 4px 0; border: 0; text-decoration: underline; text-underline-offset: 4px; background: transparent; text-align: left; }
.demo-text-button:hover { color: #fff; }
.demo-org-note { color: var(--demo-muted); margin: 20px 0 0; }
.demo-history-record { margin-top: 20px; padding: 20px 0; border-top: 1px solid var(--demo-line); }
.demo-history-record > div { display: grid; gap: 6px; }
.demo-history-record > div > span:first-child { color: var(--demo-muted); font: .75rem ui-monospace, monospace; }
.demo-history-record strong { font-size: 1rem; }
.demo-history-status { justify-self: start; border: 1px solid #567591; padding: 2px 7px; color: var(--demo-accent); font-size: .8125rem; }
.demo-history-record p { margin: 12px 0; color: var(--demo-soft); white-space: pre-wrap; overflow-wrap: anywhere; }
.demo-history-record small { display: block; color: var(--demo-muted); font-size: .8125rem; }
.demo-history-record button { display: block; margin-top: 12px; }
.demo-history-empty { margin-top: 20px; padding: 24px 0; border-top: 1px solid var(--demo-line); }
.demo-history-empty p { color: var(--demo-muted); margin: 8px 0 18px; }
.demo-footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 20px; padding: 14px 20px; border-top: 1px solid var(--demo-line); background: #102238; color: var(--demo-muted); font-size: .75rem; }
.demo-mobile-picker { display: none; }
.demo-reset-dialog { max-width: min(460px, calc(100% - 32px)); border: 1px solid #8ca5ba; border-radius: 6px; padding: 24px; background: #102238; color: #edf5fd; }
.demo-reset-dialog::backdrop { background: rgba(0, 10, 22, .75); }
.demo-reset-dialog h3 { margin: 0 0 10px; }
.demo-reset-dialog p { color: #b7c9da; margin: 0 0 22px; }
.demo-reset-dialog > div { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 12px; }
.demo-explanation { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 24px; color: #b8cadd; font-size: .875rem; }
.demo-explanation p { margin: 0; }
.demo-explanation strong { color: #eef6ff; }
.demo-glossary { margin-top: 24px; border-block: 1px solid #34506a; color: #b8cadd; }
.demo-glossary summary { min-height: 48px; padding: 16px 0; color: #d2e8ff; font-size: .9375rem; font-weight: 650; cursor: pointer; }
.demo-glossary dl { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 40px; margin: 8px 0 24px; }
.demo-glossary dt { color: #edf5fd; font-weight: 650; }
.demo-glossary dd { margin: 6px 0 0; font-size: .875rem; }
.demo-noscript { padding: 24px; border: 1px solid #34506a; color: #b8cadd; }
@media (max-width: 1050px) {
  .demo-investigations { grid-template-columns: 210px minmax(0, 1fr); }
  .demo-evidence { grid-template-columns: 1fr; }
  .demo-timeline-wrap { border-right: 0; border-bottom: 1px solid var(--demo-line); }
  .demo-timeline { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
  .demo-investigations { grid-template-columns: 1fr; }
  .demo-queue { border-right: 0; border-bottom: 1px solid var(--demo-line); }
  .demo-queue-heading { display: flex; justify-content: space-between; gap: 16px; padding-bottom: 10px; }
  .demo-queue [data-demo-queue] { display: none; }
  .demo-mobile-picker { display: grid; gap: 8px; padding: 0 18px 16px; }
  .demo-mobile-picker label { color: var(--demo-soft); font-size: .8125rem; }
  .demo-mobile-picker select { width: 100%; font-size: 1rem; }
  .demo-queue-note { margin: 0 18px 16px; }
  .demo-timeline { display: none; }
  .demo-briefing { grid-template-columns: 1fr; gap: 12px; }
  .demo-navigation { flex-wrap: wrap; gap: 0; padding-bottom: 10px; }
  .demo-navigation > div { width: 100%; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .demo-navigation button { padding-inline: 4px; font-size: .875rem; }
  .demo-navigation > span { width: 100%; }
  .demo-controls { margin-left: 0; width: 100%; }
  .demo-controls select { flex: 1; font-size: 1rem; }
  .demo-context-list > div { grid-template-columns: 1fr; gap: 8px; }
  .demo-org-summary { grid-template-columns: 1fr; }
  .demo-org-summary > div { padding: 16px 0; border-right: 0; border-bottom: 1px solid var(--demo-line); }
  .demo-org-summary > div:last-child { border-bottom: 0; }
  .demo-table { min-width: 650px; }
  .demo-explanation, .demo-glossary dl { grid-template-columns: 1fr; gap: 16px; }
  .demo-table-wrap { border: 1px solid var(--demo-line); }
}
@media (max-width: 480px) {
  .demo-toolbar { padding: 16px; gap: 12px; }
  .demo-badge { margin-left: auto; }
  .demo-navigation { padding-inline: 16px; }
  .demo-case-heading { padding: 20px 16px 0; flex-direction: column; gap: 10px; }
  .demo-case-summary { margin-inline: 16px; }
  .demo-entity-strip { margin-inline: 16px; grid-template-columns: 1fr 1fr; gap: 12px; }
  .demo-case-tabs { padding-inline: 4px; }
  .demo-case-tabs button { flex: 1; min-width: 0; padding-inline: 6px; font-size: .875rem; }
  .demo-inspector { padding: 20px 16px; }
  .demo-fields > div { grid-template-columns: 1fr; gap: 4px; }
  .demo-evidence-actions { display: grid; }
  .demo-context, .demo-notes { padding-inline: 16px; }
  .demo-panel-title { flex-wrap: wrap; }
  .demo textarea, .demo-decision-row select { font-size: 1rem; }
  .demo-decision-row { display: grid; grid-template-columns: minmax(0, 1fr); }
  .demo-organisation, .demo-history { padding: 20px 16px; }
  .demo-view-heading { flex-direction: column; gap: 14px; }
}
@media (max-width: 360px) {
  .demo-navigation > div { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .demo-navigation button:last-child { grid-column: 1 / -1; }
}
@media (forced-colors: active) {
  .demo button, .demo select, .demo textarea { border: 1px solid ButtonText; }
  .demo button[aria-selected="true"], .demo button[aria-pressed="true"] { outline: 2px solid Highlight; outline-offset: -3px; }
}
