@import url("https://fonts.googleapis.com/css2?family=Cinzel+Decorative:wght@700&display=swap");

:root {
  --bg: #101a2b;
  --panel: rgba(20, 33, 54, 0.94);
  --panel-soft: rgba(24, 38, 60, 0.84);
  --ink: #eef4ff;
  --muted: #9daecc;
  --line: rgba(162, 178, 201, 0.22);
  --accent: #3f8cff;
  --accent-soft: #82b7ff;
  --positive: #69e2c2;
  --negative: #ff8f7a;
  --neutral: #c7d2e6;
  --shadow: 0 18px 46px rgba(5, 10, 18, 0.34);
  --body-radial-1: rgba(96, 165, 250, 0.2);
  --body-radial-2: rgba(148, 197, 255, 0.12);
  --body-gradient-start: #172335;
  --body-gradient-end: #1b2940;
  --interactive-bg: rgba(24, 36, 58, 0.76);
  --pill-bg: rgba(37, 99, 235, 0.12);
  --pill-ink: #b9d5ff;
  --toggle-active-bg: rgba(63, 140, 255, 0.18);
  --toggle-active-ink: var(--ink);
}

html[data-theme="light"] {
  color-scheme: light;
  --bg: #edf3fb;
  --panel: rgba(255, 255, 255, 0.95);
  --panel-soft: rgba(242, 247, 255, 0.96);
  --ink: #13233b;
  --muted: #5a6c87;
  --line: rgba(99, 115, 145, 0.22);
  --accent: #2563eb;
  --accent-soft: #1d4ed8;
  --positive: #0f9f79;
  --negative: #d4583f;
  --neutral: #5a6c87;
  --shadow: 0 18px 46px rgba(80, 102, 138, 0.14);
  --body-radial-1: rgba(96, 165, 250, 0.18);
  --body-radial-2: rgba(59, 130, 246, 0.1);
  --body-gradient-start: #f3f7fc;
  --body-gradient-end: #ebf1fb;
  --interactive-bg: rgba(255, 255, 255, 0.82);
  --pill-bg: rgba(37, 99, 235, 0.1);
  --pill-ink: #1d4ed8;
  --toggle-active-bg: rgba(37, 99, 235, 0.12);
  --toggle-active-ink: #173c88;
}

* {
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  color-scheme: dark;
}

html[data-font-size="small"] {
  font-size: 15px;
}

html[data-font-size="medium"] {
  font-size: 16px;
}

html[data-font-size="large"] {
  font-size: 17px;
}

body {
  margin: 0;
  font-family: "Manrope", "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, var(--body-radial-1), transparent 36%),
    radial-gradient(circle at 80% 0%, var(--body-radial-2), transparent 26%),
    linear-gradient(180deg, var(--body-gradient-start) 0%, var(--body-gradient-end) 100%);
  transition: background-color 180ms ease, color 180ms ease;
}

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

.mobile-shell {
  width: min(100%, 430px);
  min-height: 100vh;
  margin: 0 auto;
  padding: 16px 14px 28px;
}

.mobile-topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 0 18px;
  background: linear-gradient(180deg, rgba(4, 11, 22, 0.96) 0%, rgba(4, 11, 22, 0.76) 75%, transparent 100%);
  backdrop-filter: blur(14px);
}

.mobile-topbar-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.eyebrow,
.card-kicker {
  margin: 0 0 6px;
  color: var(--accent-soft);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.68rem;
  font-weight: 700;
}

.brand {
  font-family: "Cinzel Decorative", "Cormorant Garamond", Georgia, serif;
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1;
  text-shadow: 0 8px 22px rgba(37, 99, 235, 0.16);
}

.desktop-link {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--interactive-bg);
  color: var(--muted);
  font-size: 0.88rem;
}

.lang-switch,
.theme-switch,
.font-size-switch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--interactive-bg);
  color: var(--muted);
  font-size: 0.82rem;
  white-space: nowrap;
}

.theme-switch,
.font-size-switch {
  gap: 4px;
  padding: 4px;
}

.theme-button,
.font-size-button {
  min-height: 30px;
  padding: 0 10px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.78rem;
  cursor: pointer;
}

.font-size-button[data-font-size-value="small"] {
  font-size: 0.72rem;
}

