@import url('https://fonts.googleapis.com/css2?family=Amiri+Quran&family=Amiri:ital,wght@0,400;0,700;1,400&family=Inter:wght@300;400;500;600;700;800&family=Outfit:wght@400;500;600;700;800&display=swap');

/* ==========================================================================
 *   EL-ISLAM.SI - Modern Islamic Educational Portal Design System
 *   Aesthetic inspired by IslamQA.info (#1f2a37 slate & #2eb96a emerald green)
 *   Pure CSS3, Single-Line Ultra-Modern Navigation & Amiri Arabic Typography
 *   ========================================================================== */

/* Local and Web Amiri Font Definitions */
@font-face {
  font-family: 'Amiri';
  src: url('../fonts/Amiri-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
}
@font-face {
  font-family: 'Amiri';
  src: url('../fonts/Amiri-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
}
@font-face {
  font-family: 'Amiri Quran';
  src: url('../fonts/AmiriQuran-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
}

/* Automatic fallback: any Arabic Unicode character in Latin text uses Amiri */
@font-face {
  font-family: 'Inter';
  src: url('../fonts/Amiri-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF;
}
@font-face {
  font-family: 'Inter';
  src: url('../fonts/Amiri-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF;
}
@font-face {
  font-family: 'Outfit';
  src: url('../fonts/Amiri-Bold.ttf') format('truetype');
  font-weight: 600;
  font-style: normal;
  unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF;
}

:root {
  /* IslamQA.info Slate Palette - User Specified Background #1f2a37 */
  --bg-primary: #1f2a37;       /* Main site background (slate-800) */
  --bg-secondary: #111827;     /* Header & deep contrast surface (slate-900) */
  --bg-surface: #243040;       /* Section surface */
  --bg-card: #283548;          /* Card background */
  --bg-card-subtle: #212c3b;   /* Slightly recessed card background */
  --bg-hover: #324357;         /* Interactive hover background */

  /* Text Colors */
  --text-primary: #F9FAFB;     /* Pure crisp white / off-white */
  --text-secondary: #E5E7EB;   /* Secondary readable body text */
  --text-muted: #9CA3AF;       /* Muted text (slate-400) */
  --text-heading: #FFFFFF;     /* Headings */

  /* IslamQA Signature Emerald Green - User Specified #2eb96a for buttons & icons */
  --btn-primary: #2eb96a;
  --btn-primary-hover: #25a05b;
  --icon-color: #2eb96a;
  --accent-green: #2eb96a;
  --accent-green-glow: rgba(46, 185, 106, 0.25);

  /* Gold & Amber Accents (Preserved for Islamic Royalty & Tajweed Highlights) */
  --gold-400: #FACC15;
  --gold-500: #EAB308;
  --gold-600: #CA8A04;         /* IslamQA Q&A border yellow-600 */
  --gold-metallic: #D4AF37;    /* One unified color for El-Islam.si logo */
  --gold-glow: rgba(202, 138, 4, 0.2);

  /* Borders */
  --border-subtle: #374151;    /* Slate-700 border */
  --border-card: #374151;
  --border-gold: rgba(202, 138, 4, 0.4);
  --border-green: rgba(46, 185, 106, 0.4);

  /* Typography - STRICTLY AMIRI FOR ALL ARABIC */
  --font-sans: 'Inter', 'Amiri', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-heading: 'Outfit', 'Amiri', 'Cinzel', serif;
  --font-arabic: 'Amiri', 'Amiri Quran', serif;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.35);
  --shadow-lg: 0 10px 20px -3px rgba(0, 0, 0, 0.45);
  --shadow-card: 0 8px 24px rgba(0, 0, 0, 0.35);
  --shadow-green: 0 0 20px rgba(46, 185, 106, 0.3);

  /* Radius */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-full: 9999px;

  /* Layout - EXACT UNIFIED 1200px WIDTH FOR ALL SECTIONS */
  --max-width: 1200px;
  --reader-width: 840px;

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s ease;
  --transition-smooth: 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-color: var(--bg-primary);
  color: var(--text-primary);
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

/* ==========================================================================
 *   Top Header Bar - ALIGNED STRICTLY TO 1200px
 *   ========================================================================== */
.topbar {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 0.82rem;
  padding: 7px 0;
  position: relative;
  z-index: 50;
  width: 100%;
}

.topbar-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  width: 100%;
}

.topbar-left, .topbar-right, .topbar-center {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.topbar-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  line-height: 1;
}

.topbar-item > span:first-child {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  font-size: 0.85rem;
}

.hijri-badge {
  background: rgba(46, 185, 106, 0.12);
  border: 1px solid rgba(46, 185, 106, 0.35);
  color: var(--btn-primary);
  height: 26px;
  line-height: 24px;
  padding: 0 10px;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 0.78rem;
  display: inline-flex;
  align-items: center;
  box-sizing: border-box;
}

.city-select {
  background-color: var(--bg-surface);
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
  height: 26px;
  line-height: 24px;
  padding: 0 24px 0 8px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%239CA3AF' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 6px center;
  background-size: 11px;
  display: inline-flex;
  align-items: center;
  vertical-align: middle;
  box-sizing: border-box;
  margin: 0;
  transition: border-color var(--transition-fast);
}
.city-select:focus {
  border-color: var(--btn-primary);
}

.prayer-ticker {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 500;
}
.prayer-ticker-highlight {
  color: var(--btn-primary);
  font-weight: 700;
  padding-right: 3px;
}

.mawaqit-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: var(--btn-primary);
  font-weight: 600;
  padding: 3px 10px;
  border-radius: var(--radius-sm);
  background: rgba(46, 185, 106, 0.12);
  border: 1px solid rgba(46, 185, 106, 0.25);
  transition: all var(--transition-fast);
}
.mawaqit-link:hover {
  background: var(--btn-primary);
  color: #FFFFFF;
}

/* ==========================================================================
 *   Main Navigation Header - MODERN, CENTERED & UNIFIED ON ALL PAGES
 *   ========================================================================== */
.main-header {
  background: rgba(17, 24, 39, 0.94);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  position: sticky;
  top: 0;
  z-index: 500;
  width: 100%;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
}

.header-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0.6rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
  width: 100%;
}

/* Brand Logo & One-Color Text (Left) */
.brand-wrap {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-shrink: 0;
  text-decoration: none;
}

.brand-logo {
  width: 38px;
  height: 46px;
  object-fit: contain;
}

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

.brand-text .site-title,
.site-title {
  font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
  font-size: 1.35rem !important;
  font-weight: 600 !important;
  color: #dee1e5 !important;
  line-height: 1.1 !important;
  letter-spacing: -0.01em !important;
}

.brand-wrap span {
  font-weight: 600 !important;
}

.brand-text .site-tagline {
  font-size: 0.72rem;
  color: var(--text-muted);
  text-transform: lowercase;
  letter-spacing: 0.05em;
  font-weight: 500;
  margin-top: 1px;
}

/* Centered Navigation Wrapper (Desktop) */
.main-nav-centered {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Nav Menu Desktop - Sleek Centered Floating Capsule */
.nav-menu {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.15rem;
  list-style: none;
  margin: 0;
  padding: 0.25rem 0.45rem;
  background: rgba(31, 42, 55, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-full);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.05);
}

.nav-item {
  position: relative;
  flex-shrink: 0;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.38rem 0.58rem;
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--text-secondary);
  border-radius: var(--radius-full);
  white-space: nowrap;
  transition: all var(--transition-fast);
  text-decoration: none;
}

.nav-link:hover {
  color: #FFFFFF;
  background: rgba(46, 185, 106, 0.15);
}

.nav-link.active {
  color: #FFFFFF;
  background: var(--btn-primary);
  box-shadow: 0 2px 8px rgba(46, 185, 106, 0.35);
}

.nav-arrow {
  font-size: 0.72rem;
  opacity: 0.75;
  transition: transform var(--transition-fast);
}

.nav-item:hover .nav-arrow {
  transform: rotate(180deg);
}

/* Dropdown Menu - Sleek Glassmorphism Floating Sheet */
.dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(6px);
  min-width: 225px;
  background: rgba(23, 32, 45, 0.98);
  border: 1px solid rgba(212, 175, 55, 0.25);
  border-radius: var(--radius-lg);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.65), 0 0 1px rgba(255, 255, 255, 0.1);
  padding: 0.5rem;
  list-style: none;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-fast);
  z-index: 200;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.nav-item:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.dropdown-item a {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.52rem 0.85rem;
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: var(--radius-md);
  white-space: nowrap;
  transition: all var(--transition-fast);
  text-decoration: none;
}

.dropdown-item a:hover {
  background: rgba(46, 185, 106, 0.15);
  color: #FFFFFF;
  transform: translateX(3px);
}

.dropdown-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  margin: 0.35rem 0;
}

/* Header Right Actions */
.header-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-shrink: 0;
}

.header-search-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(46, 185, 106, 0.1);
  border: 1px solid rgba(46, 185, 106, 0.25);
  color: var(--btn-primary);
  transition: all var(--transition-fast);
  text-decoration: none;
}

.header-search-icon-btn:hover {
  background: var(--btn-primary);
  color: #FFFFFF;
  transform: scale(1.05);
}

/* Modern Animated Hamburger Toggle Button */
.mobile-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  padding: 0;
  background: rgba(31, 42, 55, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-md);
  color: #FFFFFF;
  cursor: pointer;
  outline: none;
  position: relative;
  z-index: 310;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: all var(--transition-fast);
}

.mobile-toggle:hover {
  background: rgba(46, 185, 106, 0.15);
  border-color: var(--btn-primary);
  box-shadow: 0 0 12px rgba(46, 185, 106, 0.3);
}

.mobile-toggle:focus-visible {
  border-color: var(--btn-primary);
  box-shadow: 0 0 0 3px rgba(46, 185, 106, 0.35);
}

.hamburger-box {
  width: 20px;
  height: 14px;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  pointer-events: none;
}

.hamburger-bar {
  display: block;
  width: 100%;
  height: 2px;
  background-color: #FFFFFF;
  border-radius: 2px;
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.22s ease, background-color 0.22s ease;
  transform-origin: center;
}

/* Active State transforms Hamburger into sleek 'X' */
.mobile-toggle.is-active {
  background: rgba(220, 38, 38, 0.15);
  border-color: rgba(239, 68, 68, 0.45);
}

.mobile-toggle.is-active:hover {
  background: rgba(220, 38, 38, 0.25);
  border-color: #EF4444;
  box-shadow: 0 0 14px rgba(239, 68, 68, 0.35);
}

.mobile-toggle.is-active .hamburger-bar {
  background-color: #F87171;
}

.mobile-toggle.is-active .hamburger-bar:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.mobile-toggle.is-active .hamburger-bar:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.mobile-toggle.is-active .hamburger-bar:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* Mobile Navigation Backdrop - Crisp, high-contrast, zero blur layer bugs */
.mobile-nav-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(10, 15, 25, 0.72);
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  z-index: 400;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.mobile-nav-backdrop.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* Prevent background body scroll when mobile menu is active */
body.mobile-menu-active {
  overflow: hidden !important;
  touch-action: none;
}


/* ==========================================================================
 *   Hero Section - MODERN, DIGNIFIED & PROFESSIONAL ISLAMIC BACKDROP
 *   ========================================================================== */
