/* ==========================================================================
   BOOKORA - ELEGANT WARM EDITORIAL DESIGN SYSTEM & STYLING ARCHITECTURE
   Color Palette: Warm White/Cream (#faf8f5), Dark Charcoal (#111827), Deep Purple Accent (#5b21b6)
   ========================================================================== */

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

:root {
  --font-display: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  /* Warm Cream & Charcoal Neutral Palette */
  --bg-body: #faf8f5;
  --bg-body-alt: #f3f0ea;
  --bg-card: #ffffff;
  --bg-card-hover: #fcfbfa;
  --bg-dark-hero: #0f172a;
  --bg-purple-hero: #18092b;

  --text-primary: #111827;
  --text-secondary: #374151;
  --text-muted: #6b7280;
  --text-light-muted: #9ca3af;
  --text-white: #ffffff;

  --border-light: #e6e1d7;
  --border-subtle: #f0ebe1;
  --border-focus: #5b21b6;

  /* Accent Colors */
  --purple-primary: #5b21b6;
  --purple-hover: #6d28d9;
  --purple-light: #f3e8ff;
  --purple-border: #ddd6fe;

  --amber-star: #f59e0b;
  --green-success: #16a34a;
  --red-danger: #dc2626;

  /* Shadows */
  --shadow-sm: 0 1px 3px 0 rgba(15, 23, 42, 0.06);
  --shadow-md: 0 4px 12px -2px rgba(15, 23, 42, 0.08), 0 2px 6px -2px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 12px 24px -4px rgba(15, 23, 42, 0.12), 0 4px 10px -2px rgba(15, 23, 42, 0.06);
  --shadow-cover: 0 16px 32px -8px rgba(15, 23, 42, 0.28), 0 8px 16px -6px rgba(0, 0, 0, 0.12);

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

  --transition-normal: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

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

ul, ol, li {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 !important;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-body);
  color: var(--text-primary);
  line-height: 1.6;
  font-size: 15px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  color: var(--text-primary);
  font-weight: 700;
  line-height: 1.25;
}

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

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

.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

.container-sm {
  max-width: 900px;
}

.site-content {
  flex: 1;
}

.section {
  padding: 64px 0;
}

.section-bg-alt {
  background-color: var(--bg-body-alt);
}

.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 16px; }
.mt-4 { margin-top: 24px; }
.mt-5 { margin-top: 40px; }

/* ==========================================================================
   HEADER NAVIGATION BAR
   ========================================================================== */
.bookora-header {
  background-color: #ffffff;
  border-bottom: 1px solid var(--border-light);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow-sm);
}

.bookora-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: 24px;
}

.bookora-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.5rem;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.bookora-brand-icon {
  width: 32px;
  height: 32px;
  background: var(--purple-primary);
  color: #ffffff;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.bookora-nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  font-weight: 500;
  font-size: 0.95rem;
}

.bookora-nav-links a {
  color: var(--text-secondary);
  padding: 6px 0;
  position: relative;
}

.bookora-nav-links a:hover,
.bookora-nav-links a.active {
  color: var(--purple-primary);
  font-weight: 600;
}

.bookora-nav-links a.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--purple-primary);
  border-radius: 2px;
}

/* Header Search Input */
.header-search-wrap {
  position: relative;
  flex: 1;
  max-width: 380px;
}

.header-search-input {
  width: 100%;
  padding: 10px 16px 10px 42px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-light);
  background-color: var(--bg-body);
  font-family: var(--font-sans);
  font-size: 0.9rem;
  color: var(--text-primary);
  outline: none;
  transition: all var(--transition-normal);
}

.header-search-input:focus {
  border-color: var(--purple-primary);
  background-color: #ffffff;
  box-shadow: 0 0 0 3px rgba(91, 33, 182, 0.12);
}

.header-search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
  font-size: 0.9rem;
}

/* Search Autocomplete Modal Dropdown */
.autocomplete-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: #ffffff;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-lg);
  z-index: 1050;
  display: none;
  overflow: hidden;
}

.autocomplete-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border-subtle);
  transition: background var(--transition-normal);
}

