:root {
  color-scheme: dark;
  --bg: #07090d;
  --chrome: #202228;
  --frame: #030507;
  --panel: rgba(8, 12, 17, 0.84);
  --panel-2: rgba(13, 18, 25, 0.88);
  --line: rgba(142, 180, 215, 0.22);
  --line-hot: rgba(38, 126, 255, 0.76);
  --text: #f7f9fc;
  --muted: #bac6d5;
  --dim: #7f8ea1;
  --blue: #0877ff;
  --cyan: #65d8ff;
  --green: #2ee2c2;
  --amber: #e0b75b;
  --red: #ee6b6e;
  --shadow: rgba(0, 0, 0, 0.62);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(130deg, #070707, #0c1420 58%, #05070b),
    var(--bg);
  color: var(--text);
}

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

a,
button {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--text);
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  font-weight: 850;
}

a:hover,
button:hover {
  border-color: var(--line-hot);
  box-shadow: 0 0 22px rgba(8, 119, 255, 0.24);
}

.grid-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.1;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.09) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.09) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: linear-gradient(to bottom, black, transparent 74%);
}

.browser-frame {
  position: relative;
  width: 100%;
  min-height: 100vh;
  margin: 0;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.login-frame {
  margin-top: 0;
}

.dashboard-frame {
  margin-top: 0;
  margin-bottom: 0;
}

.browser-chrome {
  display: none;
}

.browser-chrome span {
  width: 10px;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #a9adb6;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
}

.site-hero {
  position: relative;
  min-height: 576px;
  overflow: hidden;
  isolation: isolate;
  background: #020405;
}

.dashboard-hero {
  min-height: 680px;
}

.login-hero {
  min-height: 100vh;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -3;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 64% center;
  filter: saturate(1.08) contrast(1.06);
}

.hero-video-bg {
  background: #020405;
  opacity: 0;
  transition: opacity 420ms ease;
}

.hero-video-bg + .hero-image-fallback {
  opacity: 1;
  transition: opacity 420ms ease;
}

.hero-video-bg[data-ready="true"] {
  opacity: 1;
}

.hero-video-bg[data-ready="true"] + .hero-image-fallback {
  opacity: 0;
}

.hero-layer {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 64% center;
  pointer-events: none;
  filter: saturate(1.08) contrast(1.06);
  transform-origin: 63% 42%;
  will-change: transform, opacity;
}

.boot-sequence {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #020405;
  pointer-events: none;
  animation: boot-fade 3.2s ease forwards;
}

.boot-sequence video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.68;
  filter: saturate(1.12) contrast(1.04);
}

.boot-sequence::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.24) 54%, rgba(0, 0, 0, 0.58)),
    linear-gradient(to top, rgba(0, 0, 0, 0.72), transparent 46%);
}

.boot-copy {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 8px;
  text-align: center;
  text-shadow: 0 0 28px rgba(8, 119, 255, 0.9);
}

.boot-copy span {
  color: var(--cyan);
  font-size: 13px;
  font-weight: 950;
  text-transform: uppercase;
}

.boot-copy strong {
  font-size: clamp(36px, 7vw, 82px);
  line-height: 0.92;
}

.hero-body-layer {
  clip-path: polygon(42% 56%, 78% 55%, 84% 100%, 35% 100%);
  opacity: 0.32;
  animation: hq-body-idle 8s ease-in-out infinite alternate;
}

.hero-head-layer {
  clip-path: ellipse(17% 23% at 64% 38%);
  opacity: 0.42;
  animation: hq-head-idle 6.8s ease-in-out infinite alternate;
}

.hero-dim {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.52) 38%, rgba(0, 0, 0, 0.14) 72%),
    linear-gradient(to top, rgba(0, 0, 0, 0.62), transparent 48%),
    linear-gradient(to bottom, rgba(0, 0, 0, 0.36), transparent 34%);
}

