/* ============================================================
   MAYELE ACADEMY — main.css
   Global Public Styles
   ============================================================ */

:root {
  /* Brand — overridden at runtime from Admin ▸ Settings ▸ Appearance;
     these are just the documented defaults (Refined Navy & Amber). */
  --primary:       #0B1526;
  --gold:          #C8863A;

  /* Derived brand shades — computed from the two tokens above so the
     whole palette stays in sync if the brand colors ever change. */
  --primary-light: color-mix(in srgb, var(--primary) 78%, white 22%);
  --primary-deep:  color-mix(in srgb, var(--primary) 85%, black 15%);
  --gold-hover:    color-mix(in srgb, var(--gold) 78%, white 22%);
  --gold-deep:     color-mix(in srgb, var(--gold) 80%, black 20%);
  --primary-rgb:   11, 21, 38;
  --gold-rgb:      200, 134, 58;

  /* Neutrals */
  --text:          #1A2233;
  --text-muted:    #667085;
  --bg-light:      #FBF8F3;
  --white:         #ffffff;

  /* Effects */
  --radius:        20px;
  --radius-sm:     12px;
  --shadow:        0 4px 24px rgba(var(--primary-rgb), 0.07);
  --shadow-hover:  0 20px 50px rgba(var(--primary-rgb), 0.14);
  --transition:    0.3s cubic-bezier(.4, 0, .2, 1);
}

/* ── Dark Mode ─────────────────────────────────────────── */
.dark-mode {
  --bg-light: #0d1117;
  --white: #161b22;
  --text: #e6edf3;
  --text-muted: #8b949e;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
}

body {
  font-family: 'DM Sans', sans-serif;
  color: var(--text);
  background-color: var(--white);
  line-height: 1.6;
  scroll-behavior: smooth;
  transition: background-color var(--transition), color var(--transition);
}

a {
  text-decoration: none;
  transition: color var(--transition);
}

/* ── Navigation ─────────────────────────────────────────── */
.navbar {
  background: linear-gradient(rgba(var(--primary-rgb),.55), rgba(var(--primary-rgb),0)) !important;
  padding: 26px 0;
}

.navbar-brand {
  font-family: 'Playfair Display', serif;
  font-size: 23px;
  color: #fff !important;
  font-weight: 700;
  letter-spacing: .5px;
}

.navbar-brand span {
  color: var(--gold);
}

.nav-link {
  color: rgba(255, 255, 255, .8) !important;
  font-size: 14px;
  font-weight: 500;
  transition: var(--transition);
}

.nav-link:hover, .nav-link.active {
  color: var(--gold) !important;
}

/* ── Buttons ────────────────────────────────────────────── */
.btn-enroll {
  background: var(--gold);
  color: var(--primary);
  font-weight: 700;
  padding: 8px 22px;
  border-radius: 8px;
  border: none;
  font-size: 14px;
  transition: var(--transition);
  display: inline-block;
  text-align: center;
}

.btn-enroll:hover {
  background: var(--gold-hover);
  transform: translateY(-1px);
  color: var(--primary);
}

.btn-outline-white {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, .3);
  border-radius: 8px;
  padding: 7px 18px;
  font-size: 14px;
  background: transparent;
  transition: var(--transition);
}

.btn-outline-white:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, .1);
  color: #fff;
}

/* ── Dark Mode Toggle ────────────────────────────────────── */
.dark-icon { display: block; width: 18px; height: 18px; color: #fff; }
.light-icon { display: none; width: 18px; height: 18px; color: var(--gold); }
.dark-mode .dark-icon { display: none; }
.dark-mode .light-icon { display: block; }

/* ── Hero Sections ──────────────────────────────────────── */
.hero {
  background: linear-gradient(135deg, var(--primary-deep) 0%, var(--primary) 55%, var(--primary-light) 100%);
  min-height: 88vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  color: #fff;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.02'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/svg%3E");
}

.page-hero {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  padding: 88px 0;
  text-align: center;
  color: #fff;
}

.hero-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(38px, 6vw, 72px);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -.5px;
  margin-bottom: 20px;
}

.hero-title em {
  color: var(--gold);
  font-style: normal;
}

.hero-sub {
  font-size: 18px;
  color: rgba(255, 255, 255, .75);
  margin-bottom: 32px;
  max-width: 540px;
  line-height: 1.7;
}

/* ── Editorial Homepage Hero ────────────────────────────── */
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 700; letter-spacing: 2px; text-transform: uppercase;
  color: var(--gold); margin-bottom: 22px;
}
.hero-eyebrow::before { content: ''; width: 26px; height: 1px; background: var(--gold); display: inline-block; }

