/* ============================================
   PREDIQTIFY — Brand System v3 (Modern, FTMO-clean)
   ============================================ */
:root {
  /* Surfaces — pure, clean light */
  --surface: #FFFFFF;
  --surface-2: #FFFFFF;
  --surface-3: #F7F8F7;
  --surface-sunken: #F2F4F2;

  /* Ink — neutral with the slightest green tint to harmonize w/ teal */
  --ink-1: #0A0F0C;       /* near-black */
  --ink-2: #1F2421;
  --ink-3: #5A6360;
  --ink-4: #8A938F;
  --ink-5: #BFC5C2;

  /* Borders */
  --line: #ECEEEC;
  --line-2: #DCE0DD;
  --line-strong: #0A0F0C;

  /* Brand teal — single signature color */
  --brand: #0E8478;
  --brand-2: #0AA396;
  --brand-soft: #E6F4F2;
  --brand-line: #B5DFDA;
  --brand-deep: #075F57;

  /* Trade colors */
  --yes: #1F7A4A;
  --yes-soft: #E8F3EC;
  --yes-line: #C2DECB;
  --no: #B83232;
  --no-soft: #FBEBEA;
  --no-line: #ECC4C2;

  /* Accents */
  --gold: #B8862E;
  --gold-soft: #FAF1DC;

  /* Type — clean modern grotesque */
  --font-display: 'Inter Tight', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SF Mono, monospace;

  /* Radii — more modern, slightly less rounded */
  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 14px;
  --r-xl: 20px;

  /* Shadows */
  --shadow-1: 0 1px 0 rgba(10,15,12,0.04), 0 1px 2px rgba(10,15,12,0.04);
  --shadow-2: 0 4px 12px rgba(10,15,12,0.05);
  --shadow-3: 0 16px 40px rgba(10,15,12,0.08);
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: var(--font-body);
  background: var(--surface);
  color: var(--ink-1);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: 'cv11', 'ss01', 'ss03';
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

.mono  { font-family: var(--font-mono); }
.brand { color: var(--brand); }

/* ============== UTILITIES ============== */
.container { max-width: 1280px; margin: 0 auto; padding: 0 32px; }
.container-narrow { max-width: 980px; margin: 0 auto; padding: 0 32px; }

/* ============== NAV ============== */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px; max-width: 1400px; margin: 0 auto; padding: 0 32px;
}
.logo {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-display);
  font-size: 19px; letter-spacing: -0.025em;
  color: var(--ink-1); font-weight: 700;
}
.logo-mark {
  display: inline-flex;
}
.nav-links { display: flex; gap: 2px; }
.nav-links a {
  padding: 8px 14px; border-radius: 8px;
  color: var(--ink-3); font-size: 14px; font-weight: 500;
  transition: all 0.15s;
  letter-spacing: -0.005em;
}
.nav-links a:hover { color: var(--ink-1); background: var(--surface-3); }
.nav-links a.active { color: var(--brand); background: var(--brand-soft); }

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

/* ============== BUTTONS ============== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 18px;
  border-radius: 8px;
  font-size: 14px; font-weight: 600;
  letter-spacing: -0.005em;
  border: 1px solid transparent;
  transition: all 0.15s;
  white-space: nowrap;
  font-family: inherit;
}
.btn-pri  { background: var(--ink-1); color: #fff; }
.btn-pri:hover { background: var(--ink-2); transform: translateY(-1px); }
.btn-brand { background: var(--brand); color: #fff; box-shadow: 0 1px 0 rgba(0,0,0,0.1), 0 0 0 1px var(--brand-deep) inset; }
.btn-brand:hover { background: var(--brand-2); }
.btn-ghost { background: transparent; color: var(--ink-2); }
.btn-ghost:hover { background: var(--surface-3); }
.btn-sec  { background: var(--surface-2); color: var(--ink-1); border-color: var(--line-2); }
.btn-sec:hover { border-color: var(--ink-1); }
.btn-sm { padding: 7px 14px; font-size: 13px; border-radius: 6px; }
.btn-lg { padding: 14px 24px; font-size: 15px; border-radius: 10px; }
.btn-full { width: 100%; }

.btn-yes { background: var(--surface-2); color: var(--yes); border: 1px solid var(--yes-line); }
.btn-yes:hover { background: var(--yes-soft); }
.btn-no  { background: var(--surface-2); color: var(--no);  border: 1px solid var(--no-line); }
.btn-no:hover { background: var(--no-soft); }

/* ============== BADGES ============== */
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 11px; font-weight: 600; letter-spacing: 0.01em;
  border: 1px solid;
}
.badge-brand { background: var(--brand-soft); color: var(--brand); border-color: var(--brand-line); }
.badge-yes   { background: var(--yes-soft);   color: var(--yes);   border-color: var(--yes-line); }
.badge-no    { background: var(--no-soft);    color: var(--no);    border-color: var(--no-line); }
.badge-gold  { background: var(--gold-soft);  color: var(--gold);  border-color: #ECD491; }
.badge-gray  { background: var(--surface-3);  color: var(--ink-3); border-color: var(--line); }
.badge-live  { background: #fff;              color: var(--no);    border-color: var(--no-line); }
.badge-live::before { content:""; width: 6px; height: 6px; border-radius:50%; background: var(--no); animation: pulse 1.5s infinite; }
@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:0.4} }

/* ============== CARDS ============== */
.card {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 20px;
  transition: all 0.15s;
}
.card-hover:hover { border-color: var(--line-2); box-shadow: var(--shadow-2); }

