/* ========================================= */
/* --- ESTILOS DE LA PÁGINA DE SERVICIOS --- */
/* ========================================= */

body.dark-theme {
    background-color: #0b1320; 
    color: white;
    font-family: 'Helvetica Neue', Arial, sans-serif;
}

/* --- HERO BANNER --- */
.hero-servicios {
    height: 45vh;
    min-height: 350px;
    background: linear-gradient(to bottom, rgba(11, 19, 32, 0.4), rgba(11, 19, 32, 1)), 
                url('https://images.unsplash.com/photo-1492684223066-81342ee5ff30?auto=format&fit=crop&q=80'); 
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 40px;
    text-align: center;
    padding-top: 80px; 
}

.hero-servicios-content {
    padding: 0 20px;
}

.hero-servicios-content h1 {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    color: #ffd700; 
    margin-bottom: 10px;
    text-shadow: 0 4px 15px rgba(0,0,0,0.8);
}

.hero-servicios-content p {
    font-size: 1.2rem;
    color: #e0e0e0;
    max-width: 600px;
    margin: 0 auto;
}

/* --- FILTROS (Efecto Píldora) --- */
.contenedor-filtros-servicios {
    padding: 15px 0;
    position: sticky;
    top: 60px; /* Se queda pegado justo debajo de la navbar */
    z-index: 100;
    background: rgba(11, 19, 32, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.filtros-scroll {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding: 5px 20px;
    justify-content: center;
    max-width: 1000px;
    margin: 0 auto;
    scroll-snap-type: x mandatory;
}

.filtros-scroll::-webkit-scrollbar { display: none; }

.btn-filtro-servicio {
    scroll-snap-align: center;
    padding: 10px 22px;
    border-radius: 30px;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    color: #ccc;
    font-size: 0.85rem;
    font-weight: bold;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.3s;
}

.btn-filtro-servicio:hover { background: rgba(255,255,255,0.15); }

.btn-filtro-servicio.activo {
    background: #4a90e2; 
    color: white;
    border-color: #4a90e2;
    box-shadow: 0 0 15px rgba(74, 144, 226, 0.4);
}

/* --- GRID DE TARJETAS --- */
.contenedor-catalogo-servicios {
    padding: 40px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.grid-servicios {
    display: grid;
    /* Esto hace la magia responsiva: crea columnas de min 280px */
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

/* --- TARJETA INDIVIDUAL --- */
.tarjeta-servicio {
    background: #1a2639;
    border-radius: 16px;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid rgba(255,255,255,0.05);
    display: flex;
    flex-direction: column;
}

.tarjeta-servicio:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.5);
    border-color: rgba(255, 215, 0, 0.3);
}

.img-servicio {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.info-servicio {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex: 1; 
}

.tag-categoria {
    font-size: 0.7rem;
    color: #4a90e2;
    text-transform: uppercase;
    font-weight: bold;
    margin-bottom: 8px;
    letter-spacing: 1px;
}

.info-servicio h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: white;
}

.desc-servicio {
    font-size: 0.9rem;
    color: #aaa;
    line-height: 1.5;
    margin-bottom: 20px;
    flex: 1;
}

.precio-servicio {
    font-size: 1.1rem;
    color: #ffd700;
    font-weight: bold;
    margin-bottom: 15px;
}

/* Botón llamativo tipo carrito */
.btn-agregar-servicio {
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    background: #4a90e2;
    color: white;
    border: none;
    font-weight: bold;
    font-size: 1rem;
    cursor: pointer;
    transition: 0.3s;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.btn-agregar-servicio:hover {
    background: #357abd;
}

/* ========================================= */
/* --- AJUSTES ESPECÍFICOS PARA MÓVILES  --- */
/* ========================================= */
@media (max-width: 768px) {
    /* El banner es más corto para que se vean los productos rápido */
    .hero-servicios {
        height: 35vh;
        min-height: 280px;
        padding-bottom: 20px;
    }

    .hero-servicios-content h1 {
        font-size: 2.2rem;
    }

    .hero-servicios-content p {
        font-size: 1rem;
    }

    /* Los filtros se alinean a la izquierda para invitar a hacer scroll */
    .filtros-scroll {
        justify-content: flex-start;
        padding: 5px 15px;
    }

    /* Reducimos el padding general para aprovechar la pantalla */
    .contenedor-catalogo-servicios {
        padding: 25px 15px;
    }

    /* Las tarjetas se apilan a 1 sola columna ocupando todo el ancho */
    .grid-servicios {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

/* ========================================= */
/* --- MENÚ HAMBURGUESA Y SIDEBAR --- */
/* ========================================= */

.nav-left {
    display: flex;
    align-items: center;
    gap: 15px; /* Separación entre las rayas y el logo FLOM */
}

.hamburger-btn {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.3s;
    padding: 5px; /* Área táctil más grande */
}

.hamburger-btn:hover {
    color: #4a90e2; /* Azul FLOM */
}

/* El fondo negro transparente que tapa la página */
.sidebar-overlay {
    position: fixed;
    top: 0; 
    left: 0; 
    width: 100vw; 
    height: 100vh;
    background: rgba(0,0,0,0.7);
    z-index: 2999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.sidebar-overlay.activo {
    opacity: 1;
    visibility: visible;
}

/* El cajón del menú que sale de la izquierda */
.sidebar-menu {
    position: fixed;
    top: 0; 
    left: -300px; /* Escondido fuera de la pantalla por defecto */
    width: 280px;
    height: 100vh;
    background: #111;
    z-index: 3000;
    transition: left 0.3s ease;
    box-shadow: 5px 0 20px rgba(0,0,0,0.8);
    display: flex;
    flex-direction: column;
}

.sidebar-menu.activo {
    left: 0; /* Lo metemos a la pantalla */
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.sidebar-header h2 { 
    color: white; 
    margin: 0; 
    font-size: 1.2rem;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.close-sidebar {
    background: none; 
    border: none; 
    color: #aaa;
    font-size: 2rem; 
    cursor: pointer;
    transition: 0.3s;
}

.close-sidebar:hover { color: white; }

.sidebar-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-links li {
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.sidebar-links a {
    display: flex;
    align-items: center;
    padding: 20px 25px;
    color: #ccc;
    text-decoration: none;
    font-size: 1.1rem;
    transition: all 0.3s;
    gap: 15px;
}

.sidebar-links a i {
    width: 25px; 
    text-align: center;
    color: #4a90e2; /* Íconos en azul */
}

.sidebar-links a:hover {
    background: rgba(74, 144, 226, 0.1);
    color: white;
    padding-left: 30px; /* Efecto de moverse un poquito a la derecha al pasar el mouse */
}

/* ========================================= */
/* --- AJUSTE CELULAR PARA EL MENÚ --- */
/* ========================================= */
@media (max-width: 768px) {
    /* Como agrupamos el logo y las barras, les decimos que ellos dos van a la izquierda */
    .nav-left { 
        order: 1 !important; 
        margin-right: auto !important; 
    }
    
    /* Le quitamos el margin al logo que habíamos puesto antes para que no se separe feo de las barras */
    .logo-nav { 
        margin-right: 0 !important; 
    }
}

/* ========================================= */
/* --- NOTIFICACIÓN VERDE (TOAST) --- */
/* ========================================= */
#toast-notificacion {
    visibility: hidden;
    min-width: 250px;
    background-color: #2ecc71; /* Verde FLOM */
    color: white;
    text-align: center;
    border-radius: 50px;
    padding: 15px 25px;
    position: fixed;
    z-index: 9999;
    right: 30px;
    bottom: 30px;
    font-size: 1rem;
    font-weight: bold;
    box-shadow: 0 5px 15px rgba(46, 204, 113, 0.4);
    opacity: 0;
    transition: opacity 0.4s ease, bottom 0.4s ease;
}

#toast-notificacion.mostrar {
    visibility: visible;
    opacity: 1;
    bottom: 50px; /* Hace un saltito hacia arriba al aparecer */
}

/* Ajuste en celular para que salga en el centro y no estorbe al botón de WhatsApp */
@media (max-width: 768px) {
    #toast-notificacion {
        right: 50%;
        transform: translateX(50%); /* Centrado perfecto */
        min-width: 80%;
        bottom: 80px; /* Más arriba por el botón flotante */
    }
    #toast-notificacion.mostrar {
        bottom: 100px; 
    }
}