.hero-section {
  position: relative;
  padding: 4.5rem 0 4.5rem;
  background:
  linear-gradient(180deg, rgba(15, 23, 42, 0.88) 0%, rgba(24, 35, 50, 0.90) 50%, rgba(15, 23, 42, 0.94) 100%),
  url('../images/hero-bg.jpg') center center / cover no-repeat;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
  width: 100%;
}

/* Subtle Ambient Islamic Lattice Pattern */
.hero-backdrop {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  display: none;
}

.hero-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
  position: relative;
  z-index: 2;
  text-align: center;
  width: 100%;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(46, 185, 106, 0.1);
  border: 1px solid rgba(46, 185, 106, 0.35);
  color: var(--btn-primary);
  padding: 5px 16px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1.25rem;
  box-shadow: 0 2px 10px rgba(46, 185, 106, 0.15);
}

.hero-title {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 5vw, 3.4rem);
  font-weight: 600 !important;
  line-height: 1.18;
  color: #FFFFFF;
  margin-bottom: 0.85rem;
  letter-spacing: -0.02em;
}

.hero-title .highlight {
  color: #D4AF37;
}

.hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.15rem);
  color: var(--text-muted);
  max-width: 680px;
  margin: 0 auto 2rem;
  line-height: 1.6;
}

/* Hero Quran Verses Showcase Card */
.hero-verses-wrap {
  max-width: 800px;
  margin: 0 auto 2.25rem;
}

.verse-tabs {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 0.85rem;
  flex-wrap: wrap;
}

.verse-tab-btn {
  background: rgba(31, 42, 55, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.verse-tab-btn:hover {
  background: rgba(46, 185, 106, 0.15);
  color: #FFFFFF;
  border-color: rgba(46, 185, 106, 0.3);
}

.verse-tab-btn.active {
  background: var(--btn-primary);
  color: #FFFFFF;
  border-color: var(--btn-primary);
  box-shadow: 0 2px 8px rgba(46, 185, 106, 0.35);
}

.verse-card {
  background: rgba(33, 44, 59, 0.85);
  border: 1px solid rgba(212, 175, 55, 0.28);
  border-radius: var(--radius-xl);
  padding: 2rem 2.25rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), 0 0 20px rgba(212, 175, 55, 0.06);
  position: relative;
  transition: all var(--transition-smooth);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

/* Refined Arabic size in Hero Card - Tasteful, Not Oversized */
.verse-arabic {
  font-family: var(--font-arabic) !important;
  font-size: clamp(1.45rem, 3.2vw, 1.95rem) !important;
  font-weight: 400 !important;
  color: #FFFFFF;
  line-height: 2.15 !important;
  direction: rtl;
  text-align: center;
  margin-bottom: 1.15rem;
  letter-spacing: 0.01em;
}

.verse-translation {
  font-size: 1.1rem;
  color: var(--text-primary);
  font-style: italic;
  line-height: 1.65;
  margin-bottom: 0.75rem;
}

.verse-reference {
  font-size: 0.82rem;
  color: #D4AF37;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* Hero Instant Search Bar */
.hero-search-wrap {
  max-width: 620px;
  margin: 0 auto;
  position: relative;
}

.hero-search-input {
  width: 100%;
  padding: 0.95rem 3.5rem 0.95rem 1.5rem;
  background: rgba(17, 24, 39, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-full);
  color: var(--text-primary);
  font-size: 0.98rem;
  outline: none;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
  transition: all var(--transition-fast);
  backdrop-filter: blur(8px);
}

.hero-search-input:focus {
  border-color: var(--btn-primary);
  box-shadow: 0 0 0 3px rgba(46, 185, 106, 0.25);
}

.hero-search-btn {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  background: var(--btn-primary);
  border: none;
  color: #FFFFFF;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--transition-fast), transform var(--transition-fast);
}

.hero-search-btn:hover {
  background: var(--btn-primary-hover);
  transform: translateY(-50%) scale(1.05);
}

/* ==========================================================================
 *   Hero Category Quick Menu (Hero Menu)
 *   ========================================================================== */
.hero-category-menu {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 1.5rem;
  max-width: 920px;
  margin-left: auto;
  margin-right: auto;
}

.hero-cat-label {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-right: 0.25rem;
}

.hero-cat-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.38rem 0.9rem;
  border-radius: var(--radius-full);
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--text-secondary);
  background: rgba(31, 42, 55, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all var(--transition-fast);
  backdrop-filter: blur(8px);
  text-decoration: none;
}

.hero-cat-chip:hover {
  background: var(--btn-primary);
  color: #FFFFFF;
  border-color: var(--btn-primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(46, 185, 106, 0.35);
}

/* ==========================================================================
 *   Section Containers - EXACT UNIFIED 1200px WIDTH FOR ALL SECTIONS
 *   ========================================================================== */
.section-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 3.5rem 1.25rem;
  width: 100%;
}

.section-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 2.5rem;
}

.section-subtitle {
  color: var(--btn-primary);
  font-size: 0.84rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  display: block;
  margin-bottom: 0.45rem;
}

.section-title {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  font-weight: 700;
  color: var(--text-heading);
  line-height: 1.2;
  margin-bottom: 0.75rem;
}

.section-description {
  color: var(--text-muted);
  font-size: 1rem;
  line-height: 1.6;
}

/* ==========================================================================
 *   Prayer Times Timetable Widget
 *   ========================================================================== */
.prayer-widget {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2rem;
  box-shadow: var(--shadow-card);
  margin-bottom: 2rem;
}

.prayer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.75rem;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 1.25rem;
}

.prayer-header .city-select,
.prayer-city-select {
  height: 38px;
  line-height: 38px;
  padding: 0 34px 0 14px;
  font-size: 0.92rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  background-color: var(--bg-surface);
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
  display: inline-flex;
  align-items: center;
  vertical-align: middle;
  box-sizing: border-box;
  background-position: right 10px center;
  background-size: 13px;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.prayer-header .city-select:focus,
.prayer-city-select:focus {
  border-color: var(--btn-primary);
  box-shadow: 0 0 0 2px rgba(46, 185, 106, 0.2);
}

.prayer-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 1rem;
}

.prayer-cell {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.25rem 0.75rem;
  text-align: center;
  transition: all var(--transition-fast);
}

.prayer-cell.active {
  background: rgba(46, 185, 106, 0.1);
  border-color: var(--btn-primary);
  box-shadow: var(--shadow-green);
}

.prayer-name {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 0.35rem;
}

.prayer-time {
  font-family: var(--font-heading);
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--text-heading);
  margin-bottom: 0.25rem;
}

.prayer-arabic-name {
  font-family: var(--font-arabic) !important;
  font-size: 1.15rem !important;
  font-weight: 400 !important;
  color: var(--btn-primary);
  direction: rtl;
}

/* Moon Sighting Card */
.moon-tracker-card {
  background: var(--bg-card-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.75rem;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 1.5rem;
}

.moon-icon-wrap {
  width: 58px;
  height: 58px;
  background: rgba(46, 185, 106, 0.12);
  border: 1px solid rgba(46, 185, 106, 0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
}

/* ==========================================================================
 *   Flagship Pillars Grid (6 Stebrov verovanja & Osnove vere)
 *   ========================================================================== */
.flagship-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
  width: 100%;
}

.flagship-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 2rem 1.75rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-smooth);
}

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

.card-top-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.25rem;
}

.card-number-badge {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(46, 185, 106, 0.12);
  border: 1px solid rgba(46, 185, 106, 0.35);
  color: var(--btn-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.88rem;
}

.card-arabic-sub {
  font-family: var(--font-arabic) !important;
  font-size: 1.3rem !important;
  font-weight: 400 !important;
  color: #D4AF37;
  direction: rtl;
}

.flagship-card h3 {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 0.75rem;
}

.flagship-card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.card-footer-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--btn-primary);
  font-weight: 700;
  font-size: 0.92rem;
  transition: all var(--transition-fast);
}
.card-footer-link:hover {
  color: var(--btn-primary-hover);
  transform: translateX(4px);
}

/* ==========================================================================
 *   Category Filter Tabs
 *   ========================================================================== */
.filter-tabs {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 2.25rem;
}

.filter-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

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

.filter-btn.active {
  background: var(--btn-primary);
  color: #FFFFFF;
  border-color: var(--btn-primary);
  box-shadow: var(--shadow-green);
}

/* ==========================================================================
 *   Articles Grid & Cards
 *   ========================================================================== */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.75rem;
  width: 100%;
}

.article-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-smooth);
}

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

.article-img-wrap {
  position: relative;
  width: 100%;
  height: 180px;
  overflow: hidden;
  background: linear-gradient(135deg, #111827 0%, #243040 100%);
}

.article-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.article-card:hover .article-img-wrap img {
  transform: scale(1.05);
}

.category-tag {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(17, 24, 39, 0.85);
  border: 1px solid rgba(46, 185, 106, 0.4);
  color: var(--btn-primary);
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 3px 10px;
  border-radius: var(--radius-full);
}

.article-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.article-meta {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 500;
  margin-bottom: 0.75rem;
}

.article-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text-heading);
  margin-bottom: 0.85rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-title a:hover {
  color: var(--btn-primary);
}

.article-excerpt {
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
  flex-grow: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1rem;
  border-top: 1px solid var(--border-subtle);
}

/* ==========================================================================
 *   IslamQA Reader Layout (article.html)
 *   ========================================================================== */
.reader-container {
  max-width: var(--reader-width);
  margin: 0 auto;
  padding: 3rem 1.25rem 5rem;
  width: 100%;
}

.reader-breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.reader-breadcrumb a:hover {
  color: var(--btn-primary);
}

.reader-header {
  margin-bottom: 2rem;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 1.5rem;
}

.reader-title {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 800;
  line-height: 1.25;
  color: var(--text-heading);
  margin-bottom: 1.25rem;
}

.reader-meta-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.font-resizer {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.resizer-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--btn-primary);
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  cursor: pointer;
}
.resizer-btn:hover {
  background: var(--btn-primary);
  color: #FFFFFF;
}

/* IslamQA Question Box (.dark:tw-border-yellow-600) */
.question-box {
  background: var(--bg-card);
  border: 2px solid var(--gold-600);
  border-radius: var(--radius-lg);
  padding: 1.75rem 2rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow-md);
}

.question-box-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #D4AF37;
  font-weight: 800;
  text-transform: uppercase;
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  margin-bottom: 0.85rem;
}

.question-box-content {
  color: var(--text-primary);
  font-size: 1.05rem;
  line-height: 1.7;
  font-weight: 500;
}

.answer-box-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--btn-primary);
  font-family: var(--font-heading);
  font-size: 1.45rem;
  font-weight: 700;
  margin: 2.5rem 0 1.25rem;
}

.article-content {
  font-size: 1.12rem;
  line-height: 1.85;
  color: var(--text-primary);
}

.article-content p {
  margin-bottom: 1.5rem;
}

.article-content h2, .article-content h3 {
  font-family: var(--font-heading);
  color: var(--text-heading);
  margin: 2.25rem 0 1rem;
}

