/* ═══════════════════════════════════════════════════════════════
   QEARA — Global Stylesheet
   Premium Trilingual Arabic & English Language Learning Platform
   ═══════════════════════════════════════════════════════════════ */

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* Brand Colours */
  --color-primary: #520120;
  --color-primary-light: #6b1a3a;
  --color-primary-dark: #3a0017;
  --color-teal: #08403E;
  --color-teal-light: #0d5c59;
  --color-teal-dark: #052c2b;
  --color-olive: #706513;
  --color-amber: #B57114;
  --color-amber-light: #d4891f;
  --color-rust: #962B09;
  --color-cream: #FAF7F2;
  --color-cream-dark: #F0EBE3;
  --color-text: #1A1A1A;
  --color-text-muted: #5A5A5A;
  --color-text-light: #8A8A8A;
  --color-white: #FFFFFF;
  --color-border: #E5E0D8;
  --color-border-light: #F0EBE3;

  /* Typography */
  --font-latin: 'Poppins', 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-arabic: 'Scheherazade New', 'Amiri', 'Noto Naskh Arabic', serif;

  /* Type Scale */
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.8125rem);
  --text-sm: clamp(0.8125rem, 0.78rem + 0.2vw, 0.875rem);
  --text-base: clamp(0.9375rem, 0.9rem + 0.2vw, 1rem);
  --text-lg: clamp(1.0625rem, 1rem + 0.35vw, 1.1875rem);
  --text-xl: clamp(1.25rem, 1.1rem + 0.75vw, 1.625rem);
  --text-2xl: clamp(1.5rem, 1.2rem + 1.5vw, 2.25rem);
  --text-3xl: clamp(1.875rem, 1.2rem + 3vw, 3.25rem);
  --text-hero: clamp(2.25rem, 1rem + 5vw, 4.5rem);

  /* Spacing */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;

  /* Radius */
  --radius-sm: 0.375rem;
  --radius-md: 0.625rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(26,26,26,0.06);
  --shadow-md: 0 4px 16px rgba(26,26,26,0.08);
  --shadow-lg: 0 12px 40px rgba(26,26,26,0.12);
  --shadow-xl: 0 24px 60px rgba(26,26,26,0.16);

  /* Transitions */
  --transition-fast: 150ms cubic-bezier(0.16, 1, 0.3, 1);
  --transition-base: 250ms cubic-bezier(0.16, 1, 0.3, 1);
  --transition-slow: 400ms cubic-bezier(0.16, 1, 0.3, 1);

  /* Layout */
  --content-max: 1200px;
  --content-narrow: 800px;
  --nav-height: 72px;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-height) + var(--space-4));
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* --- Page Load Animation --- */
body {
  font-family: var(--font-latin);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--color-text);
  background-color: var(--color-cream);
  min-height: 100dvh;
  overflow-x: hidden;
  opacity: 0;
  transition: opacity 0.4s ease;
}

body.page-loaded {
  opacity: 1;
}

/* RTL Support */
[dir="rtl"] body {
  font-family: var(--font-arabic);
}

[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] h3,
[dir="rtl"] h4, [dir="rtl"] h5, [dir="rtl"] h6 {
  font-family: var(--font-arabic);
}

[dir="rtl"] .nav-link, [dir="rtl"] .btn,
[dir="rtl"] .card, [dir="rtl"] .footer {
  font-family: var(--font-arabic);
}

img, picture, video, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; background: none; border: none; font: inherit; }
ul, ol { list-style: none; }
input, textarea, select { font: inherit; }

h1, h2, h3, h4, h5, h6 {
  line-height: 1.2;
  font-weight: 600;
  color: var(--color-text);
  text-wrap: balance;
}

p { text-wrap: pretty; max-width: 72ch; }

::selection {
  background: rgba(82, 1, 32, 0.15);
  color: var(--color-text);
}

:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* --- Utility Classes --- */
.container {
  width: 100%;
  max-width: var(--content-max);
  margin: 0 auto;
  padding-inline: var(--space-6);
}

.container-narrow {
  max-width: var(--content-narrow);
}

.section {
  padding-block: clamp(var(--space-12), 8vw, var(--space-24));
  position: relative;
}

.section-sm {
  padding-block: clamp(var(--space-8), 5vw, var(--space-16));
}

.text-center { text-align: center; }
.text-muted { color: var(--color-text-muted); }
.text-light { color: var(--color-text-light); }

/* --- Section Divider --- */
.section + .section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, var(--color-amber), var(--color-primary));
  border-radius: 2px;
  opacity: 0.3;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  font-size: var(--text-sm);
  font-weight: 600;
  border-radius: var(--radius-md);
  transition: all var(--transition-base);
  white-space: nowrap;
  text-decoration: none;
  line-height: 1.4;
}

.btn-primary {
  background: var(--color-primary);
  color: var(--color-white);
  box-shadow: 0 2px 8px rgba(82, 1, 32, 0.25);
}
.btn-primary:hover {
  background: var(--color-primary-light);
  box-shadow: 0 4px 16px rgba(82, 1, 32, 0.35);
  transform: translateY(-2px) scale(1.02);
}

.btn-secondary {
  background: var(--color-teal);
  color: var(--color-white);
  box-shadow: 0 2px 8px rgba(8, 64, 62, 0.25);
}
.btn-secondary:hover {
  background: var(--color-teal-light);
  box-shadow: 0 4px 16px rgba(8, 64, 62, 0.35);
  transform: translateY(-2px) scale(1.02);
}

.btn-outline {
  background: transparent;
  color: var(--color-primary);
  border: 2px solid var(--color-primary);
}
.btn-outline:hover {
  background: var(--color-primary);
  color: var(--color-white);
  transform: translateY(-2px) scale(1.02);
}

.btn-ghost {
  background: transparent;
  color: var(--color-teal);
  padding: var(--space-2) var(--space-4);
}
.btn-ghost:hover {
  background: rgba(8, 64, 62, 0.06);
}

.btn-lg {
  padding: var(--space-4) var(--space-8);
  font-size: var(--text-base);
  border-radius: var(--radius-lg);
}

.btn-sm {
  padding: var(--space-2) var(--space-4);
  font-size: var(--text-xs);
}

.btn-full {
  width: 100%;
}

/* Button focus states */
.btn:focus-visible {
  outline: 2px solid var(--color-amber);
  outline-offset: 3px;
}

/* --- Navigation --- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  z-index: 100;
  background: rgba(250, 247, 242, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid transparent;
  transition: all var(--transition-base);
}

.navbar.scrolled {
  border-bottom-color: var(--color-border);
  box-shadow: var(--shadow-sm);
}

.navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: var(--content-max);
  margin: 0 auto;
  padding-inline: var(--space-6);
}

.navbar-logo {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xl);
  font-weight: 700;
  color: var(--color-primary);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.navbar-logo svg {
  width: 36px;
  height: 36px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

.nav-link {
  padding: var(--space-2) var(--space-3);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text-muted);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
}

.nav-link:hover, .nav-link.active {
  color: var(--color-primary);
  background: rgba(82, 1, 32, 0.05);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

/* Language Toggle (legacy - kept for compatibility) */
.lang-toggle { display: none; }

