/* ===== NUEVO DISEÑO MODERNO Y ELEGANTE ===== */

/* Importar fuentes modernas */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Poppins:wght@300;400;500;600;700;800&display=swap');

/* Variables CSS modernas */
:root {
  /* Paleta de colores moderna */
  --bg-primary: #0a0a0f;
  --bg-secondary: #1a1a2e;
  --bg-card: rgba(26, 26, 46, 0.8);
  --bg-card-hover: rgba(30, 30, 60, 0.9);
  
  /* Colores de acento */
  --accent-primary: #ff3cac;
  --accent-secondary: #a259ff;
  --accent-gold: #ffd700;
  --accent-blue: #00d4ff;
  
  /* Texto */
  --text-primary: #ffffff;
  --text-secondary: #b8b8d1;
  --text-muted: #8a8a9c;
  
  /* Bordes y sombras */
  --border-color: rgba(255, 60, 172, 0.3);
  --shadow-primary: 0 8px 32px rgba(255, 60, 172, 0.15);
  --shadow-secondary: 0 4px 20px rgba(162, 89, 255, 0.2);
  --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.3);
  
  /* Gradientes */
  --gradient-primary: linear-gradient(135deg, #ff3cac 0%, #a259ff 100%);
  --gradient-secondary: linear-gradient(135deg, #a259ff 0%, #00d4ff 100%);
  --gradient-gold: linear-gradient(135deg, #ffd700 0%, #ffb347 100%);
  
  /* Bordes redondeados */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
}

/* Reset y configuración base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
}

/* ===== SIDEBAR MODERNO ===== */
.sidebar {
  width: 80px;
  background: rgba(26, 26, 46, 0.95);
  backdrop-filter: blur(20px);
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 24px 0;
  gap: 32px;
  position: fixed;
  height: 100vh;
  z-index: 1000;
  left: 0;
  top: 0;
  bottom: 0;
  transition: all 0.3s ease;
}

.sidebar a, .sidebar button {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 1.2em;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.sidebar a:hover, .sidebar button:hover {
  background: var(--gradient-primary);
  color: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow-primary);
  border-color: transparent;
}

.sidebar a.active, .sidebar button.active {
  background: var(--gradient-primary);
  color: white;
  box-shadow: var(--shadow-primary);
}

.sidebar svg {
  width: 24px;
  height: 24px;
  transition: all 0.3s ease;
}

/* ===== HEADER MODERNO ===== */
header {
  background: rgba(26, 26, 46, 0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  padding: 16px 32px;
  position: fixed;
  top: 0;
  left: 80px;
  right: 0;
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.header-content-center {
  display: flex;
  align-items: center;
  gap: 24px;
  flex: 1;
  justify-content: center;
}

.logo {
  font-family: 'Poppins', sans-serif;
  font-size: 2.2rem;
  font-weight: 800;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -1px;
}

/* ===== BOTONES MODERNOS ===== */
.btn-modern {
  background: var(--gradient-primary);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  padding: 12px 24px;
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-primary);
}

.btn-modern:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(255, 60, 172, 0.3);
}

.btn-modern:active {
  transform: translateY(0);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: var(--accent-primary);
}

.btn-gold {
  background: var(--gradient-gold);
  color: #000;
}

.btn-gold:hover {
  box-shadow: 0 12px 40px rgba(255, 215, 0, 0.3);
}

/* ===== BÚSQUEDA MODERNA ===== */
.search-bar {
  position: relative;
  display: flex;
  align-items: center;
}

#searchInput {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-lg);
  padding: 12px 20px;
  color: var(--text-primary);
  font-size: 0.95rem;
  width: 280px;
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

#searchInput:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(255, 60, 172, 0.1);
  background: rgba(255, 255, 255, 0.15);
}

#search-btn-lupa {
  position: absolute;
  right: 12px;
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 1.2rem;
  cursor: pointer;
  transition: color 0.3s ease;
}

#search-btn-lupa:hover {
  color: var(--accent-primary);
}

/* ===== CONTENIDO PRINCIPAL ===== */
.main-content {
  margin-left: 80px;
  padding-top: 80px;
  min-height: 100vh;
  background: var(--bg-primary);
}

.content-area {
  padding: 32px;
  max-width: 1400px;
  margin: 0 auto;
}

/* ===== TARJETAS MODERNAS ===== */
.post-card {
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all 0.3s ease;
  position: relative;
  height: 460px;
  min-height: 460px;
  display: flex;
  flex-direction: column;
}

.post-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-card);
  border-color: var(--border-color);
  background: var(--bg-card-hover);
}

.post-image {
  width: 100%;
  height: 180px;
  object-fit: cover;
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.post-card:hover .post-image {
  transform: scale(1.05);
}

.post-info {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 0;
}

.post-title {
  font-family: 'Poppins', sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.4;
  margin-bottom: 4px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  text-overflow: ellipsis;
}

.post-meta {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.5;
  flex-shrink: 0;
  margin-bottom: 4px;
}

.post-meta span {
  color: var(--text-primary);
  font-weight: 500;
}

.post-description {
  color: var(--text-secondary);
  font-size: 0.85rem;
  line-height: 1.4;
  flex-shrink: 0;
  margin-bottom: 8px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  text-overflow: ellipsis;
  max-height: 3.6em; /* 3 líneas * 1.2em */
}

.post-actions {
  margin-top: auto;
  flex-shrink: 0;
  padding-top: 8px;
}

/* ===== GRID DE NOVELAS ===== */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 32px;
  min-height: 400px;
  padding: 0 16px;
}

.posts-grid:empty::before {
  content: 'Cargando novelas...';
  display: flex;
  justify-content: center;
  align-items: center;
  height: 200px;
  color: var(--text-secondary);
  font-size: 16px;
  grid-column: 1 / -1;
}

/* ===== SECCIÓN DESTACADA ===== */
.featured-post {
  background: var(--gradient-primary);
  border-radius: var(--radius-xl);
  overflow: hidden;
  position: relative;
  min-height: 300px;
  margin-bottom: 32px;
  box-shadow: var(--shadow-primary);
}

.featured-post img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1;
}

.featured-overlay {
  position: relative;
  z-index: 2;
  padding: 40px;
  background: linear-gradient(135deg, rgba(10, 10, 15, 0.8) 0%, rgba(26, 26, 46, 0.6) 100%);
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.featured-title {
  font-family: 'Poppins', sans-serif;
  font-size: 2.2rem;
  font-weight: 700;
  color: white;
  margin-bottom: 12px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.featured-meta {
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 20px;
  line-height: 1.6;
}

.featured-author {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.featured-author img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid var(--accent-primary);
}

.verified {
  color: var(--accent-gold);
  font-size: 1.2rem;
}

/* ===== CARRUSEL VIP ===== */
#vipCarouselSection {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: 32px;
  margin: 32px 0;
  border: 1px solid var(--border-color);
  backdrop-filter: blur(20px);
  position: relative;
}

#vip-carousel {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  min-height: 200px;
}

#vip-slide {
  display: flex;
  gap: 20px;
  padding: 20px;
  transition: transform 0.3s ease;
  overflow-x: auto;
  scroll-behavior: smooth;
}

#vip-prev, #vip-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.7);
  color: white;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  font-size: 18px;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
}

#vip-prev:hover, #vip-next:hover {
  background: rgba(0, 0, 0, 0.9);
  transform: translateY(-50%) scale(1.1);
}

