/* ========================================
   ReaderVerse - Design System
   ======================================== */

/* ========================================
   CSS Custom Properties (Variables)
   ======================================== */
:root {
  /* Colors - Dark Theme */
  --bg-primary: #0a0a0a;
  --bg-secondary: #111111;
  --bg-tertiary: #1a1a1a;
  --bg-card: rgba(255, 255, 255, 0.02);
  --bg-card-hover: rgba(255, 255, 255, 0.05);
  
  /* Accent Colors */
  --accent: #6366f1;
  --accent-hover: #818cf8;
  --accent-light: rgba(99, 102, 241, 0.1);
  --accent-gradient: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #a855f7 100%);
  
  /* Text Colors */
  --text-primary: #fafafa;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;
  --text-accent: #6366f1;
  
  /* Border & Glass */
  --border: rgba(255, 255, 255, 0.08);
  --border-hover: rgba(255, 255, 255, 0.15);
  --glass: rgba(255, 255, 255, 0.03);
  --glass-blur: blur(20px);
  
  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.5);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 40px rgba(99, 102, 241, 0.15);
  
  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  
  /* Typography */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-display: 'Outfit', var(--font-sans);
  
  /* Font Sizes */
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.25rem;
  --text-2xl: 1.5rem;
  --text-3xl: 2rem;
  --text-4xl: 2.5rem;
  --text-5xl: 3.5rem;
  
  /* Border Radius */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-2xl: 1.5rem;
  --radius-full: 9999px;
  
  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
  --transition-slow: 400ms ease;
  
  /* Container */
  --container-max: 1200px;
  --container-padding: 1.5rem;
}

/* ========================================
   Reset & Base Styles
   ======================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--bg-primary);
  min-height: 100vh;
}

/* Links */
a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--accent);
}

/* Images */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Lists */
ul, ol {
  list-style: none;
}

/* Buttons */
button {
  font-family: inherit;
  font-size: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

/* ========================================
   Typography
   ======================================== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.2;
  color: var(--text-primary);
}

h1 { font-size: var(--text-5xl); }
h2 { font-size: var(--text-4xl); }
h3 { font-size: var(--text-3xl); }
h4 { font-size: var(--text-2xl); }
h5 { font-size: var(--text-xl); }
h6 { font-size: var(--text-lg); }

p {
  color: var(--text-secondary);
  margin-bottom: var(--space-md);
}

.text-gradient {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.text-muted {
  color: var(--text-muted);
}

/* ========================================
   Layout
   ======================================== */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

.section {
  padding: var(--space-3xl) 0;
}

.grid {
  display: grid;
  gap: var(--space-lg);
}

.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
  
  h1 { font-size: var(--text-3xl); }
  h2 { font-size: var(--text-2xl); }
  h3 { font-size: var(--text-xl); }
}

/* ========================================
   Header & Navigation
   ======================================== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(10, 10, 10, 0.8);
  backdrop-filter: var(--glass-blur);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.logo {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.logo-icon {
  width: 32px;
  height: 32px;
  background: var(--accent-gradient);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-lg);
}

.nav {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
}

.nav-links {
  display: flex;
  gap: var(--space-lg);
}

.nav-link {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--text-secondary);
  transition: color var(--transition-fast);
  position: relative;
}

.nav-link:hover,
.nav-link.active {
  color: var(--text-primary);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width var(--transition-base);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* Language Switcher */
.lang-switcher {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-xs) var(--space-sm);
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
}

.lang-btn {
  padding: var(--space-xs) var(--space-sm);
  border-radius: var(--radius-full);
  font-weight: 500;
  color: var(--text-muted);
  transition: all var(--transition-fast);
}

.lang-btn.active {
  background: var(--accent);
  color: white;
}

.lang-btn:hover:not(.active) {
  color: var(--text-primary);
}

/* Mobile Menu */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: var(--space-sm);
}

