:root {
  --bg: #090a0d;
  --surface: #111318;
  --surface-raised: #171a20;
  --surface-soft: #0e1014;
  --text: #f4f3ef;
  --text-soft: #a2a4ad;
  --text-faint: #686b75;
  --line: rgba(255, 255, 255, 0.09);
  --line-strong: rgba(255, 255, 255, 0.16);
  --primary: #d6ff72;
  --primary-ink: #10130a;
  --violet: #9e8cff;
  --cyan: #6fe7e1;
  --success: #75e3b4;
  --warning: #f0c06b;
  --danger: #ff8796;
  --shadow: 0 22px 70px rgba(0, 0, 0, 0.34);
  color: var(--text);
  background: var(--bg);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { overflow-x: clip; background: var(--bg); scroll-behavior: smooth; }
body {
  min-height: 100vh;
  margin: 0;
  overflow-x: clip;
  background:
    radial-gradient(circle at 82% -10%, rgba(158, 140, 255, 0.1), transparent 28rem),
    radial-gradient(circle at -8% 38%, rgba(111, 231, 225, 0.055), transparent 30rem),
    #090a0d;
}
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 3px;
}

.ambient { position: fixed; z-index: -1; border-radius: 50%; pointer-events: none; filter: blur(80px); }
.ambient-a { top: 16rem; right: -13rem; width: 30rem; height: 30rem; background: rgba(104, 85, 218, 0.08); }
.ambient-b { bottom: -16rem; left: 12%; width: 34rem; height: 34rem; background: rgba(46, 177, 165, 0.045); }
.shell { position: relative; width: min(1440px, calc(100% - 48px)); min-height: 100vh; margin: 0 auto; }

