/* ==========================================
   MANGAFIRE - COMPLETE STYLESHEET
   Mobile-First Responsive Design
   ========================================== */

/* CSS Variables */
:root {
  /* Colors - Dark Theme */
  --bg-primary: #0d0d0d;
  --bg-secondary: #141414;
  --bg-tertiary: #1a1a1a;
  --bg-card: #1f1f1f;
  --bg-card-hover: #252525;
  --bg-input: #2a2a2a;
  
  --accent-primary: #ff6b35;
  --accent-secondary: #ff8c5a;
  --accent-gradient: linear-gradient(135deg, #ff6b35 0%, #f7931e 100%);
  
  --text-primary: #ffffff;
  --text-secondary: #b3b3b3;
  --text-muted: #666666;
  --text-dark: #0d0d0d;
  
  --border-color: #2a2a2a;
  --border-light: #333333;
  
  --success: #22c55e;
  --warning: #f59e0b;
  --error: #ef4444;
  --info: #3b82f6;
  
  /* Typography */
  --font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  
  /* Spacing */
  --header-height: 64px;
  --container-width: 1320px;
  
  /* Border Radius */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;
  
  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
  
  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.3s ease;
  
  /* Z-Index */
  --z-dropdown: 100;
  --z-sticky: 200;
  --z-fixed: 300;
  --z-modal-backdrop: 400;
  --z-modal: 500;
  --z-toast: 600;
  --z-preloader: 1000;
}

/* ==========================================
   RESET & BASE
   ========================================== */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
}

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

body.no-scroll {
  overflow: hidden;
  position: fixed;
  width: 100%;
}

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

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  outline: none;
  background: none;
  -webkit-tap-highlight-color: transparent;
}

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

ul, ol {
  list-style: none;
}

input, textarea, select {
  font-family: inherit;
  font-size: 16px; /* Prevents zoom on iOS */
  outline: none;
  border: none;
}

/* ==========================================
   PRELOADER
   ========================================== */
/* ==========================================
   PRELOADER (Lottie Version)
   ========================================== */
#preloader {
  position: fixed;
  inset: 0;
  background: #0d0d0d; /* Keep dark background */
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: var(--z-preloader);
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

#preloader.loaded {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.preloader-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  /* No gap needed, we control spacing via margins */
}

/* We don't need the old .preloader-icon class anymore, 
   but if you kept the div wrapper, ensure it has no background */
.preloader-inner lottie-player {
  /* Ensure it pops against the dark background */
  filter: drop-shadow(0 0 20px rgba(255, 107, 53, 0.2)); 
}

.preloader-inner span {
  font-size: 24px;
  font-weight: 800;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.8; transform: scale(0.98); }
}
/* ==========================================
   SCROLLBAR
   ========================================== */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
  background: var(--border-light);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

/* ==========================================
   CONTAINER
   ========================================== */
.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 16px;
}

@media (min-width: 768px) {
  .container {
    padding: 0 20px;
  }
}

/* ==========================================
   HEADER
   ========================================== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: rgba(13, 13, 13, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-color);
  z-index: var(--z-fixed);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  gap: 12px;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.logo-icon {
  width: 36px;
  height: 36px;
  background: var(--accent-gradient);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: white;
}

.logo-text {
  font-size: 20px;
  font-weight: 800;
  color: var(--text-primary);
  display: none;
}

.logo-text span {
  color: var(--accent-primary);
}

@media (min-width: 480px) {
  .logo-text {
    display: block;
  }
}

@media (min-width: 768px) {
  .logo-icon {
    width: 40px;
    height: 40px;
    font-size: 20px;
  }
  
  .logo-text {
    font-size: 22px;
  }
}

/* Navigation */
.nav {
  display: none;
  align-items: center;
  gap: 4px;
}

@media (min-width: 992px) {
  .nav {
    display: flex;
  }
}

.nav-link {
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link:hover,
.nav-link.active {
  color: var(--text-primary);
  background: var(--bg-tertiary);
}

.nav-link.active {
  color: var(--accent-primary);
}

/* Search Bar */
.search-bar {
  flex: 1;
  max-width: 400px;
  position: relative;
  display: none;
}

@media (min-width: 768px) {
  .search-bar {
    display: block;
  }
}

.search-bar input {
  width: 100%;
  height: 42px;
  padding: 0 46px 0 18px;
  background: var(--bg-input);
  border: 2px solid transparent;
  border-radius: var(--radius-full);
  color: var(--text-primary);
  font-size: 14px;
  transition: all var(--transition-fast);
}

.search-bar input::placeholder {
  color: var(--text-muted);
}

.search-bar input:focus {
  border-color: var(--accent-primary);
  background: var(--bg-tertiary);
}

.search-bar button {
  position: absolute;
  right: 5px;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  background: var(--accent-gradient);
  border-radius: var(--radius-full);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
}

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

.auth-buttons {
  display: flex;
  align-items: center;
  gap: 8px;
}

.auth-buttons .btn-ghost {
  display: none;
}

@media (min-width: 480px) {
  .auth-buttons .btn-ghost {
    display: inline-flex;
  }
}

/* User Menu */
.user-menu {
  position: relative;
}

.user-menu-trigger {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 10px 5px 5px;
  background: var(--bg-input);
  border-radius: var(--radius-full);
  cursor: pointer;
}

.user-menu-trigger img {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-full);
  object-fit: cover;
}

.user-menu-trigger span {
  font-size: 14px;
  font-weight: 500;
  max-width: 80px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: none;
}

@media (min-width: 480px) {
  .user-menu-trigger span {
    display: block;
  }
}

.user-menu-trigger i {
  font-size: 12px;
  color: var(--text-muted);
  display: none;
}

@media (min-width: 480px) {
  .user-menu-trigger i {
    display: block;
  }
}

.user-menu-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 200px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-lg);
  z-index: var(--z-dropdown);
}

.user-menu.active .user-menu-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.user-menu-dropdown a,
.user-menu-dropdown button {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 16px;
  font-size: 14px;
  color: var(--text-secondary);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
  text-align: left;
}

.user-menu-dropdown a:hover,
.user-menu-dropdown button:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
}

.user-menu-dropdown .divider {
  height: 1px;
  background: var(--border-color);
  margin: 8px 0;
}

.user-menu-dropdown .logout-btn:hover {
  color: var(--error);
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
  display: flex;
  width: 40px;
  height: 40px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
  align-items: center;
  justify-content: center;
  color: var(--text-primary);
  font-size: 18px;
}

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

/* ==========================================
   MOBILE MENU
   ========================================== */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  pointer-events: none;
}

.mobile-menu.active {
  pointer-events: auto;
}

.mobile-menu-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  opacity: 0;
  transition: opacity var(--transition-normal);
}

.mobile-menu.active .mobile-menu-overlay {
  opacity: 1;
}

.mobile-menu-content {
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: 280px;
  max-width: 85%;
  background: var(--bg-card);
  padding: 20px;
  transform: translateX(-100%);
  transition: transform var(--transition-normal);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.mobile-menu.active .mobile-menu-content {
  transform: translateX(0);
}

.mobile-menu-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 20px;
}

.mobile-menu-close {
  width: 36px;
  height: 36px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

.mobile-menu-search {
  position: relative;
  margin-bottom: 20px;
}

.mobile-menu-search input {
  width: 100%;
  padding: 12px 16px 12px 44px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
}

.mobile-menu-search i {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
}

.mobile-menu-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 20px;
}

.mobile-menu-nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
}

.mobile-menu-nav a:hover,
.mobile-menu-nav a.active {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.mobile-menu-nav a i {
  width: 20px;
  text-align: center;
}

.mobile-menu-divider {
  height: 1px;
  background: var(--border-color);
  margin: 16px 0;
}

.mobile-menu-auth {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.mobile-menu-auth .btn {
  width: 100%;
  justify-content: center;
}

/* ==========================================
   BUTTONS
   ========================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  font-size: 14px;
  font-weight: 600;
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}

.btn-sm {
  padding: 8px 14px;
  font-size: 13px;
}

.btn-lg {
  padding: 14px 28px;
  font-size: 15px;
}

.btn-primary {
  background: var(--accent-gradient);
  color: white;
  box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 107, 53, 0.4);
  color: white;
}

.btn-secondary {
  background: var(--bg-input);
  color: var(--text-primary);
}

.btn-secondary:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
}

.btn-ghost:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
}

/* ==========================================
   MAIN CONTENT
   ========================================== */
#main-content {
  min-height: calc(100vh - var(--header-height));
  padding-top: var(--header-height);
}

/* ==========================================
   LOADING & SPINNER
   ========================================== */
.loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  gap: 16px;
  min-height: 300px;
}

.spinner {
  width: 44px;
  height: 44px;
  border: 4px solid var(--border-color);
  border-top-color: var(--accent-primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.loading-text {
  font-size: 14px;
  color: var(--text-muted);
}

/* ==========================================
   EMPTY STATE
   ========================================== */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  text-align: center;
}

.empty-state-icon {
  width: 80px;
  height: 80px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.empty-state-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}

.empty-state-desc {
  font-size: 14px;
  color: var(--text-muted);
  max-width: 300px;
  margin-bottom: 20px;
}

/* ==========================================
   HERO SECTION
   ========================================== */
.hero {
  padding: 20px 0;
}

@media (min-width: 768px) {
  .hero {
    padding: 40px 0;
  }
}

.hero-slider {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-secondary);
}

@media (min-width: 768px) {
  .hero-slider {
    border-radius: var(--radius-xl);
  }
}

.hero-slide {
  display: none;
  position: relative;
  min-height: 320px;
}

@media (min-width: 768px) {
  .hero-slide {
    min-height: 420px;
  }
}

@media (min-width: 992px) {
  .hero-slide {
    min-height: 450px;
  }
}

.hero-slide.active {
  display: block;
  animation: fadeIn 0.5s ease;
}

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

.hero-slide-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center top;
  filter: blur(20px);
  transform: scale(1.2);
  opacity: 0.5;
}

.hero-slide-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    rgba(13, 13, 13, 0.98) 0%,
    rgba(13, 13, 13, 0.9) 30%,
    rgba(13, 13, 13, 0.7) 60%,
    rgba(13, 13, 13, 0.5) 100%
  );
}

@media (max-width: 767px) {
  .hero-slide-overlay {
    background: linear-gradient(
      to bottom,
      rgba(13, 13, 13, 0.5) 0%,
      rgba(13, 13, 13, 0.95) 100%
    );
  }
}

.hero-slide-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 30px 20px;
  min-height: 320px;
}

@media (min-width: 768px) {
  .hero-slide-content {
    flex-direction: row;
    text-align: left;
    align-items: center;
    gap: 30px;
    padding: 40px;
    min-height: 420px;
  }
}

@media (min-width: 992px) {
  .hero-slide-content {
    gap: 40px;
    min-height: 450px;
  }
}

.hero-slide-poster {
  flex-shrink: 0;
  width: 140px;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  margin-bottom: 16px;
}

@media (min-width: 768px) {
  .hero-slide-poster {
    width: 200px;
    border-radius: var(--radius-lg);
    margin-bottom: 0;
  }
}

@media (min-width: 992px) {
  .hero-slide-poster {
    width: 260px;
  }
}

.hero-slide-poster img {
  width: 100%;
  height: auto;
  aspect-ratio: 3/4;
  object-fit: cover;
}

.hero-slide-info {
  flex: 1;
  max-width: 100%;
}

@media (min-width: 768px) {
  .hero-slide-info {
    max-width: 500px;
  }
}

@media (min-width: 992px) {
  .hero-slide-info {
    max-width: 600px;
  }
}

.hero-slide-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  background: var(--accent-primary);
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 600;
  color: white;
  margin-bottom: 12px;
}

.hero-slide-title {
  font-size: 22px;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 10px;
}

@media (min-width: 768px) {
  .hero-slide-title {
    font-size: 28px;
    margin-bottom: 12px;
  }
}

@media (min-width: 992px) {
  .hero-slide-title {
    font-size: 36px;
  }
}

.hero-slide-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-bottom: 12px;
}

@media (min-width: 768px) {
  .hero-slide-meta {
    justify-content: flex-start;
    gap: 16px;
  }
}

.hero-slide-meta-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  color: var(--text-secondary);
}

@media (min-width: 768px) {
  .hero-slide-meta-item {
    font-size: 13px;
  }
}

.hero-slide-meta-item i {
  color: var(--accent-primary);
  font-size: 11px;
}

.hero-slide-genres {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin-bottom: 12px;
}

@media (min-width: 768px) {
  .hero-slide-genres {
    justify-content: flex-start;
    gap: 8px;
    margin-bottom: 14px;
  }
}

.hero-slide-genres span {
  padding: 5px 12px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 500;
}

.hero-slide-desc {
  display: none;
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 20px;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@media (min-width: 768px) {
  .hero-slide-desc {
    display: -webkit-box;
  }
}

.hero-slide-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
}

@media (min-width: 768px) {
  .hero-slide-actions {
    justify-content: flex-start;
    gap: 12px;
  }
}

.hero-slide-actions .btn {
  padding: 10px 20px;
  font-size: 13px;
}

@media (min-width: 768px) {
  .hero-slide-actions .btn {
    padding: 12px 24px;
    font-size: 14px;
  }
}

/* Hero Navigation */
.hero-nav {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 2;
}

.hero-nav-dot {
  width: 8px;
  height: 8px;
  background: rgba(255, 255, 255, 0.3);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
  border: none;
}

.hero-nav-dot.active {
  width: 28px;
  background: var(--accent-primary);
}

/* Hero Arrows */
.hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-full);
  color: white;
  font-size: 16px;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2;
  opacity: 0;
  transition: all var(--transition-fast);
}

@media (min-width: 768px) {
  .hero-arrow {
    display: flex;
  }
  
  .hero-slider:hover .hero-arrow {
    opacity: 1;
  }
}