.font-size-button[data-font-size-value="medium"] {
  font-size: 0.78rem;
}

.font-size-button[data-font-size-value="large"] {
  font-size: 0.86rem;
}

.theme-button:hover,
.theme-button:focus-visible,
.font-size-button:hover,
.font-size-button:focus-visible {
  color: var(--accent-soft);
  outline: none;
}

.theme-button.is-active,
.font-size-button.is-active {
  background: var(--toggle-active-bg);
  color: var(--toggle-active-ink);
  font-weight: 700;
}

.lang-link.is-active {
  color: var(--ink);
  font-weight: 700;
}

.lang-separator {
  color: rgba(149, 167, 198, 0.7);
}

.mobile-nav {
  display: flex;
  gap: 10px;
  padding: 0 0 16px;
  overflow-x: auto;
  scrollbar-width: none;
}

.mobile-nav::-webkit-scrollbar {
  display: none;
}

.mobile-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--interactive-bg);
  color: var(--muted);
  white-space: nowrap;
  font-size: 0.84rem;
}

.mobile-main {
  display: grid;
  gap: 16px;
}

.hero-card,
.mobile-card {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: linear-gradient(180deg, var(--panel) 0%, rgba(8, 14, 25, 0.94) 100%);
  box-shadow: var(--shadow);
}

.hero-card {
  padding: 20px;
}

.mobile-card {
  padding: 18px;
}

h1,
h2 {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  line-height: 1.05;
}

h1 {
  font-size: clamp(2rem, 9vw, 3rem);
  max-width: 11ch;
}

h2 {
  font-size: 1.5rem;
}

.lede {
  margin: 14px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-size: 0.82rem;
}

.status-pill {
  background: var(--pill-bg);
  color: var(--pill-ink);
}

.mobile-news-feed,
.mobile-event-feed {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.mobile-news-item,
.mobile-event-row {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel-soft);
}

.mobile-news-meta,
.mobile-event-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.74rem;
}

.mobile-news-source,
.mobile-impact {
  color: #b9d5ff;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
}

.mobile-news-item h3,
.mobile-event-row h3 {
  margin: 0 0 8px;
  font-size: 1rem;
}

.mobile-news-item p,
.mobile-event-row p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
  font-size: 0.92rem;
}

.mobile-news-link {
  display: inline-flex;
  margin-top: 10px;
  color: #b9d5ff;
  font-size: 0.86rem;
}

.mobile-news-item h3 .mobile-news-link {
  display: inline;
  margin-top: 0;
  color: inherit;
  font-size: inherit;
  text-decoration: none;
}

.mobile-news-item h3 .mobile-news-link:hover {
  color: #82b7ff;
}

.section-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

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

.metric-box {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel-soft);
}

.metric-box span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 0.76rem;
}

.metric-box strong {
  font-size: 0.96rem;
}

.curve-card {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel-soft);
}

.curve-chart {
  width: 100%;
  height: auto;
}

.grid-lines line {
  stroke: rgba(148, 163, 184, 0.16);
  stroke-width: 1;
}

.curve-area {
  fill: rgba(96, 165, 250, 0.2);
}

.curve-line {
  fill: none;
  stroke: #4e8fff;
  stroke-width: 2.5;
  stroke-linecap: round;
}

.curve-points circle {
  fill: #d7ecff;
  stroke: #2563eb;
  stroke-width: 3;
}

.curve-labels {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.8rem;
}

.spot-list {
  display: grid;
}

.spot-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.spot-row:first-child {
  padding-top: 0;
}

.spot-row:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.spot-name,
.spot-symbol {
  display: block;
}

.spot-name {
  margin-bottom: 4px;
  font-size: 0.92rem;
}

.spot-symbol {
  color: var(--muted);
  font-size: 0.76rem;
  letter-spacing: 0.08em;
}

.spot-price {
  text-align: right;
}

.spot-price strong {
  display: block;
  margin-bottom: 4px;
  font-size: 0.95rem;
}

.signal-up {
  color: var(--positive);
}

.signal-down {
  color: var(--negative);
}

.footer-card h2 {
  margin-bottom: 18px;
}

.legal-page .hero-card h1 {
  font-size: clamp(1.45rem, 6vw, 2rem);
}

.legal-page .mobile-card h2 {
  font-size: 1.1rem;
}