#vip-prev {
  left: 10px;
}

#vip-next {
  right: 10px;
}

.vip-card {
  background: linear-gradient(145deg, var(--bg-card), var(--bg-card-secondary));
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 12px;
  margin: 8px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(10px);
  min-width: 200px;
  max-width: 250px;
}

.vip-card:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
  border-color: var(--accent-gold);
}

.vip-card img {
  width: 100%;
  height: 120px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 8px;
}

.vip-card-info {
  text-align: center;
}

.vip-card-info h4 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0 0 4px 0;
  line-height: 1.3;
}

.vip-card-info p {
  font-size: 11px;
  color: var(--text-secondary);
  margin: 0;
}

/* ===== PANEL DE CATEGORÍAS ===== */
#panel-categorias {
  position: fixed;
  top: 0;
  right: 0;
  height: 100vh;
  width: 320px;
  max-width: 96vw;
  z-index: 2500;
  transform: translateX(110%);
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}

#panel-categorias.open {
  transform: translateX(0);
}

#panel-categorias-bg {
  display: none;
  position: fixed;
  z-index: 2000;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0,0,0,0.8);
  backdrop-filter: blur(10px);
}

#panel-categorias-bg.active {
  display: block;
}

#panel-categorias .panel-categorias-header {
  background: var(--gradient-primary);
  padding: 24px;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

#panel-categorias .panel-categorias-header h2 {
  color: white;
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  margin: 0;
}

.category-chip2 {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-md);
  padding: 8px 16px;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.category-chip2:hover {
  background: var(--gradient-primary);
  color: white;
  border-color: transparent;
  transform: translateY(-2px);
}

/* ===== MODALES MODERNOS ===== */
.modal-form {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
  padding: 40px;
  max-width: 500px;
  width: 90vw;
  z-index: 2500;
}

.modal-form h2 {
  font-family: 'Poppins', sans-serif;
  font-size: 1.8rem;
  font-weight: 700;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 24px;
  text-align: center;
}

.modal-form input {
  width: 100%;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  color: var(--text-primary);
  font-size: 0.95rem;
  margin-bottom: 16px;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.modal-form input:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(255, 60, 172, 0.1);
  background: rgba(255, 255, 255, 0.15);
}

.modal-form button[type="submit"] {
  width: 100%;
  background: var(--gradient-primary);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  padding: 14px 24px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 8px;
}

.modal-form button[type="submit"]:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(255, 60, 172, 0.3);
}

.close-modal {
  position: absolute;
  top: 20px;
  right: 20px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  color: var(--text-secondary);
  font-size: 1.2rem;
  cursor: pointer;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.close-modal:hover {
  background: var(--gradient-primary);
  color: white;
  transform: scale(1.1);
}

/* ===== BADGE VIP ===== */
.vip-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  background: var(--gradient-gold);
  color: #000;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  z-index: 3;
  box-shadow: 0 4px 16px rgba(255, 215, 0, 0.3);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .sidebar {
    width: 100%;
    height: 60px;
    flex-direction: row;
    bottom: 0;
    top: auto;
    padding: 0 16px;
    gap: 20px;
  }
  
  .main-content {
    margin-left: 0;
    padding-bottom: 80px;
  }
  
  header {
    left: 0;
    padding: 12px 20px;
  }
  
  .content-area {
    padding: 20px;
  }
  
  .featured-title {
    font-size: 1.6rem;
  }
  
  .modal-form {
    padding: 24px;
    margin: 20px;
  }
}

@media (max-width: 480px) {
  .header-content-center {
    gap: 16px;
  }
  
  #searchInput {
    width: 200px;
  }
  
  .logo {
    font-size: 1.8rem;
  }
}

/* ===== ANIMACIONES ===== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.post-card {
  animation: fadeInUp 0.6s ease forwards;
}

/* ===== SCROLLBAR PERSONALIZADA ===== */
::-webkit-scrollbar {
  width: 8px;
}

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

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

::-webkit-scrollbar-thumb:hover {
  background: var(--gradient-secondary);
}

/* ===== LOADING STATES ===== */
.loading {
  opacity: 0.6;
  pointer-events: none;
}

.loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  margin: -10px 0 0 -10px;
  border: 2px solid var(--accent-primary);
  border-top: 2px solid transparent;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
} 

/* --- Botón hamburguesa --- */
.sidebar-toggle-btn {
  position: fixed;
  top: 18px;
  left: 18px;
  z-index: 3000;
  background: var(--bg-card);
  color: var(--accent-primary);
  border: none;
  border-radius: 50%;
  width: 44px;
  height: 44px;
  font-size: 2rem;
  box-shadow: var(--shadow-card);
  cursor: pointer;
  transition: background 0.2s;
}
.sidebar-toggle-btn:hover {
  background: var(--accent-primary);
  color: #fff;
}

/* --- Sidebar colapsable --- */
.sidebar {
  width: 72px;
  transition: width 0.3s cubic-bezier(.4,2,.6,1), box-shadow 0.2s;
  overflow-x: hidden;
}
.sidebar.expanded {
  width: 220px;
  box-shadow: 0 2px 16px #ffd70055;
}

/* Opcional: mostrar texto de los items solo cuando está expandida */
.sidebar .sidebar-item-text {
  display: none;
  margin-left: 12px;
  font-size: 1rem;
  color: var(--text-primary);
  vertical-align: middle;
}
.sidebar.open .sidebar-item-text {
  display: inline;
}

/* --- Header superior --- */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 56px;
  background: var(--bg-card);
  box-shadow: var(--shadow-card);
  z-index: 4000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  gap: 16px;
}

.sidebar-toggle-btn {
  margin: 0;
  position: static;
  top: auto;
  left: auto;
  z-index: 4200;
  flex-shrink: 0;
}

.search-bar {
  flex: 1;
  max-width: 400px;
  display: flex;
  align-items: center;
  gap: 8px;
}

#user-btn {
  flex-shrink: 0;
}

/* Ajustar el main-content para que no quede debajo del header */
.main-content {
  margin-top: 56px;
}

/* Sidebar oculta y animada */
.sidebar {
  position: fixed;
  top: 0;
  left: -240px;
  width: 220px;
  height: 100vh;
  background: rgba(26, 26, 46, 0.95);
  box-shadow: 2px 0 16px #0008;
  transition: left 0.3s cubic-bezier(.4,2,.6,1);
  z-index: 4100;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 24px 0;
  gap: 32px;
  overflow-x: hidden;
}
.sidebar.open {
  left: 0;
}

#sidebar-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0,0,0,0.6);
  z-index: 4090;
  transition: opacity 0.2s;
}
#sidebar-overlay.active {
  display: block;
}

@media (max-width: 700px) {
  .sidebar {
    width: 80vw;
    max-width: 320px;
  }
  .search-bar {
    max-width: 200px;
  }
} 

/* Sidebar header y centrado de items */
.sidebar {
  display: flex;
  flex-direction: column;
  align-items: stretch;
}
.sidebar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 16px 20px 8px 20px;
  border-bottom: 1px solid var(--border-color);
}
.sidebar-title {
  font-size: 1.3rem;
  font-weight: bold;
  color: var(--accent-primary);
  letter-spacing: 1px;
}
.sidebar-close-btn {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 50%;
  transition: background 0.2s;
}
.sidebar-close-btn:hover {
  background: var(--accent-primary);
  color: #fff;
}
.sidebar-items {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  width: 100%;
}