.hero-arrow:hover {
  background: var(--accent-primary);
}

.hero-arrow.prev {
  left: 16px;
}

.hero-arrow.next {
  right: 16px;
}

/* ==========================================
   SECTION
   ========================================== */
.section {
  padding: 30px 0;
}

@media (min-width: 768px) {
  .section {
    padding: 40px 0;
  }
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  gap: 16px;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 700;
}

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

.section-title i {
  color: var(--accent-primary);
}

.view-all-link {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 500;
  color: var(--accent-primary);
  white-space: nowrap;
}

.view-all-link:hover {
  gap: 10px;
}

/* ==========================================
   MANGA CARD
   ========================================== */
.manga-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

@media (min-width: 480px) {
  .manga-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }
}

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

@media (min-width: 992px) {
  .manga-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

@media (min-width: 1200px) {
  .manga-grid {
    grid-template-columns: repeat(6, 1fr);
  }
}

.manga-card {
  position: relative;
  background: var(--bg-card);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: all var(--transition-normal);
}

@media (min-width: 768px) {
  .manga-card {
    border-radius: var(--radius-lg);
  }
  
  .manga-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
  }
}

.manga-card-poster {
  position: relative;
  aspect-ratio: 3/4;
  overflow: hidden;
}

.manga-card-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-normal);
}

@media (min-width: 768px) {
  .manga-card:hover .manga-card-poster img {
    transform: scale(1.1);
  }
}

.manga-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, transparent 50%);
  opacity: 0;
  transition: opacity var(--transition-fast);
}

.manga-card:hover .manga-card-overlay {
  opacity: 1;
}

.manga-card-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.8);
  width: 48px;
  height: 48px;
  background: var(--accent-gradient);
  border-radius: var(--radius-full);
  display: none;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 18px;
  opacity: 0;
  transition: all var(--transition-fast);
}

@media (min-width: 768px) {
  .manga-card-play {
    display: flex;
  }
  
  .manga-card:hover .manga-card-play {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

.manga-card-badges {
  position: absolute;
  top: 8px;
  left: 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.manga-card-badge {
  padding: 3px 8px;
  background: var(--accent-primary);
  border-radius: var(--radius-sm);
  font-size: 10px;
  font-weight: 600;
  color: white;
}

.manga-card-rating {
  position: absolute;
  top: 8px;
  right: 8px;
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 3px 8px;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 600;
}

.manga-card-rating i {
  color: #ffc107;
  font-size: 9px;
}

.manga-card-info {
  padding: 10px;
}

@media (min-width: 768px) {
  .manga-card-info {
    padding: 14px;
  }
}

.manga-card-title {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 6px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@media (min-width: 768px) {
  .manga-card-title {
    font-size: 14px;
  }
}

.manga-card:hover .manga-card-title {
  color: var(--accent-primary);
}

.manga-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  color: var(--text-muted);
}

.manga-card-chapter {
  color: var(--accent-primary);
  font-weight: 500;
}

.manga-card-status {
  display: flex;
  align-items: center;
  gap: 4px;
}

.manga-card-status::before {
  content: '';
  width: 5px;
  height: 5px;
  border-radius: var(--radius-full);
  background: var(--success);
}

.manga-card-status.completed::before {
  background: var(--info);
}

.manga-card-status.hiatus::before {
  background: var(--warning);
}

/* ==========================================
   UPDATE CARDS
   ========================================== */
.updates-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

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

.update-card {
  display: flex;
  gap: 12px;
  padding: 12px;
  background: var(--bg-card);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
}

@media (min-width: 768px) {
  .update-card {
    padding: 14px;
    border-radius: var(--radius-lg);
  }
  
  .update-card:hover {
    background: var(--bg-card-hover);
  }
}

.update-card-poster {
  flex-shrink: 0;
  width: 60px;
  height: 80px;
  border-radius: var(--radius-sm);
  overflow: hidden;
}

@media (min-width: 768px) {
  .update-card-poster {
    width: 70px;
    height: 95px;
    border-radius: var(--radius-md);
  }
}

.update-card-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.update-card-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.update-card-title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.update-card-title:hover {
  color: var(--accent-primary);
}

.update-card-chapters {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: auto;
}

.update-card-chapter {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 10px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-sm);
  font-size: 12px;
}

.update-card-chapter:hover {
  background: var(--accent-primary);
  color: white;
}

.update-card-chapter span:first-child {
  font-weight: 500;
}

.update-card-chapter span:last-child {
  font-size: 11px;
  color: var(--text-muted);
}

.update-card-chapter:hover span:last-child {
  color: rgba(255, 255, 255, 0.7);
}

/* ==========================================
   HOME LAYOUT
   ========================================== */
.home-layout {
  display: flex;
  flex-direction: column;
  gap: 30px;
}

@media (min-width: 1200px) {
  .home-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 30px;
  }
}

.home-main {
  min-width: 0;
}

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

@media (min-width: 768px) and (max-width: 1199px) {
  .home-sidebar {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Sidebar Sections */
.sidebar-section {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 16px;
}

@media (min-width: 768px) {
  .sidebar-section {
    padding: 20px;
  }
}

.sidebar-section-header {
  margin-bottom: 14px;
}

.sidebar-section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 700;
}

.sidebar-section-title i {
  color: var(--accent-primary);
}

/* Ranking List */
.ranking-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ranking-item {
  display: flex;
  gap: 10px;
  padding: 8px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
}

.ranking-item:hover {
  background: var(--bg-card-hover);
}

.ranking-number {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  background: var(--bg-input);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
}

.ranking-item:nth-child(1) .ranking-number {
  background: var(--accent-gradient);
  color: white;
}

.ranking-item:nth-child(2) .ranking-number {
  background: #c0c0c0;
  color: var(--text-dark);
}

.ranking-item:nth-child(3) .ranking-number {
  background: #cd7f32;
  color: white;
}

.ranking-poster {
  flex-shrink: 0;
  width: 40px;
  height: 54px;
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.ranking-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ranking-info {
  flex: 1;
  min-width: 0;
}

.ranking-title {
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ranking-title:hover {
  color: var(--accent-primary);
}

.ranking-meta {
  display: flex;
  gap: 10px;
  font-size: 11px;
  color: var(--text-muted);
}

.ranking-meta span {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Genres Cloud */
.genres-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.genre-tag {
  padding: 7px 12px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--transition-fast);
}

.genre-tag:hover {
  background: var(--accent-primary);
  color: white;
}

/* ==========================================
   MANGA DETAIL PAGE
   ========================================== */
.manga-detail {
  padding-bottom: 40px;
}

.manga-detail-header {
  position: relative;
  margin-bottom: 24px;
}

.manga-detail-banner {
  position: absolute;
  inset: 0;
  height: 280px;
  background-size: cover;
  background-position: center;
  filter: blur(30px);
  opacity: 0.3;
  transform: scale(1.1);
}

@media (min-width: 768px) {
  .manga-detail-banner {
    height: 350px;
  }
}

.manga-detail-banner-overlay {
  position: absolute;
  inset: 0;
  height: 280px;
  background: linear-gradient(to bottom, transparent 0%, var(--bg-primary) 100%);
}

@media (min-width: 768px) {
  .manga-detail-banner-overlay {
    height: 350px;
  }
}

.manga-detail-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding-top: 24px;
}

@media (min-width: 768px) {
  .manga-detail-content {
    flex-direction: row;
    align-items: flex-start;
    text-align: left;
    gap: 30px;
    padding-top: 30px;
  }
}

.manga-detail-poster {
  flex-shrink: 0;
  width: 180px;
  margin-bottom: 20px;
}

@media (min-width: 768px) {
  .manga-detail-poster {
    width: 250px;
    margin-bottom: 0;
  }
}

@media (min-width: 992px) {
  .manga-detail-poster {
    width: 280px;
  }
}

.manga-detail-poster img {
  width: 100%;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.manga-detail-poster-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 16px;
}

.manga-detail-poster-actions .btn {
  width: 100%;
}

.manga-detail-info {
  flex: 1;
}

.manga-detail-type {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  background: var(--accent-gradient);
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 600;
  color: white;
  margin-bottom: 12px;
}

.manga-detail-title {
  font-size: 24px;
  font-weight: 800;
  line-height: 1.3;
  margin-bottom: 8px;
}

@media (min-width: 768px) {
  .manga-detail-title {
    font-size: 28px;
  }
}

@media (min-width: 992px) {
  .manga-detail-title {
    font-size: 32px;
  }
}

.manga-detail-alt-title {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.manga-detail-stats {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
  margin-bottom: 20px;
}

@media (min-width: 768px) {
  .manga-detail-stats {
    justify-content: flex-start;
    gap: 24px;
  }
}

.manga-detail-stat {
  text-align: center;
}

.manga-detail-stat-value {
  font-size: 22px;
  font-weight: 700;
  color: var(--accent-primary);
}

.manga-detail-stat-label {
  font-size: 11px;
  color: var(--text-muted);
}

.manga-detail-meta {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin-bottom: 16px;
}

@media (min-width: 480px) {
  .manga-detail-meta {
    grid-template-columns: repeat(2, 1fr);
  }
}

.manga-detail-meta-item {
  display: flex;
  gap: 8px;
  font-size: 13px;
  justify-content: center;
}

@media (min-width: 768px) {
  .manga-detail-meta-item {
    justify-content: flex-start;
  }
}

.manga-detail-meta-item .label {
  color: var(--text-muted);
}

.manga-detail-meta-item .value {
  font-weight: 500;
}

.manga-detail-genres {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-bottom: 20px;
}

@media (min-width: 768px) {
  .manga-detail-genres {
    justify-content: flex-start;
  }
}

.manga-detail-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

@media (min-width: 768px) {
  .manga-detail-actions {
    justify-content: flex-start;
  }
}

/* Manga Detail Sections */
.manga-detail-section {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 20px;
}

@media (min-width: 768px) {
  .manga-detail-section {
    padding: 24px;
  }
}

.manga-detail-section-title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}

@media (min-width: 768px) {
  .manga-detail-section-title {
    font-size: 18px;
  }
}

.manga-detail-section-title i {
  color: var(--accent-primary);
}

.manga-detail-section-title .count {
  font-size: 13px;
  font-weight: 400;
  color: var(--text-muted);
}

.manga-detail-desc {
  font-size: 13px;
  line-height: 1.8;
  color: var(--text-secondary);
}

@media (min-width: 768px) {
  .manga-detail-desc {
    font-size: 14px;
  }
}

/* Chapter List */
.chapter-list-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  flex-wrap: wrap;
  gap: 12px;
}

.chapter-list-controls select {
  padding: 8px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 13px;
}

.chapter-list {
  max-height: 450px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.chapter-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-md);
  margin-bottom: 8px;
  transition: all var(--transition-fast);
  gap: 12px;
}

.chapter-item:hover {
  background: var(--bg-card-hover);
}

@media (min-width: 768px) {
  .chapter-item:hover {
    transform: translateX(6px);
  }
}

.chapter-item-info {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.chapter-number {
  font-weight: 600;
  color: var(--accent-primary);
  font-size: 13px;
}

.chapter-title {
  font-size: 12px;
  color: var(--text-secondary);
}

.chapter-item-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 11px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.chapter-item-meta span {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ==========================================
   READER PAGE - FULLY RESPONSIVE
   ========================================== */
.reader-page {
  background: #000;
  min-height: 100vh;
  position: relative;
}

/* Reader Header */
.reader-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 56px;
  background: rgba(13, 13, 13, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-color);
  z-index: var(--z-fixed);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 12px;
  transition: transform var(--transition-fast);
}

@media (min-width: 768px) {
  .reader-header {
    height: 60px;
    padding: 0 20px;
  }
}

.reader-header.hidden {
  transform: translateY(-100%);
}

.reader-header-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}

.reader-back-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 14px;
  flex-shrink: 0;
}

@media (min-width: 480px) {
  .reader-back-btn {
    width: auto;
    padding: 0 12px;
    gap: 6px;
  }
  
  .reader-back-btn span {
    display: inline;
    font-size: 13px;
    font-weight: 500;
  }
}

.reader-back-btn span {
  display: none;
}

.reader-manga-title {
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: none;
}

@media (min-width: 768px) {
  .reader-manga-title {
    display: block;
    max-width: 200px;
  }
}

@media (min-width: 992px) {
  .reader-manga-title {
    max-width: 300px;
  }
}

.reader-header-center {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-shrink: 0;
}

@media (min-width: 768px) {
  .reader-header-center {
    gap: 10px;
  }
}

.reader-nav-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 14px;
  transition: all var(--transition-fast);
}

@media (min-width: 480px) {
  .reader-nav-btn {
    width: auto;
    padding: 0 12px;
    gap: 5px;
  }
  
  .reader-nav-btn span {
    display: inline;
    font-size: 12px;
    font-weight: 500;
  }
}

.reader-nav-btn span {
  display: none;
}

.reader-nav-btn:hover:not(:disabled) {
  background: var(--accent-primary);
}

.reader-nav-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.reader-chapter-select {
  width: 100px;
  padding: 8px 10px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 12px;
  text-overflow: ellipsis;
}

@media (min-width: 480px) {
  .reader-chapter-select {
    width: 140px;
    padding: 8px 12px;
    font-size: 13px;
  }
}

@media (min-width: 768px) {
  .reader-chapter-select {
    width: 180px;
  }
}

.reader-header-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.reader-settings-btn {
  width: 36px;
  height: 36px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  transition: background var(--transition-fast);
}

.reader-settings-btn:hover {
  background: var(--bg-tertiary);
}

