/* ============================================
   FEATURES.CSS - Estilos de funcionalidades extras
   ============================================ */

/* 1. BARRA DE PROGRESO DE LECTURA */
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 0%;
  height: 3px;
  background: linear-gradient(90deg, #d4af37, #fff5cc);
  z-index: 1001;
  transition: width 0.1s ease;
  box-shadow: 0 0 10px rgba(212,175,55,0.5);
}
/* 3. BREADCRUMB */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1rem;
  font-size: 0.85rem;
  color: #888;
  background: rgba(255,255,255,0.02);
  border-bottom: 2px solid rgba(212,175,55,0.1);
  max-width: 1200px;
  margin: 0;
  flex-wrap: wrap;
}

.breadcrumb a {
  color: #d4af37;
  text-decoration: none;
  transition: color 0.3s;
}

.breadcrumb a:hover {
  color: #fff5cc;
  text-shadow: 0 0 5px rgba(212,175,55,0.5);
}

.breadcrumb-separator {
  color: #555;
  user-select: none;
}

/* 4. TIEMPO DE LECTURA */
.reading-time {
  text-align: center;
  color: #888;
  font-size: 0.85rem;
  margin: 1rem auto;
  padding: 0.6rem 1rem;
  background: rgba(255,255,255,0.02);
  border-radius: 20px;
  max-width: 200px;
  border: 1px solid rgba(212,175,55,0.1);
  display: inline-block;
}

.reading-time::before {
  content: '🕐';
  margin-right: 0.5rem;
}

/* 6. BOTONES DE COMPARTIR */
.social-share {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin: 2.5rem 0;
  padding: 1.5rem;
  border-top: 1px solid rgba(212,175,55,0.1);
  border-bottom: 1px solid rgba(212,175,55,0.1);
  background: rgba(255,255,255,0.01);
}

.social-btn {
  width: 45px;
  height: 45px;
  border-radius: 50%;
  background: rgba(212,175,55,0.1);
  border: 1px solid rgba(212,175,55,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1.3rem;
}

.social-btn:hover {
  background: rgba(212,175,55,0.3);
  transform: translateY(-4px) scale(1.1);
  box-shadow: 0 6px 16px rgba(212,175,55,0.4);
}

.social-btn:active {
  transform: translateY(-2px) scale(1.05);
}

/* 7. NAVEGACIÓN FLOTANTE */
.floating-nav {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  z-index: 100;
  animation: slideInRight 0.5s ease;
}
.botones-secundarios {
  text-align: center;
  margin: 40px 0;
  color: #d4af37;
  font-family: 'Cinzel', serif;
  letter-spacing: 0.5px;
}

.boton-contenedor {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.boton-dorado {
  background: transparent;
  border: 1.9px solid #d4af37;
  color: #d4af37;
  padding: 10px 20px;
  border-radius: 10px;
  text-decoration: none;
  font-family: 'Crimson Pro', serif;
  font-weight: 500;
  transition: all 0.3s ease;
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.1);
}

.boton-dorado:hover {
  background: #d4af37;
  color: #0b0b0c;
  box-shadow: 0 0 15px rgba(212, 175, 55, 0.4);
  transform: translateY(-2px);
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(100px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.floating-nav button {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(20,20,20,0.95);
  border: 1px solid rgba(212,175,55,0.3);
  color: #d4af37;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1.3rem;
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.5);
  font-weight: bold;
}

.floating-nav button:hover {
  background: rgba(212,175,55,0.2);
  transform: translateY(-3px) scale(1.1);
  box-shadow: 0 6px 20px rgba(212,175,55,0.4);
  border-color: #d4af37;
}

.floating-nav button:active {
  transform: translateY(-1px) scale(1.05);
}

/* 8. FRASE ROTATIVA */
.frase-rotativa {
  text-align: center;
  color: rgba(212,175,55,0.7);
  font-style: italic;
  font-size: 0.95rem;
  margin: 1.5rem auto;
  max-width: 600px;
  padding: 0.8rem 1rem;
  transition: opacity 0.4s ease;
  line-height: 1.6;
  background: rgba(255,255,255,0.02);
  border-radius: 8px;
  border-left: 3px solid rgba(212,175,55,0.3);
}
/* 9. ÍNDICE DE CONTENIDOS */
.table-of-contents {
  position: fixed;
  right: 2rem;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(20,20,20,0.95);
  padding: 1.2rem;
  border-radius: 10px;
  border: 1px solid rgba(212,175,55,0.2);
  max-width: 220px;
  backdrop-filter: blur(10px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.5);
  z-index: 90;
  animation: slideInRight 0.5s ease;
}

.table-of-contents h3 {
  font-size: 0.9rem;
  color: #d4af37;
  margin: 0 0 1rem 0;
  text-align: center;
  letter-spacing: 1px;
  border-bottom: 1px solid rgba(212,175,55,0.2);
  padding-bottom: 0.5rem;
}

.table-of-contents ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.table-of-contents li {
  margin-bottom: 0.5rem;
}

.table-of-contents a {
  color: #888;
  text-decoration: none;
  font-size: 0.85rem;
  transition: all 0.3s;
  display: block;
  padding: 0.4rem 0.6rem;
  border-radius: 4px;
  border-left: 2px solid transparent;
}

.table-of-contents a:hover {
  color: #d4af37;
  background: rgba(212,175,55,0.1);
  border-left-color: #d4af37;
  transform: translateX(3px);
}

.table-of-contents a.active {
  color: #d4af37;
  background: rgba(212,175,55,0.15);
  border-left-color: #d4af37;
  font-weight: bold;
}
/* ==================== CATEGORÍAS ==================== */

.reflexion-categories {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: center;
  margin: 1.5rem auto;
  max-width: 700px;
  padding: 0 1rem;
}

.category-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.4rem 1rem;
  background: rgba(255,255,255,0.05);
  border: 1.5px solid;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  color: #d4af37;
  transition: all 0.3s ease;
}

.category-badge:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(212,175,55,0.3);
  background: rgba(255,255,255,0.1);
}