.sidebar-item-container {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 0 20px;
}

.sidebar-item {
  flex-shrink: 0;
}

.sidebar-item-text {
  display: none;
  font-size: 1rem;
  color: var(--text-primary);
  font-weight: 500;
}

.sidebar.open .sidebar-item-text {
  display: block;
} 

/* ===== PANEL DE USUARIO ===== */
#user-panel {
  position: absolute;
  top: 60px;
  right: 20px;
  z-index: 3000;
  background: var(--bg-card);
  padding: 20px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border-color);
  backdrop-filter: blur(20px);
  min-width: 160px;
}

#user-info {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 8px 16px;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border-color);
  backdrop-filter: blur(20px);
  min-width: 200px;
  z-index: 3000;
} 

/* ===== PANEL DE USUARIO COMPLETO ===== */
#user-panel {
  position: absolute;
  top: 60px;
  right: 20px;
  z-index: 3000;
  background: linear-gradient(135deg, #1a0a1a 0%, #2d0a2d 50%, #1a0a1a 100%);
  border: 2px solid var(--accent-primary);
  border-radius: var(--radius-xl);
  box-shadow: 0 20px 60px rgba(255, 60, 172, 0.3), 0 0 40px rgba(162, 89, 255, 0.2);
  backdrop-filter: blur(20px);
  width: 380px;
  max-width: 90vw;
  max-height: 80vh;
  overflow: hidden;
  animation: slideInPanel 0.3s ease-out;
}

@keyframes slideInPanel {
  from {
    opacity: 0;
    transform: translateY(-20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.user-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px;
  background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.user-welcome {
  display: flex;
  align-items: center;
  gap: 12px;
}

.user-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.3);
  object-fit: cover;
  box-shadow: 0 4px 16px rgba(255, 60, 172, 0.4);
}

.user-info h3 {
  color: white;
  font-family: 'Poppins', sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.user-status {
  color: var(--accent-gold);
  font-size: 0.8rem;
  font-weight: 500;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
}

.user-status.vip {
  color: var(--accent-gold);
  font-weight: 600;
  text-shadow: 0 1px 4px rgba(255, 215, 0, 0.3);
}

.close-panel-btn {
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  color: white;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.close-panel-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.1);
}

.user-panel-content {
  padding: 20px;
  max-height: 60vh;
  overflow-y: auto;
  padding-bottom: 100px; /* Espacio extra al final */
}

.panel-section {
  margin-bottom: 24px;
}

.panel-section h4 {
  color: var(--accent-primary);
  font-family: 'Poppins', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 12px;
  text-shadow: 0 1px 4px rgba(255, 60, 172, 0.3);
}

.favorites-list, .downloads-list {
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-md);
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.favorite-item, .download-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.favorite-item:last-child, .download-item:last-child {
  border-bottom: none;
}

.favorite-item .novel-title {
  color: var(--text-primary);
  font-weight: 500;
}

.download-item .download-date {
  color: var(--text-muted);
  font-size: 0.8rem;
}

.empty-state {
  color: var(--text-muted);
  font-style: italic;
  text-align: center;
  padding: 20px;
  margin: 0;
}

.benefits-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.benefit-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-secondary);
  font-size: 0.85rem;
  transition: all 0.3s ease;
}

.benefit-item:hover {
  background: rgba(255, 60, 172, 0.1);
  border-color: var(--accent-primary);
  transform: translateY(-2px);
}

.benefit-icon {
  font-size: 1.2rem;
}

.vip-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 12px;
}

.vip-type {
  color: var(--accent-gold);
  font-weight: 600;
  font-size: 1rem;
}

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

.btn-vip-upgrade {
  width: 100%;
  background: var(--gradient-gold);
  color: #000;
  border: none;
  border-radius: var(--radius-md);
  padding: 12px 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: 'Poppins', sans-serif;
}

.btn-vip-upgrade:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(255, 215, 0, 0.3);
}

.settings-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.setting-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.3s ease;
  text-align: left;
}

.setting-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--accent-primary);
  transform: translateX(4px);
}

.setting-btn.danger:hover {
  background: rgba(255, 60, 60, 0.1);
  border-color: #ff3c3c;
}

.setting-icon {
  font-size: 1.1rem;
}

.btn-logout {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 16px;
  background: linear-gradient(135deg, #ff3c3c 0%, #ff6b6b 100%);
  border: none;
  border-radius: var(--radius-md);
  color: white;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: 'Poppins', sans-serif;
}

.btn-logout:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(255, 60, 60, 0.3);
}

.logout-icon {
  font-size: 1.1rem;
}

/* Responsive */
@media (max-width: 768px) {
  #user-panel {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    height: 100vh;
    max-width: none;
    max-height: none;
    border-radius: 0;
    z-index: 4000;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    transform: none !important;
    animation: none;
  }
  
  .user-panel-header {
    position: sticky;
    top: 0;
    z-index: 10;
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    padding: 16px;
  }
  
  .user-panel-content {
    max-height: none;
    padding: 16px;
    overflow-y: visible;
    flex: 1;
  }
  
  .user-welcome {
    gap: 12px;
  }
  
  .user-avatar {
    width: 48px;
    height: 48px;
  }
  
  .user-info h3 {
    font-size: 1.1rem;
  }
  
  .user-status {
    font-size: 0.8rem;
  }
  

  
  .benefits-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  
  .panel-section {
    margin-bottom: 20px;
  }
  
  .panel-section h4 {
    font-size: 0.9rem;
    margin-bottom: 10px;
  }
  
  .favorites-btn, .downloads-btn, .playlist-btn, .share-btn {
    padding: 12px;
  }
  
  .favorites-icon, .downloads-icon, .playlist-icon, .share-icon {
    font-size: 1.2rem;
  }
  
  .favorites-info h4, .downloads-info h4, .playlist-info h4, .share-info h4 {
    font-size: 0.9rem;
  }
  
  .favorites-info span, .downloads-info span, .playlist-info span, .share-info span {
    font-size: 0.8rem;
  }
  
  .settings-list {
    gap: 6px;
  }
  
  .setting-btn {
    padding: 10px 12px;
    font-size: 0.85rem;
  }
  
  .close-panel-btn {
    width: 36px;
    height: 36px;
    font-size: 0.9rem;
  }
  
  .sync-section {
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-md);
  }
  
  .vip-benefits {
    padding: 12px;
    background: rgba(255, 215, 0, 0.05);
    border-radius: var(--radius-md);
  }
  
  .vip-status {
    padding: 12px;
    background: rgba(255, 215, 0, 0.1);
    border-radius: var(--radius-md);
  }
} 

/* ===== BOTÓN DE FAVORITO ===== */

/* Ajustar posición del badge VIP para no solaparse con favorito */
.vip-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  background: var(--gradient-gold);
  color: #000;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  z-index: 3;
  box-shadow: 0 4px 16px rgba(255, 215, 0, 0.3);
} 

