:root {
  color-scheme: light;
  --paper: #f5f4ef;
  --paper-deep: #ebe9e1;
  --surface: #ffffff;
  --ink: #13231e;
  --ink-soft: #41534c;
  --muted: #718078;
  --line: #dfe3dc;
  --line-strong: #c9d0c9;
  --green: #12805f;
  --green-dark: #075c43;
  --green-soft: #e7f3ee;
  --gold: #b98a3b;
  --gold-soft: #f4ead7;
  --red: #b94c43;
  --red-soft: #f8e9e6;
  --shadow: 0 24px 70px rgba(23, 45, 36, 0.1);
  --shadow-soft: 0 10px 34px rgba(23, 45, 36, 0.07);
  --max: 1240px;
  font-family: "Avenir Next", Avenir, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  overflow-x: hidden;
  color: var(--ink);
  background:
    radial-gradient(circle at 8% 0%, rgba(18, 128, 95, 0.06), transparent 24rem),
    var(--paper);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body.modal-open {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  color: inherit;
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 30;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 40px;
  height: 74px;
  padding: 0 max(36px, calc((100vw - var(--max)) / 2));
  border-bottom: 1px solid transparent;
  transition: background 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.site-header[data-elevated="true"] {
  border-color: rgba(201, 208, 201, 0.82);
  background: rgba(250, 249, 245, 0.9);
  box-shadow: 0 8px 32px rgba(23, 45, 36, 0.06);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.brand-mark {
  display: block;
  width: 32px;
  height: 32px;
  overflow: hidden;
  border-radius: 10px;
  box-shadow: 0 7px 18px rgba(7, 48, 37, 0.14);
}

.brand-mark img {
  display: block;
  width: 100%;
  height: 100%;
}

.brand-copy strong,
.brand-copy small {
  display: block;
}

.brand-copy strong {
  font-family: Optima, Candara, "Avenir Next", sans-serif;
  font-size: 17px;
  letter-spacing: -0.02em;
}

.brand-copy strong span {
  color: var(--gold);
}

.brand-copy small {
  margin-top: -2px;
  color: var(--muted);
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.nav-links {
  display: flex;
  justify-content: center;
  gap: 32px;
}

.nav-links a {
  position: relative;
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 700;
}

.nav-links a::after {
  content: "";
  position: absolute;
  inset: auto 0 -7px;
  height: 1px;
  background: var(--green);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 180ms ease;
}

.nav-links a:hover::after {
  transform: scaleX(1);
}

.header-actions,
.header-live {
  display: flex;
  align-items: center;
}

.header-actions {
  gap: 16px;
}

.header-live {
  gap: 7px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.header-live i,
.live-pill i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #20a879;
  box-shadow: 0 0 0 5px rgba(32, 168, 121, 0.11);
}

.language-toggle {
  min-width: 46px;
  height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.68);
  cursor: pointer;
  font-size: 11px;
  font-weight: 800;
}

.language-toggle:hover {
  border-color: var(--green);
  color: var(--green-dark);
}

.hero {
  position: relative;
  overflow: clip;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(430px, 0.9fr);
  gap: 56px;
  align-items: center;
  width: min(var(--max), calc(100% - 56px));
  min-height: 690px;
  margin: 0 auto;
  padding: 142px 0 72px;
}

.hero::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: 70px;
  right: -22vw;
  width: 72vw;
  height: 520px;
  opacity: 0.52;
  background-image:
    linear-gradient(rgba(18, 128, 95, 0.075) 1px, transparent 1px),
    linear-gradient(90deg, rgba(18, 128, 95, 0.075) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: linear-gradient(90deg, transparent, #000 20%, #000 80%, transparent);
}

.hero-copy-block {
  min-width: 0;
}

.eyebrow {
  margin: 0 0 18px;
  color: var(--green);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  font-family: Optima, Candara, "Avenir Next", "PingFang SC", sans-serif;
}

h1 {
  max-width: 690px;
  margin-bottom: 26px;
  font-size: clamp(46px, 4.6vw, 62px);
  font-weight: 650;
  line-height: 1.06;
  letter-spacing: -0.055em;
}

h1 span,
h1 em {
  display: block;
}

h1 em {
  color: var(--green-dark);
  font-style: normal;
  white-space: nowrap;
}

.hero-lead {
  max-width: 620px;
  margin-bottom: 32px;
  color: var(--ink-soft);
  font-size: 17px;
  line-height: 1.9;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 24px;
}

.primary-button {
  display: inline-flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  padding: 0 24px;
  border: 1px solid var(--green-dark);
  border-radius: 8px;
  color: white;
  background: var(--green-dark);
  box-shadow: 0 12px 26px rgba(7, 92, 67, 0.18);
  font-size: 13px;
  font-weight: 800;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.primary-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px rgba(7, 92, 67, 0.23);
}

.refresh-note {
  display: grid;
  gap: 2px;
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.refresh-note strong {
  color: var(--ink-soft);
  font-size: 12px;
  letter-spacing: 0;
  text-transform: none;
}

.hero-board {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(7, 92, 67, 0.16);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px);
}

.hero-board::after {
  content: "";
  position: absolute;
  top: 88px;
  right: 28px;
  width: 142px;
  height: 142px;
  opacity: 0.035;
  background: url("./assets/brand/quantxau-mark.svg?v=20260807d") center / contain no-repeat;
  pointer-events: none;
}

.board-head,
.board-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.board-head {
  padding: 24px 26px;
  border-bottom: 1px solid var(--line);
}

.board-head strong,
.board-label {
  display: block;
}

.board-head strong {
  margin-top: 2px;
  font-family: Optima, sans-serif;
  font-size: 19px;
}

.board-label {
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.13em;
}

.live-pill {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 7px 10px;
  border-radius: 999px;
  color: var(--green-dark);
  background: var(--green-soft);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.1em;
}

.board-main {
  position: relative;
  z-index: 1;
  padding: 30px 28px 0;
}

.board-main > span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.board-main div {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-top: -4px;
}

.board-main strong {
  color: var(--green-dark);
  font-family: Optima, sans-serif;
  font-size: 72px;
  font-weight: 650;
  letter-spacing: -0.06em;
}

.board-main small {
  color: var(--muted);
  font-size: 19px;
  font-weight: 700;
}

.hero-curve {
  display: block;
  width: calc(100% - 48px);
  height: 150px;
  margin: -6px 24px 0;
}

.curve-grid {
  fill: none;
  stroke: rgba(18, 128, 95, 0.08);
  stroke-width: 1;
}

.curve-area {
  fill: url(#heroArea);
}

.curve-line {
  fill: none;
  stroke: var(--green);
  stroke-linecap: round;
  stroke-width: 3;
  vector-effect: non-scaling-stroke;
  stroke-dasharray: 1000;
  animation: draw-line 1.5s ease both;
}

.board-foot {
  gap: 1px;
  border-top: 1px solid var(--line);
  background: var(--line);
}

.board-foot div {
  flex: 1;
  min-width: 0;
  padding: 18px 20px;
  background: rgba(255, 255, 255, 0.98);
}

.board-foot span,
.board-foot strong {
  display: block;
}

.board-foot span {
  overflow: hidden;
  color: var(--muted);
  font-size: 9px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.board-foot strong {
  margin-top: 5px;
  font-family: Optima, sans-serif;
  font-size: 17px;
}

.overview-band {
  border-block: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.72);
}

.overview-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  width: min(var(--max), calc(100% - 56px));
  margin: 0 auto;
}

.overview-metric {
  position: relative;
  min-width: 0;
  padding: 26px 28px 28px;
  border-left: 1px solid var(--line);
}

.overview-metric:last-child {
  border-right: 1px solid var(--line);
}

.overview-metric span,
.overview-metric strong,
.overview-metric small {
  display: block;
}

.overview-metric span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.overview-metric strong {
  margin: 8px 0 4px;
  font-family: Optima, sans-serif;
  font-size: 34px;
  font-weight: 650;
  letter-spacing: -0.04em;
}

.overview-metric small {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.metric-skeleton {
  height: 112px;
  border-left: 1px solid var(--line);
  background: linear-gradient(90deg, transparent, rgba(18, 128, 95, 0.05), transparent);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
}

.section {
  width: min(var(--max), calc(100% - 56px));
  margin: 0 auto;
  padding: 104px 0;
  scroll-margin-top: 88px;
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.55fr);
  gap: 80px;
  align-items: end;
  margin-bottom: 38px;
}

h2 {
  max-width: 800px;
  margin-bottom: 0;
  font-size: clamp(36px, 4vw, 54px);
  font-weight: 650;
  line-height: 1.12;
  letter-spacing: -0.045em;
}

.heading-meta {
  padding-left: 26px;
  border-left: 2px solid var(--green);
}

.heading-meta p {
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 13px;
}

.heading-meta strong {
  color: var(--green-dark);
  font-size: 12px;
}

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

.history-card {
  position: relative;
  display: flex;
  min-width: 0;
  min-height: 550px;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
  animation: card-in 500ms ease both;
}

.history-card:hover {
  z-index: 1;
  transform: translateY(-4px);
  border-color: rgba(18, 128, 95, 0.34);
  box-shadow: 0 20px 48px rgba(23, 45, 36, 0.11);
}

.history-card.offline {
  background: #f9f9f6;
  box-shadow: none;
}

.history-card.offline::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(145deg, rgba(245, 244, 239, 0.1), rgba(245, 244, 239, 0.38));
}

.history-card > * {
  position: relative;
  z-index: 1;
}

.history-card-head {
  padding: 22px 22px 6px;
}

.history-card-topline,
.history-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.history-card-topline {
  margin-bottom: 14px;
}

.history-symbol {
  color: var(--green-dark);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.1em;
}

.history-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 8px;
  border-radius: 999px;
  color: var(--green-dark);
  background: var(--green-soft);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.history-badge::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
}

.history-badge.offline {
  color: var(--muted);
  background: #eceeea;
}

.history-card h3 {
  min-height: 48px;
  margin: 0;
  font-size: 19px;
  font-weight: 650;
  line-height: 1.25;
}

.history-summary {
  display: -webkit-box;
  min-height: 50px;
  margin: 8px 0 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.55;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.history-chart {
  position: relative;
  height: 122px;
  margin: 18px 16px 0;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

.history-chart::before {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(0deg, transparent 0 39px, rgba(18, 128, 95, 0.055) 39px 40px);
}

.history-chart svg {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
}

.history-chart .area {
  fill: rgba(18, 128, 95, 0.1);
}

.history-chart .line {
  fill: none;
  stroke: var(--green);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2.2;
  vector-effect: non-scaling-stroke;
}

.history-card.negative .history-chart .area {
  fill: rgba(185, 76, 67, 0.08);
}

.history-card.negative .history-chart .line {
  stroke: var(--red);
}

.history-card.offline .history-chart .line {
  stroke: #aab2ac;
  stroke-dasharray: 5 6;
}

.history-card.offline .history-chart .area {
  fill: transparent;
}

.history-returns,
.history-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  padding: 14px 20px 0;
}

.history-returns {
  gap: 1px;
  margin: 12px 20px 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(18, 128, 95, 0.13);
  border-radius: 9px;
  background: rgba(18, 128, 95, 0.13);
}

.history-returns div {
  min-width: 0;
  padding: 11px 9px;
  background: var(--green-soft);
}

.history-window {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 20px 0;
  color: var(--muted);
  font-size: 9px;
}

.history-window span {
  color: var(--green-dark);
  font-weight: 900;
  letter-spacing: 0.04em;
}

.history-window strong {
  overflow: hidden;
  color: var(--ink-soft);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.history-window small {
  margin-left: auto;
  white-space: nowrap;
}

.history-returns span,
.history-metrics span,
.history-pnl span {
  display: block;
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.history-returns strong,
.history-metrics strong {
  display: block;
  margin-top: 4px;
  font-family: Optima, sans-serif;
  font-size: 16px;
}

.history-returns strong {
  color: var(--green-dark);
  font-size: 15px;
}

.history-card-foot {
  align-items: end;
  margin-top: auto;
  padding: 18px 20px 20px;
}

.history-pnl strong {
  display: block;
  margin-top: 3px;
  color: var(--green-dark);
  font-family: Optima, sans-serif;
  font-size: 25px;
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.history-card.negative .history-pnl strong {
  color: var(--red);
}

.history-risk {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 9px;
}

.history-detail-button {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: white;
  cursor: pointer;
  font-size: 11px;
  font-weight: 800;
}

.history-detail-button:hover {
  border-color: var(--green);
  color: var(--green-dark);
}

.empty-state {
  grid-column: 1 / -1;
  min-height: 220px;
  display: grid;
  place-items: center;
  border: 1px dashed var(--line-strong);
  border-radius: 14px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.55);
}

.about-section {
  padding-top: 44px;
}

.about-shell {
  position: relative;
  overflow: hidden;
  padding: 58px;
  border-radius: 24px;
  color: #eaf5f0;
  background:
    radial-gradient(circle at 92% 7%, rgba(86, 198, 159, 0.18), transparent 23rem),
    linear-gradient(145deg, #0b3026 0%, #09271f 58%, #071f19 100%);
  box-shadow: 0 30px 80px rgba(7, 48, 37, 0.2);
}

.about-shell::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.1;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.32) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.32) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: linear-gradient(115deg, transparent 15%, #000 100%);
}

.about-shell > * {
  position: relative;
}

.about-heading {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.65fr);
  gap: 72px;
  align-items: end;
}

.about-heading .eyebrow {
  color: #58caa4;
}

.about-heading h2 {
  max-width: 720px;
  color: #f5fbf8;
}

.about-heading > p {
  margin: 0;
  padding-left: 24px;
  border-left: 1px solid rgba(112, 216, 181, 0.6);
  color: #a9c0b7;
  font-size: 13px;
  line-height: 1.85;
}

.about-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 44px;
  overflow: hidden;
  border-block: 1px solid rgba(164, 211, 194, 0.18);
}

.about-stats div {
  min-width: 0;
  padding: 24px 20px 24px 0;
  border-right: 1px solid rgba(164, 211, 194, 0.18);
}

.about-stats div:not(:first-child) {
  padding-left: 24px;
}

.about-stats div:last-child {
  border-right: 0;
}

.about-stats strong,
.about-stats span {
  display: block;
}

.about-stats strong {
  color: #effaf6;
  font-family: Optima, Candara, "Avenir Next", sans-serif;
  font-size: 31px;
  font-weight: 650;
  letter-spacing: -0.04em;
}

.about-stats span {
  margin-top: 3px;
  overflow: hidden;
  color: #79988d;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(0, 0.94fr);
  gap: 20px;
  margin-top: 32px;
}

.about-story,
.about-principles {
  min-width: 0;
}

.about-story {
  display: flex;
  min-height: 410px;
  flex-direction: column;
  padding: 34px;
  border: 1px solid rgba(162, 214, 195, 0.2);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.055);
}

.about-index,
.about-principles article > span {
  color: #58caa4;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.13em;
}

.about-story h3,
.about-principles h3 {
  color: #f2faf7;
}

.about-story h3 {
  max-width: 480px;
  margin: 46px 0 16px;
  font-size: 30px;
  line-height: 1.18;
}

.about-story p,
.about-principles p {
  color: #9cb4aa;
  font-size: 12px;
  line-height: 1.8;
}

.about-story blockquote {
  margin: auto 0 0;
  padding-top: 28px;
  border-top: 1px solid rgba(164, 211, 194, 0.18);
  color: #d9ebe4;
  font-family: Optima, Candara, "PingFang SC", sans-serif;
  font-size: 19px;
  line-height: 1.55;
}

.about-principles {
  display: grid;
  gap: 12px;
}

.about-principles article {
  display: grid;
  grid-template-columns: 86px minmax(120px, 0.54fr) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  padding: 24px;
  border: 1px solid rgba(162, 214, 195, 0.16);
  border-radius: 14px;
  background: rgba(2, 19, 15, 0.2);
}

.about-principles h3,
.about-principles p {
  margin: 0;
}

.about-principles h3 {
  font-size: 16px;
  line-height: 1.35;
}

.about-principles p {
  font-size: 11px;
  line-height: 1.7;
}

.partner-panel {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  margin-top: 20px;
  padding: 20px 22px;
  border: 1px solid rgba(199, 174, 109, 0.33);
  border-radius: 14px;
  background: rgba(184, 142, 59, 0.08);
}

.partner-mark {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  align-content: center;
  border: 1px solid rgba(211, 183, 112, 0.45);
  border-radius: 12px;
  color: #e9d49f;
  background: rgba(9, 27, 22, 0.65);
}

.partner-mark span,
.partner-mark small {
  display: block;
  line-height: 1;
}

.partner-mark span {
  font-family: Optima, sans-serif;
  font-size: 18px;
  font-weight: 800;
}

.partner-mark small {
  margin-top: 4px;
  font-size: 6px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.partner-copy strong {
  color: #f0dfb5;
  font-size: 12px;
}

.partner-copy p {
  margin: 4px 0 0;
  color: #9eb1aa;
  font-size: 10px;
  line-height: 1.6;
}

.partner-panel > a {
  padding: 10px 12px;
  border: 1px solid rgba(223, 201, 145, 0.3);
  border-radius: 8px;
  color: #e9d49f;
  font-size: 9px;
  font-weight: 800;
  white-space: nowrap;
  transition: border-color 180ms ease, background 180ms ease;
}

.partner-panel > a:hover {
  border-color: rgba(233, 212, 159, 0.65);
  background: rgba(233, 212, 159, 0.07);
}

.modal-layer[hidden] {
  display: none;
}

.modal-layer {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: grid;
  place-items: center;
  padding: 8px;
  background: rgba(14, 20, 19, 0.62);
  backdrop-filter: blur(8px);
}

.detail-modal {
  position: relative;
  width: min(1560px, calc(100vw - 16px));
  height: min(860px, calc(100dvh - 16px));
  max-height: calc(100dvh - 16px);
  overflow: hidden;
  padding: 0;
  border: 1px solid #3a454e;
  border-radius: 7px;
  background: #20272e;
  box-shadow: 0 28px 90px rgba(3, 10, 8, 0.45);
}

.modal-close {
  position: absolute;
  top: 7px;
  right: 9px;
  z-index: 5;
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border: 1px solid #424e57;
  border-radius: 50%;
  color: #b7c3ca;
  background: #252e35;
  cursor: pointer;
  font-size: 17px;
  line-height: 1;
}

.detail-head {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.detail-status {
  display: inline-flex;
  margin-bottom: 9px;
  color: var(--green);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.detail-head h2 {
  margin-bottom: 5px;
  font-size: 36px;
}

.detail-head p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.detail-data-state {
  display: inline-flex;
  min-width: 0;
  align-items: center;
  overflow: hidden;
  color: #65cfb1;
  background: transparent;
  font-size: 9px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.detail-data-state::before {
  content: "";
  width: 5px;
  height: 5px;
  flex: 0 0 auto;
  margin-right: 6px;
  border-radius: 50%;
  background: currentColor;
}

.detail-data-state.stale {
  color: #ef8579;
  background: transparent;
}

.performance-terminal {
  display: flex;
  height: 100%;
  min-height: 0;
  flex-direction: column;
  margin: 0;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  color: #c8d2d9;
  background: #20272e;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.04);
}

.terminal-toolbar {
  flex: 0 0 auto;
  display: grid;
  min-height: 44px;
  grid-template-columns: minmax(300px, 1fr) auto minmax(300px, 1fr);
  align-items: center;
  gap: 14px;
  padding: 6px 52px 6px 10px;
  border-bottom: 1px solid #343e47;
  background: #1b2127;
}

.terminal-ranges {
  display: flex;
  align-items: center;
  gap: 3px;
}

.terminal-ranges button {
  min-width: 34px;
  min-height: 28px;
  padding: 0 8px;
  border: 0;
  border-radius: 6px;
  color: #8d9aa4;
  background: transparent;
  cursor: pointer;
  font-size: 10px;
  font-weight: 800;
}

.terminal-trajectory {
  color: #6e7b85;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.18em;
}

.terminal-meta {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: flex-end;
  gap: 15px;
}

.terminal-ranges button:hover,
.terminal-ranges button.active {
  color: #e7f7fb;
  background: #2b3b43;
}

.terminal-ranges button.active {
  box-shadow: inset 0 -2px #38c2e8;
}

.terminal-database {
  display: flex;
  align-items: baseline;
  gap: 9px;
  color: #73818b;
  flex: 0 0 auto;
  font-size: 8px;
  letter-spacing: 0.06em;
}

.terminal-database strong {
  color: #aebbc3;
  font-size: 9px;
  letter-spacing: 0;
}

.terminal-chart {
  position: relative;
  height: 194px;
  flex: 0 0 auto;
  overflow: hidden;
  border-bottom: 1px solid #37414a;
  background: linear-gradient(180deg, #232b32 0%, #20272e 100%);
}

.terminal-chart svg {
  position: absolute;
  top: 38px;
  left: 0;
  display: block;
  width: 100%;
  height: calc(100% - 38px);
}

.terminal-grid {
  fill: none;
  stroke: #35414a;
  stroke-width: 1;
}

.terminal-area {
  fill: rgba(54, 194, 232, 0.08);
}

.terminal-line {
  fill: none;
  stroke: #38c2e8;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}

.terminal-equity-label {
  position: absolute;
  top: 7px;
  left: 11px;
  display: grid;
  min-width: 112px;
  padding: 5px 9px 6px;
  border: 1px solid rgba(92, 112, 124, 0.34);
  border-radius: 5px;
  background: rgba(27, 33, 39, 0.9);
  place-items: start;
  box-shadow: 0 5px 18px rgba(8, 13, 16, 0.12);
}

.terminal-equity-label span {
  color: #85939d;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.09em;
}

.terminal-equity-label strong {
  margin-top: 2px;
  color: #f17870;
  font-family: Optima, sans-serif;
  font-size: 18px;
  line-height: 1;
}

.terminal-axis {
  position: absolute;
  right: 11px;
  bottom: 6px;
  left: 11px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 12px;
  align-items: center;
  color: #7d8992;
  font-size: 8px;
}

.terminal-axis strong {
  overflow: hidden;
  color: #a7b4bc;
  font-size: 10px;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.terminal-axis span:last-child {
  text-align: right;
}

.terminal-chart-empty {
  display: grid;
  height: 100%;
  place-items: center;
  color: #74828c;
  font-size: 11px;
}

.terminal-table-shell {
  min-height: 0;
  max-height: 218px;
  flex: 0 1 218px;
  overflow: auto;
  border-bottom: 1px solid #3b454d;
  scrollbar-color: #53636e #20272e;
}

.daily-performance-table {
  width: 100%;
  min-width: 1280px;
  table-layout: fixed;
  background: #20272e;
}

.daily-performance-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 8px 5px;
  border-color: #39434c;
  color: #9daab3;
  background: #252e35;
  font-size: 8px;
  letter-spacing: 0.02em;
  text-transform: none;
}

.daily-performance-table td {
  overflow: hidden;
  padding: 7px 5px;
  border-color: #313b43;
  color: #c1ccd3;
  background: #20272e;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 8.5px;
  text-overflow: ellipsis;
}

.daily-performance-table th:nth-child(1) { width: 92px; }
.daily-performance-table th:nth-child(2) { width: 62px; }
.daily-performance-table th:nth-child(3) { width: 86px; }
.daily-performance-table th:nth-child(4) { width: 52px; }
.daily-performance-table th:nth-child(5) { width: 70px; }
.daily-performance-table th:nth-child(6) { width: 66px; }
.daily-performance-table th:nth-child(7) { width: 62px; }
.daily-performance-table th:nth-child(8) { width: 82px; }
.daily-performance-table th:nth-child(9) { width: 82px; }
.daily-performance-table th:nth-child(10) { width: 64px; }
.daily-performance-table th:nth-child(11) { width: 84px; }
.daily-performance-table th:nth-child(12) { width: 64px; }
.daily-performance-table th:nth-child(13) { width: 180px; }
.daily-performance-table th:nth-child(14) { width: 64px; }
.daily-performance-table th:nth-child(15) { width: 58px; }

.daily-performance-table tbody tr:hover td {
  background: #242e35;
}

.daily-performance-table .terminal-period {
  color: #e0e7eb;
  font-family: inherit;
  font-weight: 800;
}

.daily-performance-table .pnl-win {
  color: #ff7e74;
}

.daily-performance-table .pnl-loss {
  color: #48c7df;
}

.recent-orders-panel {
  display: flex;
  min-height: 190px;
  flex: 1 1 300px;
  flex-direction: column;
  overflow: hidden;
  background: #1d242a;
}

.recent-orders-head {
  display: flex;
  min-height: 43px;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 7px 12px;
  border-bottom: 1px solid #3a444c;
  background: #1b2127;
}

.recent-orders-head > div {
  display: flex;
  min-width: 0;
  align-items: baseline;
  gap: 12px;
}

.recent-orders-head strong {
  color: #dce5e9;
  font-size: 10px;
  letter-spacing: 0.08em;
}

.recent-orders-head span {
  overflow: hidden;
  color: #75838c;
  font-size: 8.5px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recent-orders-head b {
  flex: 0 0 auto;
  color: #67cfb2;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 9px;
  font-weight: 700;
}

.recent-orders-shell {
  min-height: 0;
  flex: 1 1 auto;
  overflow: auto;
  scrollbar-color: #53636e #20272e;
}

.recent-orders-table {
  width: 100%;
  min-width: 1280px;
  table-layout: fixed;
  background: #1d242a;
}

.recent-orders-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 7px 6px;
  border-color: #39434c;
  color: #94a2ab;
  background: #252e35;
  font-size: 8px;
  font-weight: 800;
}

.recent-orders-table td {
  overflow: hidden;
  padding: 7px 6px;
  border-color: #303940;
  color: #bdc8ce;
  background: #1d242a;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 8.5px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recent-orders-table tbody tr:hover td {
  background: #232d33;
}

.recent-orders-table th:nth-child(1) { width: 108px; }
.recent-orders-table th:nth-child(2) { width: 142px; }
.recent-orders-table th:nth-child(3) { width: 74px; }
.recent-orders-table th:nth-child(4) { width: 58px; }
.recent-orders-table th:nth-child(5) { width: 64px; }
.recent-orders-table th:nth-child(6) { width: 142px; }
.recent-orders-table th:nth-child(7),
.recent-orders-table th:nth-child(8),
.recent-orders-table th:nth-child(9),
.recent-orders-table th:nth-child(10) { width: 82px; }
.recent-orders-table th:nth-child(11) { width: 84px; }

.recent-orders-table .order-ticket,
.recent-orders-table .order-symbol {
  color: #e0e7eb;
  font-weight: 800;
}

.recent-orders-table .order-buy,
.recent-orders-table .pnl-win {
  color: #ff7e74;
}

.recent-orders-table .order-sell,
.recent-orders-table .pnl-loss {
  color: #48c7df;
}

.floating-estimate {
  cursor: help;
  text-decoration: underline dotted rgba(177, 194, 203, 0.45);
  text-underline-offset: 2px;
}

.terminal-holding {
  min-width: 0;
}

.detail-kpis {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  margin: 24px 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--line);
}

.detail-kpis div {
  min-width: 0;
  padding: 15px;
  background: white;
}

.detail-kpis span,
.detail-kpis strong {
  display: block;
}

.detail-kpis span {
  overflow: hidden;
  color: var(--muted);
  font-size: 9px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.detail-kpis strong {
  margin-top: 6px;
  font-family: Optima, sans-serif;
  font-size: 17px;
}

.detail-section + .detail-section {
  margin-top: 26px;
}

.detail-section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.detail-section-title h3 {
  margin: 0;
  font-size: 16px;
}

.detail-section-title span {
  color: var(--muted);
  font-size: 11px;
}

.table-shell {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: white;
}

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

th,
td {
  padding: 12px 14px;
  border-bottom: 1px solid #edf0eb;
  text-align: left;
  white-space: nowrap;
}

th {
  color: var(--muted);
  background: #f7f8f5;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

td {
  color: var(--ink-soft);
  font-size: 11px;
}

tbody tr:last-child td {
  border-bottom: 0;
}

.side-buy,
.pnl-win {
  color: var(--green);
  font-weight: 800;
}

.side-sell,
.pnl-loss {
  color: var(--red);
  font-weight: 800;
}

.empty-row td {
  height: 76px;
  color: var(--muted);
  text-align: center;
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 28px max(28px, calc((100vw - var(--max)) / 2));
  border-top: 1px solid var(--line);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.5);
  font-size: 11px;
}

.site-footer p {
  margin: 0;
}

.site-footer strong {
  color: var(--ink);
  font-family: Optima, sans-serif;
}

@keyframes draw-line {
  from { stroke-dashoffset: 1000; }
  to { stroke-dashoffset: 0; }
}

@keyframes card-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes shimmer {
  to { background-position: -200% 0; }
}

@media (max-width: 1040px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 48px;
    padding-top: 140px;
  }

  .hero-copy-block {
    max-width: 760px;
  }

  .hero-board {
    width: min(720px, 100%);
  }

  .history-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .detail-kpis {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .about-shell {
    padding: 46px;
  }

  .about-heading {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .about-heading > p {
    max-width: 720px;
  }

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

  .about-story {
    min-height: 350px;
  }
}

@media (max-width: 720px) {
  .site-header {
    grid-template-columns: 1fr auto;
    height: 66px;
    padding: 0 22px;
  }

  .brand-mark {
    width: 30px;
    height: 30px;
    border-radius: 9px;
  }

  .brand-copy small,
  .nav-links,
  .header-live {
    display: none;
  }

  .hero,
  .overview-grid,
  .section {
    width: min(var(--max), calc(100% - 32px));
  }

  .hero {
    min-height: auto;
    padding: 116px 0 64px;
  }

  .hero::before {
    top: 40px;
    right: -60vw;
    width: 150vw;
    height: 420px;
    background-size: 40px 40px;
  }

  h1 {
    font-size: clamp(40px, 12vw, 56px);
    letter-spacing: -0.05em;
  }

  h1 em {
    white-space: normal;
  }

  .hero-lead {
    font-size: 15px;
    line-height: 1.8;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
    gap: 16px;
  }

  .primary-button {
    width: 100%;
  }

  .board-main strong {
    font-size: 62px;
  }

  .hero-curve {
    height: 128px;
  }

  .board-foot {
    align-items: stretch;
  }

  .board-foot div {
    padding: 14px 10px;
  }

  .board-foot strong {
    font-size: 14px;
  }

  .overview-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .overview-metric:nth-child(3) {
    border-top: 1px solid var(--line);
  }

  .overview-metric:nth-child(4) {
    border-top: 1px solid var(--line);
    border-right: 1px solid var(--line);
  }

  .overview-metric {
    padding: 20px;
  }

  .overview-metric strong {
    font-size: 28px;
  }

  .section {
    padding: 78px 0;
  }

  .section-heading {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  h2 {
    font-size: 36px;
  }

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

  .history-card {
    min-height: 540px;
  }

  .about-section {
    padding-top: 22px;
  }

  .about-shell {
    margin-inline: -16px;
    padding: 40px 24px;
    border-radius: 0;
  }

  .about-heading > p {
    padding: 0;
    border-left: 0;
  }

  .about-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .about-stats div:nth-child(2) {
    border-right: 0;
  }

  .about-stats div:nth-child(n + 3) {
    border-top: 1px solid rgba(164, 211, 194, 0.18);
  }

  .about-stats div:nth-child(3) {
    padding-left: 0;
  }

  .about-stats strong {
    font-size: 27px;
  }

  .about-stats span {
    min-height: 2.8em;
    line-height: 1.4;
    white-space: normal;
  }

  .about-story {
    min-height: 420px;
    padding: 26px;
  }

  .about-story h3 {
    margin-top: 34px;
    font-size: 25px;
  }

  .about-principles article {
    grid-template-columns: 1fr;
    gap: 9px;
    padding: 22px;
  }

  .partner-panel {
    grid-template-columns: auto 1fr;
  }

  .partner-panel > a {
    grid-column: 1 / -1;
    text-align: center;
  }

  .detail-modal {
    width: calc(100vw - 8px);
    height: calc(100dvh - 8px);
    max-height: calc(100dvh - 8px);
    border-radius: 5px;
    padding: 0;
  }

  .terminal-toolbar {
    align-items: stretch;
    grid-template-columns: 1fr;
    gap: 7px;
    padding: 7px 42px 7px 7px;
  }

  .terminal-ranges {
    overflow-x: auto;
  }

  .terminal-ranges button {
    flex: 1;
  }

  .terminal-database {
    justify-content: space-between;
  }

  .terminal-trajectory,
  .terminal-database span,
  .detail-data-state {
    display: none;
  }

  .terminal-meta {
    display: none;
  }

  .terminal-chart {
    height: 150px;
  }

  .terminal-equity-label strong {
    font-size: 18px;
  }

  .terminal-axis strong {
    max-width: 120px;
  }

  .terminal-table-shell {
    max-height: 155px;
    flex: 0 0 155px;
  }

  .recent-orders-panel {
    min-height: 0;
    flex: 1 1 220px;
  }

  .recent-orders-head {
    padding-right: 10px;
    padding-left: 10px;
  }

  .recent-orders-head span {
    display: none;
  }

  .detail-head {
    padding-right: 48px;
  }

  .detail-head h2 {
    font-size: 30px;
  }

  .detail-kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
    padding: 24px 18px;
  }
}

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