/* ==========================================================================
   ILMI BOOKS — Premium Monochromatic Emerald Green Storefront Stylesheet
   Designed for Authentic Classical Islamic Literature & Hadith Books
   Strict Mobile-First, Smooth CSS Animations, Zero Fluff
   ========================================================================== */

/* --- Fonts & CSS Variables --- */
@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@500;600;700;800;900&family=Amiri:ital,wght@0,400;0,700;1,400&family=Plus+Jakarta+Sans:wght@300;400;500;600;700&display=swap');

:root {
  /* Monochromatic Emerald Green Palette */
  --emerald-950: #011d16;
  --emerald-900: #022c22;
  --emerald-850: #033a2e;
  --emerald-800: #064e3b;
  --emerald-700: #047857;
  --emerald-600: #059669;
  --emerald-500: #10b981;
  --emerald-400: #34d399;
  --emerald-200: #a7f3d0;
  --emerald-100: #d1fae5;
  --emerald-50:  #ecfdf5;

  /* Subtle Gold & Brass Accents */
  --gold-300: #fef08a;
  --gold-400: #facc15;
  --gold-500: #d4af37;
  --gold-600: #b8860b;
  --gold-700: #926707;
  --gold-border: rgba(212, 175, 55, 0.35);
  --gold-glow: rgba(212, 175, 55, 0.18);

  /* Clean White & Neutral Tones */
  --bg-white: #ffffff;
  --bg-page: #fbfdfc;
  --bg-surface: #f4f8f5;
  --bg-subtle: #edf3ee;
  
  --text-main: #0f241d;
  --text-muted: #4b6358;
  --text-light: #718a7f;
  --text-inverse: #ffffff;

  --border-light: #e3ede6;
  --border-subtle: #d2e3d7;
  
  /* Layout & Elevations */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  --shadow-sm: 0 2px 4px rgba(2, 44, 34, 0.04);
  --shadow-md: 0 4px 16px rgba(2, 44, 34, 0.08);
  --shadow-lg: 0 10px 30px rgba(2, 44, 34, 0.12);
  --shadow-xl: 0 20px 45px rgba(2, 44, 34, 0.16);

  --font-serif: 'Cinzel', Georgia, 'Times New Roman', serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-arabic: 'Amiri', 'Traditional Arabic', serif;

  --transition-fast: 0.18s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.28s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: 0.4s cubic-bezier(0.16, 1, 0.3, 1);

  --container-max: 1240px;
}

/* --- Base & Reset --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-page);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  position: relative;
}

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

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

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  outline: none;
  border: none;
}

button {
  cursor: pointer;
  background: none;
}

/* --- Accessibility & Focus --- */
:focus-visible {
  outline: 2px solid var(--emerald-600);
  outline-offset: 2px;
}

/* --- Keyframe Animations --- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(22px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

@keyframes gentlePulse {
  0% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.45);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(16, 185, 129, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

@keyframes goldGlow {
  0%, 100% {
    border-color: rgba(212, 175, 55, 0.4);
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.1);
  }
  50% {
    border-color: rgba(212, 175, 55, 0.8);
    box-shadow: 0 0 25px rgba(212, 175, 55, 0.25);
  }
}

@keyframes toastSlideIn {
  from {
    transform: translateY(100%) scale(0.9);
    opacity: 0;
  }
  to {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

@keyframes modalScaleIn {
  from {
    transform: scale(0.94);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

/* Utility Animations */
.animate-fade-in-up {
  animation: fadeInUp 0.7s var(--transition-smooth) forwards;
}

.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }

/* --- Container --- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: 20px;
  padding-right: 20px;
}

@media (max-width: 480px) {
  .container {
    padding-left: 14px;
    padding-right: 14px;
  }
}

@media (min-width: 768px) {
  .container {
    padding-left: 32px;
    padding-right: 32px;
  }
}

/* --- Top Announcement Bar --- */
.announcement-bar {
  background: var(--emerald-950);
  color: var(--emerald-100);
  font-size: 0.82rem;
  letter-spacing: 0.5px;
  padding: 8px 16px;
  text-align: center;
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  position: relative;
  z-index: 40;
  width: 100%;
  max-width: 100vw;
  box-sizing: border-box;
}

@media (max-width: 600px) {
  .announcement-bar {
    flex-direction: column;
    padding: 6px 10px;
    gap: 3px;
    font-size: 0.72rem;
    line-height: 1.3;
  }
}

.announcement-bar .bismillah {
  font-family: var(--font-arabic);
  font-size: 1rem;
  color: var(--gold-400);
  margin-right: 4px;
}

@media (max-width: 600px) {
  .announcement-bar .bismillah {
    font-size: 0.85rem;
    margin-right: 0;
  }
}

.announcement-badge {
  background: rgba(212, 175, 55, 0.18);
  border: 1px solid rgba(212, 175, 55, 0.4);
  color: var(--gold-300);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  display: inline-block;
  white-space: normal;
  max-width: 100%;
  text-align: center;
}

