/* ==========================================================================
   AL-AMEEN (الأمين | အလ်-အမီန်း) — 3D Interactive Landing Page
   Theme: Pure Luminous Pearl & Cobalt Glass ("Glow & Glassy")
   ========================================================================== */

:root {
  /* Core Luminous Pearl Palette */
  --bg-pearl: #f3f7fc;
  --bg-pearl-deep: #e8eff8;
  --bg-surface: rgba(255, 255, 255, 0.74);
  --bg-surface-strong: rgba(255, 255, 255, 0.88);
  --bg-surface-subtle: rgba(255, 255, 255, 0.52);

  /* Brand Cobalt & Sapphire Accents (from App UI) */
  --cobalt-600: #1d4ed8;
  --cobalt-500: #2563eb;
  --cobalt-400: #3b82f6;
  --cobalt-100: #dbeafe;
  --cobalt-50: #eff6ff;
  --cobalt-glow: rgba(37, 99, 235, 0.28);
  --cobalt-soft: rgba(37, 99, 235, 0.1);

  /* Warm Amber / Streak Flame Accents (from Quick Access & Daily Challenge) */
  --amber-500: #f59e0b;
  --amber-400: #fbbf24;
  --amber-100: #fef3c7;
  --amber-50: #fffbeb;
  --amber-glow: rgba(245, 158, 11, 0.22);

  /* Heritage Midnight Navy (from Dictionary.png cover) */
  --navy-900: #0f1a28;
  --navy-800: #152232;
  --gold-400: #f5c26b;

  /* Text Hierarchy */
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #64748b;

  /* Glass Borders & Shadows */
  --glass-border: rgba(255, 255, 255, 0.92);
  --glass-border-subtle: rgba(255, 255, 255, 0.68);
  --glass-outer-ring: rgba(148, 163, 184, 0.16);
  --shadow-glass:
    0 24px 60px -12px rgba(15, 23, 42, 0.08),
    0 8px 24px -4px rgba(37, 99, 235, 0.06),
    inset 0 1px 1px rgba(255, 255, 255, 0.96);
  --shadow-glass-hover:
    0 32px 72px -12px rgba(29, 78, 216, 0.15),
    0 12px 32px -4px rgba(37, 99, 235, 0.1),
    inset 0 1px 2px rgba(255, 255, 255, 1);
  --shadow-cobalt-btn:
    0 14px 32px -6px rgba(29, 78, 216, 0.45),
    0 4px 12px rgba(37, 99, 235, 0.25),
    inset 0 1px 1px rgba(255, 255, 255, 0.35);

  /* Typography */
  --font-sans: 'Plus Jakarta Sans', 'Inter', 'Padauk', 'Noto Sans Myanmar', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-arabic: 'Amiri', 'Readex Pro', 'Noto Naskh Arabic', serif;
  --font-mm: 'Padauk', 'Noto Sans Myanmar', sans-serif;

  /* Radii */
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-pill: 9999px;
}

/* Night Aura Preview Mode for Settings Widget / Optional Global Toggle */
body.night-aura-mode {
  --bg-pearl: #0b1320;
  --bg-pearl-deep: #111d30;
  --bg-surface: rgba(21, 34, 50, 0.72);
  --bg-surface-strong: rgba(26, 42, 62, 0.88);
  --bg-surface-subtle: rgba(21, 34, 50, 0.5);
  --text-primary: #f8fafc;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;
  --glass-border: rgba(255, 255, 255, 0.16);
  --glass-border-subtle: rgba(255, 255, 255, 0.1);
  --glass-outer-ring: rgba(59, 130, 246, 0.22);
  --shadow-glass:
    0 24px 60px -12px rgba(0, 0, 0, 0.45),
    0 8px 24px -4px rgba(37, 99, 235, 0.18),
    inset 0 1px 1px rgba(255, 255, 255, 0.15);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-family: var(--font-sans);
  color: var(--text-primary);
  background: var(--bg-pearl);
  overflow-x: hidden;
}

body {
  background: radial-gradient(circle at 50% 0%, #ffffff 0%, var(--bg-pearl) 55%, var(--bg-pearl-deep) 100%);
  color: var(--text-primary);
  overflow-x: hidden;
  min-height: 100vh;
  transition: background 0.5s ease, color 0.4s ease;
  -webkit-font-smoothing: antialiased;
}

/* ==========================================================================
   AMBIENT LUMINOUS GLOW AURAS & ISLAMIC GEOMETRIC WATERMARK
   ========================================================================== */
.ambient-backdrop {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.aura-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.65;
  transition: all 1.2s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform, background;
}

.aura-blob--cobalt {
  width: 58vw;
  height: 58vw;
  max-width: 780px;
  max-height: 780px;
  top: -12%;
  right: -8%;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.22) 0%, rgba(96, 165, 250, 0.08) 60%, transparent 100%);
}

.aura-blob--amber {
  width: 48vw;
  height: 48vw;
  max-width: 640px;
  max-height: 640px;
  bottom: 5%;
  left: -10%;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.16) 0%, rgba(251, 191, 36, 0.06) 60%, transparent 100%);
}