.site-nav {
  position: relative;
  z-index: 2;
  min-height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 0 clamp(32px, 7vw, 90px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.brand-mark {
  min-height: auto;
  border: 0;
  background: transparent;
  padding: 0;
  color: var(--text);
  font-size: clamp(30px, 3vw, 36px);
  font-weight: 950;
  white-space: nowrap;
  text-shadow:
    0 0 8px rgba(8, 119, 255, 0.85),
    0 0 28px rgba(8, 119, 255, 0.68);
}

.site-nav nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px 26px;
  min-width: 0;
}

.site-nav nav a,
.site-nav nav span {
  min-height: auto;
  border: 0;
  background: transparent;
  padding: 0;
  color: rgba(255, 255, 255, 0.92);
  font-size: 15px;
  font-weight: 750;
}

.hero-content {
  position: relative;
  z-index: 1;
  display: grid;
  gap: clamp(22px, 4vw, 52px);
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: clamp(66px, 8vw, 96px) clamp(32px, 7vw, 90px) clamp(56px, 7vw, 84px);
  min-width: 0;
}

.login-content {
  grid-template-columns: minmax(0, 0.95fr) minmax(340px, 400px);
  align-items: center;
}

.dashboard-content {
  grid-template-columns: minmax(0, 1fr) minmax(250px, 300px);
  align-items: end;
}

.hero-copy-block {
  width: min(560px, 100%);
  min-width: 0;
}

.eyebrow,
.login-kicker,
.panel-head p,
.status-strip span {
  margin: 0;
  color: var(--cyan);
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: clamp(42px, 5.35vw, 64px);
  line-height: 0.98;
  letter-spacing: 0;
  text-wrap: balance;
}

.login-content h1 {
  font-size: clamp(48px, 6.2vw, 76px);
}

.subtitle {
  width: min(560px, 100%);
  margin-top: 18px;
  color: #eef3f9;
  font-size: 18px;
  line-height: 1.42;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.76);
}

.action.primary,
.login-form .primary {
  background: linear-gradient(180deg, #1684ff, #0567f2);
  border-color: rgba(102, 185, 255, 0.72);
  box-shadow: 0 0 30px rgba(8, 119, 255, 0.42);
  color: #fff;
}

.login-panel,
.hero-status,
.panel,
.detail,
.status-strip article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  backdrop-filter: blur(18px);
}

.login-panel {
  width: 100%;
  min-width: 0;
  padding: 24px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
}

.login-panel h2 {
  margin-top: 6px;
  font-size: 30px;
  line-height: 1.05;
}

.login-copy {
  margin-top: 12px;
  color: var(--muted);
  line-height: 1.45;
}

.login-error {
  margin-top: 16px;
  border: 1px solid rgba(238, 107, 110, 0.55);
  border-radius: 8px;
  background: rgba(238, 107, 110, 0.14);
  color: #ffd6d7;
  padding: 12px;
  font-weight: 850;
}

.login-form {
  display: grid;
  gap: 13px;
  margin-top: 20px;
}

.login-form label {
  display: grid;
  gap: 8px;
}

.login-form span {
  color: var(--dim);
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}

.login-form input {
  min-height: 48px;
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.07);
  color: var(--text);
  padding: 0 13px;
}

.login-form input:focus {
  border-color: var(--line-hot);
  box-shadow: 0 0 0 3px rgba(8, 119, 255, 0.18);
  outline: none;
}

.login-form button {
  width: 100%;
}

.hero-actions {
  margin-top: 28px;
}

.quick-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(136px, 1fr));
  gap: 10px;
  max-width: 610px;
}

.quick-actions .action,
.logout-form,
.logout-form button {
  width: 100%;
}

.logout-form {
  margin: 0;
}

.hero-status {
  width: 100%;
  min-width: 0;
  padding: 16px;
  display: grid;
  gap: 12px;
}

.status-orb {
  width: 132px;
  aspect-ratio: 1;
  margin-left: auto;
  border: 2px solid rgba(101, 216, 255, 0.62);
  border-radius: 50%;
  display: grid;
  place-items: center;
  position: relative;
  background: rgba(2, 8, 13, 0.58);
  box-shadow:
    0 0 34px rgba(8, 119, 255, 0.34),
    inset 0 0 28px rgba(101, 216, 255, 0.14);
}

.status-orb::before,
.status-orb::after {
  content: "";
  position: absolute;
  inset: 14px;
  border: 1px solid rgba(46, 226, 194, 0.38);
  border-radius: 50%;
}

.status-orb::after {
  inset: 38px;
  border-color: rgba(224, 183, 91, 0.42);
}

.status-orb span {
  position: absolute;
  inset: 54px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 24px rgba(101, 216, 255, 0.7);
}

.status-orb strong {
  position: relative;
  z-index: 1;
  font-size: 12px;
}

#core-copy {
  color: var(--muted);
  line-height: 1.42;
  text-align: right;
}