.hero-title-xl {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: clamp(44px, 7vw, 92px);
  line-height: .98;
  letter-spacing: -1.5px;
  margin-bottom: 26px;
  color: #fff;
}

.hero-sub-xl {
  font-size: clamp(16px, 1.6vw, 19px);
  color: rgba(255, 255, 255, .68);
  max-width: 480px;
  line-height: 1.75;
  margin-bottom: 36px;
}

.hero-stat-row { display: flex; gap: 0; margin-top: 56px; }
.hero-stat-row .stat { padding-right: 32px; margin-right: 32px; border-right: 1px solid rgba(255,255,255,.14); }
.hero-stat-row .stat:last-child { border-right: none; margin-right: 0; padding-right: 0; }
.hero-stat-row .stat .num { font-family: 'Playfair Display', serif; font-size: clamp(24px, 2.6vw, 34px); font-weight: 700; color: #fff; line-height: 1; }
.hero-stat-row .stat .lbl { font-size: 11px; letter-spacing: 1px; text-transform: uppercase; color: rgba(255,255,255,.5); margin-top: 6px; }

.hero-visual { position: relative; padding: 30px 10px 50px 30px; }
.hero-visual-card {
  border-radius: 22px;
  box-shadow: 0 30px 70px rgba(0,0,0,.35);
}
.hero-visual-card.main {
  background: linear-gradient(160deg, rgba(255,255,255,.08), rgba(255,255,255,.02));
  border: 1px solid rgba(255,255,255,.12);
  backdrop-filter: blur(6px);
  padding: 36px 32px;
  transform: rotate(-3deg);
  color: #fff;
}
.hero-visual-card.main .vc-icon { font-size: 40px; margin-bottom: 14px; }
.hero-visual-card.main .vc-cat { font-size: 11px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--gold); font-weight: 700; margin-bottom: 8px; }
.hero-visual-card.main .vc-title { font-family: 'Playfair Display', serif; font-size: 22px; margin-bottom: 14px; line-height: 1.3; }
.hero-visual-card.main .vc-price { font-size: 26px; font-weight: 700; color: var(--gold); }

.hero-visual-card.floating {
  position: absolute;
  background: #fff;
  color: var(--text);
  padding: 14px 20px;
  display: flex; align-items: center; gap: 12px;
  animation: heroFloat 5s ease-in-out infinite;
}
.hero-visual-card.floating .fc-emoji { font-size: 22px; }
.hero-visual-card.floating .fc-num { font-weight: 700; font-size: 16px; line-height: 1.1; }
.hero-visual-card.floating .fc-lbl { font-size: 10.5px; color: var(--text-muted); text-transform: uppercase; letter-spacing: .5px; }
.hero-visual-card.floating.badge-1 { top: -14px; right: 10px; animation-delay: 0s; }
.hero-visual-card.floating.badge-2 { bottom: 6px; left: -18px; animation-delay: -2.5s; }

@keyframes heroFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@media (prefers-reduced-motion: reduce) { .hero-visual-card.floating { animation: none; } }
@media (max-width: 991px) { .hero-visual { display: none; } }

/* ── Editorial numbering ────────────────────────────────── */
.editorial-num {
  font-family: 'Playfair Display', serif;
  font-size: 13px; font-weight: 700; color: var(--gold);
  letter-spacing: 1px;
}

/* ── Filter tabs (Programs page) ────────────────────────── */
.filter-tabs { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; border-bottom: 1px solid rgba(0,0,0,.08); margin-bottom: 56px; }
.dark-mode .filter-tabs { border-color: rgba(255,255,255,.1); }
.filter-tab {
  background: none; border: none; padding: 0 6px 16px;
  font-size: 14px; font-weight: 600; color: var(--text-muted);
  border-bottom: 2px solid transparent; margin-bottom: -1px;
  transition: color var(--transition), border-color var(--transition);
}
.filter-tab:hover { color: var(--primary); }
.dark-mode .filter-tab:hover { color: var(--gold); }
.filter-tab.active-cat { color: var(--primary); border-bottom-color: var(--gold); }
.dark-mode .filter-tab.active-cat { color: var(--gold); }

/* ── Spotlight card (Programs page featured item) ───────── */
.spotlight-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-hover);
  overflow: hidden;
  border: 1px solid rgba(0,0,0,.05);
}
.spotlight-card .sc-media {
  min-height: 280px;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  display: flex; align-items: center; justify-content: center;
  font-size: 96px; color: #fff;
  position: relative;
}
.spotlight-card .sc-media img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; }

/* ── Content Sections ───────────────────────────────────── */
section {
  padding: 96px 0;
}