/* Reader Content */
.reader-content {
  padding-top: 56px;
  padding-bottom: 70px;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 100vh;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

@media (min-width: 768px) {
  .reader-content {
    padding-top: 60px;
    padding-bottom: 80px;
  }
}

.reader-images {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

.reader-image {
  display: block;
  max-width: 100%;
  width: auto;
  height: auto;
}

.reader-image.fit-width {
  width: 100%;
  max-width: 900px;
  height: auto;
}

.reader-image.fit-height {
  width: auto;
  max-height: 100vh;
  max-width: 100%;
}

/* Reader Footer */
.reader-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: rgba(13, 13, 13, 0.95);
  backdrop-filter: blur(10px);
  border-top: 1px solid var(--border-color);
  z-index: var(--z-fixed);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 0 16px;
  transition: transform var(--transition-fast);
}

@media (min-width: 768px) {
  .reader-footer {
    height: 60px;
    gap: 20px;
    padding: 0 20px;
  }
}

.reader-footer.hidden {
  transform: translateY(100%);
}

.reader-page-indicator {
  font-size: 13px;
  font-weight: 600;
  min-width: 60px;
  text-align: center;
  flex-shrink: 0;
}

@media (min-width: 768px) {
  .reader-page-indicator {
    font-size: 14px;
    min-width: 80px;
  }
}

.reader-progress {
  flex: 1;
  max-width: 350px;
  height: 8px;
  background: var(--bg-input);
  border-radius: 4px;
  cursor: pointer;
  position: relative;
  -webkit-tap-highlight-color: transparent;
}

@media (min-width: 768px) {
  .reader-progress {
    max-width: 400px;
    height: 6px;
  }
}

.reader-progress-fill {
  height: 100%;
  background: var(--accent-gradient);
  border-radius: 4px;
  transition: width var(--transition-fast);
  pointer-events: none;
}

/* Reader Settings Panel */
.reader-settings-panel {
  position: fixed;
  top: 64px;
  right: 12px;
  width: calc(100% - 24px);
  max-width: 280px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 16px;
  z-index: var(--z-modal);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-lg);
}

@media (min-width: 768px) {
  .reader-settings-panel {
    top: 70px;
    right: 20px;
    width: 280px;
    padding: 20px;
  }
}

.reader-settings-panel.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.settings-group {
  margin-bottom: 18px;
}

.settings-group:last-child {
  margin-bottom: 0;
}

.settings-group label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--text-secondary);
}

.settings-options {
  display: flex;
  gap: 8px;
}

.settings-option {
  flex: 1;
  padding: 10px 8px;
  background: var(--bg-input);
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 500;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.settings-option:hover {
  background: var(--bg-tertiary);
}

.settings-option.active {
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  background: rgba(255, 107, 53, 0.1);
}

/* ==========================================
   BROWSE PAGE
   ========================================== */
.browse-page {
  padding: 20px 0 40px;
}

@media (min-width: 768px) {
  .browse-page {
    padding: 30px 0 40px;
  }
}

.browse-header {
  margin-bottom: 24px;
}

.browse-title {
  font-size: 22px;
  font-weight: 800;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}

@media (min-width: 768px) {
  .browse-title {
    font-size: 28px;
    margin-bottom: 20px;
  }
}

.browse-title i {
  color: var(--accent-primary);
}

.browse-filters {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
}

@media (min-width: 768px) {
  .browse-filters {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 16px;
    padding: 20px;
  }
}

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

@media (min-width: 768px) {
  .filter-group {
    min-width: 150px;
  }
}

.filter-group label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
}

.filter-group select,
.filter-group input {
  padding: 10px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 13px;
  width: 100%;
}

.browse-search {
  flex: 1;
  position: relative;
}

@media (min-width: 768px) {
  .browse-search {
    min-width: 200px;
  }
}

.browse-search input {
  padding-left: 40px;
}

.browse-search i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  margin-top: 10px;
}

@media (min-width: 768px) {
  .browse-search i {
    margin-top: 0;
    top: calc(50% + 10px);
  }
}

.browse-results-info {
  margin-bottom: 16px;
  font-size: 13px;
  color: var(--text-secondary);
}

/* ==========================================
   AUTH PAGES
   ========================================== */
.auth-page {
  min-height: calc(100vh - var(--header-height));
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 30px 16px;
}

.auth-card {
  width: 100%;
  max-width: 400px;
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: 28px 24px;
  box-shadow: var(--shadow-lg);
}

@media (min-width: 768px) {
  .auth-card {
    padding: 40px;
  }
}

.auth-card-header {
  text-align: center;
  margin-bottom: 28px;
}

.auth-card-icon {
  width: 56px;
  height: 56px;
  background: var(--accent-gradient);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: white;
  margin: 0 auto 14px;
}

.auth-card-title {
  font-size: 22px;
  font-weight: 800;
  margin-bottom: 6px;
}

.auth-card-subtitle {
  font-size: 13px;
  color: var(--text-muted);
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

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

.form-group label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
}

.form-group input {
  width: 100%;
  padding: 12px 14px;
  background: var(--bg-input);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  transition: border-color var(--transition-fast);
}

.form-group input:focus {
  border-color: var(--accent-primary);
}

.form-group-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.form-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
}

.form-checkbox input {
  width: 16px;
  height: 16px;
  accent-color: var(--accent-primary);
}

.form-link {
  font-size: 13px;
  color: var(--accent-primary);
  font-weight: 500;
}

.auth-form .btn {
  width: 100%;
  padding: 14px;
  margin-top: 8px;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 20px 0;
  color: var(--text-muted);
  font-size: 12px;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-color);
}

.auth-social {
  display: flex;
  gap: 10px;
}

.auth-social-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 13px;
  font-weight: 500;
  transition: background var(--transition-fast);
}

.auth-social-btn:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.auth-footer {
  text-align: center;
  margin-top: 20px;
  font-size: 13px;
  color: var(--text-muted);
}

.auth-footer a {
  color: var(--accent-primary);
  font-weight: 600;
}

/* ==========================================
   PROFILE PAGE
   ========================================== */
.profile-page {
  padding: 20px 0 40px;
}

@media (min-width: 768px) {
  .profile-page {
    padding: 30px 0 40px;
  }
}

.profile-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 16px;
  padding: 24px;
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  margin-bottom: 24px;
}

@media (min-width: 768px) {
  .profile-header {
    flex-direction: row;
    text-align: left;
    gap: 24px;
    padding: 30px;
  }
}

.profile-avatar {
  position: relative;
  flex-shrink: 0;
}

.profile-avatar img {
  width: 100px;
  height: 100px;
  border-radius: var(--radius-full);
  object-fit: cover;
  border: 4px solid var(--accent-primary);
}

@media (min-width: 768px) {
  .profile-avatar img {
    width: 120px;
    height: 120px;
  }
}

.profile-avatar-edit {
  position: absolute;
  bottom: 2px;
  right: 2px;
  width: 30px;
  height: 30px;
  background: var(--accent-gradient);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 12px;
  cursor: pointer;
}

.profile-info {
  flex: 1;
}

.profile-name {
  font-size: 22px;
  font-weight: 800;
  margin-bottom: 4px;
}

@media (min-width: 768px) {
  .profile-name {
    font-size: 28px;
  }
}

.profile-email {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.profile-stats {
  display: flex;
  justify-content: center;
  gap: 28px;
}

@media (min-width: 768px) {
  .profile-stats {
    justify-content: flex-start;
    gap: 32px;
  }
}

.profile-stat {
  text-align: center;
}

.profile-stat-value {
  font-size: 22px;
  font-weight: 700;
  color: var(--accent-primary);
}

.profile-stat-label {
  font-size: 11px;
  color: var(--text-muted);
}

.profile-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 20px;
  background: var(--bg-card);
  padding: 6px;
  border-radius: var(--radius-lg);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.profile-tab {
  flex: 1;
  min-width: 100px;
  padding: 10px 16px;
  background: transparent;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.profile-tab:hover {
  color: var(--text-primary);
  background: var(--bg-tertiary);
}

.profile-tab.active {
  background: var(--accent-gradient);
  color: white;
}

.profile-content {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: 20px;
  min-height: 300px;
}

@media (min-width: 768px) {
  .profile-content {
    padding: 24px;
  }
}

/* ==========================================
   ADMIN PAGE
   ========================================== */
.admin-page {
  padding: 20px 0 40px;
}

@media (min-width: 768px) {
  .admin-page {
    padding: 30px 0 40px;
  }
}

.admin-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 16px;
}

.admin-title {
  font-size: 22px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 10px;
}

@media (min-width: 768px) {
  .admin-title {
    font-size: 28px;
  }
}

.admin-title i {
  color: var(--accent-primary);
}

.admin-layout {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

@media (min-width: 992px) {
  .admin-layout {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 24px;
  }
}

.admin-sidebar {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: 12px;
  height: fit-content;
}

@media (min-width: 992px) {
  .admin-sidebar {
    position: sticky;
    top: calc(var(--header-height) + 20px);
    padding: 16px;
  }
}

.admin-nav {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 4px;
}

@media (min-width: 992px) {
  .admin-nav {
    flex-direction: column;
    overflow-x: visible;
    padding-bottom: 0;
  }
}

.admin-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.admin-nav-item:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.admin-nav-item.active {
  background: var(--accent-gradient);
  color: white;
}

.admin-nav-item i {
  width: 18px;
  text-align: center;
  font-size: 15px;
}

.admin-content {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: 16px;
  min-height: 400px;
}

@media (min-width: 768px) {
  .admin-content {
    padding: 24px;
  }
}

/* Admin Stats */
.admin-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

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

.admin-stat-card {
  background: var(--bg-tertiary);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}

@media (min-width: 768px) {
  .admin-stat-card {
    padding: 20px;
    gap: 16px;
  }
}

.admin-stat-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}

@media (min-width: 768px) {
  .admin-stat-icon {
    width: 56px;
    height: 56px;
    font-size: 22px;
  }
}

.admin-stat-icon.primary {
  background: rgba(255, 107, 53, 0.2);
  color: var(--accent-primary);
}

.admin-stat-icon.success {
  background: rgba(34, 197, 94, 0.2);
  color: var(--success);
}

.admin-stat-icon.info {
  background: rgba(59, 130, 246, 0.2);
  color: var(--info);
}

.admin-stat-icon.warning {
  background: rgba(245, 158, 11, 0.2);
  color: var(--warning);
}

.admin-stat-info h3 {
  font-size: 20px;
  font-weight: 800;
  margin-bottom: 2px;
}

@media (min-width: 768px) {
  .admin-stat-info h3 {
    font-size: 26px;
  }
}

.admin-stat-info p {
  font-size: 11px;
  color: var(--text-muted);
}

@media (min-width: 768px) {
  .admin-stat-info p {
    font-size: 13px;
  }
}

/* Admin Table */
.admin-table-header {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 16px;
}

@media (min-width: 768px) {
  .admin-table-header {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
  }
}

.admin-table-title {
  font-size: 16px;
  font-weight: 700;
}

@media (min-width: 768px) {
  .admin-table-title {
    font-size: 18px;
  }
}

.admin-table-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-search {
  position: relative;
  flex: 1;
  min-width: 200px;
}

.admin-search input {
  width: 100%;
  padding: 10px 14px 10px 38px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 13px;
}

.admin-search i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 14px;
}

/* Data Table */
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.data-table th,
.data-table td {
  padding: 12px 10px;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
}

@media (min-width: 768px) {
  .data-table th,
  .data-table td {
    padding: 14px 16px;
  }
}

.data-table th {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  color: var(--text-muted);
  background: var(--bg-tertiary);
  white-space: nowrap;
}

.data-table th:first-child {
  border-radius: var(--radius-md) 0 0 var(--radius-md);
}

.data-table th:last-child {
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

.data-table tbody tr {
  transition: background var(--transition-fast);
}

.data-table tbody tr:hover {
  background: var(--bg-tertiary);
}

.data-table .cover-cell {
  width: 50px;
}

@media (min-width: 768px) {
  .data-table .cover-cell {
    width: 60px;
  }
}

.data-table .cover-cell img {
  width: 40px;
  height: 54px;
  object-fit: cover;
  border-radius: var(--radius-sm);
}

@media (min-width: 768px) {
  .data-table .cover-cell img {
    width: 45px;
    height: 60px;
  }
}

/* Responsive table wrapper */
.table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 0 -16px;
  padding: 0 16px;
}

@media (min-width: 768px) {
  .table-responsive {
    margin: 0;
    padding: 0;
  }
}

/* Status Badge */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
}

.status-badge::before {
  content: '';
  width: 5px;
  height: 5px;
  border-radius: var(--radius-full);
}

.status-badge.ongoing {
  background: rgba(59, 130, 246, 0.15);
  color: var(--info);
}

.status-badge.ongoing::before {
  background: var(--info);
}

.status-badge.completed {
  background: rgba(34, 197, 94, 0.15);
  color: var(--success);
}

.status-badge.completed::before {
  background: var(--success);
}

.status-badge.hiatus {
  background: rgba(245, 158, 11, 0.15);
  color: var(--warning);
}

.status-badge.hiatus::before {
  background: var(--warning);
}

/* Action Buttons */
.action-btns {
  display: flex;
  gap: 6px;
}

.action-btn {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  transition: all var(--transition-fast);
}

@media (min-width: 768px) {
  .action-btn {
    width: 34px;
    height: 34px;
    font-size: 14px;
  }
}

.action-btn.view {
  background: rgba(59, 130, 246, 0.15);
  color: var(--info);
}

.action-btn.edit {
  background: rgba(245, 158, 11, 0.15);
  color: var(--warning);
}

.action-btn.delete {
  background: rgba(239, 68, 68, 0.15);
  color: var(--error);
}

.action-btn:hover {
  transform: scale(1.1);
}

/* Pagination */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 20px;
  flex-wrap: wrap;
}

.pagination-btn {
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.pagination-btn:hover:not(:disabled) {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.pagination-btn.active {
  background: var(--accent-gradient);
  color: white;
}

.pagination-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ==========================================
   MODAL
   ========================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(4px);
  z-index: var(--z-modal-backdrop);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-fast);
}

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

