:root {
  color-scheme: dark;
  --bg: #08110f;
  --panel: #111d19;
  --panel-2: #172820;
  --text: #f4f7ee;
  --muted: #afbbb1;
  --line: #254034;
  --accent: #f2b705;
  --accent-2: #29d391;
  --danger: #ff6b6b;
  --radius: 8px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body.light {
  color-scheme: light;
  --bg: #f6f5ee;
  --panel: #ffffff;
  --panel-2: #eef4ee;
  --text: #17201b;
  --muted: #526157;
  --line: #d9e0d8;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 20% 0%, rgba(41, 211, 145, 0.16), transparent 28rem),
    linear-gradient(180deg, rgba(242, 183, 5, 0.08), transparent 22rem),
    var(--bg);
  color: var(--text);
  letter-spacing: 0;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: 72px;
  padding: 14px clamp(18px, 5vw, 72px);
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  white-space: nowrap;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent);
  color: #111;
}

.nav {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: 1;
  overflow-x: auto;
  color: var(--muted);
  font-size: 15px;
}

.nav a:hover,
.cluster-list a:hover,
.footer a:hover {
  color: var(--accent);
}

.theme-toggle {
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  color: var(--text);
  cursor: pointer;
}

main {
  width: min(1180px, calc(100% - 36px));
  margin: 0 auto;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
  gap: 28px;
  align-items: stretch;
  min-height: 520px;
  padding: 68px 0 36px;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.eyebrow,
.tag,
.label {
  color: var(--accent-2);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0;
}

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

h1 {
  max-width: 840px;
  margin-bottom: 22px;
  font-size: clamp(42px, 8vw, 86px);
  line-height: 0.95;
}

h2 {
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.05;
}

h3 {
  font-size: 22px;
  line-height: 1.18;
}

.lead {
  max-width: 760px;
  color: var(--muted);
  font-size: 20px;
  line-height: 1.6;
}

.search {
  display: flex;
  width: min(620px, 100%);
  margin-top: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--panel);
}

.search input {
  min-width: 0;
  flex: 1;
  border: 0;
  padding: 16px 18px;
  background: transparent;
  color: var(--text);
  font: inherit;
}

.search button {
  border: 0;
  padding: 0 22px;
  background: var(--accent);
  color: #121212;
  font-weight: 800;
  cursor: pointer;
}

.market-board {
  display: grid;
  align-content: end;
  gap: 14px;
  min-height: 420px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(145deg, rgba(242, 183, 5, 0.18), transparent 45%),
    linear-gradient(315deg, rgba(41, 211, 145, 0.18), transparent 48%),
    var(--panel);
}

.market-board div {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--panel-2) 82%, transparent);
}

.market-board strong {
  display: block;
  margin-top: 8px;
  font-size: 28px;
}

.ticker-strip {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 14px 0 34px;
}

.ticker-strip span {
  flex: 0 0 auto;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: var(--panel);
}

.section {
  padding: 48px 0;
  border-top: 1px solid var(--line);
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 22px;
}

.section-head p,
.split p {
  max-width: 520px;
  color: var(--muted);
  line-height: 1.6;
}

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

.card {
  min-height: 260px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}

.card a {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 22px;
}

.card p {
  color: var(--muted);
  line-height: 1.55;
}

.feature-card {
  grid-column: span 2;
  background:
    linear-gradient(135deg, rgba(242, 183, 5, 0.2), transparent 55%),
    var(--panel);
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 40px;
}

.cluster-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.cluster-list a {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  font-weight: 700;
}

.faq {
  display: grid;
  gap: 12px;
}

details {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}

summary {
  cursor: pointer;
  padding: 18px;
  font-weight: 800;
}

details p {
  padding: 0 18px 18px;
  color: var(--muted);
  line-height: 1.6;
}

.footer {
  width: min(1180px, calc(100% - 36px));
  margin: 0 auto;
  padding: 36px 0 52px;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

mark {
  background: rgba(242, 183, 5, 0.25);
  color: inherit;
}

.empty-search {
  display: none;
  padding: 18px;
  border: 1px solid var(--danger);
  border-radius: var(--radius);
  color: var(--danger);
}

@media (max-width: 880px) {
  .site-header {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .nav {
    order: 3;
    width: 100%;
  }

  .hero,
  .split {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    padding-top: 42px;
  }

  .market-board {
    min-height: 260px;
  }

  .article-grid,
  .cluster-list {
    grid-template-columns: 1fr;
  }

  .feature-card {
    grid-column: auto;
  }

  .section-head {
    display: block;
  }
}

@media (max-width: 520px) {
  main,
  .footer {
    width: min(100% - 24px, 1180px);
  }

  h1 {
    font-size: 40px;
  }

  .search {
    display: grid;
  }

  .search button {
    min-height: 48px;
  }
}