.bg-light {
  background-color: var(--bg-light) !important;
}

.section-label {
  font-size: 11px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 600;
}

.section-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(28px, 4vw, 42px);
  color: var(--primary);
  margin-top: 6px;
  margin-bottom: 8px;
}

.dark-mode .section-title {
  color: var(--gold);
}

.section-sub {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 560px;
  margin: 0 auto 48px;
}

/* ── Course Cards ───────────────────────────────────────── */
.course-card {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
  background: var(--white);
  border: 1px solid rgba(0,0,0,0.05);
  height: 100%;
}

.course-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-4px);
}

.course-thumb {
  height: 180px;
  object-fit: cover;
  width: 100%;
}

.course-thumb-placeholder {
  height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 52px;
  color: #fff;
}

.badge-level {
  font-size: 10px;
  padding: 3px 10px;
  border-radius: 100px;
  font-weight: 600;
  background: rgba(var(--primary-rgb), .08);
  color: var(--primary);
}

.dark-mode .badge-level {
  background: rgba(var(--gold-rgb), .15);
  color: var(--gold);
}

.course-price {
  font-family: 'Playfair Display', serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--primary);
}

.dark-mode .course-price {
  color: var(--gold);
}

/* ── Testimonials ───────────────────────────────────────── */
.testi-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
  height: 100%;
  border: 1px solid rgba(0,0,0,0.05);
}

.testi-quote {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.7;
  font-style: italic;
  margin-bottom: 18px;
}

.testi-quote::before {
  content: '"';
  font-size: 40px;
  color: var(--gold);
  font-family: 'Playfair Display', serif;
  line-height: .7;
  display: block;
  margin-bottom: 8px;
}

/* ── Footer ─────────────────────────────────────────────── */
footer {
  background: #0d1b2a;
  color: rgba(255, 255, 255, .6);
  padding: 50px 0 24px;
}

footer a {
  color: rgba(255, 255, 255, .5);
  font-size: 14px;
}

footer a:hover {
  color: var(--gold);
}

.footer-brand {
  font-family: 'Playfair Display', serif;
  font-size: 22px;
  color: #fff;
  margin-bottom: 8px;
}

.footer-divider {
  border-color: rgba(255, 255, 255, .08);
}

/* ── WhatsApp ───────────────────────────────────────────── */
.wa-btn {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 9999;
  background: #25D366;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(37, 211, 102, .4);
  transition: var(--transition);
}

.wa-btn:hover {
  transform: scale(1.1);
  background: #1ebe5a;
}

.wa-btn svg {
  width: 30px;
  height: 30px;
}

/* ── Responsive Video Embed ─────────────────────────────── */
.video-embed-wrap {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  border-radius: 18px;
  overflow: hidden;
  background: #000;
  box-shadow: var(--shadow-hover);
}
.video-embed-wrap iframe,
.video-embed-wrap video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* ── Program Overview Page ─────────────────────────────── */
.overview-hero {
  background: linear-gradient(135deg, var(--primary-deep) 0%, var(--primary) 55%, var(--primary-light) 100%);
  color: #fff;
  padding: 56px 0 90px;
  position: relative;
  overflow: hidden;
}
.overview-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.02'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/svg%3E");
}
.overview-breadcrumb { font-size: 13px; color: rgba(255,255,255,.55); margin-bottom: 18px; }
.overview-breadcrumb a { color: rgba(255,255,255,.7); }
.overview-breadcrumb a:hover { color: var(--gold); }
.overview-meta-row { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 22px; }
.overview-meta-pill {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14);
  border-radius: 100px; padding: 7px 16px; font-size: 12.5px; color: rgba(255,255,255,.85);
}
.overview-meta-pill svg { width: 14px; height: 14px; color: var(--gold); }