.modal {
  width: 100%;
  max-width: 500px;
  max-height: calc(100vh - 32px);
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  overflow: hidden;
  transform: scale(0.95) translateY(20px);
  transition: transform var(--transition-fast);
  display: flex;
  flex-direction: column;
}

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

.modal.large {
  max-width: 700px;
}

.modal.small {
  max-width: 380px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
  flex-shrink: 0;
}

.modal-title {
  font-size: 16px;
  font-weight: 700;
}

@media (min-width: 768px) {
  .modal-title {
    font-size: 18px;
  }
}

.modal-close {
  width: 34px;
  height: 34px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  transition: all var(--transition-fast);
}

.modal-close:hover {
  background: var(--error);
  color: white;
}

.modal-body {
  padding: 20px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  flex: 1;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 16px 20px;
  border-top: 1px solid var(--border-color);
  flex-shrink: 0;
}

/* Form elements inside modal */
.modal-body .form-group {
  margin-bottom: 16px;
}

.modal-body .form-group:last-child {
  margin-bottom: 0;
}

.modal-body textarea {
  width: 100%;
  min-height: 100px;
  padding: 12px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 14px;
  resize: vertical;
}

.modal-body textarea:focus {
  border-color: var(--accent-primary);
}

.modal-body select {
  width: 100%;
  padding: 10px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 14px;
}

/* ==========================================
   IMAGE UPLOAD
   ========================================== */
.image-upload {
  border: 2px dashed var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.image-upload:hover {
  border-color: var(--accent-primary);
  background: rgba(255, 107, 53, 0.05);
}

.image-upload-icon {
  font-size: 36px;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.image-upload-text {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.image-upload-hint {
  font-size: 11px;
  color: var(--text-muted);
}

.image-upload.has-image {
  padding: 12px;
  border-style: solid;
}

.image-upload.has-image .preview {
  max-height: 180px;
  border-radius: var(--radius-md);
}

/* Multi Image Upload */
.multi-upload-area {
  border: 2px dashed var(--border-color);
  border-radius: var(--radius-lg);
  padding: 20px;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  margin-bottom: 14px;
}

.multi-upload-area:hover {
  border-color: var(--accent-primary);
  background: rgba(255, 107, 53, 0.05);
}

.pages-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  gap: 10px;
}

@media (min-width: 768px) {
  .pages-grid {
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  }
}

.page-item {
  position: relative;
  aspect-ratio: 3/4;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--bg-tertiary);
}

.page-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.page-item-number {
  position: absolute;
  bottom: 4px;
  left: 4px;
  padding: 3px 7px;
  background: rgba(0, 0, 0, 0.8);
  border-radius: var(--radius-sm);
  font-size: 10px;
  font-weight: 600;
}

.page-item-remove {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 22px;
  height: 22px;
  background: var(--error);
  border-radius: var(--radius-full);
  color: white;
  font-size: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition-fast);
  cursor: pointer;
}

.page-item:hover .page-item-remove {
  opacity: 1;
}

/* Genre Selector */
.genre-selector {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 14px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-lg);
  max-height: 180px;
  overflow-y: auto;
}

.genre-chip {
  padding: 7px 12px;
  background: var(--bg-input);
  border: 2px solid transparent;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.genre-chip:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
}

.genre-chip.selected {
  background: rgba(255, 107, 53, 0.15);
  border-color: var(--accent-primary);
  color: var(--accent-primary);
}

/* ==========================================
   TOAST NOTIFICATIONS
   ========================================== */
#toast-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  left: 20px;
  z-index: var(--z-toast);
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  pointer-events: none;
}

@media (min-width: 768px) {
  #toast-container {
    left: auto;
    width: 360px;
  }
}

.toast {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  border-left: 4px solid var(--info);
  transform: translateX(120%);
  transition: transform var(--transition-normal);
  width: 100%;
  max-width: 360px;
  pointer-events: auto;
}

.toast.show {
  transform: translateX(0);
}

.toast.success {
  border-left-color: var(--success);
}

.toast.error {
  border-left-color: var(--error);
}

.toast.warning {
  border-left-color: var(--warning);
}

.toast-icon {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  flex-shrink: 0;
}

.toast.success .toast-icon {
  background: rgba(34, 197, 94, 0.15);
  color: var(--success);
}

.toast.error .toast-icon {
  background: rgba(239, 68, 68, 0.15);
  color: var(--error);
}

.toast.warning .toast-icon {
  background: rgba(245, 158, 11, 0.15);
  color: var(--warning);
}

.toast.info .toast-icon {
  background: rgba(59, 130, 246, 0.15);
  color: var(--info);
}

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

.toast-message {
  font-size: 13px;
  color: var(--text-primary);
  word-wrap: break-word;
}

.toast-close {
  width: 26px;
  height: 26px;
  background: var(--bg-input);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  cursor: pointer;
  flex-shrink: 0;
  transition: all var(--transition-fast);
}

.toast-close:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

/* ==========================================
   FOOTER
   ========================================== */
.footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 40px 0 24px;
  margin-top: 40px;
}

@media (min-width: 768px) {
  .footer {
    padding: 60px 0 30px;
    margin-top: 60px;
  }
}

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

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

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

.footer-brand {
  max-width: 300px;
}

@media (max-width: 767px) {
  .footer-brand {
    text-align: center;
    max-width: 100%;
  }
  
  .footer-brand .logo {
    justify-content: center;
  }
}

.footer-brand .logo {
  margin-bottom: 14px;
}

.footer-brand .logo-text {
  display: block;
}

.footer-brand p {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 16px;
}

.footer-social {
  display: flex;
  gap: 10px;
}

@media (max-width: 767px) {
  .footer-social {
    justify-content: center;
  }
}

.footer-social a {
  width: 36px;
  height: 36px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 16px;
  transition: all var(--transition-fast);
}

.footer-social a:hover {
  background: var(--accent-primary);
  color: white;
}

.footer-column h4 {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 16px;
}

@media (max-width: 767px) {
  .footer-column {
    text-align: center;
  }
}

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

@media (max-width: 767px) {
  .footer-links {
    align-items: center;
  }
}

.footer-links a {
  font-size: 13px;
  color: var(--text-muted);
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--accent-primary);
}

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
  text-align: center;
}

.footer-copyright {
  font-size: 12px;
  color: var(--text-muted);
}

/* ==========================================
   BACK TO TOP BUTTON
   ========================================== */
.back-to-top {
  position: fixed;
  bottom: 80px;
  right: 16px;
  width: 44px;
  height: 44px;
  background: var(--accent-gradient);
  border-radius: var(--radius-full);
  color: white;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: var(--z-sticky);
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-md);
}

@media (min-width: 768px) {
  .back-to-top {
    bottom: 30px;
    right: 30px;
    width: 48px;
    height: 48px;
  }
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  transform: translateY(-4px);
}

/* ==========================================
   COMMENTS SECTION
   ========================================== */
.comments-section {
  margin-top: 24px;
}

.comments-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.comments-title {
  font-size: 16px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.comments-title i {
  color: var(--accent-primary);
}

.comments-count {
  font-size: 13px;
  font-weight: 400;
  color: var(--text-muted);
}

.comment-form {
  margin-bottom: 24px;
}

.comment-form textarea {
  width: 100%;
  min-height: 90px;
  padding: 14px;
  background: var(--bg-input);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-lg);
  color: var(--text-primary);
  font-size: 14px;
  resize: vertical;
  margin-bottom: 10px;
  transition: border-color var(--transition-fast);
}

.comment-form textarea:focus {
  border-color: var(--accent-primary);
}

.comment-form textarea::placeholder {
  color: var(--text-muted);
}

.comment-form-actions {
  display: flex;
  justify-content: flex-end;
}

.comments-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.comment {
  display: flex;
  gap: 12px;
  padding: 16px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-lg);
}

.comment-avatar {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  overflow: hidden;
}

@media (min-width: 768px) {
  .comment-avatar {
    width: 48px;
    height: 48px;
  }
}

.comment-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

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

.comment-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}

.comment-author {
  font-size: 13px;
  font-weight: 600;
}

.comment-date {
  font-size: 11px;
  color: var(--text-muted);
}

.comment-text {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
  word-wrap: break-word;
}

/* ==========================================
   UTILITY CLASSES
   ========================================== */
.text-primary { color: var(--text-primary) !important; }
.text-secondary { color: var(--text-secondary) !important; }
.text-muted { color: var(--text-muted) !important; }
.text-accent { color: var(--accent-primary) !important; }
.text-success { color: var(--success) !important; }
.text-warning { color: var(--warning) !important; }
.text-error { color: var(--error) !important; }

.text-center { text-align: center !important; }
.text-left { text-align: left !important; }
.text-right { text-align: right !important; }

.font-bold { font-weight: 700 !important; }
.font-semibold { font-weight: 600 !important; }
.font-medium { font-weight: 500 !important; }

.hidden { display: none !important; }

.mt-1 { margin-top: 4px !important; }
.mt-2 { margin-top: 8px !important; }
.mt-3 { margin-top: 12px !important; }
.mt-4 { margin-top: 16px !important; }
.mt-5 { margin-top: 20px !important; }

.mb-1 { margin-bottom: 4px !important; }
.mb-2 { margin-bottom: 8px !important; }
.mb-3 { margin-bottom: 12px !important; }
.mb-4 { margin-bottom: 16px !important; }
.mb-5 { margin-bottom: 20px !important; }

/* Selection */
::selection {
  background: var(--accent-primary);
  color: white;
}

/* Focus Visible */
:focus-visible {
  outline: 2px solid var(--accent-primary);
  outline-offset: 2px;
}

/* Hide focus for mouse users */
:focus:not(:focus-visible) {
  outline: none;
}

/* Touch-friendly tap areas */
@media (pointer: coarse) {
  .btn,
  .nav-link,
  .genre-tag,
  .manga-card,
  .update-card-chapter,
  .chapter-item,
  .action-btn {
    min-height: 44px;
  }
  
  .reader-nav-btn,
  .reader-settings-btn,
  .reader-back-btn {
    min-width: 44px;
    min-height: 44px;
  }
}

/* Disable hover effects on touch devices */
@media (hover: none) {
  .manga-card:hover {
    transform: none;
    box-shadow: none;
  }
  
  .manga-card:hover .manga-card-poster img {
    transform: none;
  }
  
  .manga-card:hover .manga-card-play {
    opacity: 0;
  }
  
  .manga-card:hover .manga-card-overlay {
    opacity: 0;
  }
  
  .btn-primary:hover {
    transform: none;
  }
  
  .chapter-item:hover {
    transform: none;
  }
}

/* Safe area insets for notched devices */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
  .reader-footer {
    padding-bottom: calc(12px + env(safe-area-inset-bottom));
    height: calc(60px + env(safe-area-inset-bottom));
  }
  
  #toast-container {
    bottom: calc(20px + env(safe-area-inset-bottom));
  }
  
  .back-to-top {
    bottom: calc(80px + env(safe-area-inset-bottom));
  }
  
  @media (min-width: 768px) {
    .back-to-top {
      bottom: calc(30px + env(safe-area-inset-bottom));
    }
  }
}

/* Print styles */
@media print {
  .header,
  .footer,
  .reader-header,
  .reader-footer,
  .back-to-top,
  #toast-container,
  .modal-overlay {
    display: none !important;
  }
  
  #main-content {
    padding-top: 0;
  }
  
  body {
    background: white;
    color: black;
  }
}

/* ==========================================
   ENHANCED READER STYLES
   Add these to your style.css
   ========================================== */

/* Reader Settings Panel - Enhanced */
.reader-settings-panel {
  position: fixed;
  top: 60px;
  right: -400px;
  width: 400px;
  max-width: 90vw;
  height: calc(100vh - 60px);
  background: var(--bg-card);
  border-left: 1px solid var(--border-color);
  z-index: var(--z-modal);
  transition: right var(--transition-normal);
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
}

.reader-settings-panel.active {
  right: 0;
}

.settings-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  background: var(--bg-card);
  z-index: 1;
}

.settings-panel-header h3 {
  font-size: 18px;
  font-weight: 700;
  margin: 0;
}

.settings-close-btn {
  width: 36px;
  height: 36px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  transition: all var(--transition-fast);
}

.settings-close-btn:hover {
  background: var(--error);
  color: white;
}

/* Settings Tabs */
.settings-tabs {
  display: flex;
  gap: 0;
  padding: 0;
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-tertiary);
}

.settings-tab {
  flex: 1;
  padding: 14px 16px;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all var(--transition-fast);
  border-bottom: 2px solid transparent;
}

.settings-tab:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.settings-tab.active {
  color: var(--accent-primary);
  background: var(--bg-card);
  border-bottom-color: var(--accent-primary);
}

.settings-tab i {
  font-size: 16px;
}

/* Settings Tab Content */
.settings-tab-content {
  display: none;
  padding: 20px;
}

.settings-tab-content.active {
  display: block;
}

/* Settings Section */
.settings-section {
  margin-bottom: 24px;
}

.settings-section:last-child {
  margin-bottom: 0;
}