.hq-eye-pulse {
  position: absolute;
  z-index: 1;
  top: 8.4%;
  left: 61.2%;
  width: 108px;
  aspect-ratio: 1;
  border-radius: 50%;
  mix-blend-mode: screen;
  pointer-events: none;
  opacity: 0.26;
  background:
    radial-gradient(circle, transparent 0 36%, rgba(101, 216, 255, 0.48) 37% 48%, rgba(101, 216, 255, 0.16) 49% 58%, transparent 59%),
    repeating-conic-gradient(from 4deg, rgba(101, 216, 255, 0.42) 0 3deg, transparent 3deg 8deg);
  filter:
    drop-shadow(0 0 6px rgba(101, 216, 255, 0.9))
    drop-shadow(0 0 15px rgba(46, 226, 194, 0.34));
  transform: translate(-50%, -50%) scale(1);
  animation: hq-eye-idle 2.4s ease-in-out infinite alternate;
}

.status-strip,
.panel-grid,
.detail-grid {
  display: grid;
  gap: 14px;
  width: min(1180px, 100%);
  margin-left: auto;
  margin-right: auto;
  padding: 0 28px;
}

.status-strip {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 22px;
}

.status-strip article {
  min-height: 78px;
  padding: 14px;
  display: grid;
  gap: 8px;
}

.status-strip strong {
  font-size: 18px;
}

.panel-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 14px;
}

.detail-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 14px auto 28px;
}

.panel,
.detail {
  min-height: 240px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.wide {
  grid-column: span 2;
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.panel-head span {
  min-width: 72px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 8px;
  color: var(--green);
  text-align: center;
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.panel h2,
.detail h2 {
  font-size: 21px;
  line-height: 1.12;
  overflow-wrap: anywhere;
}

.panel p,
.detail p,
.detail li {
  color: var(--muted);
  line-height: 1.48;
  overflow-wrap: anywhere;
}

.panel a,
.panel button {
  margin-top: auto;
  width: fit-content;
  max-width: 100%;
}

.detail {
  min-height: 210px;
  background: var(--panel-2);
}

.detail ul {
  margin: 0;
  padding-left: 18px;
}

.broker-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.broker-grid div {
  min-height: 70px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(3, 7, 11, 0.5);
}

.broker-grid span {
  display: block;
  color: var(--cyan);
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.broker-grid strong {
  display: block;
  margin-top: 8px;
  font-size: 17px;
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.finance-frame {
  overflow: visible;
}

.os-frame {
  overflow: visible;
}

.life-shell {
  min-height: 100vh;
  position: relative;
}

.finance-shell-head {
  min-height: 270px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 28px;
  padding: 44px 54px 34px;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.84), rgba(5, 20, 32, 0.66) 58%, rgba(0, 0, 0, 0.38)),
    url("/avatar.jpeg") right center / cover no-repeat;
}

.life-shell-head {
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.86), rgba(4, 18, 30, 0.74) 58%, rgba(0, 0, 0, 0.34)),
    url("/avatar.jpeg") right center / cover no-repeat;
}

.os-shell-head {
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.88), rgba(7, 18, 26, 0.76) 54%, rgba(0, 0, 0, 0.32)),
    url("/jarvis-hero-poster.png") right center / cover no-repeat;
}

.finance-shell-head h1 {
  margin-top: 8px;
  font-size: 56px;
}

.finance-shell-head nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.finance-alert {
  margin: 20px 28px 0;
  border: 1px solid rgba(101, 216, 255, 0.28);
  border-radius: 8px;
  background: rgba(3, 7, 11, 0.72);
  color: var(--muted);
  padding: 14px 16px;
  font-weight: 750;
}

.life-grid {
  width: min(1180px, 100%);
  margin: 20px auto 34px;
  padding: 0 28px;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(280px, 0.75fr);
  gap: 14px;
}

.life-command-panel,
.life-help,
.life-result-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 12, 17, 0.88);
  backdrop-filter: blur(18px);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.os-command-strip,
.os-grid {
  width: min(1180px, 100%);
  margin-left: auto;
  margin-right: auto;
  padding: 0 28px;
}

.os-command-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.os-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 14px;
  margin-bottom: 34px;
}

.os-panel {
  min-height: 260px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 12, 17, 0.88);
  backdrop-filter: blur(18px);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.os-panel-wide {
  grid-column: span 2;
}

.os-mission-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 0.7fr);
  gap: 14px;
  min-width: 0;
}

.os-facts {
  align-self: start;
}