.aura-blob--center {
  width: 44vw;
  height: 44vw;
  max-width: 600px;
  max-height: 600px;
  top: 28%;
  left: 42%;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.18) 0%, rgba(147, 197, 253, 0.05) 65%, transparent 100%);
}

/* Geometric Arabesque Corner Watermarks (Inspired by Dictionary.png) */
.geometric-ornament {
  position: fixed;
  width: 440px;
  height: 440px;
  pointer-events: none;
  z-index: 0;
  opacity: 0.28;
  transition: transform 0.8s ease, opacity 0.5s ease;
}

.geometric-ornament--top-left {
  top: -110px;
  left: -110px;
  animation: slowSpin 90s linear infinite;
}

.geometric-ornament--bottom-right {
  bottom: -120px;
  right: -120px;
  animation: slowSpinReverse 110s linear infinite;
}

@keyframes slowSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes slowSpinReverse {
  from { transform: rotate(360deg); }
  to { transform: rotate(0deg); }
}

/* ==========================================================================
   FIXED 3D WEBGL STAGE (Three.js)
   ========================================================================== */
#webgl-container {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: 2;
  pointer-events: none;
}

#webgl-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

/* Floating 3D Phone HUD Controls (Flip / Screen Indicator) */
.phone-hud-pill {
  position: fixed;
  right: 28px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 30;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 10px;
  border-radius: var(--radius-pill);
  background: var(--bg-surface);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-glass);
}

.hud-screen-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  display: grid;
  place-items: center;
  position: relative;
  transition: all 0.25s cubic-bezier(0.22, 1, 0.36, 1);
  font-size: 13px;
  font-weight: 700;
}

.hud-screen-btn:hover {
  background: var(--cobalt-50);
  color: var(--cobalt-600);
  transform: scale(1.08);
}

.hud-screen-btn.active {
  background: linear-gradient(135deg, var(--cobalt-500), var(--cobalt-600));
  color: #ffffff;
  box-shadow: 0 6px 16px rgba(37, 99, 235, 0.35);
}

.hud-screen-btn .hud-tooltip {
  position: absolute;
  right: 50px;
  white-space: nowrap;
  padding: 6px 12px;
  border-radius: 10px;
  background: var(--navy-900);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  opacity: 0;
  pointer-events: none;
  transform: translateX(8px);
  transition: all 0.2s ease;
}

.hud-screen-btn:hover .hud-tooltip {
  opacity: 1;
  transform: translateX(0);
}

.hud-divider {
  height: 1px;
  width: 24px;
  margin: 2px auto;
  background: rgba(148, 163, 184, 0.28);
}

/* ==========================================================================
   TOP FLOATING GLASS HEADER (App Header Pill Style)
   ========================================================================== */
.top-glass-nav {
  position: fixed;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  width: min(1240px, calc(100vw - 32px));
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 16px;
  border-radius: var(--radius-pill);
  background: var(--bg-surface-strong);
  backdrop-filter: blur(24px) saturate(190%);
  -webkit-backdrop-filter: blur(24px) saturate(190%);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-glass);
  transition: all 0.35s ease;
}

.brand-pill {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: inherit;
}

/* Logo Medallion: Deep Cobalt-Navy Glass Sphere so white al_ameen.png glows crisply */
.brand-logo-orb {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 25%, #2563eb 0%, #152232 70%, #0f172a 100%);
  display: grid;
  place-items: center;
  box-shadow:
    0 6px 16px rgba(29, 78, 216, 0.32),
    inset 0 1px 2px rgba(255, 255, 255, 0.45);
  border: 1.5px solid rgba(255, 255, 255, 0.8);
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
}

.brand-logo-orb img {
  width: 32px;
  height: 32px;
  object-fit: contain;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.35));
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

.brand-pill:hover .brand-logo-orb img {
  transform: scale(1.1) rotate(-4deg);
}

.brand-text-wrap {
  display: flex;
  flex-direction: column;
}

.brand-title {
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.brand-title-mm {
  font-family: var(--font-mm);
  font-size: 13px;
  font-weight: 700;
  color: var(--amber-500);
  background: var(--amber-50);
  padding: 1px 8px;
  border-radius: 99px;
  border: 1px solid rgba(245, 158, 11, 0.25);
  white-space: nowrap;
}

.brand-subtitle {
  font-size: 12px;
  font-weight: 600;
  color: var(--cobalt-600);
}

.nav-center-links {
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(241, 245, 249, 0.7);
  padding: 4px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.8);
}

body.night-aura-mode .nav-center-links {
  background: rgba(15, 23, 42, 0.6);
  border-color: rgba(255, 255, 255, 0.1);
}

.nav-chip {
  padding: 7px 14px;
  border-radius: var(--radius-pill);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all 0.25s ease;
  white-space: nowrap;
}

.nav-chip:hover {
  color: var(--cobalt-600);
  background: rgba(255, 255, 255, 0.7);
}

.nav-chip.active {
  background: #ffffff;
  color: var(--cobalt-600);
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
}

