/* =====================================================
   SportsbookReviews.co.za – Site Stylesheet
   ===================================================== */

/* ---- 1. CSS Custom Properties ---- */
:root {
  --bg-primary:       #080d18;
  --bg-secondary:     #0f1625;
  --bg-card:          #121c2e;
  --bg-card-hover:    #172035;
  --border:           #1e2d47;
  --border-light:     #243552;
  --accent-gold:      #f6a623;
  --accent-green:     #22c55e;
  --accent-red:       #ef4444;
  --accent-blue:      #3b82f6;
  --text-primary:     #e8edf5;
  --text-muted:       #7a8ba6;
  --text-faint:       #4a5a72;
  --radius:           10px;
  --radius-lg:        16px;
  --shadow:           0 4px 24px rgba(0,0,0,0.45);
  --container:        1160px;
  --transition:       0.2s ease;
}

/* ---- 2. Reset & Base ---- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  line-height: 1.75;
  color: var(--text-primary);
  background: var(--bg-primary);
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { flex: 1; }

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a { color: var(--accent-gold); text-decoration: none; }
a:hover { text-decoration: underline; }

ul, ol { padding-left: 1.5rem; }
li { margin-bottom: 0.25rem; }

/* ---- 3. Typography ---- */
h1, h2, h3, h4 {
  font-family: 'Playfair Display', serif;
  line-height: 1.2;
  color: var(--text-primary);
}
h1 { font-size: clamp(1.9rem, 4vw, 3rem); font-weight: 900; margin: 0 0 1rem; }
h2 { font-size: clamp(1.4rem, 2.5vw, 2rem); font-weight: 800; margin-top: 2.5rem; margin-bottom: 1rem; }
h3 { font-size: clamp(1.1rem, 1.8vw, 1.4rem); font-weight: 700; margin-top: 2rem; margin-bottom: 0.75rem; }
h4 { font-size: 1rem; font-weight: 700; margin-top: 1.5rem; margin-bottom: 0.5rem; }
p  { color: var(--text-muted); margin: 0 0 1rem; }

/* ---- 4. Layout Helpers ---- */
.container {
  width: min(100% - 2rem, var(--container));
  margin-inline: auto;
}

.section-gap { margin-top: 3rem; padding-top: 2rem; border-top: 1px solid var(--border); }
.section-gap:first-of-type { border-top: none; }

.layout-two-col {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 2rem;
  align-items: start;
}
@media (max-width: 900px) {
  .layout-two-col { grid-template-columns: 1fr; }
}

/* ---- 5. Skip Link ---- */
.skip-link {
  position: absolute;
  left: -9999px;
  z-index: 9999;
}
.skip-link:focus {
  left: 1rem;
  top: 1rem;
  background: var(--accent-gold);
  color: #0a0a0a;
  padding: 0.5rem 1rem;
  border-radius: var(--radius);
  font-weight: 700;
  text-decoration: none;
}

/* ---- 6. Site Header ---- */
.site-header {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
  gap: 1rem;
  position: relative;
}
.site-logo { text-decoration: none; }
.logo-text {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  font-weight: 900;
  color: var(--text-primary);
}
.logo-za { color: var(--accent-gold); }

.primary-nav ul {
  display: flex;
  gap: 1.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
}
.primary-nav a {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
  transition: color var(--transition);
  text-decoration: none;
}
.primary-nav a:hover { color: var(--text-primary); }

/* Dropdown nav */
.has-dropdown { position: relative; }
.dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.5rem 0;
  min-width: 220px;
  list-style: none;
  z-index: 200;
  flex-direction: column;
  gap: 0;
  /* hidden by default — JS adds .open class */
  visibility: hidden;
  opacity: 0;
  display: flex;
  pointer-events: none;
  transition: opacity 0.15s ease, visibility 0.15s ease;
  box-shadow: var(--shadow);
}
.has-dropdown.open .dropdown {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
}
.dropdown li { width: 100%; }
.dropdown a {
  display: block;
  padding: 0.45rem 1rem;
  white-space: nowrap;
  font-size: 0.85rem;
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.4rem 0.6rem;
  cursor: pointer;
  flex-direction: column;
  gap: 4px;
}
.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
}