/* Language Dropdown */
.lang-dropdown {
  position: relative;
  z-index: 100;
}

.lang-dropdown-toggle {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  font-size: var(--text-xs);
  font-weight: 600;
  border-radius: var(--radius-md);
  background: var(--color-cream-dark);
  color: var(--color-text);
  cursor: pointer;
  transition: all var(--transition-fast);
  border: 1px solid transparent;
  min-width: 64px;
  justify-content: center;
}

.lang-dropdown-toggle:hover {
  background: var(--color-cream);
  border-color: var(--color-border);
}

.lang-dropdown-toggle[aria-expanded="true"] {
  background: var(--color-white);
  border-color: var(--color-border);
  box-shadow: var(--shadow-sm);
}

.lang-dropdown-toggle[aria-expanded="true"] .lang-chevron {
  transform: rotate(180deg);
}

.lang-chevron {
  transition: transform var(--transition-fast);
  flex-shrink: 0;
}

.lang-dropdown-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 140px;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: var(--space-1);
  list-style: none;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: all var(--transition-fast);
}

.lang-dropdown-menu.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.lang-dropdown-menu li {
  padding: var(--space-2) var(--space-3);
  font-size: var(--text-sm);
  font-weight: 500;
  cursor: pointer;
  border-radius: calc(var(--radius-md) - 2px);
  transition: all var(--transition-fast);
  color: var(--color-text);
}

.lang-dropdown-menu li:hover {
  background: var(--color-cream);
  color: var(--color-primary);
}

.lang-dropdown-menu li.active {
  background: rgba(82,1,32,0.06);
  color: var(--color-primary);
  font-weight: 600;
}

[dir="rtl"] .lang-dropdown-menu {
  right: auto;
  left: 0;
}

/* Mobile language dropdown */
.mobile-lang-dropdown {
  margin-top: var(--space-4);
}

.mobile-lang-dropdown .lang-dropdown-menu {
  position: static;
  opacity: 1;
  visibility: visible;
  transform: none;
  box-shadow: none;
  border: 1px solid var(--color-border-light);
  display: none;
}

.mobile-lang-dropdown .lang-dropdown-menu.open {
  display: block;
}

/* Mobile Menu */
.mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: var(--space-2);
  cursor: pointer;
}

.mobile-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: all var(--transition-base);
  transform-origin: center;
}

.mobile-toggle.is-active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.mobile-toggle.is-active span:nth-child(2) {
  opacity: 0;
}
.mobile-toggle.is-active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

.mobile-menu {
  position: fixed;
  top: var(--nav-height);
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--color-cream);
  padding: var(--space-6);
  z-index: 99;
  flex-direction: column;
  gap: var(--space-2);
  overflow-y: auto;
  transform: translateY(-20px);
  opacity: 0;
  pointer-events: none;
  transition: transform var(--transition-base), opacity var(--transition-base);
  display: flex;
}

.mobile-menu.open {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.mobile-menu .nav-link {
  font-size: var(--text-lg);
  padding: var(--space-4) var(--space-4);
  border-bottom: 1px solid var(--color-border-light);
}

@media (max-width: 960px) {
  .nav-links { display: none; }
  .nav-actions .btn { display: none; }
  .mobile-toggle { display: flex; }
}

/* --- Hero Section --- */
.hero {
  position: relative;
  min-height: 85vh;
  display: flex;
  align-items: center;
  padding-top: var(--nav-height);
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(145deg, var(--color-teal) 0%, var(--color-teal-dark) 40%, var(--color-primary-dark) 100%);
  z-index: 0;
}

/* Islamic Geometric Pattern for Hero */
.hero-pattern {
  position: absolute;
  inset: 0;
  opacity: 0.07;
  background-image:
    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='none' stroke='%23ffffff' stroke-width='0.8'%3E%3Cpath d='M30 0L60 30L30 60L0 30z'/%3E%3Ccircle cx='30' cy='30' r='10'/%3E%3Cpath d='M30 5L55 30L30 55L5 30z'/%3E%3Ccircle cx='30' cy='30' r='18'/%3E%3Cpath d='M15 0L30 15L15 30L0 15z'/%3E%3Cpath d='M45 0L60 15L45 30L30 15z'/%3E%3Cpath d='M15 30L30 45L15 60L0 45z'/%3E%3Cpath d='M45 30L60 45L45 60L30 45z'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 60px 60px;
  z-index: 1;
  animation: patternDrift 60s linear infinite;
}

@keyframes patternDrift {
  from { background-position: 0 0; }
  to { background-position: 60px 60px; }
}

/* Hero gradient overlay for text readability */
.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(0,0,0,0.15) 100%);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: var(--content-max);
  margin: 0 auto;
  padding: var(--space-12) var(--space-6);
  color: var(--color-white);
}

/* Hero text entrance animations */
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 500;
  color: rgba(255,255,255,0.9);
  margin-bottom: var(--space-6);
  backdrop-filter: blur(8px);
  animation: heroFadeUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.1s both;
}

.hero h1 {
  font-size: var(--text-hero);
  font-weight: 700;
  color: var(--color-white);
  margin-bottom: var(--space-6);
  max-width: 16ch;
  letter-spacing: -0.03em;
  line-height: 1.08;
  animation: heroFadeUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.2s both;
}

.hero-subtitle {
  font-size: var(--text-lg);
  color: rgba(255,255,255,0.85);
  margin-bottom: var(--space-8);
  max-width: 52ch;
  line-height: 1.6;
  animation: heroFadeUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.35s both;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  animation: heroFadeUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.5s both;
}

.hero .btn-primary {
  background: var(--color-amber);
  box-shadow: 0 4px 20px rgba(181, 113, 20, 0.4);
}
.hero .btn-primary:hover {
  background: var(--color-amber-light);
  box-shadow: 0 6px 28px rgba(181, 113, 20, 0.5);
}

.hero .btn-outline {
  border-color: rgba(255,255,255,0.5);
  color: var(--color-white);
}
.hero .btn-outline:hover {
  background: rgba(255,255,255,0.12);
  border-color: var(--color-white);
}

.hero-stats {
  display: flex;
  gap: var(--space-10);
  margin-top: var(--space-12);
  padding-top: var(--space-8);
  border-top: 1px solid rgba(255,255,255,0.15);
  animation: heroFadeUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.65s both;
}

.hero-stat-value {
  font-size: var(--text-2xl);
  font-weight: 700;
  color: var(--color-amber);
}