/* ============== INPUTS ============== */
.input {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--line-2);
  border-radius: var(--r-md);
  background: var(--surface-2);
  font-size: 14px; font-family: inherit;
  color: var(--ink-1); outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
  letter-spacing: -0.005em;
}
.input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.label { display: block; font-size: 12px; color: var(--ink-3); margin-bottom: 6px; font-weight: 500; }

/* ============== SECTION HEADINGS ============== */
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-mono); font-size: 11px;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--brand);
  font-weight: 500;
}
.eyebrow::before { content:""; width: 16px; height: 1px; background: var(--brand); }

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

/* DISPLAY HEADINGS — Inter Tight, modern, weighty */
h1, h2, h3, h4, h5 { font-family: var(--font-display); }

h1.display {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(44px, 6.5vw, 84px); line-height: 1.02;
  letter-spacing: -0.035em; margin: 0 0 8px;
  color: var(--ink-1);
}
h1.display em { font-style: normal; color: var(--brand); font-weight: 700; }
h1.display b { font-weight: 700; color: var(--brand); }

h2.display { font-family: var(--font-display); font-weight: 700; font-size: clamp(32px, 4.2vw, 52px); line-height: 1.05; letter-spacing: -0.03em; margin: 0; }
h2.display em { font-style: normal; color: var(--brand); }

h3.display { font-family: var(--font-display); font-weight: 600; font-size: 24px; line-height: 1.2; letter-spacing: -0.02em; margin: 0; }

/* legacy serif classes — now mapped to clean display style for backwards compat */
.serif, h2.serif, h3.serif {
  font-family: var(--font-display);
  letter-spacing: -0.025em;
  font-weight: 700;
}
h2.serif { font-size: clamp(32px, 4.2vw, 52px); line-height: 1.05; margin: 0; }
h2.serif em { font-style: normal; color: var(--brand); font-weight: 700; }
h3.serif { font-size: 22px; line-height: 1.2; font-weight: 600; margin: 0; }
h3.serif em { font-style: normal; color: var(--brand); }

/* Italic accents in pages — neutralize to weight + color */
.section-h2 em, .page-head h1 em, .hero h1 em, .feature h3 em {
  font-style: normal !important;
  color: var(--brand);
}

/* ============== FOOTER ============== */
.footer {
  background: var(--surface-3);
  border-top: 1px solid var(--line);
  padding: 64px 0 32px;
  margin-top: 96px;
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  gap: 48px;
  max-width: 1280px; margin: 0 auto; padding: 0 32px;
}
.footer h5 { font-size: 12px; color: var(--ink-3); margin: 0 0 16px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; }
.footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.footer li a { font-size: 14px; color: var(--ink-2); }
.footer li a:hover { color: var(--brand); }
.footer-bottom {
  max-width: 1280px; margin: 32px auto 0; padding: 24px 32px 0;
  border-top: 1px solid var(--line);
  display: flex; justify-content: space-between;
  font-size: 11px; color: var(--ink-4);
  font-family: var(--font-mono);
  letter-spacing: 0.05em;
}
.footer-blurb { font-size: 14px; color: var(--ink-3); max-width: 32ch; line-height: 1.6; margin: 14px 0 0; }

/* ============== MARKET CARDS ============== */
.market-card {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 18px;
  display: flex; flex-direction: column; gap: 12px;
  transition: all 0.15s;
  cursor: pointer;
}
.market-card:hover { border-color: var(--line-2); box-shadow: var(--shadow-2); transform: translateY(-1px); }
.market-card .mc-top { display: flex; justify-content: space-between; align-items: flex-start; }
.market-card h4 { font-size: 15px; font-weight: 600; margin: 0; line-height: 1.35; min-height: 40px; color: var(--ink-1); letter-spacing: -0.01em; }
.market-card .mc-prices { display: flex; justify-content: space-between; align-items: flex-end; }
.market-card .mc-prices .px-yes { font-family: var(--font-display); font-size: 28px; font-weight: 700; color: var(--yes); letter-spacing: -0.03em; line-height: 1; }
.market-card .mc-prices .px-yes small { font-size: 14px; color: var(--ink-4); font-weight: 500; }
.market-card .mc-prices .vol { font-family: var(--font-mono); font-size: 11px; color: var(--ink-4); }
.market-card .mc-actions { display: flex; gap: 6px; }

/* ============== STAT ROW ============== */
.stat-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 0; }
.stat-row > div { padding: 24px 28px; border-right: 1px solid var(--line); }
.stat-row > div:last-child { border-right: none; }
.stat-row b { display: block; font-family: var(--font-display); font-weight: 700; font-size: 32px; letter-spacing: -0.03em; line-height: 1; }
.stat-row span { font-size: 12px; color: var(--ink-3); margin-top: 6px; display: block; letter-spacing: 0.02em; }

/* ============== TOAST ============== */
.toast-container { position: fixed; bottom: 24px; right: 24px; z-index: 999; display: flex; flex-direction: column; gap: 10px; }
.toast { background: var(--ink-1); color: #fff; padding: 12px 18px; border-radius: var(--r-md); box-shadow: var(--shadow-3); font-size: 13px; animation: toast-in 0.3s ease; }
@keyframes toast-in { from { transform: translateX(40px); opacity: 0; } to { transform: translateX(0); opacity: 1; } }

/* ============== RESPONSIVE ============== */
@media (max-width: 900px) {
  .nav-links { display: none; }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .stat-row > div { border-right: none; border-bottom: 1px solid var(--line); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
