* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg: #080c1a;
  --bg-2: #0f1528;
  --card: #121a33;
  --text: #e8ecf7;
  --muted: #9fb0d0;
  --accent: #6ee0c5;
  --accent-2: #5c8df6;
  --danger: #ff8b7b;
  --border: #1f2946;
  --shadow: 0 20px 80px rgba(0, 0, 0, 0.35);
  --radius: 14px;
  --transition: 180ms ease;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: radial-gradient(circle at 20% 20%, rgba(108, 148, 255, 0.1), transparent 35%), radial-gradient(circle at 80% 0%, rgba(110, 224, 197, 0.12), transparent 30%), var(--bg);
  color: var(--text);
  line-height: 1.6;
}

.page {
  max-width: 1200px;
  margin: 0 auto;
}

.market-shell {
  padding: 32px 24px 56px;
}

.market-top {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  padding: 12px 0 18px;
  border-bottom: 1px solid var(--border);
}

.market-identity {
  display: flex;
  gap: 12px;
  align-items: center;
}

.flag-badge {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, #f5515f, #f9d423);
  display: grid;
  place-items: center;
  font-weight: 800;
  color: #0a0f1f;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-top: 6px;
  font-size: 14px;
}

.dot-sep {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--border);
}

.top-actions {
  display: flex;
  gap: 10px;
}

.market-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(280px, 0.9fr);
  gap: 16px;
  margin-top: 20px;
}

.market-left {
  display: grid;
  gap: 14px;
}

.outcome-list {
  display: grid;
  gap: 12px;
}

.outcome-row {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  box-shadow: var(--shadow);
}

.outcome-row h3 {
  font-size: 18px;
}

.outcome-price {
  display: flex;
  align-items: center;
  gap: 12px;
}

.pct {
  min-width: 60px;
  text-align: right;
  font-weight: 700;
  padding: 6px 10px;
  border-radius: 10px;
}

.pct.up {
  background: rgba(110, 224, 197, 0.12);
  color: #34d399; /* green */
}

.pct.down {
  background: rgba(255, 99, 99, 0.12);
  color: #ef4444; /* red */
}

.cta-pair {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

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

.compact {
  padding: 8px 12px;
  font-size: 14px;
  transition: all var(--transition);
}

.compact:hover {
  transform: scale(1.05);
}

.card-line {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 14px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
  box-shadow: var(--shadow);
}

.collapse {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 14px;
  box-shadow: var(--shadow);
}

.collapse summary {
  cursor: pointer;
  font-weight: 700;
  transition: all var(--transition);
  padding-left: 0;
}

.collapse summary:hover {
  color: var(--accent);
  padding-left: 5px;
}

.collapse[open] {
  border-color: rgba(92, 141, 246, 0.4);
}

.collapse p, .collapse ul {
  margin-top: 10px;
}

.trade-card {
  position: sticky;
  top: 76px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 12px;
  height: fit-content;
}

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

.side-select {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.side-btn {
  border-radius: 12px;
  border: 1px solid var(--border);
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.02);
  color: var(--text);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  transition: all var(--transition);
  cursor: pointer;
}

.side-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.side-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.side-btn.active {
  border-color: rgba(92, 141, 246, 0.5);
  box-shadow: var(--shadow);
}

.side-btn.yes {
  border-color: rgba(52, 211, 153, 0.4);
  background: rgba(52, 211, 153, 0.08);
  color: #34d399;
}

.side-btn.yes:hover:not(:disabled) {
  border-color: rgba(52, 211, 153, 0.6);
  background: rgba(52, 211, 153, 0.15);
  box-shadow: 0 5px 20px rgba(52, 211, 153, 0.3);
}

.side-btn.no {
  border-color: rgba(239, 68, 68, 0.4);
  background: rgba(239, 68, 68, 0.08);
  color: #ef4444;
}

.side-btn.no:hover:not(:disabled) {
  border-color: rgba(239, 68, 68, 0.6);
  background: rgba(239, 68, 68, 0.15);
  box-shadow: 0 5px 20px rgba(239, 68, 68, 0.3);
}

.side-btn.yes.active {
  border-color: #34d399;
  background: rgba(52, 211, 153, 0.22);
  transform: scale(1.02);
}

.side-btn.no.active {
  border-color: #ef4444;
  background: rgba(239, 68, 68, 0.22);
  transform: scale(1.02);
}

.toast {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  padding: 12px 16px;
  background: rgba(0, 0, 0, 0.8);
  color: #fff;
  border-radius: 12px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms ease, transform 200ms ease;
  z-index: 999;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(-6px);
}

.input-label {
  font-weight: 600;
}

.input-row {
  display: grid;
  gap: 8px;
}

.input-row input {
  padding: 12px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text);
}

.chip-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.chip {
  padding: 8px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all var(--transition);
}

.chip:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
}

