/* AXIS Market Terminal — visual system v2. Loaded last by design. */
html.axis-motion-booting body {
  opacity: 0;
}

html.axis-motion-booting body[data-route="home"],
html.axis-motion-booting body[data-route="sentinel"] {
  opacity: 1;
}

:root {
  --axis-bg-0: #030405;
  --axis-bg-1: #07090d;
  --axis-bg-2: #0c1016;
  --axis-bg-3: #121823;
  --axis-line: rgba(232, 195, 104, 0.16);
  --axis-line-strong: rgba(237, 197, 93, 0.38);
  --axis-gold: #d6a94a;
  --axis-gold-bright: #ffd66b;
  --axis-platinum: #f4f5f7;
  --axis-muted: #929ba8;
  --axis-positive: #2ad3ad;
  --axis-negative: #ff5c69;
  --axis-info: #5bc8ff;
  --axis-violet: #9b7bff;
  --axis-radius-sm: 10px;
  --axis-radius-md: 16px;
  --axis-radius-lg: 24px;
  --axis-shadow: 0 22px 60px rgba(0, 0, 0, 0.4);
  --axis-ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --axis-ease-drawer: cubic-bezier(0.32, 0.72, 0, 1);
}

html {
  color-scheme: dark;
  background: var(--axis-bg-0);
}

body {
  background:
    radial-gradient(1000px 620px at 92% -10%, rgba(214, 169, 74, 0.075), transparent 65%),
    radial-gradient(800px 520px at -8% 34%, rgba(54, 106, 118, 0.05), transparent 70%),
    var(--axis-bg-0);
  color: var(--axis-platinum);
}

body::selection { background: rgba(214, 169, 74, 0.34); color: #fff; }

.site-header {
  background: linear-gradient(180deg, rgba(6, 8, 11, 0.96), rgba(3, 4, 6, 0.9));
  border-bottom-color: var(--axis-line);
  box-shadow: 0 10px 38px rgba(0, 0, 0, 0.28);
}

.brand-button { min-width: max-content; }
.brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(255, 214, 107, 0.16), 0 8px 24px rgba(0, 0, 0, 0.32);
}
.brand-logo,
.brand-mark img { display: block; width: 100%; height: 100%; object-fit: contain; }
.brand-title { letter-spacing: 0.12em; }
.brand-subtitle { color: #bd9850; letter-spacing: 0.16em; }

.selector-trigger,
.hero-button,
button {
  transition: border-color 180ms var(--axis-ease-out), color 180ms var(--axis-ease-out), background-color 180ms var(--axis-ease-out), box-shadow 180ms var(--axis-ease-out), opacity 180ms var(--axis-ease-out);
}

.market-hub-trigger:hover,
.market-hub-trigger:focus-visible,
.market-hub-trigger[aria-expanded="true"] {
  border-color: var(--axis-line-strong);
  box-shadow: 0 0 0 3px rgba(214, 169, 74, 0.07);
}

/* Social is intentionally dormant while AXIS focuses on the terminal. */
a[href$="social.html"],
a[href$="social-profile.html"],
[data-route-link="social"] { display: none !important; }

/* Premium dashboard surfaces. No transforms are applied to chart canvases. */
.dashboard-tile,
.market-dashboard-tile,
.sentinel-panel,
.macro-panel,
.intelligence-card {
  background:
    linear-gradient(145deg, rgba(18, 24, 34, 0.94), rgba(6, 8, 12, 0.98) 68%),
    var(--axis-bg-1);
  border-color: rgba(213, 177, 83, 0.18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.025), 0 18px 42px rgba(0, 0, 0, 0.18);
}

.dashboard-tile::before,
.market-dashboard-tile::before {
  background: linear-gradient(90deg, transparent, rgba(214, 169, 74, 0.74), transparent);
  height: 1px;
  opacity: 0.72;
}

.dashboard-tile[data-tone="positive"]::before,
.dashboard-tile.is-positive::before { background: linear-gradient(90deg, transparent, var(--axis-positive), transparent); }
.dashboard-tile[data-tone="negative"]::before,
.dashboard-tile.is-negative::before { background: linear-gradient(90deg, transparent, var(--axis-negative), transparent); }
.dashboard-tile[data-tone="info"]::before { background: linear-gradient(90deg, transparent, var(--axis-info), transparent); }
.dashboard-tile[data-tone="volatility"]::before { background: linear-gradient(90deg, transparent, var(--axis-violet), transparent); }

/* A restrained market-spectrum rhythm keeps large dashboards legible without
   recoloring the data itself. Metric state colors still take precedence. */
body[data-route="dashboard"] .dashboard-grid > .dashboard-tile:nth-child(6n + 2):not([data-tone])::before {
  background: linear-gradient(90deg, transparent, rgba(42, 211, 173, .72), transparent);
}
body[data-route="dashboard"] .dashboard-grid > .dashboard-tile:nth-child(6n + 3):not([data-tone])::before {
  background: linear-gradient(90deg, transparent, rgba(91, 200, 255, .72), transparent);
}
body[data-route="dashboard"] .dashboard-grid > .dashboard-tile:nth-child(6n + 4):not([data-tone])::before {
  background: linear-gradient(90deg, transparent, rgba(155, 123, 255, .68), transparent);
}
body[data-route="dashboard"] .dashboard-grid > .dashboard-tile:nth-child(6n + 5):not([data-tone])::before {
  background: linear-gradient(90deg, transparent, rgba(255, 92, 105, .64), transparent);
}

.dashboard-tile:hover {
  border-color: rgba(214, 169, 74, 0.32);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035), 0 22px 48px rgba(0, 0, 0, 0.22), 0 0 30px rgba(214, 169, 74, 0.035);
}