body.night-aura-mode .nav-chip.active {
  background: var(--cobalt-600);
  color: #ffffff;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Language Switcher Pill (EN | မြန်မာ) */
.lang-switch-pill {
  display: inline-flex;
  align-items: center;
  background: rgba(241, 245, 249, 0.85);
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: var(--radius-pill);
  padding: 3px;
  gap: 2px;
}

body.night-aura-mode .lang-switch-pill {
  background: rgba(15, 23, 42, 0.75);
  border-color: rgba(255, 255, 255, 0.12);
}

.lang-btn {
  border: none;
  background: transparent;
  padding: 6px 11px;
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 700;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: var(--font-sans);
}

.lang-btn.active {
  background: var(--cobalt-600);
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(29, 78, 216, 0.35);
}

/* Circular Icon Button (Like History & Moon Icon on home.jpg) */
.circle-glass-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(203, 213, 225, 0.7);
  background: rgba(248, 250, 252, 0.85);
  color: var(--text-primary);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 0.25s ease;
  box-shadow: inset 0 1px 1px #fff, 0 4px 10px rgba(15, 23, 42, 0.04);
}

body.night-aura-mode .circle-glass-btn {
  background: rgba(30, 41, 59, 0.85);
  border-color: rgba(255, 255, 255, 0.15);
  color: #f8fafc;
}

.circle-glass-btn:hover {
  transform: translateY(-2px);
  border-color: var(--cobalt-400);
  color: var(--cobalt-600);
}

.btn-cobalt-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px;
  border-radius: var(--radius-pill);
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  color: #ffffff;
  font-size: 13.5px;
  font-weight: 700;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: var(--shadow-cobalt-btn);
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.btn-cobalt-pill:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 18px 38px -6px rgba(29, 78, 216, 0.55);
}

/* ==========================================================================
   FLOATING GLASS BOTTOM DOCK (Exact 5-Icon Bar from App Screenshots!)
   ========================================================================== */
.app-bottom-dock {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 45;
  display: flex;
  align-items: center;
  justify-content: space-around;
  width: min(460px, calc(100vw - 32px));
  height: 68px;
  padding: 0 18px;
  border-radius: 40px;
  background: linear-gradient(135deg, rgba(241, 245, 252, 0.86), rgba(228, 236, 248, 0.76));
  backdrop-filter: blur(28px) saturate(200%);
  -webkit-backdrop-filter: blur(28px) saturate(200%);
  border: 1.5px solid rgba(255, 255, 255, 0.95);
  box-shadow:
    0 20px 50px -8px rgba(15, 23, 42, 0.14),
    0 4px 16px rgba(37, 99, 235, 0.08),
    inset 0 1px 2px rgba(255, 255, 255, 1);
}

body.night-aura-mode .app-bottom-dock {
  background: linear-gradient(135deg, rgba(21, 34, 50, 0.88), rgba(15, 23, 42, 0.82));
  border-color: rgba(255, 255, 255, 0.16);
}

.dock-item {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 52px;
  border-radius: 24px;
  color: #334155;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  cursor: pointer;
  border: none;
  background: transparent;
}

body.night-aura-mode .dock-item {
  color: #94a3b8;
}

.dock-item svg {
  width: 24px;
  height: 24px;
  stroke-width: 2;
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), color 0.25s ease;
}

.dock-item:hover {
  color: var(--cobalt-600);
  transform: translateY(-3px);
}

.dock-item.active {
  color: var(--cobalt-600);
}

body.night-aura-mode .dock-item.active {
  color: #60a5fa;
}

.dock-item.active svg {
  transform: translateY(-3px) scale(1.08);
  filter: drop-shadow(0 4px 10px rgba(37, 99, 235, 0.35));
}

/* Signature Blue Dot Under Active Icon (Exact match to App Screenshots) */
.dock-dot {
  position: absolute;
  bottom: 4px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--cobalt-600);
  box-shadow: 0 0 8px var(--cobalt-500);
  opacity: 0;
  transform: scale(0);
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.dock-item.active .dock-dot {
  opacity: 1;
  transform: scale(1);
}

.dock-label-tooltip {
  position: absolute;
  top: -36px;
  padding: 4px 10px;
  border-radius: 8px;
  background: var(--navy-900);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transform: translateY(6px);
  transition: all 0.2s ease;
}

.dock-item:hover .dock-label-tooltip {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   MAIN SCROLLABLE STORY LAYOUT & SECTIONS
   ========================================================================== */
.scroll-content {
  position: relative;
  z-index: 10;
  padding-bottom: 140px;
}

.story-section {
  position: relative;
  min-height: 100vh;
  width: min(1280px, calc(100vw - 40px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  align-items: center;
  gap: 28px;
  padding: 120px 0 90px;
  pointer-events: none; /* Let clicks pass through empty areas to 3D canvas if needed */
}

/* Re-enable pointer events on interactive cards & text columns */
.story-col,
.glass-card,
.interactive-panel {
  pointer-events: auto;
}

.col-left-7 {
  grid-column: 1 / span 6;
  max-width: 590px;
}

.col-left-6 {
  grid-column: 1 / span 6;
  max-width: 590px;
}

.col-right-6 {
  grid-column: 7 / span 6;
  padding-right: 64px;
}

.col-right-7 {
  grid-column: 7 / span 6;
  padding-right: 64px;
}

.col-finale-left {
  grid-column: 1 / span 7;
  max-width: 680px;
}

.col-full {
  grid-column: 1 / -1;
}

/* ==========================================================================
   REUSABLE LIQUID GLASS COMPONENTS
   ========================================================================== */
.glass-card {
  background: var(--bg-surface);
  backdrop-filter: blur(24px) saturate(185%);
  -webkit-backdrop-filter: blur(24px) saturate(185%);
  border: 1.5px solid var(--glass-border);
  outline: 1px solid var(--glass-outer-ring);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-glass);
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s ease;
}

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

.eyebrow-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px;
  border-radius: var(--radius-pill);
  background: var(--bg-surface-strong);
  border: 1px solid var(--glass-border);
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.08);
  font-size: 12.5px;
  font-weight: 700;
  color: var(--cobalt-600);
  margin-bottom: 20px;
}