.article-content h4 {
  font-family: var(--font-heading) !important;
  font-size: 1.22rem !important;
  font-weight: 700 !important;
  line-height: 1.6 !important;
  direction: ltr !important;
  text-align: left !important;
  color: var(--text-heading) !important;
  margin: 1.75rem 0 1rem;
  padding: 1rem 1.5rem;
  background: var(--bg-card);
  border-left: 4px solid var(--btn-primary);
  border-right: none !important;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

/* Ensure ALL Latin article text is strictly LTR and left-aligned */
.article-content,
.article-content p:not([dir="rtl"]):not(.arabic-quote):not(.arabic-text),
.article-content h1,
.article-content h2,
.article-content h3,
.article-content h5,
.article-content h6,
.article-content blockquote {
  direction: ltr !important;
  text-align: left !important;
  font-family: var(--font-sans);
}

/* Article Lists: Perfectly aligned inside article text margin with emerald bullets */
.article-content ul,
.article-content ol,
.article-content .bs-shortcode-list,
.article-content .wp-block-list {
  direction: ltr !important;
  text-align: left !important;
  margin: 1.25rem 0 1.5rem 0 !important;
  padding-left: 2rem !important;
  padding-right: 0 !important;
  box-sizing: border-box !important;
}

.article-content ul,
.article-content .bs-shortcode-list {
  list-style-type: disc !important;
}

.article-content ol {
  list-style-type: decimal !important;
}

.article-content li {
  direction: ltr !important;
  text-align: left !important;
  margin-bottom: 0.65rem;
  line-height: 1.75;
  padding-left: 0.35rem;
  color: var(--text-primary);
}

.article-content li::marker {
  color: var(--btn-primary);
  font-size: 1.1em;
}

.article-content ul ul,
.article-content ol ol,
.article-content ul ol,
.article-content ol ul {
  margin: 0.5rem 0 0.5rem 0 !important;
  padding-left: 1.75rem !important;
}

/* Standalone Arabic Quranic & Hadith Quotes in Articles - Strictly Single Unified Card */
.article-content p.arabic-quote,
.article-content blockquote.arabic-quote,
.article-content div.arabic-quote {
  direction: rtl !important;
  text-align: right !important;
  font-family: var(--font-arabic) !important;
  font-size: clamp(1.3rem, 2.7vw, 1.65rem) !important;
  line-height: 2.1 !important;
  font-weight: 400 !important;
  color: #FFFFFF !important;
  margin: 1.5rem 0 1.25rem !important;
  padding: 1.1rem 1.6rem !important;
  background: rgba(36, 48, 64, 0.75) !important;
  border-right: 4px solid #D4AF37 !important;
  border-left: none !important;
  border-top: none !important;
  border-bottom: none !important;
  border-radius: var(--radius-md) !important;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25) !important;
  clear: both;
}

/* Strictly prevent ANY child spans, strong, em or nested tags from creating duplicate boxes, multiple backgrounds, or shrunken fonts */
.article-content .arabic-quote *,
.article-content .arabic-quote span,
.article-content .arabic-quote strong,
.article-content .arabic-quote em,
.article-content .arabic-quote font,
.article-content .arabic-quote p,
.article-content .arabic-quote div,
.article-content .arabic-quote blockquote,
.article-content .arabic-quote .arabic-quote,
.article-content span[dir="rtl"],
.article-content span[lang="ar"],
.article-content span.arabic-text {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
  margin: 0 !important;
  display: inline !important;
  color: inherit !important;
  font-family: var(--font-arabic) !important;
  font-weight: 400 !important;
  font-size: inherit !important;
  line-height: inherit !important;
}

/* Inline Arabic in the middle of normal text: strictly Amiri font, identical size to surrounding text */
.arabic-inline,
.article-content .arabic-inline,
.article-content span[lang="ar"]:not(.arabic-quote),
.article-content span.arabic:not(.arabic-quote),
.article-content span.arabic-text:not(.arabic-quote) {
  font-family: 'Amiri', 'Amiri Quran', serif !important;
  font-size: 1em !important;
  line-height: inherit !important;
  font-weight: inherit !important;
  direction: rtl;
  unicode-bidi: isolate;
  display: inline !important;
}

/* If a blockquote or div wraps an arabic quote, neutralize outer box styling */
.article-content blockquote:has(.arabic-quote),
.article-content div:has(> .arabic-quote) {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
}

.article-content blockquote {
  border-left: 4px solid var(--btn-primary);
  background: var(--bg-surface);
  padding: 1rem 1.5rem;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  margin: 1.5rem 0;
  font-style: italic;
  direction: ltr !important;
  text-align: left !important;
  color: var(--text-secondary);
}

/* ==========================================================================
 *   Social Share Bar - ICONS ONLY AS REQUESTED
 *   ========================================================================== */
.share-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 3.5rem 0 2rem;
  padding: 1.25rem 1.5rem;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  flex-wrap: wrap;
}

.share-label {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-right: 0.35rem;
}

.share-icons-group {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

/* SLEEK ROUND ICON BUTTONS */
.btn-share-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #FFFFFF;
  cursor: pointer;
  border: none;
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-sm);
}

.btn-share-icon:hover {
  transform: translateY(-2px);
  filter: brightness(1.15);
}

.share-icon-x { background: #000000; border: 1px solid #374151; }
.share-icon-tg { background: #229ED9; }
.share-icon-fb { background: #1877F2; }
.share-icon-wa { background: #25D366; }
.share-icon-copy {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--btn-primary);
}
.share-icon-copy:hover {
  border-color: var(--btn-primary);
}

/* ==========================================================================
 *   Article Prev/Next Navigation Cards & Related Articles Section
 *   ========================================================================== */
.article-prev-next-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin: 3rem 0 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-subtle);
}
@media (max-width: 640px) {
  .article-prev-next-nav {
    grid-template-columns: 1fr;
  }
}
.nav-card {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding: 1.25rem 1.4rem;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  text-decoration: none;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}
.nav-card:hover {
  border-color: var(--btn-primary);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  background: var(--bg-card-hover);
}
.nav-card-dir {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--btn-primary);
}
.nav-card-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-heading);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.nav-card-next {
  text-align: right;
}

.related-articles-section {
  margin: 3.5rem 0 2.5rem;
  padding-top: 2.5rem;
  border-top: 1px solid var(--border-subtle);
}
.related-section-title {
  font-family: var(--font-heading);
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 1.75rem;
  display: flex;
  align-items: center;
  gap: 0.65rem;
}
.related-section-title::before {
  content: "";
  display: inline-block;
  width: 4px;
  height: 1.25em;
  background: var(--btn-primary);
  border-radius: 2px;
}
.related-articles-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.15rem;
}
@media (max-width: 820px) {
  .related-articles-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 540px) {
  .related-articles-grid {
    grid-template-columns: 1fr;
  }
}
.related-articles-grid .article-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  overflow: hidden;
  transition: all var(--transition-base);
}
.related-articles-grid .article-card:hover {
  border-color: rgba(212, 175, 55, 0.4);
  transform: translateY(-3px);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.35);
}
.related-articles-grid .article-img-wrap {
  position: relative;
  width: 100%;
  height: 135px;
  overflow: hidden;
  background: var(--bg-surface);
}
.related-articles-grid .article-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}
.related-articles-grid .article-card:hover .article-img-wrap img {
  transform: scale(1.05);
}
.related-articles-grid .article-body {
  padding: 1rem 1.1rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.related-articles-grid .article-title {
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 0.5rem;
}
.related-articles-grid .article-title a {
  color: var(--text-heading);
  text-decoration: none;
  transition: color var(--transition-fast);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.related-articles-grid .article-title a:hover {
  color: var(--btn-primary);
}
.related-articles-grid .article-excerpt {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 0.9rem;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.related-articles-grid .article-footer {
  margin-top: auto;
  padding-top: 0.7rem;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.related-articles-grid .card-footer-link {
  font-size: 0.82rem;
  font-weight: 600;
}

/* ==========================================================================
 *   Tools Grid & Cards
 *   ========================================================================== */
.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.75rem;
  margin-top: 2rem;
  width: 100%;
}

.tool-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2.25rem 2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all var(--transition-smooth);
}

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

.tool-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-lg);
  background: rgba(46, 185, 106, 0.12);
  border: 1px solid rgba(46, 185, 106, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  margin-bottom: 1.25rem;
  color: var(--btn-primary);
}

/* ==========================================================================
 *   Arabic Alphabet Interactive Grid (abeceda.html)
 *   ========================================================================== */
.alphabet-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.letter-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.25rem 0.75rem;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.letter-card:hover, .letter-card.active {
  border-color: var(--btn-primary);
  background: rgba(46, 185, 106, 0.08);
  transform: translateY(-3px);
  box-shadow: var(--shadow-green);
}

.letter-arabic {
  font-family: var(--font-arabic) !important;
  font-size: 2.35rem !important;
  font-weight: 400 !important;
  line-height: 1.25;
  color: var(--text-heading);
  margin-bottom: 0.35rem;
}

.letter-name {
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--btn-primary);
}

.letter-example {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

/* ==========================================================================
 *   Sufara Vadnica (Sufara Word Reading Trainer) Styles
 *   ========================================================================== */
.sufara-nav-tabs {
  display: flex;
  justify-content: center;
  gap: 0.65rem;
  margin: 1.5rem 0 2.25rem;
  flex-wrap: wrap;
}

.sufara-nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.4rem;
  border-radius: var(--radius-full);
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-secondary);
  background: rgba(31, 42, 55, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.sufara-nav-btn:hover {
  background: rgba(46, 185, 106, 0.15);
  color: #FFFFFF;
}

.sufara-nav-btn.active {
  background: var(--btn-primary);
  color: #FFFFFF;
  border-color: var(--btn-primary);
  box-shadow: 0 4px 14px rgba(46, 185, 106, 0.35);
}

/* Quick Letter Ribbon for Sufara Mode */
.sufara-ribbon {
  display: flex;
  gap: 0.35rem;
  overflow-x: auto;
  padding: 0.65rem 0.5rem 1rem;
  margin-bottom: 2rem;
  scrollbar-width: thin;
  scrollbar-color: var(--btn-primary) var(--bg-card);
  direction: rtl;
}

.sufara-ribbon-btn {
  font-family: var(--font-arabic) !important;
  font-size: 1.45rem;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.sufara-ribbon-btn:hover, .sufara-ribbon-btn.active {
  background: var(--btn-primary);
  color: #FFFFFF;
  border-color: var(--btn-primary);
  transform: translateY(-2px);
  box-shadow: 0 3px 10px rgba(46, 185, 106, 0.35);
}

/* Sufara Trainer Card Box */
.sufara-trainer-box {
  background: var(--bg-card);
  border: 1px solid rgba(212, 175, 55, 0.28);
  border-radius: var(--radius-xl);
  padding: 2.25rem 2rem;
  box-shadow: var(--shadow-card);
  margin-bottom: 2.5rem;
}

/* 4 Writing Forms Grid */
.sufara-shapes-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
  margin: 1.5rem 0;
  direction: rtl;
}

.sufara-shape-item {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1rem 0.5rem;
  text-align: center;
  transition: all var(--transition-fast);
}

.sufara-shape-item:hover {
  border-color: #D4AF37;
  transform: translateY(-2px);
}

.sufara-shape-char {
  font-family: var(--font-arabic) !important;
  font-size: 2.4rem;
  color: #D4AF37;
  line-height: 1.2;
  margin-bottom: 0.35rem;
}

.sufara-shape-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
}

/* Vowel Harakat Drill Cards */
.sufara-vowels-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.85rem;
  margin: 1.5rem 0;
  direction: rtl;
}