.autocomplete-item:hover {
  background-color: var(--bg-body);
}

.autocomplete-item img {
  width: 36px;
  height: 50px;
  object-fit: cover;
  border-radius: 4px;
  box-shadow: var(--shadow-sm);
}

.autocomplete-title {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-primary);
}

.autocomplete-author {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Right User Actions */
.bookora-header-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.cart-icon-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: var(--purple-light);
  color: var(--purple-primary);
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 0.9rem;
  transition: background var(--transition-normal);
}

.cart-icon-btn:hover {
  background: #e9d5ff;
}

.cart-badge {
  background: var(--purple-primary);
  color: #ffffff;
  font-size: 0.75rem;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ==========================================================================
   BUTTON SYSTEM
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.9rem;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--transition-normal);
  text-align: center;
}

.btn-purple {
  background-color: var(--purple-primary);
  color: #ffffff;
}

.btn-purple:hover {
  background-color: var(--purple-hover);
  box-shadow: 0 4px 12px rgba(91, 33, 182, 0.25);
}

.btn-outline-purple {
  background-color: transparent;
  border-color: var(--purple-primary);
  color: var(--purple-primary);
}

.btn-outline-purple:hover {
  background-color: var(--purple-light);
}

.btn-dark {
  background-color: var(--text-primary);
  color: #ffffff;
}

.btn-dark:hover {
  background-color: #000000;
}

.btn-outline-dark {
  background-color: transparent;
  border-color: var(--text-primary);
  color: var(--text-primary);
}

.btn-outline-dark:hover {
  background-color: var(--text-primary);
  color: #ffffff;
}

.btn-sm {
  padding: 6px 14px;
  font-size: 0.825rem;
}

.btn-lg {
  padding: 14px 28px;
  font-size: 1.05rem;
  border-radius: var(--radius-lg);
}

.btn-block {
  width: 100%;
}

/* ==========================================================================
   HOMEPAGE HERO BANNER (DRAMATIC CHARCOAL / DEEP PURPLE ACCENT)
   ========================================================================== */
.hero-bookora {
  background: linear-gradient(135deg, var(--bg-purple-hero) 0%, #1e0a38 50%, var(--bg-dark-hero) 100%);
  color: #ffffff;
  padding: 72px 0;
  position: relative;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 48px;
  align-items: center;
}

.hero-content h1 {
  color: #ffffff;
  font-size: 3rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-bottom: 18px;
}

.hero-content h1 span {
  color: #c084fc;
}

.hero-subtext {
  font-size: 1.1rem;
  color: #d1d5db;
  margin-bottom: 32px;
  max-width: 520px;
}

.hero-search-box {
  display: flex;
  background: #ffffff;
  padding: 6px;
  border-radius: var(--radius-full);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
  max-width: 480px;
  margin-bottom: 24px;
}

.hero-search-box input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 12px 20px;
  font-size: 0.95rem;
  color: var(--text-primary);
  outline: none;
}

.hero-search-box button {
  background: var(--purple-primary);
  color: #ffffff;
  border: none;
  padding: 12px 28px;
  border-radius: var(--radius-full);
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition-normal);
}

.hero-search-box button:hover {
  background: var(--purple-hover);
}

.hero-trending-showcase {
  display: flex;
  gap: 20px;
  justify-content: center;
  align-items: center;
  perspective: 1000px;
}

.hero-cover-card {
  width: 160px;
  height: 230px;
  border-radius: var(--radius-md);
  object-fit: cover;
  box-shadow: var(--shadow-cover);
  transition: transform 0.3s ease;
}

.hero-cover-card:hover {
  transform: translateY(-10px) scale(1.05);
}

.hero-cover-featured {
  width: 190px;
  height: 270px;
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

/* ==========================================================================
   PROMOTIONAL DEAL CARDS (FLASH SALE / DEAL OF THE DAY / LATEST ARRIVAL)
   ========================================================================== */
.promo-banners-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: -36px;
  position: relative;
  z-index: 10;
}