/* Filtro de categorías */
.category-filter {
  max-width: 900px;
  margin: 2rem auto;
  padding: 1.5rem;
  background: rgba(255,255,255,0.03);
  border-radius: 12px;
  border: 1px solid rgba(212,175,55,0.2);
}

.category-filter h3 {
  color: #d4af37;
  text-align: center;
  margin-bottom: 1rem;
  font-size: 1.3rem;
}

.category-buttons {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.category-btn {
  padding: 0.6rem 1.2rem;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(212,175,55,0.3);
  border-radius: 25px;
  color: #d4af37;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}

.category-btn:hover {
  background: rgba(212,175,55,0.15);
  border-color: rgba(212,175,55,0.5);
  transform: translateY(-2px);
}

.category-btn.active {
  background: rgba(212,175,55,0.25);
  border-color: #d4af37;
  font-weight: 600;
}

.no-results-category {
  text-align: center;
  color: #888;
  padding: 2rem;
  font-size: 1.1rem;
}

/* Tema claro */
body[data-theme="light"] .category-badge {
  background: rgba(139,115,85,0.1);
  color: #6d5a45;
}

body[data-theme="light"] .category-filter {
  background: rgba(139,115,85,0.05);
  border-color: rgba(139,115,85,0.2);
}

body[data-theme="light"] .category-filter h3 {
  color: #8b7355;
}

body[data-theme="light"] .category-btn {
  background: rgba(139,115,85,0.1);
  border-color: rgba(139,115,85,0.3);
  color: #6d5a45;
}

body[data-theme="light"] .category-btn:hover {
  background: rgba(139,115,85,0.2);
}

body[data-theme="light"] .category-btn.active {
  background: rgba(139,115,85,0.3);
  border-color: #8b7355;
}

@media (max-width: 768px) {
  .reflexion-categories {
    gap: 0.4rem;
  }

  .category-badge {
    font-size: 0.8rem;
    padding: 0.3rem 0.8rem;
  }

  .category-filter {
    padding: 1rem;
  }

  .category-buttons {
    gap: 0.4rem;
  }

  .category-btn {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
  }
}
/* ==================== COMENTARIOS ==================== */

.comments-section {
  max-width: 800px;
  margin: 4rem auto 2rem;
  padding: 2rem 1rem;
  border-top: 2px solid rgba(212,175,55,0.3);
}

.comments-title {
  font-family: 'Cinzel', serif;
  font-size: 1.8rem;
  color: #d4af37;
  text-align: center;
  margin-bottom: 0.5rem;
}

.comments-subtitle {
  text-align: center;
  color: #888;
  font-size: 0.95rem;
  margin-bottom: 2rem;
}

#comments-container {
  margin-top: 2rem;
}

/* Tema claro */
body[data-theme="light"] .comments-title {
  color: #8b7355;
}

body[data-theme="light"] .comments-subtitle {
  color: #666;
}

body[data-theme="light"] .comments-section {
  border-top-color: rgba(139,115,85,0.3);
}

@media (max-width: 768px) {
  .comments-section {
    padding: 1.5rem 0.5rem;
    margin: 3rem auto 1rem;
  }

  .comments-title {
    font-size: 1.5rem;
  }

  .comments-subtitle {
    font-size: 0.9rem;
  }
}


/* ============================================
10. MODO LECTURA SUGERIDO */
.reading-mode-suggestion {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(20,20,20,0.95);
  padding: 0.8rem 1.8rem;
  border-radius: 25px;
  border: 1px solid rgba(212,175,55,0.3);
  color: #d4af37;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.3s;
  backdrop-filter: blur(10px);
  display: none;
  z-index: 100;
  box-shadow: 0 4px 12px rgba(0,0,0,0.5);
  animation: slideUp 0.4s ease;
}

body.scrolled .reading-mode-suggestion {
  display: block;
}

.reading-mode-suggestion:hover {
  background: rgba(212,175,55,0.2);
  transform: translateX(-50%) translateY(-3px);
  box-shadow: 0 6px 16px rgba(212,175,55,0.3);
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}
/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 1400px) {
  .table-of-contents {
    display: none;
  }
}

@media (max-width: 968px) {
  .floating-nav {
    bottom: 1rem;
    right: 1rem;
  }

  .floating-nav button {
    width: 45px;
    height: 45px;
    font-size: 1.1rem;
  }

  .social-share {
    gap: 0.8rem;
    padding: 1rem;
  }

  .social-btn {
    width: 40px;
    height: 40px;
    font-size: 1.1rem;
  }
}

@media (max-width: 480px) {
  .breadcrumb {
    font-size: 0.75rem;
    padding: 0.5rem 0.8rem;
  }

  .frase-rotativa {
    font-size: 0.85rem;
    padding: 0.6rem 0.8rem;
  }

  .floating-nav {
    bottom: 0.5rem;
    right: 0.5rem;
  }

  .floating-nav button {
    width: 40px;
    height: 40px;
    font-size: 1rem;
  }

  .reading-mode-suggestion {
    font-size: 0.8rem;
    padding: 0.6rem 1.2rem;
    bottom: 1rem;
  }
}

/* ============================================
   ANIMACIONES ADICIONALES
   ============================================ */

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