@media (max-width: 768px) {
  .nav-toggle { display: flex; }
  .primary-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: -1rem;
    right: -1rem;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
    padding: 1rem;
  }
  .primary-nav.is-open { display: block; }
  .primary-nav ul { flex-direction: column; gap: 0.25rem; }
  .primary-nav a { display: block; padding: 0.5rem 0; font-size: 1rem; }
  .dropdown { display: none !important; }
}

/* ---- 7. Breadcrumbs ---- */
.breadcrumbs { margin: 1rem 0 0.5rem; }
.breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.5rem;
  list-style: none;
  padding: 0.75rem 0;
  margin: 0;
  font-size: 0.82rem;
  color: var(--text-faint);
}
.breadcrumbs li + li::before { content: "/"; margin-right: 0.5rem; }
.breadcrumbs a { color: var(--text-faint); text-decoration: none; }
.breadcrumbs a:hover { color: var(--accent-gold); }
.breadcrumbs [aria-current] { color: var(--text-muted); }

/* ---- 8. Card ---- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: border-color var(--transition), background var(--transition);
}
.card:hover {
  border-color: var(--border-light);
  background: var(--bg-card-hover);
}

/* ---- 9. Score Badge ---- */
.score-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.9rem;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--accent-gold);
}

/* ---- 10. Buttons ---- */
.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
  transition: opacity var(--transition);
  text-decoration: none;
  cursor: pointer;
  border: none;
}
.btn:hover { opacity: 0.88; text-decoration: none; }
.btn-primary { background: var(--accent-gold); color: #0a0a0a; }
.btn-outline { border: 1px solid var(--border-light); color: var(--text-primary); background: transparent; }

/* ---- 11. Hero ---- */
.hero {
  padding: 4rem 0 3rem;
  background: linear-gradient(180deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
  border-bottom: 1px solid var(--border);
}
.hero__inner {
  max-width: 760px;
}
.hero__sub {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin: 1rem 0 1.5rem;
}
.hero__cta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}

/* ---- 12. Quick Facts ---- */
.quick-facts {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  margin: 1.5rem 0;
}
.quick-facts dl {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.5rem 1.5rem;
  margin: 0;
}
.quick-facts dt { color: var(--text-muted); font-size: 0.85rem; font-weight: 600; }
.quick-facts dd { color: var(--text-primary); font-weight: 500; margin: 0; }

/* ---- 13. Comparison Table ---- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.comparison-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.9rem;
}
.comparison-table th {
  background: var(--bg-card);
  color: var(--text-muted);
  font-weight: 600;
  text-align: left;
  padding: 0.75rem 1rem;
  border-bottom: 2px solid var(--border);
}
.comparison-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-primary);
  vertical-align: top;
}
.comparison-table tr:hover td { background: var(--bg-card); }

/* ---- 14. Pros / Cons ---- */
.pros-cons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin: 1.5rem 0;
}
.pros, .cons {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
}
.pros h3 { color: var(--accent-green); margin-top: 0; }
.cons h3 { color: var(--accent-red); margin-top: 0; }
.pros ul, .cons ul { padding-left: 1.25rem; margin: 0; }
.pros li, .cons li { color: var(--text-muted); margin-bottom: 0.4rem; }
@media (max-width: 600px) { .pros-cons { grid-template-columns: 1fr; } }

/* ---- 15. Verdict Box ---- */
.verdict-box {
  background: var(--bg-card);
  border: 1px solid var(--accent-gold);
  border-radius: var(--radius-lg);
  padding: 1.5rem 2rem;
  margin: 2rem 0;
}
.verdict-box h2 { margin-top: 0; color: var(--accent-gold); }
.score-large {
  font-family: 'Playfair Display', serif;
  font-size: 2.5rem;
  font-weight: 900;
  color: var(--accent-gold);
  display: block;
  margin: 0.5rem 0 1rem;
}

/* ---- 16. Disclosure / RG Bar ---- */
.disclosure-bar {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  font-size: 0.8rem;
  color: var(--text-faint);
  margin: 1rem 0;
}
.rg-bar {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  text-align: center;
  padding: 0.6rem 1rem;
  font-size: 0.78rem;
  color: var(--text-faint);
}

