/* ========================================
   Cable Entretenimiento - Custom TailwindCSS
   ======================================== */

/* Variables CSS */
:root {
  --ce-bg: #0b1220;
  --ce-card: #0f1a33;
  --ce-border: rgba(255, 255, 255, .08);
  --ce-primary: #40a6d4;
  --ce-primary-hover: #3596c4;
}

/* ======================================== */
   RESET GLOBAL PARA ENLACES
   ======================================== */

/* Eliminar subrayado y estilos de enlace por defecto en todo el sitio */
a,
a:link,
a:visited,
a:hover,
a:active {
  text-decoration: none !important;
}

/* ======================================== */
   OVERRIDE ESTILOS VIEJOS - IMPORTANTE
   ======================================== */

/* Forzar el diseño moderno del header */
#main-header,
header#main-header,
body header#main-header {
  background: rgba(255, 255, 255, 0.9) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  border-bottom: 1px solid rgba(226, 232, 240, 0.5) !important;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1) !important;
}

/* Resetear estilos de navbar viejos */
#main-header .navbar,
#main-header .navbar-nav,
#main-header .navbar-collapse,
#main-header #navbarSupportedContent {
  background: transparent !important;
  height: auto !important;
  padding: 0 !important;
}

/* Links del menú con diseño moderno - selectores super específicos */
#main-header a,
#main-header .navbar a,
#main-header .navbar-nav a,
#main-header .navbar ul li a,
#main-header details summary {
  color: rgb(51, 65, 85) !important; /* text-slate-700 */
  font-size: 0.875rem !important; /* text-sm */
  font-weight: 600 !important; /* font-semibold */
  background: transparent !important;
  border-radius: 0 !important;
  border: none !important;
  padding: 0 !important;
  margin: 0 !important;
  text-transform: none !important;
  text-decoration: none !important;
  transition: color 0.3s ease, transform 0.3s ease !important;
}

#main-header a:hover,
#main-header .navbar a:hover,
#main-header .navbar-nav a:hover,
#main-header .navbar ul li a:hover,
#main-header details summary:hover {
  color: rgb(15, 23, 42) !important; /* text-slate-900 */
  background: transparent !important;
  text-decoration: none !important;
  transform: scale(1.05) !important;
  -webkit-transform: scale(1.05) !important;
}

/* Eliminar el subrayado en enlaces del logo */
#main-header a.group,
#main-header .navbar-brand,
#main-header .group {
  text-decoration: none !important;
}

#main-header a.group:hover,
#main-header .navbar-brand:hover {
  text-decoration: none !important;
  transform: none !important;
  -webkit-transform: none !important;
}

/* Botón primario del menú - override completo */
#main-header .ce-btn-primary,
#main-header a.ce-btn-primary,
#main-header .navbar-nav .ce-btn-primary {
  background: linear-gradient(135deg, #40a6d4 0%, #3596c4 100%) !important;
  color: white !important;
  padding: 0.625rem 1.25rem !important;
  border-radius: 0.75rem !important;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1) !important;
  text-decoration: none !important;
}

#main-header .ce-btn-primary:hover,
#main-header a.ce-btn-primary:hover {
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1) !important;
  text-decoration: none !important;
}

/* Fuentes específicas para el header */
#main-header,
#main-header * {
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif !important;
}

/* ======================================== */
   MENÚ MÓVIL - DETAILS Y ENLACES
   ======================================== */

/* Enlaces dentro del panel móvil (data-ce-nav-panel) */
[data-ce-nav-panel] a,
[data-ce-nav-panel] summary,
[data-ce-nav-panel] details summary {
  text-decoration: none !important;
  transform: none !important;
}

/* Enlaces dentro de detalles del menú móvil - sin subrayado ni movimiento extraño */
[data-ce-nav-panel] details a,
[data-ce-nav-panel] .group a {
  text-decoration: none !important;
}

[data-ce-nav-panel] details a:hover,
[data-ce-nav-panel] .group a:hover {
  text-decoration: none !important;
  transform: none !important;
}

/* Summary del details - sin subrayado */
summary {
  text-decoration: none !important;
  list-style: none;
}

summary::-webkit-details-marker {
  display: none;
}

summary:hover {
  text-decoration: none !important;
}

/* ======================================== */
   CLASES PERSONALIZADAS
   ======================================== */

/* Navegación */
.ce-nav {
  background: rgba(255, 255, 255, .95);
}

/* Focusable - Estilos de accesibilidad para enlaces y botones */
.ce-focusable {
  outline: 2px solid transparent;
  outline-offset: 2px;
  transition: outline-color 0.2s ease-in-out;
}

.ce-focusable:focus {
  outline-color: var(--ce-primary);
}

.ce-focusable:focus-visible {
  outline-color: var(--ce-primary);
}

