:root {
  color-scheme: dark;
  font-family: "Geist", "Inter", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  color: #f0f2fb;
  background: #0b1020;
  --muted: #aab4cd;
  --line: #283350;
  --accent: #c1cdff;
  --up: #ff969f;
  --down: #7adfc7;
  --mono: ui-monospace, "SF Mono", Consolas, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  isolation: isolate;
  background:
    radial-gradient(ellipse 62rem 44rem at 74% 13%, #1d2750 0%, transparent 73%),
    radial-gradient(ellipse 45rem 43rem at 13% 39%, #172540 0%, transparent 76%),
    linear-gradient(162deg, #10182e 0%, #0b1020 68%);
}
.particle-field { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: -1; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
h1, h2, h3, p, dl, dd { margin: 0; }
.shell { width: min(1320px, 100% - clamp(32px, 7vw, 112px)); margin-inline: auto; }
.site-header { border-bottom: 1px solid var(--line); background: #0d1528cc; }
.header-inner { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.header-inner nav { display: flex; align-items: center; gap: 8px; }
.brand { display: inline-flex; flex-direction: column; align-items: flex-start; gap: 5px; white-space: nowrap; }
.brand strong { font-size: 24px; font-weight: 650; letter-spacing: -.055em; line-height: 1; }
.brand small { color: var(--muted); font: 500 .67rem var(--mono); letter-spacing: .14em; }
.button {
  display: inline-flex; align-items: center; justify-content: center; min-height: 43px;
  border: 1px solid transparent; border-radius: 8px; padding: 10px 17px; font-size: .9375rem;
  font-weight: 700; white-space: nowrap; transition: background-color 150ms, border-color 150ms, color 150ms;
}
.button-outline { background: #19243e; border-color: #495879; }
.button-outline:hover { border-color: var(--accent); color: var(--accent); }
.button-primary {
  min-height: 52px; padding-inline: 21px; color: #101b3a;
  background: linear-gradient(115deg, #e0dcff, #b4caff);
  box-shadow: 0 8px 30px #8ba8ff27;
}
.button-primary:hover { background: #e5eaff; }
.nav-link, .text-link { color: var(--muted); font-size: .875rem; font-weight: 650; }
.nav-link:hover, .text-link:hover { color: var(--accent); }
.text-link { text-decoration: underline; text-underline-offset: 4px; text-decoration-color: #5b6a94; }

.account-page { min-height: 100vh; min-height: 100svh; display: grid; place-items: center; padding: 24px 16px; }
.access-card { width: min(100%, 440px); padding: clamp(20px, 4vw, 32px); color: #f0f2fb; background: #151e33; border: 1px solid #394765; border-radius: 16px; box-shadow: 0 24px 84px #03071688; }
.access-card :is(h1, h2) { margin: 0 0 8px; font-size: 1.5rem; line-height: 1.3; }
.account-page .brand { margin-bottom: 24px; }
.access-home { display: inline-block; margin-top: 20px; }
.access-card p { color: var(--muted); line-height: 1.55; font-size: .9rem; }
.access-dialog { position: fixed; inset: 0; margin: auto; width: min(440px, calc(100% - 32px)); max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px); overflow-y: auto; overscroll-behavior: contain; }
.access-dialog::backdrop { background: #060c1ac9; }
html:has(.access-dialog[open]) { overflow: hidden; }
.access-dialog h2 { padding-right: 34px; }
.access-close { position: absolute; top: 8px; right: 8px; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 8px; color: var(--muted); background: transparent; font-size: 1.55rem; line-height: 1; }
.access-close:hover { color: #fff; background: #202c47; }
.access-card form, .access-card label { display: grid; gap: 8px; }
.access-card form, .access-card section { margin-top: 20px; }
.access-card form { gap: 16px; }
.access-card input, .access-card textarea { width: 100%; min-width: 0; padding: 11px; font: inherit; font-size: 1rem; color: inherit; background: #0d1528; border: 1px solid #495879; border-radius: 7px; }
.access-card textarea { font: .9rem/1.5 var(--mono); resize: vertical; margin-bottom: 12px; }
.access-links { display: flex; align-items: center; flex-wrap: wrap; gap: 12px 18px; }
.access-links button.text-link { background: none; border: 0; min-height: 44px; padding: 4px 0; }
.access-card button:disabled { cursor: wait; opacity: .65; }
.access-card [role="alert"] { color: #ffb4b6; }
.access-card [role="status"]:not(:empty), .access-card [role="alert"]:not(:empty) { margin-top: 14px; }

.hero {
  display: grid;
  grid-template-columns: minmax(0, .83fr) minmax(0, 1.42fr);
  align-items: center;
  gap: clamp(28px, 5.4vw, 85px);
  padding-block: clamp(36px, 6vw, 84px);
}
.hero-copy h1 {
  font-size: clamp(3.15rem, 6.25vw, 6.1rem);
  line-height: 1.095;
  font-weight: 400;
  letter-spacing: -.048em;
}
.hero-brand { display: block; color: #cfdaff; font-size: .594em; font-weight: 450; letter-spacing: -.06em; margin-bottom: .26em; }
/* Align the visible strokes of 你 and 复 with the buttons and the market divider. */
.hero-headline { display: block; margin-inline-start: -.034em; }
.title-line { display: block; }
.title-line + .title-line { text-indent: -.023em; }
.title-market { color: var(--accent); }
.hero-copy > p { max-width: 26em; margin-top: 24px; margin-inline-start: -.033em; color: var(--muted); font-size: clamp(1rem, 1.6vw, 1.175rem); line-height: 1.82; }
.hero-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: 29px; }
.hero-actions .button { min-height: 48px; }
.hero-copy > .entry-status { color: var(--muted); font-size: .875rem; margin-top: 10px; }
.market-totals { display: flex; gap: clamp(16px, 3.3vw, 45px); padding-top: 21px; margin-top: 38px; border-top: 1px solid var(--line); }
.market-totals dt { color: var(--muted); font-size: .875rem; white-space: nowrap; }
.market-totals dd { margin-top: 6px; font: 700 clamp(1.125rem, 2.2vw, 1.65rem) var(--mono); letter-spacing: -.045em; }
.market-totals > :first-child > :is(dt, dd) { text-indent: -.05em; }
.positive { color: var(--up); }
.negative { color: var(--down); }

.terminal {
  border: 1px solid #3b4a72;
  background: linear-gradient(146deg, #192340, #11192e 72%);
  border-radius: 20px;
  padding: clamp(12px, 1.5vw, 20px);
  box-shadow: 0 24px 72px #05091688, inset 0 1px #d5e0ff1a;
  scroll-margin-top: 18px;
}
.terminal-header, .stock-heading, .chart-header, .chart-footer { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.terminal-header { margin-bottom: 14px; }
.terminal-header h2 { font-size: 1.145rem; font-weight: 750; }
.terminal-header p { margin-top: 3px; color: var(--muted); font-size: .828rem; }
.snapshot-date {
  align-self: flex-start; flex-shrink: 0; padding: 5px 8px; border: 1px solid #425274; border-radius: 6px;
  background: #1c2946; color: #d0d9ed; font: 600 .75rem var(--mono);
}
.snapshot-date:empty { display: none; }
.map {
  position: relative; isolation: isolate; min-height: 216px; height: clamp(218px, 20vw, 294px);
  background: #0f172b; border-radius: 9px; overflow: hidden;
}
.tile {
  position: absolute; padding: 0; border: 2px solid #151e36; border-radius: 6px; text-align: left;
  min-width: 0; overflow: hidden; color: #f0f7ff; background: var(--tile-fill); transition: filter 140ms;
}
.tile::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(140deg, #f0f5ff26, transparent 66%);
  opacity: 0; transition: opacity 180ms ease-out;
}
.tile:hover::before, .tile:focus-visible::before { opacity: 1; }
.tile > span { display: block; position: relative; padding: 6px clamp(5px, .8vw, 13px); }
.tile strong { display: block; font-size: clamp(.81rem, 1.05vw, .95rem); line-height: 1.2; overflow-wrap: anywhere; }
.tile em { display: block; margin-top: 3px; font: 600 .8rem/1.12 var(--mono); white-space: nowrap; }
.tile[data-size="large"] strong { font-size: clamp(.94rem, 1.52vw, 1.27rem); }
.tile[data-size="large"] em { font-size: .95rem; }
.tile[data-size="short"] > span { padding-block: 2px; }
.tile[data-size="short"] strong { font-size: .72rem; line-height: 1.1; }
.tile[data-size="short"] em { margin-top: 2px; }
.tile[data-narrow="true"] > span { padding-inline: 2px; }
.tile[data-narrow="true"] em { font-size: .64rem; }
.tile:hover { z-index: 2; filter: brightness(1.2); }
.tile:focus-visible, .tile[aria-pressed="true"] { z-index: 3; outline: 2px solid #e0e7ff; outline-offset: -4px; }
@media (prefers-reduced-motion: no-preference) {
  .tile { animation: reveal-sector 390ms ease-out var(--tile-delay, 0ms) backwards; }
  .tile[aria-pressed="true"]::after {
    content: ""; position: absolute; inset: 2px; border-radius: 3px; pointer-events: none;
    box-shadow: inset 0 0 0 1px #f0f5ff, inset 0 0 22px #cfdaff70;
    opacity: 0; animation: select-sector 460ms ease-out;
  }
}
@keyframes reveal-sector {
  from { opacity: .06; }
  to { opacity: 1; }
}
@keyframes select-sector {
  from { opacity: .9; }
  to { opacity: 0; }
}
.map-note { margin-top: 7px; color: var(--muted); font-size: .78rem; line-height: 1.5; }
.stock-panel { margin-top: 13px; }
.stock-heading h3, .chart-header h3 { font-size: .95rem; font-weight: 720; }
.stock-heading span, .chart-header p { font-size: .8rem; color: var(--muted); }
.stock-list { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.stock-button {
  display: inline-flex; align-items: center; gap: 7px; min-height: 34px; padding: 4px 7px;
  background: #18223b; border: 1px solid #364669; border-radius: 6px; font-size: .84rem; white-space: nowrap;
}
.stock-button small { font: 600 .755rem var(--mono); }
.stock-button:hover { border-color: #8c9bcc; }
.stock-button[aria-pressed="true"] { background: #28385e; border-color: #99abeb; }
.chart-panel { border-top: 1px solid var(--line); margin-top: 14px; padding-top: 12px; }
.chart-header p { margin-top: 2px; }
.period-switch { display: flex; gap: 3px; background: #101829; border: 1px solid #354368; border-radius: 7px; padding: 3px; }
.period-switch button {
  background: transparent; border: 0; border-radius: 4px; padding: 5px 8px; min-height: 31px; color: var(--muted); font-size: .82rem;
}
.period-switch button:hover { color: #f2faff; }
.period-switch button[aria-pressed="true"] { color: #ecf0ff; background: #2b3b65; }
.period-switch button:disabled { opacity: .55; cursor: default; }
.chart-legend { display: flex; align-items: center; flex-wrap: wrap; gap: 5px 12px; margin: 10px 0 4px; min-height: 20px; }
.legend-item { display: inline-flex; align-items: center; gap: 5px; font-size: .8rem; color: #d0d9ef; white-space: nowrap; }
.legend-item::before { content: ""; width: 10px; height: 3px; border-radius: 2px; background: var(--series-color); }
.legend-item strong { color: var(--series-color); font: 600 .79rem var(--mono); }
#trend { display: block; width: 100%; height: 136px; border-radius: 5px; touch-action: pan-y; }
.chart-footer { margin-top: 5px; font: 500 .76rem var(--mono); color: var(--muted); }
.chart-footer a { font-size: .8rem; white-space: nowrap; }
.demo-status, .chart-status { padding: 16px 0; color: var(--muted); line-height: 1.65; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }

.features { padding-block: 42px 50px; border-top: 1px solid var(--line); scroll-margin-top: 18px; }
.features-header h2 { font-size: clamp(1.7rem, 3.45vw, 2.5rem); letter-spacing: -.04em; line-height: 1.2; }
.feature-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 27px; }
.feature {
  display: flex; flex-direction: column; align-items: flex-start; padding: clamp(18px, 2vw, 28px);
  border: 1px solid var(--line); background: linear-gradient(140deg, #192542, #121b31 78%); border-radius: 12px;
}
.feature h3 { margin-top: 16px; font-size: 1.16rem; line-height: 1.35; }
.feature p { margin-top: 8px; color: var(--muted); line-height: 1.7; }
.feature-icon { width: 34px; height: 34px; display: grid; gap: 3px; align-items: end; padding: 5px; color: #9bead8; }
.feature-icon i { display: block; background: currentColor; border-radius: 2px; }
.icon-map { grid-template-columns: 3fr 2fr; grid-template-rows: 1fr 1fr 1fr; align-items: stretch; }
.icon-map i:first-child { grid-row: span 2; }
.icon-map i:last-child { grid-column: span 2; opacity: .55; }
.icon-map i:nth-child(3) { opacity: .65; }
.icon-funds { grid-template-columns: repeat(4, 1fr); color: #9bbef9; }
.icon-funds i:nth-child(1) { height: 33%; opacity: .5; }
.icon-funds i:nth-child(2) { height: 65%; opacity: .74; }
.icon-funds i:nth-child(3) { height: 51%; opacity: .65; }
.icon-funds i:nth-child(4) { height: 95%; }
.icon-candles { grid-template-columns: repeat(4, 1fr); align-items: center; color: #cdb4ff; }
.icon-candles i { position: relative; height: 40%; }
.icon-candles i::after { content: ""; position: absolute; width: 1px; height: 175%; top: -37.5%; left: 50%; background: currentColor; }
.icon-candles i:nth-child(1) { transform: translateY(5px); }
.icon-candles i:nth-child(2) { height: 46%; }
.icon-candles i:nth-child(3) { height: 37%; transform: translateY(3px); }
.icon-candles i:nth-child(4) { transform: translateY(-5px); }
.site-footer {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; padding-block: 23px 30px;
  border-top: 1px solid var(--line); color: var(--muted); font-size: .82rem;
}
.site-footer-brand { display: grid; justify-items: start; gap: 8px; }
.site-footer-brand > a { letter-spacing: .04em; }
.site-footer-brand .contact-line, .site-footer-brand .contact-profile { display: inline-flex; align-items: center; }
.site-footer-brand .contact-profile { gap: 5px; }
@media (max-width: 990px) {
  .hero { grid-template-columns: minmax(0, 1fr); gap: 26px; }
  .hero-copy { max-width: 37em; }
  .hero-copy h1 { font-size: clamp(3rem, 8vw, 5.5rem); }
  .title-line { display: inline; }
  .market-totals { width: min(100%, 450px); margin-top: 23px; }
  .map { height: clamp(218px, 34vw, 295px); }
  .tile strong { font-size: .9375rem; }
}
@media (max-width: 650px) {
  .header-inner { min-height: 65px; }
  .brand small { display: none; }
  .brand strong { font-size: 21px; }
  .header-inner .button { min-height: 44px; padding: 8px 12px; }
  .hero { padding-block: 32px; }
  .hero-copy h1 { font-size: clamp(2.4rem, 7.8vw, 3.2rem); }
  .hero-copy > p { margin-top: 15px; }
  .hero-actions { margin-top: 20px; }
  .tile strong { font-size: .78rem; }
  .tile em { font-size: .72rem; }
  .tile > span { padding-inline: 4px; }
  .tile[data-size="large"] strong { font-size: .94rem; }
  .tile[data-size="large"] em { font-size: .82rem; }
  .feature-grid { grid-template-columns: 1fr; }
  .stock-button { min-height: 40px; }
  .snapshot-date { padding-inline: 4px; }
  .chart-legend { gap: 5px 8px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .particle-field { display: none; }
  *, *::before, *::after { transition: none !important; }
}