.chip.ghost {
  background: transparent;
}

.chip.ghost:hover {
  background: rgba(255, 255, 255, 0.06);
}

.small {
  font-size: 13px;
}

.trade-eligibility {
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
  align-items: center;
}


body.light {
  --bg: #f6f8fc;
  --bg-2: #eef2fb;
  --card: #ffffff;
  --text: #0e1528;
  --muted: #4d5d7a;
  --border: #d8e0f0;
  --shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
  background: var(--bg);
  color: var(--text);
}

a {
  color: var(--text);
  text-decoration: none;
  transition: all var(--transition);
}

a:hover {
  opacity: 0.8;
}

button {
  font: inherit;
  border: none;
  cursor: pointer;
  position: relative;
  transition: all var(--transition);
}

button:active:not(:disabled) {
  transform: scale(0.98);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 32px;
  background: rgba(8, 12, 26, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.context-banner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 8px;
  align-items: center;
  padding: 20px 24px;
  max-width: 1200px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid var(--border);
}

.token-hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
  align-items: center;
  padding: 20px 24px 20px;
  max-width: 1200px;
  margin: 0 auto;
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
}

.token-left {
  display: flex;
  gap: 12px;
  align-items: center;
}

.token-avatar {
  width: 88px;
  height: 88px;
  border-radius: 18px;
  overflow: hidden;
}

.token-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ca-row {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-top: 6px;
  flex-wrap: wrap;
}

.mono {
  font-family: "SFMono-Regular", Consolas, monospace;
  background: rgba(255, 255, 255, 0.06);
  padding: 6px 10px;
  border-radius: 8px;
  border: 1px solid var(--border);
}

.token-socials {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

.crumbs {
  color: var(--muted);
  font-size: 13px;
}

.banner-title {
  font-weight: 700;
}

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

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

.logo {
  width: 64px;
  height: 64px;
  border-radius: 10px;
  overflow: hidden;
}

.logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.brand-name {
  font-weight: 700;
  letter-spacing: 0.01em;
}

.brand-tag {
  font-size: 12px;
  color: var(--muted);
}

.nav-links {
  display: flex;
  gap: 16px;
  align-items: center;
}

.nav-links a {
  padding: 8px 10px;
  color: var(--muted);
  border-radius: 10px;
  transition: all var(--transition);
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: all var(--transition);
  transform: translateX(-50%);
}

.nav-links a:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  transform: translateY(-1px);
}

.nav-links a:hover::after {
  width: 80%;
}

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

.primary-btn, .secondary-btn, .ghost-btn {
  border-radius: 12px;
  padding: 10px 16px;
  font-weight: 600;
  transition: var(--transition);
}

.primary-btn {
  background: linear-gradient(135deg, var(--accent-2), var(--accent));
  color: #0a0f1f;
  position: relative;
  overflow: hidden;
}

.primary-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  opacity: 0;
  transition: opacity var(--transition);
}

.primary-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(110, 224, 197, 0.3);
}

.primary-btn:hover::before {
  opacity: 0.2;
}

.primary-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.secondary-btn {
  background: rgba(92, 141, 246, 0.16);
  color: var(--text);
  border: 1px solid rgba(92, 141, 246, 0.4);
}

.secondary-btn:hover {
  background: rgba(92, 141, 246, 0.26);
  border-color: rgba(92, 141, 246, 0.6);
  transform: translateY(-1px);
  box-shadow: 0 5px 20px rgba(92, 141, 246, 0.2);
}

.secondary-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.ghost-btn {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  border: 1px solid var(--border);
}

.ghost-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
}

.ghost-btn.active {
  border-color: var(--accent);
  color: var(--accent);
}

.ghost-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.hero {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 28px;
  padding: 56px 32px 24px;
  align-items: center;
}

.hero-text h1 {
  font-size: 38px;
  line-height: 1.2;
  margin: 12px 0;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: rgba(92, 141, 246, 0.12);
  border: 1px solid rgba(92, 141, 246, 0.25);
  border-radius: 999px;
  color: var(--accent-2);
  font-weight: 600;
  font-size: 13px;
  transition: all var(--transition);
}

.pill:hover {
  background: rgba(92, 141, 246, 0.18);
  border-color: rgba(92, 141, 246, 0.35);
  transform: scale(1.02);
}

.lede {
  color: var(--muted);
  max-width: 680px;
}

.hero-cta {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 16px;
}

.hero-cta .meta {
  display: flex;
  gap: 16px;
  color: var(--muted);
  font-size: 14px;
}