.os-panel pre {
  min-height: 260px;
  max-height: 620px;
  margin: 0;
  overflow: auto;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  color: var(--muted);
  font: 13px/1.45 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

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

.capability-grid article {
  min-height: 178px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(3, 7, 11, 0.5);
  padding: 13px;
  display: grid;
  gap: 10px;
  align-content: start;
  min-width: 0;
}

.capability-grid h3 {
  margin: 0;
  font-size: 17px;
  line-height: 1.14;
}

.capability-grid p {
  margin: 0;
  color: var(--muted);
  line-height: 1.38;
}

.capability-grid code {
  display: block;
  overflow-wrap: anywhere;
  font-size: 12px;
  line-height: 1.35;
}

.wide-life {
  grid-column: 1 / -1;
}

.life-form {
  display: grid;
  gap: 13px;
}

.life-form label {
  display: grid;
  gap: 8px;
}

.life-form span {
  color: var(--dim);
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}

.life-form textarea,
.life-form input {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.07);
  color: var(--text);
  padding: 13px;
  resize: vertical;
}

.life-form input {
  min-height: 46px;
}

.life-help button {
  justify-content: flex-start;
  min-height: 38px;
  width: 100%;
  text-align: left;
}

.life-result-panel pre {
  min-height: 260px;
  max-height: 560px;
  margin: 0;
  overflow: auto;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  color: var(--muted);
  font: 13px/1.45 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.finance-metrics,
.finance-grid {
  display: grid;
  gap: 14px;
  padding: 0 28px;
}

.finance-metrics {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 14px;
}

.finance-metrics article,
.finance-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 12, 17, 0.88);
  backdrop-filter: blur(18px);
}

.finance-metrics article {
  min-height: 118px;
  padding: 16px;
  display: grid;
  gap: 8px;
}

.finance-metrics span,
.finance-facts dt,
.trade-form span {
  color: var(--cyan);
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.finance-metrics strong {
  font-size: 27px;
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.finance-metrics small {
  color: var(--muted);
  font-weight: 760;
}

.finance-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 14px 0 28px;
}

.finance-panel {
  min-height: 220px;
  padding: 18px;
  display: grid;
  gap: 14px;
  align-content: start;
}

.finance-panel-wide {
  grid-column: span 2;
}

.finance-chart {
  min-height: 242px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(101, 216, 255, 0.16);
  border-radius: 8px;
  background:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    rgba(3, 7, 11, 0.66);
  background-size: 42px 42px;
  color: var(--muted);
  padding: 16px;
}

.finance-chart svg {
  width: 100%;
  height: 220px;
}

.equity-line-glow {
  stroke: rgba(101, 216, 255, 0.26);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 12;
}

.equity-line {
  stroke: var(--cyan);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 4;
  filter: drop-shadow(0 0 12px rgba(101, 216, 255, 0.58));
}

.finance-facts {
  display: grid;
  gap: 10px;
  margin: 0;
}

.finance-facts div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding-bottom: 10px;
}

.finance-facts dd {
  margin: 0;
  color: var(--text);
  font-weight: 900;
  text-align: right;
}

.trade-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.trade-form label {
  display: grid;
  gap: 7px;
}

.trade-form input,
.trade-form select {
  min-height: 44px;
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.07);
  color: var(--text);
  padding: 0 12px;
}

.trade-form option {
  color: #071018;
}

.trade-form button {
  grid-column: span 2;
}

.draft-output {
  color: var(--muted);
  line-height: 1.44;
  overflow-wrap: anywhere;
}

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

table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
}

th,
td {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding: 11px 8px;
  text-align: left;
  font-size: 13px;
}