.hero-stat-label {
  font-size: var(--text-xs);
  color: rgba(255,255,255,0.7);
  margin-top: var(--space-1);
}

@keyframes heroFadeUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 640px) {
  .hero { min-height: 75vh; }
  .hero-stats { flex-wrap: wrap; gap: var(--space-6); }
}

/* --- Section Headers --- */
.section-header {
  margin-bottom: clamp(var(--space-8), 4vw, var(--space-12));
}

.section-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-amber);
  margin-bottom: var(--space-3);
}

.section-label::before {
  content: '';
  width: 24px;
  height: 2px;
  background: var(--color-amber);
  border-radius: 1px;
}

[dir="rtl"] .section-label::before {
  order: 1;
}

.section-title {
  font-size: var(--text-2xl);
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: var(--space-4);
  letter-spacing: -0.02em;
}

.section-desc {
  font-size: var(--text-base);
  color: var(--color-text-muted);
  max-width: 60ch;
  line-height: 1.7;
}

.section-header.center {
  text-align: center;
}

.section-header.center .section-label::before {
  display: none;
}

.section-header.center .section-desc {
  margin-inline: auto;
}

.section-cta {
  text-align: center;
  margin-top: var(--space-10);
}

/* --- Cards --- */
.card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border-light);
  padding: var(--space-6);
  transition: all var(--transition-base);
  box-shadow: var(--shadow-sm);
}

.card:hover {
  box-shadow: var(--shadow-lg);
  border-color: var(--color-border);
  transform: translateY(-4px);
}

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-4);
  font-size: 1.5rem;
}

.card-icon.color-burgundy, .color-burgundy { background: rgba(82,1,32,0.08); color: var(--color-primary); }
.card-icon.color-teal, .color-teal { background: rgba(8,64,62,0.08); color: var(--color-teal); }
.card-icon.color-amber, .color-amber { background: rgba(181,113,20,0.08); color: var(--color-amber); }
.card-icon.color-olive, .color-olive { background: rgba(112,101,19,0.08); color: var(--color-olive); }
.card-icon.color-rust, .color-rust { background: rgba(150,43,9,0.08); color: var(--color-rust); }

/* Legacy color classes */
.card-icon.burgundy { background: rgba(82,1,32,0.08); color: var(--color-primary); }
.card-icon.teal { background: rgba(8,64,62,0.08); color: var(--color-teal); }
.card-icon.amber { background: rgba(181,113,20,0.08); color: var(--color-amber); }
.card-icon.olive { background: rgba(112,101,19,0.08); color: var(--color-olive); }
.card-icon.rust { background: rgba(150,43,9,0.08); color: var(--color-rust); }

.card-title {
  font-size: var(--text-lg);
  font-weight: 600;
  margin-bottom: var(--space-2);
}

.card-desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* --- Grid Layouts --- */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-6);
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-6);
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-6);
}

@media (max-width: 960px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

/* --- Feature / Value Prop Grid --- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-8);
}

@media (max-width: 960px) { .features-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .features-grid { grid-template-columns: 1fr; } }

/* --- Steps / How It Works --- */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-8);
  position: relative;
}

.steps::before {
  content: '';
  position: absolute;
  top: 32px;
  left: 80px;
  right: 80px;
  height: 2px;
  background: linear-gradient(90deg, var(--color-amber), var(--color-teal), var(--color-primary));
  z-index: 0;
}

[dir="rtl"] .steps::before {
  background: linear-gradient(270deg, var(--color-amber), var(--color-teal), var(--color-primary));
}

.step {
  text-align: center;
  position: relative;
  z-index: 1;
}

.step-number {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-xl);
  font-weight: 700;
  margin: 0 auto var(--space-4);
  background: var(--color-white);
  border: 3px solid var(--color-amber);
  color: var(--color-amber);
  box-shadow: var(--shadow-md);
}

.step-title {
  font-size: var(--text-lg);
  font-weight: 600;
  margin-bottom: var(--space-2);
}

.step-desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  max-width: 28ch;
  margin-inline: auto;
}

@media (max-width: 640px) {
  .steps { grid-template-columns: 1fr; gap: var(--space-8); }
  .steps::before { display: none; }
}

/* --- Course Cards --- */
.course-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border-light);
  overflow: hidden;
  transition: all var(--transition-base);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
}

.course-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-6px);
}

.course-card-header {
  padding: var(--space-5) var(--space-6);
  background: var(--color-teal);
  color: var(--color-white);
}

.course-card-header.course-header-burgundy, .course-card-header.burgundy { background: var(--color-primary); }
.course-card-header.course-header-amber, .course-card-header.amber { background: var(--color-amber); }
.course-card-header.course-header-olive, .course-card-header.olive { background: var(--color-olive); }
.course-card-header.course-header-rust, .course-card-header.rust { background: var(--color-rust); }
.course-card-header.course-header-teal, .course-card-header.teal { background: var(--color-teal); }

.course-card-body {
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  flex: 1;
}

.course-card-body > .btn,
.course-card-body > a.btn {
  margin-top: auto;
}

.course-card-icon {
  margin-bottom: var(--space-3);
}

.course-card-title {
  font-size: var(--text-lg);
  font-weight: 700;
  margin-bottom: var(--space-1);
}

.course-card-tagline {
  font-size: var(--text-xs);
  opacity: 0.8;
}

.course-card-level {
  font-size: var(--text-xs);
  opacity: 0.8;
}

.course-card-desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.6;
  margin-bottom: var(--space-4);
}

.course-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-4);
  flex-wrap: wrap;
  gap: var(--space-2);
}

.course-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-bottom: var(--space-4);
}

.course-meta-item {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

.course-price {
  font-size: var(--text-xl);
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: var(--space-4);
}

.course-price span {
  font-size: var(--text-sm);
  font-weight: 400;
  color: var(--color-text-muted);
}

.course-price-custom {
  font-size: var(--text-lg);
}

.level-badge {
  display: inline-flex;
  padding: var(--space-1) var(--space-3);
  font-size: var(--text-xs);
  font-weight: 600;
  border-radius: var(--radius-full);
  background: rgba(8,64,62,0.08);
  color: var(--color-teal);
}

.level-badge.level-all { background: rgba(8,64,62,0.08); color: var(--color-teal); }
.level-badge.level-beginner { background: rgba(181,113,20,0.08); color: var(--color-amber); }
.level-badge.level-pro { background: rgba(82,1,32,0.08); color: var(--color-primary); }

.price-per {
  font-size: var(--text-sm);
  font-weight: 400;
  color: var(--color-text-muted);
}

/* --- Teacher Cards --- */
.teacher-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border-light);
  overflow: hidden;
  transition: all var(--transition-base);
  text-align: center;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
}