.hero-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.card-header, .price-row, .stats {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.label {
  color: var(--muted);
  font-size: 13px;
}

.status {
  padding: 6px 10px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 12px;
  transition: all var(--transition);
}

.status.live {
  background: rgba(110, 224, 197, 0.15);
  color: var(--accent);
}

.status.locked {
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
}

.status.ghost {
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
  border: 1px solid var(--border);
}

.price-row {
  gap: 12px;
}

.price-box {
  flex: 1;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
}

.price-box.yes {
  border-color: rgba(110, 224, 197, 0.4);
}

.price-box.no {
  border-color: rgba(92, 141, 246, 0.4);
}

.chart {
  height: 120px;
  background: linear-gradient(180deg, rgba(92, 141, 246, 0.2), rgba(8, 12, 26, 0.05));
  border-radius: 12px;
  border: 1px dashed var(--border);
  position: relative;
  overflow: hidden;
}

.chart .spark {
  position: absolute;
  bottom: 0;
  width: 8px;
  background: linear-gradient(180deg, var(--accent-2), transparent);
  border-radius: 6px 6px 0 0;
}

.stats {
  gap: 16px;
}

.stats strong {
  display: block;
  font-size: 18px;
}

.full-btn {
  width: 100%;
}

.section {
  padding: 48px 32px;
}

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

.section h2 {
  font-size: 28px;
  margin: 8px 0;
}

.muted {
  color: var(--muted);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}

.market-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.market-card.faded {
  opacity: 0.6;
}

.market-header {
  display: flex;
  justify-content: space-between;
}

.market-prices {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.trend {
  padding: 6px 10px;
  border-radius: 10px;
  font-weight: 700;
}

.trend.up {
  background: rgba(110, 224, 197, 0.12);
  color: var(--accent);
}

.market-meta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 14px;
}

.filters {
  display: flex;
  gap: 10px;
}

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.step {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  position: relative;
  overflow: hidden;
}

.step-num {
  position: absolute;
  top: 12px;
  right: 12px;
  font-weight: 700;
  color: var(--accent);
  opacity: 0.7;
}

.split {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 20px;
  align-items: start;
}

.list {
  list-style: none;
  display: grid;
  gap: 10px;
  margin: 12px 0;
}

.list li {
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
}

.tags {
  display: flex;
  gap: 10px;
}

.tag {
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(92, 141, 246, 0.14);
  color: var(--accent-2);
  border: 1px solid rgba(92, 141, 246, 0.25);
}

.oracle-card, .card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow);
}

.timeline {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  float: left;
  margin-right: 14px;
}

.dot {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--border);
  border: 2px solid var(--border);
}

.dot.done {
  background: var(--accent);
}

.line {
  width: 2px;
  height: 30px;
  background: var(--border);
}

.line.done {
  background: var(--accent);
}

.timeline-content {
  display: grid;
  gap: 14px;
}

.eligibility {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin: 12px 0;
}

.vote-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.thin {
  padding: 10px 14px;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.bar {
  width: 100%;
  height: 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
  border: 1px solid var(--border);
  margin: 12px 0 8px;
}

.bar-fill {
  height: 100%;
  width: 60%;
  background: linear-gradient(90deg, var(--accent-2), var(--accent));
}

.bar-labels {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 14px;
}

.claim-card {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  align-items: center;
  margin: 12px 0;
}

.accordion details {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
  box-shadow: var(--shadow);
}

.accordion summary {
  cursor: pointer;
  font-weight: 600;
}

.accordion p {
  margin-top: 10px;
  color: var(--muted);
}

.footer {
  border-top: 1px solid var(--border);
  padding: 24px 32px 32px;
  background: #070a16;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  align-items: center;
}

.footer-links {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.footer-links a {
  color: var(--muted);
  padding: 5px 10px;
  border-radius: 8px;
  transition: all var(--transition);
}

.footer-links a:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
  transform: translateY(-1px);
  opacity: 1;
}

.footer-meta {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 14px;
}

@media (max-width: 900px) {
  .topbar {
    flex-wrap: wrap;
    gap: 8px;
    padding: 12px 16px;
  }
  .nav-links {
    display: none;
  }
  .actions {
    width: 100%;
    justify-content: center;
  }
  .context-banner,
  .token-hero,
  .market-shell,
  .footer {
    padding: 16px;
  }
  .page {
    max-width: 100%;
    padding: 0 8px;
  }
  .market-grid {
    grid-template-columns: 1fr;
  }
  .trade-card {
    position: static;
  }
  .logo {
    width: 72px;
    height: 72px;
  }
  .token-avatar {
    width: 80px;
    height: 80px;
  }
}

@media (max-width: 600px) {
  .market-top {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  h1 {
    font-size: 26px;
    line-height: 1.2;
  }
  .banner-title {
    font-size: 15px;
  }
  .meta-row {
    gap: 6px;
  }
  .side-select {
    grid-template-columns: 1fr;
  }
  .eligibility {
    grid-template-columns: 1fr;
  }
  .logo {
    width: 64px;
    height: 64px;
  }
  .token-avatar {
    width: 72px;
    height: 72px;
  }
  .actions {
    flex-direction: column;
  }
}