.menu-toggle span {
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  transition: all var(--transition-fast);
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  
  .menu-toggle {
    display: flex;
  }
  
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
    padding: var(--space-lg);
    gap: var(--space-md);
  }
}

/* ========================================
   Hero Section - Premium Design
   ======================================== */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 72px;
  padding-bottom: 120px;
  position: relative;
  overflow: hidden;
  background: radial-gradient(ellipse 80% 50% at 50% -20%, rgba(99, 102, 241, 0.15), transparent);
}

/* Seamless Bottom Gradient Transition */
.hero .hero-fade {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 200px;
  background: linear-gradient(to bottom, transparent 0%, var(--bg-primary) 100%);
  pointer-events: none;
  z-index: 1;
}

/* Animated Gradient Orbs */
.hero::before {
  content: '';
  position: absolute;
  top: -20%;
  left: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.2) 0%, transparent 60%);
  pointer-events: none;
  animation: float-orb 15s ease-in-out infinite;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  right: -10%;
  width: 700px;
  height: 700px;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.15) 0%, transparent 60%);
  pointer-events: none;
  animation: float-orb 20s ease-in-out infinite reverse;
}

@keyframes float-orb {
  0%, 100% { transform: translate(0, 0) scale(1); }
  25% { transform: translate(30px, -30px) scale(1.05); }
  50% { transform: translate(-20px, 20px) scale(0.95); }
  75% { transform: translate(20px, 30px) scale(1.02); }
}

/* Floating Particles Container */
.hero-particles {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.hero-particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--accent);
  border-radius: 50%;
  opacity: 0.3;
  animation: particle-float 8s ease-in-out infinite;
}

.hero-particle:nth-child(1) { left: 10%; top: 20%; animation-delay: 0s; animation-duration: 12s; }
.hero-particle:nth-child(2) { left: 20%; top: 60%; animation-delay: 1s; animation-duration: 10s; }
.hero-particle:nth-child(3) { left: 70%; top: 30%; animation-delay: 2s; animation-duration: 14s; }
.hero-particle:nth-child(4) { left: 80%; top: 70%; animation-delay: 3s; animation-duration: 11s; }
.hero-particle:nth-child(5) { left: 50%; top: 80%; animation-delay: 1.5s; animation-duration: 9s; }
.hero-particle:nth-child(6) { left: 30%; top: 40%; animation-delay: 2.5s; animation-duration: 13s; }
.hero-particle:nth-child(7) { left: 90%; top: 50%; animation-delay: 0.5s; animation-duration: 10s; }
.hero-particle:nth-child(8) { left: 5%; top: 85%; animation-delay: 4s; animation-duration: 15s; }

@keyframes particle-float {
  0%, 100% { transform: translateY(0) scale(1); opacity: 0.3; }
  50% { transform: translateY(-100px) scale(1.5); opacity: 0.6; }
}

/* Floating Book Icons */
.hero-floating-icons {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.floating-icon {
  position: absolute;
  font-size: 2rem;
  opacity: 0.08;
  animation: float-icon 20s ease-in-out infinite;
}

.floating-icon:nth-child(1) { left: 5%; top: 15%; animation-delay: 0s; }
.floating-icon:nth-child(2) { right: 8%; top: 25%; animation-delay: 3s; }
.floating-icon:nth-child(3) { left: 12%; bottom: 20%; animation-delay: 6s; }
.floating-icon:nth-child(4) { right: 15%; bottom: 30%; animation-delay: 9s; }
.floating-icon:nth-child(5) { left: 25%; top: 35%; animation-delay: 2s; font-size: 1.5rem; }
.floating-icon:nth-child(6) { right: 25%; top: 60%; animation-delay: 5s; font-size: 1.5rem; }

@keyframes float-icon {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  25% { transform: translateY(-20px) rotate(5deg); }
  50% { transform: translateY(-10px) rotate(-3deg); }
  75% { transform: translateY(-25px) rotate(3deg); }
}

.hero-content {
  text-align: center;
  max-width: 850px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
  animation: hero-reveal 1s ease-out;
}

@keyframes hero-reveal {
  from { opacity: 0; transform: translateY(40px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Enhanced Badge with Glow */
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-lg);
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.15) 0%, rgba(139, 92, 246, 0.1) 100%);
  border: 1px solid rgba(99, 102, 241, 0.4);
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--accent-hover);
  margin-bottom: var(--space-xl);
  backdrop-filter: blur(10px);
  box-shadow: 0 0 30px rgba(99, 102, 241, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  animation: badge-glow 3s ease-in-out infinite, hero-reveal 0.8s ease-out;
}