.eyebrow-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cobalt-500);
  box-shadow: 0 0 10px var(--cobalt-500);
}

.eyebrow-dot--amber {
  background: var(--amber-500);
  box-shadow: 0 0 10px var(--amber-500);
}

.section-heading {
  font-size: clamp(2.25rem, 4vw, 3.6rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  margin-bottom: 18px;
}

body.lang-mm .section-heading {
  font-family: var(--font-mm);
  font-size: clamp(1.75rem, 2.65vw, 2.45rem);
  line-height: 1.52;
  letter-spacing: 0;
}

body.lang-mm .section-lead {
  font-family: var(--font-mm);
  line-height: 1.85;
}

.section-heading .gradient-cobalt {
  background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 50%, #0ea5e9 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.section-heading .gradient-amber {
  background: linear-gradient(135deg, #d97706 0%, #f59e0b 60%, #fbbf24 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.section-lead {
  font-size: clamp(1.02rem, 1.25vw, 1.16rem);
  line-height: 1.68;
  color: var(--text-secondary);
  margin-bottom: 28px;
  max-width: 58ch;
}

/* ==========================================================================
   CHAPTER 1: HERO SECTION (Home Screen + Quick Access + Streak)
   ========================================================================== */
.hero-bilingual-banner {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 10px 18px;
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(15, 26, 40, 0.94), rgba(29, 78, 216, 0.9));
  color: #ffffff;
  margin-bottom: 22px;
  box-shadow: 0 14px 34px -8px rgba(15, 26, 40, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.22);
}

.hero-bilingual-banner img {
  width: 38px;
  height: 38px;
  object-fit: contain;
}

.hero-bilingual-text {
  display: flex;
  flex-direction: column;
}

.hero-mm-gold {
  font-family: var(--font-mm);
  font-size: 16px;
  font-weight: 700;
  color: var(--gold-400);
  line-height: 1.3;
}

.hero-mm-sub {
  font-family: var(--font-mm);
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.88);
}

.hero-cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-bottom: 34px;
}

.btn-glass-secondary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 13px 22px;
  border-radius: var(--radius-pill);
  background: var(--bg-surface-strong);
  border: 1.5px solid var(--glass-border);
  box-shadow: var(--shadow-glass);
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.25s ease;
}

.btn-glass-secondary:hover {
  transform: translateY(-2px);
  border-color: var(--cobalt-400);
  color: var(--cobalt-600);
}

/* Quick Access 4-Card Row (Mirrors home.jpg Quick Access) */
.quick-access-label {
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.quick-access-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}

.qa-card {
  padding: 16px 12px;
  border-radius: 22px;
  background: var(--bg-surface-strong);
  border: 1.5px solid var(--glass-border);
  box-shadow: var(--shadow-glass);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  position: relative;
  overflow: hidden;
}

.qa-card::before {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0.35;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.qa-card--saved::before {
  background: radial-gradient(circle at 50% 35%, rgba(251, 191, 36, 0.25), transparent 70%);
}
.qa-card--rules::before {
  background: radial-gradient(circle at 50% 35%, rgba(245, 158, 11, 0.32), transparent 75%);
}
.qa-card--team::before {
  background: radial-gradient(circle at 50% 35%, rgba(37, 99, 235, 0.25), transparent 70%);
}
.qa-card--donate::before {
  background: radial-gradient(circle at 50% 35%, rgba(244, 63, 94, 0.22), transparent 70%);
}

.qa-card:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: var(--shadow-glass-hover);
}

.qa-icon-3d {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-size: 26px;
  filter: drop-shadow(0 8px 12px rgba(15, 23, 42, 0.14));
}

.qa-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-primary);
}

/* Learning Progress Strip (Mirrors home.jpg "Your Learning Progress") */
.progress-overview-card {
  padding: 20px 24px;
  border-radius: 26px;
}

.progress-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.progress-header-left {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  font-size: 15px;
}

.icon-circle-blue {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--cobalt-100);
  color: var(--cobalt-600);
  display: grid;
  place-items: center;
}

.streak-badge-amber {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
  border: 1px solid #f59e0b;
  color: #b45309;
  font-size: 12.5px;
  font-weight: 700;
}

.progress-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: rgba(255, 255, 255, 0.65);
  border-radius: 18px;
  padding: 14px 8px;
  border: 1px solid rgba(255, 255, 255, 0.9);
}