@media (max-width: 600px) {
  .announcement-badge {
    font-size: 0.62rem;
    padding: 1px 6px;
    letter-spacing: 0.5px;
  }
}

/* --- Header --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-light);
  box-shadow: 0 4px 20px rgba(2, 44, 34, 0.04);
  transition: all var(--transition-normal);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 74px;
}

/* Brand Logo */
.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.logo-symbol {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
}

@media (max-width: 480px) {
  .logo-symbol {
    width: 32px;
    height: 32px;
  }
}

.logo-text-group {
  display: flex;
  flex-direction: column;
}

.logo-title {
  font-family: var(--font-serif);
  font-size: 1.45rem;
  font-weight: 800;
  letter-spacing: 2px;
  color: var(--emerald-900);
  line-height: 1;
}

@media (max-width: 480px) {
  .logo-title {
    font-size: 1.12rem;
    letter-spacing: 0.8px;
  }
}

.logo-title span {
  color: var(--emerald-700);
}

.logo-tagline {
  font-family: var(--font-serif);
  font-size: 0.62rem;
  letter-spacing: 2px;
  color: var(--emerald-600);
  font-weight: 600;
  text-transform: uppercase;
  margin-top: 3px;
}

@media (max-width: 480px) {
  .logo-tagline {
    display: none;
  }
}

/* Desktop Navigation */
.nav-desktop {
  display: none;
}

@media (min-width: 992px) {
  .nav-desktop {
    display: flex;
    align-items: center;
    gap: 32px;
  }
}

.nav-link {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-muted);
  position: relative;
  padding: 6px 0;
  transition: color var(--transition-fast);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--emerald-700), var(--gold-500));
  transition: width var(--transition-normal);
}

.nav-link:hover,
.nav-link.active {
  color: var(--emerald-900);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* Header Actions */
.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

@media (max-width: 576px) {
  .header-inner {
    height: 62px;
  }
  .header-actions {
    gap: 6px;
  }
}

.action-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: var(--radius-full);
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  color: var(--emerald-900);
  position: relative;
  transition: all var(--transition-fast);
}

@media (max-width: 576px) {
  .action-btn {
    width: 36px;
    height: 36px;
  }
}

.action-btn:hover {
  background: var(--emerald-50);
  border-color: var(--emerald-200);
  color: var(--emerald-700);
  transform: translateY(-1px);
}

.cart-badge {
  position: absolute;
  top: -3px;
  right: -3px;
  background: var(--emerald-700);
  color: var(--bg-white);
  font-size: 0.72rem;
  font-weight: 700;
  min-width: 20px;
  height: 20px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
  border: 2px solid var(--bg-white);
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

/* Mobile Hamburger Toggle */
.mobile-toggle-btn {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  padding: 10px;
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  cursor: pointer;
  flex-shrink: 0;
}

@media (max-width: 576px) {
  .mobile-toggle-btn {
    width: 36px;
    height: 36px;
    padding: 8px;
    gap: 4px;
  }
}

@media (min-width: 992px) {
  .mobile-toggle-btn {
    display: none;
  }
}

.mobile-toggle-btn span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--emerald-900);
  border-radius: 2px;
  transition: transform var(--transition-fast), opacity var(--transition-fast);
}

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

/* Mobile Navigation Drawer */
.mobile-nav-drawer {
  position: fixed;
  top: 74px;
  left: 0;
  width: 100%;
  background: var(--bg-white);
  border-bottom: 1px solid var(--border-light);
  box-shadow: var(--shadow-xl);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transform: translateY(-110%);
  opacity: 0;
  pointer-events: none;
  transition: transform var(--transition-smooth), opacity var(--transition-smooth);
  z-index: 29;
}

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

.mobile-nav-link {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-main);
  padding: 10px 0;
  border-bottom: 1px solid var(--bg-surface);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.mobile-nav-link:hover {
  color: var(--emerald-700);
}

/* --- Hero / Text-Based Introduction Section --- */
/* Strict Rule: "The website MUST open directly with a brief, highly professional introduction text at the very top... DO NOT use a massive hero banner; use an elegantly animated, text-based introduction." */
.hero-intro-section {
  padding: 48px 0 36px;
  background: linear-gradient(180deg, #ffffff 0%, var(--bg-surface) 100%);
  border-bottom: 1px solid var(--border-light);
  position: relative;
  overflow: hidden;
}

.hero-intro-section::before {
  content: '';
  position: absolute;
  top: -120px;
  right: -120px;
  width: 380px;
  height: 380px;
  border-radius: var(--radius-full);
  background: radial-gradient(circle, rgba(16, 185, 129, 0.08) 0%, rgba(255,255,255,0) 70%);
  pointer-events: none;
}

@media (max-width: 768px) {
  .hero-intro-section::before {
    display: none;
  }
}

.hero-intro-content {
  text-align: center;
  max-width: 860px;
  margin: 0 auto;
}

.islamic-rosette-accent {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 18px;
}

.rosette-line {
  width: 60px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-500));
}
.rosette-line.right {
  background: linear-gradient(90deg, var(--gold-500), transparent);
}