/* ---- 17. FAQ Accordion ---- */
.faq-list { border-top: 1px solid var(--border); margin: 1.5rem 0; }
.faq-item { border-bottom: 1px solid var(--border); }
.faq-question {
  width: 100%;
  background: none;
  border: none;
  text-align: left;
  padding: 1rem 0;
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}
.faq-question::after { content: '+'; font-size: 1.3rem; color: var(--accent-gold); flex-shrink: 0; }
.faq-question[aria-expanded="true"]::after { content: '−'; }
.faq-answer { padding-bottom: 1rem; }
.faq-answer[hidden] { display: none; }

/* ---- 18. Review Header ---- */
.review-header {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}
.review-header h1 { margin: 0; flex: 1; min-width: 200px; }

/* ---- 19. Sidebar ---- */
.review-sidebar { position: sticky; top: 90px; }
.sidebar-cta { text-align: center; }
.sidebar-score {
  font-family: 'Playfair Display', serif;
  font-size: 2rem;
  font-weight: 900;
  color: var(--accent-gold);
  margin: 0 0 0.25rem;
}
.sidebar-best-for { color: var(--text-muted); font-size: 0.85rem; margin-bottom: 1rem; }
.sidebar-disclosure { color: var(--text-faint); font-size: 0.75rem; margin-top: 0.75rem; margin-bottom: 0; }
.sidebar-nav h4 { margin: 0 0 0.75rem; }
.sidebar-nav ul { list-style: none; padding: 0; margin: 0; }
.sidebar-nav li { border-bottom: 1px solid var(--border); }
.sidebar-nav a {
  display: block;
  padding: 0.4rem 0;
  color: var(--text-muted);
  font-size: 0.85rem;
  text-decoration: none;
  transition: color var(--transition);
}
.sidebar-nav a:hover { color: var(--accent-gold); }
.sidebar-nav li:last-child { border-bottom: none; }

/* ---- 20. Top Picks Grid ---- */
.top-picks-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 1.5rem;
}
@media (max-width: 900px) { .top-picks-grid { grid-template-columns: 1fr; } }
.pick-card { display: flex; flex-direction: column; gap: 0.75rem; }
.pick-card h3 { margin-top: 0; color: var(--accent-gold); font-size: 1rem; }
.pick-card p { flex: 1; font-size: 0.9rem; }

/* ---- 21. Review Cards Grid (Hub) ---- */
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin-top: 1.5rem;
}
@media (max-width: 700px) { .reviews-grid { grid-template-columns: 1fr; } }
.review-card { display: flex; flex-direction: column; gap: 0.5rem; }
.review-card h3 { margin: 0; }
.review-card .score-badge { align-self: flex-start; }
.review-card p { font-size: 0.9rem; flex: 1; }
.review-card .btn { align-self: flex-start; margin-top: auto; }

/* Operator logos in cards */
.operator-logo {
  height: 36px;
  width: auto;
  max-width: 160px;
  display: block;
  margin-bottom: 0.5rem;
  filter: brightness(0) invert(1);
  opacity: 0.9;
  object-fit: contain;
  align-self: flex-start;
}
.review-card .operator-logo { height: 32px; }
.operator-logo-sm {
  height: 24px;
  width: auto;
  display: inline-block;
  vertical-align: middle;
  filter: brightness(0) invert(1);
  opacity: 0.8;
  margin-right: 0.5rem;
  object-fit: contain;
  flex-shrink: 0;
}

/* Blog hub grid */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin-top: 1.5rem;
}
@media (max-width: 700px) { .blog-grid { grid-template-columns: 1fr; } }
.blog-card { display: flex; flex-direction: column; gap: 0.5rem; }
.blog-card .blog-meta { font-size: 0.78rem; color: var(--text-faint); display: flex; gap: 0.75rem; flex-wrap: wrap; }
.blog-card h2 { font-size: 1.1rem; margin: 0; }
.blog-card h2 a { color: var(--text-primary); text-decoration: none; }
.blog-card h2 a:hover { color: var(--accent-gold); }
.blog-card p { font-size: 0.9rem; flex: 1; color: var(--text-muted); margin: 0; }
.blog-card .btn { align-self: flex-start; margin-top: auto; }
.blog-tag {
  display: inline-block;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--accent-gold);
  padding: 0.1rem 0.45rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ---- 22. How We Score Grid ---- */