.dashboard-tile canvas,
.chart-canvas,
.chart-surface canvas,
.footprint-canvas,
.market-profile-canvas { transform: none; filter: none; }

/* Home */
body[data-route="home"] .site-main {
  overflow: clip;
  background: transparent;
}

body[data-route="home"] .landing-page {
  position: relative;
  isolation: isolate;
  max-width: none;
  padding: 0 clamp(16px, 2.4vw, 46px) 64px;
}

body[data-route="home"] .landing-page::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    linear-gradient(rgba(255,255,255,.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.018) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(circle at 50% 20%, #000, transparent 72%);
}

body[data-route="home"] .landing-hero {
  position: relative;
  min-height: min(850px, calc(100svh - 78px));
  max-width: 1680px;
  margin: 0 auto;
  padding: clamp(72px, 11vh, 138px) clamp(4px, 2vw, 32px) 58px;
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(420px, 1.08fr);
  align-items: center;
  gap: clamp(28px, 4vw, 78px);
  border: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

body[data-route="home"] .landing-hero::before {
  content: "";
  position: absolute;
  width: min(76vw, 1100px);
  aspect-ratio: 1;
  right: -26%;
  top: -34%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(214,169,74,.13), rgba(45,99,111,.025) 46%, transparent 70%);
  filter: blur(14px);
  pointer-events: none;
}

body[data-route="home"] .landing-copy {
  position: relative;
  z-index: 4;
  max-width: 760px;
  padding: 0;
  grid-column: 1;
}

body[data-route="home"] .landing-copy .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #dfba63;
  letter-spacing: .22em;
}

body[data-route="home"] .landing-copy .eyebrow::before {
  content: "";
  width: 28px;
  height: 1px;
  background: linear-gradient(90deg, var(--axis-gold), transparent);
}