.settings-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Settings Options */
.settings-options {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.settings-options-vertical {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.settings-option {
  flex: 1;
  min-width: calc(33.333% - 7px);
  padding: 14px 16px;
  background: var(--bg-input);
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.settings-option i {
  font-size: 20px;
}

.settings-option:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.settings-option.active {
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  background: rgba(255, 107, 53, 0.1);
}

/* Small Settings Options (for grid) */
.settings-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
}

.settings-option-sm {
  padding: 12px;
  background: var(--bg-input);
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-size: 16px;
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
}

.settings-option-sm:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.settings-option-sm.active {
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  background: rgba(255, 107, 53, 0.1);
}

/* Settings Toggle */
.settings-toggle {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background var(--transition-fast);
}

.settings-toggle:hover {
  background: var(--bg-tertiary);
}

.settings-toggle input[type="checkbox"],
.settings-toggle input[type="radio"] {
  width: 20px;
  height: 20px;
  accent-color: var(--accent-primary);
  cursor: pointer;
}

.settings-toggle span {
  flex: 1;
  font-size: 13px;
  color: var(--text-secondary);
}

/* Shortcuts List */
.shortcuts-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.shortcut-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
}

.shortcut-item kbd {
  padding: 6px 12px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  font-family: var(--font-family);
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-primary);
  min-width: 40px;
  text-align: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.shortcut-item span {
  flex: 1;
  font-size: 13px;
  color: var(--text-secondary);
}

/* Reader Content Display Modes */
.reader-content.single-page {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: calc(100vh - 120px);
}

.reader-content.double-page .reader-images {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  min-height: calc(100vh - 120px);
}

.reader-content.longstrip .reader-images {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Image Sizing Classes */
.reader-image.sizing-width {
  max-width: 100%;
  width: auto;
  height: auto;
}

.reader-image.sizing-height {
  max-height: 100vh;
  width: auto;
  height: auto;
}

.reader-image.sizing-stretch {
  max-width: 100%;
  width: 100%;
  height: auto;
}

.reader-image.sizing-limit-width {
  max-width: 900px;
  width: 100%;
  height: auto;
}

.reader-image.sizing-limit-height {
  max-height: 90vh;
  width: auto;
  height: auto;
}

/* Progress Bar Positions */
.reader-progress-bar {
  position: fixed;
  z-index: 1000;
  background: rgba(0, 0, 0, 0.3);
}

.reader-progress-fill {
  background: var(--accent-gradient);
  transition: all 0.3s ease;
}

/* Reader Tips */
.reader-tips {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 500;
  pointer-events: none;
  display: none;
}

.reader-header.hidden ~ * .reader-tips {
  display: block;
}

.reader-tip {
  padding: 16px 24px;
  background: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-lg);
  color: white;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  animation: fadeInOut 3s ease-in-out infinite;
}

.reader-tip i {
  font-size: 20px;
  color: var(--accent-primary);
}

.reader-tip kbd {
  padding: 4px 8px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-sm);
  font-family: monospace;
  font-size: 12px;
  color: var(--accent-primary);
}

@keyframes fadeInOut {
  0%, 100% { opacity: 0.7; }
  50% { opacity: 1; }
}

/* RTL Support */
.reader-content[dir="rtl"] .double-page .reader-images {
  flex-direction: row-reverse;
}

/* Touch Indicators (Mobile) */
@media (hover: none) and (pointer: coarse) {
  .reader-content::before,
  .reader-content::after {
    content: '';
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(255, 107, 53, 0.1);
    border: 2px solid var(--accent-primary);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    z-index: 100;
  }
  
  .reader-content::before {
    left: 20px;
    content: '←';
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-primary);
    font-size: 24px;
  }
  
  .reader-content::after {
    right: 20px;
    content: '→';
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-primary);
    font-size: 24px;
  }
  
  .reader-content:active::before,
  .reader-content:active::after {
    opacity: 1;
  }
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .reader-settings-panel {
    width: 100%;
    max-width: 100%;
    right: -100%;
    top: 50px;
    height: calc(100vh - 50px);
  }
  
  .settings-panel-header {
    padding: 16px;
  }
  
  .settings-tabs {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  .settings-tab {
    flex-shrink: 0;
    padding: 12px 14px;
    font-size: 12px;
  }
  
  .settings-tab span {
    display: none;
  }
  
  .settings-tab i {
    font-size: 18px;
  }
  
  .settings-tab-content {
    padding: 16px;
  }
  
  .settings-section {
    margin-bottom: 20px;
  }
  
  .settings-option {
    min-width: calc(50% - 5px);
    padding: 12px 14px;
  }
  
  .settings-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .shortcut-item {
    font-size: 12px;
    padding: 10px 12px;
  }
  
  .shortcut-item kbd {
    min-width: 35px;
    padding: 4px 8px;
    font-size: 11px;
  }
  
  .reader-tip {
    padding: 12px 16px;
    font-size: 12px;
  }
  
  /* Hide double page on mobile */
  .settings-option[onclick*="double"] {
    display: none;
  }
}

@media (max-width: 480px) {
  .settings-option {
    min-width: 100%;
  }
  
  .settings-grid {
    grid-template-columns: repeat(5, 1fr);
    gap: 6px;
  }
  
  .settings-option-sm {
    padding: 10px;
    font-size: 14px;
  }
}

/* Landscape Mobile */
@media (max-height: 500px) and (orientation: landscape) {
  .reader-settings-panel {
    height: 100vh;
    top: 0;
  }
  
  .settings-panel-header {
    padding: 12px 16px;
  }
  
  .settings-tab {
    padding: 10px 12px;
  }
  
  .settings-tab-content {
    padding: 12px 16px;
  }
  
  .settings-section {
    margin-bottom: 16px;
  }
}

/* Print Styles */
@media print {
  .reader-header,
  .reader-footer,
  .reader-settings-panel,
  .reader-progress-bar,
  .reader-tips {
    display: none !important;
  }
  
  .reader-content {
    padding: 0 !important;
  }
  
  .reader-image {
    max-width: 100%;
    page-break-inside: avoid;
  }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
  .reader-settings-panel,
  .reader-tip,
  .settings-option,
  .settings-tab {
    transition: none !important;
    animation: none !important;
  }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
  .settings-option,
  .settings-toggle,
  .shortcut-item {
    border: 1px solid currentColor;
  }
  
  .reader-progress-fill {
    background: currentColor;
  }
}

/* ==========================================
   STATIC PAGES (About, Contact, DMCA, etc.)
   ========================================== */
.static-page {
  padding: 30px 0 60px;
}

@media (min-width: 768px) {
  .static-page {
    padding: 40px 0 80px;
  }
}

/* Static Hero */
.static-hero {
  text-align: center;
  padding: 40px 20px;
  margin-bottom: 30px;
}

@media (min-width: 768px) {
  .static-hero {
    padding: 60px 20px;
    margin-bottom: 40px;
  }
}

.static-hero-icon {
  width: 80px;
  height: 80px;
  background: var(--accent-gradient);
  border-radius: var(--radius-xl);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  color: white;
  margin: 0 auto 20px;
  box-shadow: 0 10px 40px rgba(255, 107, 53, 0.3);
}

@media (min-width: 768px) {
  .static-hero-icon {
    width: 100px;
    height: 100px;
    font-size: 44px;
  }
}

.static-hero-icon.warning {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  box-shadow: 0 10px 40px rgba(245, 158, 11, 0.3);
}

.static-hero-title {
  font-size: 28px;
  font-weight: 800;
  margin-bottom: 10px;
}

@media (min-width: 768px) {
  .static-hero-title {
    font-size: 40px;
  }
}

.static-hero-subtitle {
  font-size: 16px;
  color: var(--text-secondary);
}

@media (min-width: 768px) {
  .static-hero-subtitle {
    font-size: 18px;
  }
}

/* Static Content */
.static-content {
  max-width: 900px;
  margin: 0 auto;
}

.static-section {
  margin-bottom: 40px;
}

.static-section h2 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-primary);
}

@media (min-width: 768px) {
  .static-section h2 {
    font-size: 24px;
  }
}

.static-section h2 i {
  color: var(--accent-primary);
}

.static-section h3 {
  font-size: 16px;
  font-weight: 600;
  margin: 20px 0 12px;
  color: var(--text-primary);
}

.static-section p {
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.static-section p:last-child {
  margin-bottom: 0;
}

.static-section a {
  color: var(--accent-primary);
}

.static-section a:hover {
  text-decoration: underline;
}

.static-section.centered {
  text-align: center;
}

/* Features Grid */
.features-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-top: 20px;
}

@media (min-width: 600px) {
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

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

.feature-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-align: center;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

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

.feature-icon {
  width: 56px;
  height: 56px;
  background: rgba(255, 107, 53, 0.15);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: var(--accent-primary);
  margin: 0 auto 16px;
}

.feature-card h3 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
}

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-top: 20px;
}

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

.stat-item {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-align: center;
}

.stat-number {
  font-size: 32px;
  font-weight: 800;
  color: var(--accent-primary);
  margin-bottom: 4px;
}

@media (min-width: 768px) {
  .stat-number {
    font-size: 40px;
  }
}

.stat-label {
  font-size: 13px;
  color: var(--text-muted);
}

/* Team Grid */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.team-member {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-align: center;
}

.team-avatar {
  width: 70px;
  height: 70px;
  background: var(--accent-gradient);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: white;
  margin: 0 auto 16px;
}

.team-member h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 4px;
}

.team-member p {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
}

/* Contact Page */
.contact-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
}

@media (min-width: 992px) {
  .contact-layout {
    grid-template-columns: 1.2fr 1fr;
    gap: 40px;
  }
}

.contact-form-section,
.contact-info-section {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: 24px;
}

@media (min-width: 768px) {
  .contact-form-section,
  .contact-info-section {
    padding: 32px;
  }
}

.contact-form-section h2,
.contact-info-section h2 {
  font-size: 20px;
  margin-bottom: 8px;
}

.section-desc {
  color: var(--text-muted);
  margin-bottom: 24px;
  font-size: 14px;
}

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

@media (min-width: 600px) {
  .contact-form .form-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

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

.contact-form textarea {
  width: 100%;
  min-height: 120px;
  padding: 12px 14px;
  background: var(--bg-input);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 14px;
  resize: vertical;
}

.contact-form textarea:focus {
  border-color: var(--accent-primary);
}

.contact-form select {
  width: 100%;
  padding: 12px 14px;
  background: var(--bg-input);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 14px;
}

/* Contact Info Cards */
.contact-info-cards {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 24px;
}

.contact-info-card {
  display: flex;
  gap: 16px;
  padding: 16px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-lg);
}

.contact-info-icon {
  width: 44px;
  height: 44px;
  background: rgba(255, 107, 53, 0.15);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: var(--accent-primary);
  flex-shrink: 0;
}

.contact-info-content h4 {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 4px;
}

.contact-info-content p {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.contact-info-content a {
  font-size: 13px;
  color: var(--accent-primary);
  font-weight: 500;
}

.response-time {
  display: flex;
  gap: 16px;
  padding: 16px;
  background: rgba(59, 130, 246, 0.1);
  border-radius: var(--radius-lg);
  margin-bottom: 24px;
}

.response-time i {
  color: var(--info);
  font-size: 20px;
  margin-top: 2px;
}

.response-time h4 {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 4px;
}

.response-time p {
  font-size: 13px;
  color: var(--text-secondary);
  margin: 0;
}

.faq-cta {
  padding: 20px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-lg);
  text-align: center;
}

.faq-cta h4 {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 6px;
}

.faq-cta p {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

/* Legal Content */
.legal-content {
  max-width: 800px;
}

.legal-notice {
  display: flex;
  gap: 16px;
  padding: 16px 20px;
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: var(--radius-lg);
  margin-bottom: 30px;
}

.legal-notice i {
  color: var(--warning);
  font-size: 20px;
  margin-top: 2px;
}

.legal-notice.info {
  background: rgba(59, 130, 246, 0.1);
  border-color: rgba(59, 130, 246, 0.3);
}

.legal-notice.info i {
  color: var(--info);
}

.legal-notice strong {
  color: var(--text-primary);
}

.legal-list {
  list-style: none;
  padding: 0;
  margin: 16px 0;
}

.legal-list li {
  position: relative;
  padding-left: 24px;
  margin-bottom: 10px;
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

.legal-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 8px;
  width: 8px;
  height: 8px;
  background: var(--accent-primary);
  border-radius: 50%;
}

/* DMCA Requirements */
.dmca-requirements {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 24px 0;
}

.dmca-requirement {
  display: flex;
  gap: 16px;
  padding: 20px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
}

.requirement-number {
  width: 36px;
  height: 36px;
  background: var(--accent-gradient);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 700;
  color: white;
  flex-shrink: 0;
}

.requirement-content h4 {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 6px;
}

.requirement-content p {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
}

/* DMCA Contact Methods */
.dmca-contact-methods {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-top: 20px;
}

@media (min-width: 600px) {
  .dmca-contact-methods {
    grid-template-columns: repeat(2, 1fr);
  }
}

.dmca-contact-method {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 24px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
}

.method-icon {
  width: 56px;
  height: 56px;
  background: rgba(255, 107, 53, 0.15);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: var(--accent-primary);
  margin-bottom: 16px;
}

.method-content h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
}

.method-content a {
  color: var(--accent-primary);
  font-size: 14px;
}

.method-note {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 8px;
}

.dmca-footer {
  padding-top: 30px;
  border-top: 1px solid var(--border-color);
  text-align: center;
}

.dmca-footer p {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

/* FAQ Page */
.faq-search {
  position: relative;
  max-width: 500px;
  margin: 0 auto 30px;
}

.faq-search i {
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
}

.faq-search input {
  width: 100%;
  padding: 14px 20px 14px 50px;
  background: var(--bg-card);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-full);
  color: var(--text-primary);
  font-size: 15px;
}

.faq-search input:focus {
  border-color: var(--accent-primary);
}

.faq-container {
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.faq-category-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.faq-category-title i {
  color: var(--accent-primary);
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.faq-item {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  text-align: left;
  transition: background var(--transition-fast);
}

.faq-question:hover {
  background: var(--bg-card-hover);
}

.faq-question i {
  color: var(--text-muted);
  font-size: 14px;
  transition: transform var(--transition-fast);
  flex-shrink: 0;
}

.faq-item.open .faq-question {
  background: var(--bg-card-hover);
}

.faq-item.open .faq-question i {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--transition-normal);
}

.faq-item.open .faq-answer {
  max-height: 500px;
}

.faq-answer p {
  padding: 0 20px 18px;
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.7;
  margin: 0;
}

.faq-cta-section {
  text-align: center;
  padding: 40px 20px;
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  margin-top: 40px;
}

.faq-cta-section h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 8px;
}

