/**
* Template Name: OnePage - Ecommerce Automotora
* Updated: Enero 2026 - Modularizado
* Estructura: CSS Variables + Imports modulares
* 
* ============================================
* IMPORTANTE: Este archivo es SOLO para el área PÚBLICA
* ============================================
* - Rutas: /, /productos, /carrito, etc.
* - Layout: resources/views/layouts/public.blade.php
* - Header: resources/views/layouts_public/header.blade.php
* 
* Para el área de ADMINISTRADOR (/Administrador/*):
* - Usar: css/admin/dashboard.css y css/style_admin.css
* - Layout: resources/views/layouts/admin.blade.php
* ============================================
*/

/*--------------------------------------------------------------
# Import Modular CSS Files (MUST be at top before any rules)
--------------------------------------------------------------*/
@import url('components/navigation.css');
@import url('components/modals.css');
@import url('components/footer.css');
@import url('components/ecommerce.css');
@import url('components/offers.css');
@import url('utilities.css');
@import url('responsive.css');

/*--------------------------------------------------------------
# CSS Variables (Design Tokens)
--------------------------------------------------------------*/
:root {
    /* Colores principales */
    --primary-green: #24b540;
    --primary-white: #fff;
    --dark-green: #004a19;
    
    /* Colores secundarios */
    --header-border-boton: #e6f2fb;
    --header-logo-a: #16507b;
    --a-hover: #469fdf;
    --preloader-before-border: #2487ce;
    --color-azul-raro: #3194db;
    
    /* Sombras */
    --box-shadow: rgba(18, 66, 101, 0.08);
    --box-shadow-dropdown: rgba(127, 137, 161, 0.25);
    
    /* Fondos */
    --movile-focus: #124265;
    --navbar-movile-background: rgba(10, 38, 58, 0.9);
    --hero-before-background: rgba(255, 255, 255, 0.8);
    --hero-h2: #004a19;
    --blanco-gris: #f8fbfe;
    --testimonials: #f3f9fd;
    
    /* Colores de íconos */
    --services-icon: #47aeff;
    --icon-box-oranage: #ffa76e;
    --icon-pink: #e80368;
    --icon-yellow: #ffbb2c;
    --iconred-i: #ff5828;
    --iconbox-teal: #11dbcf;
    
    /* Colores de texto */
    --porfolio: #444444;
    --body: var(--porfolio);
    --details: #eee;
    --team: #777777;
    --contact: #18d26e;
    
    /* Otros */
    --swiper-navigation-color: #f0f0f0;
}

/*--------------------------------------------------------------
# Base Styles
--------------------------------------------------------------*/
body {
    font-family: "Open Sans", sans-serif;
    color: var(--body);
}

a {
    color: var(--preloader-before-border);
    text-decoration: none;
}

a:hover {
    color: var(--a-hover);
    text-decoration: none;
}

h1, h2, h3, h4, h5, h6 {
    font-family: "Raleway", sans-serif;
}

/*--------------------------------------------------------------
# Header Público - Estilos Críticos (Inline para evitar FOUC)
--------------------------------------------------------------*/

/* Header Base */
#header {
    transition: all 0.5s;
    z-index: 997;
    padding: 15px 0;
    background: #ffffff;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
}

#header.header-scrolled,
#header.header-inner-pages {
    background: #ffffff;
    padding: 12px 0;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
}

/* Logo */
#header .logo {
    font-size: 30px;
    margin: 0;
    padding: 0;
    line-height: 1;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
}

#header .logo a {
    color: #124265;
}

#header .logo img {
    max-height: 50px;
}

/* Franja negra promocional */
.franja-negra {
    background: linear-gradient(90deg, #000 0%, #1a1a1a 50%, #000 100%);
    padding: 8px 0;
    overflow: hidden;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.oferta-container {
    display: flex;
    animation: scroll-left 30s linear infinite;
    white-space: nowrap;
}

.oferta-container .item {
    color: #fff;
    font-size: 13px;
    padding: 0 40px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.oferta-container .icon {
    color: #24b540;
}

@keyframes scroll-left {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

/* Desktop Navigation (public header) */
#header .navbar {
    padding: 0;
}

#header .navbar ul {
    margin: 0;
    padding: 0;
    display: flex;
    list-style: none;
    align-items: center;
}

#header .navbar li {
    position: relative;
}

#header .navbar a,
#header .navbar a:focus,
#header .navbar button.nav-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0 10px 20px;
    font-family: "Raleway", sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #124265;
    white-space: nowrap;
    transition: 0.3s;
    text-decoration: none;
}

