@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,700;0,900;1,700&family=DM+Sans:wght@300;400;500;600&family=Space+Mono:wght@400;700&display=swap');

:root {
  --ink: #0d0d1a;
  --cream: #faf8f3;
  --saffron: #f97316;
  --amber: #fbbf24;
  --sky: #0ea5e9;
  --mint: #10b981;
  --violet: #7c3aed;
  --rose: #f43f5e;
  --surface: #ffffff;
  --muted: #6b7280;
  --border: #e5e7eb;
  --shadow: 0 4px 24px rgba(13,13,26,0.08);
  --shadow-lg: 0 16px 48px rgba(13,13,26,0.14);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--cream);
  color: var(--ink);
  line-height: 1.6;
  overflow-x: hidden;
}

/* ---- NAV ---- */
nav {
  position: sticky;
  top: 0;
  z-index: 999;
  background: rgba(250,248,243,0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 2rem;
  height: 68px;
  display: flex;
  align-items: center;
  gap: 2rem;
}

.logo {
  font-family: 'Playfair Display', serif;
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.5px;
}

.logo span { color: var(--saffron); }

.nav-links {
  display: flex;
  gap: 0.25rem;
  list-style: none;
  margin-left: auto;
}

.nav-links a {
  text-decoration: none;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  transition: all 0.2s;
}

.nav-links a:hover, .nav-links a.active {
  color: var(--ink);
  background: rgba(13,13,26,0.06);
}

.nav-cta {
  background: var(--ink) !important;
  color: var(--cream) !important;
  border-radius: 8px !important;
  padding: 0.5rem 1.25rem !important;
}

.nav-cta:hover {
  background: var(--saffron) !important;
  color: var(--ink) !important;
}

/* ---- BUTTONS ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.75rem;
  border-radius: 10px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: all 0.25s cubic-bezier(0.4,0,0.2,1);
}

.btn-primary {
  background: var(--saffron);
  color: white;
  box-shadow: 0 4px 16px rgba(249,115,22,0.35);
}

.btn-primary:hover {
  background: #ea6d08;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(249,115,22,0.4);
}

.btn-dark {
  background: var(--ink);
  color: white;
}

.btn-dark:hover {
  background: #1e1e3a;
  transform: translateY(-2px);
}

.btn-outline {
  background: transparent;
  color: var(--ink);
  border: 2px solid var(--ink);
}

.btn-outline:hover {
  background: var(--ink);
  color: white;
}

.btn-lg { padding: 1rem 2.25rem; font-size: 1.05rem; border-radius: 12px; }

/* ---- CONTAINER ---- */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* ---- BADGES ---- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.9rem;
  border-radius: 100px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.03em;
}

.badge-saffron { background: rgba(249,115,22,0.12); color: var(--saffron); }
.badge-sky { background: rgba(14,165,233,0.12); color: var(--sky); }
.badge-mint { background: rgba(16,185,129,0.12); color: var(--mint); }
.badge-violet { background: rgba(124,58,237,0.12); color: var(--violet); }
.badge-rose { background: rgba(244,63,94,0.12); color: var(--rose); }

/* ---- CARDS ---- */
.card {
  background: var(--surface);
  border-radius: 16px;
  border: 1px solid var(--border);
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: transparent;
}

/* ---- SECTION TITLES ---- */
.section-label {
  font-family: 'Space Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--saffron);
  margin-bottom: 0.75rem;
  display: block;
}

.section-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 900;
  line-height: 1.1;
  color: var(--ink);
}

.section-title em {
  font-style: italic;
  color: var(--saffron);
}

/* ---- FOOTER ---- */
footer {
  background: var(--ink);
  color: rgba(255,255,255,0.7);
  padding: 4rem 0 2rem;
}

footer .logo { color: white; }

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

footer h4 {
  color: white;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
  letter-spacing: 0.02em;
}

footer ul { list-style: none; }
footer ul li { margin-bottom: 0.6rem; }
footer ul a {
  color: rgba(255,255,255,0.55);
  text-decoration: none;
  font-size: 0.88rem;
  transition: color 0.2s;
}
footer ul a:hover { color: var(--saffron); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.82rem;
  color: rgba(255,255,255,0.4);
}

/* ---- STAR RATING ---- */
.stars { color: var(--amber); letter-spacing: 2px; }

/* ---- MOBILE ---- */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 480px) {
  .footer-grid { grid-template-columns: 1fr; }
  .container { padding: 0 1.25rem; }
}

/* =====================================================
   COURSES PAGE — extra styles
   ===================================================== */

/* Mobile nav toggle */
.menu-btn {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--ink);
}

@media (max-width: 768px) {
  .menu-btn { display: block; margin-left: auto; }
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--cream);
    padding: 1rem 2rem;
    border-bottom: 1px solid var(--border);
    gap: 0.25rem;
    margin-left: 0;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 0.75rem 0.5rem; }
}