.faq-cta-section p {
  color: var(--text-muted);
  margin-bottom: 20px;
}

/* Enhanced Chapter Upload Styles */
/* Add these styles to your public/css/style.css */

/* Multi Upload Area */
.multi-upload-area {
  border: 2px dashed var(--border-color);
  border-radius: var(--radius-lg);
  padding: 40px 20px;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  background: var(--bg-tertiary);
}

.multi-upload-area:hover {
  border-color: var(--accent-primary);
  background: rgba(255, 107, 53, 0.05);
}

.multi-upload-area i {
  display: block;
}

/* Pages Grid - Enhanced */
.pages-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
  margin: 16px 0;
}

/* Page Item - Enhanced with drag and drop */
.page-item {
  position: relative;
  aspect-ratio: 3/4;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--bg-tertiary);
  cursor: move;
  transition: all var(--transition-fast);
  border: 2px solid transparent;
}

.page-item:hover {
  border-color: var(--accent-primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.page-item.dragging {
  opacity: 0.5;
}

.page-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

.page-item-number {
  position: absolute;
  top: 4px;
  left: 4px;
  padding: 4px 8px;
  background: rgba(0, 0, 0, 0.8);
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 700;
  color: white;
  z-index: 2;
}

.page-item-remove {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 24px;
  height: 24px;
  background: var(--error);
  border-radius: var(--radius-full);
  color: white;
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition-fast);
  cursor: pointer;
  z-index: 2;
  border: none;
}

.page-item:hover .page-item-remove {
  opacity: 1;
}

.page-item-remove:hover {
  background: #dc2626;
  transform: scale(1.1);
}

/* Form Checkbox - Enhanced */
.form-checkbox {
  display: flex;
  align-items: start;
  gap: 10px;
  padding: 12px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background var(--transition-fast);
  border: 2px solid transparent;
}

.form-checkbox:hover {
  background: var(--bg-tertiary);
}

.form-checkbox input[type="checkbox"],
.form-checkbox input[type="radio"] {
  width: 18px;
  height: 18px;
  accent-color: var(--accent-primary);
  cursor: pointer;
  flex-shrink: 0;
  margin-top: 2px;
}

.form-checkbox input:checked + span {
  color: var(--text-primary);
}

/* Files Uploaded Section */
#files-uploaded-section {
  padding: 20px;
  background: var(--bg-input);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
}

#files-uploaded-section h4 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 12px;
}

/* Upload Info Banner */
.upload-info-banner {
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.3);
  border-radius: var(--radius-md);
  padding: 12px;
  margin-bottom: 16px;
}

.upload-info-banner i {
  color: var(--info);
  font-size: 16px;
}

/* Section Dividers */
.manga-detail-section {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 20px;
  border: 1px solid var(--border-color);
}

.manga-detail-section-title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-primary);
}

.manga-detail-section-title i {
  color: var(--accent-primary);
  font-size: 18px;
}

.manga-detail-section-title .count {
  font-size: 13px;
  font-weight: 400;
  color: var(--text-muted);
}

/* Small helper text */
small {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Button Groups */
.btn-group {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* Select Dropdowns */
select {
  width: 100%;
  padding: 10px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 13px;
  cursor: pointer;
  transition: border-color var(--transition-fast);
}

select:hover {
  border-color: var(--accent-primary);
}

select:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
}

/* Input Fields */
input[type="text"],
input[type="number"] {
  width: 100%;
  padding: 10px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 14px;
  transition: border-color var(--transition-fast);
}

input[type="text"]:focus,
input[type="number"]:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
}

/* Form Labels */
.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .pages-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }
  
  .manga-detail-section {
    padding: 16px;
  }
  
  .form-checkbox {
    padding: 10px;
  }
  
  #files-uploaded-section {
    padding: 16px;
  }
}

@media (max-width: 480px) {
  .pages-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .multi-upload-area {
    padding: 30px 15px;
  }
  
  .btn-group {
    flex-direction: column;
  }
  
  .btn-group .btn {
    width: 100%;
  }
}

/* Loading State for Pages */
.page-item.loading {
  background: var(--bg-input);
  display: flex;
  align-items: center;
  justify-content: center;
}

.page-item.loading::after {
  content: '';
  width: 24px;
  height: 24px;
  border: 3px solid var(--border-color);
  border-top-color: var(--accent-primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

/* Drag and Drop Visual Feedback */
.pages-grid.drag-over {
  background: rgba(255, 107, 53, 0.05);
  border: 2px dashed var(--accent-primary);
  border-radius: var(--radius-lg);
  padding: 8px;
}

/* Success/Error States */
.page-item.error {
  border-color: var(--error);
}

.page-item.error::before {
  content: '⚠';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 32px;
  color: var(--error);
  z-index: 3;
}

/* Modal enhancements for upload */
.modal.large .modal-body {
  max-height: calc(90vh - 120px);
}

/* File name overflow handling */
.page-item [title] {
  cursor: help;
}

/* Smooth transitions */
* {
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

/* Prevent text selection during drag */
.page-item.dragging * {
  user-select: none;
}

/* Grid column variations */
.pages-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.pages-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.pages-grid.cols-5 { grid-template-columns: repeat(5, 1fr); }
.pages-grid.cols-6 { grid-template-columns: repeat(6, 1fr); }
.pages-grid.cols-8 { grid-template-columns: repeat(8, 1fr); }

/* ==========================================
   NOTIFICATION SYSTEM
   ========================================== */
.notification-wrapper {
  position: relative;
}

.notification-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  background: var(--error);
  color: white;
  font-size: 10px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  border: 2px solid var(--bg-primary);
  pointer-events: none;
}

.notification-dropdown {
  position: absolute;
  top: calc(100% + 15px);
  right: -50px;
  width: 320px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  z-index: var(--z-dropdown);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.2s ease;
  overflow: hidden;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
}

@media (max-width: 480px) {
  .notification-dropdown {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    width: 100%;
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  }
}

.notification-dropdown.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.notification-header {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  font-size: 14px;
  background: var(--bg-tertiary);
}

.notification-list {
  overflow-y: auto;
}

.notification-item {
  display: flex;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-light);
  transition: background 0.2s;
  background: var(--bg-card);
}

.notification-item:hover {
  background: var(--bg-tertiary);
}

.notification-item.unread {
  background: rgba(255, 107, 53, 0.08);
  border-left: 3px solid var(--accent-primary);
}

.notification-icon {
  width: 40px;
  height: 56px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  flex-shrink: 0;
  background: var(--bg-input);
}

.notification-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.notification-content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.notification-text {
  font-size: 13px;
  color: var(--text-primary);
  line-height: 1.4;
  margin-bottom: 6px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.notification-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.notification-time {
  font-size: 11px;
  color: var(--text-muted);
}

.btn-read-notify {
  background: var(--accent-gradient);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  padding: 4px 12px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.btn-read-notify:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(255, 107, 53, 0.4);
}

/* ==========================================
   COIN SYSTEM & LOCKED CHAPTERS
   ========================================== */

/* Coin Icon & Text */
.coin-display {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-weight: 600;
  color: #fbbf24; /* Gold color */
}

.coin-icon {
  width: 18px;
  height: 18px;
  background: radial-gradient(circle at 30% 30%, #ffd700, #b8860b);
  border-radius: 50%;
  border: 1px solid #d4af37;
  box-shadow: 0 2px 4px rgba(0,0,0,0.3);
  display: inline-block;
  position: relative;
}

.coin-icon::after {
  content: '$';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 11px;
  color: #7c5e10;
  font-weight: 800;
}

/* Locked Chapter Item */
.chapter-item.locked {
  opacity: 0.8;
  background: rgba(255, 255, 255, 0.02);
  border: 1px dashed var(--border-color);
  cursor: pointer;
}

.chapter-item.locked:hover {
  background: rgba(251, 191, 36, 0.05); /* Slight gold tint */
  border-color: #fbbf24;
}

.chapter-item.locked .chapter-number {
  color: var(--text-muted);
}

.chapter-lock-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
}

.btn-unlock {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: white;
  border-radius: var(--radius-full);
  padding: 4px 12px;
  font-size: 11px;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
  transition: all var(--transition-fast);
}

.btn-unlock:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.5);
}

/* User Profile Wallet Section */
.wallet-card {
  background: linear-gradient(135deg, #1f1f1f 0%, #171717 100%);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

.wallet-info h4 {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.wallet-balance {
  font-size: 32px;
  font-weight: 800;
  color: white;
  display: flex;
  align-items: center;
  gap: 12px;
}

.wallet-balance .coin-icon {
  width: 32px;
  height: 32px;
}

.wallet-balance .coin-icon::after {
  font-size: 18px;
}

/* Transaction History Table adjustments */
.transaction-type {
  font-weight: 600;
  text-transform: uppercase;
  font-size: 11px;
  padding: 4px 8px;
  border-radius: 4px;
}

.transaction-type.deposit {
  background: rgba(34, 197, 94, 0.1);
  color: var(--success);
}

.transaction-type.purchase {
  background: rgba(239, 68, 68, 0.1);
  color: var(--error);
}

.transaction-type.admin_gift {
  background: rgba(245, 158, 11, 0.1);
  color: var(--warning);
}

/* Purchase Modal */
.purchase-modal-content {
  text-align: center;
  padding: 20px 0;
}

.purchase-icon-lg {
  font-size: 48px;
  color: #fbbf24;
  margin-bottom: 16px;
  animation: bounce 2s infinite;
}

.purchase-price {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 10px 0 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {transform: translateY(0);}
  40% {transform: translateY(-10px);}
  60% {transform: translateY(-5px);}
}
/* Pricing Page Styles */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 30px 20px;
  text-align: center;
  position: relative;
  transition: transform 0.2s, border-color 0.2s;
  display: flex;
  flex-direction: column;
}

.pricing-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent-primary);
}

.pricing-card.popular {
  border-color: #fbbf24;
  background: linear-gradient(to bottom, rgba(251, 191, 36, 0.05), var(--bg-card));
}

.popular-tag {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: #fbbf24;
  color: black;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 20px;
  text-transform: uppercase;
}

.pricing-label {
  font-size: 14px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 10px;
}

.pricing-coins {
  font-size: 28px;
  font-weight: 800;
  color: white;
  margin-bottom: 5px;
}

.pricing-coins i {
  color: #fbbf24;
}

.pricing-bonus {
  font-size: 12px;
  color: #4ade80; /* Green */
  font-weight: 600;
  margin-bottom: 15px;
}

.pricing-price {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-primary);
  margin-top: auto;
  margin-bottom: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--border-color);
}

.btn-block {
  width: 100%;
}
/* ==========================================
   AWESOME HOME ANIMATIONS
   ========================================== */