th {
  color: var(--cyan);
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

td {
  color: var(--muted);
  font-weight: 760;
}

.mini-list {
  display: grid;
  gap: 10px;
}

.mini-list div,
.mini-list p {
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(3, 7, 11, 0.5);
  padding: 12px;
}

.mini-list strong,
.mini-list span {
  display: block;
}

.mini-list span,
.radar-list {
  color: var(--muted);
}

.radar-list {
  margin: 0;
  padding-left: 18px;
  line-height: 1.48;
}

code {
  color: var(--green);
}

@keyframes hq-eye-idle {
  from {
    opacity: 0.18;
    transform: translate(-50%, -50%) scale(0.985);
  }
  to {
    opacity: 0.32;
    transform: translate(-50%, -50%) scale(1.035);
  }
}

@keyframes hq-body-idle {
  from {
    opacity: 0.26;
    transform: scale(1.006) translate3d(0, 0, 0);
  }
  to {
    opacity: 0.36;
    transform: scale(1.014) translate3d(0, -3px, 0);
  }
}

@keyframes hq-head-idle {
  from {
    opacity: 0.34;
    transform: scale(1.006) translate3d(-1px, 1px, 0) rotate(-0.2deg);
  }
  to {
    opacity: 0.46;
    transform: scale(1.018) translate3d(2px, -2px, 0) rotate(0.28deg);
  }
}

@keyframes boot-fade {
  0% {
    opacity: 1;
    visibility: visible;
  }
  72% {
    opacity: 1;
    visibility: visible;
  }
  100% {
    opacity: 0;
    visibility: hidden;
  }
}

@media (prefers-reduced-motion: reduce) {
  .boot-sequence {
    display: none;
  }

  .hero-video-bg {
    display: none;
  }

  .hero-video-bg + .hero-image-fallback {
    opacity: 1;
  }
}

@media (max-width: 1100px) {
  .browser-frame {
    width: 100%;
    margin-top: 0;
  }

  .site-nav {
    padding: 0 28px;
  }

  .hero-content,
  .login-content,
  .dashboard-content {
    grid-template-columns: 1fr;
    padding: 74px 28px 42px;
  }

  .login-panel,
  .hero-status {
    width: min(420px, 100%);
  }

  .hero-status {
    margin-left: 0;
  }

  .status-strip,
  .panel-grid,
  .detail-grid,
  .finance-metrics,
  .finance-grid {
    grid-template-columns: 1fr 1fr;
    padding: 0 18px;
  }

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

  .wide {
    grid-column: span 2;
  }

  .finance-shell-head {
    min-height: 240px;
    padding: 34px 28px;
  }

  .finance-panel-wide {
    grid-column: span 2;
  }

  .life-grid {
    grid-template-columns: 1fr;
    padding: 0 18px;
  }

  .os-grid {
    grid-template-columns: 1fr 1fr;
    padding: 0 18px;
  }

  .os-panel-wide {
    grid-column: span 2;
  }

  .os-mission-layout,
  .capability-grid {
    grid-template-columns: 1fr 1fr;
  }

  .wide-life {
    grid-column: span 1;
  }
}

@media (max-width: 640px) {
  .browser-frame {
    width: 100%;
    margin-top: 0;
    margin-bottom: 0;
  }

  .site-hero,
  .dashboard-hero {
    min-height: auto;
  }

  .site-nav {
    min-height: auto;
    align-items: flex-start;
    flex-direction: column;
    padding: 18px;
  }

  .brand-mark {
    font-size: 32px;
  }

  .site-nav nav {
    width: 100%;
    min-width: 0;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 14px 22px;
  }

  .site-nav nav a,
  .site-nav nav span {
    font-size: 14px;
  }

  .hero-content,
  .login-content,
  .dashboard-content {
    padding: 48px 18px 30px;
    min-width: 0;
  }

  h1,
  .login-content h1 {
    font-size: 40px;
    line-height: 1.02;
  }

  .subtitle {
    font-size: 16px;
  }

  .quick-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .logout-form button,
  .quick-actions .action {
    width: 100%;
  }

  .hero-status {
    width: 100%;
  }

  .login-panel {
    width: 100%;
    min-width: 0;
  }

  .login-form input,
  .login-form button {
    min-width: 0;
  }

  .login-copy {
    overflow-wrap: anywhere;
  }

  #core-copy {
    text-align: left;
  }

  .status-orb {
    margin-left: 0;
  }

  .hq-eye-pulse {
    top: 34.5%;
    left: 61.2%;
    width: 86px;
  }

  .status-strip,
  .panel-grid,
  .detail-grid,
  .finance-metrics,
  .finance-grid {
    grid-template-columns: 1fr;
    padding: 0 12px;
  }

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

  .wide {
    grid-column: span 1;
  }

  .finance-shell-head {
    min-height: 360px;
    flex-direction: column;
    padding: 24px 18px;
    background-position: 60% center;
  }

  .finance-shell-head h1 {
    font-size: 42px;
  }

  .finance-shell-head nav,
  .finance-shell-head nav a,
  .finance-shell-head nav button {
    width: 100%;
  }

  .finance-alert {
    margin: 14px 12px 0;
  }

  .life-grid {
    padding: 0 12px;
  }

  .os-command-strip,
  .os-grid {
    padding: 0 12px;
  }

  .os-command-strip .action,
  .os-command-strip button {
    width: 100%;
  }

  .os-grid,
  .os-mission-layout,
  .capability-grid {
    grid-template-columns: 1fr;
  }

  .os-panel-wide {
    grid-column: span 1;
  }

  .life-command-panel,
  .life-help,
  .life-result-panel {
    padding: 14px;
  }

  .finance-panel-wide {
    grid-column: span 1;
  }

  .trade-form {
    grid-template-columns: 1fr;
  }

  .trade-form button {
    grid-column: span 1;
  }
}