/* ===== RESPONSIVE DESIGN MEJORADO PARA ANDROID ===== */
@media (max-width: 768px) {
  /* Ajustes generales para móviles */
  body {
    font-size: 14px;
    line-height: 1.5;
  }
  
  /* Topbar responsive */
  .topbar {
    height: 60px;
    padding: 0 12px;
    gap: 8px;
  }
  
  .sidebar-toggle-btn {
    width: 40px;
    height: 40px;
    font-size: 1.5rem;
  }
  
  /* Search bar responsive */
  .search-bar {
    max-width: 150px;
    flex: 1;
  }
  
  #searchInput {
    width: 100%;
    padding: 8px 12px;
    font-size: 0.9rem;
  }
  
  /* Botones de usuario responsive */
  #user-btn {
    width: 40px;
    height: 40px;
  }
  
  #auth-buttons {
    display: flex;
    gap: 4px;
  }
  
  #auth-buttons .btn-modern {
    padding: 8px 12px;
    font-size: 0.8rem;
  }
  
  /* Sidebar responsive */
  .sidebar {
    width: 100vw;
    max-width: 320px;
    left: -100vw;
  }
  
  .sidebar.open {
    left: 0;
  }
  
  .sidebar-header {
    padding: 12px 16px;
  }
  
  .sidebar-title {
    font-size: 1.1rem;
  }
  
  .sidebar-items {
    gap: 16px;
    padding: 16px;
  }
  
  .sidebar-item-container {
    padding: 0 12px;
  }
  
  /* Main content responsive */
  .main-content {
    margin-left: 0;
    margin-top: 60px;
    padding-top: 0;
  }
  
  .content-area {
    padding: 16px;
  }
  

  
  .post-card {
    height: auto;
    min-height: 400px;
  }
  
  .post-image {
    height: 160px;
  }
  
  .post-info {
    padding: 16px;
    gap: 6px;
  }
  
  .post-title {
    font-size: 1rem;
    margin-bottom: 6px;
  }
  
  .post-meta {
    font-size: 0.8rem;
    margin-bottom: 6px;
  }
  
  .post-description {
    font-size: 0.8rem;
    margin-bottom: 6px;
  }
  
  /* Botón de favorito responsive */
  .btn-favorite {
    width: 36px;
    height: 36px;
    font-size: 1rem;
    top: 8px;
    left: 8px;
  }
  
  /* Panel de usuario responsive */
  #user-panel {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    border-radius: 0;
    z-index: 4000;
  }
  
  .user-panel-content {
    max-height: calc(100vh - 100px);
    padding: 16px;
  }
  
  .panel-section {
    margin-bottom: 20px;
  }
  
  .panel-section h4 {
    font-size: 0.9rem;
    margin-bottom: 10px;
  }
  
  .benefits-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  
  .benefit-item {
    padding: 10px;
    font-size: 0.8rem;
  }
  
  .settings-list {
    gap: 6px;
  }
  
  .setting-btn {
    padding: 10px 12px;
    font-size: 0.85rem;
  }
  
  /* Modales responsive */
  .modal-form {
    padding: 24px;
    margin: 16px;
    max-width: calc(100vw - 32px);
  }
  
  .modal-form h2 {
    font-size: 1.4rem;
    margin-bottom: 20px;
  }
  
  .modal-form input {
    padding: 10px 12px;
    font-size: 0.9rem;
    margin-bottom: 12px;
  }
  
  .modal-form button[type="submit"] {
    padding: 12px 20px;
    font-size: 0.9rem;
  }
  
  /* Panel de categorías responsive */
  #panel-categorias {
    width: 100vw;
    max-width: none;
  }
  
  .category-chip2 {
    padding: 6px 12px;
    font-size: 0.8rem;
  }
  
  /* Carrusel VIP responsive */
  #vipCarouselSection {
    padding: 20px;
    margin: 20px 0;
  }
  
  .vip-card {
    min-width: 240px;
    height: 280px;
  }
  
  #vip-prev, #vip-next {
    width: 40px;
    height: 40px;
    font-size: 1rem;
  }
  
  /* Featured post responsive */
  .featured-post {
    min-height: 200px;
    margin-bottom: 20px;
  }
  
  .featured-overlay {
    padding: 24px;
  }
  
  .featured-title {
    font-size: 1.4rem;
    margin-bottom: 8px;
  }
  
  .featured-meta {
    font-size: 0.9rem;
    margin-bottom: 16px;
  }
  
  .featured-author {
    margin-bottom: 12px;
  }
  
  .featured-author img {
    width: 32px;
    height: 32px;
  }
  
  /* Botón de favorito en página responsive */
  .page-favorite-btn {
    width: 44px;
    height: 44px;
    font-size: 1.3rem;
    top: 80px;
    right: 16px;
  }
}

/* Ajustes específicos para pantallas muy pequeñas */
@media (max-width: 480px) {
  .topbar {
    padding: 0 8px;
    gap: 6px;
  }
  
  .search-bar {
    max-width: 120px;
  }
  
  #searchInput {
    padding: 6px 10px;
    font-size: 0.85rem;
  }
  
  .content-area {
    padding: 12px;
  }
  
  .post-card {
    min-height: 380px;
  }
  
  .post-image {
    height: 140px;
  }
  
  .post-info {
    padding: 12px;
  }
  
  .post-title {
    font-size: 0.9rem;
  }
  
  .post-meta {
    font-size: 0.75rem;
  }
  
  .post-description {
    font-size: 0.75rem;
  }
  
  .modal-form {
    padding: 20px;
    margin: 12px;
  }
  
  .modal-form h2 {
    font-size: 1.2rem;
  }
  
  .featured-title {
    font-size: 1.2rem;
  }
  
  .featured-meta {
    font-size: 0.8rem;
  }
  
  /* Panel de usuario en pantallas muy pequeñas */
  #user-panel {
    padding: 0;
    width: 100vw !important;
    height: 100vh !important;
    left: 0 !important;
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    transform: none !important;
    animation: none !important;
    border-radius: 0 !important;
    max-width: none !important;
    max-height: none !important;
  }
  
  .user-panel-header {
    padding: 12px 16px;
    position: sticky;
    top: 0;
    z-index: 10;
  }
  
  .user-panel-content {
    padding: 12px;
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  .user-welcome {
    gap: 8px;
  }
  
  .user-avatar {
    width: 40px;
    height: 40px;
  }
  
  .user-info h3 {
    font-size: 1rem;
  }
  
  .user-status {
    font-size: 0.75rem;
  }
  

  

  

  
  .panel-section {
    margin-bottom: 16px;
  }
  
  .panel-section h4 {
    font-size: 0.85rem;
    margin-bottom: 8px;
  }
  
  .favorites-btn, .downloads-btn, .playlist-btn, .share-btn, .compras-btn {
    padding: 10px;
  }
  
  .favorites-icon, .downloads-icon, .playlist-icon, .share-icon, .compras-icon {
    font-size: 1.1rem;
  }
  
  .favorites-info h4, .downloads-info h4, .playlist-info h4, .share-info h4, .compras-info h4 {
    font-size: 0.85rem;
  }
  
  .favorites-info span, .downloads-info span, .playlist-info span, .share-info span, .compras-info span {
    font-size: 0.75rem;
  }
  
  .benefit-item {
    padding: 8px;
    font-size: 0.75rem;
  }
  
  .benefit-icon {
    font-size: 1rem;
  }
  
  .settings-list {
    gap: 4px;
  }
  
  .setting-btn {
    padding: 8px 10px;
    font-size: 0.8rem;
  }
  
  .setting-icon {
    font-size: 1rem;
  }
  
  .btn-logout {
    padding: 12px 16px;
    font-size: 0.9rem;
  }
  
  .logout-icon {
    font-size: 1rem;
  }
  
  .sync-section, .vip-benefits, .vip-status {
    padding: 10px;
    margin-bottom: 12px;
  }
  
  .benefits-grid {
    gap: 6px;
  }
  
  .close-panel-btn {
    width: 32px;
    height: 32px;
    font-size: 0.8rem;
  }
}

