/*
 * LuminaBook - Ultra-Modern Bookstore & Digital Publishing Studio
 * Sleek Obsidian, Electric Cyan & Regal Gold Aesthetic
 * Fully Responsive for Web, Mobile & Android
 */

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

:root {
  --bg-primary: #08090e;
  --bg-secondary: #0f121d;
  --bg-card: rgba(18, 22, 34, 0.85);
  --bg-card-hover: rgba(26, 32, 50, 0.95);
  --glass-border: rgba(255, 255, 255, 0.08);
  --glass-border-focus: rgba(56, 189, 248, 0.5);
  --accent-cyan: #38bdf8;
  --accent-cyan-glow: rgba(56, 189, 248, 0.35);
  --accent-gold: #fbbf24;
  --accent-purple: #a855f7;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  --radius-xl: 20px;
  --radius-lg: 14px;
  --radius-md: 10px;
  --shadow-card: 0 16px 36px -10px rgba(0, 0, 0, 0.6), 0 0 0 1px var(--glass-border);
  --shadow-glow: 0 0 30px -5px var(--accent-cyan-glow);
  --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-serif: 'Playfair Display', Georgia, serif;
}

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

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

/* Wallpaper Hero Background */
.hero-wallpaper-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 640px;
  background-image: url('../covers/hero_wallpaper.svg');
  background-size: cover;
  background-position: center top;
  opacity: 0.85;
  z-index: 0;
  pointer-events: none;
}

.hero-wallpaper-backdrop::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(8, 9, 14, 0.2) 0%, rgba(8, 9, 14, 0.8) 70%, var(--bg-primary) 100%);
}

/* Glassmorphism Header */
.lumina-nav {
  position: sticky;
  top: 16px;
  z-index: 1000;
  margin: 0 auto;
  max-width: 1320px;
  padding: 12px 24px;
  background: rgba(15, 18, 29, 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  transition: all 0.3s ease;
}

.brand-title {
  font-family: var(--font-serif);
  font-weight: 800;
  font-size: 1.6rem;
  background: linear-gradient(135deg, #ffffff 40%, var(--accent-cyan) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.nav-link-custom {
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.95rem;
  padding: 8px 14px;
  border-radius: var(--radius-md);
  text-decoration: none;
  transition: all 0.2s;
}

.nav-link-custom:hover, .nav-link-custom.active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.06);
}

.currency-select {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--glass-border);
  color: #ffffff;
  padding: 6px 12px;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  outline: none;
}

.btn-cyan {
  background: linear-gradient(135deg, var(--accent-cyan), #0284c7);
  color: #030712;
  font-weight: 700;
  border: none;
  border-radius: var(--radius-md);
  padding: 10px 20px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.25s ease;
  box-shadow: 0 4px 18px var(--accent-cyan-glow);
  text-decoration: none;
  cursor: pointer;
}

.btn-cyan:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(56, 189, 248, 0.5);
  color: #000000;
}

.btn-glass {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--glass-border);
  color: #ffffff;
  border-radius: var(--radius-md);
  padding: 10px 18px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  transition: all 0.2s;
  cursor: pointer;
}

.btn-glass:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.2);
}

/* Hero Section */
.hero-content {
  position: relative;
  z-index: 10;
  padding: 80px 0 60px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: 30px;
  color: var(--accent-cyan);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 20px;
}

.hero-heading {
  font-family: var(--font-serif);
  font-size: 3.6rem;
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.5px;
  margin-bottom: 24px;
}

.hero-heading span.gradient-text {
  background: linear-gradient(135deg, var(--accent-cyan) 20%, #e0e7ff 60%, var(--accent-gold) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtext {
  color: var(--text-muted);
  font-size: 1.15rem;
  max-width: 580px;
  margin-bottom: 34px;
}

/* Search Bar */
.lumina-search-box {
  background: rgba(15, 18, 29, 0.9);
  border: 1px solid var(--glass-border);
  border-radius: 50px;
  padding: 8px 12px 8px 24px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 560px;
  transition: all 0.25s ease;
}

.lumina-search-box:focus-within {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 25px var(--accent-cyan-glow);
}

.lumina-search-box input {
  background: transparent;
  border: none;
  color: #ffffff;
  outline: none;
  font-size: 1rem;
  width: 100%;
}

.lumina-search-box input::placeholder {
  color: var(--text-dim);
}

/* Category Filter Pills */
.genre-pills {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 20px 0;
  scrollbar-width: none;
}

.genre-pills::-webkit-scrollbar {
  display: none;
}

.pill-item {
  white-space: nowrap;
  padding: 10px 20px;
  border-radius: 40px;
  background: var(--bg-card);
  border: 1px solid var(--glass-border);
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 8px;
}

.pill-item:hover, .pill-item.active {
  background: rgba(56, 189, 248, 0.15);
  border-color: var(--accent-cyan);
  color: #ffffff;
  transform: translateY(-2px);
}

/* Book Card & 3D Cover */
.book-card {
  background: var(--bg-card);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
  padding: 20px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  height: 100%;
}

.book-card:hover {
  background: var(--bg-card-hover);
  border-color: rgba(56, 189, 248, 0.3);
  transform: translateY(-8px);
  box-shadow: 0 24px 48px -12px rgba(0, 0, 0, 0.7), var(--shadow-glow);
}

.book-cover-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 2 / 3;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: #020617;
  margin-bottom: 16px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.8);
}

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

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