.rosette-icon {
  width: 24px;
  height: 24px;
}

.hero-badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--emerald-50);
  border: 1px solid var(--emerald-200);
  color: var(--emerald-800);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 6px 18px;
  border-radius: var(--radius-full);
  margin-bottom: 16px;
}

.hero-main-title {
  font-family: var(--font-serif);
  font-size: 1.38rem;
  font-weight: 800;
  color: var(--emerald-950);
  letter-spacing: 0.5px;
  line-height: 1.25;
  margin-bottom: 14px;
  word-break: normal;
  overflow-wrap: break-word;
}

@media (min-width: 480px) {
  .hero-main-title {
    font-size: 1.8rem;
  }
}

@media (min-width: 768px) {
  .hero-main-title {
    font-size: 2.8rem;
  }
}

.hero-main-title span {
  color: var(--emerald-700);
  position: relative;
}

.hero-lead-text {
  font-size: 1.12rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 28px;
  font-weight: 400;
}

@media (min-width: 768px) {
  .hero-lead-text {
    font-size: 1.22rem;
  }
}

/* Trust Pillar Chips */
.hero-pillars-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin-top: 24px;
}

@media (min-width: 480px) {
  .hero-pillars-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
}

@media (min-width: 768px) {
  .hero-pillars-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
  }
}

.pillar-chip {
  background: var(--bg-white);
  border: 1px solid var(--border-light);
  padding: 14px 12px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.pillar-chip:hover {
  transform: translateY(-2px);
  border-color: var(--emerald-300);
}

.pillar-icon-box {
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  background: var(--emerald-50);
  color: var(--emerald-700);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.pillar-text {
  text-align: left;
}

.pillar-title {
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--emerald-900);
  line-height: 1.2;
}

.pillar-desc {
  font-size: 0.72rem;
  color: var(--text-light);
  line-height: 1.2;
  margin-top: 2px;
}

/* --- Catalog Filter & Search Section --- */
.catalog-controls-section {
  padding: 30px 0 16px;
  background: var(--bg-page);
}

.catalog-controls-bar {
  display: flex;
  flex-direction: column;
  gap: 16px;
  background: var(--bg-white);
  padding: 16px 20px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
  width: 100%;
}

@media (min-width: 768px) {
  .catalog-controls-bar {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.search-input-wrapper {
  position: relative;
  flex: 1;
  width: 100%;
  max-width: 480px;
}

.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-light);
  pointer-events: none;
}

.catalog-search-input {
  width: 100%;
  height: 44px;
  padding: 8px 14px 8px 42px;
  border-radius: var(--radius-full);
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  font-size: 0.92rem;
  color: var(--text-main);
  transition: all var(--transition-fast);
}

.catalog-search-input:focus {
  background: var(--bg-white);
  border-color: var(--emerald-600);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15);
}

.catalog-sort-wrapper {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  width: 100%;
}

@media (min-width: 600px) {
  .catalog-sort-wrapper {
    flex-direction: row;
    align-items: center;
    gap: 12px;
    width: auto;
  }
}

.catalog-count-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  white-space: normal;
}

.sort-select {
  height: 44px;
  width: 100%;
  padding: 0 34px 0 16px;
  border-radius: var(--radius-full);
  background: var(--bg-surface) 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='%23064e3b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 14px center;
  border: 1px solid var(--border-light);
  color: var(--emerald-900);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  transition: all var(--transition-fast);
}

@media (min-width: 600px) {
  .sort-select {
    width: auto;
  }
}

.sort-select:focus {
  border-color: var(--emerald-600);
}

/* ==========================================================================
   Interactive Featured Hadith Slider (Slide Showcase)
   ========================================================================== */
.featured-slider-section {
  padding: 10px 0 42px;
  background: var(--bg-page);
  position: relative;
}

.slider-wrapper {
  position: relative;
  background: linear-gradient(145deg, #ffffff 0%, var(--bg-surface) 100%);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  box-shadow: 0 12px 36px rgba(2, 44, 34, 0.08);
  overflow: hidden;
  padding: 36px 32px 28px;
}

@media (max-width: 768px) {
  .slider-wrapper {
    padding: 24px 18px 20px;
    border-radius: var(--radius-lg);
  }
}

.slider-track {
  position: relative;
  min-height: 440px;
}

@media (max-width: 991px) {
  .slider-track {
    min-height: auto;
  }
}

/* Individual Slide */
.slider-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateX(30px);
  transition: opacity 0.45s ease, transform 0.45s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.45s;
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  align-items: center;
}

.slider-slide.is-active {
  position: relative;
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(0);
}