body.night-aura-mode .progress-stats-grid {
  background: rgba(15, 23, 42, 0.55);
  border-color: rgba(255, 255, 255, 0.08);
}

.stat-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  border-right: 1px solid rgba(203, 213, 225, 0.5);
}

.stat-cell:last-child {
  border-right: none;
}

.stat-num {
  font-size: 20px;
  font-weight: 800;
  color: var(--text-primary);
}

.stat-label {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 600;
}

/* ==========================================================================
   CHAPTER 2: LIVE TYPING → SEARCH MATCH → WORD DETAIL CHOREOGRAPHY
   (home.jpg → search.jpg → details.jpg)
   ========================================================================== */
.search-choreo-section {
  min-height: 125vh;
}

.choreo-stepper-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  background: var(--bg-surface-strong);
  padding: 6px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-glass);
}

.step-tab-btn {
  flex: 1;
  min-width: 135px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: var(--radius-pill);
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  font-family: var(--font-sans);
}

.step-tab-btn .step-num {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(148, 163, 184, 0.2);
  display: grid;
  place-items: center;
  font-size: 11px;
}

.step-tab-btn.active {
  background: linear-gradient(135deg, var(--cobalt-500), var(--cobalt-600));
  color: #ffffff;
  box-shadow: 0 8px 20px -4px rgba(29, 78, 216, 0.45);
}

.step-tab-btn.active .step-num {
  background: rgba(255, 255, 255, 0.25);
  color: #fff;
}

.autoplay-pill-btn {
  padding: 10px 16px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(37, 99, 235, 0.25);
  background: var(--cobalt-50);
  color: var(--cobalt-600);
  font-size: 12.5px;
  font-weight: 800;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.25s ease;
}

.autoplay-pill-btn:hover {
  background: var(--cobalt-100);
}

/* App-Authentic Search Pill Box (Mirrors home.jpg & search.jpg) */
.app-search-simulator {
  padding: 22px;
  border-radius: 30px;
}

.search-bar-glass {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 20px;
  border-radius: var(--radius-pill);
  background: #ffffff;
  border: 2px solid rgba(37, 99, 235, 0.18);
  box-shadow:
    0 10px 30px -6px rgba(29, 78, 216, 0.12),
    inset 0 2px 4px rgba(15, 23, 42, 0.02);
  margin-bottom: 14px;
  transition: all 0.3s ease;
}

body.night-aura-mode .search-bar-glass {
  background: rgba(15, 23, 42, 0.9);
  border-color: rgba(59, 130, 246, 0.35);
}

.search-bar-glass.typing-active {
  border-color: var(--cobalt-500);
  box-shadow:
    0 0 0 4px rgba(37, 99, 235, 0.15),
    0 14px 34px -6px rgba(29, 78, 216, 0.22);
}

.search-clear-btn {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: none;
  background: #64748b;
  color: #ffffff;
  display: grid;
  place-items: center;
  cursor: pointer;
  font-size: 13px;
  transition: all 0.2s ease;
}

.search-clear-btn:hover {
  background: #334155;
}

.search-input-stage {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  min-height: 32px;
  position: relative;
}

.search-placeholder-serif {
  font-family: var(--font-serif);
  font-size: 18px;
  color: #64748b;
  letter-spacing: 0.01em;
  width: 100%;
  text-align: center;
}

.search-typed-arabic {
  font-family: var(--font-arabic);
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  direction: rtl;
}

.typing-caret {
  display: inline-block;
  width: 2.5px;
  height: 24px;
  background: var(--cobalt-600);
  border-radius: 2px;
  animation: blinkCaret 0.85s step-end infinite;
}

@keyframes blinkCaret {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.search-Sample-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
}

.sample-chip-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
}

.word-preset-chip {
  padding: 5px 13px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(37, 99, 235, 0.2);
  background: rgba(255, 255, 255, 0.75);
  color: var(--text-primary);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}

body.night-aura-mode .word-preset-chip {
  background: rgba(30, 41, 59, 0.8);
  color: #f8fafc;
}

.word-preset-chip .chip-ar {
  font-family: var(--font-arabic);
  font-size: 15px;
  font-weight: 700;
  color: var(--cobalt-600);
}

body.night-aura-mode .word-preset-chip .chip-ar {
  color: #60a5fa;
}

.word-preset-chip.active,
.word-preset-chip:hover {
  background: var(--cobalt-50);
  border-color: var(--cobalt-500);
  transform: translateY(-1px);
}

/* Dynamic Stage Container inside Simulator (Home Prompt / Search Results / Word Detail) */
.simulator-dynamic-viewport {
  position: relative;
  min-height: 360px;
}