.teacher-info {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.teacher-info > .btn,
.teacher-info > a.btn {
  margin-top: auto;
}

.teacher-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-6px);
}

.teacher-avatar {
  width: 100%;
  aspect-ratio: 1;
  background: linear-gradient(135deg, var(--color-teal), var(--color-primary));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: var(--color-white);
}

.teacher-info {
  padding: var(--space-5) var(--space-4);
}

.teacher-name {
  font-size: var(--text-lg);
  font-weight: 600;
  margin-bottom: var(--space-1);
}

.teacher-dialect {
  font-size: var(--text-xs);
  color: var(--color-amber);
  font-weight: 600;
  margin-bottom: var(--space-2);
}

.teacher-bio {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin-bottom: var(--space-4);
  line-height: 1.5;
}

.teacher-rating {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-1);
  font-size: var(--text-sm);
  color: var(--color-amber);
  margin-bottom: var(--space-4);
}

/* --- Promise Section (replaces Testimonials) --- */
.promise-wrapper {
  position: relative;
  overflow: hidden;
}

.promise-track {
  display: flex;
  gap: var(--space-6);
  transition: transform var(--transition-slow);
}

.promise-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  border: 1px solid var(--color-border-light);
  min-width: 100%;
  flex-shrink: 0;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
}

.promise-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

@media (min-width: 641px) {
  .promise-card { min-width: calc(50% - var(--space-3)); }
}

@media (min-width: 961px) {
  .promise-card { min-width: calc(33.333% - var(--space-4)); }
}

.promise-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-4);
}

.promise-title {
  font-size: var(--text-lg);
  font-weight: 600;
  margin-bottom: var(--space-2);
}

.promise-desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.7;
}

.promise-controls {
  display: flex;
  justify-content: center;
  gap: var(--space-4);
  margin-top: var(--space-6);
}

.promise-prev, .promise-next {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 2px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-muted);
  transition: all var(--transition-fast);
  background: var(--color-white);
}

.promise-prev:hover, .promise-next:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
  box-shadow: var(--shadow-sm);
}

/* --- Email Capture --- */
.email-capture {
  background: linear-gradient(135deg, var(--color-teal) 0%, var(--color-teal-dark) 100%);
  border-radius: var(--radius-xl);
  padding: clamp(var(--space-8), 5vw, var(--space-12));
  color: var(--color-white);
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

/* Decorative pattern on email capture */
.email-capture::before {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' stroke='%23ffffff' stroke-width='0.5'%3E%3Cpath d='M20 0L40 20L20 40L0 20z'/%3E%3Ccircle cx='20' cy='20' r='8'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 40px 40px;
  pointer-events: none;
}

.email-capture-inner {
  position: relative;
  z-index: 1;
}

.email-capture-icon {
  margin-bottom: var(--space-4);
}

.email-capture h2, .email-capture h3 {
  color: var(--color-white);
  font-size: var(--text-2xl);
  margin-bottom: var(--space-3);
}

.email-capture p {
  color: rgba(255,255,255,0.8);
  margin-bottom: var(--space-6);
  margin-inline: auto;
}

.email-capture-note {
  font-size: var(--text-xs);
  color: rgba(255,255,255,0.5);
  margin-top: var(--space-3);
  margin-bottom: 0;
}

.email-form {
  display: flex;
  gap: var(--space-3);
  max-width: 480px;
  margin-inline: auto;
}

.email-form input {
  flex: 1;
  padding: var(--space-3) var(--space-4);
  border: 2px solid rgba(255,255,255,0.3);
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.1);
  color: var(--color-white);
  font-size: var(--text-sm);
}

.email-form input::placeholder { color: rgba(255,255,255,0.5); }

.email-form input:focus {
  outline: none;
  border-color: var(--color-amber);
  background: rgba(255,255,255,0.15);
}

.email-form .btn { flex-shrink: 0; }

@media (max-width: 480px) {
  .email-form { flex-direction: column; }
}

/* --- Pricing Table --- */
.pricing-toggle {
  display: flex;
  justify-content: center;
  gap: var(--space-2);
  margin-bottom: var(--space-10);
  background: var(--color-cream-dark);
  border-radius: var(--radius-full);
  padding: 4px;
  width: fit-content;
  margin-inline: auto;
}

.pricing-toggle-btn {
  padding: var(--space-2) var(--space-6);
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text-muted);
  transition: all var(--transition-fast);
}

.pricing-toggle-btn.active {
  background: var(--color-white);
  color: var(--color-primary);
  box-shadow: var(--shadow-sm);
}

.pricing-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border-light);
  padding: var(--space-8);
  text-align: center;
  transition: all var(--transition-base);
  position: relative;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
}

.pricing-card > .btn,
.pricing-card > a.btn {
  margin-top: auto;
}

.pricing-card.featured {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-lg);
  transform: scale(1.02);
}

.pricing-card.featured::before {
  content: attr(data-badge);
  position: absolute;
  top: calc(-1 * var(--space-3));
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-primary);
  color: var(--color-white);
  font-size: var(--text-xs);
  font-weight: 600;
  padding: var(--space-1) var(--space-4);
  border-radius: var(--radius-full);
  white-space: nowrap;
}

.pricing-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.pricing-card.featured:hover {
  transform: scale(1.02) translateY(-4px);
}

.pricing-name {
  font-size: var(--text-lg);
  font-weight: 700;
  margin-bottom: var(--space-2);
}

.pricing-amount {
  font-size: var(--text-3xl);
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: var(--space-1);
}

.pricing-period {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  margin-bottom: var(--space-6);
}

.pricing-features {
  text-align: start;
  margin-bottom: var(--space-6);
  flex: 1;
}

.pricing-feature {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
  padding: var(--space-2) 0;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

.pricing-feature svg {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  color: var(--color-teal);
  margin-top: 2px;
}

/* --- FAQ Accordion --- */
.faq-list { max-width: var(--content-narrow); margin-inline: auto; }

.faq-item {
  border-bottom: 1px solid var(--color-border-light);
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-5) 0;
  font-size: var(--text-base);
  font-weight: 600;
  color: var(--color-text);
  text-align: start;
  cursor: pointer;
  transition: color var(--transition-fast);
}

.faq-question:hover { color: var(--color-primary); }

.faq-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  transition: transform var(--transition-base);
  color: var(--color-text-light);
}

.faq-item.open .faq-icon { transform: rotate(45deg); color: var(--color-primary); }

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--transition-slow);
}

.faq-answer-inner {
  padding-bottom: var(--space-5);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.7;
}

/* --- Contact Form --- */
.contact-form {
  display: grid;
  gap: var(--space-5);
}

.form-group { display: flex; flex-direction: column; gap: var(--space-2); }

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-5);
}

@media (max-width: 640px) { .form-row { grid-template-columns: 1fr; } }