@media (min-width: 992px) {
  .slider-slide {
    grid-template-columns: 340px 1fr;
    gap: 44px;
  }
}

/* Slide Media Presentation */
.slide-media {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at 50% 50%, #ffffff 0%, #edf5f0 70%, #dbe8de 100%);
  border-radius: var(--radius-lg);
  padding: 30px 20px;
  border: 1px solid var(--border-light);
  box-shadow: inset 0 0 30px rgba(6, 78, 59, 0.05);
}

.slide-image-frame {
  position: relative;
  width: 100%;
  max-width: 250px;
  aspect-ratio: 3 / 4;
  display: flex;
  align-items: center;
  justify-content: center;
}

.slide-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 16px 28px rgba(2, 44, 34, 0.22));
  transition: transform var(--transition-smooth);
}

.slide-media:hover .slide-image {
  transform: scale(1.04) translateY(-6px);
}

/* Floating Sold Pill on Slide Media */
.slide-sold-floating-tag {
  position: absolute;
  top: 14px;
  right: 14px;
  background: linear-gradient(135deg, var(--emerald-850), var(--emerald-950));
  color: #fffadb;
  border: 1px solid var(--gold-500);
  font-size: 0.76rem;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  gap: 5px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.18);
  animation: gentlePulse 2.5s infinite;
}

/* Slide Info Details */
.slide-info {
  display: flex;
  flex-direction: column;
}

.slide-header-badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.slide-rank-badge {
  background: var(--emerald-800);
  color: var(--emerald-50);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(212, 175, 55, 0.4);
}

.slide-sold-badge-glow {
  background: rgba(16, 185, 129, 0.12);
  color: var(--emerald-800);
  border: 1px solid var(--emerald-400);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.slide-arabic-title {
  font-family: var(--font-arabic);
  font-size: 1.85rem;
  font-weight: 700;
  color: var(--emerald-700);
  line-height: 1.25;
  margin-bottom: 4px;
}

.slide-english-title {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--emerald-950);
  line-height: 1.3;
  margin-bottom: 6px;
}

.slide-compiler {
  font-size: 0.88rem;
  color: var(--text-muted);
  font-style: italic;
  margin-bottom: 12px;
}

.slide-desc {
  font-size: 0.94rem;
  color: var(--text-main);
  line-height: 1.65;
  margin-bottom: 16px;
}

/* Sold meter bar in slide */
.slide-sold-meter {
  background: var(--bg-white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  margin-bottom: 16px;
}

.slide-sold-meter-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.82rem;
  margin-bottom: 6px;
}

.slide-sold-meter-label {
  font-weight: 700;
  color: var(--emerald-800);
  display: flex;
  align-items: center;
  gap: 5px;
}

.slide-sold-meter-left {
  color: var(--gold-700);
  font-weight: 600;
  font-size: 0.78rem;
}

.slide-sold-meter-track {
  height: 7px;
  background: var(--bg-subtle);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.slide-sold-meter-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--emerald-700), var(--emerald-500), var(--gold-500));
  border-radius: var(--radius-full);
  transition: width 0.8s ease;
}

.slide-specs-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.slide-spec-pill {
  font-size: 0.78rem;
  background: var(--bg-white);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  padding: 5px 11px;
  border-radius: var(--radius-sm);
  font-weight: 600;
}

.slide-action-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border-light);
}

.slide-price-tag {
  display: flex;
  flex-direction: column;
}

.slide-price-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-light);
  font-weight: 600;
}

.slide-price-val {
  font-family: var(--font-serif);
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--emerald-900);
  line-height: 1.1;
}

.slide-buttons-group {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.slide-add-cart-btn {
  background: var(--emerald-800);
  color: #ffffff;
  padding: 11px 22px;
  border-radius: var(--radius-md);
  font-size: 0.92rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid rgba(212, 175, 55, 0.4);
  box-shadow: 0 4px 14px rgba(6, 78, 59, 0.25);
  animation: gentlePulse 3s infinite;
  transition: all var(--transition-fast);
}

.slide-add-cart-btn:hover {
  background: var(--emerald-700);
  border-color: var(--gold-500);
  transform: translateY(-2px);
  animation: none;
}

.slide-quick-btn {
  background: var(--bg-white);
  color: var(--emerald-900);
  border: 1px solid var(--border-subtle);
  padding: 11px 18px;
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  font-weight: 600;
  transition: all var(--transition-fast);
}

.slide-quick-btn:hover {
  background: var(--emerald-50);
  border-color: var(--emerald-600);
  color: var(--emerald-700);
}

/* Slider Navigation Bar */
.slider-nav-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px dashed var(--border-light);
}

.slider-nav-btn {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-full);
  background: var(--bg-white);
  border: 1px solid var(--border-subtle);
  color: var(--emerald-900);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-fast);
}

.slider-nav-btn:hover {
  background: var(--emerald-800);
  color: #ffffff;
  border-color: var(--emerald-800);
  transform: scale(1.08);
}