.score-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-top: 1.5rem;
}
@media (max-width: 600px) { .score-grid { grid-template-columns: 1fr; } }
.score-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
}
.score-item h3 { margin: 0 0 0.25rem; font-size: 0.95rem; color: var(--accent-gold); }
.score-item p { font-size: 0.85rem; margin: 0; }
.score-weight {
  font-size: 0.75rem;
  color: var(--text-faint);
  font-weight: 700;
  margin-bottom: 0.25rem;
}

/* ---- 23. Footer ---- */
.site-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 3rem 0 0;
  margin-top: 4rem;
}
.site-footer__inner {
  display: grid;
  grid-template-columns: 200px repeat(4, 1fr);
  gap: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}
@media (max-width: 900px) {
  .site-footer__inner { grid-template-columns: 1fr 1fr; }
  .footer-col { grid-column: 1 / -1; }
}
@media (max-width: 540px) { .site-footer__inner { grid-template-columns: 1fr; } }
.footer-logo {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  font-weight: 900;
  color: var(--text-primary);
  margin: 0 0 0.5rem;
}
.footer-logo span { color: var(--accent-gold); }
.footer-tagline { font-size: 0.85rem; color: var(--text-faint); margin: 0; }
.footer-nav { display: contents; }
.footer-nav-col h4 {
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-faint);
  margin: 0 0 0.75rem;
}
.footer-nav-col ul { list-style: none; padding: 0; margin: 0; }
.footer-nav-col li { margin-bottom: 0.4rem; }
.footer-nav-col a {
  color: var(--text-muted);
  font-size: 0.85rem;
  text-decoration: none;
  transition: color var(--transition);
}
.footer-nav-col a:hover { color: var(--accent-gold); }

.footer-legal {
  padding: 1.5rem 0;
  text-align: center;
}
.footer-legal p {
  font-size: 0.78rem;
  color: var(--text-faint);
  margin-bottom: 0.5rem;
}
.footer-legal nav { display: flex; justify-content: center; gap: 1.5rem; flex-wrap: wrap; margin-top: 0.75rem; }
.footer-legal nav a { font-size: 0.78rem; color: var(--text-faint); }
.footer-legal nav a:hover { color: var(--text-muted); }

/* ---- 24. Related Links ---- */
.related-links {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  margin-top: 2rem;
}
.related-links h3 { margin-top: 0; font-size: 0.95rem; color: var(--text-muted); }
.related-links ul { list-style: none; padding: 0; margin: 0; }
.related-links li { border-bottom: 1px solid var(--border); }
.related-links li:last-child { border-bottom: none; }
.related-links a {
  display: block;
  padding: 0.4rem 0;
  color: var(--text-muted);
  font-size: 0.9rem;
  transition: color var(--transition);
}
.related-links a:hover { color: var(--accent-gold); }

/* ---- 25. Hub Grid (Compare Hub) ---- */
.hub-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin-top: 1.5rem;
}
@media (max-width: 600px) { .hub-grid { grid-template-columns: 1fr; } }
.hub-card { display: flex; flex-direction: column; gap: 0.5rem; }
.hub-card h3 { margin: 0; font-size: 1rem; }
.hub-card p { font-size: 0.9rem; flex: 1; }
.hub-card .btn { align-self: flex-start; margin-top: auto; font-size: 0.85rem; padding: 0.5rem 1rem; }

/* ---- 26. Contact Form ---- */
.contact-form { margin-top: 1.5rem; }
.form-group { margin-bottom: 1.25rem; }
.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.6rem 0.9rem;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  transition: border-color var(--transition);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent-gold);
}
.form-group textarea { resize: vertical; min-height: 120px; }

/* ---- 27. Page Content Blocks ---- */
.page-content { padding: 2rem 0 4rem; }
.page-content h2:first-of-type { margin-top: 0; }
.page-content article { max-width: 760px; }

/* ---- 28. Utility ---- */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.text-gold { color: var(--accent-gold); }
.text-green { color: var(--accent-green); }
.text-red { color: var(--accent-red); }
.text-muted { color: var(--text-muted); }
.mt-0 { margin-top: 0; }