.hero-badge span:first-child {
  animation: sparkle 2s ease-in-out infinite;
}

@keyframes badge-glow {
  0%, 100% { box-shadow: 0 0 20px rgba(99, 102, 241, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.1); }
  50% { box-shadow: 0 0 40px rgba(99, 102, 241, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.15); }
}

@keyframes sparkle {
  0%, 100% { transform: scale(1) rotate(0deg); }
  50% { transform: scale(1.2) rotate(10deg); }
}

/* Title with Gradient Animation */
.hero-title {
  margin-bottom: var(--space-lg);
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  line-height: 1.1;
  animation: hero-reveal 1s ease-out 0.1s both;
}

.hero-title .text-gradient {
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 25%, #a855f7 50%, #8b5cf6 75%, #6366f1 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradient-shift 4s linear infinite;
  display: inline-block;
}

@keyframes gradient-shift {
  0% { background-position: 0% center; }
  100% { background-position: 200% center; }
}

.hero-subtitle {
  font-size: var(--text-xl);
  color: var(--text-secondary);
  margin-bottom: var(--space-2xl);
  max-width: 650px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.7;
  animation: hero-reveal 1s ease-out 0.2s both;
}

/* Premium Buttons */
.hero-buttons {
  display: flex;
  gap: var(--space-md);
  justify-content: center;
  flex-wrap: wrap;
  animation: hero-reveal 1s ease-out 0.3s both;
}

.hero-buttons .btn-primary {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
}

.hero-buttons .btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}

.hero-buttons .btn-primary:hover::before {
  left: 100%;
}

.hero-buttons .btn-secondary {
  position: relative;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
}

.hero-buttons .btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(99, 102, 241, 0.5);
  box-shadow: 0 0 30px rgba(99, 102, 241, 0.15);
}

/* Scroll Indicator */
.hero-scroll-indicator {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  color: var(--text-muted);
  font-size: var(--text-sm);
  animation: bounce-fade 2s ease-in-out infinite;
  cursor: pointer;
  z-index: 2;
}

.hero-scroll-indicator::after {
  content: '';
  width: 24px;
  height: 40px;
  border: 2px solid var(--border-hover);
  border-radius: var(--radius-full);
  position: relative;
}

.hero-scroll-indicator::before {
  content: '';
  position: absolute;
  bottom: 28px;
  width: 4px;
  height: 8px;
  background: var(--accent);
  border-radius: var(--radius-full);
  animation: scroll-dot 2s ease-in-out infinite;
}

@keyframes bounce-fade {
  0%, 100% { opacity: 0.5; transform: translateX(-50%) translateY(0); }
  50% { opacity: 1; transform: translateX(-50%) translateY(-5px); }
}

@keyframes scroll-dot {
  0%, 100% { transform: translateY(0); opacity: 1; }
  50% { transform: translateY(10px); opacity: 0.3; }
}