.slider-dots {
  display: flex;
  align-items: center;
  gap: 8px;
}

.slider-dot {
  width: 10px;
  height: 10px;
  border-radius: var(--radius-full);
  background: var(--border-subtle);
  cursor: pointer;
  transition: all var(--transition-normal);
}

.slider-dot.is-active {
  width: 28px;
  background: var(--emerald-700);
  box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.25);
}

.slider-counter {
  font-family: var(--font-serif);
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--emerald-850);
  letter-spacing: 1px;
}

/* --- Section Headers --- */
.section-header {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 36px;
}

.section-tag {
  display: inline-block;
  font-family: var(--font-serif);
  font-size: 0.8rem;
  letter-spacing: 2px;
  color: var(--gold-600);
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.section-title {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--emerald-950);
  line-height: 1.3;
  margin-bottom: 12px;
  overflow-wrap: break-word;
}

@media (min-width: 576px) {
  .section-title {
    font-size: 1.85rem;
  }
}

@media (min-width: 768px) {
  .section-title {
    font-size: 2.3rem;
  }
}

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

@media (max-width: 576px) {
  .section-title {
    font-size: 1.25rem !important;
    letter-spacing: 0.5px !important;
    line-height: 1.35 !important;
    word-break: break-word !important;
  }
  .hero-main-title {
    font-size: 1.25rem !important;
    line-height: 1.35 !important;
    letter-spacing: 0.5px !important;
  }
  .hero-lead-text {
    font-size: 0.92rem !important;
    line-height: 1.6 !important;
  }
  .slide-arabic-title {
    font-size: 1.35rem !important;
  }
  .slide-english-title {
    font-size: 1.15rem !important;
    line-height: 1.3 !important;
    word-break: break-word !important;
  }
  .slide-media {
    padding: 16px 10px !important;
    position: relative;
    overflow: visible !important;
  }
  .slide-sold-floating-tag {
    top: 6px !important;
    right: 6px !important;
    font-size: 0.65rem !important;
    padding: 3px 8px !important;
  }
  .slide-sold-badge-glow {
    font-size: 0.72rem !important;
    padding: 3px 8px !important;
  }
  .slide-rank-badge {
    font-size: 0.7rem !important;
    padding: 3px 8px !important;
  }
  .slider-wrapper {
    padding: 16px 12px !important;
  }
}

/* --- Product Inventory Grid (Exact 6 Hadith Books) --- */
.products-section {
  padding: 24px 0 64px;
}

.product-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
}

@media (min-width: 576px) {
  .product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }
}

@media (min-width: 992px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
  }
}

/* Product Card — Smooth CSS Animations & Hover Effects */
.product-card {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
  position: relative;
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 16px 36px rgba(2, 44, 34, 0.12), 0 0 0 1px rgba(212, 175, 55, 0.4);
  border-color: rgba(212, 175, 55, 0.6);
}

/* Card Visual Header */
.product-card-media {
  position: relative;
  background: radial-gradient(circle at 50% 40%, #ffffff 0%, #f4f8f5 80%);
  padding: 28px 24px 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--border-light);
  overflow: hidden;
}

/* Uniform normal size image container */
.product-image-frame {
  position: relative;
  width: 100%;
  max-width: 250px;
  aspect-ratio: 3 / 4;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-card-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform var(--transition-smooth);
  filter: drop-shadow(0 10px 18px rgba(0, 30, 15, 0.15));
}

.product-card:hover .product-card-image {
  transform: scale(1.04) translateY(-4px);
  filter: drop-shadow(0 16px 24px rgba(0, 30, 15, 0.22));
}

/* Badges */
.card-badge-top {
  position: absolute;
  top: 14px;
  left: 14px;
  background: var(--emerald-800);
  color: var(--emerald-50);
  border: 1px solid rgba(212, 175, 55, 0.35);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  z-index: 2;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.card-sold-pill {
  position: absolute;
  top: 14px;
  right: 14px;
  background: rgba(2, 44, 34, 0.92);
  backdrop-filter: blur(4px);
  color: #fffadb;
  border: 1px solid var(--gold-500);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  z-index: 2;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
  display: flex;
  align-items: center;
  gap: 4px;
  animation: gentlePulse 3.5s infinite;
}

.card-quick-view-btn {
  position: absolute;
  bottom: 14px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-subtle);
  color: var(--emerald-900);
  font-size: 0.8rem;
  font-weight: 700;
  padding: 7px 16px;
  border-radius: var(--radius-full);
  opacity: 0;
  transform: translateY(8px);
  transition: all var(--transition-fast);
  z-index: 2;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.product-card:hover .card-quick-view-btn {
  opacity: 1;
  transform: translateY(0);
}

.card-quick-view-btn:hover {
  background: var(--emerald-700);
  color: var(--bg-white);
  border-color: var(--emerald-700);
}

/* Card Body */
.product-card-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.product-arabic-snippet {
  font-family: var(--font-arabic);
  font-size: 1.15rem;
  color: var(--emerald-700);
  line-height: 1.2;
  margin-bottom: 4px;
  font-weight: 700;
}

.product-title {
  font-family: var(--font-serif);
  font-size: 1.12rem;
  font-weight: 700;
  color: var(--emerald-950);
  line-height: 1.35;
  margin-bottom: 8px;
}

.product-specs-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}

