
/* ── The Exchange (homepage) ───────────────────────── */
.exchange { padding-bottom: 48px; }
.ex-hero { background: radial-gradient(ellipse at center, #FDFCF8 18%, #F0EDE4 100%); padding: 56px 40px 28px; text-align: center; }
.ex-eyebrow { font-family: 'Runtime', sans-serif; font-size: 11px; letter-spacing: 0.25em; color: var(--muted); text-transform: uppercase; }
.orn { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 18px auto 0; max-width: 260px; }
.orn::before, .orn::after { content: ''; flex: 1; height: 1px; background: linear-gradient(to right, transparent, var(--gold), transparent); }
.orn span { width: 7px; height: 7px; border: 1px solid var(--gold); transform: rotate(45deg); }
.ex-title { font-size: 52px; margin: 28px 0 8px; letter-spacing: -0.01em; }
.ex-tagline { font-style: italic; color: var(--muted); margin-bottom: 40px; }
.ex-stats { display: flex; justify-content: center; flex-wrap: wrap; margin-bottom: 36px; }
.ex-stat { padding: 0 32px; border-left: 1px solid var(--border); }
.ex-stat:first-child { border-left: 0; }
.ex-stat-n { font-family: 'Linden Hill', Georgia, serif; font-size: 34px; color: var(--gold); line-height: 1; margin-bottom: 8px; }
.ex-stat-l { font-family: 'Runtime', sans-serif; font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.ticker { overflow: hidden; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--card);
  -webkit-mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent); mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent); }
.ticker-track { display: flex; width: max-content; animation: ticker 60s linear infinite; }
.ticker:hover .ticker-track { animation-play-state: paused; }
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker-track { animation: none; } }
.tick { display: inline-flex; gap: 10px; align-items: baseline; padding: 10px 28px; white-space: nowrap; font-size: 13px; border-right: 1px solid var(--border); }
.tick .up, .tick .down { font-size: 12px; font-weight: 600; }
.ex-sample-note { font-size: 0.75rem; color: var(--faint); font-style: italic; margin-top: 8px; min-height: 1em; }

.ex-grid { max-width: 1280px; margin: 0 auto; padding: 32px 40px 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.ex-span-2 { grid-column: span 2; }
.ex-card { padding: 24px; }
.ex-card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 14px; border-bottom: 1px solid var(--border); padding-bottom: 10px; }
.ex-card-head h2 { font-size: 1.35rem; }
.table-wrap { overflow-x: auto; }
.movers td { vertical-align: middle; }
.movers .num, .movers th.num { text-align: right; white-space: nowrap; }
.movers .glaid-text { font-size: 12px; white-space: nowrap; }
.spark { width: 96px; height: 26px; display: block; }
.spark polyline { fill: none; stroke-width: 1.6; stroke-linejoin: round; stroke-linecap: round; }
.spark.up polyline { stroke: var(--up); } .spark.down polyline { stroke: var(--down); }