.sim-state-panel {
  display: none;
  animation: stateFadeIn 0.42s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.sim-state-panel.active {
  display: block;
}

@keyframes stateFadeIn {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Match List Cards (Mirrors search.jpg 1:1!) */
.match-results-stack {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.match-result-card {
  padding: 16px 20px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.86);
  border: 1.5px solid rgba(255, 255, 255, 0.96);
  box-shadow: 0 8px 24px -4px rgba(15, 23, 42, 0.05);
  cursor: pointer;
  transition: all 0.28s cubic-bezier(0.22, 1, 0.36, 1);
  position: relative;
  overflow: hidden;
}

body.night-aura-mode .match-result-card {
  background: rgba(30, 41, 59, 0.82);
  border-color: rgba(255, 255, 255, 0.12);
}

.match-result-card:hover,
.match-result-card.highlighted-match {
  border-color: var(--cobalt-400);
  transform: translateX(4px);
  box-shadow: 0 12px 30px -6px rgba(29, 78, 216, 0.16);
}

.match-ar-heading {
  font-family: var(--font-arabic);
  font-size: 26px;
  font-weight: 700;
  color: var(--cobalt-600);
  text-align: right;
  direction: rtl;
  line-height: 1.3;
  margin-bottom: 6px;
}

body.night-aura-mode .match-ar-heading {
  color: #60a5fa;
}

.match-mm-snippet {
  font-family: var(--font-mm);
  font-size: 14.5px;
  line-height: 1.65;
  color: var(--text-primary);
}

.match-click-hint {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--cobalt-600);
  background: var(--cobalt-50);
  padding: 3px 10px;
  border-radius: 99px;
}

/* Word Detail Panel (Mirrors details.jpg 1:1!) */
.detail-top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid var(--glass-border);
  margin-bottom: 12px;
}

body.night-aura-mode .detail-top-bar {
  background: rgba(30, 41, 59, 0.85);
}

.detail-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: none;
  background: transparent;
  font-weight: 800;
  font-size: 15px;
  color: var(--text-primary);
  cursor: pointer;
}

.detail-back-circle {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--bg-pearl);
  border: 1px solid rgba(203, 213, 225, 0.7);
  display: grid;
  place-items: center;
}

.detail-actions-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.detail-icon-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: var(--text-primary);
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: all 0.2s ease;
}

.detail-icon-btn:hover {
  background: var(--cobalt-50);
  color: var(--cobalt-600);
}

.detail-hero-word-card {
  padding: 18px 24px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.9);
  border: 1.5px solid var(--glass-border);
  text-align: right;
  font-family: var(--font-arabic);
  font-size: 38px;
  font-weight: 700;
  color: var(--cobalt-600);
  margin-bottom: 12px;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

body.night-aura-mode .detail-hero-word-card {
  background: rgba(30, 41, 59, 0.88);
  color: #60a5fa;
}

.detail-lexicon-card {
  padding: 18px 22px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.9);
  border: 1.5px solid var(--glass-border);
  margin-bottom: 12px;
}

body.night-aura-mode .detail-lexicon-card {
  background: rgba(30, 41, 59, 0.88);
}

.lexicon-badge-row {
  display: flex;
  margin-bottom: 10px;
}

.lexicon-badge-row--right {
  justify-content: flex-end;
}

.lexicon-pill-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  background: #dbeafe;
  border: 1px solid #93c5fd;
  color: #1d4ed8;
  font-size: 12.5px;
  font-weight: 700;
}

.lexicon-arabic-body {
  font-family: var(--font-arabic);
  font-size: 20px;
  line-height: 1.85;
  direction: rtl;
  text-align: right;
  color: var(--text-primary);
}

.lexicon-mm-body {
  font-family: var(--font-mm);
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-primary);
}

/* ==========================================================================
   CHAPTER 3: TRAIN & DAILY VOCABULARY GOAL (train.jpg)
   ========================================================================== */
.daily-goal-widget {
  padding: 28px;
  border-radius: 30px;
  margin-bottom: 20px;
}

.goal-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
}

.goal-title-group {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 19px;
  font-weight: 800;
}

.orange-status-dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #f59e0b;
  box-shadow: 0 0 10px #f59e0b;
}

.goal-metrics-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(203, 213, 225, 0.45);
}