.spec-pill {
  font-size: 0.72rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  color: var(--text-muted);
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  font-weight: 500;
}

/* Sold Progress Meter */
.sold-progress-box {
  margin: 6px 0 14px;
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 8px 10px;
}

.sold-progress-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 5px;
  font-size: 0.74rem;
}

.sold-badge-chip {
  font-weight: 700;
  color: var(--emerald-800);
  display: flex;
  align-items: center;
  gap: 4px;
}

.stock-left-label {
  color: var(--gold-700);
  font-weight: 600;
  font-size: 0.72rem;
}

.sold-progress-track {
  width: 100%;
  height: 5px;
  background: var(--border-light);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.sold-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--emerald-600), var(--emerald-400), var(--gold-500));
  border-radius: var(--radius-full);
  transition: width 0.6s ease;
}

.product-card-price-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px dashed var(--border-light);
  margin-bottom: 16px;
}

.price-box {
  display: flex;
  flex-direction: column;
}

.price-currency {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-light);
  text-transform: uppercase;
}

.price-amount {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--emerald-900);
  line-height: 1.1;
}

.stock-status {
  font-size: 0.76rem;
  color: var(--emerald-700);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 5px;
}

.stock-dot {
  width: 7px;
  height: 7px;
  border-radius: var(--radius-full);
  background: var(--emerald-500);
}

/* Add To Cart Button — Gentle Pulsing CSS Animation */
.add-to-cart-btn {
  width: 100%;
  height: 46px;
  background: var(--emerald-800);
  color: var(--bg-white);
  border-radius: var(--radius-md);
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px solid rgba(212, 175, 55, 0.4);
  animation: gentlePulse 3s infinite;
  transition: all var(--transition-fast);
}

.add-to-cart-btn:hover {
  background: var(--emerald-700);
  border-color: var(--gold-500);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(6, 78, 59, 0.35);
  animation: none;
}

.add-to-cart-btn:active {
  transform: translateY(0);
}

/* --- Publication Standards / Heritage Section --- */
.standards-section {
  padding: 64px 0;
  background: var(--bg-white);
  border-top: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
}

.standards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .standards-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.standard-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 32px 24px;
  text-align: center;
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.standard-card:hover {
  transform: translateY(-4px);
  border-color: var(--emerald-300);
}

.standard-icon-circle {
  width: 58px;
  height: 58px;
  border-radius: var(--radius-full);
  background: var(--emerald-100);
  color: var(--emerald-800);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 18px;
  border: 1px solid rgba(212, 175, 55, 0.3);
}

.standard-title {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--emerald-950);
  margin-bottom: 10px;
}

.standard-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* --- Scholarly Reviews / Readers Section --- */
.reviews-section {
  padding: 64px 0;
  background: var(--bg-page);
}

.reviews-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .reviews-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.review-card {
  background: var(--bg-white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
}

.review-stars {
  color: var(--gold-500);
  display: flex;
  gap: 3px;
  margin-bottom: 14px;
}

.review-text {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.6;
  font-style: italic;
  margin-bottom: 18px;
  flex-grow: 1;
}

.reviewer-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  border-top: 1px solid var(--bg-surface);
  padding-top: 14px;
}

.reviewer-avatar {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--emerald-50);
  color: var(--emerald-800);
  font-weight: 700;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--emerald-200);
}

.reviewer-name {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--emerald-950);
}

.reviewer-role {
  font-size: 0.74rem;
  color: var(--text-light);
}

/* --- Contact Section (Working In-Page Form) --- */
.contact-section {
  padding: 64px 0;
  background: var(--bg-surface);
  border-top: 1px solid var(--border-light);
}

.contact-card-box {
  background: var(--bg-white);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-md);
  max-width: 820px;
  margin: 0 auto;
  padding: 36px 24px;
}

@media (min-width: 768px) {
  .contact-card-box {
    padding: 48px 42px;
  }
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

@media (min-width: 768px) {
  .form-grid.two-cols {
    grid-template-columns: 1fr 1fr;
  }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-label {
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--emerald-950);
}

.form-input, .form-textarea, .form-select {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-size: 0.92rem;
  transition: all var(--transition-fast);
}

.form-input:focus, .form-textarea:focus, .form-select:focus {
  background: var(--bg-white);
  border-color: var(--emerald-600);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15);
}

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