.sufara-vowel-card {
  background: rgba(46, 185, 106, 0.08);
  border: 1px solid rgba(46, 185, 106, 0.25);
  border-radius: var(--radius-md);
  padding: 0.85rem 0.5rem;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.sufara-vowel-card:hover {
  background: var(--btn-primary);
  border-color: var(--btn-primary);
}

.sufara-vowel-card:hover .sufara-vowel-char,
.sufara-vowel-card:hover .sufara-vowel-name {
  color: #FFFFFF !important;
}

.sufara-vowel-char {
  font-family: var(--font-arabic) !important;
  font-size: 2.1rem;
  color: var(--btn-primary);
  line-height: 1.2;
}

.sufara-vowel-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-secondary);
  margin-top: 0.25rem;
}

/* Training Words Grid */
.sufara-words-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.25rem;
  margin-top: 1.5rem;
}

.sufara-word-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.35rem 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  text-align: center;
  transition: all var(--transition-smooth);
  position: relative;
}

.sufara-word-card:hover {
  border-color: #D4AF37;
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.sufara-word-pos-badge {
  display: inline-block;
  align-self: center;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: rgba(212, 175, 55, 0.12);
  color: #D4AF37;
  border: 1px solid rgba(212, 175, 55, 0.3);
  margin-bottom: 0.65rem;
}

.sufara-word-ar {
  font-family: var(--font-arabic) !important;
  font-size: 2.2rem;
  color: #FFFFFF;
  line-height: 1.4;
  direction: rtl;
  margin: 0.35rem 0 0.65rem;
}

.sufara-word-trans {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--btn-primary);
  margin-bottom: 0.25rem;
}

.sufara-word-meaning {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 0.85rem;
}

.sufara-audio-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
  margin: 0 auto;
}

.sufara-audio-btn:hover {
  background: var(--btn-primary);
  border-color: var(--btn-primary);
  color: #FFFFFF;
}

/* ==========================================================================
 *   Duas List & Cards (dove.html)
 *   ========================================================================== */
.dua-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2rem;
  margin-bottom: 1.75rem;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-fast);
}

.dua-card:hover {
  border-color: var(--btn-primary);
}

.dua-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 0.75rem;
}

.dua-arabic {
  font-family: var(--font-arabic) !important;
  font-size: clamp(1.45rem, 3vw, 1.85rem) !important;
  font-weight: 400 !important;
  line-height: 2.1 !important;
  color: #FFFFFF;
  direction: rtl;
  text-align: right;
  margin: 1.15rem 0;
}

.dua-translit {
  color: var(--text-muted);
  font-style: italic;
  margin-bottom: 0.75rem;
  font-size: 0.98rem;
}

.dua-translation {
  color: var(--text-primary);
  font-size: 1.05rem;
  line-height: 1.7;
}

/* ==========================================================================
 *   Quran Reader Styles (quran.html)
 *   ========================================================================== */
.surah-select-wrap {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin: 2rem 0;
  flex-wrap: wrap;
}

.ayah-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.75rem 2rem;
  margin-bottom: 1.75rem;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-fast);
}

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

.ayah-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 0.65rem;
}

.ayah-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2rem;
  height: 2rem;
  padding: 0 0.6rem;
  box-sizing: border-box;
  background: rgba(46, 185, 106, 0.12);
  border: 1px solid rgba(46, 185, 106, 0.35);
  color: var(--btn-primary);
  font-weight: 700;
  font-size: 0.9rem;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  border-radius: var(--radius-full);
  flex-shrink: 0;
}

/* Tastefully Proportioned Arabic Ayah Text */
.ayah-arabic {
  font-family: var(--font-arabic) !important;
  font-size: clamp(1.45rem, 3vw, 1.9rem) !important;
  font-weight: 400 !important;
  line-height: 2.2 !important;
  text-align: right;
  direction: rtl;
  margin-bottom: 1.25rem;
  color: #FFFFFF;
}

/* Modern Ayah End Marker with Dynamic Width for 1, 2, and 3 Digits */
.ayah-end-marker {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 34px;
  padding: 0 6px;
  border-radius: 999px;
  border: 1.5px solid rgba(212, 175, 55, 0.55);
  background: radial-gradient(circle, rgba(212, 175, 55, 0.14) 0%, rgba(31, 42, 55, 0.95) 100%);
  color: #D4AF37;
  font-family: var(--font-heading), -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 0.65em;
  font-weight: 700;
  line-height: 1;
  vertical-align: middle;
  margin: 0 12px;
  box-shadow: 0 0 12px rgba(212, 175, 55, 0.18);
  position: relative;
  user-select: none;
  box-sizing: border-box;
}

.ayah-end-marker.digits-3 {
  min-width: 44px;
  padding: 0 8px;
  font-size: 0.54em;
  letter-spacing: -0.02em;
}

.ayah-end-marker::after {
  content: '';
  position: absolute;
  inset: 2px;
  border-radius: 999px;
  border: 1px dashed rgba(212, 175, 55, 0.3);
  pointer-events: none;
}

.ayah-card.highlight-jump {
  border-color: #D4AF37 !important;
  box-shadow: 0 0 24px rgba(212, 175, 55, 0.45) !important;
  animation: pulseAyah 2.5s ease-out;
}

@keyframes pulseAyah {
  0% { transform: scale(1.01); border-color: #D4AF37; box-shadow: 0 0 28px rgba(212, 175, 55, 0.6); }
  50% { transform: scale(1); border-color: #D4AF37; box-shadow: 0 0 18px rgba(212, 175, 55, 0.35); }
  100% { border-color: var(--border-subtle); box-shadow: var(--shadow-sm); }
}

.ayah-actions {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.ayah-action-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: all var(--transition-fast);
}

.ayah-action-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-heading);
  border-color: rgba(255, 255, 255, 0.25);
}

.ayah-action-btn.bookmarked {
  background: rgba(212, 175, 55, 0.16);
  border-color: #D4AF37;
  color: #FBBF24;
}

.ayah-translation {
  font-size: 1.1rem;
  line-height: 1.7;
  color: var(--text-primary);
  font-weight: 500;
}

/* Neutralized Tajweed (Clean Authentic Quran Text Without Distracting Colors) */
.tajweed-legend {
  display: none !important;
}

.tajweed-qalqalah,
.tajweed-ghunnah,
.tajweed-madd,
.tajweed-ikhfa {
  background: transparent !important;
  color: inherit !important;
  border: none !important;
  padding: 0 !important;
}

/* ==========================================================================
 *   Footer - ALIGNED TO 1200px
 *   ========================================================================== */
.site-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-subtle);
  padding: 4rem 0 2rem;
  margin-top: auto;
  width: 100%;
}

.footer-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2.5rem;
  width: 100%;
}

.footer-col h4 {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  color: var(--text-heading);
  margin-bottom: 1.25rem;
  font-weight: 700;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.footer-links a {
  color: var(--text-muted);
  font-size: 0.9rem;
  transition: all var(--transition-fast);
}

.footer-links a:hover {
  color: var(--btn-primary);
  padding-left: 0.35rem;
}

.footer-bottom {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2rem 1.25rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  width: 100%;
}

/* Toast Notifications */
.toast-notice {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--bg-card);
  border: 1px solid var(--btn-primary);
  color: var(--text-primary);
  padding: 0.85rem 1.4rem;
  border-radius: var(--radius-md);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
  z-index: 300;
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-weight: 600;
  font-size: 0.9rem;
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.toast-notice.show {
  transform: translateY(0);
  opacity: 1;
}

/* General Buttons */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: var(--btn-primary);
  color: #FFFFFF;
  padding: 0.75rem 1.75rem;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 0.95rem;
  border: none;
  cursor: pointer;
  transition: all var(--transition-fast);
}
.btn-primary:hover {
  background: var(--btn-primary-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-green);
}

.btn-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--btn-primary);
  cursor: pointer;
  transition: all var(--transition-fast);
}
.btn-icon:hover {
  color: #FFFFFF;
  background: var(--btn-primary);
  border-color: var(--btn-primary);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.55rem 1.25rem;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-primary);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  text-decoration: none;
  transition: all var(--transition-fast);
}
.btn-secondary:hover {
  border-color: var(--btn-primary);
  color: var(--btn-primary);
  background: var(--bg-card-hover);
  transform: translateY(-1px);
}

/* Dua Filter Pills */
.dua-filter-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 1rem;
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}
.dua-filter-pill:hover {
  border-color: var(--btn-primary);
  color: #FFFFFF;
  background: rgba(46, 185, 106, 0.14);
}
.dua-filter-pill.active {
  background: var(--btn-primary) !important;
  color: #FFFFFF !important;
  border-color: var(--btn-primary) !important;
  box-shadow: 0 4px 14px rgba(46, 185, 106, 0.4) !important;
}

/* Dua Copy Button */
.btn-copy-dua {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.38rem 0.85rem;
  border-radius: var(--radius-md);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  transition: all var(--transition-fast);
}
.btn-copy-dua:hover {
  border-color: var(--btn-primary);
  color: var(--btn-primary);
  background: rgba(46, 185, 106, 0.12);
}
.btn-copy-dua.copied {
  background: var(--btn-primary) !important;
  color: #FFFFFF !important;
  border-color: var(--btn-primary) !important;
}

/* Audio Playing Pulse Animation */
@keyframes audioPulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

.audio-playing {
  animation: audioPulse 1.2s infinite ease-in-out;
  color: #FFFFFF !important;
  background: var(--btn-primary) !important;
}

/* Responsive Media Queries */
@media (max-width: 1024px) {
  /* backdrop-filter makes the header the containing block for the fixed
   *     mobile menu, which pushed the menu down and hid its first items. */
  .main-header {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    background: rgba(17, 24, 39, 0.98);
  }
  .nav-menu { display: none; }
  .mobile-toggle { display: inline-flex; }
  .footer-container { grid-template-columns: 1fr 1fr; }
  .prayer-grid { grid-template-columns: repeat(3, 1fr); }
  .moon-tracker-card { grid-template-columns: 1fr; text-align: center; justify-items: center; }

  /* Fully Fixed Modern Slate Mobile Menu Overlay & Drawer - Ultra Sharp, Zero Blur */
  .nav-menu.mobile-open {
    display: flex !important;
    flex-direction: column;
    /* center-justify in an overflowing column hides the first items */
    justify-content: flex-start;
    align-items: stretch;
    position: fixed;
    top: 58px;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: calc(100vh - 58px);
    height: calc(100dvh - 58px);
    max-height: calc(100dvh - 58px);
    background: #192230;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    border-bottom: 3px solid var(--btn-primary);
    border-radius: 0;
    padding: 1.25rem 1.25rem 4rem;
    gap: 0.65rem;
    z-index: 550;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    transform: none !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    animation: mobileMenuFade 0.2s ease-out forwards;
  }

  @keyframes mobileMenuFade {
    from {
      opacity: 0;
    }
    to {
      opacity: 1;
    }
  }

  .nav-menu.mobile-open .nav-item {
    flex-shrink: 0;
    width: 100%;
    position: relative;
    transform: none !important;
  }

  .nav-menu.mobile-open .nav-link {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.85rem 1.1rem;
    font-size: 0.98rem;
    font-weight: 600;
    color: #F3F4F6;
    background: #202c3d;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-md);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.25);
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
    transform: none !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
  }

  .nav-menu.mobile-open .nav-link:hover,
  .nav-menu.mobile-open .nav-link:active {
    background: rgba(46, 185, 106, 0.22);
    border-color: var(--btn-primary);
    color: #FFFFFF;
    transform: none !important;
  }

  .nav-menu.mobile-open .nav-link.active {
    background: var(--btn-primary);
    color: #FFFFFF;
    border-color: var(--btn-primary);
    box-shadow: 0 4px 14px rgba(46, 185, 106, 0.4);
    transform: none !important;
  }

  .nav-menu.mobile-open .dropdown-menu {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none !important;
    box-shadow: none;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: #141c28;
    border-radius: var(--radius-md);
    margin: 0.45rem 0 0.5rem;
    padding: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    min-width: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
  }

  .nav-menu.mobile-open .dropdown-item a {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.65rem 0.9rem;
    font-size: 0.9rem;
    color: #E2E8F0;
    border-radius: var(--radius-sm);
    transition: background 0.15s ease, color 0.15s ease;
    transform: none !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
  }

  .nav-menu.mobile-open .dropdown-item a:hover {
    background: rgba(46, 185, 106, 0.2);
    color: #FFFFFF;
    transform: none !important;
  }
}