/* ========================================
   Buttons
   ======================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-xl);
  font-size: var(--text-sm);
  font-weight: 600;
  border-radius: var(--radius-lg);
  transition: all var(--transition-base);
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent-gradient);
  color: white;
  box-shadow: var(--shadow-md), var(--shadow-glow);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg), 0 0 60px rgba(99, 102, 241, 0.25);
  color: white;
}

.btn-secondary {
  background: var(--glass);
  border: 1px solid var(--border);
  color: var(--text-primary);
}

.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
  color: var(--text-primary);
}

.btn-amazon {
  background: #ff9900;
  color: #111;
}

.btn-amazon:hover {
  background: #ffad33;
  color: #111;
  transform: translateY(-2px);
}

.btn-sm {
  padding: var(--space-sm) var(--space-md);
  font-size: var(--text-xs);
}

.btn-lg {
  padding: var(--space-lg) var(--space-2xl);
  font-size: var(--text-base);
}

/* ========================================
   Cards
   ======================================== */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  transition: all var(--transition-base);
}

.card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

/* Book Card - Premium Hover Effect */
.book-card {
  display: flex;
  flex-direction: column;
}

.book-card-cover {
  aspect-ratio: 2/3;
  background: var(--bg-tertiary);
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.4s ease;
}

.book-card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

/* Clean Pop-Up Effect - No Distortion */
.book-card:hover .book-card-cover {
  transform: translateY(-12px) scale(1.02);
  box-shadow: 
    0 25px 50px rgba(0, 0, 0, 0.4),
    0 0 30px rgba(99, 102, 241, 0.15);
}

.book-card:hover .book-card-cover img {
  transform: scale(1.08);
}

/* Glow ring effect */
.book-card-cover::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  opacity: 0;
  transition: opacity 0.4s ease;
  box-shadow: inset 0 0 0 2px rgba(99, 102, 241, 0.5);
}

.book-card:hover .book-card-cover::after {
  opacity: 1;
}

/* Typewriter Animation */
.typewriter {
  overflow: hidden;
  border-right: 2px solid var(--accent);
  white-space: nowrap;
  margin: 0 auto;
  letter-spacing: 0.15em;
  animation: 
    typing 3.5s steps(40, end),
    blink-caret .75s step-end infinite;
}

@keyframes typing {
  from { width: 0 }
  to { width: 100% }
}

@keyframes blink-caret {
  from, to { border-color: transparent }
  50% { border-color: var(--accent) }
}

.book-card-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-secondary) 100%);
  padding: var(--space-lg);
  text-align: center;
}

.book-card-placeholder-icon {
  font-size: 3rem;
  margin-bottom: var(--space-md);
  opacity: 0.5;
}

.book-card-placeholder-title {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.3;
}

.book-card-body {
  padding: var(--space-lg);
  flex: 1;
  display: flex;
  flex-direction: column;
}

.book-card-title {
  font-size: var(--text-lg);
  font-weight: 600;
  margin-bottom: var(--space-xs);
  line-height: 1.3;
}

.book-card-subtitle {
  font-size: var(--text-sm);
  color: var(--text-muted);
  margin-bottom: var(--space-sm);
}

.book-card-author {
  font-size: var(--text-sm);
  color: var(--text-secondary);
  margin-bottom: var(--space-md);
}

.book-card-buttons {
  display: flex;
  gap: var(--space-sm);
  margin-top: auto;
  flex-wrap: wrap;
}

.book-card-buttons .btn {
  flex: 1;
  min-width: 0;
  padding: var(--space-sm) var(--space-md);
}

/* ========================================
   Book Formats Badges
   ======================================== */
.format-badges {
  display: flex;
  gap: var(--space-xs);
  flex-wrap: wrap;
  margin-bottom: var(--space-md);
}

.format-badge {
  padding: var(--space-xs) var(--space-sm);
  font-size: var(--text-xs);
  font-weight: 500;
  border-radius: var(--radius-sm);
  background: var(--glass);
  border: 1px solid var(--border);
  color: var(--text-muted);
}

.format-badge.available {
  background: var(--accent-light);
  border-color: rgba(99, 102, 241, 0.3);
  color: var(--accent);
}

/* ========================================
   Section Headers
   ======================================== */
.section-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto var(--space-3xl);
}

.section-label {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: var(--space-sm);
}

.section-title {
  margin-bottom: var(--space-md);
}

.section-description {
  font-size: var(--text-lg);
  color: var(--text-secondary);
}