.contact-submit-btn {
  height: 50px;
  background: var(--emerald-800);
  color: var(--bg-white);
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  font-weight: 700;
  border: 1px solid rgba(212, 175, 55, 0.4);
  transition: all var(--transition-fast);
  margin-top: 8px;
}

.contact-submit-btn:hover {
  background: var(--emerald-700);
  border-color: var(--gold-500);
  box-shadow: var(--shadow-md);
}

/* Success notification message */
.form-success-banner {
  display: none;
  background: var(--emerald-50);
  border: 1px solid var(--emerald-300);
  color: var(--emerald-900);
  padding: 18px 20px;
  border-radius: var(--radius-md);
  margin-bottom: 24px;
  align-items: center;
  gap: 12px;
  animation: fadeIn 0.3s ease;
}

.form-success-banner.is-active {
  display: flex;
}

/* --- FOOTER (STRICT RULES) --- */
/* Strictly: Email ONLY in Footer: ilmibooks.store77@gmail.com */
/* Strictly NO phone, NO map, NO address, NO whatsapp, NO fluff */
.site-footer {
  background: var(--emerald-950);
  color: var(--emerald-100);
  border-top: 1px solid rgba(212, 175, 55, 0.25);
  padding: 56px 0 28px;
  margin-top: auto;
}

.footer-top-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 36px;
  margin-bottom: 48px;
}

@media (min-width: 768px) {
  .footer-top-grid {
    grid-template-columns: 2fr 1fr 1.5fr;
    gap: 40px;
  }
}

.footer-brand-col {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.footer-logo-title {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: 2px;
  color: var(--bg-white);
}

.footer-logo-title span {
  color: var(--gold-400);
}

.footer-about-text {
  font-size: 0.88rem;
  color: var(--emerald-200);
  line-height: 1.65;
  max-width: 380px;
}

.footer-col-title {
  font-family: var(--font-serif);
  font-size: 0.96rem;
  letter-spacing: 1.5px;
  color: var(--gold-400);
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 16px;
  position: relative;
  display: inline-block;
}

.footer-col-title::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 24px;
  height: 2px;
  background: var(--gold-500);
}

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

.footer-link-item a {
  font-size: 0.88rem;
  color: var(--emerald-200);
  transition: color var(--transition-fast);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.footer-link-item a:hover {
  color: var(--bg-white);
  transform: translateX(3px);
}

/* Verified Business Channel (Strict Email Only) */
.footer-contact-channel {
  background: rgba(2, 44, 34, 0.6);
  border: 1px solid rgba(212, 175, 55, 0.25);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.verified-channel-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--gold-400);
}

.footer-email-link {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--bg-white);
  word-break: break-all;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all var(--transition-fast);
}

.footer-email-link:hover {
  background: rgba(212, 175, 55, 0.15);
  border-color: var(--gold-500);
  color: var(--gold-300);
}

.footer-email-note {
  font-size: 0.78rem;
  color: var(--emerald-200);
  line-height: 1.4;
}

/* Footer Bottom Bar */
.footer-bottom-bar {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: center;
  text-align: center;
  font-size: 0.82rem;
  color: var(--emerald-200);
}

@media (min-width: 768px) {
  .footer-bottom-bar {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }
}

.footer-copyright span {
  color: var(--gold-400);
}

/* --- Slide-Over Cart Drawer --- */
.cart-drawer-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(1, 29, 22, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 50;
  overflow: hidden;
}

.cart-drawer-overlay.is-active {
  display: flex;
}

.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  max-width: 440px;
  background: var(--bg-white);
  box-shadow: -10px 0 35px rgba(0,0,0,0.25);
  z-index: 51;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform var(--transition-smooth);
}

@media (max-width: 480px) {
  .cart-drawer {
    max-width: 100vw;
  }
}

.cart-drawer-overlay.is-active .cart-drawer {
  transform: translateX(0);
}

.cart-header {
  padding: 20px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-light);
  background: var(--bg-surface);
}

.cart-header-title {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--emerald-950);
}

.cart-close-btn {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: all var(--transition-fast);
}

.cart-close-btn:hover {
  background: var(--emerald-100);
  color: var(--emerald-900);
}

.cart-items-body {
  flex-grow: 1;
  overflow-y: auto;
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Empty cart state */
.cart-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  height: 100%;
  padding: 32px 16px;
}

.cart-empty-icon {
  width: 64px;
  height: 64px;
  color: var(--emerald-300);
  margin-bottom: 16px;
}

.cart-empty-text {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  color: var(--emerald-900);
  font-weight: 700;
  margin-bottom: 8px;
}

.cart-empty-desc {
  font-size: 0.88rem;
  color: var(--text-light);
  margin-bottom: 20px;
}

/* Cart Item Row */
.cart-item-row {
  display: flex;
  gap: 14px;
  padding: 14px;
  border-radius: var(--radius-md);
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
}

.cart-item-thumb {
  width: 65px;
  height: 85px;
  border-radius: var(--radius-sm);
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
  border: 1px solid var(--border-light);
}