.glaid-anatomy { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px 8px; margin-top: 14px; }
.seg { display: flex; flex-direction: column; border-left: 2px solid var(--gold); padding: 2px 0 2px 8px; }
.seg-code { font-size: 15px; }
.seg-label { font-size: 0.62rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.seg-value { font-size: 0.85rem; }

.bars { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.bars li { display: grid; grid-template-columns: 110px 1fr 40px; gap: 10px; align-items: center; font-size: 0.9rem; }
.bar-track { height: 6px; background: #ece7da; border-radius: 3px; overflow: hidden; }
.bar-fill { display: block; height: 100%; background: var(--gold); border-radius: 3px; }
.bar-n { text-align: right; color: var(--muted); font-size: 0.85rem; }

.lib { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; margin-bottom: 14px; }
.lib dt { font-size: 0.65rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.lib dd { font-family: 'Linden Hill', Georgia, serif; font-size: 1.5rem; line-height: 1.1; }

.leaders { list-style: none; counter-reset: lead; display: flex; flex-direction: column; gap: 10px; }
.leaders li { counter-increment: lead; display: grid; grid-template-columns: 22px 80px 1fr; gap: 6px 10px; align-items: baseline; }
.leaders li::before { content: counter(lead); font-family: 'Linden Hill', Georgia, serif; color: var(--gold); font-size: 1.2rem; }
.leaders li > :last-child { grid-column: 3; }

.industries { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px 16px; }
.ind { display: grid; grid-template-columns: 30px 1fr auto; gap: 8px; align-items: baseline; padding: 6px 0; border-bottom: 1px dotted var(--border); }
.ind-code { color: var(--gold-dark); }
.recent { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.recent li { display: flex; flex-direction: column; }

@media (max-width: 1000px) { .ex-grid { grid-template-columns: 1fr 1fr; } .ex-span-2 { grid-column: span 2; } }
@media (max-width: 680px) {
  .ex-hero { padding: 40px 16px 20px; } .ex-title { font-size: 40px; }
  .ex-stat { padding: 0 14px; } .ex-stat-n { font-size: 26px; }
  .ex-grid { grid-template-columns: 1fr; padding: 24px 16px 0; } .ex-span-2 { grid-column: auto; }
  .glaid-anatomy { grid-template-columns: repeat(2, 1fr); }
}

.ex-grid > * { min-width: 0; }
.ex-stats { row-gap: 18px; }

@media (max-width: 680px) {
  .movers thead { display: none; }
  .movers, .movers tbody, .movers td { display: block; }
  .movers tr { display: grid; grid-template-columns: 1fr auto auto; gap: 2px 12px; padding: 12px 0; border-bottom: 1px solid var(--border); align-items: center; }
  .movers td { border: 0; padding: 0; }
  .movers td:nth-child(1), .movers td:nth-child(2) { grid-column: 1 / -1; }
  .movers td:nth-child(2) { font-size: 0.9rem; margin-bottom: 4px; }
  .movers td:nth-child(3) { grid-column: 1; grid-row: 3; text-align: left; }
  .movers td:nth-child(4) { grid-column: 2; grid-row: 3; }
  .movers td:nth-child(5) { grid-column: 3; grid-row: 3; }
}

/* industry + currency controls */
.ex-controls { display: inline-flex; gap: 14px; flex-wrap: wrap; justify-content: center; margin: -16px auto 36px; padding: 10px 16px; background: var(--card); border: 1px solid var(--border); border-radius: 999px; }
.ex-control { display: inline-flex; align-items: center; gap: 8px; margin: 0; }
.ex-control span { font-family: 'Runtime', sans-serif; font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.ex-control select { width: auto; min-width: 150px; padding: 6px 10px; border-radius: 999px; font-size: 0.9rem; }
.ex-rates-note { font-size: 0.72rem; color: var(--faint); margin-top: 2px; min-height: 1em; }
.ex-span-3 { grid-column: 1 / -1; }
.ind-btn { background: none; border: 0; border-bottom: 1px dotted var(--border); font: inherit; color: inherit; text-align: left; cursor: pointer; width: 100%; }
.ind-btn:hover .ind-name { color: var(--gold-dark); }
.ind-back { margin-top: 12px; grid-column: 1 / -1; justify-self: start; padding: 6px 12px; font-size: 0.85rem; }
@media (max-width: 680px) { .ex-controls { border-radius: 12px; flex-direction: column; align-items: stretch; } .ex-control { justify-content: space-between; } .ex-control select { min-width: 0; flex: 1; } }
.trend-sub { margin: -6px 0 10px; }
.trending td { vertical-align: middle; }
.trending .num, .trending th.num { text-align: right; white-space: nowrap; }
@media (max-width: 680px) {
  .trending thead { display: none; }
  .trending, .trending tbody, .trending td { display: block; }
  .trending tr { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 2px 10px; padding: 10px 0; border-bottom: 1px solid var(--border); }
  .trending td { border: 0; padding: 0; text-align: left !important; }
  .trending td:nth-child(1) { grid-column: 1 / -1; font-weight: 600; }
}

/* signed-out preview: fades to the page color, with the sign-up panel over the fade */
.ex-fold { position: relative; }
.gated .ex-grid { max-height: 520px; overflow: hidden; }
.gated .ex-fold .ex-grid { pointer-events: none; user-select: none; }
.gated .ex-private { display: none; }
.gated .ex-fold::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 80%; background: linear-gradient(to bottom, rgba(240, 237, 228, 0) 0%, rgba(240, 237, 228, 0.82) 45%, #F0EDE4 85%); pointer-events: none; z-index: 1; }
.ex-gate { position: absolute; z-index: 2; left: 50%; bottom: 36px; transform: translateX(-50%); width: min(560px, calc(100% - 32px)); text-align: center; background: var(--card); border: 1px solid var(--border); border-radius: 10px; box-shadow: var(--shadow); padding: 28px 28px 24px; }
.ex-gate[hidden] { display: none; }
.ex-gate h2 { font-family: 'Linden Hill', Georgia, serif; font-weight: normal; font-size: 1.6rem; margin-bottom: 8px; }
.ex-gate p { color: var(--muted); margin-bottom: 18px; line-height: 1.5; }
.ex-gate-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

.gated .ex-gate { position: sticky; left: auto; bottom: 24px; transform: none; margin: -300px auto 0; }

.gated .ex-fold { height: 520px; }