.overview-card {
  background: var(--white);
  border-radius: 20px;
  box-shadow: var(--shadow-hover);
  margin-top: -70px;
  position: relative;
  z-index: 2;
}
.overview-sticky {
  position: sticky;
  top: 24px;
}
.overview-price-box {
  background: var(--white);
  border-radius: 18px;
  box-shadow: var(--shadow-hover);
  padding: 28px;
  border: 1px solid rgba(0,0,0,.05);
}
.overview-section-label {
  font-size: 11px; letter-spacing: 2.5px; text-transform: uppercase;
  color: var(--gold); font-weight: 700; margin-bottom: 8px;
}
.overview-section-title {
  font-family: 'Playfair Display', serif;
  font-size: 26px; color: var(--primary); margin-bottom: 18px;
}
.dark-mode .overview-section-title { color: var(--gold); }
.overview-body-text { font-size: 15.5px; line-height: 1.9; color: var(--text-muted); }
.overview-fact { display: flex; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid rgba(0,0,0,.06); font-size: 14px; }
.dark-mode .overview-fact { border-color: rgba(255,255,255,.08); }
.overview-fact span:first-child { color: var(--text-muted); }
.overview-fact span:last-child { font-weight: 600; color: var(--text); }
.instructor-chip { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.instructor-chip img { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; }
.curriculum-item {
  display: flex; align-items: center; gap: 14px;
  padding: 14px 18px; border-radius: 12px; background: var(--bg-light);
  margin-bottom: 10px; font-size: 14px;
}
.curriculum-item .cur-icon {
  width: 34px; height: 34px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(var(--primary-rgb),.08); color: var(--primary); flex-shrink: 0;
}
.dark-mode .curriculum-item .cur-icon { background: rgba(var(--gold-rgb),.15); color: var(--gold); }
.related-badge-new {
  position: absolute; top: 14px; left: 14px; z-index: 3;
  background: var(--gold); color: var(--primary); font-size: 10px; font-weight: 700;
  padding: 4px 12px; border-radius: 100px; letter-spacing: .5px; text-transform: uppercase;
}

/* ── Global Micro-polish ────────────────────────────────── */
::selection { background: var(--gold); color: var(--primary); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(var(--primary-rgb),.18); border-radius: 100px; }
::-webkit-scrollbar-thumb:hover { background: rgba(var(--primary-rgb),.32); }
.dark-mode ::-webkit-scrollbar-thumb { background: rgba(255,255,255,.15); }
.dark-mode ::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,.28); }

/* ── Scroll Reveal ──────────────────────────────────────── */
.reveal-init {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s cubic-bezier(.16,1,.3,1), transform .7s cubic-bezier(.16,1,.3,1);
  transition-delay: var(--reveal-delay, 0ms);
  will-change: opacity, transform;
}
.reveal-init.is-visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .reveal-init { opacity: 1 !important; transform: none !important; transition: none !important; }
}

/* ── Navbar scroll state ────────────────────────────────── */
.navbar.sticky-top {
  transition: padding var(--transition), box-shadow var(--transition), background-color var(--transition);
}
.navbar.sticky-top.nav-scrolled {
  padding: 8px 0;
  box-shadow: 0 8px 30px rgba(0,0,0,.25);
  background: rgba(var(--primary-rgb),.96) !important;
  backdrop-filter: blur(10px);
}
.navbar-nav .nav-link { position: relative; }
.navbar-nav .nav-link::after {
  content: '';
  position: absolute; left: 50%; bottom: -4px;
  width: 0; height: 2px; background: var(--gold);
  transition: width var(--transition), left var(--transition);
  transform: translateX(-50%);
}
.navbar-nav .nav-link:hover::after,
.navbar-nav .nav-link.active::after { width: 60%; }

/* ── Hero cursor glow ───────────────────────────────────── */
.hero, .page-hero { position: relative; }
.hero::after, .page-hero::after {
  content: '';
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(600px circle at var(--x, 50%) var(--y, 30%), rgba(var(--gold-rgb),.18), transparent 45%);
  opacity: 0; transition: opacity .4s ease;
}
.hero:hover::after, .page-hero:hover::after { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .hero::after, .page-hero::after { display: none; }
}

/* ── Button shine sweep ─────────────────────────────────── */
.btn-enroll { position: relative; overflow: hidden; }
.btn-enroll::before {
  content: '';
  position: absolute; top: 0; left: -60%; width: 35%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,.55), transparent);
  transform: skewX(-20deg);
  transition: left .6s ease;
}
.btn-enroll:hover::before { left: 130%; }

/* ── Card motion polish ─────────────────────────────────── */
.course-card { overflow: hidden; }
.course-thumb { transition: transform .5s ease; }
.course-card:hover .course-thumb { transform: scale(1.06); }
.testi-card { transition: transform var(--transition), box-shadow var(--transition); }
.testi-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-hover); }
.course-item { transition: opacity .22s ease, transform .22s ease; }
.filter-btn { transition: all .2s ease; }

/* ── Stats Bar ──────────────────────────────────────────── */
.stats-bar {
  background: var(--primary);
  padding: 60px 0;
  text-align: center;
  color: #fff;
}

.stats-bar .num {
  font-size: 42px;
  font-weight: 700;
  color: var(--gold);
  font-family: 'Playfair Display', serif;
}

.stats-bar .lbl {
  font-size: 13px;
  color: rgba(255, 255, 255, .6);
  letter-spacing: 1px;
  text-transform: uppercase;
}