.promo-card {
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  gap: 20px;
  transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

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

.promo-card-content {
  flex: 1;
}

.promo-badge {
  display: inline-block;
  background: var(--purple-light);
  color: var(--purple-primary);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  margin-bottom: 8px;
  text-transform: uppercase;
}

.promo-card h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.promo-card p {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.promo-card img {
  width: 80px;
  height: 115px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
}

/* ==========================================================================
   SECTION HEADINGS & CATEGORY TABS
   ========================================================================== */
.section-header-flex {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
  flex-wrap: wrap;
  gap: 16px;
}

.section-title {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text-primary);
}

.category-tabs-row {
  display: flex;
  align-items: center;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.category-tab {
  padding: 8px 18px;
  border-radius: var(--radius-full);
  background: transparent;
  border: 1px solid var(--border-light);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.875rem;
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--transition-normal);
}

.category-tab:hover,
.category-tab.active {
  background: var(--purple-primary);
  color: #ffffff;
  border-color: var(--purple-primary);
}

/* ==========================================================================
   EBOOK CARDS GRID (HIGH-QUALITY COVER DESIGN)
   ========================================================================== */
.books-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 28px;
}

.book-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: var(--radius-lg);
  padding: 16px;
  display: flex;
  flex-direction: column;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  position: relative;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.04);
}

.book-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 32px rgba(15, 23, 42, 0.08);
  border-color: #cbd5e1;
}

.book-card-cover-wrap {
  width: 100%;
  aspect-ratio: 2 / 3;
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 14px;
  background: #f1f5f9;
  position: relative;
}

.book-card-cover-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.book-card:hover .book-card-cover-wrap img {
  transform: scale(1.04);
}

.book-card-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: #7c3aed;
  color: #ffffff;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 8px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.book-card-rating {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  color: #d97706;
  margin-bottom: 6px;
  font-weight: 700;
}

.book-card-title {
  font-size: 1.05rem;
  font-weight: 800;
  margin-bottom: 4px;
  line-height: 1.3;
  color: #0f172a;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.book-card-title a {
  color: #0f172a;
  text-decoration: none;
}

.book-card-title a:hover {
  color: #7c3aed;
}

.book-card-author {
  font-size: 0.85rem;
  color: #64748b;
  margin-bottom: 14px;
  font-weight: 600;
}

.book-card-author a {
  color: #64748b;
  text-decoration: none;
}

.book-card-author a:hover {
  color: #7c3aed;
}

.book-card-bottom {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 12px;
  border-top: 1px solid #f1f5f9;
}

.price-box {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.price-current {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.15rem;
  color: #0f172a;
}

.price-original {
  font-size: 0.85rem;
  color: #94a3b8;
  text-decoration: line-through;
}

.add-basket-btn {
  background: #7c3aed !important;
  color: #ffffff !important;
  border: none !important;
  padding: 8px 16px !important;
  border-radius: var(--radius-full) !important;
  font-size: 0.85rem !important;
  font-weight: 700 !important;
  cursor: pointer;
  transition: all 0.2s ease !important;
  box-shadow: 0 4px 12px rgba(124, 58, 237, 0.3) !important;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.add-basket-btn:hover {
  background: #6d28d9 !important;
  color: #ffffff !important;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(124, 58, 237, 0.4) !important;
}
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all var(--transition-normal);
}

.add-basket-btn:hover {
  background: var(--purple-primary);
  color: #ffffff;
}

/* ==========================================================================
   FEATURED AUTHOR & PUBLISHER SHOWCASE
   ========================================================================== */
.authors-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 24px;
}

.author-card {
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-align: center;
  transition: transform var(--transition-normal);
}

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

.author-avatar-img {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 14px;
  border: 3px solid var(--purple-light);
}

.publisher-bar {
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 32px 0;
  border-top: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
  margin: 48px 0;
  opacity: 0.7;
}

/* ==========================================================================
   NEWSLETTER SUBSCRIPTION BANNER
   ========================================================================== */
