/* ============================================
   BrokerBrawl — Clean Editorial v3
   ============================================ */

:root {
  --bg: #0f1114;
  --bg-2: #15171c;
  --bg-3: #1a1d23;
  --bg-card: #181b21;
  --border: rgba(255,255,255,0.06);
  --border-h: rgba(255,255,255,0.12);
  --text: #b8bac2;
  --text-m: #72747e;
  --white: #e8e9ed;
  --heading: #d5d7de;
  --accent: #4a8eff;
  --accent-soft: rgba(74,142,255,.08);
  --green: #3ecf8e;
  --green-soft: rgba(62,207,142,.08);
  --amber: #f0b429;
  --red-warn: #ef4444;
  --r: 8px;
  --r-lg: 12px;
  --tr: .2s ease;
}

*,*::before,*::after { margin:0; padding:0; box-sizing:border-box }
html { scroll-behavior:smooth; scroll-padding-top:72px }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.72;
  -webkit-font-smoothing: antialiased;
  font-size: 15px;
}

.container { max-width: 1080px; margin: 0 auto; padding: 0 20px }
a { color: var(--accent); text-decoration: none; transition: color var(--tr) }
a:hover { color: #6da8ff }
img { max-width: 100%; display: block }

/* ===== Risk Bar ===== */
.risk-bar {
  background: #1a1315;
  border-bottom: 1px solid rgba(239,68,68,.1);
  padding: 7px 0;
  text-align: center;
}
.risk-bar p { font-size: .73rem; color: #8a7070; line-height: 1.5 }
.risk-bar strong { color: #c87070 }
.risk-bar a { color: #c87070; text-decoration: underline }

/* ===== Navbar ===== */
.navbar {
  position: sticky; top: 0; z-index: 1000;
  background: rgba(15,17,20,.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.navbar.scrolled { box-shadow: 0 1px 12px rgba(0,0,0,.5) }
.nav-flex { display: flex; align-items: center; justify-content: space-between; height: 56px }

.logo { display: flex; align-items: center; gap: 7px; color: var(--white); text-decoration: none }
.logo-icon { font-size: 1.15rem }
.logo-text {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.15rem; font-weight: 700; letter-spacing: -.3px;
}
.logo-accent { color: var(--accent) }

.nav-links { display: flex; list-style: none; gap: 24px }
.nav-links a {
  color: var(--text-m); font-size: .84rem; font-weight: 500;
  text-decoration: none; transition: color var(--tr);
}
.nav-links a:hover, .nav-links a.active { color: var(--white) }
.nav-links a.active::after {
  content: ''; position: absolute; bottom: -3px; left: 0; right: 0;
  height: 1.5px; background: var(--accent); border-radius: 1px;
}
.nav-links a { position: relative }

.nav-burger { display: none; flex-direction: column; gap: 4px; background: none; border: none; cursor: pointer; padding: 4px }
.nav-burger span { width: 20px; height: 1.5px; background: var(--white); border-radius: 1px; transition: var(--tr) }

/* ===== Buttons ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 9px 22px; border-radius: 6px; font-size: .86rem; font-weight: 600;
  border: none; cursor: pointer; transition: all var(--tr);
  background: var(--accent); color: #fff; white-space: nowrap;
}
.btn:hover { background: #5d9aff; color: #fff; transform: translateY(-1px) }
.btn-sm { padding: 6px 16px; font-size: .8rem }
.btn-outline { background: transparent; border: 1.5px solid var(--border-h); color: var(--white) }
.btn-outline:hover { border-color: var(--accent); color: var(--accent) }
.btn-ghost { background: transparent; color: var(--text-m); padding: 9px 12px }
.btn-ghost:hover { color: var(--white) }

/* ===== Hero ===== */
.hero {
  position: relative; padding: 64px 0 48px;
  text-align: center; overflow: hidden;
}
.hero-glow {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 50% 20%, rgba(74,142,255,.05) 0%, transparent 60%);
  pointer-events: none;
}
.hero-inner { position: relative; z-index: 1 }
.hero-label {
  font-size: .78rem; color: var(--text-m);
  margin-bottom: 14px; letter-spacing: .2px;
}
.hero h1 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.8rem, 4.5vw, 2.8rem);
  font-weight: 700; line-height: 1.18;
  margin-bottom: 14px; color: var(--heading);
}
.grad-text { color: var(--accent) }
.hero-desc { max-width: 580px; margin: 0 auto 24px; font-size: .96rem; color: var(--text-m) }
.hero-tags { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap }
.hero-tag {
  padding: 6px 16px; border-radius: 5px; font-size: .82rem; font-weight: 500;
  background: var(--bg-3); border: 1px solid var(--border); color: var(--text-m);
  transition: all var(--tr);
}
.hero-tag:hover { border-color: var(--accent); color: var(--white) }

/* ===== Section Titles ===== */
.sec-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.3rem, 3vw, 1.7rem);
  font-weight: 700; color: var(--heading);
  text-align: center; margin-bottom: 6px;
}
.sec-desc {
  text-align: center; color: var(--text-m);
  max-width: 520px; margin: 0 auto 36px; font-size: .92rem;
}

/* ===== Article Cards ===== */
.articles { padding: 56px 0 }
.card-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 20px }