.form-label {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
}

.form-input, .form-select, .form-textarea {
  padding: var(--space-3) var(--space-4);
  border: 2px solid var(--color-border);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  background: var(--color-white);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  width: 100%;
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(82, 1, 32, 0.1);
}

.form-textarea {
  resize: vertical;
  min-height: 120px;
}

/* --- Footer --- */
/* ═══════════════════════════════════════════════════════════════
   FOOTER — Modern Redesign with Teal Glow
   ═══════════════════════════════════════════════════════════════ */
.footer {
  background: linear-gradient(180deg, var(--color-teal-dark) 0%, #021f1e 100%);
  color: var(--color-white);
  padding-block: var(--space-16) var(--space-8);
  position: relative;
  overflow: hidden;
}

.footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(8,64,62,0.5), rgba(181,113,20,0.3), transparent);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.8fr 1fr 1fr 1fr;
  gap: var(--space-10);
  margin-bottom: var(--space-12);
}

@media (max-width: 960px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .footer-grid { grid-template-columns: 1fr; gap: var(--space-8); } }

.footer-logo-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  color: var(--color-white);
  text-decoration: none;
  margin-bottom: var(--space-3);
}

.footer-logo-text {
  font-size: var(--text-lg);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.footer-desc {
  color: rgba(255,255,255,0.6);
  font-size: var(--text-sm);
  line-height: 1.7;
  max-width: 32ch;
  margin-bottom: var(--space-5);
}

.footer-brand p {
  color: rgba(255,255,255,0.6);
  font-size: var(--text-sm);
  margin-top: var(--space-4);
  line-height: 1.7;
  max-width: 36ch;
}

.footer-heading {
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: var(--space-5);
  color: rgba(255,255,255,0.4);
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-link {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) 0;
  font-size: var(--text-sm);
  color: rgba(255,255,255,0.7);
  transition: color var(--transition-fast), text-shadow var(--transition-fast), padding-inline-start var(--transition-fast);
  text-decoration: none;
}

.footer-link:hover {
  color: var(--color-white);
  text-shadow: 0 0 12px rgba(8,64,62,0.6), 0 0 24px rgba(8,64,62,0.3);
  padding-inline-start: var(--space-2);
}

.footer-link-icon {
  flex-shrink: 0;
  opacity: 0.7;
  transition: opacity var(--transition-fast);
}

.footer-link:hover .footer-link-icon {
  opacity: 1;
}

.footer-socials {
  display: flex;
  gap: var(--space-3);
  margin-top: var(--space-5);
}

.footer-social {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
  color: rgba(255,255,255,0.6);
}

.footer-social:hover {
  background: rgba(8,64,62,0.4);
  border-color: rgba(8,64,62,0.6);
  color: var(--color-white);
  box-shadow: 0 0 16px rgba(8,64,62,0.4), 0 0 32px rgba(8,64,62,0.15);
  transform: translateY(-2px);
}

.footer-bottom {
  padding-top: var(--space-8);
  border-top: 1px solid rgba(255,255,255,0.06);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-4);
}

.footer-bottom p {
  font-size: var(--text-xs);
  color: rgba(255,255,255,0.4);
}

.footer-tagline {
  font-size: var(--text-xs);
  color: rgba(255,255,255,0.3);
  font-style: italic;
}

/* --- WhatsApp Button --- */
.whatsapp-float {
  position: fixed;
  bottom: var(--space-6);
  right: var(--space-6);
  z-index: 90;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #25D366;
  color: var(--color-white);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
  transition: all var(--transition-base);
  animation: whatsappEntrance 0.6s cubic-bezier(0.16, 1, 0.3, 1) 1s both, pulse-wp 2s 2s infinite;
}

[dir="rtl"] .whatsapp-float {
  right: auto;
  left: var(--space-6);
}

.whatsapp-float:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 28px rgba(37, 211, 102, 0.5);
}

@keyframes whatsappEntrance {
  from {
    opacity: 0;
    transform: translateY(40px) scale(0.8);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes pulse-wp {
  0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.4); }
  70% { box-shadow: 0 0 0 14px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* --- Islamic Geometric Motif (decorative) --- */
.motif-line {
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg,
    transparent 0%,
    var(--color-olive) 20%,
    var(--color-amber) 50%,
    var(--color-olive) 80%,
    transparent 100%
  );
  opacity: 0.3;
}

/* --- Alternating Section Backgrounds --- */
.bg-white { background: var(--color-white); }
.bg-cream { background: var(--color-cream); }
.bg-teal { background: var(--color-teal); color: var(--color-white); }
.bg-primary { background: var(--color-primary); color: var(--color-white); }

/* --- Badge / Tag --- */
.badge {
  display: inline-flex;
  align-items: center;
  padding: var(--space-1) var(--space-3);
  font-size: var(--text-xs);
  font-weight: 600;
  border-radius: var(--radius-full);
}

.badge-primary { background: rgba(82,1,32,0.08); color: var(--color-primary); }
.badge-teal { background: rgba(8,64,62,0.08); color: var(--color-teal); }
.badge-amber { background: rgba(181,113,20,0.08); color: var(--color-amber); }

/* --- Filter Bar (Teachers) --- */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-8);
  justify-content: center;
}

.filter-btn {
  padding: var(--space-2) var(--space-4);
  font-size: var(--text-sm);
  font-weight: 500;
  border-radius: var(--radius-full);
  border: 1px solid var(--color-border);
  color: var(--color-text-muted);
  transition: all var(--transition-fast);
}

.filter-btn.active, .filter-btn:hover {
  background: var(--color-primary);
  color: var(--color-white);
  border-color: var(--color-primary);
}

/* --- Scroll Animations --- */
.animate-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.animate-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger children */
.stagger > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: calc(var(--i, 0) * 100ms);
}

.stagger.visible > * {
  opacity: 1;
  transform: translateY(0);
}

/* --- About Page --- */
.values-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-6);
}

@media (max-width: 640px) { .values-grid { grid-template-columns: 1fr; } }

.value-card {
  text-align: center;
  padding: var(--space-8);
}

.value-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-4);
  font-size: 2rem;
}

/* --- Team Cards --- */
.team-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-8);
  max-width: 700px;
  margin-inline: auto;
}

@media (max-width: 640px) { .team-grid { grid-template-columns: 1fr; } }

.team-card {
  text-align: center;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  border: 1px solid var(--color-border-light);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
}

.team-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.team-avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  margin: 0 auto var(--space-4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
}

.team-name {
  font-size: var(--text-lg);
  font-weight: 600;
  margin-bottom: var(--space-1);
}

.team-role {
  font-size: var(--text-sm);
  color: var(--color-amber);
  font-weight: 500;
  margin-bottom: var(--space-3);
}