.badge-overlay {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent-gold);
  display: flex;
  align-items: center;
  gap: 5px;
}

.badge-discount {
  position: absolute;
  top: 12px;
  right: 12px;
  background: linear-gradient(135deg, #ef4444, #b91c1c);
  color: #ffffff;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 800;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}

.book-meta-author {
  font-size: 0.85rem;
  color: var(--accent-cyan);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}

.book-title {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.3;
  color: #ffffff;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.book-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 16px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex-grow: 1;
}

.book-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--glass-border);
  padding-top: 14px;
  margin-top: auto;
}

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

.price-current {
  font-size: 1.25rem;
  font-weight: 800;
  color: #ffffff;
}

.price-old {
  font-size: 0.85rem;
  color: var(--text-dim);
  text-decoration: line-through;
}

.btn-card-action {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--glass-border);
  color: #ffffff;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
}

.btn-card-action:hover {
  background: var(--accent-cyan);
  color: #000000;
  border-color: var(--accent-cyan);
  box-shadow: 0 0 16px var(--accent-cyan-glow);
}

/* Spotlight Section */
.spotlight-card {
  background: linear-gradient(135deg, rgba(30, 27, 75, 0.7), rgba(15, 23, 42, 0.9));
  border: 1px solid rgba(168, 85, 247, 0.3);
  border-radius: var(--radius-xl);
  padding: 40px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
  position: relative;
  overflow: hidden;
}

.spotlight-card::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(168, 85, 247, 0.2), transparent 70%);
  pointer-events: none;
}

/* Interactive Reader Modal */
.reader-modal-dialog {
  max-width: 800px;
}

.reader-sheet {
  background: #fbfbf9;
  color: #1a1a1a;
  border-radius: var(--radius-lg);
  padding: 40px 50px;
  font-family: Georgia, serif;
  font-size: 1.15rem;
  line-height: 1.8;
  max-height: 70vh;
  overflow-y: auto;
  box-shadow: inset 0 0 20px rgba(0,0,0,0.05);
}

.reader-theme-dark {
  background: #12131a;
  color: #e2e8f0;
}

.reader-theme-sepia {
  background: #f4ecd8;
  color: #433422;
}

/* Cart Badge */
.cart-badge {
  background: var(--accent-cyan);
  color: #000000;
  font-size: 0.75rem;
  font-weight: 800;
  border-radius: 50%;
  padding: 2px 7px;
  position: relative;
  top: -8px;
  left: -4px;
}

/* Admin Styling */
.admin-sidebar {
  background: rgba(15, 18, 29, 0.95);
  border-right: 1px solid var(--glass-border);
  min-height: 100vh;
  padding: 24px;
}

.admin-card {
  background: var(--bg-card);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-card);
}

.kpi-stat {
  font-size: 2.2rem;
  font-weight: 800;
  color: #ffffff;
  margin: 8px 0;
}

.table-glass {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  color: var(--text-main);
}

.table-glass th {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-muted);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--glass-border);
}

.table-glass td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--glass-border);
  vertical-align: middle;
}

.table-glass tr:hover td {
  background: rgba(255, 255, 255, 0.03);
}

/* Mobile Bottom Navigation */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: rgba(15, 18, 29, 0.95);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--glass-border);
  padding: 10px 0;
  z-index: 1050;
  justify-content: space-around;
  align-items: center;
}

.mobile-nav-item {
  color: var(--text-muted);
  text-decoration: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size: 0.75rem;
  gap: 3px;
}

.mobile-nav-item.active, .mobile-nav-item:hover {
  color: var(--accent-cyan);
}

@media (max-width: 991px) {
  .hero-heading {
    font-size: 2.6rem;
  }
  .spotlight-card {
    padding: 24px;
  }
}

@media (max-width: 768px) {
  .lumina-nav {
    top: 0;
    border-radius: 0;
    margin: 0;
    border-left: none;
    border-right: none;
  }
  .mobile-bottom-nav {
    display: flex;
  }
  body {
    padding-bottom: 70px;
  }
  .reader-sheet {
    padding: 20px 24px;
  }
}