body[data-route="home"] .landing-copy h1 {
  margin: 18px 0 22px;
  max-width: 10ch;
  font-size: clamp(54px, 7.2vw, 112px);
  line-height: .88;
  letter-spacing: -.065em;
  text-wrap: balance;
  background: linear-gradient(135deg, #fff 5%, #b9c0c9 56%, #f4ca68 105%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

body[data-route="home"] .landing-lead {
  max-width: 62ch;
  color: #abb2bd;
  font-size: clamp(16px, 1.35vw, 21px);
  line-height: 1.65;
}

.axis-hero-stage {
  position: relative;
  z-index: 2;
  grid-column: 2;
  min-height: clamp(440px, 56vw, 720px);
  perspective: 1200px;
  pointer-events: none;
  --axis-hero-x: 0px;
  --axis-hero-y: 0px;
  --axis-hero-scroll: 0px;
}

.axis-hero-art {
  position: absolute;
  inset: -4% -12% -6% -18%;
  background: url("../assets/axis-hero-orbit-v2.webp?v=20260809b") center / contain no-repeat;
  transform: translate3d(var(--axis-hero-x), calc(var(--axis-hero-y) + var(--axis-hero-scroll)), 0) rotateY(-4deg);
  transform-origin: 54% 50%;
  will-change: transform;
  filter: saturate(.95) contrast(1.04);
}

.axis-hero-orbit {
  position: absolute;
  width: 48%;
  aspect-ratio: 1;
  right: 15%;
  top: 21%;
  border: 1px solid rgba(255, 214, 107, .18);
  border-radius: 50%;
  box-shadow: inset 0 0 60px rgba(255,214,107,.035), 0 0 60px rgba(255,214,107,.025);
  animation: axis-orbit-turn 24s linear infinite;
}
.axis-hero-orbit::before,
.axis-hero-orbit::after {
  content: "";
  position: absolute;
  inset: 14%;
  border: 1px dashed rgba(115, 208, 216, .16);
  border-radius: 50%;
}
.axis-hero-orbit::after { inset: 34%; border-style: solid; border-color: rgba(255,214,107,.26); }

.axis-hero-signal {
  position: absolute;
  right: 3%;
  bottom: 14%;
  display: grid;
  gap: 6px;
  padding: 13px 16px;
  min-width: 190px;
  background: rgba(6, 9, 13, .72);
  border: 1px solid rgba(214, 169, 74, .2);
  border-radius: 14px;
  box-shadow: 0 18px 44px rgba(0,0,0,.34);
  backdrop-filter: blur(14px);
}
.axis-hero-signal span { color: var(--axis-muted); font-size: 10px; text-transform: uppercase; letter-spacing: .16em; }
.axis-hero-signal strong { color: #f8dd99; font-size: 15px; font-variant-numeric: tabular-nums; }

@keyframes axis-orbit-turn { to { transform: rotate(360deg); } }

body[data-route="home"] .landing-actions { margin-top: 32px; }
body[data-route="home"] .hero-button {
  min-height: 46px;
  border-radius: 999px;
  padding-inline: 22px;
}
body[data-route="home"] .hero-button-primary {
  color: #090704;
  background: linear-gradient(135deg, #fff0af, #d6a94a 60%, #9a6c20);
  border-color: rgba(255, 230, 159, .54);
  box-shadow: 0 12px 32px rgba(177, 125, 34, .18);
}

body[data-route="home"] .landing-metrics {
  margin-top: 42px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid rgba(214,169,74,.14);
  border-radius: 14px;
  background: rgba(214,169,74,.12);
}
body[data-route="home"] .landing-metrics div {
  border: 0;
  border-radius: 0;
  background: rgba(6,8,11,.88);
}

body[data-route="home"] .landing-hero-status {
  grid-column: 1 / -1;
  position: relative;
  inset: auto;
  justify-self: stretch;
  margin-top: 22px;
  border-color: rgba(214,169,74,.12);
  background: rgba(5,7,10,.78);
}

body[data-route="home"] .landing-command-strip,
body[data-route="home"] .landing-intel-section,
body[data-route="home"] .landing-modules,
body[data-route="home"] .landing-gallery,
body[data-route="home"] .landing-workflow,
body[data-route="home"] .landing-access-band {
  max-width: 1500px;
  margin-left: auto;
  margin-right: auto;
}

body[data-route="home"] .landing-command-strip {
  border: 1px solid rgba(214,169,74,.14);
  border-radius: var(--axis-radius-lg);
  overflow: hidden;
  background: rgba(6,8,12,.8);
  box-shadow: var(--axis-shadow);
}
body[data-route="home"] .landing-command-strip a {
  position: relative;
  min-height: 138px;
  background: linear-gradient(180deg, rgba(18,23,32,.7), rgba(7,9,13,.84));
}
body[data-route="home"] .landing-command-strip a::after {
  content: "";
  position: absolute;
  inset: auto 18px 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--axis-gold), transparent);
  opacity: 0;
  transition: opacity 200ms var(--axis-ease-out);
}
body[data-route="home"] .landing-command-strip a:hover::after { opacity: .8; }

body[data-route="home"] .landing-intel-section,
body[data-route="home"] .landing-gallery article,
body[data-route="home"] .landing-workflow,
body[data-route="home"] .landing-access-band {
  border: 1px solid rgba(214,169,74,.14);
  border-radius: var(--axis-radius-lg);
  background: linear-gradient(145deg, rgba(16,21,30,.86), rgba(5,7,10,.94));
  box-shadow: var(--axis-shadow);
}

body[data-route="home"] .landing-screenshot,
body[data-route="home"] .landing-gallery img {
  border-color: rgba(214,169,74,.24);
  box-shadow: 0 26px 70px rgba(0,0,0,.44);
}

body[data-route="home"] .landing-modules article {
  position: relative;
  overflow: hidden;
  background: linear-gradient(145deg, rgba(19,25,35,.92), rgba(6,8,12,.96));
  border-color: rgba(214,169,74,.16);
}
body[data-route="home"] .landing-modules article::before {
  content: "";
  position: absolute;
  width: 160px;
  height: 160px;
  right: -80px;
  top: -90px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(214,169,74,.16), transparent 70%);
}

[data-axis-reveal] {
  opacity: 0;
  transform: translate3d(0, 18px, 0);
  transition: opacity 440ms var(--axis-ease-out), transform 440ms var(--axis-ease-out);
}
[data-axis-reveal].is-axis-visible { opacity: 1; transform: none; }

/* Sentinel / Ascentinova shares the terminal visual language. */
body[data-route="sentinel"] {
  --sentinel-cyan: var(--axis-info);
  --sentinel-cyan-bright: #8de2ff;
  --sentinel-purple: var(--axis-violet);
  --sentinel-panel: var(--axis-bg-2);
  background: var(--axis-bg-0);
}
body[data-route="sentinel"] .sentinel-main {
  background-image:
    radial-gradient(850px 500px at 100% 0%, rgba(214,169,74,.075), transparent 68%) !important;
  background:
    radial-gradient(850px 500px at 100% 0%, rgba(214,169,74,.075), transparent 68%),
    var(--axis-bg-0);
}
body[data-route="sentinel"] .site-background,
body[data-axis-theme][data-route="sentinel"] .site-background,
body[data-axis-theme-gradient="off"][data-route="sentinel"] .site-background {
  background:
    linear-gradient(180deg, rgba(3,4,5,.28), rgba(3,4,5,.94)),
    radial-gradient(circle at 78% 4%, rgba(214,169,74,.11), transparent 34%),
    radial-gradient(circle at 12% 34%, rgba(91,200,255,.045), transparent 35%) !important;
}
body[data-route="sentinel"] .sentinel-console {
  background: transparent;
  color: var(--axis-platinum);
}
body[data-route="sentinel"] .sentinel-rail,
body[data-route="sentinel"] .sentinel-command,
body[data-route="sentinel"] .sentinel-panel,
body[data-route="sentinel"] .sentinel-kpi,
body[data-route="sentinel"] .sentinel-status-card {
  background: linear-gradient(145deg, rgba(17,22,31,.96), rgba(5,7,10,.98));
  border-color: rgba(214,169,74,.17);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.025), 0 18px 42px rgba(0,0,0,.18);
}
body[data-route="sentinel"] .sentinel-rail-brand,
body[data-route="sentinel"] .sentinel-kicker,
body[data-route="sentinel"] .sentinel-panel-kicker { color: var(--axis-gold); }
body[data-route="sentinel"] .sentinel-orb,
body[data-route="sentinel"] .sentinel-boot-orb {
  background: url("../assets/axis-logo-emblem-64.png?v=20260809-premium3") center / contain no-repeat;
  border: 0;
  border-radius: 12px;
  box-shadow: 0 0 30px rgba(214,169,74,.14);
}
body[data-route="sentinel"] .sentinel-orb::before,
body[data-route="sentinel"] .sentinel-orb::after,
body[data-route="sentinel"] .sentinel-boot-orb::before,
body[data-route="sentinel"] .sentinel-boot-orb::after { display: none; }
body[data-route="sentinel"] .sentinel-rail-nav button.is-active,
body[data-route="sentinel"] .sentinel-rail-nav button:hover {
  color: #f7df9d;
  background: rgba(214,169,74,.1);
  border-color: rgba(214,169,74,.28);
}
body[data-route="sentinel"] .sentinel-status-figure { display: none; }
body[data-route="sentinel"] [data-sentinel-trade-toggle],
body[data-route="sentinel"] .sentinel-refresh {
  color: #080603;
  background: linear-gradient(135deg, #ffe7a2, #c99738);
  border-color: rgba(255,230,155,.5);
}
body[data-route="sentinel"] .sentinel-chart-status {
  background: rgba(5,7,10,.78);
  border-color: rgba(214,169,74,.16);
}
body[data-route="sentinel"] .sentinel-boot {
  background: rgba(3,4,5,.96);
  backdrop-filter: none;
}

@media (max-width: 980px) {
  body[data-route="home"] .landing-hero {
    grid-template-columns: 1fr;
    min-height: auto;
    padding-top: 70px;
  }
  body[data-route="home"] .landing-copy { grid-column: 1; }
  .axis-hero-stage { grid-column: 1; min-height: 430px; order: -1; }
  .axis-hero-art { inset: -14% -8% -10%; }
  .axis-hero-signal { right: 8%; bottom: 7%; }
  body[data-route="home"] .landing-copy h1 { max-width: 12ch; }
}

@media (max-width: 640px) {
  body[data-route="home"] .landing-page { padding-inline: 12px; }
  body[data-route="home"] .landing-hero { padding-top: 38px; gap: 10px; }
  .axis-hero-stage { min-height: 330px; }
  .axis-hero-art { inset: -18% -34% -10% -22%; }
  .axis-hero-orbit { display: none; }
  .axis-hero-signal { right: 0; bottom: 0; transform: scale(.9); transform-origin: bottom right; }
  body[data-route="home"] .landing-copy h1 { font-size: clamp(48px, 17vw, 72px); }
  body[data-route="home"] .landing-metrics { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  [data-axis-reveal] { opacity: 1; transform: none; }
  .axis-hero-art { transform: none; will-change: auto; }
}