/* Ajustes para orientación landscape en móviles */
@media (max-width: 768px) and (orientation: landscape) {
  .topbar {
    height: 50px;
  }
  
  .main-content {
    margin-top: 50px;
  }
  
  .sidebar {
    width: 280px;
  }
  
  .post-card {
    min-height: 320px;
  }
  
  .post-image {
    height: 120px;
  }
  
  /* Panel de usuario en landscape */
  #user-panel {
    width: 100vw !important;
    height: 100vh !important;
    left: 0 !important;
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    transform: none !important;
    animation: none !important;
    border-radius: 0 !important;
    max-width: none !important;
    max-height: none !important;
  }
  
  .user-panel-content {
    padding: 12px;
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  .user-panel-header {
    padding: 10px 16px;
    position: sticky;
    top: 0;
    z-index: 10;
  }
  
  .user-avatar {
    width: 36px;
    height: 36px;
  }
  
  .user-info h3 {
    font-size: 0.9rem;
  }
  
  .user-status {
    font-size: 0.7rem;
  }
  
  .monedas-display {
    flex-direction: row;
    gap: 8px;
    padding: 8px;
  }
  
  .moneda-item {
    flex: 1;
    justify-content: center;
    padding: 6px 8px;
    font-size: 0.8rem;
  }
  
  .panel-section {
    margin-bottom: 12px;
  }
  
  .panel-section h4 {
    font-size: 0.8rem;
    margin-bottom: 6px;
  }
  
  .favorites-btn, .downloads-btn, .playlist-btn, .share-btn, .tienda-btn, .compras-btn {
    padding: 8px;
  }
  
  .favorites-icon, .downloads-icon, .playlist-icon, .share-icon, .tienda-icon, .compras-icon {
    font-size: 1rem;
  }
  
  .favorites-info h4, .downloads-info h4, .playlist-info h4, .share-info h4, .compras-info h4 {
    font-size: 0.8rem;
  }
  
  .favorites-info span, .downloads-info span, .playlist-info span, .share-info span, .compras-info span {
    font-size: 0.7rem;
  }
  
  .benefits-grid {
    grid-template-columns: 1fr 1fr;
    gap: 6px;
  }
  
  .benefit-item {
    padding: 6px;
    font-size: 0.7rem;
  }
  
  .benefit-icon {
    font-size: 0.9rem;
  }
  
  .settings-list {
    gap: 4px;
  }
  
  .setting-btn {
    padding: 6px 8px;
    font-size: 0.75rem;
  }
  
  .setting-icon {
    font-size: 0.9rem;
  }
  
  .btn-logout {
    padding: 8px 12px;
    font-size: 0.8rem;
  }
  
  .logout-icon {
    font-size: 0.9rem;
  }
  
  .close-panel-btn {
    width: 28px;
    height: 28px;
    font-size: 0.7rem;
  }
}

/* Ajustes para tablets */
@media (min-width: 769px) and (max-width: 1024px) {

  
  .content-area {
    padding: 24px;
  }
  
  .search-bar {
    max-width: 300px;
  }
  
  .sidebar {
    width: 200px;
  }
}

/* Ajustes para pantallas muy grandes */
@media (min-width: 1400px) {
  .content-area {
    max-width: 1600px;
  }
  

} 

/* ===== MEJORAS PARA EXPERIENCIA TÁCTIL EN ANDROID ===== */
@media (max-width: 768px) {
  /* Mejorar área de toque para botones */
  .btn-modern, .btn-favorite, .setting-btn, .sidebar-item, .sidebar-toggle-btn {
    min-height: 44px;
    min-width: 44px;
  }
  
  /* Evitar zoom en inputs en iOS */
  input[type="text"], input[type="password"], input[type="email"] {
    font-size: 16px !important;
  }
  
  /* Mejorar scroll en Android */
  .user-panel-content, #panel-categorias-lista {
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
  }
  
  /* Prevenir selección de texto en botones */
  .btn-modern, .btn-favorite, .setting-btn {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
  }
  
  /* Mejorar feedback táctil */
  .btn-modern:active, .btn-favorite:active, .setting-btn:active {
    transform: scale(0.95);
  }
  
  /* Ajustar espaciado para dedos */
  .sidebar-item-container {
    padding: 8px 12px;
  }
  
  .settings-list {
    gap: 8px;
  }
  
  /* Mejorar navegación por gestos */
  .sidebar-overlay {
    -webkit-tap-highlight-color: transparent;
  }
  
  /* Optimizar para pantallas con notch */
  .topbar {
    padding-top: env(safe-area-inset-top);
  }
  
  .main-content {
    padding-top: env(safe-area-inset-top);
  }
  
  /* Mejorar legibilidad en pantallas pequeñas */
  .post-title {
    line-height: 1.3;
  }
  
  .post-meta {
    line-height: 1.4;
  }
  
  /* Ajustar tamaños de fuente para mejor legibilidad */
  .modal-form h2 {
    line-height: 1.2;
  }
  
  .panel-section h4 {
    line-height: 1.3;
  }
} 

/* ===== BOTÓN DE FAVORITOS EN PANEL DE USUARIO ===== */
.favorites-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.3s ease;
  text-align: left;
}

.favorites-btn:hover {
  background: rgba(255, 60, 172, 0.1);
  border-color: var(--accent-primary);
  transform: translateX(4px);
}

.favorites-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.favorites-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.favorites-info h4 {
  color: var(--text-primary);
  font-family: 'Poppins', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  margin: 0;
}

.favorites-info span {
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.favorites-arrow {
  color: var(--accent-primary);
  font-size: 1.2rem;
  font-weight: bold;
  flex-shrink: 0;
} 

/* ===== BOTONES DE PANEL DE USUARIO ===== */
.downloads-btn, .playlist-btn, .share-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.3s ease;
  text-align: left;
}

.downloads-btn:hover, .playlist-btn:hover, .share-btn:hover {
  background: rgba(255, 60, 172, 0.1);
  border-color: var(--accent-primary);
  transform: translateX(4px);
}

.downloads-icon, .playlist-icon, .share-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.downloads-info, .playlist-info, .share-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.downloads-info h4, .playlist-info h4, .share-info h4 {
  color: var(--text-primary);
  font-family: 'Poppins', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  margin: 0;
}