.legal-stack + .legal-stack {
  margin-top: 18px;
}

.legal-stack p {
  margin: 0 0 8px;
  color: var(--muted);
  line-height: 1.65;
}

.legal-stack p:last-child {
  margin-bottom: 0;
}

.legal-placeholder {
  color: #ffd08a;
}

.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border-radius: 999px;
  background: linear-gradient(135deg, #63a4ff 0%, #2563eb 100%);
  color: #eef6ff;
  box-shadow: 0 12px 34px rgba(37, 99, 235, 0.34);
}

.strategy-card-mobile h2 {
  margin-bottom: 12px;
  font-variant-numeric: lining-nums;
  font-feature-settings: "lnum" 1;
}

.strategy-card-mobile p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.strategy-list-mobile {
  display: grid;
  gap: 10px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.strategy-list-mobile li {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel-soft);
  color: var(--muted);
  line-height: 1.55;
}

.strategy-list-mobile strong {
  display: block;
  margin-bottom: 4px;
  color: var(--ink);
  font-size: 0.92rem;
}

.strategy-inline-link {
  color: var(--accent-strong);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.strategy-source {
  margin-top: 14px;
  font-size: 0.92rem;
  color: var(--muted);
}

.strategy-card-mobile .cta {
  margin-top: 14px;
}

.payoff-chart {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel-soft);
}

.payoff-chart svg {
  display: block;
  width: 100%;
  height: auto;
}

.payoff-chart-compact {
  margin-top: 12px;
  padding: 12px;
}

.strategy-example {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel-soft);
}

.strategy-example h3 {
  margin: 0 0 10px;
  font-size: 1.02rem;
  font-family: "Cormorant Garamond", Georgia, serif;
}

.strategy-example p {
  margin: 0 0 10px;
}

.strategy-example p:last-child {
  margin-bottom: 0;
}

.strategy-heatmap {
  margin-top: 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  background: var(--panel-soft);
}

.strategy-image-grid {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.strategy-image-card {
  display: block;
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  background: var(--panel-soft);
  cursor: zoom-in;
}

.strategy-heatmap-image {
  display: block;
  width: 100%;
  height: auto;
}

.lede,
.strategy-card-mobile p:not(.card-kicker),
.basics-card-mobile p:not(.card-kicker),
.tools-card-mobile p:not(.card-kicker),
.legal-stack p,
.strategy-example p {
  margin-bottom: 10px;
}

.lede:last-child,
.strategy-card-mobile p:not(.card-kicker):last-child,
.basics-card-mobile p:not(.card-kicker):last-child,
.tools-card-mobile p:not(.card-kicker):last-child,
.legal-stack p:last-child,
.strategy-example p:last-child {
  margin-bottom: 0;
}

.basics-card-mobile h2 {
  margin-bottom: 12px;
}

.basics-card-mobile p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.basics-list-mobile {
  display: grid;
  gap: 10px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.basics-list-mobile li {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel-soft);
  color: var(--muted);
  line-height: 1.55;
}

.basics-list-mobile strong {
  display: block;
  margin-bottom: 4px;
  color: var(--ink);
  font-size: 0.92rem;
}

.tools-card-mobile h2 {
  margin-bottom: 12px;
}

.tools-preview {
  display: block;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  background: var(--panel-soft);
  max-width: min(60%, 260px);
  cursor: zoom-in;
}

.tools-preview-image {
  display: block;
  width: 100%;
  height: auto;
}

.tools-card-mobile p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.tools-preview + p {
  margin-top: 16px;
}

.tools-feature-list {
  margin: 16px 0 0;
  padding-left: 1.1rem;
  color: var(--muted);
  line-height: 1.7;
}

.tools-feature-list li + li {
  margin-top: 9px;
}

.tools-list-mobile {
  display: grid;
  gap: 10px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.tools-list-mobile li {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel-soft);
  color: var(--muted);
  line-height: 1.55;
}

.tools-list-mobile strong {
  display: block;
  margin-bottom: 4px;
  color: var(--ink);
  font-size: 0.92rem;
}

@media (max-width: 360px) {
  .metric-row {
    grid-template-columns: 1fr;
  }

  .section-head,
  .spot-row {
    flex-direction: column;
    align-items: start;
  }

  .spot-price {
    text-align: left;
  }
}