/* 1. Fire Flicker (For Trending/Featured) */
@keyframes fireFlicker {
  0% { transform: scale(1); filter: drop-shadow(0 0 2px #ff6b35); }
  25% { transform: scale(1.1) rotate(-2deg); filter: drop-shadow(0 0 5px #ff6b35); }
  50% { transform: scale(0.95) rotate(2deg); filter: drop-shadow(0 0 2px #f7931e); }
  75% { transform: scale(1.05) rotate(-1deg); filter: drop-shadow(0 0 4px #ff6b35); }
  100% { transform: scale(1); filter: drop-shadow(0 0 2px #ff6b35); }
}
.icon-animate-fire {
  display: inline-block;
  color: #ff6b35;
  animation: fireFlicker 2s infinite alternate;
}

/* 2. Clock Swing (For Latest Updates) */
@keyframes clockSwing {
  0% { transform: rotate(0deg); }
  25% { transform: rotate(15deg); }
  50% { transform: rotate(0deg); }
  75% { transform: rotate(-15deg); }
  100% { transform: rotate(0deg); }
}
.icon-animate-clock {
  display: inline-block;
  color: var(--info);
  transform-origin: top center;
  animation: clockSwing 2s infinite ease-in-out;
}

/* 3. Smooth Spin (For Ongoing) */
@keyframes smoothSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
.icon-animate-spin {
  display: inline-block;
  color: #3b82f6;
  animation: smoothSpin 3s linear infinite;
}

/* 4. Trophy Float (For Ranking) */
@keyframes floatTrophy {
  0% { transform: translateY(0px) rotate(0deg); filter: drop-shadow(0 5px 5px rgba(255, 215, 0, 0.2)); }
  50% { transform: translateY(-6px) rotate(5deg); filter: drop-shadow(0 15px 10px rgba(255, 215, 0, 0.4)); }
  100% { transform: translateY(0px) rotate(0deg); filter: drop-shadow(0 5px 5px rgba(255, 215, 0, 0.2)); }
}
.icon-animate-trophy {
  display: inline-block;
  color: #fbbf24; /* Gold */
  animation: floatTrophy 3s ease-in-out infinite;
}

/* 5. Bounce Check (For Completed) */
@keyframes bounceCheck {
  0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
  40% { transform: translateY(-6px); }
  60% { transform: translateY(-3px); }
}
.icon-animate-bounce {
  display: inline-block;
  color: #22c55e;
  animation: bounceCheck 2s infinite;
}

/* 6. Tag Shake (For Genres) */
@keyframes tagShake {
  0% { transform: rotate(0deg); }
  25% { transform: rotate(5deg); }
  75% { transform: rotate(-5deg); }
  100% { transform: rotate(0deg); }
}
.icon-animate-tag {
  display: inline-block;
  color: var(--accent-primary);
  animation: tagShake 3s ease-in-out infinite;
}

/* Section Title Enhancements */
.section-title {
  position: relative;
  overflow: hidden;
}
/* ==========================================
   ANNOUNCEMENT BAR
   ========================================== */
.announcement-section {
  margin-bottom: 24px;
}

.ann-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 16px;
  border: 1px solid var(--border-color);
  position: relative;
  overflow: hidden;
  transition: transform var(--transition-fast);
}

.ann-card:hover {
  border-color: var(--accent-primary);
  transform: translateY(-2px);
}

/* Animated Icon Container */
.ann-icon-wrapper {
  position: relative;
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* The Animated Pulse Circles */
.ann-icon-wrapper::before,
.ann-icon-wrapper::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 2px solid var(--accent-primary);
  width: 100%;
  height: 100%;
  opacity: 0;
  animation: pulse-ring 2.5s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
}

.ann-icon-wrapper::after {
  animation-delay: 1.25s;
}

/* The Icon Itself */
.ann-icon {
  width: 40px;
  height: 40px;
  background: var(--bg-tertiary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-primary);
  font-size: 18px;
  position: relative;
  z-index: 2;
  box-shadow: 0 0 10px rgba(0,0,0,0.3);
}

/* Text Content */
.ann-content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ann-title {
  font-size: 16px;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--text-primary);
  letter-spacing: 0.5px;
  line-height: 1.2;
}

.ann-message {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  /* Simple animation for text entrance */
  animation: slide-in-text 0.5s ease-out;
}

.ann-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

.ann-dot {
  width: 6px;
  height: 6px;
  background: var(--accent-primary);
  border-radius: 50%;
}

/* Empty State */
.ann-empty {
  text-align: center;
  padding: 20px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-lg);
  color: var(--text-muted);
  font-size: 13px;
  border: 1px dashed var(--border-color);
}

/* Animations */
@keyframes pulse-ring {
  0% { transform: translate(-50%, -50%) scale(0.8); opacity: 0.8; border-width: 3px; }
  100% { transform: translate(-50%, -50%) scale(2.2); opacity: 0; border-width: 0px; }
}

@keyframes slide-in-text {
  from { opacity: 0; transform: translateX(10px); }
  to { opacity: 1; transform: translateX(0); }
}

/* Admin Styles for Announcement */
.admin-ann-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 20px;
}

.admin-ann-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--bg-input);
  padding: 12px;
  border-radius: var(--radius-md);
  border-left: 3px solid var(--accent-primary);
}
/* ==========================================
   ANNOUNCEMENT SLIDER
   ========================================== */
.announcement-section {
  margin-bottom: 24px;
  position: relative;
}

.ann-slider {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch; /* Smooth scroll on iOS */
  scrollbar-width: none; /* Hide scrollbar Firefox */
  gap: 16px;
  padding-bottom: 10px; /* Space for dots */
}

.ann-slider::-webkit-scrollbar {
  display: none; /* Hide scrollbar Chrome/Safari */
}

.ann-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 16px;
  border: 1px solid var(--border-color);
  position: relative;
  overflow: hidden;
  min-width: 100%; /* Takes full width of container */
  scroll-snap-align: center; /* Snap to center */
  transition: transform var(--transition-fast);
}

/* Pagination Dots */
.ann-pagination {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: -6px;
}

.ann-page-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--border-color);
  transition: all 0.3s ease;
}

.ann-page-dot.active {
  background: var(--accent-primary);
  width: 16px;
  border-radius: 10px;
}

/* Pulse Animation (Same as before) */
.ann-icon-wrapper {
  position: relative;
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ann-icon-wrapper::before,
.ann-icon-wrapper::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 2px solid var(--accent-primary);
  width: 100%;
  height: 100%;
  opacity: 0;
  animation: pulse-ring 2.5s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
}
.ann-icon-wrapper::after { animation-delay: 1.25s; }

.ann-icon {
  width: 40px;
  height: 40px;
  background: var(--bg-tertiary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-primary);
  font-size: 18px;
  position: relative;
  z-index: 2;
}

.ann-content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ann-title {
  font-size: 16px;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--text-primary);
}

.ann-message {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ann-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-muted);
}

@keyframes pulse-ring {
  0% { transform: translate(-50%, -50%) scale(0.8); opacity: 0.8; border-width: 3px; }
  100% { transform: translate(-50%, -50%) scale(2.2); opacity: 0; border-width: 0px; }
}
/* ==========================================
   ADMIN IMPORT STYLES (NEW)
   ========================================== */
#mf-results .manga-card {
  transition: transform 0.2s;
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  border-radius: var(--radius-md);
  overflow: hidden;
}

#mf-results .manga-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent-primary);
}

#mf-search:focus {
  border-color: var(--accent-primary);
  outline: none;
}

/* Badge Styles for Admin Table */
.status-badge { 
  display: inline-flex; 
  align-items: center; 
  gap: 5px; 
  padding: 4px 10px; 
  border-radius: 4px; 
  font-size: 11px; 
  font-weight: 600; 
  text-transform: capitalize; 
}
.status-badge.ongoing { background: rgba(59, 130, 246, 0.15); color: #3b82f6; }
.status-badge.completed { background: rgba(34, 197, 94, 0.15); color: #22c55e; }
.status-badge.hiatus { background: rgba(245, 158, 11, 0.15); color: #f59e0b; }

/* Custom Scrollbar for Admin Sidebar */
.admin-sidebar {
  position: sticky;
  top: 80px;
  max-height: calc(100vh - 100px);
  overflow-y: auto;
}
.admin-sidebar::-webkit-scrollbar { width: 4px; }
.admin-sidebar::-webkit-scrollbar-thumb { background: var(--border-color); border-radius: 4px; }
/* ==========================================
   PROMO POPUP
   ========================================== */
.popup-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.popup-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.popup-content {
  background: transparent; /* TRANSPARENT BACKGROUND */
  width: 90%;
  max-width: 420px;
  position: relative;
  border: none;
  box-shadow: none; /* REMOVE BOX SHADOW FROM CONTAINER */
  transform: scale(0.9) translateY(20px);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.popup-backdrop.active .popup-content {
  transform: scale(1) translateY(0);
}

.popup-close {
  position: absolute;
  top: 0;
  right: 0;
  width: 32px;
  height: 32px;
  background: var(--error); /* Red background to make it visible */
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 20;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
  transition: transform 0.2s;
}

.popup-close:hover {
  transform: scale(1.1);
}

.popup-image {
  width: 100%;
  height: auto;
  max-height: 55vh; /* Limit height so it fits on mobile */
  display: block;
  object-fit: contain; /* Prevents cutting */
  background: transparent; /* NO BACKGROUND COLOR */
  
  /* This adds a shadow to the PNG shape, not the box */
  filter: drop-shadow(0 10px 15px rgba(0,0,0,0.5)); 
  
  z-index: 10;
  margin-bottom: -10px;
}

.popup-body {
  width: 100%;
  background: var(--bg-card);
  padding: 24px 20px 20px;
  text-align: center;
  border-radius: 16px;
  border: 1px solid var(--border-color);
  box-shadow: 0 10px 40px rgba(0,0,0,0.6);
  position: relative;
  z-index: 5;
}

.popup-btn {
  width: 100%;
  padding: 14px;
  background: var(--accent-gradient);
  color: white;
  font-weight: 700;
  font-size: 15px;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 15px rgba(255, 107, 53, 0.4);
  animation: pulse-btn 2s infinite;
}

@keyframes pulse-btn {
  0% { transform: scale(1); }
  50% { transform: scale(1.02); }
  100% { transform: scale(1); }
}
/* Add this to the bottom of style.css for Floating PNG support */

/* Makes the container transparent */
.popup-backdrop .popup-content {
  background: transparent; 
  border: none;
  box-shadow: none;
}

/* Adds a dark background ONLY to the text area at the bottom */
.popup-body {
  background: var(--bg-card);
  border-radius: 0 0 16px 16px; /* Rounded bottom corners */
  margin-top: -5px; /* Removes tiny gap between image and text */
}

/* Optional: Adds shadow to the image itself so it pops */
.popup-image {
  filter: drop-shadow(0 10px 20px rgba(0,0,0,0.5));
}

/* ==========================================
   HOME POPUP MODAL
   ========================================== */
.home-popup-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px); /* The blur effect */
  z-index: 2000; /* Higher than header/sidebar */
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

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

.home-popup-card {
  width: 100%;
  max-width: 450px;
  background: var(--bg-card);
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  transform: scale(0.9) translateY(20px);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  border: 1px solid var(--border-color);
}

.home-popup-overlay.active .home-popup-card {
  transform: scale(1) translateY(0);
}

.home-popup-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 32px;
  height: 32px;
  background: rgba(0, 0, 0, 0.7);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  transition: background 0.2s;
}

.home-popup-close:hover {
  background: var(--accent-primary);
}

.home-popup-image {
  width: 100%;
  display: block;
  max-height: 400px;
  object-fit: cover;
}

.home-popup-content {
  padding: 20px;
  text-align: center;
}

.home-popup-btn {
  display: inline-flex;
  width: 100%;
  justify-content: center;
  padding: 14px;
  background: var(--accent-gradient);
  color: white;
  font-weight: 700;
  border-radius: 8px;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 4px 15px rgba(255, 107, 53, 0.4);
}

.home-popup-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 107, 53, 0.6);
  color: white;
}

/* ... existing home-popup styles ... */

/* TRANSPARENT MODE (For PNGs) */
.home-popup-card.is-png {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
}

/* Adjust Image for PNG mode */
.home-popup-card.is-png .home-popup-image {
  max-height: 500px;
  object-fit: contain;
  /* Add a subtle drop shadow to the image itself so it pops */
  filter: drop-shadow(0 10px 20px rgba(0,0,0,0.4)); 
}

/* Float the close button for PNGs */
.home-popup-card.is-png .home-popup-close {
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(4px);
  top: 0;
  right: 0;
  border: 1px solid rgba(255,255,255,0.1);
}

.home-popup-card.is-png .home-popup-close:hover {
  background: var(--accent-primary);
  border-color: var(--accent-primary);
}

/* Adjust the content area */
.home-popup-card.is-png .home-popup-content {
  padding: 10px 0 0 0;
}

/* Make the button stand out more since there is no card background */
.home-popup-card.is-png .home-popup-btn {
  box-shadow: 0 4px 25px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
  max-width: 250px; /* Prevent button from being too wide on transparent mode */
  margin: 0 auto;   /* Center the button */
}
/* ==========================================
   MODERN MANGA DETAIL PAGE - INSPIRED BY MANGADEX & MODERN SITES
   Replace your existing manga detail styles with this
   ========================================== */

/* Manga Detail Page Container */
.manga-detail {
  padding-bottom: 40px;
  overflow: hidden;
}

/* ==========================================
   IMMERSIVE BANNER SECTION
   ========================================== */
.manga-detail-header {
  position: relative;
  margin-bottom: 30px;
  overflow: hidden;
}

/* Large Blurred Background Banner */
.manga-detail-banner {
  position: absolute;
  inset: 0;
  height: 450px;
  background-size: cover;
  background-position: center 20%;
  filter: blur(50px) brightness(0.4);
  transform: scale(1.2);
  z-index: 0;
}

@media (min-width: 768px) {
  .manga-detail-banner {
    height: 500px;
  }
}

/* Gradient Overlay */
.manga-detail-banner-overlay {
  position: absolute;
  inset: 0;
  height: 450px;
  background: linear-gradient(
    to bottom,
    rgba(13, 13, 13, 0.3) 0%,
    rgba(13, 13, 13, 0.8) 50%,
    var(--bg-primary) 100%
  );
  z-index: 1;
}

@media (min-width: 768px) {
  .manga-detail-banner-overlay {
    height: 500px;
  }
}

/* Content Section */
.manga-detail-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 50px 20px 30px;
  gap: 24px;
}

@media (min-width: 768px) {
  .manga-detail-content {
    flex-direction: row;
    align-items: flex-end;
    text-align: left;
    padding: 80px 30px 30px;
    gap: 30px;
  }
}

/* ==========================================
   POSTER WITH GLASSMORPHISM
   ========================================== */
.manga-detail-poster {
  flex-shrink: 0;
  width: 200px;
  position: relative;
}

@media (min-width: 768px) {
  .manga-detail-poster {
    width: 240px;
    transform: translateY(30px); /* Extends below banner */
  }
}

@media (min-width: 992px) {
  .manga-detail-poster {
    width: 280px;
  }
}

.manga-detail-poster img {
  width: 100%;
  border-radius: var(--radius-xl);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8),
              0 0 0 1px rgba(255, 255, 255, 0.1);
  transition: transform 0.3s ease;
}

.manga-detail-poster:hover img {
  transform: translateY(-8px) scale(1.02);
}

/* Floating Badge on Poster */
.manga-detail-poster::before {
  content: attr(data-status);
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 6px 12px;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 700;
  color: white;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  z-index: 3;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

/* Poster Action Buttons - Glassmorphism Style */
.manga-detail-poster-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 16px;
}

.manga-detail-poster-actions .btn {
  width: 100%;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  font-weight: 600;
  transition: all 0.3s ease;
}

.manga-detail-poster-actions .btn:hover {
  background: var(--accent-gradient);
  border-color: transparent;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(255, 107, 53, 0.4);
}

.manga-detail-poster-actions .btn-primary {
  background: var(--accent-gradient);
  border-color: transparent;
}

/* ==========================================
   INFO SECTION
   ========================================== */
.manga-detail-info {
  flex: 1;
  max-width: 100%;
}

@media (min-width: 768px) {
  .manga-detail-info {
    max-width: 700px;
  }
}

