/* --- CONFIGURACIÓN BASE --- */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;700&display=swap');

:root {
    --accent-color: #d4ff00; /* Lima para fondos oscuros */
    --accent-hover: #ff6600; 
    --accent-dark: #0a5a1a;  /* NUEVO: Verde bosque profundo para legibilidad en blanco */
    --text-dark: #121212;
    --verde-delgado: #0d4a1a;
    --text-opc-footer: #afb4b9;
    --secondary: #afb4b9;
}

body { font-family: 'Montserrat', sans-serif; }

.h2, h2 {
    font-size: calc(1rem + .9vw) !important;
}

/* Alineación perfecta de items y separador */
.breadcrumb-item {
    display: flex;
    align-items: center;
    z-index: 1;
}

/* El separador (Chevron) */
.breadcrumb-item + .breadcrumb-item::before {
    display: inline-block;
    content: "\F285"; /* Chevron right de Bootstrap Icons */
    font-family: "bootstrap-icons";
    font-size: 0.7rem;
    color: #1a3a00; /* Verde oscuro */
    padding-right: 0.5rem;
    line-height: 1;
}

/* Links (Inicio y Categorías intermedias) */
.breadcrumb-item a {
    color: #6c757d;
    transition: color 0.2s ease;
    z-index: 1060;
}

.breadcrumb-item a:hover {
    color: #1a3a00 !important;
    text-decoration: underline !important;
}

/* Página Activa (Naranja Nerox) */
.breadcrumb-item.active {
    color: #ff8a00 !important;
    font-weight: 500;
}

/* Ajuste para el icono de la casita */
.breadcrumb-item i.bi-house-door {
    margin-right: 4px;
    font-size: 0.9rem;
}

/* --- NAVBAR Y NAVEGACIÓN (CORREGIDO) --- */
/* Color para todas las pestañas */
.nav-tabs-mobile .nav-link {
    color: #4f6274e7;
    border: none; /* Quitamos bordes laterales */
    border-bottom: 3px solid transparent; /* Reservamos el espacio para la línea */
    transition: all 0.3s ease;
}

/* Color al pasar el mouse */
.nav-tabs-mobile .nav-link:hover {
    color: var(--accent-hover);
    border-bottom: 3px solid #e9ecef;
}

/* Color y línea para la pestaña SELECCIONADA (.active) */
.nav-tabs-mobile .nav-link.active {
    color: var(--accent-hover) !important;
    background-color: transparent !important; /* Evita el fondo blanco de Bootstrap */
    border: none !important;
    border-bottom: 3px solid var(--accent-hover) !important; /* Línea de color activa */
}

.navbar { z-index: 1030 !important; transition: all 0.3s ease; }

.navbar-nav .nav-link {
    font-weight: 500;
    margin: 0 10px;
    position: relative;
    padding-bottom: 8px; /* Espacio para la línea */
}

/* Efecto de línea animada para enlaces normales */
.navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

.navbar-nav .nav-link:hover::after,
.navbar-nav .nav-link.active::after {
    width: 100%;
}

/* Color especial para el texto activo (opcional, para resaltar más) */
.navbar-nav .nav-link.active {
    color: var(--accent-color) !important;
    font-weight: 700;
}
/* Aseguramos que en el dropdown de Bicicletas también se note si estamos ahí */
.nav-link.dropdown-toggle.active::after {
    width: 100%;
}
accent-dark
/* EXCEPCIÓN: Quitar línea verde del menú de USUARIO y de BICICLETAS (Dropdowns) */
#userDropdown::before,
#navbarDropdown::before {
    display: none !important;
    content: none !important;
}
#navbarDropdown::after, 
#userDropdown::after {
    display: inline-block !important; /* Volvemos a mostrarlo pero... */
    content: none !important;        /* ... quitamos el dibujo de la flecha */
    border: none !important;         /* Eliminamos los bordes que forman el triángulo */
    margin: 0 !important;
}

/* --- ELEMENTOS DE INTERFAZ --- */
.text-primary { color: var(--accent-dark) !important; }/* Por defecto, usamos el oscuro para que se lea siempre */
.text-secondary { color: var(--secondary) !important; }
.text-opc-footer { color: var(--text-opc-footer) !important; }

/* Creamos una clase específica para cuando el texto está sobre fondo oscuro (Hero/Footer)*/
.hero-section .text-primary, 
footer .text-primary,
.bg-dark .text-primary {
    color: var(--accent-color) !important; /* Aquí sí usamos el lima brillante
} 

.bg-dark .text-primary {
    color: var(--accent-color) !important; /* Aquí sí usamos el lima brillante*/
} 

.btn-primary {
    background-color: var(--accent-color) !important;
    /* border-color: var(--accent-color) !important; Borde igual al fondo inicial */
    border-color: #b4d707 !important;
    color: var(--text-dark) !important;
    font-weight: 600;
    padding: 0.5rem 1.5rem;
    border-radius: 10px;
    transition: all 0.3s ease;
}
.btn-primary:hover {
    background-color: var(--accent-hover) !important; /* El naranja que definimos */
    border-color: var(--accent-hover) !important;     /* El borde ahora sigue al naranja */
    color: white !important;                          /* Texto blanco para mejor contraste en naranja */
    transform: translateY(-2px);                      /* Efecto sutil de elevación */
    box-shadow: 0 4px 15px rgba(255, 102, 0, 0.3);    /* Sombra naranja suave */
}
.btn-outline-primary {
    color: var(--accent-dark);
    border-color: var(--accent-dark);
}