.goal-metric-box {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.goal-metric-numbers {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.goal-big-num {
  font-size: 36px;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
}

.goal-sub-left {
  font-size: 13px;
  color: var(--text-secondary);
  font-weight: 600;
}

.goal-bar-track {
  width: 100%;
  height: 8px;
  border-radius: 99px;
  background: #e2e8f0;
  overflow: hidden;
}

body.night-aura-mode .goal-bar-track {
  background: #334155;
}

.goal-bar-fill {
  height: 100%;
  border-radius: 99px;
  background: linear-gradient(90deg, #1d4ed8, #3b82f6);
  transition: width 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

.goal-metric-caption {
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.goal-bottom-action-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.keep-it-up-text {
  font-size: 15px;
  font-weight: 700;
  color: var(--cobalt-600);
}

/* Interactive Flashcard Mini-Trainer */
.flashcard-trainer-box {
  padding: 22px 24px;
  border-radius: 26px;
  position: relative;
}

.flashcard-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.flashcard-stage {
  padding: 22px;
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(239, 246, 255, 0.75));
  border: 1.5px solid rgba(147, 197, 253, 0.5);
  text-align: center;
  cursor: pointer;
  transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

body.night-aura-mode .flashcard-stage {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.8));
}

.flashcard-stage:hover {
  transform: scale(1.01);
  border-color: var(--cobalt-400);
}

.flashcard-ar-word {
  font-family: var(--font-arabic);
  font-size: 36px;
  font-weight: 700;
  color: var(--cobalt-600);
  margin-bottom: 6px;
}

body.night-aura-mode .flashcard-ar-word {
  color: #60a5fa;
}

.flashcard-mm-answer {
  font-family: var(--font-mm);
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

/* ==========================================================================
   CHAPTER 4: CURATED CLASSICAL LIBRARY (library.jpg)
   ========================================================================== */
.lisan-hero-banner {
  position: relative;
  border-radius: 28px;
  padding: 26px;
  color: #ffffff;
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.88) 0%, rgba(45, 28, 16, 0.78) 55%, rgba(29, 78, 216, 0.75) 100%);
  border: 1.5px solid rgba(245, 194, 107, 0.45);
  box-shadow: 0 24px 50px -12px rgba(15, 23, 42, 0.32);
  margin-bottom: 18px;
  overflow: hidden;
}

.lisan-hero-banner::after {
  content: 'لسان العرب';
  position: absolute;
  right: 18px;
  top: 8px;
  font-family: var(--font-arabic);
  font-size: 64px;
  font-weight: 700;
  color: rgba(245, 194, 107, 0.16);
  pointer-events: none;
}

.continue-reading-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 18px;
}

.lisan-title {
  font-size: 26px;
  font-weight: 800;
  margin-bottom: 4px;
}

.lisan-author {
  font-size: 13.5px;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 16px;
}

.lisan-progress-track {
  width: 100%;
  height: 7px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.24);
  margin-bottom: 18px;
  overflow: hidden;
}

.lisan-progress-fill {
  height: 100%;
  width: 27%;
  background: #ffffff;
  border-radius: 99px;
  transition: width 0.4s ease;
}

.lisan-bottom-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.library-books-stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.book-row-card {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 16px 20px;
  border-radius: 24px;
  cursor: pointer;
}

.book-cover-3d {
  width: 68px;
  height: 88px;
  border-radius: 14px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 8px;
  color: #fff;
  font-family: var(--font-arabic);
  font-weight: 700;
  box-shadow: 0 10px 22px -4px rgba(15, 23, 42, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.35);
}

.book-cover--lisan {
  background: linear-gradient(145deg, #3b2314, #1c120c);
  color: #f5c26b;
}

.book-cover--grammar {
  background: linear-gradient(145deg, #1e1b4b, #312e81);
  color: #e0e7ff;
}

.book-cover--nights {
  background: linear-gradient(145deg, #1e3a8a, #9333ea);
  color: #fde68a;
}

.book-info-col {
  flex: 1;
}

.book-info-title {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.book-info-author {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 10px;
}

.book-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-secondary);
  margin-top: 8px;
}

.book-pct-blue {
  color: var(--cobalt-600);
}

/* ==========================================================================
   CHAPTER 5: SETTINGS & LIVE TYPOGRAPHY PLAYGROUND (settings.jpg)
   ========================================================================== */
.settings-playground-card {
  padding: 26px;
  border-radius: 30px;
}

.setting-row-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid var(--glass-border);
  margin-bottom: 12px;
}

body.night-aura-mode .setting-row-pill {
  background: rgba(30, 41, 59, 0.85);
}

.setting-row-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.setting-icon-orb {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #dbeafe;
  color: #1d4ed8;
  display: grid;
  place-items: center;
  font-weight: 800;
}

.setting-label-title {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-primary);
}

.setting-label-sub {
  font-size: 12.5px;
  color: var(--text-muted);
}

/* Authentic iOS Blue Toggle Switch (Mirrors settings.jpg) */
.ios-switch {
  position: relative;
  width: 58px;
  height: 32px;
  border-radius: var(--radius-pill);
  background: #cbd5e1;
  border: none;
  cursor: pointer;
  padding: 3px;
  transition: background 0.3s ease;
}

.ios-switch.active {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
}

.ios-switch-thumb {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.25);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.ios-switch.active .ios-switch-thumb {
  transform: translateX(26px);
}

/* Segmented Font Size Control (S | M | L | XL from settings.jpg) */
.font-size-card {
  padding: 20px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid var(--glass-border);
  margin-bottom: 12px;
}

body.night-aura-mode .font-size-card {
  background: rgba(30, 41, 59, 0.88);
}

.segmented-size-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  padding: 5px;
  border-radius: 16px;
  background: #e8f0ec;
  margin: 14px 0;
}

body.night-aura-mode .segmented-size-bar {
  background: #0f172a;
}

.size-seg-btn {
  padding: 10px 0;
  border-radius: 12px;
  border: none;
  background: transparent;
  font-size: 14px;
  font-weight: 800;
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.22, 1, 0.36, 1);
}