.newsletter-banner {
  background: linear-gradient(135deg, var(--purple-primary) 0%, #3b0764 100%);
  color: #ffffff;
  border-radius: var(--radius-xl);
  padding: 56px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  box-shadow: var(--shadow-lg);
}

.newsletter-content h2 {
  color: #ffffff;
  font-size: 2.2rem;
  font-weight: 800;
  margin-bottom: 8px;
}

.newsletter-content p {
  color: #e9d5ff;
  font-size: 1rem;
}

.newsletter-form {
  display: flex;
  gap: 12px;
  width: 100%;
  max-width: 440px;
}

.newsletter-form input {
  flex: 1;
  padding: 14px 20px;
  border-radius: var(--radius-md);
  border: none;
  font-size: 0.95rem;
  outline: none;
}

.newsletter-form button {
  background: #ffffff;
  color: var(--purple-primary);
  border: none;
  padding: 14px 24px;
  border-radius: var(--radius-md);
  font-weight: 700;
  cursor: pointer;
  transition: background var(--transition-normal);
}

.newsletter-form button:hover {
  background: var(--purple-light);
}

/* ==========================================================================
   HEADER & FOOTER RESPONSIVE ARCHITECTURE
   ========================================================================== */
.flash-sale-top-banner {
  background: linear-gradient(90deg, #e11d48 0%, #b91c1c 50%, #9f1239 100%);
  color: #ffffff;
  padding: 10px 16px;
  font-size: 0.9rem;
  font-weight: 700;
  text-align: center;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  box-shadow: 0 4px 12px rgba(225, 29, 72, 0.25);
  z-index: 1000;
  position: relative;
}

.bookora-header {
  background: #ffffff;
  border-bottom: 1px solid var(--border-light);
  position: sticky;
  top: 0;
  z-index: 900;
  box-shadow: var(--shadow-sm);
}

.bookora-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 16px;
}

.bookora-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.4rem;
  color: var(--text-primary);
}