@media (max-width: 768px) {
  .topbar {
    display: block !important;
    padding: 6px 0;
  }
  .topbar-container {
    padding: 0 0.85rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    flex-wrap: nowrap;
  }
  .topbar-right {
    display: none !important;
  }
  .hijri-badge {
    display: none !important;
  }
  .topbar-left {
    gap: 0.35rem;
    flex-shrink: 0;
  }
  .topbar-center {
    flex: 1;
    min-width: 0;
    justify-content: flex-end;
  }
  .prayer-ticker {
    font-size: 0.77rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    justify-content: flex-end;
  }
  .prayer-ticker-countdown,
  .prayer-ticker-label,
  .prayer-ticker-ob {
    display: none !important;
  }
}

@media (max-width: 640px) {
  .footer-container { grid-template-columns: 1fr; }
  .prayer-grid { grid-template-columns: repeat(2, 1fr); }
  .section-container { padding: 2.75rem 1rem; }
  .hero-section { padding: 3.5rem 0 4rem; }
  .verse-card { padding: 1.5rem 1.25rem; }
  .reader-container { padding: 2rem 1rem 4rem; }
}

@media (max-width: 480px) {
  .topbar-container {
    padding: 0 0.5rem;
    gap: 0.35rem;
  }
  .city-select {
    font-size: 0.75rem;
    height: 24px;
    line-height: 22px;
    padding: 0 18px 0 6px;
  }
  .prayer-ticker {
    font-size: 0.72rem;
  }
}

/* Global Amiri Arabic Typography for Arabic Dropdown Menus */
.dropdown-menu [lang="ar"],
.dropdown-item [lang="ar"],
.dropdown-menu .arabic-text {
  font-family: 'Amiri', 'Amiri Quran', var(--font-arabic), serif !important;
}

/* ==========================================================================
 *   Lunin koledar & Opazovanje mlaje (Hilal) & Moonsighting Maps
 *   ========================================================================== */
.moon-maps-section {
  margin: 2.5rem 0 3.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-card);
}

.moon-maps-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border-subtle);
}

.moon-maps-title-wrap h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-heading);
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0;
}

.moon-current-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(46, 185, 106, 0.15);
  border: 1px solid var(--border-green);
  color: var(--btn-primary);
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
}

.moon-month-pills {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  margin-bottom: 1.5rem;
  scrollbar-width: thin;
}

.moon-month-pill {
  padding: 0.5rem 1rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.moon-month-pill:hover {
  background: var(--bg-hover);
  color: #FFFFFF;
  border-color: var(--btn-primary);
}

.moon-month-pill.active {
  background: var(--btn-primary);
  color: #FFFFFF;
  border-color: var(--btn-primary);
  box-shadow: 0 0 12px rgba(46, 185, 106, 0.4);
}

.moon-maps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

@media (max-width: 860px) {
  .moon-maps-grid {
    grid-template-columns: 1fr;
  }
}

.moon-map-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: all var(--transition-normal);
  display: flex;
  flex-direction: column;
}

.moon-map-card:hover {
  border-color: var(--btn-primary);
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.moon-map-img-wrap {
  position: relative;
  cursor: pointer;
  background: #0d131d;
  aspect-ratio: 4 / 3;
  overflow: hidden;
}

.moon-map-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  transition: transform var(--transition-normal);
}

.moon-map-card:hover .moon-map-img-wrap img {
  transform: scale(1.03);
}

.moon-map-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(17, 24, 39, 0.85);
  backdrop-filter: blur(4px);
  border: 1px solid var(--border-subtle);
  color: #FFFFFF;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.6rem;
  border-radius: var(--radius-sm);
  z-index: 2;
}

.moon-map-zoom-hint {
  position: absolute;
  inset: 0;
  background: rgba(17, 24, 39, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition-fast);
  color: #FFFFFF;
  font-size: 0.9rem;
  font-weight: 600;
  gap: 0.5rem;
  text-align: center;
  padding: 1rem;
}

.moon-map-img-wrap:hover .moon-map-zoom-hint {
  opacity: 1;
}

.moon-map-card-body {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.moon-map-card-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-heading);
}

.moon-map-card-desc {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Lightbox Modal */
.moon-lightbox-modal {
  position: fixed;
  inset: 0;
  background: rgba(10, 15, 25, 0.92);
  backdrop-filter: blur(8px);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  animation: fadeIn 0.2s ease;
}

.moon-lightbox-content {
  position: relative;
  max-width: 95vw;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.moon-lightbox-content img {
  max-width: 92vw;
  max-height: 82vh;
  object-fit: contain;
  border-radius: var(--radius-md);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8);
  border: 1px solid var(--border-subtle);
}

.moon-lightbox-close {
  position: absolute;
  top: -42px;
  right: 0;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #FFFFFF;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.3rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.moon-lightbox-close:hover {
  background: var(--btn-primary);
  border-color: var(--btn-primary);
}

.moon-lightbox-caption {
  margin-top: 0.75rem;
  color: #E5E7EB;
  font-size: 0.9rem;
  text-align: center;
  font-weight: 500;
}

/* Observation Guidelines Section */
.moon-guide-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 2.25rem;
  margin: 3rem 0;
  box-shadow: var(--shadow-card);
}

.moon-guide-card h2 {
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.moon-steps-list {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.moon-steps-list li {
  position: relative;
  padding-left: 2.25rem;
  font-size: 0.96rem;
  line-height: 1.65;
  color: var(--text-secondary);
}

.moon-steps-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 2px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(46, 185, 106, 0.18);
  color: var(--btn-primary);
  font-weight: 800;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.moon-steps-list strong {
  color: #FFFFFF;
}

.moon-data-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-left: 4px solid var(--btn-primary);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.5rem;
  margin-top: 1.5rem;
}

.moon-data-box h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 0.5rem;
}

.moon-data-box p {
  font-size: 0.92rem;
  color: var(--text-muted);
  margin-bottom: 0.85rem;
}

.btn-external-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--btn-primary);
  color: #FFFFFF !important;
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.65rem 1.25rem;
  border-radius: var(--radius-sm);
  text-decoration: none !important;
  transition: all var(--transition-fast);
}

.btn-external-link:hover {
  background: var(--btn-primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(46, 185, 106, 0.35);
}

/* ==========================================================================
 *   Interactive Moon Tracker (2-Row x 2-Column Hilal Grid)
 *   ========================================================================== */
.moon-live-container {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
  margin-top: 1.5rem;
}

.moon-grid-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.15rem;
}

.moon-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 1.15rem 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.16);
  min-width: 0;
  box-sizing: border-box;
}

.moon-card.highlight {
  border-color: rgba(46, 185, 106, 0.45);
  background: linear-gradient(145deg, var(--bg-surface) 0%, rgba(46, 185, 106, 0.12) 100%);
  box-shadow: 0 4px 18px rgba(46, 185, 106, 0.15);
}

/* Card 1: Controls & Title */
.moon-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 0.85rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.moon-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-heading);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.moon-status-badge {
  font-size: 0.72rem;
  color: var(--btn-primary);
  background: rgba(46, 185, 106, 0.12);
  border: 1px solid rgba(46, 185, 106, 0.3);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  font-weight: 600;
  white-space: nowrap;
}

.moon-toolbox {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.moon-toolbox-date-row,
.moon-toolbox-city-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.moon-city-label {
  font-size: 0.82rem;
  color: var(--text-secondary);
  font-weight: 500;
  white-space: nowrap;
}

.moon-btn-group {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 2px;
}

.moon-quick-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 0.78rem;
  font-weight: 600;
  height: 28px;
  padding: 0 0.6rem;
  border-radius: 3px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.moon-quick-btn:hover {
  color: var(--text-heading);
  background: rgba(255, 255, 255, 0.08);
}

.moon-quick-btn.active {
  background: var(--btn-primary);
  color: #FFFFFF;
}

.moon-date-input,
.moon-city-input {
  background-color: var(--bg-card);
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
  height: 32px;
  line-height: 30px;
  padding: 0 0.6rem;
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  font-weight: 600;
  outline: none;
  box-sizing: border-box;
  transition: all var(--transition-fast);
}

.moon-date-input {
  flex: 1;
  min-width: 125px;
}

.moon-city-input {
  flex: 1;
  min-width: 140px;
  cursor: pointer;
}

.moon-date-input:focus,
.moon-city-input:focus {
  border-color: var(--btn-primary);
}

/* Card 2: Compass & Observation */
.moon-card-compass {
  background: linear-gradient(145deg, var(--bg-surface) 0%, rgba(46, 185, 106, 0.05) 100%);
  border: 1px solid rgba(46, 185, 106, 0.22);
}

.moon-compass-main {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
}

.moon-compass-svg {
  width: 52px;
  height: 52px;
  flex-shrink: 0;
  margin-top: 2px;
}

.moon-compass-content {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  flex: 1;
  min-width: 0;
}

.moon-compass-heading {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.moon-compass-label {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-heading);
}

.moon-compass-value {
  color: #FBBF24;
  font-weight: 700;
  font-size: 0.95rem;
}

.moon-date-badge {
  font-size: 0.72rem;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.06);
  padding: 2px 7px;
  border-radius: 4px;
  font-weight: 500;
}

.moon-compass-desc {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.45;
  margin: 0;
}

.moon-compass-action {
  display: flex;
  justify-content: flex-end;
  margin-top: 0.75rem;
  padding-top: 0.6rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.moon-link-btn {
  font-size: 0.8rem;
  padding: 0.35rem 0.85rem;
  height: 28px;
  display: inline-flex;
  align-items: center;
}

/* Card 3 & 4: Metric Cards */
.moon-card-metric {
  padding: 1.15rem 1.25rem;
}

.moon-metric-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.35rem;
}

.moon-metric-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.moon-metric-label.highlight-label {
  color: var(--btn-primary);
}

.moon-metric-icon {
  font-size: 1.4rem;
}

.moon-metric-value {
  font-family: var(--font-heading);
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--text-heading);
  line-height: 1.2;
  margin-bottom: 0.35rem;
}