/* Title with Gradient */
.manga-detail-title {
  font-size: 28px;
  font-weight: 900;
  line-height: 1.2;
  margin-bottom: 10px;
  background: linear-gradient(135deg, #ffffff 0%, #e0e0e0 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

@media (min-width: 768px) {
  .manga-detail-title {
    font-size: 36px;
  }
}

@media (min-width: 992px) {
  .manga-detail-title {
    font-size: 42px;
  }
}

.manga-detail-alt-title {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 20px;
  font-style: italic;
}

/* Type Badge */
.manga-detail-type {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: var(--accent-gradient);
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 700;
  color: white;
  margin-bottom: 16px;
  box-shadow: 0 4px 12px rgba(255, 107, 53, 0.4);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Quick Stats Bar - Glassmorphism */
.manga-detail-quick-stats {
  display: flex;
  justify-content: center;
  gap: 20px;
  padding: 16px 24px;
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-xl);
  margin-bottom: 20px;
  flex-wrap: wrap;
}

@media (min-width: 768px) {
  .manga-detail-quick-stats {
    justify-content: flex-start;
  }
}

.quick-stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-width: 70px;
}

@media (min-width: 768px) {
  .quick-stat-item {
    align-items: flex-start;
  }
}

.quick-stat-value {
  font-size: 24px;
  font-weight: 800;
  color: var(--accent-primary);
  line-height: 1;
  display: flex;
  align-items: center;
  gap: 6px;
}

.quick-stat-value i {
  font-size: 18px;
  opacity: 0.8;
}

.quick-stat-label {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  line-height: 1;
}

/* Genre Tags - Modern Pills */
.manga-detail-genres {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-bottom: 20px;
}

@media (min-width: 768px) {
  .manga-detail-genres {
    justify-content: flex-start;
  }
}

.genre-tag {
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.8);
  transition: all 0.3s ease;
  cursor: pointer;
}

.genre-tag:hover {
  background: var(--accent-gradient);
  border-color: transparent;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
}

/* Action Buttons */
.manga-detail-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

@media (min-width: 768px) {
  .manga-detail-actions {
    justify-content: flex-start;
  }
}

.manga-detail-actions .btn {
  padding: 12px 24px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  transition: all 0.3s ease;
}

.manga-detail-actions .btn:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.manga-detail-actions .btn-primary {
  background: var(--accent-gradient);
  border-color: transparent;
}

.manga-detail-actions .btn-primary:hover {
  box-shadow: 0 6px 20px rgba(255, 107, 53, 0.5);
}

/* ==========================================
   TABBED CONTENT SECTION
   ========================================== */
.manga-detail-tabs {
  display: flex;
  gap: 8px;
  padding: 8px;
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  margin-bottom: 24px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.manga-detail-tabs::-webkit-scrollbar {
  display: none;
}

.manga-detail-tab {
  flex: 1;
  min-width: 100px;
  padding: 14px 20px;
  background: transparent;
  border: none;
  border-radius: var(--radius-lg);
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.manga-detail-tab:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.manga-detail-tab.active {
  background: var(--accent-gradient);
  color: white;
  box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
}

.manga-detail-tab i {
  font-size: 16px;
}

.manga-detail-tab .count {
  font-size: 12px;
  padding: 2px 8px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: var(--radius-full);
  margin-left: 4px;
}

/* Tab Content */
.manga-detail-tab-content {
  display: none;
  animation: fadeInUp 0.4s ease;
}

.manga-detail-tab-content.active {
  display: block;
}

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

/* ==========================================
   ENHANCED INFO CARDS
   ========================================== */
.manga-detail-section {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  padding: 24px;
  margin-bottom: 20px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

@media (min-width: 768px) {
  .manga-detail-section {
    padding: 30px;
  }
}

.manga-detail-section-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text-primary);
}

.manga-detail-section-title i {
  color: var(--accent-primary);
  font-size: 20px;
}

.manga-detail-section-title .count {
  font-size: 14px;
  font-weight: 400;
  color: var(--text-muted);
  margin-left: auto;
}

/* Description with Read More */
.manga-detail-desc {
  font-size: 14px;
  line-height: 1.8;
  color: var(--text-secondary);
  position: relative;
}

.manga-detail-desc.collapsed {
  max-height: 120px;
  overflow: hidden;
}

.manga-detail-desc.collapsed::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: linear-gradient(to bottom, transparent, var(--bg-card));
}

.read-more-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent-primary);
  font-weight: 600;
  font-size: 13px;
  margin-top: 10px;
  cursor: pointer;
  transition: gap 0.3s ease;
}

.read-more-btn:hover {
  gap: 10px;
}

/* Meta Info Grid */
.manga-detail-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-top: 20px;
}

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

.meta-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 16px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
}

.meta-item-label {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
}

.meta-item-value {
  font-size: 14px;
  color: var(--text-primary);
  font-weight: 600;
}

/* ==========================================
   ENHANCED CHAPTER LIST
   ========================================== */
.chapter-list-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  gap: 16px;
  flex-wrap: wrap;
}

.chapter-list-controls {
  display: flex;
  gap: 10px;
  align-items: center;
}

.chapter-list-controls select {
  padding: 10px 16px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 13px;
  min-width: 140px;
  cursor: pointer;
}

.chapter-list {
  max-height: 600px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--border-color) transparent;
}

.chapter-list::-webkit-scrollbar {
  width: 6px;
}

.chapter-list::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 3px;
}

/* Enhanced Chapter Item */
.chapter-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  background: var(--bg-tertiary);
  border: 1px solid transparent;
  border-radius: var(--radius-lg);
  margin-bottom: 8px;
  transition: all 0.3s ease;
  gap: 16px;
  cursor: pointer;
}

.chapter-item:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent-primary);
  transform: translateX(8px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.chapter-item-main {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
}

.chapter-number-badge {
  width: 50px;
  height: 50px;
  background: var(--accent-gradient);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 14px;
  color: white;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
}

.chapter-info {
  flex: 1;
  min-width: 0;
}

.chapter-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chapter-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.chapter-meta span {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Mobile Responsive */
@media (max-width: 480px) {
  .chapter-item {
    flex-direction: column;
    align-items: flex-start;
    padding: 14px;
  }
  
  .chapter-item-main {
    width: 100%;
  }
  
  .chapter-number-badge {
    width: 45px;
    height: 45px;
    font-size: 13px;
  }
}

/* Very Small Screens */
@media (max-width: 380px) {
  .manga-detail-title {
    font-size: 24px;
  }
  
  .manga-detail-poster {
    width: 180px;
  }
  
  .quick-stat-item {
    min-width: 60px;
  }
  
  .quick-stat-value {
    font-size: 20px;
  }
}

/* Loading Animation */
@keyframes shimmer {
  0% { background-position: -1000px 0; }
  100% { background-position: 1000px 0; }
}

.loading-shimmer {
  background: linear-gradient(
    90deg,
    var(--bg-tertiary) 0%,
    var(--bg-card-hover) 50%,
    var(--bg-tertiary) 100%
  );
  background-size: 1000px 100%;
  animation: shimmer 2s infinite;
}

/* ==========================================
   XP & LEVELING SYSTEM
   ========================================== */
.xp-card {
  background: linear-gradient(135deg, #1a1a1a 0%, #0d0d0d 100%);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
  position: relative;
  overflow: hidden;
}

/* Glowing background effect */
.xp-card::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 150px;
  height: 150px;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.15) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.xp-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.xp-level-badge {
  background: var(--accent-gradient);
  color: white;
  padding: 6px 14px;
  border-radius: 20px;
  font-weight: 800;
  font-size: 14px;
  box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
  display: flex;
  align-items: center;
  gap: 6px;
}

.xp-info {
  text-align: right;
}

.xp-text {
  font-size: 14px;
  color: var(--text-secondary);
  font-weight: 600;
}

.xp-text span {
  color: var(--text-primary);
  font-size: 18px;
}

/* Progress Bar Container */
.xp-progress-container {
  height: 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 20px;
  position: relative;
}

/* Animated Progress Fill */
.xp-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #3b82f6, #8b5cf6);
  border-radius: 10px;
  width: 0%; /* JS will update this */
  transition: width 1s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}

/* Shimmer effect on bar */
.xp-progress-fill::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.3) 50%,
    transparent 100%
  );
  transform: translateX(-100%);
  animation: shimmer 2s infinite;
}

.xp-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border-color);
}

.btn-redeem {
  background: rgba(34, 197, 94, 0.1);
  color: #4ade80;
  border: 1px solid rgba(34, 197, 94, 0.3);
  width: 100%;
}

.btn-redeem:hover {
  background: rgba(34, 197, 94, 0.2);
  transform: translateY(-2px);
}

.redeem-hint {
  font-size: 11px;
  color: var(--text-muted);
  text-align: center;
  margin-top: 8px;
}
/* ==========================================
   THEME CUSTOMIZER MODAL
   ========================================== */

.theme-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.theme-modal-overlay.active {
    display: flex;
    opacity: 1;
}

.theme-modal-card {
    background: #1a1a1a;
    width: 90%;
    max-width: 400px;
    border-radius: 20px;
    border: 1px solid #333;
    padding: 24px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.8);
    transform: translateY(20px);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.theme-modal-overlay.active .theme-modal-card {
    transform: translateY(0);
}

.theme-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.theme-header h3 {
    font-size: 20px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
}

.theme-header h3 i {
    color: var(--accent-primary);
}

.theme-close {
    width: 32px;
    height: 32px;
    background: rgba(255,255,255,0.05);
    border-radius: 50%;
    color: #888;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}

.theme-close:hover {
    background: rgba(255,255,255,0.1);
    color: #fff;
}

.theme-desc {
    color: #888;
    font-size: 14px;
    margin-bottom: 24px;
}

/* Grid of Themes */
.theme-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.theme-btn {
    position: relative;
    background: rgba(255,255,255,0.03);
    border: 2px solid transparent;
    border-radius: 12px;
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    transition: all 0.2s;
    overflow: hidden;
    text-align: left;
}

.theme-btn:hover {
    background: rgba(255,255,255,0.08);
}

.theme-btn.active {
    border-color: var(--accent-primary);
    background: rgba(255,255,255,0.05);
}

.theme-preview {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    box-shadow: 0 2px 5px rgba(0,0,0,0.5);
    border: 2px solid rgba(255,255,255,0.2);
}

.theme-btn span {
    font-size: 13px;
    font-weight: 600;
    color: #eee;
}

.theme-check {
    position: absolute;
    right: 12px;
    color: var(--accent-primary);
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.2s;
}

.theme-btn.active .theme-check {
    opacity: 1;
    transform: scale(1);
}

/* Header Action Button Helper */
.btn-ghost.icon-only {
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: var(--text-secondary);
}

.btn-ghost.icon-only:hover {
    background: var(--bg-input);
    color: var(--text-primary);
   }
/* ==========================================
   ANIMATED BURNING LOGO
   ========================================== */

/* Target the FontAwesome icon inside the logo */
.logo-icon i {
    animation: fireBurn 2.5s infinite alternate ease-in-out;
    /* Ensure smooth color transition when theme changes */
    transition: color 0.5s ease, filter 0.5s ease;
}

/* The Burning Animation */
@keyframes fireBurn {
    0% {
        transform: scale(1) translateY(0);
        /* Soft glow matching the theme */
        filter: drop-shadow(0 0 2px var(--accent-primary));
        opacity: 0.9;
    }
    25% {
        transform: scale(1.1) rotate(-3deg);
    }
    50% {
        transform: scale(0.95) rotate(3deg) translateY(1px);
        /* Intense glow matching the theme */
        filter: drop-shadow(0 0 10px var(--accent-primary));
        opacity: 1;
    }
    75% {
        transform: scale(1.05) rotate(-2deg);
    }
    100% {
        transform: scale(1) translateY(0);
        filter: drop-shadow(0 0 2px var(--accent-primary));
        opacity: 0.9;
    }
}

/* Optional: Make the box container breathe slightly too */
.logo-icon {
    animation: boxBreathe 4s infinite ease-in-out;
}

@keyframes boxBreathe {
    0%, 100% { box-shadow: 0 0 0 rgba(0,0,0,0); }
    50% { box-shadow: 0 0 15px var(--accent-primary); border-color: var(--accent-primary); }
}
/* ==========================================
   UPDATED FIRE LOGO ANIMATION
   ========================================== */

/* Remove any old filters/mix-blend-modes from previous attempt */
.logo-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    filter: none;
    box-shadow: none;
    overflow: visible; /* Let the glow spill out */
}

/* Target the Icon specifically */
.logo-icon i {
    font-size: 24px;
    
    /* Create a gradient fill for depth */
    background: linear-gradient(to top, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    
    /* The Glow Effect */
    filter: drop-shadow(0 0 5px var(--accent-primary));
    
    /* Anchor animation at the bottom so it "burns up" */
    transform-origin: bottom center;
    animation: sharpBurn 1.5s infinite alternate ease-in-out;
}

/* The Burning Keyframes */
@keyframes sharpBurn {
    0% {
        transform: scale(1) rotate(0deg);
        filter: drop-shadow(0 0 4px var(--accent-primary));
        opacity: 0.9;
    }
    25% {
        transform: scale(1.1) rotate(-3deg);
    }
    50% {
        transform: scale(0.95) rotate(3deg) translateY(1px);
        filter: drop-shadow(0 0 12px var(--accent-primary));
        opacity: 1;
    }
    75% {
        transform: scale(1.05) rotate(-2deg);
    }
    100% {
        transform: scale(1) rotate(0deg);
        filter: drop-shadow(0 0 4px var(--accent-primary));
        opacity: 0.9;
    }
}

/* ==========================================
   MOBILE MENU LOGO FIX
   Add this to your style.css
   ========================================== */

/* Force logo text to show in mobile menu */
.mobile-menu-header .logo-text {
  display: block !important;
  font-size: 18px !important;
}

.mobile-menu-header .logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mobile-menu-header .logo-icon {
  width: 36px;
  height: 36px;
  font-size: 18px;
}

/* Ensure proper spacing */
.mobile-menu-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 16px;
}

/* Make sure close button is visible */
.mobile-menu-close {
  width: 36px;
  height: 36px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
  cursor: pointer;
  transition: background 0.2s ease;
}

.mobile-menu-close:hover {
  background: var(--bg-tertiary);
}