.cart-item-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.cart-item-details {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.cart-item-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--emerald-950);
  line-height: 1.25;
}

.cart-item-price {
  font-family: var(--font-serif);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--emerald-800);
  margin-top: 4px;
}

.cart-item-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 8px;
}

.qty-counter {
  display: flex;
  align-items: center;
  background: var(--bg-white);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  height: 28px;
}

.qty-btn {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--emerald-900);
  font-weight: 700;
  font-size: 0.9rem;
}

.qty-val {
  min-width: 22px;
  text-align: center;
  font-size: 0.84rem;
  font-weight: 700;
}

.cart-item-remove-btn {
  font-size: 0.74rem;
  color: #ef4444;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 3px;
}

.cart-item-remove-btn:hover {
  text-decoration: underline;
}

/* Cart Footer */
.cart-footer {
  padding: 20px 24px;
  background: var(--bg-surface);
  border-top: 1px solid var(--border-light);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.cart-summary-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.cart-summary-line.total {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--emerald-950);
  border-top: 1px dashed var(--border-subtle);
  padding-top: 10px;
}

.checkout-trigger-btn {
  height: 48px;
  background: var(--emerald-800);
  color: var(--bg-white);
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  font-weight: 700;
  border: 1px solid rgba(212, 175, 55, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all var(--transition-fast);
}

.checkout-trigger-btn:hover {
  background: var(--emerald-700);
  border-color: var(--gold-500);
  box-shadow: 0 4px 16px rgba(6, 78, 59, 0.3);
}

/* --- Checkout Modal & Order Confirmation --- */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(1, 29, 22, 0.7);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  z-index: 60;
  align-items: center;
  justify-content: center;
  padding: 16px;
  overflow: hidden;
}

.modal-overlay.is-active {
  display: flex;
}

.modal-content-card {
  background: var(--bg-white);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 620px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-xl);
  position: relative;
  animation: modalScaleIn 0.3s var(--transition-smooth);
}

.modal-header-bar {
  padding: 20px 28px;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-title {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--emerald-950);
}

.modal-body {
  padding: 28px;
}

/* Payment Selector Cards */
.payment-methods-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-top: 10px;
}

@media (min-width: 576px) {
  .payment-methods-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.payment-method-card {
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 14px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  background: var(--bg-surface);
  transition: all var(--transition-fast);
}

.payment-method-card:hover,
.payment-method-card.is-selected {
  border-color: var(--emerald-600);
  background: var(--emerald-50);
}

.payment-method-card input[type="radio"] {
  accent-color: var(--emerald-700);
  margin-top: 3px;
}

.payment-name {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--emerald-950);
}

.payment-sub {
  font-size: 0.74rem;
  color: var(--text-light);
  margin-top: 2px;
}

/* Order Success Screen */
.order-success-screen {
  text-align: center;
  padding: 36px 20px;
}

.success-badge-circle {
  width: 72px;
  height: 72px;
  border-radius: var(--radius-full);
  background: var(--emerald-100);
  color: var(--emerald-700);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  border: 2px solid var(--emerald-300);
}

.order-ref-badge {
  display: inline-block;
  background: var(--bg-surface);
  border: 1px dashed var(--emerald-600);
  color: var(--emerald-900);
  font-family: monospace;
  font-size: 1.15rem;
  font-weight: 700;
  padding: 6px 18px;
  border-radius: var(--radius-sm);
  margin: 12px 0 20px;
}

.order-receipt-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 20px;
  text-align: left;
  margin: 20px 0;
  font-size: 0.88rem;
}

/* --- Quick View Modal --- */
.quick-view-dialog {
  max-width: 820px;
}

.quick-view-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .quick-view-grid {
    grid-template-columns: 1fr 1.2fr;
    gap: 32px;
  }
}

.quick-view-media-box {
  background: radial-gradient(circle at 50% 40%, #ffffff 0%, #f4f8f5 80%);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.quick-view-media-box img {
  max-width: 100%;
  max-height: 380px;
  object-fit: contain;
  filter: drop-shadow(0 12px 24px rgba(2, 44, 34, 0.2));
}

.spec-table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  font-size: 0.84rem;
}

.spec-table tr {
  border-bottom: 1px solid var(--border-light);
}

.spec-table td {
  padding: 8px 6px;
}

.spec-table td:first-child {
  font-weight: 600;
  color: var(--text-muted);
  width: 38%;
}

.spec-table td:last-child {
  color: var(--emerald-950);
  font-weight: 500;
}

/* --- Toast Notification --- */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast-message {
  pointer-events: auto;
  background: var(--emerald-950);
  color: var(--bg-white);
  border: 1px solid rgba(212, 175, 55, 0.4);
  padding: 14px 20px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.9rem;
  font-weight: 600;
  animation: toastSlideIn 0.3s var(--transition-smooth);
}

.toast-message.success svg {
  color: var(--emerald-400);
}