.downloads-info span, .playlist-info span, .share-info span {
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.downloads-arrow, .playlist-arrow, .share-arrow {
  color: var(--accent-primary);
  font-size: 1.2rem;
  font-weight: bold;
  flex-shrink: 0;
}

/* Colores específicos para cada botón */
.playlist-btn:hover {
  background: rgba(162, 89, 255, 0.1);
  border-color: var(--accent-secondary);
}

.share-btn:hover {
  background: rgba(0, 212, 255, 0.1);
  border-color: var(--accent-blue);
} 

/* Estilos para el botón de compras */
.compras-btn {
  width: 100%;
  padding: 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  color: var(--text-primary);
  text-decoration: none;
}

.compras-btn:hover {
  background: var(--gradient-primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-primary);
}

.compras-icon {
  font-size: 1.5em;
  color: var(--accent-gold);
  transition: all 0.3s ease;
}

.compras-info {
  flex: 1;
  text-align: left;
}

.compras-info h4 {
  font-size: 1rem;
  font-weight: 600;
  margin: 0 0 4px 0;
  color: var(--text-primary);
}

.compras-info span {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.compras-arrow {
  font-size: 1.2em;
  color: var(--text-secondary);
  transition: all 0.3s ease;
}

/* Responsive para nuevos botones */
@media (max-width: 768px) {
  .downloads-btn, .playlist-btn, .share-btn, .compras-btn {
    padding: 12px;
  }
  
  .downloads-icon, .playlist-icon, .share-icon, .compras-icon {
    font-size: 1.2rem;
  }
  
  .downloads-info h4, .playlist-info h4, .share-info h4, .compras-info h4 {
    font-size: 0.9rem;
  }
  
  .downloads-info span, .playlist-info span, .share-info span, .compras-info span {
    font-size: 0.8rem;
  }
  
  /* Botones en tarjetas de novelas */
  .post-card button[onclick*="addToPlaylist"],
  .post-card button[onclick*="shareNovela"] {
    width: 28px;
    height: 28px;
    font-size: 0.9rem;
  }
} 

/* ===== ESTADO DE SINCRONIZACIÓN ===== */
.sync-section {
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
}

.sync-status {
  font-size: 0.9rem;
  font-weight: 500;
  margin-bottom: 8px;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  text-align: center;
}

.sync-status.synced {
  color: #4CAF50;
  background: rgba(76, 175, 80, 0.1);
  border: 1px solid rgba(76, 175, 80, 0.3);
}

.sync-status.syncing {
  color: #FF9800;
  background: rgba(255, 152, 0, 0.1);
  border: 1px solid rgba(255, 152, 0, 0.3);
  animation: pulse 1.5s infinite;
}

.sync-status.pending {
  color: #FF5722;
  background: rgba(255, 87, 34, 0.1);
  border: 1px solid rgba(255, 87, 34, 0.3);
}

.queue-status {
  font-size: 0.8rem;
  color: var(--text-secondary);
  text-align: center;
  margin-bottom: 12px;
}

.btn-sync {
  width: 100%;
  background: var(--gradient-secondary);
  font-size: 0.9rem;
  padding: 10px 16px;
}

.btn-sync:hover {
  background: var(--gradient-primary);
}

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

/* ===== SISTEMA DE MONEDAS Y TIENDA ===== */

/* Display de monedas en el panel de usuario */
.monedas-display {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.moneda-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
  font-weight: 600;
}

.moneda-icon {
  font-size: 1.1rem;
}

/* Botón de tienda */
.tienda-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: linear-gradient(135deg, rgba(255, 215, 0, 0.1) 0%, rgba(255, 193, 7, 0.1) 100%);
  border: 1px solid rgba(255, 215, 0, 0.3);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.3s ease;
  text-align: left;
}

.tienda-btn:hover {
  background: linear-gradient(135deg, rgba(255, 215, 0, 0.2) 0%, rgba(255, 193, 7, 0.2) 100%);
  border-color: var(--accent-gold);
  transform: translateX(4px);
}

.tienda-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.tienda-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.tienda-info h4 {
  color: var(--accent-gold);
  font-family: 'Poppins', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  margin: 0;
}

.tienda-info span {
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.tienda-arrow {
  color: var(--accent-gold);
  font-size: 1.2rem;
  font-weight: bold;
  flex-shrink: 0;
}

/* Responsive para botón de tienda */
@media (max-width: 768px) {
  .tienda-btn {
    padding: 12px;
  }
  
  .tienda-icon {
    font-size: 1.2rem;
  }
  
  .tienda-info h4 {
    font-size: 0.9rem;
  }
  
  .tienda-info span {
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  .tienda-btn {
    padding: 10px;
  }
  
  .tienda-icon {
    font-size: 1.1rem;
  }
  
  .tienda-info h4 {
    font-size: 0.85rem;
  }
  
  .tienda-info span {
    font-size: 0.75rem;
  }
}

/* Modal de tienda */
.tienda-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.9);
  z-index: 5000;
  display: none;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(20px);
}

/* ================== ESTILOS PARA MODALES ================== */

.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 10000;
}

.modal-content {
  background: #111;
  padding: 30px;
  border-radius: 15px;
  max-width: 600px;
  width: 90%;
  color: white;
  border: 2px solid #ffd700;
  max-height: 80vh;
  overflow-y: auto;
  position: relative;
}

.close {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 28px;
  font-weight: bold;
  color: #ffd700;
  cursor: pointer;
  transition: color 0.3s ease;
}

.close:hover {
  color: #ffed4e;
}

/* ================== ESTILOS PARA BOTONES ================== */

.btn-primary {
  background: #ffd700;
  color: #000;
  border: none;
  padding: 12px 24px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: bold;
  transition: all 0.3s ease;
}

.btn-primary:hover {
  background: #ffed4e;
  transform: scale(1.05);
}

.btn-secondary {
  background: #333;
  color: white;
  border: 2px solid #ffd700;
  padding: 10px 20px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-secondary:hover {
  background: #ffd700;
  color: #000;
}

.btn-danger {
  background: #f44336;
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: bold;
  transition: all 0.3s ease;
}

.btn-danger:hover {
  background: #d32f2f;
}

/* ================== ESTILOS PARA FORMULARIOS ================== */

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

.form-group label {
  display: block;
  margin-bottom: 8px;
  color: #ffd700;
  font-weight: bold;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px;
  border: 2px solid #333;
  border-radius: 8px;
  background: #222;
  color: white;
  font-size: 16px;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: #ffd700;
}

.form-group input:invalid {
  border-color: #f44336;
}

/* ================== ESTILOS PARA LOADING ================== */

.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid #333;
  border-radius: 50%;
  border-top-color: #ffd700;
  animation: spin 1s ease-in-out infinite;
}

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

/* ================== ESTILOS PARA SCROLLBARS ================== */

::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #222;
}

::-webkit-scrollbar-thumb {
  background: #ffd700;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #ffed4e;
}

/* Modal de Eliminar Cuenta */
.delete-account-modal {
  max-width: 600px;
}

.delete-warning {
  background: rgba(255, 68, 68, 0.1);
  border: 1px solid rgba(255, 68, 68, 0.3);
  border-radius: var(--radius-md);
  padding: 20px;
  margin-bottom: 24px;
  text-align: center;
}

.warning-icon {
  font-size: 48px;
  margin-bottom: 16px;
  display: block;
}

.delete-warning h3 {
  color: #ff4444;
  margin-bottom: 16px;
  font-size: 18px;
  font-weight: 600;
}

.delete-warning p {
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.delete-warning ul {
  text-align: left;
  list-style: none;
  padding: 0;
}

.delete-warning li {
  color: var(--text-secondary);
  margin-bottom: 8px;
  padding-left: 20px;
  position: relative;
}

.delete-warning li:before {
  content: "❌";
  position: absolute;
  left: 0;
  top: 0;
}

/* Estilos para formularios */
.form-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--border-color);
}

.form-actions button {
  padding: 12px 24px;
  border-radius: var(--radius-md);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
}

.btn-primary {
  background: var(--gradient-primary);
  color: white;
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-primary);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-secondary);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.15);
  color: var(--text-primary);
}

.btn-danger {
  background: linear-gradient(135deg, #ff4444 0%, #cc0000 100%);
  color: white;
}

.btn-danger:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(255, 68, 68, 0.3);
}

.btn-danger:disabled {
  background: rgba(255, 68, 68, 0.3);
  cursor: not-allowed;
}
/* ================== ESTILOS MEJORADOS PARA BOTÓN DE USUARIO ================== */