.bookora-brand-icon {
  width: 38px;
  height: 38px;
  background: linear-gradient(135deg, #7c3aed 0%, #4c1d95 100%);
  color: #ffffff;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  box-shadow: 0 4px 12px rgba(124, 58, 237, 0.3);
  flex-shrink: 0;
}

.bookora-brand-title {
  background: linear-gradient(135deg, #0f172a 0%, #475569 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.bookora-header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.action-circle-btn {
  color: var(--text-secondary);
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #f8fafc;
  border: 1px solid var(--border-light);
  text-decoration: none;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.cart-icon-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #f8fafc;
  border: 1px solid var(--border-light);
  padding: 6px 14px;
  border-radius: 20px;
  text-decoration: none;
  color: var(--text-primary);
  font-weight: 700;
  font-size: 0.9rem;
  flex-shrink: 0;
}

.cart-badge {
  background: var(--purple-primary);
  color: #ffffff;
  font-size: 0.75rem;
  font-weight: 800;
  border-radius: 9999px;
  padding: 2px 7px;
}

.nav-signin-btn {
  font-weight: 700;
  padding: 8px 18px;
  border-radius: 20px;
}

.mobile-only-btn {
  display: none;
  background: none;
  border: none;
  font-size: 1.6rem;
  cursor: pointer;
  color: var(--text-primary);
  padding: 4px;
  flex-shrink: 0;
}

/* FOOTER ARCHITECTURE */
.bookora-footer {
  background: #0f172a;
  color: #94a3b8;
  padding: 60px 0 30px;
  border-top: 1px solid #1e293b;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr repeat(4, 1fr);
  gap: 40px;
  margin-bottom: 40px;
}

.footer-col h4 {
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 18px;
  letter-spacing: 0.04em;
}

.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 0.9rem;
}

.footer-col ul li a {
  color: #94a3b8;
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-col ul li a:hover {
  color: #ffffff;
}

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid #1e293b;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.85rem;
  color: #64748b;
}

.footer-badges {
  display: flex;
  gap: 16px;
  color: #94a3b8;
  flex-wrap: wrap;
}

/* ==========================================================================
   MOBILE & TABLET RESPONSIVE OVERRIDES (< 992px & < 768px & < 576px)
   ========================================================================== */
html, body {
  overflow-x: hidden !important;
  width: 100% !important;
}

@media (max-width: 992px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
  .footer-brand-col {
    grid-column: 1 / -1;
  }

  /* Universal Inline Grid Overrides for Mobile (Catalog, Book Detail, Cart, Checkout, Account, Admin, Legal) */
  div[style*="grid-template-columns: 260px 1fr"],
  div[style*="grid-template-columns: 340px 1fr"],
  div[style*="grid-template-columns: 1fr 340px"],
  div[style*="grid-template-columns: 1fr 360px"],
  div[style*="grid-template-columns: 270px 1fr"],
  div[style*="grid-template-columns: 280px 1fr"],
  div[style*="grid-template-columns: 2fr 1fr"],
  div[style*="grid-template-columns: 1fr 1fr"],
  div[style*="grid-template-columns: 1fr 1.1fr"] {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
  }

  aside, .catalog-filters-sidebar {
    width: 100% !important;
    margin-bottom: 20px !important;
  }

  .table-wrapper, table {
    display: block;
    width: 100% !important;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}

@media (max-width: 768px) {
  .desktop-only {
    display: none !important;
  }
  .mobile-only-btn {
    display: flex !important;
    align-items: center;
    justify-content: center;
  }
  .bookora-header-inner {
    padding: 10px 14px;
  }
  .bookora-brand-title {
    font-size: 1.25rem;
  }
  .bookora-brand-icon {
    width: 32px;
    height: 32px;
    font-size: 1rem;
  }
  .nav-signin-btn {
    padding: 6px 14px;
    font-size: 0.82rem;
  }
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
    text-align: center;
  }
  .footer-brand-col {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  .footer-brand-col p {
    margin-left: auto;
    margin-right: auto;
  }
  .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: 12px;
  }
  .footer-badges {
    justify-content: center;
  }
}

@media (max-width: 576px) {
  .container {
    padding-left: 12px !important;
    padding-right: 12px !important;
  }

  /* Product cover image fitting on phone */
  div[style*="grid-template-columns: 340px 1fr"] img {
    max-height: 360px;
    object-fit: contain;
  }

  /* Full width action buttons on phone */
  .buy-now-btn, .add-to-cart-btn {
    width: 100% !important;
    justify-content: center !important;
  }

  input[type="text"], input[type="email"], input[type="password"], select, textarea {
    font-size: 16px !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }
}

/* ==========================================================================
   EXECUTIVE PROFESSIONAL ADMIN DASHBOARD STYLING
   ========================================================================== */
.admin-body {
  background-color: #f1f5f9;
  color: #0f172a;
}

.admin-wrapper {
  display: flex;
  min-height: 100vh;
}

/* Admin Sidebar Navigation */
.admin-sidebar {
  width: 260px;
  background-color: #0f172a;
  color: #f8fafc;
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 100;
  border-right: 1px solid #1e293b;
}

.admin-brand {
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #1e293b;
}

.admin-brand .brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.25rem;
  color: #ffffff;
  letter-spacing: -0.02em;
}

.admin-badge {
  background: var(--purple-primary);
  color: #ffffff;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  letter-spacing: 0.05em;
}

.admin-nav {
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
  overflow-y: auto;
}

.admin-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  border-radius: var(--radius-md);
  color: #94a3b8;
  font-weight: 500;
  font-size: 0.9rem;
  transition: all var(--transition-normal);
}

.admin-nav-item:hover {
  color: #ffffff;
  background-color: #1e293b;
}

.admin-nav-item.active {
  color: #ffffff;
  background: linear-gradient(135deg, var(--purple-primary) 0%, #4c1d95 100%);
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(91, 33, 182, 0.3);
}

.admin-sidebar-footer {
  padding: 20px 16px;
  border-top: 1px solid #1e293b;
}

/* Admin Main Workspace */
.admin-main {
  flex: 1;
  margin-left: 260px;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.admin-topbar {
  height: 64px;
  background-color: #ffffff;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  position: sticky;
  top: 0;
  z-index: 90;
}

.admin-title h1 {
  font-size: 1.35rem;
  font-weight: 700;
  color: #0f172a;
}

.admin-user-info {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.875rem;
  color: #64748b;
}

.avatar-sm {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--purple-primary);
}

.admin-content-inner {
  padding: 32px;
  flex: 1;
}

/* Executive KPI Stat Cards */
.stats-overview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}