.moon-metric-sub {
  font-size: 0.85rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.moon-metric-angle-badge {
  background: rgba(212, 175, 55, 0.18);
  color: #FBBF24;
  border: 1px solid rgba(251, 191, 36, 0.4);
  padding: 2px 10px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.88rem;
}

/* Responsive: Collapse to 1 column only on narrow mobile screens (<= 640px) */
@media (max-width: 640px) {
  .moon-grid-row {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  .moon-compass-main {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .moon-compass-heading {
    justify-content: center;
  }
  .moon-compass-action {
    justify-content: center;
  }
}

/* ==========================================================================
 *   Header Search Pill & Shortcut Badge
 *   ========================================================================== */
.header-search-btn-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.85rem;
  background: rgba(18, 30, 24, 0.85);
  border: 1px solid rgba(46, 185, 106, 0.28);
  border-radius: var(--radius-full);
  color: var(--text-secondary);
  font-size: 0.84rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
  text-decoration: none;
}

.header-search-btn-pill:hover {
  border-color: var(--btn-primary);
  color: #FFFFFF;
  background: rgba(46, 185, 106, 0.15);
  box-shadow: 0 0 15px rgba(46, 185, 106, 0.2);
}

.search-kbd-shortcut {
  font-size: 0.72rem;
  font-family: inherit;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--text-muted);
}

@media (max-width: 768px), (hover: none) and (pointer: coarse) {
  .search-kbd-shortcut {
    display: none !important;
  }
}

/* ==========================================================================
 *   Spotlight Search Modal & Ctrl+K Engine
 *   ========================================================================== */
body.spotlight-open {
  overflow: hidden !important;
}

.spotlight-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(4, 10, 7, 0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 4.5rem 1.25rem 2rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.2s;
}

.spotlight-overlay.active {
  opacity: 1;
  visibility: visible;
}

.spotlight-dialog {
  width: 100%;
  max-width: 680px;
  background: #0D1612;
  border: 1px solid rgba(46, 185, 106, 0.32);
  border-radius: 16px;
  box-shadow: 0 25px 65px -10px rgba(0, 0, 0, 0.9), 0 0 40px rgba(46, 185, 106, 0.12);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: translateY(-12px) scale(0.98);
  transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.spotlight-overlay.active .spotlight-dialog {
  transform: translateY(0) scale(1);
}

.spotlight-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1.1rem 1.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(18, 30, 24, 0.6);
  position: relative;
}

.spotlight-search-icon {
  color: var(--btn-primary);
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.spotlight-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: #FFFFFF;
  font-family: inherit;
  font-size: 1.12rem;
  line-height: 1.5;
}

.spotlight-input::placeholder {
  color: rgba(255, 255, 255, 0.42);
}

.spotlight-clear-btn {
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: var(--text-secondary);
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  flex-shrink: 0;
}

.spotlight-clear-btn:hover {
  background: rgba(239, 68, 68, 0.3);
  color: #FFFFFF;
}

.spotlight-kbd-badge {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 4px;
  padding: 2px 7px;
  letter-spacing: 0.05em;
  flex-shrink: 0;
}

.spotlight-close-btn {
  display: none;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  margin-right: -0.35rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.spotlight-close-btn:hover,
.spotlight-close-btn:active {
  background: rgba(239, 68, 68, 0.3);
  border-color: rgba(239, 68, 68, 0.5);
  color: #FFFFFF;
}

.spotlight-cat-bar {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.65rem 1.1rem;
  background: rgba(11, 20, 16, 0.7);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  overflow-x: auto;
  scrollbar-width: none;
}
.spotlight-cat-bar::-webkit-scrollbar {
  display: none;
}

.spotlight-cat-pill {
  white-space: nowrap;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-secondary);
  padding: 0.35rem 0.8rem;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.spotlight-cat-pill:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #FFFFFF;
  border-color: rgba(46, 185, 106, 0.3);
}

.spotlight-cat-pill.active {
  background: var(--btn-primary);
  color: #FFFFFF;
  border-color: var(--btn-primary);
  box-shadow: 0 2px 8px rgba(46, 185, 106, 0.35);
}

.spotlight-status-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.55rem 1.25rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: rgba(6, 13, 9, 0.4);
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.spotlight-count-badge {
  background: rgba(46, 185, 106, 0.15);
  color: #34D399;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: none;
}

.spotlight-results-wrap {
  max-height: 440px;
  overflow-y: auto;
  padding: 0.5rem;
  scrollbar-width: thin;
  scrollbar-color: rgba(46, 185, 106, 0.4) transparent;
}

.spotlight-results-wrap::-webkit-scrollbar {
  width: 6px;
}
.spotlight-results-wrap::-webkit-scrollbar-thumb {
  background: rgba(46, 185, 106, 0.35);
  border-radius: 4px;
}

.spotlight-results-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.spotlight-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1.1rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.15s ease;
}

.spotlight-item:hover,
.spotlight-item.selected {
  background: rgba(46, 185, 106, 0.12);
  border-color: rgba(46, 185, 106, 0.35);
  transform: translateX(3px);
}

.spotlight-item-content {
  flex: 1;
  min-width: 0;
}

.spotlight-item-header {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.35rem;
}

.spotlight-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  background: rgba(46, 185, 106, 0.16);
  color: #34D399;
  border: 1px solid rgba(46, 185, 106, 0.28);
  white-space: nowrap;
}