.user-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  border: 1px solid var(--border-color);
  border-radius: 25px;
  color: white;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  font-weight: 500;
  min-width: 120px;
}

.user-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
}

.user-btn.logged-in {
  background: linear-gradient(135deg, #2c3e50, #34495e);
  border: 1px solid #3498db;
}

.user-btn.logged-in:hover {
  background: linear-gradient(135deg, #34495e, #2c3e50);
  border-color: #5dade2;
}

.user-info {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}

.user-name {
  font-size: 14px;
  font-weight: 600;
  color: white;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.user-status {
  font-size: 11px;
  font-weight: 400;
  opacity: 0.9;
}

.user-avatar {
  width: 24px;
  height: 24px;
  color: white;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
}

/* ================== NUEVO DISEÑO DE CARTAS DESDE CERO ================== */

.novela-card {
  background: linear-gradient(135deg, #0f0f23, #1a1a2e);
  border: 2px solid transparent;
  border-radius: 24px;
  padding: 0;
  margin: 0;
  transition: all 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  cursor: pointer;
  position: relative;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(25px);
  height: 450px;
  display: flex;
  flex-direction: column;
  width: 100%;
  box-sizing: border-box;
  overflow: hidden;
  border-image: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4) 1;
}

.novela-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(255, 107, 107, 0.15), rgba(78, 205, 196, 0.15));
  opacity: 0;
  transition: opacity 0.5s ease;
  z-index: 1;
}

.novela-card:hover {
  transform: translateY(-12px) scale(1.03);
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
  border-color: #ff6b6b;
}

.novela-card:hover::before {
  opacity: 1;
}

.novela-imagen {
  position: relative;
  width: 100%;
  height: 250px;
  overflow: hidden;
  flex-shrink: 0;
  z-index: 2;
}

.novela-imagen::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 80px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
  z-index: 2;
}

.novela-imagen img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s ease;
  background: linear-gradient(45deg, #2c3e50, #34495e);
}

.novela-card:hover .novela-imagen img {
  transform: scale(1.15) rotate(3deg);
}

.btn-favorite {
  position: absolute;
  top: 16px;
  left: 16px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.9);
  border: 2px solid rgba(255, 255, 255, 0.4);
  color: white;
  font-size: 18px;
  cursor: pointer;
  transition: all 0.5s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(20px);
  z-index: 3;
}

.btn-favorite:hover {
  background: rgba(255, 20, 147, 0.95);
  border-color: rgba(255, 20, 147, 0.9);
  transform: scale(1.2) rotate(8deg);
  box-shadow: 0 10px 25px rgba(255, 20, 147, 0.6);
}

.btn-favorite.favorited {
  background: rgba(255, 20, 147, 0.95);
  border-color: rgba(255, 20, 147, 0.9);
  animation: heartBeat 1s ease;
}

@keyframes heartBeat {
  0%, 100% { transform: scale(1) rotate(0deg); }
  25% { transform: scale(1.3) rotate(3deg); }
  50% { transform: scale(1.15) rotate(-2deg); }
  75% { transform: scale(1.25) rotate(2deg); }
}

.novela-actions-overlay {
  position: absolute;
  top: 16px;
  right: 16px;
  display: flex;
  gap: 10px;
  z-index: 3;
}

.btn-share-round,
.btn-playlist-round {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.9);
  border: 2px solid rgba(255, 255, 255, 0.4);
  color: white;
  font-size: 18px;
  cursor: pointer;
  transition: all 0.5s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(20px);
}

.btn-share-round:hover,
.btn-playlist-round:hover {
  background: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.9);
  transform: scale(1.2) rotate(8deg);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
}

.novela-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 24px;
  min-height: 0;
  width: 100%;
  box-sizing: border-box;
  z-index: 2;
  position: relative;
}

.novela-titulo {
  font-size: 20px;
  font-weight: 900;
  color: #ffffff;
  margin: 0;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-shadow: 0 3px 6px rgba(0, 0, 0, 0.6);
  flex-shrink: 0;
  min-height: 52px;
  word-break: break-word;
  text-overflow: ellipsis;
  white-space: normal;
  letter-spacing: 0.8px;
}

.novela-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
  flex-shrink: 0;
  align-items: center;
}

.novela-estado {
  font-size: 12px;
  color: #ffffff;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 6px 14px;
  background: linear-gradient(45deg, #ff6b6b, #ff8e8e);
  border-radius: 25px;
  box-shadow: 0 4px 12px rgba(255, 107, 107, 0.4);
}

.novela-peso {
  font-size: 12px;
  color: #ffffff;
  font-weight: 700;
  letter-spacing: 1.5px;
  padding: 6px 14px;
  background: linear-gradient(45deg, #4ecdc4, #45b7d1);
  border-radius: 25px;
  box-shadow: 0 4px 12px rgba(78, 205, 196, 0.4);
}

.novela-desc {
  font-size: 15px;
  color: #c8d4e0;
  line-height: 1.6;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
  min-height: 0;
  word-break: break-word;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
}

/* Responsive para el nuevo diseño */
@media (max-width: 768px) {
  .novela-card {
    height: 400px;
    border-radius: 20px;
  }
  
  .novela-imagen {
    height: 200px;
  }
  
  .novela-actions-overlay {
    top: 12px;
    right: 12px;
    gap: 8px;
  }
  
  .btn-share-round,
  .btn-playlist-round,
  .btn-favorite {
    width: 40px;
    height: 40px;
    font-size: 16px;
  }
  
  .novela-info {
    padding: 20px;
    gap: 12px;
  }
  
  .novela-titulo {
    font-size: 18px;
    min-height: 48px;
    letter-spacing: 0.6px;
  }
  
  .novela-desc {
    font-size: 14px;
    -webkit-line-clamp: 3;
  }
  
  .novela-meta {
    gap: 10px;
    margin-bottom: 12px;
  }
  
  .novela-estado,
  .novela-peso {
    font-size: 11px;
    padding: 5px 12px;
    letter-spacing: 1.2px;
  }
}

@media (max-width: 480px) {
  .novela-card {
    height: 380px;
    border-radius: 18px;
  }
  
  .novela-imagen {
    height: 180px;
  }
  
  .novela-actions-overlay {
    top: 10px;
    right: 10px;
    gap: 6px;
  }
  
  .btn-share-round,
  .btn-playlist-round,
  .btn-favorite {
    width: 36px;
    height: 36px;
    font-size: 14px;
  }
  
  .novela-info {
    padding: 16px;
    gap: 10px;
  }
  
  .novela-titulo {
    font-size: 16px;
    min-height: 44px;
    letter-spacing: 0.5px;
  }
  
  .novela-desc {
    font-size: 13px;
    -webkit-line-clamp: 3;
  }
  
  .novela-meta {
    gap: 8px;
    margin-bottom: 10px;
  }
  
  .novela-estado,
  .novela-peso {
    font-size: 10px;
    padding: 4px 10px;
    letter-spacing: 1px;
  }
}

/* Grid mejorado */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 32px;
  min-height: 400px;
  padding: 0 16px;
  width: 100%;
  box-sizing: border-box;
}

@media (max-width: 768px) {
  .posts-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 16px;
    padding: 0 8px;
  }
}

@media (max-width: 480px) {
  .posts-grid {
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 12px;
    padding: 0 4px;
  }
}

