/* ==========================================================================
   VARIABLES Y CONFIGURACIÓN GENERAL
   ========================================================================== */
:root {
    --primary: #dc2626; 
    --primary-dark: #b91c1c;
    --dark: #1e293b;
    --light: #f8fafc;
    --white: #ffffff;
    --text-main: #334155;
    --text-muted: #64748b;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --radius: 12px;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--text-main);
    background-color: var(--white);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.section {
    padding: 5rem 0;
}

.bg-light {
    background-color: var(--light);
}

.section-title {
    text-align: center;
    margin-bottom: 3.5rem;
}

.section-title h2 {
    font-size: 2.25rem;
    color: var(--dark);
    margin-bottom: 0.75rem;
}

.section-title p {
    font-size: 1.1rem;
    color: var(--text-muted);
}

/* ==========================================================================
   CABECERA Y NAVEGACIÓN
   ========================================================================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--white);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: var(--transition);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 80px;
}
/* Selector de Idioma (ES / EN) */
.lang-switch {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: var(--text-muted);
}

.lang-btn {
    background: none;
    border: none;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition);
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
}

.lang-btn.active, .lang-btn:hover {
    color: var(--primary);
    background-color: rgba(220, 38, 38, 0.1);
}
.logo {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    text-decoration: none;
}

.logo-img {
    height: 55px;
    width: auto;
    object-fit: contain;
    display: block;
}

.logo-text {
    display: flex;
    flex-direction: column;
    line-height: 0.95;
    text-transform: none;
}

/* CARBURANTES: Azul, alargado, en mayúsculas */
.brand-carburantes {
    font-family: 'Oswald', sans-serif;
    color: #0b579d; 
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

/* Filabres: Rojo corporativo y redondeado */
.brand-filabres {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    color: #dc2626; 
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.3px;
}

.logo i {
    color: var(--primary);
}

.nav-menu ul {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 600;
    transition: var(--transition);
}

.nav-menu a:hover {
    color: var(--primary);
}

.btn-primary {
    background-color: var(--primary);
    color: var(--white);
    padding: 0.65rem 1.25rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--dark);
}

/* ==========================================================================
   SECCIÓN HERO / INICIO CON FOTO REAL
   ========================================================================== */