.spotlight-item-meta {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.spotlight-item-title {
  font-family: var(--font-heading);
  font-size: 1.02rem;
  font-weight: 600;
  color: #FFFFFF;
  line-height: 1.35;
  margin: 0 0 0.25rem 0;
}

.spotlight-item-excerpt {
  font-size: 0.83rem;
  color: var(--text-secondary);
  line-height: 1.45;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.spotlight-item-action {
  color: var(--text-muted);
  display: flex;
  align-items: center;
  transition: transform 0.15s ease, color 0.15s ease;
  flex-shrink: 0;
}

.spotlight-item:hover .spotlight-item-action,
.spotlight-item.selected .spotlight-item-action {
  color: var(--btn-primary);
  transform: translateX(3px);
}

.spotlight-mark {
  background: rgba(46, 185, 106, 0.28);
  color: #6EE7B7;
  font-weight: 700;
  padding: 1px 3px;
  border-radius: 3px;
}

.spotlight-empty-state {
  text-align: center;
  padding: 3rem 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.spotlight-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.25rem;
  background: rgba(14, 24, 19, 0.85);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.8rem;
  color: var(--text-muted);
}

.spotlight-shortcuts {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.spotlight-shortcut {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

.spotlight-shortcut kbd {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 4px;
  padding: 1px 5px;
  font-family: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-secondary);
}

.spotlight-deep-link {
  color: var(--btn-primary);
  text-decoration: none;
  font-weight: 600;
  transition: color var(--transition-fast);
}

.spotlight-deep-link:hover {
  color: #34D399;
  text-decoration: underline;
}

/* ==========================================================================
 *   Inline Live Search & Filter Pill Bar (above content grid)
 *   ========================================================================== */
.inline-filter-system {
  margin: 2.25rem 0 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.inline-search-row {
  max-width: 640px;
  margin: 0 auto;
  width: 100%;
  position: relative;
}

.inline-search-box {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.inline-search-box .search-prefix-icon {
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--btn-primary);
  pointer-events: none;
  display: flex;
  align-items: center;
}

.inline-search-input {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid rgba(46, 185, 106, 0.3);
  border-radius: var(--radius-full);
  padding: 0.85rem 3rem 0.85rem 3.1rem;
  color: var(--text-primary);
  font-size: 0.98rem;
  outline: none;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
  transition: all var(--transition-fast);
}

.inline-search-input:focus {
  border-color: var(--btn-primary);
  box-shadow: 0 0 0 3px rgba(46, 185, 106, 0.2), 0 6px 24px rgba(0, 0, 0, 0.35);
  background: #111B16;
}

.inline-search-clear-btn {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: var(--text-secondary);
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.inline-search-clear-btn:hover {
  background: rgba(239, 68, 68, 0.3);
  color: #FFFFFF;
}

.inline-filter-pills-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.filter-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 0.5rem 1.05rem;
  border-radius: var(--radius-full);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
}

.filter-pill:hover {
  border-color: var(--btn-primary);
  color: #FFFFFF;
  background: rgba(46, 185, 106, 0.1);
  transform: translateY(-1px);
}

.filter-pill.active {
  background: var(--btn-primary);
  color: #FFFFFF;
  border-color: var(--btn-primary);
  box-shadow: 0 3px 12px rgba(46, 185, 106, 0.35);
}

.pill-count {
  display: inline-block;
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.12);
  color: inherit;
  transition: background var(--transition-fast);
}

.filter-pill.active .pill-count {
  background: rgba(0, 0, 0, 0.25);
  color: #FFFFFF;
}

.inline-filter-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  padding: 0.6rem 0.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.inline-status-badge {
  font-weight: 700;
  color: var(--btn-primary);
  font-size: 0.94rem;
}

.inline-reset-btn {
  background: transparent;
  border: 1px dashed rgba(255, 255, 255, 0.2);
  color: var(--text-muted);
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.inline-reset-btn:hover {
  border-color: rgba(239, 68, 68, 0.5);
  color: #F87171;
  background: rgba(239, 68, 68, 0.1);
}

@media (max-width: 640px) {
  .spotlight-overlay {
    padding: 1rem 0.75rem;
  }
  .spotlight-footer {
    flex-direction: column;
    gap: 0.5rem;
    align-items: flex-start;
  }
  .spotlight-kbd-badge {
    display: none;
  }
  .spotlight-close-btn {
    display: inline-flex;
  }
  .spotlight-header {
    gap: 0.6rem;
    padding: 0.85rem 1rem;
  }
  .spotlight-input {
    min-width: 0;
    font-size: 1rem;
  }
  .inline-filter-pills-bar {
    justify-content: flex-start;
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 0.4rem;
    scrollbar-width: none;
  }
  .inline-filter-pills-bar::-webkit-scrollbar {
    display: none;
  }
}





/* ==========================================================================
 *   Rich article components (ac-*) – used by long-form articles
 *   (e.g. "Jezus (Isa) skozi prizmo Kur’ana in Biblije"). Mobile-first.
 *   ========================================================================== */
.article-content .ac-lead {
  font-size: 1.18rem;
  line-height: 1.8;
  color: var(--text-heading);
  border-left: 4px solid var(--gold-metallic);
  padding: 0.25rem 0 0.25rem 1.15rem;
  margin-bottom: 1.75rem;
}
.article-content .ac-toc {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  margin: 0 0 2.25rem;
  overflow: hidden;
}
.article-content .ac-toc summary {
  cursor: pointer;
  list-style: none;
  padding: 0.95rem 1.25rem;
  font-weight: 700;
  color: var(--text-heading);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  -webkit-tap-highlight-color: transparent;
}
.article-content .ac-toc summary::-webkit-details-marker { display: none; }
.article-content .ac-toc summary::after {
  content: "+";
  font-size: 1.35rem;
  line-height: 1;
  color: var(--btn-primary);
  transition: transform var(--transition-fast);
}
.article-content .ac-toc[open] summary::after { transform: rotate(45deg); }
.article-content .ac-toc ol {
  margin: 0 !important;
  padding: 0 1.25rem 1.1rem 2.6rem !important;
  columns: 2;
  column-gap: 2rem;
}
.article-content .ac-toc li { margin-bottom: 0.35rem; font-size: 0.97rem; break-inside: avoid; }
.article-content .ac-toc li a { color: var(--text-primary); text-decoration: none; }
.article-content .ac-toc li a:hover { color: var(--btn-primary); }
.article-content h2[id], .article-content h3[id] { scroll-margin-top: 90px; }

.article-content .ac-section-title {
  display: flex;
  align-items: baseline;
  gap: 0.7rem;
  font-size: clamp(1.4rem, 3.6vw, 1.75rem);
  line-height: 1.3;
  padding-top: 0.5rem;
}
.article-content .ac-section-title .ac-num {
  flex: 0 0 auto;
  font-size: 0.8em;
  color: var(--gold-metallic);
  font-weight: 800;
}

/* Inline links inside rich articles */
.article-content:has(.ac-lead) p a,
.article-content:has(.ac-lead) li a,
.article-content:has(.ac-lead) .ac-parallel a {
  color: var(--btn-primary);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

/* Read-more card linking to a related article */
.article-content .ac-readmore {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 1.75rem 0 2.25rem;
  padding: 1.1rem 1.25rem;
  background: linear-gradient(135deg, rgba(46,185,106,0.14), rgba(46,185,106,0.04));
  border: 1px solid var(--border-green);
  border-radius: var(--radius-lg);
  text-decoration: none !important;
  color: var(--text-primary);
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}
.article-content .ac-readmore:hover { transform: translateY(-2px); border-color: var(--btn-primary); }
.article-content .ac-readmore-icon {
  flex: 0 0 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--btn-primary);
  color: #fff;
  font-size: 1.25rem;
}
.article-content .ac-readmore-text { display: flex; flex-direction: column; gap: 0.15rem; min-width: 0; }
.article-content .ac-readmore-kicker { font-size: 0.78rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--btn-primary); }
.article-content .ac-readmore-title { font-weight: 700; color: var(--text-heading); line-height: 1.4; }

/* Callout */
.article-content .ac-note {
  margin: 1.75rem 0;
  padding: 1.15rem 1.35rem;
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-lg);
}
.article-content .ac-note > *:last-child { margin-bottom: 0; }
.article-content .ac-note-title {
  display: block;
  font-weight: 800;
  color: var(--gold-metallic);
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

/* Scholar / author profile card */
.article-content .ac-author {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 1.4rem;
  align-items: start;
  margin: 2rem 0;
  padding: 1.4rem;
  background: linear-gradient(160deg, var(--bg-card) 0%, var(--bg-card-subtle) 100%);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}
.article-content .ac-author { row-gap: 0.4rem; }
.article-content .ac-author-photo { margin: 0; grid-row: 1 / span 3; }
.article-content .ac-author-info,
.article-content .ac-author-facts,
.article-content .ac-author-books { grid-column: 2; }
.article-content .ac-author-photo img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: var(--radius-md);
  border: 2px solid var(--border-gold);
  display: block;
}
.article-content .ac-author-photo figcaption { font-size: 0.68rem; color: var(--text-muted); margin-top: 0.35rem; line-height: 1.35; }
.article-content .ac-author-kicker { font-size: 0.76rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gold-metallic); }
.article-content .ac-author-name { font-family: var(--font-heading); font-size: 1.5rem; font-weight: 800; color: var(--text-heading); line-height: 1.25; margin: 0.15rem 0 0.35rem; }
.article-content .ac-author-role { font-size: 0.95rem; color: var(--text-muted); margin-bottom: 0.8rem !important; line-height: 1.55; }
.article-content .ac-author-facts {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 0 0.9rem !important;
  display: grid;
  gap: 0.45rem;
}
.article-content .ac-author-facts li {
  padding-left: 0 !important;
  margin: 0 !important;
  font-size: 0.95rem;
  line-height: 1.55;
  display: grid;
  grid-template-columns: 1.4rem minmax(0, 1fr);
}
.article-content .ac-author-facts li::before { content: "◆"; color: var(--btn-primary); font-size: 0.7rem; padding-top: 0.3rem; }
.article-content .ac-author-books { display: flex; flex-wrap: wrap; gap: 0.45rem; }
.article-content .ac-chip {
  display: inline-block;
  padding: 0.25rem 0.7rem;
  font-size: 0.8rem;
  font-style: italic;
  color: var(--text-primary);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 999px;
}

/* Big scholar quotation (original + translation) */
.article-content .ac-scholar-quote {
  position: relative;
  margin: 2rem 0;
  padding: 2.1rem 1.6rem 1.4rem;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-top: 4px solid var(--gold-metallic);
  border-radius: var(--radius-lg);
}
.article-content .ac-scholar-quote::before {
  content: "“";
  position: absolute;
  top: -0.2rem;
  left: 1rem;
  font-family: Georgia, serif;
  font-size: 4.5rem;
  line-height: 1;
  color: var(--gold-metallic);
  opacity: 0.55;
}
.article-content .ac-scholar-quote .ac-sq-sl { font-size: 1.15rem; line-height: 1.8; color: var(--text-heading); font-weight: 500; margin-bottom: 1rem; }
.article-content .ac-scholar-quote .ac-sq-en { font-size: 0.93rem; line-height: 1.7; color: var(--text-muted); font-style: italic; border-left: 2px solid var(--border-subtle); padding-left: 0.9rem; margin-bottom: 1rem; }
.article-content .ac-scholar-quote .ac-sq-src { font-size: 0.85rem; color: var(--gold-metallic); font-weight: 600; margin: 0; }

/* Stat tiles */
.article-content .ac-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.9rem;
  margin: 1.5rem 0 1.75rem;
}
.article-content .ac-stat {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1rem 1.05rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.article-content .ac-stat-value { font-family: var(--font-heading); font-size: 1.65rem; font-weight: 800; color: var(--gold-metallic); line-height: 1.15; }
.article-content .ac-stat-label { font-size: 0.9rem; font-weight: 700; color: var(--text-heading); line-height: 1.35; }
.article-content .ac-stat-sub { font-size: 0.83rem; color: var(--text-muted); line-height: 1.45; }

/* Figures */
.article-content .ac-figure { margin: 1.75rem 0 2rem; }
.article-content .ac-figure img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  background: var(--bg-card);
}
.article-content .ac-figure figcaption { font-size: 0.86rem; color: var(--text-muted); line-height: 1.55; margin-top: 0.6rem; text-align: center; }
.article-content .ac-figure-side {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
  gap: 1.25rem;
  align-items: center;
  margin: 1.75rem 0 2rem;
  padding: 1.1rem;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
}
.article-content .ac-figure-side figure { margin: 0; }
.article-content .ac-figure-side img { width: 100%; height: auto; display: block; border-radius: var(--radius-md); }
.article-content .ac-figure-side p { margin-bottom: 0.6rem; font-size: 0.98rem; line-height: 1.7; }
.article-content .ac-figure-side p:last-child { margin-bottom: 0; }
.article-content .ac-figure-side .ac-caption-small { font-size: 0.78rem; color: var(--text-muted); }
.article-content .ac-map { max-width: 560px; margin-left: auto; margin-right: auto; }

/* Aramaic ↔ Arabic comparison table */
.article-content .ac-table-wrap { margin: 1.5rem 0 2rem; }
.article-content .ac-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  font-size: 0.97rem;
}
.article-content .ac-table caption { caption-side: bottom; font-size: 0.82rem; color: var(--text-muted); padding-top: 0.6rem; text-align: left; line-height: 1.5; }
.article-content .ac-table th {
  background: var(--bg-secondary);
  color: var(--gold-metallic);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-align: left;
  padding: 0.8rem 1rem;
}
.article-content .ac-table td {
  padding: 0.8rem 1rem;
  border-top: 1px solid var(--border-subtle);
  vertical-align: middle;
  line-height: 1.45;
}
.article-content .ac-table tbody tr:nth-child(even) td { background: rgba(255,255,255,0.025); }
.article-content .ac-table .ac-n { color: var(--text-muted); font-weight: 700; width: 2.2rem; text-align: center; }
.article-content .ac-table .ac-mean { font-weight: 700; color: var(--text-heading); }
.article-content .ac-table .ac-mean small { display: block; font-weight: 400; color: var(--text-muted); font-size: 0.82rem; margin-top: 0.15rem; }
.article-content .ac-script { font-size: 1.45rem; line-height: 1.5; color: #fff; direction: rtl; text-align: left; }
.article-content .ac-script-syr { font-family: 'Noto Sans Syriac', 'Estrangelo Edessa', 'Serto Jerusalem', sans-serif; font-size: 1.3rem; }
.article-content .ac-script-ar { font-family: 'Amiri', 'Amiri Quran', serif; font-size: 1.55rem; }
.article-content .ac-translit { display: block; font-size: 0.9rem; color: var(--btn-primary); font-weight: 600; font-style: italic; }
.article-content .ac-table .ac-arabic-col .ac-translit { color: var(--gold-metallic); }

/* Bible verse card */
.article-content blockquote.ac-bible {
  position: relative;
  margin: 1.4rem 0 1.6rem;
  padding: 1.15rem 1.35rem 1.15rem 1.35rem;
  background: linear-gradient(135deg, rgba(212,175,55,0.09), rgba(212,175,55,0.02));
  border-left: 4px solid var(--gold-metallic);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  font-style: normal;
  color: var(--text-heading);
  font-size: 1.1rem;
  line-height: 1.75;
}
.article-content blockquote.ac-bible cite {
  display: table;
  margin-top: 0.65rem;
  font-style: normal;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--bg-secondary);
  background: var(--gold-metallic);
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
}
.article-content blockquote.ac-bible .ac-verse-num { color: var(--gold-metallic); font-weight: 700; font-size: 0.8em; vertical-align: super; margin-right: 0.15rem; }
.article-content .ac-bible-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin: 1.4rem 0 1.6rem; }
.article-content .ac-bible-pair blockquote.ac-bible { margin: 0; }

/* Quran translation under an Arabic quote */
.article-content blockquote.ac-quran-tr {
  margin-top: -0.4rem;
  background: var(--bg-surface);
  border-left: 4px solid var(--btn-primary);
  font-style: normal;
  color: var(--text-primary);
}
.article-content blockquote.ac-quran-tr cite { display: block; margin-top: 0.5rem; font-style: normal; font-size: 0.86rem; font-weight: 700; color: var(--btn-primary); }

/* Small lesson cards (e.g. clothing in 1st-century Palestine) */
.article-content .ac-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.9rem; margin: 1.4rem 0 2rem; }
.article-content .ac-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.05rem 1.15rem;
}
.article-content .ac-card-icon { font-size: 1.5rem; line-height: 1; margin-bottom: 0.45rem; display: block; }
.article-content .ac-card-title { display: block; font-weight: 800; color: var(--text-heading); margin-bottom: 0.3rem; font-size: 1.02rem; }
.article-content .ac-card p { font-size: 0.95rem; line-height: 1.65; margin: 0; color: var(--text-primary); }

/* Parallel / "the same in Islam" mini-callout */
.article-content .ac-parallel {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  margin: 0.4rem 0 2rem;
  padding: 0.9rem 1.1rem;
  background: rgba(46,185,106,0.08);
  border: 1px dashed var(--border-green);
  border-radius: var(--radius-md);
  font-size: 1rem;
  line-height: 1.7;
}
.article-content .ac-parallel-badge {
  flex: 0 0 auto;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #fff;
  background: var(--btn-primary);
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
  margin-top: 0.2rem;
}