/* ===== ESTILOS DEL MOSTRADOR DESTACADO (ROTADOR) ===== */
.featured-post {
  width: 100%;
  display: block;
}
.featured-panel {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  margin: 14px 0 18px 0;
  position: relative;
  z-index: 2;
}
.featured-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  max-width: 1100px;
  padding: 8px 12px;
}
.featured-card {
  position: relative;
  width: 100%;
  max-width: 920px;
  border-radius: 10px;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
  box-shadow: 0 10px 30px rgba(0,0,0,0.35);
}
.featured-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}
.featured-caption {
  position: absolute;
  bottom: 8px;
  left: 8px;
  right: 8px;
  padding: 10px 12px;
  background: linear-gradient(180deg, rgba(0,0,0,0.0), rgba(0,0,0,0.6));
  border-radius: 8px;
}
.featured-caption h2 {
  margin: 0;
  color: var(--text-primary);
  font-size: 1.05rem;
  font-weight: 700;
}
.featured-nav {
  background: rgba(0,0,0,0.45);
  color: white;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.featured-dots {
  display:flex;
  gap:8px;
  justify-content:center;
  margin-top:8px;
}
.featured-dot { width:10px; height:10px; border-radius:50%; background:rgba(255,255,255,0.12); border:1px solid rgba(255,255,255,0.06); }
.featured-dot.active { background: var(--gradient-primary); box-shadow: 0 4px 12px rgba(162,89,255,0.12); }

/* Overlay small arrows inside the card for a cleaner visual */
.featured-card .overlay-arrow { position:absolute; top:50%; transform:translateY(-50%); width:44px; height:44px; border-radius:50%; background:rgba(0,0,0,0.45); color:white; display:flex; align-items:center; justify-content:center; cursor:pointer; z-index:4; }
.featured-card .overlay-arrow.left { left:12px; }
.featured-card .overlay-arrow.right { right:12px; }

/* Fade transitions */
.featured-card .featured-image, .featured-card .featured-caption { transition: opacity 420ms ease, transform 420ms ease; }
.featured-card.fade-out .featured-image, .featured-card.fade-out .featured-caption { opacity:0; transform: translateY(6px) scale(0.995); }
.featured-card.fade-in .featured-image, .featured-card.fade-in .featured-caption { opacity:1; transform: translateY(0) scale(1); }

/* Make sure the featured doesn't cover the grid */
.featured-post { margin-bottom: 12px; }

/* ===== MODAL DE BÚSQUEDA AVANZADA ===== */
.search-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10000;
  flex-direction: column;
}

.search-modal.active {
  display: flex;
}

.search-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  cursor: pointer;
}

.search-modal-container {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 95%;
  max-width: 1200px;
  max-height: 90vh;
  height: 90vh;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-primary);
  margin: auto;
  overflow: hidden;
  animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-30px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.search-modal-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px 24px;
  background: linear-gradient(135deg, rgba(255, 60, 172, 0.1) 0%, rgba(162, 89, 255, 0.1) 100%);
  border-bottom: 1px solid var(--border-color);
}

.search-modal-input {
  flex: 1;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  color: var(--text-primary);
  font-size: 18px;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
}

.search-modal-input:focus {
  outline: none;
  border-color: var(--accent-primary);
  background: rgba(255, 60, 172, 0.1);
  box-shadow: 0 0 12px rgba(255, 60, 172, 0.3);
}

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

.search-modal-close {
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 24px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.search-modal-close:hover {
  background: rgba(255, 60, 172, 0.2);
  color: var(--accent-primary);
}

.search-modal-results {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.search-modal-results:empty::after {
  content: "No se encontraron resultados";
  padding: 40px 20px;
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
}

/* Nuevos estilos para tarjetas de lista */
.search-result-card-list {
  display: flex;
  gap: 16px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.3s ease;
  overflow: hidden;
}

.search-result-card-list:hover {
  background: rgba(255, 60, 172, 0.1);
  border-color: var(--accent-primary);
  transform: translateX(4px);
  box-shadow: 0 6px 20px rgba(255, 60, 172, 0.3);
}

.search-result-list-image {
  flex-shrink: 0;
  width: 120px;
  height: 160px;
  overflow: hidden;
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.5);
}

.search-result-list-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.search-result-list-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.search-result-list-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.3;
  margin: 0;
}

.search-result-list-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.4;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.search-result-list-genres {
  font-size: 12px;
  color: var(--text-muted);
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.search-result-list-genres strong {
  color: var(--accent-primary);
}

.search-result-list-footer {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 8px;
}

.status-badge {
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
  background: rgba(162, 89, 255, 0.2);
  color: var(--accent-secondary);
}

.status-badge.completa,
.status-badge.completada,
.status-badge.finalizado {
  background: rgba(76, 175, 80, 0.2);
  color: #4CAF50;
}

.status-badge.en\ emision,
.status-badge.en\ desarrollo,
.status-badge.en\ construccion {
  background: rgba(255, 152, 0, 0.2);
  color: #FFA500;
}

.relevance-score {
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  background: rgba(255, 60, 172, 0.2);
  color: var(--accent-primary);
  font-weight: 600;
}

.date-badge {
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  background: rgba(0, 212, 255, 0.2);
  color: var(--accent-blue);
}

.search-result-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s ease;
  overflow: hidden;
}

.search-result-card:hover {
  background: rgba(255, 60, 172, 0.1);
  border-color: var(--accent-primary);
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(255, 60, 172, 0.3);
}

.search-result-image {
  width: 100%;
  aspect-ratio: 2/3;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.5);
  height: 280px;
}

.search-result-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

/* Scrollbar personalizado para modal */
.search-modal-results::-webkit-scrollbar {
  width: 8px;
}

.search-modal-results::-webkit-scrollbar-track {
  background: rgba(255, 60, 172, 0.1);
  border-radius: 4px;
}

.search-modal-results::-webkit-scrollbar-thumb {
  background: var(--accent-primary);
  border-radius: 4px;
}

.search-modal-results::-webkit-scrollbar-thumb:hover {
  background: var(--accent-secondary);
}

@media (max-width: 768px) {
  .search-modal-container {
    width: 98%;
    max-height: 90vh;
    height: 90vh;
  }

  .search-modal-results {
    padding: 16px;
    gap: 12px;
  }

  .search-result-list-image {
    width: 100px;
    height: 140px;
  }

  .search-result-list-title {
    font-size: 15px;
  }

  .search-result-list-desc {
    font-size: 12px;
  }

  .search-result-card-list {
    padding: 12px;
    gap: 12px;
  }
}

@media (max-width: 480px) {
  .search-modal-container {
    width: 100%;
    height: 100%;
    max-height: 100vh;
    border-radius: 0;
  }

  .search-modal-results {
    padding: 12px;
    gap: 10px;
  }

  .search-result-card-list {
    flex-direction: column;
    padding: 12px;
    gap: 10px;
  }

  .search-result-list-image {
    width: 100%;
    height: 120px;
  }

  .search-result-list-title {
    font-size: 14px;
  }

  .search-result-list-desc {
    font-size: 12px;
    -webkit-line-clamp: 2;
  }

  .search-result-list-genres {
    font-size: 11px;
  }

  .search-result-list-footer {
    gap: 6px;
    font-size: 10px;
  }
}

@media (max-width: 768px) {
  .featured-image { height:140px; }
  .featured-card .overlay-arrow { width:36px; height:36px; }
  .featured-caption h2 { font-size: 0.95rem; }
}