.article-card {
  display: flex; flex-direction: column;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--r-lg); padding: 24px 22px;
  text-decoration: none; color: inherit; transition: all var(--tr);
}
.article-card:hover {
  border-color: var(--border-h);
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(0,0,0,.3);
  color: inherit;
}

.card-vs { display: flex; align-items: center; gap: 10px; margin-bottom: 14px }
.card-vs img { height: 28px; width: auto; border-radius: 4px }
.vs-badge {
  font-family: 'Space Grotesk', sans-serif;
  font-size: .65rem; font-weight: 700;
  color: var(--text-m); letter-spacing: 1px;
}
.vs-name {
  padding: 4px 12px; border-radius: 4px;
  font-size: .78rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .4px;
}
.vs-xm { background: rgba(194,23,29,.12); color: #e8706f; border: 1px solid rgba(194,23,29,.18) }
.vs-other { background: rgba(74,142,255,.08); color: var(--accent); border: 1px solid rgba(74,142,255,.12) }

.article-card h3 {
  font-size: 1.02rem; font-weight: 700;
  color: var(--heading); margin-bottom: 8px; line-height: 1.4;
}
.article-card p { color: var(--text-m); font-size: .86rem; line-height: 1.6; flex: 1 }

.card-meta {
  display: flex; gap: 14px; margin-top: 14px; padding-top: 12px;
  border-top: 1px solid var(--border); font-size: .74rem; color: var(--text-m);
}
.meta-author { font-weight: 600; color: var(--text) }

/* ===== About Section ===== */
.about-section {
  padding: 56px 0;
  background: var(--bg-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.about-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; align-items: start }
.about-text p { color: var(--text-m); font-size: .9rem; margin-bottom: 12px }

.author-card {
  background: var(--bg-3); border: 1px solid var(--border);
  border-radius: var(--r-lg); padding: 24px; text-align: center;
}
.author-avatar {
  width: 56px; height: 56px; border-radius: 50%; margin: 0 auto 12px;
  background: var(--accent-soft); border: 2px solid rgba(74,142,255,.2);
  display: flex; align-items: center; justify-content: center;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1rem; font-weight: 700; color: var(--accent);
}
.author-card h3 { font-size: 1rem; font-weight: 700; color: var(--heading); margin-bottom: 2px }
.author-role { font-size: .78rem; color: var(--accent); font-weight: 500; margin-bottom: 10px }
.author-bio { font-size: .82rem; color: var(--text-m); line-height: 1.55 }

/* ===== Footer ===== */
.footer { padding: 40px 0 0; border-top: 1px solid var(--border) }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 28px; padding-bottom: 28px }
.footer-brand p { margin-top: 8px; font-size: .8rem; color: var(--text-m) }
.footer-col h4 {
  font-size: .75rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: .5px; color: var(--text); margin-bottom: 10px;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 6px }
.footer-col a { color: var(--text-m); font-size: .82rem }
.footer-col a:hover { color: var(--white) }
.footer-bottom { padding: 14px 0; border-top: 1px solid var(--border); text-align: center }
.footer-bottom p { font-size: .74rem; color: var(--text-m) }

/* ===== Cookie Banner ===== */
.cookie-banner {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 9999;
  background: var(--bg-3); border-top: 1px solid var(--border);
  padding: 12px 20px; display: flex; align-items: center;
  justify-content: space-between; gap: 16px;
  transform: translateY(100%); transition: transform .4s ease;
}
.cookie-banner.show { transform: translateY(0) }
.cookie-banner p { font-size: .8rem; color: var(--text-m); flex: 1 }
.cookie-banner a { color: var(--accent); text-decoration: underline }

/* ===== Article Page Layout ===== */
.article-hero {
  padding: 72px 0 36px; text-align: center;
  position: relative; overflow: hidden;
}
.article-hero .hero-glow {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 50% 20%, rgba(74,142,255,.04) 0%, transparent 55%);
  pointer-events: none;
}
.article-hero-inner { position: relative; z-index: 1 }
.article-hero .card-vs { justify-content: center; margin-bottom: 18px }
.article-hero .card-vs img { height: 32px }
.article-hero h1 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.4rem, 3.5vw, 2rem);
  font-weight: 700; color: var(--heading); line-height: 1.25;
  margin-bottom: 10px; max-width: 680px; margin-left: auto; margin-right: auto;
}
.article-hero .hero-desc { margin-bottom: 0 }
.article-meta {
  display: flex; gap: 18px; justify-content: center;
  margin-top: 14px; font-size: .78rem; color: var(--text-m);
}
.article-meta strong { color: var(--text); font-weight: 600 }

.article-body { padding: 40px 0 56px }
.article-content { max-width: 740px; margin: 0 auto }