.topbar {
  position: sticky;
  z-index: 50;
  top: 0;
  height: 72px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--line);
  background: rgba(9, 10, 13, 0.82);
  backdrop-filter: blur(24px) saturate(135%);
}
.brand { display: flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.brand-mark {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: #f2f2ed;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
}
.brand-mark i { width: 3px; border-radius: 9px; background: #0d0e11; animation: brand-wave 1.4s ease-in-out infinite; }
.brand-mark i:nth-child(1) { height: 9px; }
.brand-mark i:nth-child(2) { height: 18px; animation-delay: -0.35s; }
.brand-mark i:nth-child(3) { height: 12px; animation-delay: -0.7s; }
.brand strong { display: block; font-size: 14px; font-weight: 650; letter-spacing: -0.02em; }
.brand strong span { color: #6b842a; }
.brand small { display: block; margin-top: 2px; color: var(--text-faint); font-size: 9px; }
.topbar-actions { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.system-state { color: var(--text-soft); font-size: 10px; font-weight: 560; }
.system-state > i { display: inline-block; width: 6px; height: 6px; margin-right: 7px; border-radius: 50%; background: var(--success); box-shadow: 0 0 12px var(--success); }
.system-state.degraded { color: var(--danger); }
.system-state.degraded > i { background: var(--danger); box-shadow: 0 0 12px var(--danger); }
.identity { max-width: 260px; overflow: hidden; padding: 8px 12px; border: 1px solid var(--line); border-radius: 99px; color: var(--text-soft); background: rgba(255, 255, 255, 0.025); font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }

.button {
  min-height: 43px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 16px;
  border: 1px solid transparent;
  border-radius: 11px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 650;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}
.button:hover { transform: translateY(-1px); }
.button:active { transform: translateY(0) scale(0.985); }
.button:disabled { cursor: wait; opacity: 0.55; }
.button.primary { color: var(--primary-ink); background: var(--primary); box-shadow: 0 12px 30px rgba(184, 224, 83, 0.13); }
.button.primary:hover { background: #e0ff91; box-shadow: 0 15px 35px rgba(184, 224, 83, 0.2); }
.button.secondary { color: var(--text); border-color: var(--line-strong); background: rgba(255, 255, 255, 0.055); }
.button.secondary:hover, .button.quiet:hover { border-color: rgba(255, 255, 255, 0.24); background: rgba(255, 255, 255, 0.08); }
.button.quiet { min-height: 36px; color: var(--text-soft); border-color: var(--line); background: rgba(255, 255, 255, 0.025); }
.button.full { width: 100%; }
.button-icon { font-size: 18px; font-weight: 380; }

.panel { border: 1px solid var(--line); border-radius: 18px; background: rgba(17, 19, 24, 0.9); box-shadow: var(--shadow); }
.eyebrow { margin: 0; color: var(--primary); font-size: 9px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; }

.login-view { min-height: calc(100vh - 144px); display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(420px, 0.72fr); gap: clamp(50px, 7vw, 110px); align-items: center; padding: 72px 2%; }
.welcome-pill { display: inline-flex; align-items: center; gap: 9px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 99px; color: #c8cad1; background: rgba(255, 255, 255, 0.025); font-size: 10px; }
.welcome-pill i, .live-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--primary); box-shadow: 0 0 12px var(--primary); }
.login-copy h1 { margin: 22px 0 0; font-size: clamp(54px, 6.5vw, 94px); font-weight: 510; line-height: 0.94; letter-spacing: -0.065em; }
.lede { max-width: 690px; margin: 28px 0 32px; color: var(--text-soft); font-size: 15px; line-height: 1.72; }
.paper-proof { max-width: 690px; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 15px; align-items: center; padding: 16px 17px; border: 1px solid var(--line-strong); border-radius: 14px; color: var(--text); background: rgba(255, 254, 250, 0.68); text-decoration: none; transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease; }
.paper-proof:hover { transform: translateY(-2px); border-color: rgba(90, 116, 31, 0.4); background: #fffefa; }
.paper-proof-index { padding: 7px 9px; border-radius: 7px; color: #536d1a; background: rgba(169, 210, 72, 0.15); font: 700 7px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.08em; white-space: nowrap; }
.paper-proof strong, .paper-proof small { display: block; }
.paper-proof strong { font-size: 11px; }
.paper-proof small { margin-top: 4px; color: var(--text-soft); font-size: 9px; line-height: 1.5; }
.paper-proof b { color: #5a741f; font-size: 16px; }
.paper-caveat { margin: 8px 2px 25px; color: var(--text-faint); font-size: 8px; line-height: 1.5; }
.login-flow { display: flex; align-items: center; gap: 11px; color: #d5d5d0; font: 600 9px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.08em; text-transform: uppercase; }
.login-flow i { width: 42px; height: 1px; background: linear-gradient(90deg, var(--line-strong), var(--primary)); }
.login-side { position: relative; min-height: 560px; display: grid; place-items: end center; }
.login-visual { position: absolute; top: 0; left: 50%; width: 390px; height: 390px; pointer-events: none; transform: translateX(-50%); }
.login-orbit { position: absolute; top: 50%; left: 50%; border: 1px solid var(--line); border-radius: 50%; transform: translate(-50%, -50%); }
.orbit-one { width: 300px; height: 300px; animation: network-spin 22s linear infinite; }
.orbit-two { width: 208px; height: 208px; border-style: dashed; animation: network-spin 16s linear infinite reverse; }
.demo-core { position: absolute; top: 50%; left: 50%; width: 104px; height: 104px; display: grid; place-content: center; border: 1px solid rgba(214, 255, 114, 0.28); border-radius: 50%; background: #121612; box-shadow: 0 0 0 15px rgba(214, 255, 114, 0.025), 0 0 80px rgba(214, 255, 114, 0.08); text-align: center; transform: translate(-50%, -50%); }
.demo-core > span { font-size: 23px; font-weight: 620; }
.demo-core > small { margin-top: 4px; color: var(--primary); font: 700 6px/1 ui-monospace, monospace; letter-spacing: 0.16em; }
.demo-core b { height: 16px; display: flex; align-items: center; justify-content: center; gap: 2px; margin-top: 7px; }
.demo-core b i { width: 2px; height: 5px; border-radius: 5px; background: var(--primary); animation: activity-wave 1s ease-in-out infinite; }
.demo-core b i:nth-child(2), .demo-core b i:nth-child(4) { animation-delay: -0.45s; }
.demo-core b i:nth-child(3) { animation-delay: -0.7s; }
.demo-node { position: absolute; display: grid; min-width: 55px; height: 30px; place-items: center; border: 1px solid var(--line-strong); border-radius: 9px; color: var(--text-soft); background: #111318; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.42); font: 650 7px/1 ui-monospace, monospace; }
.demo-market { top: 45px; left: 60px; }.demo-news { top: 70px; right: 35px; }.demo-fund { bottom: 58px; left: 32px; }.demo-risk { right: 45px; bottom: 42px; }
.login-card { position: relative; z-index: 2; width: min(100%, 400px); padding: 28px; backdrop-filter: blur(20px); }
.login-card h2 { margin: 8px 0 9px; font-size: 26px; font-weight: 540; letter-spacing: -0.035em; }
.login-card > p:not(.eyebrow):not(.error):not(.login-note) { margin: 0 0 22px; color: var(--text-soft); font-size: 12px; line-height: 1.6; }
#google-signin { position: relative; z-index: 10; min-height: 44px; display: flex; align-items: center; justify-content: center; isolation: isolate; touch-action: manipulation; }
#google-signin iframe { pointer-events: auto !important; touch-action: manipulation; }
.google-mobile-signin { position: relative; z-index: 20; min-height: 48px; display: none; align-items: center; justify-content: center; gap: 12px; border: 1px solid #c7c7c7; border-radius: 6px; color: #222; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08); font-size: 14px; font-weight: 560; text-decoration: none; touch-action: manipulation; }
.google-mobile-signin:active { background: #f7f7f7; transform: scale(0.99); }
.google-mobile-mark { width: 22px; height: 22px; display: grid; place-items: center; color: #4285f4; font-size: 18px; font-weight: 700; font-family: Arial, sans-serif; }
.google-signin-loading { width: 100%; min-height: 44px; display: grid; place-items: center; border: 1px solid var(--line-strong); border-radius: 6px; color: var(--text-soft); background: rgba(255, 255, 255, 0.03); font-size: 12px; }
.login-card .button.secondary { margin-top: 9px; }
.login-note { margin: 20px 0 0; padding-top: 16px; border-top: 1px solid var(--line); color: var(--text-faint); font-size: 9px; }
.login-note span { margin-right: 6px; color: var(--success); }
.error { min-height: 18px; margin: 9px 0 0; color: var(--danger); font-size: 11px; line-height: 1.5; }

.workspace-header { min-height: 195px; display: flex; align-items: center; justify-content: space-between; gap: 40px; padding: 38px 2px 28px; }
.workspace-header h1 { margin: 8px 0 8px; font-size: clamp(36px, 4vw, 54px); font-weight: 520; line-height: 1; letter-spacing: -0.05em; }
.workspace-header p:last-child { margin: 0; color: var(--text-soft); font-size: 12px; }
.workspace-header > .button { min-height: 48px; padding: 0 20px; }
.metric-grid { display: flex; gap: 8px; margin-bottom: 12px; }
.metric { min-width: 150px; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 11px 14px; border: 1px solid var(--line); border-radius: 11px; background: rgba(255, 255, 255, 0.02); }
.metric-label { display: flex; align-items: center; gap: 7px; color: var(--text-faint); font-size: 9px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; }
.metric strong { color: #dddcd6; font: 570 15px/1 ui-monospace, SFMono-Regular, Menlo, monospace; }
.live-dot { display: inline-block; width: 5px; height: 5px; animation: live-beacon 1.8s ease-in-out infinite; }

.agent-stage { position: relative; isolation: isolate; overflow: hidden; margin-bottom: 14px; border: 1px solid rgba(255, 255, 255, 0.105); border-radius: 22px; background: linear-gradient(145deg, #0d1014 0%, #10131a 52%, #0d0f14 100%); box-shadow: 0 34px 100px rgba(0, 0, 0, 0.42); }
.agent-stage::after { content: ""; position: absolute; z-index: -1; inset: 0; background-image: radial-gradient(rgba(255, 255, 255, 0.075) 0.65px, transparent 0.65px); background-size: 15px 15px; mask-image: linear-gradient(to bottom, black, transparent 72%); opacity: 0.28; pointer-events: none; }
.stage-aurora { position: absolute; z-index: -1; border-radius: 50%; filter: blur(70px); pointer-events: none; }
.stage-aurora-a { top: -160px; left: 8%; width: 430px; height: 300px; background: rgba(158, 140, 255, 0.15); }
.stage-aurora-b { right: -100px; bottom: -190px; width: 420px; height: 350px; background: rgba(111, 231, 225, 0.08); }
.stage-header { display: flex; align-items: center; justify-content: space-between; gap: 25px; padding: 25px 28px 20px; border-bottom: 1px solid var(--line); }
.stage-kicker { display: flex; align-items: center; gap: 8px; margin: 0 0 8px; color: var(--primary); font: 700 8px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.14em; text-transform: uppercase; }
.stage-kicker > i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 13px currentColor; animation: live-beacon 1.8s infinite; }
.agent-stage[data-status="completed"] .stage-kicker { color: var(--success); }
.agent-stage[data-status="completed"] .stage-kicker > i { animation: none; }
.agent-stage[data-status="completed"] .core-wave i { height: 8px; animation: none; }
.agent-stage[data-status="failed"] .stage-kicker { color: var(--danger); }
.stage-title h2 { display: flex; align-items: baseline; gap: 12px; margin: 0; }
.stage-title h2 strong { color: #fff; font-size: clamp(28px, 3vw, 40px); font-weight: 560; letter-spacing: -0.05em; }
.stage-title h2 span { color: var(--text-soft); font-size: 13px; font-weight: 430; }
.stage-session { flex: 0 0 auto; min-width: 170px; text-align: right; }
.stage-session span, .stage-session strong { display: block; }
.stage-session span { color: var(--text-faint); font-size: 8px; font-weight: 650; letter-spacing: 0.09em; text-transform: uppercase; }
.stage-session strong { margin-top: 6px; color: var(--primary); font: 600 11px/1.1 ui-monospace, SFMono-Regular, Menlo, monospace; }

.phase-track { display: grid; grid-template-columns: repeat(5, 1fr); margin: 0; padding: 0 28px; border-bottom: 1px solid var(--line); list-style: none; }
.phase-track li { position: relative; display: flex; align-items: center; gap: 8px; padding: 15px 0; color: #565962; font-size: 9px; }
.phase-track li::after { content: ""; position: absolute; right: 14px; left: 28px; bottom: -1px; height: 1px; background: transparent; }
.phase-track li i { display: grid; width: 20px; height: 20px; place-items: center; border: 1px solid var(--line); border-radius: 6px; font: 600 7px/1 ui-monospace, monospace; }
.phase-track li.done { color: #91949d; }
.phase-track li.done i { color: var(--success); border-color: rgba(117, 227, 180, 0.23); background: rgba(117, 227, 180, 0.06); }
.phase-track li.active { color: var(--text); }
.phase-track li.active i { color: var(--primary-ink); border-color: var(--primary); background: var(--primary); box-shadow: 0 0 18px rgba(214, 255, 114, 0.18); }
.phase-track li.active::after { background: linear-gradient(90deg, var(--primary), transparent); }

.stage-body { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(330px, 0.72fr); min-height: 520px; }
.agent-canvas { position: relative; min-width: 0; overflow: hidden; border-right: 1px solid var(--line); }
.canvas-grid { position: absolute; inset: 0; background: linear-gradient(rgba(255, 255, 255, 0.023) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.023) 1px, transparent 1px); background-size: 34px 34px; mask-image: radial-gradient(circle at center, black 20%, transparent 82%); }
.canvas-label { position: absolute; z-index: 5; top: 19px; left: 22px; }
.canvas-label span, .canvas-label small { display: block; }
.canvas-label span { color: #8b8e97; font: 650 8px/1 ui-monospace, monospace; letter-spacing: 0.12em; text-transform: uppercase; }
.canvas-label small { margin-top: 6px; color: #50535d; font-size: 8px; }
.live-network { position: absolute; inset: 0; }
.network-svg { position: absolute; z-index: 1; inset: 0; width: 100%; height: 100%; overflow: visible; }
.network-svg-line { fill: none; stroke: rgba(255, 255, 255, 0.07); stroke-width: 1; stroke-dasharray: 3 5; animation: network-flow 2.4s linear infinite; animation-delay: var(--delay); }
.network-svg-line.done { stroke: rgba(117, 227, 180, 0.18); }
.network-svg-line.active { stroke: rgba(214, 255, 114, 0.6); stroke-width: 1.35; filter: drop-shadow(0 0 3px rgba(214, 255, 114, 0.55)); }
.network-svg-line.future { stroke: rgba(255, 255, 255, 0.035); animation: none; }
.network-core { position: absolute; z-index: 6; top: 50%; left: 50%; width: 122px; height: 122px; display: grid; place-content: center; border: 1px solid rgba(214, 255, 114, 0.28); border-radius: 50%; background: radial-gradient(circle at 35% 28%, #28301c, #11150e 67%); box-shadow: 0 0 0 15px rgba(214, 255, 114, 0.025), 0 0 75px rgba(214, 255, 114, 0.09); text-align: center; transform: translate(-50%, -50%); }
.network-core::before, .network-core::after { content: ""; position: absolute; border: 1px solid rgba(214, 255, 114, 0.12); border-radius: 50%; animation: core-pulse 2.7s ease-out infinite; }
.network-core::before { inset: -11px; }.network-core::after { inset: -28px; animation-delay: -1.35s; }
.network-core strong { font-size: 16px; font-weight: 580; }
.network-core span { max-width: 88px; overflow: hidden; margin-top: 5px; color: var(--primary); font: 700 6px/1.25 ui-monospace, monospace; letter-spacing: 0.11em; text-overflow: ellipsis; text-transform: uppercase; white-space: nowrap; }
.core-wave { height: 19px; display: flex; align-items: center; justify-content: center; gap: 2px; margin-top: 7px; }
.core-wave i, .activity-wave i { width: 2px; height: 5px; border-radius: 5px; background: var(--primary); animation: activity-wave 1s ease-in-out infinite; }
.core-wave i:nth-child(2), .core-wave i:nth-child(4), .activity-wave i:nth-child(2), .activity-wave i:nth-child(4) { animation-delay: -0.35s; }
.core-wave i:nth-child(3), .activity-wave i:nth-child(3) { animation-delay: -0.7s; }
.core-wave i:nth-child(5), .activity-wave i:nth-child(5) { animation-delay: -0.15s; }
.network-link { position: absolute; z-index: 1; top: 50%; left: 50%; width: var(--length); height: 1px; overflow: hidden; background: rgba(255, 255, 255, 0.065); transform: rotate(var(--angle)); transform-origin: left center; }
.network-link::after { content: ""; position: absolute; width: 52px; height: 1px; background: linear-gradient(90deg, transparent, var(--link-color, var(--violet)), transparent); animation: signal-travel 2.2s linear infinite; animation-delay: var(--delay, 0s); }
.network-link.done { background: rgba(117, 227, 180, 0.1); --link-color: var(--success); }
.network-link.future::after { display: none; }
.agent-node { position: absolute; z-index: 5; left: var(--x); top: var(--y); width: 132px; min-height: 57px; display: grid; grid-template-columns: 29px minmax(0, 1fr); gap: 9px; align-items: center; padding: 9px; border: 1px solid var(--line); border-radius: 11px; color: #686b74; background: rgba(17, 19, 24, 0.93); box-shadow: 0 12px 35px rgba(0, 0, 0, 0.32); transform: translate(-50%, -50%); transition: border-color 0.3s ease, color 0.3s ease, opacity 0.3s ease, box-shadow 0.3s ease; }
.agent-node[data-agent="market"] { left: 13%; top: 22%; }
.agent-node[data-agent="fundamentals"] { left: 13%; top: 58%; }
.agent-node[data-agent="news"] { left: 22%; top: 84%; }
.agent-node[data-agent="social"] { left: 43%; top: 88%; }
.agent-node[data-agent="trader"] { left: 50%; top: 12%; }
.agent-node[data-agent="bull"] { left: 86%; top: 22%; }
.agent-node[data-agent="bear"] { left: 88%; top: 54%; }
.agent-node[data-agent="risk"] { left: 81%; top: 82%; }
.agent-node[data-agent="portfolio"] { left: 60%; top: 88%; }
.agent-node .agent-glyph { width: 29px; height: 29px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 8px; color: #80838c; background: rgba(255, 255, 255, 0.025); font: 650 8px/1 ui-monospace, monospace; }
.agent-node strong, .agent-node small { display: block; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.agent-node strong { color: inherit; font-size: 8px; font-weight: 650; }
.agent-node small { margin-top: 4px; color: #555862; font-size: 7px; }
.agent-node.future { opacity: 0.48; }
.agent-node.done { color: #b6b8bd; border-color: rgba(117, 227, 180, 0.13); }
.agent-node.done .agent-glyph { color: var(--success); border-color: rgba(117, 227, 180, 0.16); background: rgba(117, 227, 180, 0.04); }
.agent-node.active { color: #fff; border-color: rgba(214, 255, 114, 0.45); background: #181c15; box-shadow: 0 0 0 1px rgba(214, 255, 114, 0.06), 0 14px 38px rgba(0, 0, 0, 0.43), 0 0 32px rgba(214, 255, 114, 0.075); }
.agent-node.active .agent-glyph { color: var(--primary-ink); border-color: var(--primary); background: var(--primary); }
.agent-node.active::after { content: ""; position: absolute; top: 9px; right: 9px; width: 4px; height: 4px; border-radius: 50%; background: var(--primary); box-shadow: 0 0 10px var(--primary); animation: live-beacon 1.4s infinite; }

.communication-panel { min-width: 0; display: flex; flex-direction: column; background: rgba(7, 8, 11, 0.45); }
.communication-panel > header { height: 65px; flex: 0 0 auto; display: flex; align-items: center; justify-content: space-between; padding: 0 18px; border-bottom: 1px solid var(--line); }
.communication-panel > header > div { display: flex; align-items: center; gap: 10px; }
.communication-panel > header > i { width: 6px; height: 6px; border-radius: 50%; background: var(--success); box-shadow: 0 0 12px var(--success); }
.channel-icon { width: 30px; height: 30px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 8px; color: var(--violet); background: rgba(158, 140, 255, 0.05); }
.communication-panel header strong, .communication-panel header small { display: block; }
.communication-panel header strong { font-size: 10px; font-weight: 650; }
.communication-panel header small { margin-top: 3px; color: var(--text-faint); font-size: 7px; }
.communication-feed { flex: 1 1 auto; max-height: 404px; overflow-y: auto; padding: 9px 17px 16px; scrollbar-width: thin; scrollbar-color: #30333b transparent; }
.communication-empty { min-height: 280px; display: grid; place-items: center; align-content: center; color: var(--text-faint); text-align: center; }
.communication-empty span { width: 42px; height: 42px; display: grid; place-items: center; margin-bottom: 10px; border: 1px solid var(--line); border-radius: 50%; }
.communication-empty p { max-width: 210px; margin: 0; font-size: 8px; line-height: 1.55; }
.feed-event { position: relative; padding: 13px 0 13px 20px; border-bottom: 1px solid rgba(255, 255, 255, 0.055); animation: event-enter 0.38s both; }
.feed-event::before { content: ""; position: absolute; top: 20px; left: 1px; width: 6px; height: 6px; border: 1px solid #747783; border-radius: 50%; background: #17191e; }
.feed-event:not(:last-child)::after { content: ""; position: absolute; top: 28px; bottom: -7px; left: 4px; width: 1px; background: var(--line); }
.feed-event[data-kind="message"]::before { border-color: var(--violet); box-shadow: 0 0 10px rgba(158, 140, 255, 0.4); }
.feed-event[data-kind="decision"]::before { border-color: var(--primary); background: var(--primary); box-shadow: 0 0 10px rgba(214, 255, 114, 0.5); }
.feed-route { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; color: #6c6f78; font: 600 6px/1 ui-monospace, monospace; letter-spacing: 0.07em; text-transform: uppercase; }
.feed-route b { color: #a9abb2; font-weight: 600; }.feed-route i { width: 16px; height: 1px; background: #454852; }
.feed-event h3 { margin: 0; color: #deded9; font-size: 9px; font-weight: 620; line-height: 1.4; }
.feed-event p { display: -webkit-box; overflow: hidden; margin: 5px 0 0; color: #777a84; font-size: 8px; line-height: 1.55; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.feed-event time { display: block; margin-top: 6px; color: #4f525b; font: 500 6px/1 ui-monospace, monospace; }
.channel-footer { min-height: 50px; flex: 0 0 auto; display: flex; align-items: center; gap: 9px; padding: 0 18px; border-top: 1px solid var(--line); color: #6a6d76; font-size: 7px; }
.activity-wave { height: 15px; display: inline-flex; align-items: center; gap: 2px; }

.stage-footer { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); }
.stage-footer > div { min-width: 0; padding: 15px 20px; border-right: 1px solid var(--line); }
.stage-footer > div:last-child { border-right: 0; }
.stage-footer span, .stage-footer strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stage-footer span { color: #545761; font: 600 7px/1 ui-monospace, monospace; letter-spacing: 0.08em; text-transform: uppercase; }
.stage-footer strong { margin-top: 6px; color: #c9c9c4; font-size: 9px; font-weight: 590; }

.workspace-grid { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(390px, 0.88fr); gap: 14px; align-items: start; }
.analyses-panel, .briefing { min-height: 540px; padding: 25px; }
.section-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 18px; }
.section-head h2, .summary-head h2 { margin: 6px 0 0; font-size: 20px; font-weight: 540; letter-spacing: -0.03em; }
.section-description { margin: 6px 0 0; color: var(--text-faint); font-size: 9px; line-height: 1.5; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th { padding: 10px 11px; border-bottom: 1px solid var(--line); color: #555862; font: 650 7px/1 ui-monospace, monospace; letter-spacing: 0.08em; text-align: left; text-transform: uppercase; }
td { padding: 16px 11px; border-bottom: 1px solid rgba(255, 255, 255, 0.055); color: #7e818b; font-size: 9px; }
td strong { color: #dddcd7; font-size: 11px; font-weight: 650; }
tbody tr { cursor: pointer; outline: 0; transition: background 0.16s ease; }
tbody tr:hover, tbody tr:focus { background: rgba(255, 255, 255, 0.025); }
tbody tr.selected { background: rgba(214, 255, 114, 0.035); box-shadow: inset 2px 0 var(--primary); }
.badge { display: inline-flex; align-items: center; gap: 6px; font-size: 8px; font-weight: 620; white-space: nowrap; }
.badge::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; box-shadow: 0 0 8px currentColor; }
.badge-completed { color: var(--success); }.badge-running, .badge-queued { color: var(--warning); }.badge-failed, .badge-cancelled { color: var(--danger); }
.badge-running::before { animation: live-beacon 1.5s infinite; }
.job-progress { display: flex; align-items: center; gap: 7px; }.job-progress small { color: #50535d; font-size: 7px; }
.empty-state { min-height: 390px; display: grid; place-items: center; align-content: center; padding: 40px 18px; text-align: center; }
.empty-icon { width: 48px; height: 48px; display: grid; place-items: center; margin-bottom: 14px; border: 1px solid var(--line); border-radius: 15px; color: var(--primary); background: rgba(214, 255, 114, 0.04); }
.empty-state h3 { margin: 0 0 7px; font-size: 15px; font-weight: 540; }.empty-state p { max-width: 330px; margin: 0 0 18px; color: var(--text-faint); font-size: 9px; line-height: 1.6; }

.briefing { position: sticky; top: 84px; }
.summary-head { display: flex; align-items: flex-start; justify-content: space-between; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.summary-head > span { padding: 6px 8px; border: 1px solid var(--line); border-radius: 99px; color: var(--text-faint); font: 600 7px/1 ui-monospace, monospace; letter-spacing: 0.06em; text-transform: uppercase; }
.brief-empty { min-height: 410px; display: grid; place-items: center; align-content: center; padding: 32px 18px; text-align: center; }
.brief-empty > span { width: 48px; height: 48px; display: grid; place-items: center; margin-bottom: 14px; border: 1px solid var(--line); border-radius: 50%; color: var(--violet); }
.brief-empty h3 { margin: 0 0 7px; font-size: 15px; font-weight: 540; }.brief-empty p { max-width: 265px; margin: 0; color: var(--text-faint); font-size: 9px; line-height: 1.6; }
.brief-meta { display: flex; justify-content: space-between; gap: 14px; margin: 18px 0; color: var(--text-faint); font: 580 8px/1 ui-monospace, monospace; }
.decision-head { display: flex; align-items: center; justify-content: space-between; gap: 15px; }
.summary-label { margin: 0 0 7px; color: #5d606a; font: 650 7px/1 ui-monospace, monospace; letter-spacing: 0.09em; text-transform: uppercase; }
.signal { display: inline-flex; padding: 9px 11px; border: 1px solid rgba(158, 140, 255, 0.18); border-radius: 8px; color: #b7acff; background: rgba(158, 140, 255, 0.055); font: 650 11px/1 ui-monospace, monospace; overflow-wrap: anywhere; }
.signal[data-signal="completed"], .signal[data-signal="ready"], .signal[data-signal="buy"], .signal[data-signal="overweight"] { color: var(--success); border-color: rgba(117, 227, 180, 0.2); background: rgba(117, 227, 180, 0.05); }
.signal[data-signal="running"], .signal[data-signal="researching"], .signal[data-signal="queued"], .signal[data-signal="waiting"], .signal[data-signal="hold"] { color: var(--warning); border-color: rgba(240, 192, 107, 0.2); background: rgba(240, 192, 107, 0.05); }
.signal[data-signal="failed"], .signal[data-signal="needs attention"], .signal[data-signal="sell"], .signal[data-signal="underweight"] { color: var(--danger); border-color: rgba(255, 135, 150, 0.2); background: rgba(255, 135, 150, 0.05); }
.decision-mark { width: 42px; height: 42px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 50%; color: #747781; font: 650 9px/1 ui-monospace, monospace; }
.company { margin: 12px 0 0; color: var(--text-soft); font-size: 9px; line-height: 1.5; }
.decision { overflow: hidden; margin: 20px 0; border: 1px solid var(--line); border-radius: 14px; color: #b6b7ba; background: #0d0f13; font-size: 12px; line-height: 1.68; }
.decision-conclusion { padding: 20px; }
.decision-conclusion-label { display: block; margin-bottom: 9px; color: #789d28; font: 720 8px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.11em; text-transform: uppercase; }
.decision-conclusion p { margin: 0; color: var(--text); font-size: 13px; font-weight: 520; line-height: 1.72; }
.decision-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.decision-fact { min-width: 0; padding: 14px 20px; border-right: 1px solid var(--line); }
.decision-fact:last-child { border-right: 0; }
.decision-fact span, .decision-fact strong { display: block; }
.decision-fact span { color: var(--text-faint); font: 650 7px/1 ui-monospace, monospace; letter-spacing: 0.08em; text-transform: uppercase; }
.decision-fact strong { margin-top: 7px; color: var(--text); font-size: 15px; font-weight: 650; }
.decision-reasoning { border-top: 1px solid var(--line); }
.decision-reasoning summary { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 15px 20px; color: var(--text-soft); cursor: pointer; font-size: 10px; font-weight: 650; list-style: none; }
.decision-reasoning summary::-webkit-details-marker { display: none; }
.decision-reasoning summary::after { content: "+"; color: #6b842a; font-size: 16px; font-weight: 450; transition: transform 0.18s ease; }
.decision-reasoning[open] summary::after { transform: rotate(45deg); }
.decision-reasoning-body { max-height: 440px; overflow: auto; padding: 0 20px 19px; color: var(--text-soft); font-size: 11px; line-height: 1.78; scrollbar-width: thin; }
.decision-reasoning-body p { margin: 0 0 13px; }
.decision-reasoning-body p:last-child { margin-bottom: 0; }
.decision-plain { padding: 18px 20px; color: var(--text-soft); font-size: 12px; line-height: 1.75; white-space: pre-wrap; }
.reports-head { display: flex; justify-content: space-between; padding: 12px 1px; border-top: 1px solid var(--line); color: #bfc0bd; font-size: 9px; font-weight: 620; }.reports-head small { color: var(--text-faint); font-size: 7px; font-weight: 520; }
.reports { border-top: 1px solid rgba(255, 255, 255, 0.05); }
.report { border-bottom: 1px solid rgba(255, 255, 255, 0.06); }
.report summary { display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; gap: 9px; align-items: center; padding: 13px 1px; color: #bfc0bd; cursor: pointer; list-style: none; }
.report summary::-webkit-details-marker { display: none; }
.report-glyph { width: 27px; height: 27px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 8px; color: var(--violet); font: 650 7px/1 ui-monospace, monospace; }
.report-title { min-width: 0; }.report-title strong, .report-title small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }.report-title strong { font-size: 9px; font-weight: 600; }.report-title small { max-width: 100%; margin-top: 3px; color: #565963; font-size: 7px; }
.report-toggle { color: var(--text-faint); transition: transform 0.18s ease; }.report[open] .report-toggle { transform: rotate(45deg); }
.report pre { max-height: 380px; overflow: auto; margin: 0 0 14px; padding: 14px; border: 1px solid rgba(255, 255, 255, 0.045); border-radius: 9px; color: #9c9ea6; background: #0c0e11; white-space: pre-wrap; font: 8px/1.7 ui-monospace, SFMono-Regular, Menlo, monospace; }

.admin-panel { margin-top: 14px; overflow: hidden; }.admin-panel > summary { display: flex; align-items: center; justify-content: space-between; padding: 18px 22px; cursor: pointer; list-style: none; }.admin-panel > summary::-webkit-details-marker { display: none; }.admin-panel > summary > div { display: flex; align-items: center; gap: 11px; }.admin-panel > summary strong, .admin-panel > summary small { display: block; }.admin-panel > summary strong { font-size: 11px; }.admin-panel > summary small { margin-top: 3px; color: var(--text-faint); font-size: 8px; }.admin-panel > summary > span { color: var(--primary); font-size: 9px; }.settings-icon { width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 9px; }
.users { display: grid; padding: 0 22px 18px; }.user-row { display: grid; grid-template-columns: 1fr 180px 75px; gap: 17px; align-items: center; padding: 14px 0; border-top: 1px solid var(--line); }.user-row strong, .user-row small { display: block; }.user-row strong { font-size: 10px; }.user-row small { margin-top: 3px; color: var(--text-faint); font-size: 8px; }.user-row select { min-height: 36px; padding: 0 9px; border: 1px solid var(--line); border-radius: 8px; color: var(--text); background: var(--surface-soft); }.user-active, .user-disabled { color: var(--success); font-size: 7px; font-weight: 650; text-transform: uppercase; }.user-disabled { color: var(--danger); }

dialog { width: min(760px, calc(100% - 32px)); overflow: visible; padding: 0; border: 1px solid var(--line-strong); border-radius: 20px; color: var(--text); background: #121419; box-shadow: 0 34px 110px rgba(0, 0, 0, 0.7); }
dialog::backdrop { background: rgba(2, 3, 5, 0.78); backdrop-filter: blur(8px); }
#research-form { padding: 18px; }
.visually-hidden { position: absolute !important; width: 1px !important; height: 1px !important; overflow: hidden !important; clip: rect(0 0 0 0) !important; clip-path: inset(50%) !important; white-space: nowrap !important; }
.quick-launch { position: relative; padding-right: 48px; }
.quick-launch-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; }
.quick-launch .icon-button { position: absolute; top: 0; right: 0; }
.quick-launch .button { min-width: 128px; min-height: 56px; border-radius: 14px; font-size: 13px; }
.quick-launch .error { margin: 10px 2px 0; }
.icon-button { width: 38px; height: 38px; flex: 0 0 auto; border: 1px solid var(--line); border-radius: 10px; color: var(--text-soft); background: var(--surface-soft); cursor: pointer; font-size: 19px; }.icon-button:hover { border-color: var(--line-strong); background: var(--surface-raised); }
.form-step { padding: 23px 0; border-top: 1px solid var(--line); }.form-step > header { display: flex; gap: 12px; margin-bottom: 18px; }.form-step > header > span { width: 28px; height: 28px; display: grid; flex: 0 0 auto; place-items: center; border: 1px solid rgba(214, 255, 114, 0.3); border-radius: 8px; color: var(--primary); background: rgba(214, 255, 114, 0.04); font: 650 9px/1 ui-monospace, monospace; }.form-step > header h3 { margin: 0 0 4px; font-size: 13px; font-weight: 600; }.form-step > header p { margin: 0; color: var(--text-faint); font-size: 9px; }
.stock-date-grid { display: grid; grid-template-columns: 1.4fr 0.6fr; gap: 13px; }.stock-date-grid > label, .ticker-field, .two-up label { color: #c9cac7; font-size: 9px; font-weight: 620; }
#research-form input:not([type="checkbox"]), #research-form select { display: block; width: 100%; min-height: 56px; margin: 0; padding: 0 16px; border: 1px solid var(--line-strong); border-radius: 14px; color: var(--text); color-scheme: dark; background: #0d0f13; transition: border-color 0.15s, box-shadow 0.15s; }
#research-form input:not([type="checkbox"]):focus, #research-form select:focus { outline: 0; border-color: rgba(214, 255, 114, 0.45); box-shadow: 0 0 0 3px rgba(214, 255, 114, 0.055); }
#research-form #ticker { padding-right: 44px; font-size: 14px; font-weight: 600; }
#research-form label > small, .ticker-field > small { display: block; margin-top: 6px; color: var(--text-faint); font-size: 7px; font-weight: 450; }
.ticker-control { position: relative; }.ticker-control:has(.ticker-suggestions:not([hidden])) + small { visibility: hidden; }.ticker-search-status { position: absolute; top: 21px; right: 16px; width: 15px; height: 15px; overflow: hidden; color: transparent; pointer-events: none; }.ticker-search-status[data-active="true"] { border: 2px solid rgba(214, 255, 114, 0.15); border-top-color: var(--primary); border-radius: 50%; animation: ticker-spin 0.7s linear infinite; }
.ticker-suggestions { position: absolute; z-index: 60; top: calc(100% + 6px); right: 0; left: 0; max-height: 260px; overflow-y: auto; padding: 6px; border: 1px solid var(--line-strong); border-radius: 11px; background: rgba(18, 20, 25, 0.98); box-shadow: 0 22px 60px rgba(0, 0, 0, 0.55); backdrop-filter: blur(18px); }.ticker-suggestion { width: 100%; display: grid; grid-template-columns: 66px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 10px; border: 0; border-radius: 8px; color: var(--text); background: transparent; text-align: left; cursor: pointer; }.ticker-suggestion:hover, .ticker-suggestion[aria-selected="true"] { background: rgba(255, 255, 255, 0.06); }.ticker-symbol { color: var(--primary); font-size: 9px; font-weight: 680; }.ticker-name { overflow: hidden; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }.ticker-exchange { color: var(--text-faint); font-size: 7px; text-transform: uppercase; }.ticker-no-results { padding: 12px 9px; color: var(--text-soft); font-size: 8px; }
#research-form fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }#research-form legend { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.check-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }.check-grid > label { min-width: 0; display: grid; grid-template-columns: auto auto 1fr; gap: 9px; align-items: start; padding: 13px; border: 1px solid var(--line); border-radius: 10px; background: #0e1014; cursor: pointer; transition: transform 0.15s, border-color 0.15s, background 0.15s; }.check-grid > label:hover { transform: translateY(-1px); border-color: var(--line-strong); }.check-grid > label:has(input:checked) { border-color: rgba(214, 255, 114, 0.22); background: rgba(214, 255, 114, 0.035); }.check-grid input { margin: 5px 0 0; accent-color: var(--primary); }.perspective-icon { width: 28px; height: 28px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 8px; color: var(--primary); background: #15171c; }.check-grid strong, .check-grid small { display: block; }.check-grid strong { margin-top: 1px; font-size: 9px; }.check-grid small { margin-top: 4px; color: var(--text-faint); font-size: 7px; font-weight: 430; line-height: 1.4; }.two-up { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }
.dialog-actions { position: sticky; z-index: 20; bottom: 0; display: flex; align-items: center; justify-content: space-between; gap: 22px; margin: 0 -32px; padding: 17px 32px; border-top: 1px solid var(--line); background: rgba(18, 20, 25, 0.95); backdrop-filter: blur(16px); }.dialog-actions > div { min-width: 0; }.dialog-actions .error { margin: 0; }.dialog-actions small { display: block; color: var(--text-faint); font-size: 7px; }.dialog-actions .button { flex: 0 0 auto; min-width: 165px; }

footer { min-height: 88px; display: flex; align-items: center; justify-content: space-between; gap: 20px; color: #4e5159; font-size: 8px; }
footer a { color: inherit; }

/* Warm light workspace; the agent stage remains a high-contrast command center. */
:root {
  --bg: #f2f0e9;
  --surface: #fffefa;
  --surface-raised: #f8f6f0;
  --surface-soft: #efede6;
  --text: #181914;
  --text-soft: #5d6057;
  --text-faint: #85877e;
  --line: rgba(24, 26, 20, 0.11);
  --line-strong: rgba(24, 26, 20, 0.2);
  --violet: #6957cc;
  --cyan: #2d928d;
  --success: #197a55;
  --warning: #95601a;
  --danger: #bd3f51;
  --shadow: 0 22px 70px rgba(38, 39, 31, 0.08);
}
html { background: var(--bg); }
body {
  background:
    radial-gradient(circle at 84% -8%, rgba(140, 119, 222, 0.11), transparent 29rem),
    radial-gradient(circle at -10% 42%, rgba(91, 181, 166, 0.09), transparent 32rem),
    var(--bg);
}
.topbar { background: rgba(242, 240, 233, 0.84); }
.brand-mark { border-color: #181914; background: #181914; box-shadow: 0 10px 28px rgba(37, 38, 30, 0.14); }
.brand-mark i { background: #f8f6f0; }
.identity, .button.quiet { background: rgba(255, 254, 250, 0.7); }
.button.secondary { background: rgba(255, 254, 250, 0.82); }
.button.secondary:hover, .button.quiet:hover { border-color: rgba(24, 26, 20, 0.28); background: #fffefa; }
.panel { background: rgba(255, 254, 250, 0.92); }
.eyebrow, .ticker-symbol, .empty-icon, .admin-panel > summary > span,
.form-step > header > span, .perspective-icon { color: #5a741f; }
.welcome-pill { color: var(--text-soft); background: rgba(255, 254, 250, 0.62); }
.login-flow { color: var(--text); }
.demo-core { color: #f4f3ef; }
.demo-node { color: #a2a4ad; }
.login-card { background: rgba(255, 254, 250, 0.9); }
.google-signin-loading { background: #fff; }
.metric { background: rgba(255, 254, 250, 0.68); }
.metric strong, td strong { color: var(--text); }
th { color: #777a70; }
td { border-bottom-color: rgba(24, 26, 20, 0.07); color: #696c63; }
tbody tr:hover, tbody tr:focus { background: rgba(24, 26, 20, 0.025); }
tbody tr.selected { background: rgba(169, 210, 72, 0.09); }
.job-progress small { color: var(--text-faint); }
.summary-label { color: #777a70; }
.decision { color: #4f524a; background: #f8f6f0; scrollbar-color: #c9c7bf transparent; }
.reports-head, .report summary { color: #4f524b; }
.reports { border-top-color: rgba(24, 26, 20, 0.07); }
.report { border-bottom-color: rgba(24, 26, 20, 0.075); }
.report-title small { color: #85877e; }
.report pre { border-color: rgba(24, 26, 20, 0.08); color: #50534c; background: #f5f3ed; }
dialog { color: var(--text); background: #fffefa; box-shadow: 0 34px 110px rgba(38, 39, 31, 0.22); }
dialog::backdrop { background: rgba(38, 39, 31, 0.45); }
#research-form input:not([type="checkbox"]), #research-form select { color: var(--text); color-scheme: light; background: #f8f6f0; }
.stock-date-grid > label, .ticker-field, .two-up label { color: #4f524a; }
.ticker-suggestions { background: rgba(255, 254, 250, 0.98); box-shadow: 0 22px 60px rgba(38, 39, 31, 0.16); }
.ticker-suggestion:hover, .ticker-suggestion[aria-selected="true"] { background: rgba(24, 26, 20, 0.055); }
.check-grid > label { background: #faf8f3; }
.perspective-icon { background: #f0eee7; }
.dialog-actions { background: rgba(255, 254, 250, 0.95); }
footer { color: #85877e; }

.agent-stage {
  --surface: #111318;
  --surface-raised: #171a20;
  --surface-soft: #0e1014;
  --text: #f4f3ef;
  --text-soft: #a2a4ad;
  --text-faint: #686b75;
  --line: rgba(255, 255, 255, 0.09);
  --line-strong: rgba(255, 255, 255, 0.16);
  --primary: #d6ff72;
  --primary-ink: #10130a;
  --violet: #9e8cff;
  --success: #75e3b4;
  --warning: #f0c06b;
  --danger: #ff8796;
  box-shadow: 0 34px 90px rgba(38, 39, 31, 0.2);
}

@keyframes brand-wave { 50% { height: 5px; } }
@keyframes ticker-spin { to { transform: rotate(360deg); } }
@keyframes network-spin { to { transform: translate(-50%, -50%) rotate(360deg); } }
@keyframes live-beacon { 50% { opacity: 0.35; } }
@keyframes core-pulse { 70%, 100% { inset: -42px; opacity: 0; } }
@keyframes signal-travel { from { transform: translateX(-52px); } to { transform: translateX(var(--length)); } }
@keyframes network-flow { to { stroke-dashoffset: -16; } }
@keyframes activity-wave { 50% { height: 15px; opacity: 0.92; } }
@keyframes event-enter { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }
@keyframes enter-up { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
#app-view:not([hidden]) .workspace-header, #app-view:not([hidden]) .metric-grid, #app-view:not([hidden]) .agent-stage, #app-view:not([hidden]) .workspace-grid { animation: enter-up 0.42s both; }
#app-view:not([hidden]) .metric-grid { animation-delay: 0.03s; }#app-view:not([hidden]) .agent-stage { animation-delay: 0.06s; }#app-view:not([hidden]) .workspace-grid { animation-delay: 0.09s; }

@media (max-width: 1100px) {
  .login-view { grid-template-columns: 1fr; }.login-copy { max-width: 850px; }.login-side { min-height: 530px; }.workspace-grid { grid-template-columns: 1fr; }.briefing { position: static; }.stage-body { grid-template-columns: 1fr; }.agent-canvas { min-height: 530px; border-right: 0; border-bottom: 1px solid var(--line); }.communication-feed { max-height: 340px; }.communication-empty { min-height: 250px; }
}

@media (max-width: 720px) {
  .shell { width: min(100% - 24px, 1440px); }.topbar { height: 66px; }.brand small, .system-state, .identity { display: none; }.login-view { min-height: calc(100vh - 132px); padding: 50px 0; }.login-copy h1 { font-size: clamp(48px, 15vw, 70px); }.login-flow { flex-wrap: wrap; }.login-flow i { width: 22px; }.login-side { min-height: 500px; }.login-visual { width: 340px; height: 340px; }.login-card { padding: 23px; }.workspace-header { min-height: 0; align-items: flex-start; flex-direction: column; gap: 22px; padding: 45px 1px 26px; }.workspace-header h1 { font-size: 38px; }.workspace-header > .button { width: 100%; }.metric-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); overflow: visible; padding-bottom: 2px; }.metric { min-width: 0; align-items: flex-start; flex-direction: column; gap: 8px; padding: 10px 9px; }.metric-label { font-size: 7px; }.agent-stage { border-radius: 17px; }.stage-header { align-items: flex-start; flex-direction: column; padding: 21px 18px 17px; }.stage-title h2 { align-items: flex-start; flex-direction: column; gap: 5px; }.stage-session { min-width: 0; text-align: left; }.phase-track { overflow: visible; grid-template-columns: repeat(5, minmax(0, 1fr)); padding: 0 12px; }.phase-track li { min-width: 0; flex-direction: column; align-items: flex-start; gap: 6px; padding: 12px 2px; font-size: 7px; white-space: nowrap; }.phase-track li::after { right: 2px; left: 2px; }.phase-track li i { width: 18px; height: 18px; }.stage-body { min-height: 0; }.agent-canvas { min-height: 500px; }.canvas-label { left: 16px; }.agent-node { width: 112px; min-height: 52px; padding: 7px; }.agent-node .agent-glyph { width: 25px; height: 25px; }.network-core { width: 96px; height: 96px; }.communication-panel { min-height: 400px; }.communication-feed { max-height: 330px; }.stage-footer { grid-template-columns: 1fr 1fr; }.stage-footer > div:nth-child(2) { border-right: 0; }.stage-footer > div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }.analyses-panel, .briefing { min-width: 0; min-height: 0; padding: 20px 16px; }.section-head { align-items: center; }.table-wrap { overflow: visible; }table, tbody, tr, td { display: block; width: 100%; }thead { display: none; }tbody { display: grid; gap: 9px; }tbody tr { display: grid; grid-template-columns: 1fr 1fr; gap: 11px 13px; padding: 13px; border: 1px solid var(--line); border-radius: 11px; }td { min-width: 0; padding: 0; border: 0; overflow-wrap: anywhere; }td::before { content: attr(data-label); display: block; margin-bottom: 4px; color: var(--text-faint); font: 650 6px/1 ui-monospace, monospace; letter-spacing: 0.07em; text-transform: uppercase; }td:nth-child(3), td:nth-child(5) { display: none; }.brief-empty { min-height: 300px; }.user-row { grid-template-columns: 1fr 115px; }.user-row > span { display: none; }dialog { width: calc(100% - 12px); max-height: calc(100vh - 12px); border-radius: 16px; }#research-form { padding: 24px 19px 0; }.stock-date-grid, .check-grid, .two-up { grid-template-columns: 1fr; }.dialog-actions { align-items: stretch; flex-direction: column; margin: 0 -19px; padding: 15px 19px; }.dialog-actions .button { width: 100%; }.ticker-suggestions { position: static; max-height: 205px; margin-top: 6px; }.ticker-suggestion { grid-template-columns: 58px minmax(0, 1fr); }.ticker-exchange { display: none; }footer { align-items: flex-start; flex-direction: column; justify-content: center; gap: 6px; }
  .agent-node { width: 100px; }
  .agent-node[data-agent="market"] { left: 18%; top: 22%; }
  .agent-node[data-agent="fundamentals"] { left: 18%; top: 53%; }
  .agent-node[data-agent="news"] { left: 18%; top: 80%; }
  .agent-node[data-agent="trader"] { left: 50%; top: 13%; }
  .agent-node[data-agent="bull"] { left: 82%; top: 22%; }
  .agent-node[data-agent="bear"] { left: 82%; top: 50%; }
  .agent-node[data-agent="risk"] { left: 82%; top: 77%; }
  .agent-node[data-agent="social"] { left: 36%; top: 91%; }
  .agent-node[data-agent="portfolio"] { left: 66%; top: 91%; }
}

@media (max-width: 720px) {
  .login-view { display: flex; flex-direction: column; align-items: stretch; gap: 30px; padding: 28px 0 40px; }
  .login-side { order: -1; min-height: 0; }
  .login-card { width: 100%; }
  .login-visual { display: none; }
  .login-copy h1 { font-size: clamp(42px, 13.5vw, 60px); }
  .login-copy .lede { font-size: 14px; line-height: 1.58; }
  .paper-proof { grid-template-columns: 1fr auto; }
  .paper-proof-index { width: max-content; grid-column: 1 / -1; }
  .paper-proof small { font-size: 10px; }
  .decision-conclusion { padding: 18px 16px; }
  .decision-conclusion p { font-size: 13px; }
  .decision-fact { padding: 13px 16px; }
  .decision-reasoning summary { padding: 15px 16px; }
  .decision-reasoning-body { padding: 0 16px 17px; font-size: 12px; }
  .login-flow { display: none; }
  dialog { width: calc(100% - 20px); max-height: none; }
  #research-form { padding: 12px; }
  .quick-launch { padding: 44px 0 0; }
  .quick-launch-row { grid-template-columns: 1fr; }
  .quick-launch .button { width: 100%; }
  .quick-launch .error { margin-bottom: 2px; }
}

@media (max-width: 720px), (pointer: coarse) {
  #google-signin { display: none; }
  .google-mobile-signin { display: flex; }
}

@media (max-width: 360px) {
  .section-head { align-items: stretch; flex-direction: column; }
  .section-head .button { width: 100%; }
  .analyses-panel, .briefing { padding-right: 14px; padding-left: 14px; }
  .login-visual { width: 296px; height: 296px; }
}

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