/* =====================================================
   PassNova — Shared Course Page Styles
   Single source of truth for all 39 course landing pages.
   This file is loaded AFTER styles.min.css so these rules win.
   ===================================================== */

/* --- Design tokens --- */
:root {
  --course-hero-start: #2563EB;
  --course-hero-end: #1E40AF;
  --course-accent: #F59E0B;
  --course-badge-text: #B45309;   /* was #FCD34D (4.26:1 FAIL) → #B45309 (5.02:1 PASS) */
  --course-price-old-color: #64748B;   /* was #94A3B8 (2.56:1 FAIL) → #64748B (4.76:1 PASS) */
  --course-price-new-color: #2563EB;
  --course-cta-text: #111827;
}

/* --- Header must share the gradient so nav visually continues into hero --- */
.course-header {
  background: linear-gradient(135deg, var(--course-hero-start) 0%, var(--course-hero-end) 100%) !important;
  border-bottom: none !important;
  padding: 0 !important;
  display: block !important;
}

/* Scope gradient + remove double-padding where header meets hero */
.course-header + .hero {
  background: linear-gradient(135deg, var(--course-hero-start) 0%, var(--course-hero-end) 100%) !important;
  color: white;
  padding-top: 1.5rem;
}

/* Force white text in hero regardless of per-page inline styles */
.hero h1, .hero h2 {
  color: white !important;
}
.hero p, .hero .hero-subtitle, .hero .subtitle,
.hero .hero-subheading, .hero-container > p {
  color: rgba(255, 255, 255, 0.85) !important;
}

/* --- Frosted nav (nav lives INSIDE .hero) --- */
.course-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.course-nav-logo {
  color: white;
  font-weight: 800;
  font-size: 1.1rem;
  text-decoration: none;
  letter-spacing: -0.02em;
}

.course-nav-links {
  display: flex;
  gap: 1.25rem;
  align-items: center;
}

.course-nav-links a {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.85rem;
  text-decoration: none;
  transition: color 0.2s;
}

.course-nav-links a:hover {
  color: white;
}

.course-nav-actions {
  display: flex;
  gap: 0.4rem;
  align-items: center;
}

.course-nav-signin {
  border: 1px solid rgba(255, 255, 255, 0.45);
  color: white !important;
  padding: 0.35rem 0.9rem;
  border-radius: 6px;
  font-size: 0.8rem;
  text-decoration: none;
  background: transparent;
  cursor: pointer;
  transition: background 0.2s;
}

.course-nav-signin:hover {
  background: rgba(255, 255, 255, 0.1);
}

.course-nav-cta {
  background: var(--course-accent);
  color: var(--course-cta-text) !important;
  padding: 0.35rem 0.9rem;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: opacity 0.2s;
}

.course-nav-cta:hover {
  opacity: 0.9;
}

/* --- Limited Time Offer badge --- */
.course-offer-badge {
  display: inline-block;
  background: rgba(245, 158, 11, 0.2);
  color: var(--course-badge-text);
  border: 1px solid rgba(245, 158, 11, 0.4);
  padding: 3px 12px;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

/* --- 3-box stat grid --- */
.course-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  max-width: 400px;
  margin: 0 auto 1.5rem;
}

.course-stat-box {
  background: rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 8px;
  padding: 0.85rem 0.5rem;
  text-align: center;
}

/* Stat boxes outside a dark hero (e.g. kids zone pages with light bg) */
:not(.hero) > .course-stats .course-stat-box {
  background: rgba(37, 99, 235, 0.12);
  border: 1px solid rgba(37, 99, 235, 0.22);
}
:not(.hero) > .course-stats .course-stat-number { color: #1E40AF; }
:not(.hero) > .course-stats .course-stat-label  { color: #2563EB; opacity: 1; }

/* Stat boxes INSIDE a dark hero — always white regardless of nesting depth */
.hero .course-stat-number { color: white !important; }
.hero .course-stat-label  { color: rgba(255, 255, 255, 0.92) !important; }
.hero .course-stat-box    { background: rgba(255, 255, 255, 0.22) !important; border-color: rgba(255, 255, 255, 0.25) !important; }

.course-stat-number {
  font-size: 1.5rem;
  font-weight: 800;
  line-height: 1;
  color: white;
}

.course-stat-label {
  font-size: 0.65rem;
  opacity: 1;
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.92);
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

/* --- Primary amber CTA button --- */
.course-cta-btn {
  display: inline-block;
  background: var(--course-accent);
  color: var(--course-cta-text) !important;
  padding: 0.8rem 2.2rem;
  border-radius: 8px;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: opacity 0.2s;
}

.course-cta-btn:hover {
  opacity: 0.9;
}

/* Strikethrough / savings line below hero CTA */
.course-cta-savings {
  font-size: 0.78rem;
  opacity: 0.65;
  margin-top: 6px;
  color: white;
}

.course-cta-savings s {
  text-decoration: line-through;
}

/* --- Pricing section (further down page) --- */
.course-price-old {
  font-size: 0.9rem;
  color: var(--course-price-old-color);
  text-decoration: line-through;
  display: block;
  margin-bottom: 2px;
}

.course-price-current {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--course-price-new-color);
  line-height: 1;
  display: block;
}

.course-price-savings {
  font-size: 0.8rem;
  color: #92400e;   /* was var(--course-accent) #F59E0B (2.4:1 FAIL) → #92400e (7.8:1 PASS) */
  font-weight: 600;
  display: block;
  margin: 4px 0 1rem;
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .course-nav-links {
    display: none; /* hamburger not needed — sign in + cta still visible */
  }
  .course-stats {
    max-width: 100%;
  }
}

@media (max-width: 480px) {
  .course-nav {
    padding: 0.6rem 1rem;
  }
  .course-stats {
    gap: 6px;
  }
  .course-stat-number {
    font-size: 1.2rem;
  }
  .course-cta-btn {
    padding: 0.75rem 1.5rem;
    font-size: 0.9rem;
  }
}