/* --- Page Header (for inner pages) --- */
.page-header {
  padding-top: calc(var(--nav-height) + var(--space-12));
  padding-bottom: var(--space-12);
  background: linear-gradient(135deg, var(--color-teal) 0%, var(--color-teal-dark) 100%);
  color: var(--color-white);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.page-header::before {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0.05;
  background-image: 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='none' stroke='%23ffffff' stroke-width='0.8'%3E%3Cpath d='M30 0L60 30L30 60L0 30z'/%3E%3Ccircle cx='30' cy='30' r='10'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 60px 60px;
  pointer-events: none;
}

.page-header h1 {
  font-size: var(--text-2xl);
  color: var(--color-white);
  margin-bottom: var(--space-3);
}

.page-header p {
  font-size: var(--text-base);
  color: rgba(255,255,255,0.8);
  margin-inline: auto;
  max-width: 50ch;
}

/* --- Comparison Differentiator --- */
.diff-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-6);
}

@media (max-width: 640px) { .diff-grid { grid-template-columns: 1fr; } }

.diff-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  border-top: 3px solid var(--color-amber);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
}

.diff-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

/* --- Currency Toggle --- */
.currency-toggle {
  display: inline-flex;
  background: var(--color-cream-dark);
  border-radius: var(--radius-full);
  padding: 3px;
}

.currency-btn {
  padding: var(--space-1) var(--space-4);
  font-size: var(--text-xs);
  font-weight: 600;
  border-radius: var(--radius-full);
  transition: all var(--transition-fast);
  color: var(--color-text-muted);
}

.currency-btn.active {
  background: var(--color-white);
  color: var(--color-primary);
  box-shadow: var(--shadow-sm);
}

/* --- Early Bird Banner --- */
.early-bird {
  background: linear-gradient(135deg, var(--color-rust), var(--color-primary));
  color: var(--color-white);
  border-radius: var(--radius-lg);
  padding: var(--space-6) var(--space-8);
  text-align: center;
  margin-bottom: var(--space-10);
}

.early-bird h3 {
  color: var(--color-white);
  font-size: var(--text-xl);
  margin-bottom: var(--space-2);
}

.early-bird p {
  color: rgba(255,255,255,0.85);
  margin-inline: auto;
}

/* ═══════════════════════════════════════════════════════════════
   BLOG PAGE
   ═══════════════════════════════════════════════════════════════ */
.blog-filters {
  display: flex;
  gap: var(--space-2);
  margin-bottom: var(--space-8);
  flex-wrap: wrap;
}

.blog-filter-btn {
  padding: var(--space-2) var(--space-4);
  font-size: var(--text-sm);
  font-weight: 500;
  border-radius: var(--radius-full);
  background: var(--color-white);
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.blog-filter-btn:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.blog-filter-btn.active {
  background: var(--color-primary);
  color: var(--color-white);
  border-color: var(--color-primary);
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-6);
}

@media (max-width: 768px) {
  .blog-grid { grid-template-columns: 1fr; }
}

.blog-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border-light);
  padding: var(--space-6);
  transition: all var(--transition-fast);
}

.blog-card:hover {
  border-color: var(--color-border);
  box-shadow: var(--shadow-md);
}

.blog-card[hidden] {
  display: none;
}

.blog-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-4);
  flex-wrap: wrap;
  gap: var(--space-2);
}

.blog-lang-tag {
  display: inline-block;
  padding: 2px 10px;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: var(--radius-full);
}

.blog-lang-en {
  background: rgba(82,1,32,0.08);
  color: var(--color-primary);
}

.blog-lang-tr {
  background: rgba(8,64,62,0.08);
  color: var(--color-teal);
}

.blog-lang-ar {
  background: rgba(181,113,20,0.08);
  color: var(--color-amber);
}

.blog-meta {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--text-xs);
  color: var(--color-text-light);
}

.blog-reading-time::before {
  content: '\2022';
  margin-inline-end: var(--space-3);
}

.blog-card-title {
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: var(--space-3);
  line-height: 1.4;
}

[dir="rtl"] .blog-card-title {
  font-family: var(--font-arabic);
}

.blog-card-excerpt {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.7;
  margin-bottom: var(--space-4);
}

.blog-read-more-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-primary);
  cursor: pointer;
  transition: all var(--transition-fast);
  background: none;
  border: none;
  padding: 0;
}

.blog-read-more-btn:hover {
  color: var(--color-primary-light);
}

.blog-read-more-btn[aria-expanded="true"] svg {
  transform: rotate(180deg);
}

.blog-read-more-btn svg {
  transition: transform var(--transition-fast);
}

.blog-full-content {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.4s ease;
}

.blog-full-content.open {
  max-height: 3000px;
}

.blog-content-inner {
  padding-top: var(--space-6);
  border-top: 1px solid var(--color-border-light);
  margin-top: var(--space-4);
}

.blog-content-inner p {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.8;
  margin-bottom: var(--space-4);
}

.blog-content-inner h3 {
  font-size: var(--text-base);
  font-weight: 700;
  color: var(--color-text);
  margin-top: var(--space-6);
  margin-bottom: var(--space-3);
}

.blog-content-inner h3:first-child {
  margin-top: 0;
}

[dir="rtl"] .blog-content-inner {
  font-family: var(--font-arabic);
}

/* ═══════════════════════════════════════════════════════════════
   TEAM AVATARS (About page)
   ═══════════════════════════════════════════════════════════════ */