#header .navbar a i,
#header .navbar a:focus i {
    font-size: 12px;
    line-height: 0;
    margin-left: 5px;
}

#header .navbar a:hover,
#header .navbar .active,
#header .navbar .active:focus,
#header .navbar li:hover > a {
    color: #24b540;
}

#header .navbar .getstarted,
#header .navbar .getstarted:focus {
    padding: 8px 20px;
    margin-left: 15px;
    border-radius: 50px;
    font-size: 13px;
    font-weight: 600;
    transition: 0.3s;
}

#header .navbar .getstarted:hover,
#header .navbar .getstarted:focus:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

/* Mobile Navigation Toggle */
.mobile-nav-toggle {
    color: #124265;
    font-size: 28px;
    cursor: pointer;
    display: none;
    line-height: 0;
    transition: 0.5s;
}

.mobile-nav-toggle.bi-x {
    color: #124265;
}

/* Mobile Navigation */
@media (max-width: 991px) {
    .mobile-nav-toggle {
        display: block;
    }

    #header .navbar ul {
        display: none;
    }

    #header .navbar-mobile {
        position: fixed;
        overflow: hidden;
        top: 0;
        right: 0;
        left: 0;
        bottom: 0;
        background: rgba(10, 38, 58, 0.95);
        transition: 0.3s;
        z-index: 999;
    }

    #header .navbar-mobile .mobile-nav-toggle {
        position: absolute;
        top: 15px;
        right: 15px;
    }

    #header .navbar-mobile ul {
        display: block;
        position: absolute;
        top: 55px;
        right: 15px;
        bottom: 15px;
        left: 15px;
        padding: 10px 0;
        border-radius: 8px;
        background-color: #fff;
        overflow-y: auto;
        transition: 0.3s;
    }

    #header .navbar-mobile a,
    #header .navbar-mobile a:focus {
        padding: 10px 20px;
        font-size: 15px;
        color: #124265;
    }

    #header .navbar-mobile a:hover,
    #header .navbar-mobile .active,
    #header .navbar-mobile li:hover > a {
        color: #24b540;
    }

    #header .navbar-mobile .getstarted,
    #header .navbar-mobile .getstarted:focus {
        margin: 15px;
    }
}

/* Ajuste de contenido principal por header fixed */
section:first-of-type,
.productos-section {
    padding-top: 140px !important;
}

/* Hero section adjustment */
#hero {
    padding-top: 120px;
}

/*--------------------------------------------------------------
# Modal Carrito - Estilos con alta especificidad (override Bootstrap)
--------------------------------------------------------------*/

/* Forzar posición a la derecha del modal carrito */
.modal#sideModal .modal-dialog {
    position: fixed !important;
    top: 0 !important;
    right: 0 !important;
    left: auto !important;
    bottom: 0 !important;
    margin: 0 !important;
    width: 400px !important;
    max-width: 90vw !important;
    height: 100vh !important;
    max-height: 100vh !important;
    transform: translateX(100%) !important;
    transition: transform 0.3s ease-in-out !important;
}

.modal#sideModal.show .modal-dialog {
    transform: translateX(0) !important;
}

.modal#sideModal .modal-content {
    height: 100% !important;
    border-radius: 0 !important;
    border: none !important;
    border-left: 3px solid #24b540 !important;
    box-shadow: -5px 0 25px rgba(0, 0, 0, 0.15) !important;
}

.modal#sideModal .modal-header {
    background-color: #24b540;
    color: white;
    border-bottom: 2px solid #1e9535;
    border-radius: 0;
}

.modal#sideModal .modal-header .close {
    color: white;
    opacity: 1;
    font-size: 1.5rem;
    padding: 0;
    margin: 0;
    background: transparent;
    border: none;
}

.modal#sideModal .modal-body {
    overflow-y: auto;
    flex: 1;
}

.modal#sideModal .modal-footer {
    background-color: #f8f9fa;
    border-top: 2px solid #dee2e6;
}