.size-seg-btn.active {
  background: linear-gradient(135deg, #1d4ed8, #1e40af);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(29, 78, 216, 0.35);
}

.font-preview-well {
  padding: 18px 20px;
  border-radius: 18px;
  background: #eff4f9;
  border: 1px solid rgba(203, 213, 225, 0.65);
  transition: all 0.3s ease;
}

body.night-aura-mode .font-preview-well {
  background: rgba(15, 23, 42, 0.75);
  border-color: rgba(255, 255, 255, 0.12);
}

.preview-ar-line {
  font-family: var(--font-arabic);
  color: var(--cobalt-600);
  text-align: right;
  direction: rtl;
  font-weight: 700;
  margin-bottom: 8px;
  transition: font-size 0.25s ease;
}

body.night-aura-mode .preview-ar-line {
  color: #60a5fa;
}

.preview-ar-def-extra {
  font-family: var(--font-arabic);
  color: var(--text-secondary);
  text-align: right;
  direction: rtl;
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px dashed rgba(148, 163, 184, 0.4);
  transition: all 0.25s ease;
}

.preview-mm-line {
  font-family: var(--font-mm);
  color: var(--text-primary);
  line-height: 1.65;
  transition: font-size 0.25s ease;
}

/* ==========================================================================
   CHAPTER 6: ALL-SCREENS INTERACTIVE GALLERY & HERITAGE FINALE
   ========================================================================== */
.finale-section {
  min-height: 95vh;
  padding-top: 80px;
}

.screens-showcase-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin: 24px 0 32px;
}

.screen-thumb-card {
  padding: 10px;
  border-radius: 20px;
  background: var(--bg-surface-strong);
  border: 1.5px solid var(--glass-border);
  box-shadow: var(--shadow-glass);
  cursor: pointer;
  transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  text-align: center;
}

.screen-thumb-card:hover,
.screen-thumb-card.active {
  transform: translateY(-6px) scale(1.02);
  border-color: var(--cobalt-500);
  box-shadow: var(--shadow-glass-hover);
}

.screen-thumb-card img {
  width: 100%;
  max-height: 185px;
  object-fit: contain;
  border-radius: 12px;
  margin-bottom: 6px;
}

.screen-thumb-label {
  font-size: 12px;
  font-weight: 800;
  color: var(--text-primary);
}

/* Heritage Midnight & Gold Banner (Homage to Dictionary.png + al_ameen.png) */
.heritage-download-card {
  position: relative;
  border-radius: 32px;
  padding: 36px 34px;
  background: radial-gradient(circle at 80% 20%, #1e3a8a 0%, #152232 55%, #0f1a28 100%);
  color: #ffffff;
  overflow: hidden;
  border: 1.5px solid rgba(245, 194, 107, 0.45);
  box-shadow: 0 32px 80px -16px rgba(15, 26, 40, 0.45);
  display: grid;
  grid-template-columns: 1.35fr 0.65fr;
  align-items: center;
  gap: 24px;
}

.heritage-logo-showcase {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 28px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.heritage-logo-showcase img {
  width: 148px;
  height: 148px;
  object-fit: contain;
  margin-bottom: 16px;
  filter: drop-shadow(0 10px 28px rgba(37, 99, 235, 0.5));
}

.heritage-mm-title {
  font-family: var(--font-mm);
  font-size: 32px;
  font-weight: 800;
  color: var(--gold-400);
  margin-bottom: 4px;
}

.heritage-mm-subtitle {
  font-family: var(--font-mm);
  font-size: 18px;
  color: #ffffff;
  margin-bottom: 10px;
}

.heritage-domain {
  font-size: 13px;
  letter-spacing: 0.18em;
  color: rgba(255, 255, 255, 0.75);
}

.store-badges-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

.store-btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 13px 22px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.28);
  color: #ffffff;
  text-decoration: none;
  transition: all 0.25s ease;
  cursor: pointer;
}

.store-btn:hover {
  background: #ffffff;
  color: var(--navy-900);
  transform: translateY(-3px);
}

.store-btn--primary {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  border-color: rgba(255, 255, 255, 0.4);
}

.store-btn-sub {
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  opacity: 0.8;
  display: block;
}

.store-btn-main {
  font-size: 15px;
  font-weight: 800;
}

/* Toast Notification */
.glass-toast {
  position: fixed;
  top: 86px;
  right: 28px;
  z-index: 60;
  padding: 12px 20px;
  border-radius: 16px;
  background: var(--navy-900);
  color: #ffffff;
  font-size: 13.5px;
  font-weight: 700;
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.18);
  transform: translateY(-20px);
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.glass-toast.show {
  transform: translateY(0);
  opacity: 1;
}

/* ==========================================================================
   RESPONSIVE DESIGN (TABLET & MOBILE)
   ========================================================================== */
@media (max-width: 1080px) {
  .story-section {
    grid-template-columns: 1fr;
    padding: 100px 0 60px;
  }

  .col-left-7,
  .col-left-6,
  .col-right-6,
  .col-right-7,
  .col-finale-left {
    grid-column: 1 / -1;
    max-width: 640px;
    padding-right: 0;
  }

  .nav-center-links {
    display: none;
  }

  .screens-showcase-strip {
    grid-template-columns: repeat(3, 1fr);
  }

  .heritage-download-card {
    grid-template-columns: 1fr;
    padding: 32px 24px;
  }

  .phone-hud-pill {
    right: 12px;
  }
}

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

  .screens-showcase-strip {
    grid-template-columns: repeat(2, 1fr);
  }

  .phone-hud-pill {
    display: none;
  }

  .brand-subtitle {
    display: none;
  }
}