.article-content h2 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.3rem; font-weight: 700; color: var(--heading);
  margin: 40px 0 14px; padding-top: 20px;
  border-top: 1px solid var(--border);
}
.article-content h2:first-child { border-top: none; margin-top: 0; padding-top: 0 }
.article-content h3 { font-size: 1.02rem; font-weight: 700; color: var(--heading); margin: 24px 0 8px }
.article-content p { color: var(--text); font-size: .92rem; margin-bottom: 14px }
.article-content ul, .article-content ol { margin: 0 0 14px 18px; color: var(--text) }
.article-content li { font-size: .9rem; margin-bottom: 5px }
.article-content strong { color: var(--white) }
.article-content blockquote {
  margin: 20px 0; padding: 14px 18px;
  background: var(--accent-soft); border-left: 2px solid var(--accent);
  border-radius: 0 var(--r) var(--r) 0;
  font-size: .9rem; color: var(--text-m);
}

/* Comparison Table */
.cmp-table { width: 100%; border-collapse: collapse; margin: 20px 0 28px; font-size: .86rem }
.cmp-table th, .cmp-table td { padding: 10px 14px; text-align: left; border-bottom: 1px solid var(--border) }
.cmp-table th {
  font-size: .72rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: .4px; color: var(--text-m); background: var(--bg-3);
}
.cmp-table th:first-child { border-radius: var(--r) 0 0 0 }
.cmp-table th:last-child { border-radius: 0 var(--r) 0 0 }
.cmp-table td { color: var(--text) }
.cmp-table tr:hover td { background: rgba(255,255,255,.015) }
.col-xm { color: #e8706f; font-weight: 600 }
.col-other { color: var(--accent); font-weight: 600 }

/* Verdict Box */
.verdict-box {
  margin: 36px 0 0; padding: 24px;
  background: var(--green-soft);
  border: 1px solid rgba(62,207,142,.12);
  border-radius: var(--r-lg);
}
.verdict-box h2 { border: none; margin-top: 0; padding-top: 0; color: var(--green) }
.verdict-box p { color: var(--text-m) }

/* Score bars */
.score-row { display: flex; align-items: center; gap: 10px; margin-bottom: 8px }
.score-lbl { width: 120px; font-size: .8rem; color: var(--text-m); flex-shrink: 0 }
.score-track {
  flex: 1; height: 5px;
  background: rgba(255,255,255,.04);
  border-radius: 3px; overflow: hidden; position: relative;
}
.score-fill-xm, .score-fill-other {
  position: absolute; top: 0; left: 0; height: 100%;
  border-radius: 3px; transition: width 1s ease;
}
.score-fill-xm { background: #e8706f }
.score-fill-other { background: var(--accent) }
.score-val { width: 32px; font-size: .8rem; font-weight: 700; text-align: right }
.score-val-xm { color: #e8706f }
.score-val-other { color: var(--accent) }
.score-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin: 18px 0 28px }
.score-col h4 {
  font-size: .78rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: .4px; margin-bottom: 12px; display: flex; align-items: center; gap: 8px;
}
.score-col h4 img { height: 20px; border-radius: 3px }
.score-col:first-child h4 { color: #e8706f }
.score-col:last-child h4 { color: var(--accent) }

/* Back link */
.back-link {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: .84rem; font-weight: 500; color: var(--text-m);
  margin-bottom: 20px;
}
.back-link:hover { color: var(--white) }

/* Legal pages */
.legal-page { padding: 92px 0 56px }
.legal-page h1 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.8rem; font-weight: 700; color: var(--heading); margin-bottom: 24px;
}
.legal-page h2 { font-size: 1.1rem; font-weight: 700; color: var(--heading); margin: 24px 0 8px }
.legal-page p, .legal-page li { color: var(--text-m); font-size: .88rem; margin-bottom: 8px }
.legal-page ul { padding-left: 18px; margin-bottom: 12px }
.legal-page a { color: var(--accent) }

/* ===== Animations ===== */
.fade-up { opacity: 0; transform: translateY(16px); transition: opacity .45s ease, transform .45s ease }
.fade-up.visible { opacity: 1; transform: translateY(0) }

/* ===== Responsive ===== */
@media (max-width: 900px) {
  .card-grid { grid-template-columns: 1fr }
  .about-grid { grid-template-columns: 1fr }
  .footer-grid { grid-template-columns: 1fr }
  .score-pair { grid-template-columns: 1fr }
}

@media (max-width: 768px) {
  .nav-links {
    display: none; position: absolute; top: 56px; left: 0; right: 0;
    background: var(--bg); flex-direction: column; padding: 16px 20px; gap: 12px;
    border-bottom: 1px solid var(--border);
  }
  .nav-links.open { display: flex }
  .nav-burger { display: flex }
  .hero { padding: 44px 0 32px }
  .hero h1 { font-size: 1.6rem }
  .article-hero h1 { font-size: 1.3rem }
  .article-content h2 { font-size: 1.15rem }
  .cmp-table { font-size: .78rem }
  .cmp-table th, .cmp-table td { padding: 8px 9px }
  .article-meta { flex-wrap: wrap; gap: 8px }
  .cookie-banner { flex-direction: column; text-align: center; gap: 8px }
}

@media (max-width: 480px) {
  .hero-tags { flex-direction: column; align-items: center }
  .card-vs { flex-wrap: wrap }
}