.hero {
    position: relative;
    background-image: url('../assets/img/imagengaso.jpeg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    color: var(--white);
    padding: 10rem 1rem 8rem;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 85vh;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.55);
    z-index: 1;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    z-index: 2;
    position: relative;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background-color: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(5px);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.hero h1 {
    font-size: 3.2rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    text-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

.hero p {
    font-size: 1.2rem;
    color: #f1f5f9;
    margin-bottom: 2.5rem;
    line-height: 1.6;
    text-shadow: 0 1px 5px rgba(0,0,0,0.3);
}

.btn-light {
    background-color: var(--white);
    color: var(--dark);
    padding: 0.8rem 1.75rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-light:hover {
    background-color: var(--light);
    transform: translateY(-2px);
}

/* ==========================================================================
   TARJETAS Y SERVICIOS
   ========================================================================== */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.card {
    background-color: var(--white);
    padding: 2.5rem 2rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    transition: var(--transition);
    border-top: 4px solid var(--primary);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.card-icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.card h3 {
    font-size: 1.4rem;
    color: var(--dark);
    margin-bottom: 1rem;
}

.card p {
    color: var(--text-muted);
    line-height: 1.6;
}

/* Botón de galería en tarjetas */
.btn-gallery {
    margin-top: 1.25rem;
    background-color: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

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

/* ==========================================================================
   MODAL Y GALERÍA DE PRODUCTOS
   ========================================================================== */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(5px);
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background-color: var(--white);
    padding: 2.5rem;
    border-radius: var(--radius);
    max-width: 900px;
    width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.close-modal {
    position: absolute;
    top: 1.25rem;
    right: 1.5rem;
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition);
}

.close-modal:hover {
    color: var(--primary);
}

.modal-content h3 {
    margin-bottom: 1.5rem;
    font-size: 1.6rem;
    color: var(--dark);
}

.modal-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.modal-gallery-grid img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    transition: var(--transition);
    cursor: pointer;
}

.modal-gallery-grid img:hover {
    transform: scale(1.03);
}

/* Visor de Zoom individual */
.image-zoom-modal {
    display: none;
    position: fixed;
    z-index: 3000;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    align-items: center;
    justify-content: center;
    cursor: zoom-out;
}

.image-zoom-modal img {
    max-width: 90%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 0 25px rgba(255, 255, 255, 0.2);
}

/* ==========================================================================
   MAPA Y CONTACTO
   ========================================================================== */
.map-container {
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

/* ==========================================================================
   BOTONES FLOTANTES DESPLEGABLES (REDES SOCIALES)
   ========================================================================== */
.social-float-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 1000;
    display: flex;
    flex-direction: column-reverse;
    align-items: center;
}

.whatsapp-float {
    background-color: #25d366;
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
    border: none;
    cursor: pointer;
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    background-color: #20ba5a;
}

.social-float-menu {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.social-float-container:hover .social-float-menu,
.social-float-container.active .social-float-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.float-item {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.4rem;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s ease;
    text-decoration: none;
}

.float-item:hover {
    transform: scale(1.1);
}

.float-item.whatsapp {
    background-color: #25d366;
}

.float-item.facebook {
    background-color: #1877f2;
}

/* ==========================================================================
   FOOTER MEJORADO Y MULTI-COLUMNA
   ========================================================================== */
.footer {
    background-color: #0f172a; /* Fondo oscuro elegante */
    color: #94a3b8;
    padding-top: 4rem;
    border-top: 4px solid var(--primary);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.5rem;
    margin-bottom: 2rem;
}

/* En pantallas móviles se adapta a una sola columna */
@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

.footer-col h4 {
    color: var(--white);
    font-size: 1.15rem;
    margin-bottom: 1.25rem;
    position: relative;
}
footer#mapa {
    scroll-margin-top: 80px;
}

.footer-col h4::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 0;
    width: 35px;
    height: 3px;
    background-color: var(--primary);
    border-radius: 2px;
}

.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    margin-bottom: 1rem;
}
.footer-logo-img {
    background-color: #ffffff;
    border-radius: 50%;
    padding: 2px;
}
.footer-col p {
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

.footer-col p i {
    color: var(--primary);
    margin-top: 0.25rem;
}

.footer-col p a {
    color: #94a3b8;
    text-decoration: none;
    transition: var(--transition);
}

.footer-col p a:hover {
    color: var(--white);
}

.footer-col ul {
    list-style: none;
    padding: 0;
}

.footer-col ul li {
    margin-bottom: 0.6rem;
}

.footer-col ul a {
    color: #94a3b8;
    text-decoration: none;
    transition: var(--transition);
    font-size: 0.95rem;
}

.footer-col ul a:hover {
    color: var(--primary);
    padding-left: 4px;
}

.highlight-text {
    color: #22c55e ;
    font-weight: 600;
}

/* Iconos de redes en footer */
.footer-social-links {
    display: flex;
    gap: 0.75rem;
    margin-top: 1.25rem;
}

.footer-social-links a {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.08);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: var(--transition);
}

.footer-social-links a:hover {
    background-color: var(--primary);
    transform: translateY(-3px);
}

/* Barra inferior */
.footer-bottom {
    background-color: #020617;
    width: 100%;
    padding: 1.25rem 0;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-bottom p {
    margin: 0;
    color: #64748b;
    font-size: 0.9rem;
    text-align: center;
    width: 100%;
}

/* Adaptación para móviles */
@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

/* ==========================================================================
   DISEÑO RESPONSIVO (MÓVILES)
   ========================================================================== */
@media (max-width: 768px) {
    .nav-menu {
        position: absolute;
        top: 80px;
        left: -100%;
        width: 100%;
        background-color: var(--white);
        box-shadow: 0 10px 15px rgba(0,0,0,0.1);
        transition: var(--transition);
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-menu ul {
        flex-direction: column;
        padding: 2rem;
        gap: 1.5rem;
        text-align: center;
    }

    .menu-toggle {
        display: block;
    }

    .hero h1 {
        font-size: 2.4rem;
    }

    .hero p {
        font-size: 1rem;
    }
}
/* ==========================================================================
   AJUSTES ESPECÍFICOS PARA MÓVIL
   ========================================================================== */
@media (max-width: 768px) {
    /* Contenedor de la cabecera */
    .nav-container {
        padding: 0 1rem;
        gap: 0.5rem;
    }

    /* Logo adaptado para pantallas pequeñas */
    .logo-img {
        height: 42px; 
    }

    .brand-carburantes {
        font-size: 1rem;
    }

    .brand-filabres {
        font-size: 1.1rem;
    }

    /* Ocultar el botón rojo 'Cómo Llegar' de la cabecera solo en móviles para dar espacio */
    .nav-container > .btn-primary {
        display: none;
    }

    /* Ajustar selector de idiomas en móvil */
    .lang-switch {
        font-size: 0.85rem;
        gap: 0.25rem;
    }

    .lang-btn {
        padding: 0.1rem 0.3rem;
        font-size: 0.85rem;
    }

    /* Botón hamburguesa bien posicionamiento */
    .menu-toggle {
        display: block;
        font-size: 1.4rem;
        padding: 0.4rem;
        color: var(--dark);
    }

    /* Menú desplegable móvil */
    .nav-menu {
        position: absolute;
        top: 80px;
        left: -100%;
        width: 100%;
        background-color: var(--white);
        box-shadow: 0 10px 15px rgba(0,0,0,0.1);
        transition: var(--transition);
        z-index: 999;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-menu ul {
        flex-direction: column;
        padding: 1.5rem;
        gap: 1.25rem;
        text-align: center;
    }

    /* Ajuste de textos en el Hero para que no ocupen toda la pantalla */
    .hero h1 {
        font-size: 2.1rem;
    }

    .hero p {
        font-size: 0.98rem;
    }

    /* Estilo para la descripción dentro de los modales de galería */
.modal-description-text {
    margin-top: 1.5rem;
    padding: 1rem 1.25rem;
    background-color: #f1f5f9;
    border-left: 4px solid var(--primary);
    border-radius: 6px;
    font-size: 0.98rem;
    color: var(--text-main);
    line-height: 1.6;
}

.modal-description-text i {
    color: var(--primary);
    margin-right: 0.5rem;
}
}