/* Botón primario */
.ce-btn-primary {
  background: linear-gradient(135deg, #40a6d4 0%, #3596c4 100%);
  color: white !important;
  font-weight: 600;
  border: none;
  position: relative;
  overflow: hidden;
  text-decoration: none !important;
}

/* Enlaces con clase ce-btn-primary - eliminar estilos de enlace */
a.ce-btn-primary,
a.ce-btn-primary:link,
a.ce-btn-primary:visited {
  color: white !important;
  text-decoration: none !important;
}

a.ce-btn-primary:hover,
a.ce-btn-primary:focus,
a.ce-btn-primary:active {
  color: white !important;
  text-decoration: none !important;
}

.ce-btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}

.ce-btn-primary:hover::before {
  left: 100%;
}

.ce-btn-primary:hover {
  background: linear-gradient(135deg, #3596c4 0%, #2986b4 100%);
}

.ce-btn-primary:active {
  transform: scale(0.98);
}

/* Botón secundario */
.ce-btn-secondary {
  background: white;
  color: var(--ce-primary) !important;
  border: 2px solid var(--ce-primary);
  font-weight: 600;
  transition: all 0.3s ease;
  text-decoration: none !important;
}

/* Enlaces con clase ce-btn-secondary - eliminar estilos de enlace */
a.ce-btn-secondary,
a.ce-btn-secondary:link,
a.ce-btn-secondary:visited {
  color: var(--ce-primary) !important;
  text-decoration: none !important;
}

a.ce-btn-secondary:hover,
a.ce-btn-secondary:focus,
a.ce-btn-secondary:active {
  color: white !important;
  text-decoration: none !important;
}

.ce-btn-secondary:hover {
  background: var(--ce-primary);
  color: white !important;
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(64, 166, 212, 0.3);
}

/* ======================================== */
   FORMULARIOS - SELECT Y OPTIONS
   ======================================== */

/* Cards */
.ce-card {
  background: white;
  border: 1px solid rgba(0, 0, 0, .08);
  border-radius: 16px;
  padding: 1.25rem;
  box-shadow: 0 8px 30px rgba(15, 23, 42, .06);
  transition: all 0.3s ease;
}

.ce-card:hover {
  box-shadow: 0 12px 40px rgba(15, 23, 42, .12);
  transform: translateY(-4px);
}

/* Card con gradiente */
.ce-card-gradient {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border: 1px solid rgba(0, 0, 0, .05);
  border-radius: 16px;
  padding: 2rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.ce-card-gradient:hover {
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
  transform: translateY(-5px);
}

/* Hero section */
.ce-hero {
  background: 
    radial-gradient(1200px 500px at 20% 0%, rgba(93, 170, 255, .45), transparent 60%),
    radial-gradient(900px 500px at 80% 20%, rgba(145, 88, 255, .35), transparent 60%),
    linear-gradient(180deg, #0a1020 0%, #060a13 100%);
  color: white;
}

.ce-hero-content {
  padding: 5.5rem 0 4rem;
}

/* Pills / Badges */
.ce-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .18);
  background: rgba(255, 255, 255, .08);
  font-size: 0.9rem;
}

/* Sección alternativa */
.ce-section-alt {
  background: #f6f7fb;
}

/* Banner */
.ce-banner {
  display: flex;
  gap: 12px;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(255, 255, 255, .06);
  border-radius: 14px;
  padding: 0.75rem;
}

.ce-banner-img {
  width: 54px;
  height: 54px;
  border-radius: 12px;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(255, 255, 255, .12);
}

.ce-banner-body {
  flex: 1;
  min-width: 0;
}

/* Precio */
.ce-price-sign {
  font-weight: 700;
  color: var(--ce-primary);
}

.ce-price {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1;
}

/* Footer */
.ce-footer {
  background: #0a1020;
  color: white;
}

/* ========================================
   ANIMACIONES PERSONALIZADAS
   ======================================== */

@keyframes slideInFromTop {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-in {
  animation: slideInFromTop 0.3s ease-out;
}

.fade-in {
  animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.slide-in-from-top-2 {
  animation: slideInFromTop 0.2s ease-out;
}

/* ========================================
   UTILIDADES ADICIONALES
   ======================================== */

/* Scroll suave */
html {
  scroll-behavior: smooth;
}

/* Ocultar scrollbar pero mantener funcionalidad */
.scrollbar-hide::-webkit-scrollbar {
  display: none;
}

.scrollbar-hide {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* Backdrop blur fallback */
@supports not (backdrop-filter: blur(10px)) {
  .backdrop-blur-xl {
    background-color: rgba(255, 255, 255, 0.95) !important;
  }
}

/* ========================================
   RESPONSIVE
   ======================================== */

@media (max-width: 640px) {
  .ce-hero-content {
    padding: 3rem 0 2rem;
  }
  
  .ce-price {
    font-size: 1.5rem;
  }
  
  .ce-card {
    padding: 1rem;
  }
}

/* ========================================
   TRANSICIONES SUAVES (solo para elementos del header)
   ======================================== */

#main-header * {
  transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

/* Prevenir transiciones en carga inicial */
.preload * {
  transition: none !important;
}