.team-avatar-teal {
  background: linear-gradient(135deg, #08403E, #052c2b);
  color: #FAF7F2;
  font-weight: 700;
}

.team-avatar-amber {
  background: linear-gradient(135deg, #B57114, #d4891f);
  color: #FAF7F2;
  font-weight: 700;
}

.team-desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* ═══════════════════════════════════════════════════════════════
   ANIMATIONS & MICRO-INTERACTIONS
   ═══════════════════════════════════════════════════════════════ */

/* 1. Staggered entrance animations for grid items */
.animate-in:nth-child(1) { transition-delay: 0ms; }
.animate-in:nth-child(2) { transition-delay: 80ms; }
.animate-in:nth-child(3) { transition-delay: 160ms; }
.animate-in:nth-child(4) { transition-delay: 240ms; }
.animate-in:nth-child(5) { transition-delay: 320ms; }
.animate-in:nth-child(6) { transition-delay: 400ms; }

/* 2. Smooth card hover lift */
.course-card,
.pricing-card,
.teacher-card,
.blog-card {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.course-card:hover,
.pricing-card:hover,
.teacher-card:hover,
.blog-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 32px rgba(82,1,32,0.12);
}

.pricing-card.featured:hover {
  transform: scale(1.02) translateY(-6px);
}

/* 3. Button hover animations */
.btn-primary {
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(82,1,32,0.25);
}

/* 4. Nav link underline animation */
.nav-links .nav-link {
  position: relative;
}

.nav-links .nav-link::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: var(--space-3);
  right: var(--space-3);
  height: 2px;
  background: var(--color-primary);
  border-radius: 1px;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.25s ease;
}

[dir="rtl"] .nav-links .nav-link::after {
  transform-origin: right center;
}

.nav-links .nav-link:hover::after,
.nav-links .nav-link.active::after {
  transform: scaleX(1);
}

/* 5. Hero element fade-up with staggered delays */
.hero-badge { animation-delay: 0.1s; }
.hero h1 { animation-delay: 0.2s; }
.hero-subtitle { animation-delay: 0.35s; }
.hero-ctas { animation-delay: 0.5s; }

/* 6. Smooth page transition */
body {
  opacity: 0;
  animation: pageIn 0.4s ease forwards;
}

@keyframes pageIn {
  to { opacity: 1; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .animate-in { opacity: 1; transform: none; }
  .stagger > * { opacity: 1; transform: none; }
  .whatsapp-float { animation: none; }
  body { opacity: 1; }
}


/* ═══════════════════════════════════════════════════════════════
   NEW FOOTER
   ═══════════════════════════════════════════════════════════════ */

.footer-new {
  background: #0A0A0F;
  overflow: hidden;
}

/* Artwork band */
.footer-artwork-band {
  position: relative;
  width: 100%;
  padding: var(--space-10) 0 0;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  overflow: hidden;
}

.footer-artwork-glow {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 200px;
  background: radial-gradient(ellipse at center bottom, rgba(82,1,32,0.25) 0%, transparent 70%);
  pointer-events: none;
}

@keyframes footer-float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

.footer-artwork {
  animation: footer-float 7s ease-in-out infinite;
  width: 100%;
  max-width: 900px;
  opacity: 0;
  transition: opacity 0.8s ease;
}

.footer-artwork.visible {
  opacity: 1;
}

/* Main content */
.footer-main {
  padding: var(--space-10) 0 var(--space-6);
  border-top: 1px solid rgba(255,255,255,0.06);
}

.footer-grid-new {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.2fr;
  gap: var(--space-8);
}

.footer-logo-link {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  text-decoration: none;
  margin-bottom: var(--space-4);
}

.footer-logo-text-new {
  font-size: var(--text-xl);
  font-weight: 700;
  color: #FAF7F2;
  letter-spacing: -0.01em;
}

.footer-desc-new {
  font-size: var(--text-sm);
  color: #9A8E82;
  line-height: 1.7;
  margin-bottom: var(--space-5);
  max-width: 28ch;
}

.footer-socials-new {
  display: flex;
  gap: var(--space-3);
}

.footer-social-new {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  color: #9A8E82;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  text-decoration: none;
}

.footer-social-new:hover {
  background: rgba(181,113,20,0.15);
  border-color: rgba(181,113,20,0.3);
  color: #B57114;
}

.footer-col-new {}

.footer-heading-new {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(255,255,255,0.4);
  margin-bottom: var(--space-4);
}

.footer-links-new {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.footer-link-new {
  font-size: var(--text-sm);
  color: #9A8E82;
  text-decoration: none;
  transition: color 0.2s ease;
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.footer-link-new:hover {
  color: #FAF7F2;
}

.footer-link-wa-new {
  color: #25D366;
}

.footer-link-wa-new:hover {
  color: #25D366;
  opacity: 0.85;
}

.footer-link-icon-new {
  flex-shrink: 0;
  opacity: 0.7;
}

.footer-bottom-new {
  border-top: 1px solid rgba(255,255,255,0.06);
  padding: var(--space-5) 0;
}

.footer-bottom-new .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  flex-wrap: wrap;
}

.footer-bottom-new p {
  font-size: var(--text-xs);
  color: rgba(255,255,255,0.3);
  margin: 0;
}

.footer-tagline-new {
  text-align: right;
}

/* Responsive */
@media (max-width: 900px) {
  .footer-grid-new {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-8) var(--space-6);
  }
  .footer-brand-new {
    grid-column: 1 / -1;
  }
  .footer-desc-new {
    max-width: none;
  }
}

@media (max-width: 480px) {
  .footer-grid-new {
    grid-template-columns: 1fr;
  }
  .footer-bottom-new .container {
    flex-direction: column;
    text-align: center;
  }
  .footer-tagline-new {
    text-align: center;
  }
}

/* ═══════════════════════════════════════════════════════════════
   ENHANCED ANIMATIONS
   ═══════════════════════════════════════════════════════════════ */

/* Base: fade + slide up (existing .animate-in enhanced) */
.animate-in {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.65s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.65s cubic-bezier(0.16, 1, 0.3, 1);
}

.animate-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Slide from left */
.animate-left {
  opacity: 0;
  transform: translateX(-36px);
  transition: opacity 0.65s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.65s cubic-bezier(0.16, 1, 0.3, 1);
}
.animate-left.visible {
  opacity: 1;
  transform: translateX(0);
}

/* Slide from right */
.animate-right {
  opacity: 0;
  transform: translateX(36px);
  transition: opacity 0.65s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.65s cubic-bezier(0.16, 1, 0.3, 1);
}
.animate-right.visible {
  opacity: 1;
  transform: translateX(0);
}

/* Scale up */
.animate-scale {
  opacity: 0;
  transform: scale(0.92);
  transition: opacity 0.55s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.55s cubic-bezier(0.16, 1, 0.3, 1);
}
.animate-scale.visible {
  opacity: 1;
  transform: scale(1);
}

/* Stagger delays for child elements */
.stagger > *:nth-child(1) { transition-delay: 0ms; }
.stagger > *:nth-child(2) { transition-delay: 80ms; }
.stagger > *:nth-child(3) { transition-delay: 160ms; }
.stagger > *:nth-child(4) { transition-delay: 240ms; }
.stagger > *:nth-child(5) { transition-delay: 320ms; }
.stagger > *:nth-child(6) { transition-delay: 400ms; }

/* ── Steps sequential animation ── */
.steps {
  position: relative;
}

.step-item {
  opacity: 0;
  transform: translateY(32px) scale(0.97);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.step-item.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.step-item:nth-child(2) { transition-delay: 0ms; }
.step-item:nth-child(3) { transition-delay: 180ms; }
.step-item:nth-child(4) { transition-delay: 360ms; }

/* Step connector line animation */
.steps-connector {
  position: absolute;
  top: 44px;
  left: calc(16.66% + 22px);
  right: calc(16.66% + 22px);
  height: 2px;
  background: var(--color-border);
  overflow: hidden;
}

.steps-connector::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, var(--color-primary) 0%, var(--color-amber) 100%);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1) 0.3s;
}

.steps-connector.visible::after {
  transform: scaleX(1);
}