.btn-outline-primary:hover {
    background-color: var(--accent-dark);
    border-color: var(--accent-dark);
    color: white;
}
.badge-cart {
    background-color: var(--accent-color) !important;
    color: #000 !important;
    font-weight: bold;
    position: absolute;
    top: -5px;
    right: -5px;
}

/* DataTables: Espaciado entre controles (Mostrar/Buscar) y la tabla */
.dataTables_wrapper .dataTables_length, 
.dataTables_wrapper .dataTables_filter {
    margin-bottom: 25px !important;
}

/* --- SECCIÓN HERO --- */
.hero-section {
    position: relative;
    min-height: 85vh;
    padding: 100px 0;
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.4)), 
                url('https://images.pexels.com/photos/276517/pexels-photo-276517.jpeg?auto=compress&cs=tinysrgb&w=1260&h=750&dpr=2'); 
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.hero-section .lead {
    color: #eaeff3 !important;
    font-size: 1.25rem;
    max-width: 650px;
}

/* --- PRODUCTOS Y CARDS --- */
.precio-destacado {
    color: var(--accent-dark); /* Ahora es legible y elegante */
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.product-section-bg {
/* Un gris nube muy sofisticado (Slate 50/100) */
    background-color: #d8dadd; 
    /* Degradado lineal muy suave para dar volumen */
    background-image: linear-gradient(180deg, #f8fafc 0%, #e2e5e9 100%);
    /* Separación sutil */
    border-top: 1px solid #e2e8f0;
    padding-top: 5rem;
    padding-bottom: 5rem;
}
.card-hover {
    border: none !important;
    background-color: #ffffff;
    /* Sombra más ligera y dispersa */
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05) !important;
}
.card-hover:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.08) !important;
}

.precio-destacado {
    color: var(--verde-delgado);
    font-size: 2rem;
    font-weight: 800;
}

/* --- DROPDOWNS Y MODALES --- */


/* Ajuste específico para el menú de usuario (Dropdown) */
.dropdown-item i {
    width: 20px;
    margin-right: 10px;
    transition: margin 0.2s;
}

.dropdown-menu {
    font-size: 1.1rem; /* Un poco más de presencia */
    transition: transform 0.2s ease;
    z-index: 2000 !important;
    min-width: 220px;     /* Un ancho mínimo generoso */
    overflow: hidden;     /* Evita que el contenido que "se mueve" genere barras de scroll */
    border-radius: 15px;
    padding: 0.8rem 0;    /* Espaciado vertical uniforme */
    white-space: nowrap;  /* Evita que el texto salte a otra línea */
    border: none;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}
.dropdown-item {
    padding: 10px 20px;
    font-size: 0.9rem;
    transition: background-color 0.2s, color 0.2s, transform 0.2s ease-in-out;
    display: flex;
    align-items: center;
    color: var(--text-dark);
}
.dropdown-item:hover {
    background-color: #f8f9fa;
    transform: translateX(5px);
}

/* Como el menú de usuario tiene el nombre arriba, evitamos que ese texto se mueva */
.dropdown-menu li div.px-3.py-2 {
    white-space: nowrap; /* Evita que el nombre del usuario salte de línea */
}
/* Forzar el color oscuro en iconos de dropdown, incluso si tienen clases de Bootstrap */
.dropdown-menu .dropdown-item i.text-primary,
.dropdown-menu .dropdown-item i {
    color: var(--accent-dark) !important;
}

/* Para que al pasar el mouse se vea el cambio a naranja */
.dropdown-item:hover i,
.dropdown-item:hover i.text-primary {
    color: var(--accent-hover) !important;
}

.toast {
    backdrop-filter: blur(10px);
    background-color: rgba(25, 135, 84, 0.9) !important;
    border-radius: 15px;
}

/* --- FOOTER --- */
.footer-links a {
    color: #eaeff3;
    text-decoration: none;
    transition: all 0.3s ease;
}
.footer-links a:hover { color: var(--accent-color); padding-left: 5px; }

.social-icon {
    width: 40px; height: 40px;
    background-color: rgba(255,255,255,0.05);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: white; transition: all 0.3s ease;
}
.social-icon:hover { background-color: var(--accent-color); color: #000; transform: translateY(-3px); }

/* --- RESPONSIVO --- */
@media (max-width: 991px) {
    .navbar-nav { text-align: center; }
    .nav-link { margin: 10px 0; }
}

.border-dashed {
    border: 2px dashed #dee2e6;
    transition: all 0.3s ease;
}

.border-dashed:hover {
    border-color: #ff6600;
    background-color: rgba(255, 102, 0, 0.05) !important;
}

.form-control:focus, .form-select:focus {
    border-color: #ff6600;
    box-shadow: 0 0 0 0.25rem rgba(255, 102, 0, 0.15);
}

.form-check-input:checked {
    background-color: #ff6600;
    border-color: #ff6600;
}