.stat-card-admin {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.stat-card-admin:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--purple-border);
}

.stat-icon {
  width: 48px;
  height: 48px;
  background: var(--purple-light);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
}

.stat-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.stat-value {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.2;
}

/* Executive Admin Cards & Tables */
.admin-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.admin-card-header {
  padding: 20px 24px;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.admin-card-header h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: #0f172a;
}

.admin-tables-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 24px;
}

.table-responsive {
  width: 100%;
  overflow-x: auto;
}

.table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}

.table th {
  background-color: #f8fafc;
  color: #64748b;
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 12px 24px;
  border-bottom: 1px solid #e2e8f0;
}

.table td {
  padding: 14px 24px;
  border-bottom: 1px solid #f1f5f9;
  color: #334155;
  vertical-align: middle;
}

.table tbody tr:hover {
  background-color: #f8fafc;
}

.badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: var(--radius-full);
}

.badge-success { background: #dcfce7; color: #15803d; }
.badge-primary { background: var(--purple-light); color: var(--purple-primary); }
.badge-bestseller { background: #fef3c7; color: #b45309; }

.mini-cover-xs {
  width: 32px;
  height: 48px;
  object-fit: cover;
  border-radius: 4px;
  box-shadow: var(--shadow-sm);
}

.admin-actions-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

/* Admin Modals */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal.active { display: flex; }

.modal-content {
  background: #ffffff;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-lg { max-width: 760px; }

.modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-header h3 {
  font-size: 1.2rem;
  font-weight: 700;
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.3rem;
  cursor: pointer;
  color: #64748b;
}

.modal-body {
  padding: 24px;
}

.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: #334155;
  margin-bottom: 6px;
}

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

.input {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid #cbd5e1;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  outline: none;
  font-family: var(--font-sans);
}

.input:focus {
  border-color: var(--purple-primary);
  box-shadow: 0 0 0 3px rgba(91, 33, 182, 0.1);
}

/* ==========================================================================
   EXECUTIVE ADMIN NAV & TAB SYSTEM ENHANCEMENTS
   ========================================================================== */
.admin-nav-group {
  margin-top: 18px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-nav-group-title {
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #94a3b8;
  padding: 0 16px 8px 16px;
  text-transform: uppercase;
}

.nav-badge-pill {
  margin-left: auto;
  background: #dc2626;
  color: #ffffff;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 999px;
}

.editor-tab-btn {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #475569;
  padding: 8px 16px;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.editor-tab-btn:hover {
  background: #e2e8f0;
  color: #0f172a;
}

.editor-tab-btn.active {
  background: var(--purple-primary);
  border-color: var(--purple-primary);
  color: #ffffff;
  font-weight: 700;
}

.chart-period-btn {
  background: transparent;
  border: none;
  font-size: 0.78rem;
  font-weight: 600;
  color: #64748b;
  padding: 4px 10px;
  border-radius: 4px;
  cursor: pointer;
}

.chart-period-btn.active {
  background: #ffffff;
  color: var(--purple-primary);
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  font-weight: 700;
}

.mobile-drawer-toggle {
  display: none;
  background: transparent;
  border: 1px solid #e2e8f0;
  font-size: 1.2rem;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  color: #0f172a;
}

.admin-sidebar-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
  z-index: 99;
}

@media (max-width: 992px) {
  .mobile-drawer-toggle {
    display: inline-block;
  }

  .admin-sidebar {
    position: fixed;
    left: -280px;
    top: 0;
    bottom: 0;
    z-index: 100;
    transition: left 0.3s ease;
  }

  .admin-sidebar.active {
    left: 0;
  }

  .admin-sidebar-backdrop.active {
    display: block;
  }

  .d-none-mobile {
    display: none !important;
  }
}

/* ==========================================================================
   EXECUTIVE ADMIN TOPBAR, SEARCH BAR & PROFILE ALIGNMENT
   ========================================================================== */
.admin-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  padding: 0 28px;
  background: #ffffff;
  border-bottom: 1px solid #e2e8f0;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03);
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: 1;
  max-width: 480px;
}

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

.admin-topbar-search .search-icon {
  position: absolute;
  left: 14px;
  font-size: 0.95rem;
  color: #94a3b8;
  pointer-events: none;
  z-index: 2;
}

.topbar-search-input {
  width: 100%;
  height: 42px;
  padding: 0 16px 0 42px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 9999px;
  font-size: 0.88rem;
  font-family: var(--font-sans);
  color: #0f172a;
  outline: none;
  transition: all 0.2s ease;
}

.topbar-search-input:focus {
  background: #ffffff;
  border-color: var(--purple-primary);
  box-shadow: 0 0 0 4px rgba(91, 33, 182, 0.12);
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 20px;
}

.topbar-icon-link {
  position: relative;
  font-size: 1.2rem;
  color: #64748b;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  transition: background 0.2s ease;
}

.topbar-icon-link:hover {
  background: #f1f5f9;
  color: #0f172a;
}

.notification-dot {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 8px;
  height: 8px;
  background: #dc2626;
  border-radius: 50%;
  border: 2px solid #ffffff;
}

.admin-user-profile {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 10px !important;
  padding: 4px 12px 4px 6px;
  border-radius: 9999px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

.admin-user-profile img.avatar-sm {
  width: 36px !important;
  height: 36px !important;
  border-radius: 50% !important;
  object-fit: cover !alignment;
  border: 2px solid var(--purple-primary);
  display: block;
}

.admin-user-details {
  display: flex !important;
  flex-direction: column !important;
  line-height: 1.25 !important;
  text-align: left;
}

.admin-user-name {
  font-size: 0.85rem;
  font-weight: 700;
  color: #0f172a;
  white-space: nowrap;
}

.admin-user-role {
  font-size: 0.72rem;
  font-weight: 800;
  color: var(--purple-primary);
  letter-spacing: 0.04em;
}

/* ==========================================================================
   ADMIN MODAL DIALOG POPUPS
   ========================================================================== */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(4px);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal.active,
.modal.show {
  display: flex !important;
}

.modal-content {
  background: #ffffff;
  border-radius: var(--radius-lg);
  max-width: 540px;
  width: 100%;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  overflow: hidden;
  animation: modalSlide 0.25s ease-out;
}

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

.modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #f8fafc;
}

.modal-header h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
}

.modal-close {
  background: transparent;
  border: none;
  font-size: 1.2rem;
  color: #64748b;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.modal-close:hover {
  background: #cbd5e1;
  color: #0f172a;
}

/* ==========================================================================
   INSTANT ADMIN SEARCH DROPDOWN MENU
   ========================================================================== */
.admin-search-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: var(--radius-lg);
  box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.15);
  max-height: 420px;
  overflow-y: auto;
  z-index: 1000;
  padding: 8px 0;
}

.search-section {
  padding: 6px 0;
  border-bottom: 1px solid #f1f5f9;
}

.search-section:last-child {
  border-bottom: none;
}

.search-section-title {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: var(--purple-primary);
  padding: 6px 16px;
  text-transform: uppercase;
  background: #f8fafc;
}

.search-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  text-decoration: none;
  color: #0f172a;
  transition: background 0.15s ease;
}

.search-item:hover {
  background: #f1f5f9;
}

.search-item-img {
  width: 32px;
  height: 46px;
  object-fit: cover;
  border-radius: 4px;
}

.search-item-avatar {
  width: 36px;
  height: 36px;
  object-fit: cover;
  border-radius: 50%;
}

.search-item-icon {
  width: 36px;
  height: 36px;
  background: var(--purple-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}

.search-item-info {
  display: flex;
  flex-direction: column;
}

.search-item-info strong {
  font-size: 0.88rem;
  font-weight: 600;
  color: #0f172a;
}

.search-item-info small {
  font-size: 0.76rem;
  color: #64748b;
}

.search-dropdown-empty {
  padding: 16px;
  text-align: center;
  font-size: 0.85rem;
  color: #64748b;
}