/* Step number pulse on visible */
@keyframes step-pulse {
  0% { box-shadow: 0 0 0 0 rgba(82,1,32,0.3); }
  70% { box-shadow: 0 0 0 12px rgba(82,1,32,0); }
  100% { box-shadow: 0 0 0 0 rgba(82,1,32,0); }
}

.step-item.visible .step-number {
  animation: step-pulse 1s ease-out 0.4s;
}

/* ── Section labels slide in ── */
.section-label {
  opacity: 0;
  transform: translateX(-16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.section-label.visible {
  opacity: 1;
  transform: translateX(0);
}

/* ── Feature cards hover lift ── */
.feature-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 40px rgba(0,0,0,0.1);
}

/* ── Course/pricing card hover ── */
.course-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.course-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.1);
}

/* ── Stat counter fade in ── */
.hero-stat {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.hero-stat.visible {
  opacity: 1;
  transform: translateY(0);
}
.hero-stat:nth-child(1) { transition-delay: 600ms; }
.hero-stat:nth-child(2) { transition-delay: 750ms; }
.hero-stat:nth-child(3) { transition-delay: 900ms; }

/* ── Number count-up animation ── */
@keyframes count-up {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ── Promise carousel cards ── */
.promise-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease, opacity 0.3s ease;
}

/* ── Blog card hover ── */
.blog-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.08);
}

/* ── Teacher card hover ── */
.teacher-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.teacher-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.1);
}

/* Respect reduced motion preference */
@media (prefers-reduced-motion: reduce) {
  .animate-in, .animate-left, .animate-right, .animate-scale,
  .step-item, .section-label, .hero-stat {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
    animation: none !important;
  }
}


/* ══════════════════════════════════════════════════════════════
   RESPONSIVE AUDIT FIXES
   ══════════════════════════════════════════════════════════════ */

/* ── Prevent horizontal overflow ── */
html, body {
  max-width: 100vw;
  overflow-x: hidden;
}

img, svg {
  max-width: 100%;
}

/* ── Safari / WebKit fixes ── */

/* Fix for Safari not supporting gap in flex properly in older versions */
.navbar-inner {
  -webkit-gap: unset; /* fallback */
}

/* Fix Safari button appearance */
button, .btn, .currency-btn, .filter-btn, .lang-dropdown-toggle {
  -webkit-appearance: none;
  appearance: none;
}

/* Fix for Safari smooth scroll */
html {
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
}

/* Fix Safari font rendering */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Fix Safari input styling */
input, textarea, select {
  -webkit-appearance: none;
  appearance: none;
  border-radius: var(--radius-md);
}

/* Fix for CSS animation in Safari */
.footer-artwork {
  -webkit-animation: footer-float 7s ease-in-out infinite;
}

@-webkit-keyframes footer-float {
  0%, 100% { -webkit-transform: translateY(0px); transform: translateY(0px); }
  50% { -webkit-transform: translateY(-10px); transform: translateY(-10px); }
}

/* Fix for Safari backdrop-filter */
.navbar.scrolled {
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

/* Fix sticky positioning */
.navbar {
  position: -webkit-sticky;
  position: sticky;
}

/* ── Mobile fixes (max-width: 768px) ── */

@media (max-width: 768px) {
  /* Pricing cards stack properly */
  .pricing-cards {
    grid-template-columns: 1fr !important;
    max-width: 400px;
    margin-inline: auto;
  }

  /* Course cards single column */
  #courses-grid.grid-3 {
    grid-template-columns: 1fr !important;
  }

  /* Feature grid 1-col */
  .features-grid {
    grid-template-columns: 1fr !important;
  }

  /* Teachers grid */
  .teachers-grid {
    grid-template-columns: 1fr !important;
  }

  /* Steps: stack vertically */
  .steps {
    flex-direction: column !important;
    gap: var(--space-8) !important;
    align-items: center;
  }

  .step {
    max-width: 320px;
    width: 100%;
  }

  /* Hide horizontal connector on mobile */
  .steps-connector {
    display: none !important;
  }

  /* Hero section padding */
  .hero-content {
    padding-top: calc(var(--space-10) + 60px);
  }

  /* Filter bar scrollable on mobile */
  .filter-bar {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    flex-wrap: nowrap !important;
    padding-bottom: var(--space-2);
    scrollbar-width: none;
  }
  .filter-bar::-webkit-scrollbar { display: none; }

  /* Currency toggle */
  .currency-toggle {
    justify-content: center;
  }

  /* Promise carousel */
  .promise-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  /* Section padding reduction */
  .section {
    padding-block: var(--space-12) !important;
  }

  /* Page header */
  .page-header {
    padding-top: calc(80px + var(--space-10)) !important;
    padding-bottom: var(--space-10) !important;
  }

  /* Blog cards */
  .blog-grid {
    grid-template-columns: 1fr !important;
  }

  /* Contact form full width */
  .contact-form-grid {
    grid-template-columns: 1fr !important;
  }

  /* About grid */
  .about-grid, .diff-grid {
    grid-template-columns: 1fr !important;
  }

  /* Footer bottom */
  .footer-bottom-new .container {
    text-align: center;
    gap: var(--space-2);
  }

  /* Touch targets */
  .btn, .nav-link, .footer-link-new, .filter-btn, .currency-btn, .faq-question {
    min-height: 44px;
  }
  .lang-dropdown-toggle {
    min-height: 44px;
    padding-inline: var(--space-3);
  }
}

/* ── Mobile fixes (max-width: 480px) ── */

@media (max-width: 480px) {
  /* Typography scale down */
  :root {
    --text-5xl: 2.25rem;
    --text-4xl: 1.875rem;
    --text-3xl: 1.5rem;
    --text-2xl: 1.25rem;
  }

  /* Navbar logo text */
  .navbar-logo {
    font-size: var(--text-lg);
  }

  /* Hero CTA buttons stack */
  .hero-ctas {
    flex-direction: column;
    align-items: stretch !important;
  }

  .hero-ctas .btn {
    width: 100%;
    justify-content: center;
  }

  /* Stats row */
  .hero-stats {
    gap: var(--space-6) !important;
  }

  /* Coupon block padding */
  .coupon-block {
    padding: var(--space-4) var(--space-4) !important;
  }

  /* Coupon row flex direction */
  .coupon-block > div > div[style*="justify-content: space-between"] {
    flex-direction: column !important;
    align-items: flex-start;
    gap: var(--space-2);
  }
}

/* ── RTL (Arabic) fixes for mobile ── */

[dir="rtl"] .hero-ctas {
  flex-direction: row-reverse;
}

[dir="rtl"] .footer-tagline-new {
  text-align: left;
}

@media (max-width: 768px) {
  [dir="rtl"] .hero-ctas {
    flex-direction: column;
  }
  [dir="rtl"] .footer-tagline-new {
    text-align: center;
  }
}
