@layer reset, base, layout, components, responsive;
@layer components {
  /* Personal ownership stays visible; the demo has a persistent, distinct control bar. */
  .profile-button {
    display: flex;
    align-items: center;
    gap: 9px;
    border: 0;
    background: transparent;
    color: var(--text);
    cursor: pointer;
    font: inherit;
    max-width: 190px;
  }
  .profile-button #profile-name {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 12px;
  }
  .profile-button .avatar {
    flex: none;
  }
  .profile-notice {
    margin-bottom: 24px;
    padding: 12px 0 12px 16px;
    border-left: 2px solid var(--cyan);
    color: var(--muted);
    font-size: 13px;
    line-height: 1.65;
    max-width: 850px;
  }
  .demo-link {
    display: block;
    font-size: 12px;
    margin: 18px 0 10px;
    color: var(--cyan);
  }
  .demo-banner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 18px;
    border: 1px solid var(--amber);
    border-radius: 12px;
    padding: 18px 22px;
    margin-bottom: 28px;
    background: var(--surface);
  }
  .demo-banner strong {
    color: var(--amber);
    font-size: 17px;
  }
  .demo-banner p {
    margin: 5px 0 0;
    color: var(--muted);
    font-size: 12px;
    max-width: 540px;
  }
  .demo-controls {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
  }
  .demo-controls #demo-step {
    color: var(--muted);
    font-size: 12px;
    min-width: 65px;
  }
  #demo-share-status {
    flex-basis: 100%;
    overflow-wrap: anywhere;
    font-size: 12px;
    color: var(--cyan);
  }
  .reported-accounts {
    border-bottom: 1px solid var(--line);
    padding: 0 0 22px;
    margin-bottom: 24px;
  }
  .reported-accounts p {
    color: var(--text);
    font-size: 19px;
    margin: 10px 0 5px;
  }
  .reported-accounts span {
    color: var(--muted);
    font-size: 12px;
  }
  [hidden] {
    display: none !important;
  }
  @media (max-width: 700px) {
    .profile-button #profile-name {
      display: none;
    }
    .profile-button {
      padding: 0;
    }
    .demo-banner {
      padding: 16px;
      gap: 15px;
      margin-bottom: 20px;
    }
    .demo-controls {
      width: 100%;
    }
    .demo-controls .secondary-button {
      flex: 1;
      min-width: 150px;
    }
    .profile-notice {
      font-size: 12px;
      margin-bottom: 18px;
    }
  }
}
@layer reset {
  * {
    box-sizing: border-box;
  }
  body,
  h1,
  h2,
  h3,
  p {
    margin: 0;
  }
  button,
  input,
  select {
    font: inherit;
  }
  button,
  a {
    -webkit-tap-highlight-color: transparent;
  }
  button {
    cursor: pointer;
  }
  img,
  svg {
    display: block;
  }
  button:disabled {
    cursor: not-allowed;
  }
  button {
    color: inherit;
  }
  a {
    color: inherit;
  }
  button,
  input,
  select {
    min-height: 40px;
  }
  html {
    scroll-behavior: smooth;
  }
  [hidden] {
    display: none !important;
  }
}
@layer base {
  :root {
    --bg: #070d1e;
    --side: #0b1226;
    --surface: #101b32;
    --surface-2: #142039;
    --hover: #1c2b49;
    --text: #f0f4fd;
    --muted: #a1b1ce;
    --dim: #7586a6;
    --line: #263552;
    --cyan: #55dbd0;
    --blue: #abc2fb;
    --amber: #f6ba7c;
    --red: #ffaaaa;
    --shadow: 0 28px 80px #0006;
    --title: Bahnschrift, "Aptos Display", "Trebuchet MS", sans-serif;
    --body: Aptos, "Segoe UI", sans-serif;
  }
  :root[data-theme="light"] {
    --bg: #edf2fa;
    --side: #e4ebf7;
    --surface: #fff;
    --surface-2: #f2f6fc;
    --hover: #e4ecf8;
    --text: #17243e;
    --muted: #536583;
    --dim: #65758e;
    --line: #ced9e9;
    --cyan: #08796f;
    --blue: #345da6;
    --amber: #92540c;
    --red: #a72539;
    --shadow: 0 28px 80px #15294f21;
  }
  body {
    background: var(--bg);
    color: var(--text);
    font: 15px/1.55 var(--body);
    text-rendering: optimizeLegibility;
  }
  h1,
  h2,
  h3,
  .brand {
    font-family: var(--title);
    font-weight: 600;
    letter-spacing: -0.025em;
  }
  h1 {
    font-size: clamp(30px, 3.1vw, 46px);
    line-height: 1.12;
    margin: 7px 0 13px;
  }
  h2 {
    font-size: 18px;
    line-height: 1.3;
  }
  h3 {
    font-size: 18px;
  }
  p {
    max-width: 76ch;
  }
  small {
    font-size: 12px;
  }
  button {
    background: none;
    border: 0;
  }
  input,
  select {
    color: var(--text);
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 8px 12px;
  }
  input::placeholder {
    color: var(--dim);
  }
  a {
    text-decoration: none;
  }
  a:hover {
    text-decoration: underline;
  }
  a,
  button,
  input,
  select {
    outline-offset: 5px;
  }
  a:focus-visible,
  button:focus-visible,
  input:focus-visible,
  select:focus-visible {
    outline: 2px solid var(--cyan);
  }
  ::selection {
    background: #578dab65;
  }
  .muted {
    color: var(--muted);
  }
  .sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }
  .skip-link {
    position: fixed;
    left: 230px;
    top: -60px;
    background: var(--surface);
    padding: 12px;
    z-index: 99;
  }
  .skip-link:focus {
    top: 10px;
  }
  .eyebrow {
    color: var(--blue);
    font-size: 13px;
    font-weight: 600;
  }
  .dot {
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
    flex-shrink: 0;
  }
  .dot.amber {
    color: var(--amber);
  }
  .dot.cyan {
    color: var(--cyan);
  }
  .pill,
  .mini-pill {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--muted);
    border: 1px solid var(--line);
    border-radius: 100px;
    padding: 5px 10px;
    font-size: 12px;
    white-space: nowrap;
  }
  .mini-pill {
    padding: 2px 8px;
    font-size: 11px;
  }
  .pill.active {
    color: var(--cyan);
    border-color: #55dbd04a;
  }
  .quiet-button {
    padding: 5px 0;
    color: var(--muted);
    text-align: left;
    font-size: 13px;
  }
  .quiet-button:hover {
    color: var(--text);
  }
  .icon-button {
    width: 40px;
    border: 1px solid var(--line);
    border-radius: 8px;
    font-size: 22px;
    line-height: 1;
  }
  .icon-button:hover {
    background: var(--hover);
  }
  .text-button {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--cyan);
    font-weight: 600;
    padding: 8px 0;
  }
  .primary-button,
  .secondary-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 15px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-2);
    font-size: 14px;
  }
  .primary-button {
    background: var(--text);
    color: var(--bg);
    border-color: var(--text);
  }
  .secondary-button:hover {
    background: var(--hover);
  }
  .empty {
    color: var(--muted);
    padding: 24px 0;
    font-size: 14px;
  }
  .notice {
    border: 1px solid #f6ba7c55;
    background: var(--surface);
    border-left: 3px solid var(--amber);
    padding: 12px 18px;
    margin-bottom: 20px;
    border-radius: 6px;
    color: var(--amber);
  }
}
@layer layout {
  .sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: 218px;
    padding: 31px 18px 22px;
    background: var(--side);
    border-right: 1px solid var(--line);
    display: flex;
    flex-direction: column;
    z-index: 10;
  }
  .brand {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-left: 8px;
    font-size: 25px;
    line-height: 1;
  }
  .brand small {
    display: block;
    color: var(--muted);
    font: 12px/1.9 var(--body);
    letter-spacing: 0.08em;
  }
  .brand:hover {
    text-decoration: none;
  }
  nav {
    margin-top: 54px;
    display: grid;
    gap: 7px;
  }
  nav a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 12px;
    border-radius: 9px;
    font-size: 13px;
    font-weight: 500;
    color: var(--muted);
    border: 1px solid transparent;
  }
  nav a > span {
    font-size: 20px;
    width: 21px;
    text-align: center;
    line-height: 1;
  }
  nav a:hover {
    text-decoration: none;
    background: var(--surface-2);
    color: var(--text);
  }
  nav a[aria-current="page"] {
    background: var(--surface-2);
    border-color: var(--line);
    color: var(--text);
  }
  nav a[aria-current="page"] > span {
    color: var(--cyan);
  }
  .sidebar-bottom {
    margin-top: auto;
    padding: 20px 10px 0;
  }
  .sidebar-bottom p {
    color: var(--muted);
    font-size: 11px;
    margin: 11px 0 8px;
  }
  .pilot-label {
    display: flex;
    gap: 8px;
    align-items: center;
    font-size: 13px;
  }
  .host-label {
    color: var(--dim);
    border-top: 1px solid var(--line);
    padding-top: 17px;
    margin-top: 17px;
    font-size: 12px;
  }
  .shell {
    margin-left: 218px;
  }
  .topbar {
    height: 77px;
    border-bottom: 1px solid var(--line);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 34px;
    font-size: 13px;
  }
  .breadcrumb {
    color: var(--muted);
  }
  .header-divider {
    padding: 0 14px;
    color: var(--dim);
  }
  .topbar-right {
    display: flex;
    align-items: center;
    gap: 17px;
  }
  .avatar {
    width: 31px;
    height: 31px;
    border: 1px solid var(--line);
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 12px;
    color: var(--blue);
    background: var(--surface);
  }
  .connection {
    display: flex;
    align-items: center;
    gap: 7px;
    color: var(--cyan);
    font-size: 12px;
  }
  .connection.pending {
    color: var(--amber);
  }
  .connection.offline {
    color: var(--red);
  }
  main {
    max-width: 1760px;
    margin: 0 auto;
    padding: 34px;
  }
  .page-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 28px;
    margin-bottom: 28px;
  }
  .page-heading > div > p:last-child {
    color: var(--muted);
    font-size: 14px;
    max-width: 650px;
  }
  .session-status {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 165px;
    font-size: 13px;
    color: var(--muted);
    flex-shrink: 0;
  }
  .session-status strong {
    display: block;
    color: var(--text);
    font-size: 14px;
  }
  .session-orbit {
    width: 31px;
    height: 31px;
    border: 1px solid var(--line);
    border-radius: 50%;
    position: relative;
  }
  .session-orbit:after {
    content: "";
    position: absolute;
    width: 7px;
    height: 7px;
    border: 2px solid var(--bg);
    border-radius: 50%;
    background: var(--cyan);
    top: 1px;
    right: 2px;
  }
  .overview-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 318px;
    gap: 24px;
  }
  .workspace {
    min-width: 0;
  }
  .evidence-rail {
    display: flex;
    flex-direction: column;
    gap: 22px;
  }
  .process-panel {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 16px;
    overflow: hidden;
  }
  .panel-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 23px 24px;
  }
  .panel-heading p {
    font-size: 12px;
    color: var(--muted);
    margin-top: 5px;
  }
  .process-map {
    height: 318px;
    position: relative;
    background: radial-gradient(
      ellipse at 48% 48%,
      #6b9ceb0c 0,
      transparent 63%
    );
  }
  .connections {
    position: absolute;
    width: 100%;
    height: 100%;
    inset: 0;
    overflow: visible;
  }
  .connections path {
    fill: none;
    stroke: var(--line);
    stroke-width: 1.5;
  }
  .connections .active-flow {
    stroke: url(#flow-gradient);
    stroke-width: 2;
    stroke-dasharray: 4 280;
    opacity: 0;
  }
  .is-running .active-flow {
    opacity: 0.85;
    animation: flow 5s linear infinite;
  }
  @keyframes flow {
    to {
      stroke-dashoffset: -568;
    }
  }
  .map-node {
    position: absolute;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--surface);
    text-align: left;
  }
  .map-node:hover {
    background: var(--hover);
  }
  .map-node small {
    display: block;
    color: var(--muted);
    font-weight: 400;
    font-size: 10px;
    line-height: 1.6;
  }
  .source-node {
    left: 4%;
    width: 25%;
    min-height: 58px;
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 9px 10px;
    font-size: 12px;
  }
  .source-node:after {
    content: "";
    position: absolute;
    right: -4px;
    width: 5px;
    height: 5px;
    background: var(--cyan);
    border: 1px solid var(--surface);
    border-radius: 50%;
  }
  .source-prices {
    top: 12%;
  }
  .source-news {
    top: 41%;
  }
  .source-portfolio {
    top: 70%;
  }
  .node-symbol {
    font-size: 24px;
    color: var(--cyan);
    width: 26px;
    text-align: center;
  }
  .astra-node {
    top: 23%;
    left: 42%;
    width: 17%;
    height: 181px;
    background: none;
    border-radius: 70px;
    flex-direction: column;
    gap: 2px;
    text-align: center;
  }
  .astra-node:hover {
    background: #8ca7df0b;
  }
  .astra-node strong {
    font: 23px/1.4 var(--title);
  }
  .astra-ring {
    width: 95px;
    height: 95px;
    display: grid;
    place-items: center;
    border: 1px solid #8ca7df66;
    border-radius: 50%;
    background: var(--surface-2);
    box-shadow:
      0 0 0 8px #8ca7df06,
      0 0 0 20px #8ca7df04;
    margin-bottom: 7px;
  }
  .is-running .astra-ring {
    box-shadow:
      0 0 0 8px #55dbd00d,
      0 0 0 20px #55dbd006;
    border-color: var(--cyan);
  }
  .node-state {
    font-size: 10px;
    color: var(--cyan);
    padding-top: 2px;
  }
  .control-node {
    top: 34%;
    width: 17%;
    height: 122px;
    flex-direction: column;
    gap: 7px;
    border-radius: 10px;
    text-align: center;
    background: none;
    justify-content: flex-start;
  }
  .control-node strong {
    font: 12px/1.35 var(--body);
    font-weight: 600;
  }
  .control-node small {
    font-size: 9px;
  }
  .risk-node {
    left: 64%;
  }
  .result-node {
    left: 82%;
  }
  .control-icon {
    height: 51px;
    width: 51px;
    display: grid;
    place-items: center;
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: 13px;
    color: var(--blue);
    font-size: 29px;
  }
  .result-node .control-icon {
    color: var(--amber);
  }
  .map-caption {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 22px;
    border-top: 1px solid var(--line);
    font-size: 10px;
    color: var(--muted);
  }
  .map-caption > span:first-child {
    display: flex;
    align-items: center;
    gap: 6px;
  }
  .activity-panel {
    margin-top: 23px;
  }
  .activity-panel .panel-heading {
    padding: 10px 0 15px;
  }
  .activity-panel select {
    font-size: 12px;
    max-width: 148px;
  }
  .activity-list {
    max-height: 420px;
    overflow: auto;
    padding-right: 6px;
  }
  .activity-row {
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr) 56px;
    gap: 12px;
    position: relative;
    padding: 15px 0;
    border-top: 1px solid var(--line);
    font-size: 13px;
  }
  .activity-icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: var(--surface);
    border: 1px solid var(--line);
    display: grid;
    place-items: center;
    color: var(--blue);
  }
  .activity-icon.data {
    color: var(--cyan);
  }
  .activity-icon.risk {
    color: var(--amber);
  }
  .activity-row p {
    font-size: 12px;
    color: var(--muted);
    margin-top: 3px;
    overflow-wrap: anywhere;
  }
  .activity-row time {
    text-align: right;
    color: var(--muted);
    font-size: 11px;
    font-variant-numeric: tabular-nums;
  }
  .activity-actor {
    font-size: 10px;
    color: var(--dim);
    margin-left: 7px;
  }
  .activity-query {
    padding: 5px 9px;
    border-left: 2px solid var(--blue);
    margin-top: 8px !important;
    color: var(--blue) !important;
  }
  .rail-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
  }
  .rail-heading h2 {
    font-size: 15px;
  }
  .rail-heading .muted {
    font-size: 10px;
  }
  .decision-preview {
    border-left: 2px solid var(--blue);
    background: var(--surface);
    border-radius: 0 13px 13px 0;
    padding: 23px;
  }
  .decision-action {
    font: 32px/1.2 var(--title);
    margin: 22px 0 10px;
    letter-spacing: -0.03em;
  }
  .decision-action.hold {
    color: var(--amber);
  }
  .decision-action.buy {
    color: var(--cyan);
  }
  .decision-action.sell {
    color: var(--blue);
  }
  .decision-preview p {
    font-size: 13px;
    color: var(--muted);
  }
  .decision-preview .text-button {
    margin-top: 15px;
    font-size: 13px;
  }
  .decision-context {
    font-size: 11px !important;
    color: var(--dim) !important;
    margin-bottom: 12px;
  }
  .reason-excerpt {
    display: -webkit-box;
    -webkit-line-clamp: 5;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .decision-preview .outcome {
    font-size: 11px;
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid var(--line);
  }
  .portfolio-panel,
  .schedule-panel {
    padding: 0 4px;
  }
  .portfolio-value {
    font: 31px/1.4 var(--title);
    letter-spacing: -0.02em;
    margin: 13px 0 2px;
    font-variant-numeric: tabular-nums;
  }
  .portfolio-value small {
    font: 13px var(--body);
    color: var(--muted);
  }
  .portfolio-lines {
    margin-top: 17px;
    border-top: 1px solid var(--line);
    padding-top: 12px;
  }
  .data-row {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    font-size: 12px;
    padding: 5px 0;
    color: var(--muted);
  }
  .data-row span:last-child {
    color: var(--text);
    font-variant-numeric: tabular-nums;
  }
  .allocation {
    height: 5px;
    background: var(--line);
    border-radius: 4px;
    margin-top: 15px;
    overflow: hidden;
  }
  .allocation div {
    height: 100%;
    background: var(--blue);
    width: 100%;
  }
  .schedule-panel {
    padding-top: 19px;
    border-top: 1px solid var(--line);
  }
  .schedule-panel h2 {
    font-size: 15px;
  }
  .schedule-entry {
    display: grid;
    grid-template-columns: 39px 1fr;
    gap: 12px;
    margin-top: 17px;
  }
  .market-badge {
    width: 35px;
    height: 35px;
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: 8px;
    display: grid;
    place-items: center;
    font-size: 11px;
    color: var(--blue);
  }
  .schedule-entry strong {
    display: block;
    font-size: 12px;
  }
  .schedule-entry p {
    font-size: 11px;
    color: var(--muted);
  }
  footer {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 42px;
    padding-top: 18px;
    border-top: 1px solid var(--line);
    color: var(--dim);
    font-size: 11px;
  }
}
@layer components {
  .surface {
    border: 1px solid var(--line);
    border-radius: 13px;
    background: var(--surface);
    margin-top: 22px;
    overflow: hidden;
  }
  .section-toolbar,
  .section-title {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: center;
    margin: 24px 0 18px;
  }
  .section-toolbar .muted {
    font-size: 12px;
  }
  .segmented {
    display: flex;
    gap: 4px;
    padding: 4px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 9px;
  }
  .segmented button {
    padding: 7px 14px;
    border-radius: 6px;
    color: var(--muted);
    font-size: 13px;
    min-height: 34px;
  }
  .segmented button[aria-pressed="true"] {
    background: var(--hover);
    color: var(--text);
  }
  .run-row {
    display: grid;
    grid-template-columns: 55px 150px minmax(0, 1fr) 160px 30px;
    align-items: center;
    gap: 18px;
    width: 100%;
    text-align: left;
    padding: 24px 19px;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid transparent;
    border-radius: 4px;
  }
  .run-row:hover {
    background: var(--surface);
  }
  .run-action-icon {
    width: 42px;
    height: 42px;
    border-radius: 11px;
    display: grid;
    place-items: center;
    background: var(--surface);
    border: 1px solid var(--line);
    font-size: 20px;
    color: var(--amber);
  }
  .run-row h3 {
    font-size: 16px;
  }
  .run-row p {
    font-size: 12px;
    color: var(--muted);
    margin-top: 3px;
  }
  .run-row .run-excerpt {
    max-width: 670px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }
  .run-row .run-outcome {
    font-size: 12px;
    color: var(--muted);
  }
  .row-chevron {
    font-size: 26px;
    color: var(--dim);
  }
  .source-health {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
    border-block: 1px solid var(--line);
    padding: 23px 0;
    margin: 25px 0;
  }
  .source-health strong {
    display: block;
    font: 25px/1.3 var(--title);
    color: var(--blue);
  }
  .source-health p {
    font-size: 13px;
    color: var(--muted);
    margin-top: 5px;
  }
  .source-list {
    padding: 0 24px;
  }
  .source-row {
    padding: 21px 0;
    border-top: 1px solid var(--line);
    display: grid;
    grid-template-columns: 37px 1fr auto;
    gap: 16px;
    align-items: start;
  }
  .source-domain-icon {
    width: 34px;
    height: 34px;
    border: 1px solid var(--line);
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: var(--cyan);
    font-size: 14px;
  }
  .source-row a {
    font-size: 15px;
    color: var(--text);
    overflow-wrap: anywhere;
  }
  .source-row p {
    color: var(--muted);
    font-size: 12px;
    margin-top: 6px;
  }
  .source-row .source-meta {
    color: var(--dim);
    font-size: 11px;
    margin-top: 6px;
  }
  .source-arrow {
    font-size: 19px;
    color: var(--blue);
  }
  .search-section #search-list {
    padding: 0 24px;
  }
  .search-row {
    padding: 17px 0;
    border-top: 1px solid var(--line);
    display: flex;
    justify-content: space-between;
    gap: 20px;
    font-size: 13px;
  }
  .search-row time {
    color: var(--muted);
    font-size: 11px;
    white-space: nowrap;
  }
  .market-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 17px;
    margin-bottom: 32px;
  }
  .quote-card {
    border: 1px solid var(--line);
    background: var(--surface);
    border-radius: 12px;
    padding: 21px;
  }
  .quote-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
  }
  .quote-head h3 {
    font-size: 18px;
  }
  .quote-price {
    font: 29px/1.3 var(--title);
    font-variant-numeric: tabular-nums;
    margin: 19px 0 12px;
    letter-spacing: -0.03em;
  }
  .quote-price small {
    font: 13px var(--body);
    color: var(--muted);
    letter-spacing: 0;
  }
  .quote-card p {
    color: var(--muted);
    font-size: 11px;
  }
  .freshness {
    display: inline-flex;
    gap: 6px;
    align-items: center;
    font-size: 11px;
    color: var(--cyan);
    margin: 0 0 8px;
  }
  .freshness.stale {
    color: var(--amber);
  }
  .crypto-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 20px;
  }
  .chart {
    width: 100%;
    height: 140px;
    margin: 17px 0 9px;
    overflow: visible;
  }
  .chart path {
    fill: none;
    stroke: var(--cyan);
    stroke-width: 2;
    vector-effect: non-scaling-stroke;
  }
  .chart .chart-fill {
    stroke: none;
    fill: #55dbd014;
  }
  .chart line {
    stroke: var(--line);
    stroke-width: 1;
    stroke-dasharray: 3 5;
  }
  .chart-labels {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    font-size: 10px;
    color: var(--muted);
  }
  .connection-notice {
    display: flex;
    gap: 22px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 13px;
    padding: 24px;
    margin: 25px 0;
  }
  .connection-notice .control-icon {
    flex-shrink: 0;
  }
  .connection-notice h2 {
    font-size: 16px;
    margin-bottom: 7px;
  }
  .connection-notice p {
    font-size: 13px;
    color: var(--muted);
  }
  .provider-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
  }
  .provider-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    border: 1px solid var(--line);
    border-radius: 13px;
    padding: 26px;
    background: var(--surface);
  }
  .provider-top {
    display: flex;
    gap: 14px;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    margin-bottom: 17px;
  }
  .provider-logo {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 10px;
    font: 20px var(--title);
    color: var(--blue);
  }
  .provider-top > div {
    display: flex;
    gap: 13px;
    align-items: center;
  }
  .provider-card p {
    font-size: 13px;
    color: var(--muted);
    margin-bottom: 14px;
  }
  .provider-card .secondary-button {
    margin-top: auto;
  }
  .provider-status {
    font-size: 11px;
    color: var(--amber);
  }
  dialog {
    position: fixed;
    inset: 0 0 0 auto;
    margin: 0;
    height: 100dvh;
    max-height: 100dvh;
    width: min(660px, 100%);
    max-width: 100%;
    padding: 0;
    color: var(--text);
    background: var(--surface);
    border: 0;
    border-left: 1px solid var(--line);
    box-shadow: var(--shadow);
    overflow: auto;
  }
  dialog::backdrop {
    background: #030716b8;
    backdrop-filter: blur(5px);
  }
  .dialog-top {
    position: sticky;
    top: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 25px 28px;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    z-index: 2;
  }
  .dialog-top h2 {
    font-size: 25px;
    margin-top: 5px;
  }
  .detail-body {
    padding: 28px;
  }
  .detail-body p {
    color: var(--muted);
    font-size: 14px;
    white-space: pre-line;
    overflow-wrap: anywhere;
    margin: 10px 0 20px;
  }
  .detail-body h3 {
    font-size: 16px;
    margin: 26px 0 10px;
  }
  .detail-body ul,
  .detail-body ol {
    padding-left: 22px;
    color: var(--muted);
    font-size: 14px;
  }
  .detail-body li {
    margin: 11px 0;
    overflow-wrap: anywhere;
  }
  .detail-body a {
    color: var(--blue);
    text-decoration: underline;
    text-underline-offset: 3px;
    overflow-wrap: anywhere;
  }
  .detail-body .decision-action {
    font-size: 36px;
    margin-top: 10px;
  }
  .detail-meta {
    font-size: 12px;
    color: var(--muted);
    padding: 10px 0;
    border-block: 1px solid var(--line);
    margin-bottom: 20px;
  }
  .detail-block {
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 17px;
    margin: 18px 0;
  }
  .detail-block h3 {
    margin: 0 0 9px;
  }
  .detail-block p {
    margin: 0;
    font-size: 13px;
  }
  .risk-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  .risk-cell {
    border: 1px solid var(--line);
    padding: 17px;
    border-radius: 9px;
  }
  .risk-cell strong {
    font: 24px var(--title);
    display: block;
  }
  .risk-cell span {
    font-size: 12px;
    color: var(--muted);
  }
}
@layer responsive {
  .mobile-connections {
    display: none;
  }
  .mobile-theme-toggle {
    display: none;
  }
  .astra-node {
    top: calc(50% - 47.5px);
  }
  .control-node {
    top: calc(50% - 25.5px);
  }
  @media (min-width: 1600px) {
    main {
      padding: 42px;
    }
    .overview-layout {
      grid-template-columns: minmax(0, 1fr) 350px;
    }
    .process-map {
      height: 365px;
    }
    .source-node {
      font-size: 14px;
    }
    .map-node small {
      font-size: 11px;
    }
    .astra-node {
      top: 25%;
    }
    .control-node {
      top: 37%;
    }
    .source-node {
      min-height: 63px;
    }
    .activity-list {
      max-height: 480px;
    }
  }
  @media (max-width: 1240px) {
    .sidebar {
      width: 188px;
      padding-inline: 12px;
    }
    .shell {
      margin-left: 188px;
    }
    main {
      padding: 25px;
    }
    .topbar {
      padding: 0 25px;
    }
    .overview-layout {
      grid-template-columns: minmax(0, 1fr) 275px;
      gap: 18px;
    }
    .panel-heading {
      padding: 20px 18px;
    }
    .source-node {
      font-size: 10px;
      padding: 8px;
    }
    .source-node small {
      font-size: 9px;
    }
    .node-symbol {
      font-size: 18px;
      width: 15px;
    }
    .control-node strong {
      font-size: 10px;
    }
    .control-node small {
      font-size: 8px;
    }
    .astra-ring {
      width: 78px;
      height: 78px;
    }
    .astra-node {
      top: 27%;
    }
    .control-node {
      top: 34%;
    }
    .decision-preview {
      padding: 19px;
    }
    .session-status {
      display: none;
    }
    .map-caption {
      font-size: 9px;
      padding-inline: 15px;
    }
    .map-caption span:last-child {
      display: none;
    }
    .run-row {
      grid-template-columns: 45px 125px minmax(0, 1fr) 95px 16px;
      gap: 12px;
    }
  }
  @media (max-width: 1050px) {
    .overview-layout {
      grid-template-columns: minmax(0, 1fr);
    }
    .evidence-rail {
      display: grid;
      grid-template-columns: 1.1fr 1fr;
      gap: 25px;
    }
    .schedule-panel {
      grid-column: 1/-1;
      display: flex;
      align-items: center;
      gap: 30px;
    }
    .schedule-panel #schedule {
      display: flex;
      gap: 30px;
    }
    .schedule-entry {
      margin-top: 0;
    }
    .process-map {
      height: 340px;
    }
    .source-node {
      font-size: 13px;
    }
    .source-node small {
      font-size: 10px;
    }
    .node-symbol {
      font-size: 24px;
      width: 25px;
    }
    .astra-node {
      top: 25%;
    }
    .astra-ring {
      width: 95px;
      height: 95px;
    }
    .control-node {
      top: 35%;
    }
    .control-node strong {
      font-size: 12px;
    }
    .control-node small {
      font-size: 10px;
    }
    .activity-list {
      max-height: 300px;
    }
    .market-grid {
      grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .run-row {
      grid-template-columns: 40px 125px minmax(0, 1fr) 15px;
    }
    .run-outcome {
      display: none;
    }
  }
  @media (max-width: 760px) {
    .sidebar {
      position: static;
      width: 100%;
      height: auto;
      padding: 17px 18px 0;
      border-right: 0;
      border-bottom: 1px solid var(--line);
    }
    .brand {
      font-size: 21px;
      padding: 0;
    }
    .brand img {
      width: 30px;
      height: 30px;
    }
    .brand small {
      display: inline;
      margin-left: 8px;
      font-size: 12px;
      letter-spacing: 0.03em;
    }
    .sidebar-bottom {
      display: none;
    }
    nav {
      display: flex;
      gap: 5px;
      margin-top: 17px;
      overflow: auto;
      padding-bottom: 10px;
    }
    nav a {
      padding: 8px 10px;
      white-space: nowrap;
      font-size: 12px;
    }
    nav a > span {
      font-size: 16px;
      width: auto;
    }
    .shell {
      margin: 0;
    }
    .topbar {
      height: 58px;
      padding: 0 20px;
      font-size: 11px;
    }
    .topbar-right {
      gap: 10px;
    }
    .avatar:not(#profile-avatar) {
      display: none;
    }
    .connection {
      font-size: 0;
      gap: 0;
    }
    .topbar .icon-button {
      width: 32px;
      min-height: 32px;
    }
    .header-divider {
      padding: 0 8px;
    }
    main {
      padding: 25px 20px;
    }
    .page-heading {
      margin-bottom: 24px;
    }
    .page-heading > div > p:last-child {
      font-size: 13px;
    }
    .eyebrow {
      font-size: 12px;
    }
    h1 {
      font-size: 35px;
    }
    .process-map {
      height: 310px;
    }
    .panel-heading h2 {
      font-size: 15px;
    }
    .panel-heading p {
      font-size: 11px;
    }
    .process-panel .panel-heading {
      align-items: flex-start;
    }
    .process-panel .pill {
      font-size: 9px;
      padding: 4px 7px;
    }
    .source-node {
      left: 3%;
      width: 28%;
      font-size: 10px;
      min-height: 56px;
    }
    .source-node small {
      font-size: 8px;
    }
    .node-symbol {
      font-size: 18px;
      width: 16px;
    }
    .astra-node {
      left: 43%;
      width: 15%;
      top: 28%;
    }
    .astra-ring {
      width: 64px;
      height: 64px;
      box-shadow:
        0 0 0 7px #8ca7df06,
        0 0 0 14px #8ca7df04;
    }
    .astra-ring img {
      width: 34px;
      height: 34px;
    }
    .astra-node strong {
      font-size: 20px;
    }
    .map-node small {
      font-size: 9px;
    }
    .control-icon {
      width: 37px;
      height: 37px;
      font-size: 23px;
      border-radius: 10px;
    }
    .control-node {
      top: 36%;
      gap: 8px;
      width: 17%;
    }
    .control-node strong {
      font-size: 9px;
    }
    .control-node small {
      font-size: 7px;
    }
    .node-state {
      font-size: 9px;
    }
    .map-caption {
      padding: 12px 15px;
      font-size: 9px;
    }
    .activity-row {
      grid-template-columns: 26px minmax(0, 1fr) 48px;
      gap: 8px;
      font-size: 12px;
    }
    .activity-actor {
      display: block;
      margin: 1px 0 0;
    }
    .activity-row time {
      font-size: 10px;
    }
    .evidence-rail {
      gap: 24px;
    }
    .decision-preview {
      padding: 20px;
    }
    .decision-action {
      font-size: 29px;
    }
    .portfolio-value {
      font-size: 26px;
    }
    .rail-heading {
      align-items: flex-start;
    }
    .rail-heading h2 {
      font-size: 14px;
    }
    .schedule-panel {
      display: block;
    }
    .schedule-panel #schedule {
      margin-top: 17px;
      gap: 20px;
    }
    .section-toolbar {
      align-items: flex-start;
      flex-direction: column;
    }
    .segmented button {
      padding: 6px 9px;
      font-size: 12px;
    }
    .run-row {
      padding: 20px 0;
      grid-template-columns: 35px minmax(0, 1fr) 18px;
      gap: 12px;
    }
    .run-row .run-excerpt {
      grid-column: 2;
      grid-row: 2;
      font-size: 12px;
    }
    .row-chevron {
      grid-row: 1;
      grid-column: 3;
    }
    .run-action-icon {
      width: 33px;
      height: 33px;
      font-size: 17px;
    }
    .source-health {
      gap: 15px;
    }
    .source-health p {
      font-size: 11px;
    }
    .source-health strong {
      font-size: 22px;
    }
    .surface .panel-heading {
      flex-wrap: wrap;
    }
    .surface input {
      width: 100%;
      font-size: 13px;
    }
    .source-list {
      padding-inline: 18px;
    }
    .source-row {
      grid-template-columns: 28px 1fr 16px;
      gap: 12px;
    }
    .source-domain-icon {
      width: 27px;
      height: 27px;
      font-size: 12px;
    }
    .source-row a {
      font-size: 14px;
    }
    .market-grid,
    .provider-grid {
      gap: 13px;
    }
    .quote-card,
    .provider-card {
      padding: 18px;
    }
    .quote-price {
      font-size: 25px;
    }
    .quote-head {
      align-items: flex-start;
    }
    .quote-head .mini-pill {
      font-size: 9px;
    }
    .provider-top {
      align-items: flex-start;
      gap: 8px;
      flex-wrap: wrap;
    }
    .provider-top h3 {
      font-size: 17px;
    }
    .provider-logo {
      width: 30px;
      height: 30px;
      font-size: 16px;
    }
    .provider-top > div {
      gap: 9px;
    }
    .connection-notice {
      padding: 19px;
      gap: 15px;
    }
    .connection-notice h2 {
      font-size: 15px;
    }
    .connection-notice p {
      font-size: 12px;
    }
    .crypto-grid {
      grid-template-columns: 1fr;
    }
    .dialog-top {
      padding: 21px;
    }
    .detail-body {
      padding: 21px;
    }
    .dialog-top h2 {
      font-size: 23px;
    }
    .skip-link {
      left: 18px;
    }
    .section-title {
      align-items: flex-start;
      gap: 10px;
    }
    .section-title h2 {
      font-size: 17px;
    }
    .section-title .pill {
      font-size: 10px;
    }
  }
  @media (max-width: 450px) {
    main {
      padding-inline: 15px;
    }
    .topbar {
      padding-inline: 16px;
    }
    .breadcrumb {
      display: none;
    }
    .header-divider {
      display: none;
    }
    .evidence-rail {
      display: flex;
      gap: 23px;
    }
    .portfolio-panel {
      padding: 0 10px;
    }
    .schedule-panel {
      padding-inline: 10px;
    }
    .source-node {
      padding: 7px;
      gap: 5px;
    }
    .source-node small {
      font-size: 7px;
    }
    .node-symbol {
      font-size: 15px;
      width: 11px;
    }
    .source-node {
      font-size: 9px;
    }
    .map-node small {
      font-size: 8px;
    }
    .control-node small {
      font-size: 6.5px;
    }
    .market-grid,
    .provider-grid {
      grid-template-columns: 1fr;
    }
    .source-health {
      grid-template-columns: 1fr;
      gap: 14px;
    }
    .source-health > div {
      display: flex;
      align-items: center;
      gap: 15px;
    }
    .source-health strong {
      min-width: 70px;
    }
    .source-health p {
      margin: 0;
    }
    .source-prices {
      top: 12%;
    }
    .source-news {
      top: 42%;
    }
    .source-portfolio {
      top: 72%;
    }
    .provider-card {
      padding: 23px;
    }
    .provider-top {
      flex-wrap: nowrap;
    }
    .quote-card {
      padding: 22px;
    }
    footer {
      font-size: 10px;
    }
  }
  @media (prefers-reduced-motion: reduce) {
    html {
      scroll-behavior: auto;
    }
    *,
    *:before,
    *:after {
      animation: none !important;
      transition: none !important;
    }
    .connections .active-flow {
      stroke-dasharray: none;
    }
  }
  @media (max-width: 760px) {
    .mobile-theme-toggle {
      display: inline-grid;
      place-items: center;
    }
  }
  @media (min-width: 761px) {
    .astra-node {
      top: calc(50% - 47.5px);
    }
    .control-node {
      top: calc(50% - 25.5px);
    }
  }
  @media (min-width: 1051px) and (max-width: 1240px) {
    .astra-node {
      top: calc(50% - 39px);
    }
  }
  @media (max-width: 760px) {
    .process-map {
      height: 480px;
    }
    .process-map > .connections {
      display: none;
    }
    .mobile-connections {
      display: block;
      position: absolute;
      inset: 0;
      width: 100%;
      height: 100%;
    }
    .mobile-connections path {
      stroke: var(--line);
      fill: none;
      stroke-width: 1.5;
    }
    .is-running .mobile-connections path {
      stroke: var(--cyan);
    }
    .source-node {
      top: 8%;
      width: 28%;
      height: 58px;
      min-height: 58px;
      padding: 9px 7px;
      text-align: center;
      justify-content: center;
      font-size: 11px;
    }
    .source-node .node-symbol {
      display: none;
    }
    .source-node small {
      font-size: 9px;
    }
    .source-node:after {
      right: calc(50% - 2px);
      bottom: -4px;
    }
    .source-prices {
      left: 3%;
    }
    .source-news {
      left: 36%;
    }
    .source-portfolio {
      left: 69%;
    }
    .astra-node {
      left: 36%;
      width: 28%;
      top: calc(50% - 43px);
      height: 151px;
    }
    .astra-ring {
      width: 86px;
      height: 86px;
    }
    .astra-ring img {
      width: 43px;
      height: 43px;
    }
    .astra-node strong {
      font-size: 23px;
    }
    .astra-node small {
      font-size: 11px;
    }
    .control-node {
      top: 79%;
      width: 32%;
      height: 90px;
      gap: 5px;
    }
    .risk-node {
      left: 12%;
    }
    .result-node {
      left: 58%;
    }
    .control-node strong {
      font-size: 12px;
    }
    .control-node small {
      font-size: 10px;
    }
    .control-icon {
      width: 43px;
      height: 43px;
    }
    .node-state {
      font-size: 10px;
    }
    .map-caption {
      font-size: 10px;
    }
  }
}