/* ========================================
   Footer
   ======================================== */
.footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: var(--space-3xl) 0 var(--space-xl);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--space-2xl);
  margin-bottom: var(--space-2xl);
}

.footer-brand {
  max-width: 300px;
}

.footer-brand .logo {
  margin-bottom: var(--space-md);
}

.footer-brand p {
  font-size: var(--text-sm);
}

.footer-title {
  font-size: var(--text-sm);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-md);
  color: var(--text-primary);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.footer-links a {
  font-size: var(--text-sm);
  color: var(--text-muted);
}

.footer-links a:hover {
  color: var(--text-primary);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: var(--space-xl);
  border-top: 1px solid var(--border);
  font-size: var(--text-sm);
  color: var(--text-muted);
}

@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  
  .footer-brand {
    grid-column: span 2;
  }
  
  .footer-bottom {
    flex-direction: column;
    gap: var(--space-md);
    text-align: center;
  }
}

/* ========================================
   Book Detail Page
   ======================================== */
.book-detail {
  padding-top: calc(72px + var(--space-3xl));
}

.book-detail-grid {
  display: grid;
  grid-template-columns: 400px 1fr;
  gap: var(--space-3xl);
  align-items: start;
}

.book-cover-large {
  position: sticky;
  top: calc(72px + var(--space-xl));
  aspect-ratio: 2/3;
  background: var(--bg-tertiary);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.book-cover-large img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.book-info h1 {
  font-size: var(--text-4xl);
  margin-bottom: var(--space-sm);
}

.book-info .subtitle {
  font-size: var(--text-xl);
  color: var(--text-secondary);
  margin-bottom: var(--space-md);
}

.book-info .author {
  font-size: var(--text-lg);
  color: var(--text-muted);
  margin-bottom: var(--space-xl);
}

.book-description {
  font-size: var(--text-base);
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: var(--space-2xl);
}

.book-buy-buttons {
  display: flex;
  gap: var(--space-md);
  flex-wrap: wrap;
  margin-bottom: var(--space-2xl);
}

.book-keywords {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.keyword-tag {
  padding: var(--space-xs) var(--space-md);
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  color: var(--text-muted);
}

@media (max-width: 1024px) {
  .book-detail-grid {
    grid-template-columns: 1fr;
  }
  
  .book-cover-large {
    position: static;
    max-width: 300px;
    margin: 0 auto var(--space-2xl);
  }
}

/* ========================================
   Reading Sample
   ======================================== */
.reading-sample {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: var(--space-2xl);
  margin-top: var(--space-3xl);
}

.reading-sample h3 {
  margin-bottom: var(--space-lg);
}

.reading-sample-content {
  font-size: var(--text-base);
  line-height: 1.9;
  color: var(--text-secondary);
  max-height: 400px;
  overflow: hidden;
  position: relative;
}

.reading-sample-content::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 100px;
  background: linear-gradient(transparent, var(--bg-secondary));
}

.reading-sample-cta {
  margin-top: var(--space-lg);
  text-align: center;
}

/* ========================================
   Utilities
   ======================================== */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.mt-md { margin-top: var(--space-md); }
.mb-md { margin-bottom: var(--space-md); }
.mt-lg { margin-top: var(--space-lg); }
.mb-lg { margin-bottom: var(--space-lg); }
.mt-xl { margin-top: var(--space-xl); }
.mb-xl { margin-bottom: var(--space-xl); }

/* ========================================
   Animations
   ======================================== */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.animate-fade-in {
  animation: fadeIn 0.6s ease forwards;
}

.animate-delay-1 { animation-delay: 0.1s; }
.animate-delay-2 { animation-delay: 0.2s; }
.animate-delay-3 { animation-delay: 0.3s; }
.animate-delay-4 { animation-delay: 0.4s; }

/* Smooth page transition */
.page-transition {
  opacity: 0;
  animation: fadeIn 0.4s ease forwards;
}