/* Highlighted hadith / central message panel */
.article-content .ac-hadith {
  position: relative;
  margin: 2.5rem 0;
  padding: 2.4rem 1.75rem 1.9rem;
  border-radius: 20px;
  border: 1px solid rgba(212,175,55,0.45);
  background:
    radial-gradient(circle at 15% 0%, rgba(212,175,55,0.22), transparent 55%),
    radial-gradient(circle at 100% 100%, rgba(46,185,106,0.20), transparent 55%),
    repeating-linear-gradient(45deg, rgba(212,175,55,0.05) 0 2px, transparent 2px 22px),
    repeating-linear-gradient(-45deg, rgba(212,175,55,0.05) 0 2px, transparent 2px 22px),
    linear-gradient(160deg, #1c2a3a 0%, #142130 100%);
  box-shadow: 0 18px 45px rgba(0,0,0,0.35), inset 0 0 0 6px rgba(212,175,55,0.06);
  overflow: hidden;
  text-align: center;
}
.article-content .ac-hadith-label {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #1a2532;
  background: var(--gold-metallic);
  padding: 0.3rem 0.9rem;
  border-radius: 999px;
  margin-bottom: 1.2rem;
}
.article-content .ac-hadith-ar {
  font-family: 'Amiri', 'Amiri Quran', serif;
  font-size: clamp(1.65rem, 5vw, 2.35rem);
  line-height: 1.9;
  color: #fff;
  direction: rtl;
  text-align: center;
  margin: 0 0 1.1rem;
  text-shadow: 0 2px 12px rgba(0,0,0,0.4);
}
.article-content .ac-hadith-tr {
  font-size: clamp(1.08rem, 2.6vw, 1.28rem) !important;
  line-height: 1.75;
  color: var(--text-heading);
  font-weight: 600;
  max-width: 40rem;
  margin: 0 auto 0.85rem !important;
  text-align: center !important;
}
.article-content .ac-hadith-src { font-size: 0.88rem; color: var(--gold-metallic); font-weight: 700; margin: 0 !important; text-align: center !important; }
.article-content .ac-hadith-divider {
  width: 120px;
  height: 1px;
  margin: 1.3rem auto;
  background: linear-gradient(90deg, transparent, var(--gold-metallic), transparent);
}
.article-content .ac-hadith .ac-hadith-body { text-align: left; }
.article-content .ac-hadith .ac-hadith-body p { text-align: left !important; }

.article-content .ac-closing {
  margin: 2.5rem 0 1rem;
  padding: 1.25rem 1.4rem;
  text-align: center;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}
.article-content .ac-closing-ar { font-family: 'Amiri', serif; font-size: 1.7rem; color: var(--gold-metallic); direction: rtl; display: block; margin-bottom: 0.25rem; }
.article-content .ac-closing p { text-align: center !important; margin: 0 !important; font-weight: 600; color: var(--text-heading); }

/* ---- Tablet ---- */
@media (max-width: 820px) {
  .article-content .ac-stats { grid-template-columns: 1fr; }
  .article-content .ac-stat { flex-direction: row; flex-wrap: wrap; align-items: baseline; column-gap: 0.75rem; }
  .article-content .ac-stat-sub { flex-basis: 100%; }
}

/* ---- Phones ---- */
@media (max-width: 640px) {
  .article-content .ac-lead { font-size: 1.07rem; padding-left: 0.9rem; }
  .article-content .ac-toc ol { columns: 1; padding-left: 2.2rem !important; }
  .article-content .ac-readmore { padding: 0.95rem 1rem; gap: 0.8rem; }
  .article-content .ac-readmore-icon { flex-basis: 38px; height: 38px; font-size: 1.05rem; }

  .article-content .ac-author { grid-template-columns: 96px minmax(0, 1fr); gap: 0.95rem; padding: 1.05rem; }
  .article-content .ac-author-name { font-size: 1.22rem; }
  .article-content .ac-author-role { font-size: 0.88rem; }
  .article-content .ac-author { row-gap: 0.9rem; }
  .article-content .ac-author-photo { grid-row: auto; }
  .article-content .ac-author-facts,
  .article-content .ac-author-books { grid-column: 1 / -1; }
  .article-content .ac-author-facts li { font-size: 0.92rem; }

  .article-content .ac-scholar-quote { padding: 1.9rem 1.1rem 1.15rem; }
  .article-content .ac-scholar-quote .ac-sq-sl { font-size: 1.04rem; }

  .article-content .ac-figure-side { grid-template-columns: 1fr; }
  .article-content .ac-figure-side figure { max-width: 220px; margin: 0 auto; }

  .article-content .ac-bible-pair,
  .article-content .ac-cards { grid-template-columns: 1fr; }
  .article-content blockquote.ac-bible { font-size: 1.03rem; padding: 1rem 1.05rem; }

  /* Comparison table becomes a stack of cards */
  .article-content .ac-table,
  .article-content .ac-table tbody,
  .article-content .ac-table tr,
  .article-content .ac-table td { display: block; width: 100%; }
  .article-content .ac-table { background: transparent; border: none; overflow: visible; }
  .article-content .ac-table thead { display: none; }
  .article-content .ac-table caption { display: block; }
  .article-content .ac-table tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    margin-bottom: 0.7rem;
    overflow: hidden;
  }
  .article-content .ac-table tbody tr:nth-child(even) td { background: transparent; }
  .article-content .ac-table td { border-top: none; padding: 0.65rem 0.85rem; }
  .article-content .ac-table .ac-n { display: none; }
  .article-content .ac-table .ac-mean { grid-column: 1 / -1; background: var(--bg-secondary) !important; padding: 0.55rem 0.85rem; }
  .article-content .ac-table td[data-label]::before {
    content: attr(data-label);
    display: block;
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.2rem;
  }
  .article-content .ac-table .ac-arabic-col { border-left: 1px solid var(--border-subtle); }
  .article-content .ac-script { font-size: 1.3rem; }
  .article-content .ac-script-ar { font-size: 1.45rem; }

  .article-content .ac-parallel { flex-direction: column; gap: 0.45rem; }
  .article-content .ac-hadith { padding: 2rem 1.05rem 1.5rem; border-radius: 16px; margin-left: -0.25rem; margin-right: -0.25rem; }
  .article-content .ac-closing-ar { font-size: 1.5rem; }
}

/* ---- ac-* additions: subtitle, split comparison, timeline, pull quote, questions, sources ---- */
.article-content .ac-subtitle {
  font-family: var(--font-heading);
  font-size: clamp(1.15rem, 3vw, 1.4rem);
  font-style: italic;
  line-height: 1.6;
  color: var(--gold-metallic);
  text-align: center !important;
  margin: 0.5rem auto 2rem !important;
  max-width: 40rem;
  padding: 1.1rem 0.5rem;
  border-top: 1px solid rgba(212,175,55,0.35);
  border-bottom: 1px solid rgba(212,175,55,0.35);
}
.article-content .ac-split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin: 1.75rem 0 2rem;
}
.article-content .ac-split-col {
  border-radius: var(--radius-lg);
  padding: 1.2rem 1.25rem;
  border: 1px solid var(--border-subtle);
  background: var(--bg-card);
}
.article-content .ac-split-col.ac-paid { border-top: 4px solid #e0626b; background: linear-gradient(180deg, rgba(224,98,107,0.10), var(--bg-card) 60%); }
.article-content .ac-split-col.ac-punished { border-top: 4px solid var(--btn-primary); background: linear-gradient(180deg, rgba(46,185,106,0.10), var(--bg-card) 60%); }
.article-content .ac-split-title { display: block; font-weight: 800; font-size: 1.05rem; color: var(--text-heading); margin-bottom: 0.75rem; line-height: 1.35; }
.article-content .ac-split-col ul { margin: 0 !important; padding-left: 1.2rem !important; }
.article-content .ac-split-col li { font-size: 0.95rem; line-height: 1.6; margin-bottom: 0.45rem; }
.article-content .ac-split-col.ac-paid li::marker { color: #e0626b; }

.article-content .ac-timeline {
  list-style: none !important;
  margin: 1.5rem 0 2rem !important;
  padding: 0 0 0 1.5rem !important;
  border-left: 2px solid var(--border-gold);
}
.article-content .ac-timeline li {
  position: relative;
  padding: 0 0 1.1rem 0.4rem !important;
  margin: 0 !important;
  font-size: 0.98rem;
  line-height: 1.6;
}
.article-content .ac-timeline li::before {
  content: "";
  position: absolute;
  left: calc(-1.5rem - 7px);
  top: 0.45rem;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--gold-metallic);
  box-shadow: 0 0 0 4px var(--bg-primary);
}
.article-content .ac-timeline .ac-year { display: inline-block; font-weight: 800; color: var(--gold-metallic); margin-right: 0.4rem; min-width: 3rem; }

.article-content .ac-pullquote {
  margin: 2.25rem 0;
  padding: 1.5rem 1.25rem;
  text-align: center !important;
  font-family: var(--font-heading);
  font-size: clamp(1.25rem, 3.4vw, 1.6rem);
  line-height: 1.5;
  font-weight: 700;
  color: var(--text-heading);
  background: radial-gradient(circle at 50% 0%, rgba(212,175,55,0.14), transparent 70%);
  border-top: 2px solid var(--gold-metallic);
  border-bottom: 2px solid var(--gold-metallic);
}
.article-content .ac-pullquote em { color: var(--gold-metallic); font-style: normal; }

.article-content .ac-questions { display: grid; gap: 0.7rem; margin: 1.5rem 0 2rem; }
.article-content .ac-question {
  display: grid;
  grid-template-columns: 2.2rem minmax(0, 1fr);
  gap: 0.6rem;
  align-items: start;
  padding: 0.85rem 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-heading);
}
.article-content .ac-question::before {
  content: "?";
  display: grid;
  place-items: center;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  background: rgba(212,175,55,0.15);
  color: var(--gold-metallic);
  font-weight: 800;
  font-size: 1.15rem;
}
.article-content .ac-fathers { display: grid; gap: 1rem; margin: 1.5rem 0 2rem; }
.article-content .ac-father {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-left: 4px solid var(--gold-metallic);
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
  padding: 1.1rem 1.3rem;
}
.article-content .ac-father-name { display: block; font-family: var(--font-heading); font-weight: 800; font-size: 1.12rem; color: var(--text-heading); }
.article-content .ac-father-meta { display: block; font-size: 0.85rem; color: var(--text-muted); margin-bottom: 0.65rem; }
.article-content .ac-father p { margin-bottom: 0.6rem; font-size: 1rem; line-height: 1.7; }
.article-content .ac-father p:last-child { margin-bottom: 0; }
.article-content .ac-father .ac-father-quote { font-size: 1.08rem; color: var(--text-heading); font-weight: 500; }

.article-content .ac-sources {
  margin: 2.5rem 0 1rem;
  padding: 1.1rem 1.25rem;
  background: var(--bg-card-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
}
.article-content .ac-sources summary { cursor: pointer; font-weight: 700; color: var(--text-heading); }
.article-content .ac-sources ol { margin: 0.8rem 0 0 !important; padding-left: 1.4rem !important; }
.article-content .ac-sources li { font-size: 0.85rem; line-height: 1.55; color: var(--text-muted); margin-bottom: 0.35rem; }

@media (max-width: 640px) {
  .article-content .ac-split { grid-template-columns: 1fr; }
  .article-content .ac-timeline { padding-left: 1.2rem !important; }
  .article-content .ac-timeline li::before { left: calc(-1.2rem - 7px); }
  .article-content .ac-pullquote { padding: 1.2rem 0.5rem; }
  .article-content .ac-father { padding: 1rem 1.05rem; }
}