/* Hero */
.hero {
  background: linear-gradient(135deg, var(--ink), #1e1e3a);
  padding: 3rem 0 2.5rem;
}
.hero .section-title { color: white; }
.hero-sub {
  color: rgba(255,255,255,0.65);
  font-size: 1rem;
  max-width: 560px;
  margin-top: 0.5rem;
}

/* Search + level filter bar */
.filter-bar {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 1rem 0;
  position: sticky;
  top: 68px;
  z-index: 80;
}
.filter-bar-inner {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
}
.search-form { display: flex; flex: 1; min-width: 220px; }
.search-form input {
  flex: 1;
  padding: 0.6rem 0.9rem;
  border: 1.5px solid var(--border);
  border-radius: 8px 0 0 8px;
  font-size: 0.9rem;
  font-family: 'DM Sans', sans-serif;
  outline: none;
}
.search-form button {
  padding: 0.6rem 1.1rem;
  background: var(--saffron);
  color: white;
  border: none;
  border-radius: 0 8px 8px 0;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}
.level-pills { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.level-pills a {
  padding: 0.45rem 0.9rem;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  background: var(--border);
  color: var(--muted);
  white-space: nowrap;
}
.level-pills a.active { background: var(--ink); color: white; }

/* Main layout: sidebar + course grid */
.layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 2rem;
  padding: 2rem 0 4rem;
  align-items: start;
}
@media (max-width: 900px) {
  .layout { grid-template-columns: 1fr; }
}

.sidebar { position: sticky; top: 140px; }
@media (max-width: 900px) { .sidebar { position: static; } }

.sidebar-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.25rem;
  margin-bottom: 1.25rem;
}
.sidebar-box h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1rem;
  margin-bottom: 0.85rem;
}
.filter-link {
  display: flex;
  justify-content: space-between;
  padding: 0.5rem 0.6rem;
  border-radius: 8px;
  text-decoration: none;
  color: var(--muted);
  font-size: 0.88rem;
  margin-bottom: 0.15rem;
}
.filter-link:hover, .filter-link.active {
  background: rgba(13,13,26,0.06);
  color: var(--ink);
  font-weight: 600;
}
.filter-link .count { color: var(--muted); font-size: 0.78rem; }

.cta-box {
  background: linear-gradient(135deg, var(--ink), #1e1e3a);
  border-radius: 14px;
  padding: 1.5rem;
  text-align: center;
  color: white;
}
.cta-box p { color: rgba(255,255,255,0.75); font-size: 0.85rem; margin-bottom: 1rem; }

/* Results bar */
.results-bar {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}
.results-bar p { color: var(--muted); font-size: 0.9rem; }
.results-bar strong { color: var(--ink); }
.clear-link { font-size: 0.82rem; color: var(--rose); font-weight: 600; text-decoration: none; }

/* Course grid + card */
.course-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
  gap: 1.25rem;
}
.course-card { display: flex; flex-direction: column; }
.course-thumb { position: relative; height: 170px; overflow: hidden; }
.course-thumb img { width: 100%; height: 100%; object-fit: cover; }
.tag {
  position: absolute;
  top: 10px;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 700;
  color: white;
}
.tag-featured { left: 10px; background: var(--saffron); }
.tag-level { right: 10px; background: rgba(0,0,0,0.55); }

.course-body { padding: 1.1rem; flex: 1; display: flex; flex-direction: column; }
.course-cat {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--sky);
  margin-bottom: 0.4rem;
}
.course-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.02rem;
  line-height: 1.35;
  margin-bottom: 0.5rem;
  flex: 1;
}
.course-title a { color: var(--ink); text-decoration: none; }
.course-desc {
  font-size: 0.83rem;
  color: var(--muted);
  margin-bottom: 0.75rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.course-meta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.8rem;
  color: var(--muted);
  margin-bottom: 0.75rem;
}
.course-rating { display: flex; gap: 0.35rem; align-items: center; margin-bottom: 0.75rem; font-size: 0.85rem; }
.course-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: auto;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
}
.price { font-size: 1.05rem; font-weight: 800; color: var(--ink); }
.price-old { font-size: 0.8rem; color: var(--muted); text-decoration: line-through; margin-left: 0.35rem; }
.price-free { color: var(--mint); }
.course-actions { display: flex; gap: 0.5rem; }
.btn-sm { padding: 0.4rem 0.9rem; font-size: 0.8rem; border-radius: 8px; }

/* Empty state */
.empty-state {
  text-align: center;
  padding: 4rem 1.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
}

/* Pagination */
.pagination { display: flex; justify-content: center; gap: 0.5rem; margin-top: 2.5rem; flex-wrap: wrap; }
.pagination a {
  padding: 0.55rem 0.9rem;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  background: var(--surface);
  color: var(--muted);
  border: 1px solid var(--border);
}
.pagination a.active { background: var(--ink); color: white; border-color: var(--ink); }

/* Inquiry modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(13,13,26,0.6);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  z-index: 1000;
}
.modal-overlay.open { display: flex; }
.modal-box {
  background: var(--surface);
  border-radius: 16px;
  padding: 2rem;
  max-width: 440px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
}
.modal-box h2 { font-family: 'Playfair Display', serif; margin-bottom: 0.4rem; }
.modal-box > p { color: var(--muted); font-size: 0.88rem; margin-bottom: 1.25rem; }
.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: var(--border);
  cursor: pointer;
  font-size: 1rem;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; }
@media (max-width: 480px) { .form-row { grid-template-columns: 1fr; } }
.form-group { margin-bottom: 1rem; }
.form-group label { display: block; font-size: 0.82rem; font-weight: 600; margin-bottom: 0.35rem; }
.form-group input, .form-group select, .form-group textarea {
  width: 100%;
  padding: 0.6rem 0.75rem;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.9rem;
  outline: none;
}
.form-group textarea { resize: vertical; min-height: 80px; }
.alert-error {
  background: #fef2f2;
  border: 1px solid #fca5a5;
  color: #b91c1c;
  padding: 0.7rem 1rem;
  border-radius: 8px;
  font-size: 0.85rem;
  margin-bottom: 1rem;
}

/* WhatsApp float button */
.whatsapp-float {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  width: 56px;
  height: 56px;
  background: #25d366;
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  text-decoration: none;
  box-shadow: var(--shadow-lg);
  z-index: 500;
}