/* --- 1. VARIABLES Y BASE --- */
:root {
    --primary: #111111;
    --primary-logo: #1e3a8a;
    --success: #25D366;
    --danger: #ef4444;
    --bg-light: #ffffff;
    --bg-gray: #f4f7f6;
    --text-dark: #1a1a1a;
    --border: #f0f0f0;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    --radius: 12px;
}

body {
    margin: 0;
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
}

a { text-decoration: none; }

/* --- 2. HEADER --- */
.header {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 5%;
    background: var(--bg-light);
    border-bottom: 1px solid var(--border);
    gap: 10px;
}

.logo-img { width: 120px; height: auto; }
.nombre {
    font-size: 38px;
    font-weight: 800;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--primary);
}

.header-right { width: 100%; display: flex; justify-content: center; margin-top: 10px; }
.carrito-btn {
    position: relative; background: var(--primary); color: white;
    padding: 10px 22px; border-radius: 30px; font-weight: 600;
}

.contador {
    position: absolute; top: -5px; right: -5px;
    background: var(--success); color: white;
    font-size: 11px; width: 22px; height: 22px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%; border: 2px solid white;
}

/* --- 3. BANNER / SLIDER --- */
.slider-container {
    position: relative; width: 100%; height: 450px;
    overflow: hidden; margin-bottom: 30px;
}

.slide {
    position: absolute; inset: 0; background-size: cover; background-position: center;
    opacity: 0; transition: opacity 1s ease; display: flex; align-items: center; justify-content: center;
}

.slide.active { opacity: 1; z-index: 1; }
.slide::before { content: ""; position: absolute; inset: 0; background: rgba(0, 0, 0, 0.35); }

.slide-text-container { position: relative; z-index: 2; text-align: center; color: white; padding: 20px; }
.slide-text-container h2 { font-size: 2.5rem; font-weight: 900; margin-bottom: 10px; }
.btn-promo {
    display: inline-block; background: #fff; color: #000;
    padding: 12px 30px; border-radius: 30px; font-weight: 800; margin-top: 15px;
}

/* --- 4. TIENDA Y CATEGORÍAS --- */
.contenedor-categorias { max-width: 1300px; margin: 0 auto; padding: 20px; }
.titulo-categoria {
    background: #2c3e50; color: white; padding: 10px 25px;
    border-radius: 50px; display: inline-block; margin-bottom: 25px;
    font-size: 1.1rem; font-weight: bold; box-shadow: var(--shadow);
}

.grid-productos {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 25px;
}

.card {
    background: white; border: 1px solid var(--border); border-radius: var(--radius);
    padding: 15px; text-align: center; transition: 0.3s; display: flex; flex-direction: column;
}

.card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }

.contenedor-foto-principal {
    width: 100%; height: 220px; display: flex; align-items: center; justify-content: center;
    background: #f9f9f9; border-radius: 10px; overflow: hidden;
}

.foto-principal { max-width: 100%; max-height: 100%; object-fit: contain; cursor: zoom-in; }

.galeria-miniaturas { display: flex; justify-content: center; gap: 6px; margin: 12px 0; }
.mini-foto { width: 45px; height: 45px; object-fit: cover; border: 1px solid #ddd; border-radius: 6px; cursor: pointer; }

.btn-comprar {
    background-color: var(--success); color: white; border: none;
    padding: 12px; border-radius: 8px; font-weight: bold; cursor: pointer;
}

/* --- 5. CARRITO --- */
.resumen-compra {
    background: #fff; border-radius: 16px; padding: 25px;
    max-width: 600px; margin: 30px auto; box-shadow: var(--shadow);
}

.item-carrito {
    display: flex; align-items: center; padding: 15px;
    border-bottom: 1px solid var(--border);
}

.item-carrito img { width: 70px; height: 70px; object-fit: cover; border-radius: 8px; margin-right: 15px; }

.cantidad-control { display: flex; align-items: center; gap: 15px; margin: 10px 0; }
.btn-qty {
    width: 32px; height: 32px; background: #eee; border-radius: 50%;
    display: flex; align-items: center; justify-content: center; font-weight: bold;
}

.btn-whatsapp {
    display: block; background: var(--success); color: white;
    text-align: center; padding: 18px; border-radius: 50px;
    font-weight: 800; font-size: 1.1rem; margin-top: 20px;
}

/* --- 6. PANEL ADMIN --- */
.admin-container { max-width: 1100px; margin: 20px auto; padding: 0 15px; }
.form-seccion {
    background: white; padding: 25px; border-radius: var(--radius);
    margin-bottom: 30px; border: 1px solid #ddd;
}

.admin-tabla { width: 100%; border-collapse: collapse; background: white; margin-top: 20px; }
.admin-tabla th, .admin-tabla td { padding: 15px; text-align: left; border-bottom: 1px solid #eee; }
.admin-tabla th { background: #f8f8f8; font-size: 0.85rem; text-transform: uppercase; }

.btn-negro { background: #000; color: #fff; padding: 10px 20px; border-radius: 6px; font-weight: bold; border: none; cursor: pointer; }
.btn-eliminar { background: var(--danger); color: white; padding: 6px 12px; border-radius: 4px; font-size: 0.8rem; }

/* --- 7. MODAL Y VARIOS --- */
.modal-zoom {
    display: none; position: fixed; z-index: 9999; inset: 0;
    background: rgba(0,0,0,0.9); align-items: center; justify-content: center;
}
.modal-contenido { max-width: 90%; max-height: 90%; object-fit: contain; }

.whatsapp-float {
    position: fixed; width: 60px; height: 60px; bottom: 20px; right: 20px;
    background: #25d366; border-radius: 50%; display: flex; align-items: center; justify-content: center;
    z-index: 1000; box-shadow: 2px 2px 10px rgba(0,0,0,0.3);
}

/* --- 8. RESPONSIVE --- */
@media (max-width: 768px) {
    .grid-productos { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 15px; }
    .slider-container { height: 280px; }
    .nombre { font-size: 26px; }
    .admin-tabla { display: block; overflow-x: auto; } /* Tabla scrolleable en celu */
}


/* --- 10. ADMINISTRACIÓN DE BANNERS --- */

/* Contenedor específico para el formulario de banners */
.form-banner {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.form-banner label {
    font-weight: bold;
    font-size: 0.9rem;
    color: var(--primary-logo);
    margin-bottom: -10px;
}

.form-banner input[type="text"],
.form-banner textarea,
.form-banner select {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    background-color: #fff;
}

/* Estilo para la tabla de banners cargados */
.tabla-banners-admin {
    width: 100%;
    margin-top: 20px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.preview-banner-admin {
    width: 120px;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid #eee;
}

/* Badge para indicar si tiene link o no */
.badge-link {
    background: #e2e8f0;
    color: #475569;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: bold;
}

/* Responsive para el formulario de admin */
@media (max-width: 768px) {
    .form-seccion {
        padding: 15px;
    }
    
    .btn-negro {
        width: 100%; /* Botón de agregar a pantalla completa en celu */
    }
    
    .tabla-banners-admin td {
        font-size: 0.85rem;
        padding: 10px 5px;
    }
}

/* --- 11. BOTONES DE ACCIÓN EN CARRITO --- */

/* Contenedor para centrar los botones */
.acciones-carrito {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 600px;
    margin: 20px auto;
    gap: 15px;
    padding: 0 10px;
}

/* Estilo general para ambos */
.btn-seguir, .btn-vaciar {
    flex: 1; /* Para que midan lo mismo */
    padding: 14px;
    border-radius: 10px;
    font-weight: 700;
    text-align: center;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

/* Botón Seguir Comprando (Negro/Elegante) */
.btn-seguir {
    background-color: var(--primary); /* El negro que definimos arriba */
    color: white;
}

.btn-seguir:hover {
    background-color: #333;
    transform: translateY(-2px);
}

/* Botón Vaciar Carrito (Gris con borde rojo) */
.btn-vaciar {
    background-color: #f8f9fa;
    color: var(--danger);
    border: 1px solid var(--danger);
}

.btn-vaciar:hover {
    background-color: var(--danger);
    color: white;
}

/* Ajuste para celulares */
@media (max-width: 480px) {
    .acciones-carrito {
        flex-direction: column; /* Uno arriba del otro en el celu */
    }
    .btn-seguir, .btn-vaciar {
        width: 100%;
    }
}

/* --- MEJORA FORMULARIO BANNERS ADMIN --- */

/* Contenedor del formulario */
.form-seccion form {
    display: flex;
    flex-direction: column; /* Pone un campo debajo del otro */
    gap: 15px;
    max-width: 600px; /* Para que no sea tan ancho en PC */
}

/* Estilo para los grupos de inputs */
.input-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
    text-align: left;
}

.input-group label {
    font-weight: bold;
    font-size: 0.9rem;
    color: #333;
}

/* Estilo para los cuadros de texto */
.form-seccion input[type="text"],
.form-seccion textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 8px;
    box-sizing: border-box; /* Evita que se salgan del borde */
}

/* Botón de subir banner */
.btn-subir-banner {
    background-color: #000;
    color: #fff;
    padding: 12px;
    border: none;
    border-radius: 8px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
    margin-top: 10px;
}

.btn-subir-banner:hover {
    background-color: #333;
}

.btn-quitar {
    color: var(--danger); /* El rojo que definimos arriba */
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    background: none;
    border: 1px solid var(--danger);
    padding: 5px 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-block;
    margin-top: 10px;
}

.btn-quitar:hover {
    background-color: var(--danger);
    color: white;
}

/* Ajuste para que en el item del carrito quede alineado */
.item-detalles {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
}

/* --- 13. BUSCADOR Y FILTROS POR CATEGORÍA --- */

/* Contenedor del Buscador */
.buscador {
    max-width: 600px;
    margin: 30px auto;
    padding: 0 15px;
    display: flex;
    justify-content: center;
}

.buscador form {
    display: flex;
    width: 100%;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    border-radius: 30px;
    overflow: hidden;
}

.buscador input {
    flex: 1;
    padding: 15px 25px;
    border: 2px solid var(--primary);
    border-right: none;
    border-radius: 30px 0 0 30px;
    outline: none;
    font-size: 1rem;
}

.buscador button {
    padding: 15px 30px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 0 30px 30px 0;
    cursor: pointer;
    font-weight: bold;
    font-size: 1rem;
    transition: background 0.3s;
}

.buscador button:hover {
    background: #333;
}

/* Barra de Filtros (Categorías) */
.categorias {
    display: flex;
    gap: 12px;
    justify-content: center;
    padding: 10px 15px 30px;
    flex-wrap: wrap; /* Para que en celu se acomoden solos */
}

.categorias a {
    padding: 10px 22px;
    background: #ffffff;
    border: 1px solid #ddd;
    border-radius: 25px;
    color: var(--text-dark);
    font-size: 0.95rem;
    font-weight: 600;
    transition: all 0.3s ease;
    text-decoration: none;
    box-shadow: 0 2px 5px rgba(0,0,0,0.02);
}

.categorias a:hover {
    background: var(--success);
    color: white;
    border-color: var(--success);
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(37, 211, 102, 0.2);
}

/* Ajustes para Celular */
@media (max-width: 480px) {
    .buscador input {
        padding: 12px 15px;
        font-size: 0.9rem;
    }
    
    .buscador button {
        padding: 12px 20px;
    }

    .categorias a {
        padding: 8px 16px;
        font-size: 0.85rem;
    }
}

/* --- 2. HEADER ESTILO ONRENDER --- */
.header {
    display: flex;
    flex-direction: column; /* Apila todo al centro */
    align-items: center;
    padding: 20px 0;
    background: #fff;
    border-bottom: 1px solid #eee;
    width: 100%;
}

.header-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.logo-img {
    width: 120px; /* Tamaño justo para que no sea gigante */
    height: auto;
    margin-bottom: 10px;
}

.nombre {
    font-size: 42px; /* Bien grande como pediste */
    font-weight: 900;
    letter-spacing: 6px;
    text-transform: uppercase;
    color: #000;
    margin: 10px 0;
}

/* El Carrito ahora va debajo del nombre en celulares o a la derecha en PC */
.header-right {
    margin-top: 10px;
}

.carrito-btn {
    background: #000;
    color: #fff;
    padding: 10px 25px;
    border-radius: 30px;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    transition: 0.3s;
}

.carrito-btn:hover {
    transform: scale(1.05);
}

.contador {
    background: #fff;
    color: #000;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

/* --- BOTÓN FLOTANTE CARRITO --- */
.carrito-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 20px;
    left: 20px; /* Del lado opuesto a WhatsApp */
    background-color: var(--primary); /* Negro elegante */
    color: #FFF;
    border-radius: 50px;
    text-align: center;
    box-shadow: 2px 2px 10px rgba(0,0,0,0.3);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s, background-color 0.3s;
    text-decoration: none;
}

.icono-carrito {
    font-size: 28px;
}

.contador-float {
    position: absolute;
    top: 0;
    right: 0;
    background-color: var(--success); /* Verde como el de arriba */
    color: white;
    font-size: 12px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--primary);
    font-weight: bold;
}

.carrito-float:hover {
    transform: scale(1.1);
    background-color: #333;
}

/* Ajuste para celulares */
@media (max-width: 768px) {
    .carrito-float {
        width: 50px;
        height: 50px;
        bottom: 15px;
        left: 15px;
    }
    .icono-carrito {
        font-size: 22px;
    }
}

/* --- VENTANA MODAL DE EDICIÓN (ADMIN) --- */

/* El fondo oscuro detrás de la ventana */
.modal-edicion {
    display: none; /* Se activa por JS */
    position: fixed;
    z-index: 10001;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px); /* Efecto de desenfoque al fondo */
    align-items: center;
    justify-content: center;
    padding: 20px;
}

/* --- VENTANA DE EDICIÓN (MODAL) --- */
.modal-zoom {
    display: none; 
    position: fixed; 
    z-index: 99999; /* Por encima de todo */
    inset: 0; 
    background-color: rgba(0,0,0,0.7); /* Fondo oscuro */
    backdrop-filter: blur(4px); /* Efecto de desenfoque */
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-contenido-scroll {
    background: #ffffff;
    width: 90%;
    max-width: 480px;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    max-height: 85vh;
    overflow-y: auto;
}

.modal-contenido-scroll h3 {
    text-align: center;
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: var(--primary);
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
}

.modal-contenido-scroll label {
    display: block;
    margin-top: 15px;
    font-weight: bold;
    font-size: 0.9rem;
    color: #444;
}

.modal-contenido-scroll input, 
.modal-contenido-scroll select {
    width: 100%;
    padding: 12px;
    margin-top: 5px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 1rem;
    box-sizing: border-box; /* Evita que se salga del borde */
}

.modal-contenido-scroll input:focus {
    border-color: var(--success);
    outline: none;
    box-shadow: 0 0 5px rgba(37, 211, 102, 0.2);
}

/* --- DISEÑO DE FORMULARIO DE BANNERS --- */
.form-banner-admin {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-width: 700px;
    margin: 0 auto;
}

.form-banner-admin input[type="text"],
.form-banner-admin input[type="number"],
.form-banner-admin textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    background-color: #fafafa;
    transition: border-color 0.3s;
    box-sizing: border-box;
}

.form-banner-admin input:focus, 
.form-banner-admin textarea:focus {
    border-color: var(--primary-logo);
    outline: none;
    background-color: #fff;
}

.form-banner-admin label {
    font-weight: 700;
    color: #444;
    margin-bottom: -10px; /* Para que quede pegadito al input */
    font-size: 0.9rem;
}

.form-banner-admin .btn-subir-completo {
    background-color: var(--primary);
    color: white;
    padding: 15px;
    border: none;
    border-radius: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: background 0.3s;
}

.form-banner-admin .btn-subir-completo:hover {
    background-color: #333;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

/* Para que la tabla de banners activos no deforme las fotos */
.admin-tabla img {
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    object-fit: cover;
}

/* --- ESTILO REFORZADO PARA EL PANEL DE BANNERS --- */
.form-banner-guille {
    display: flex !important;
    flex-direction: column !important;
    gap: 15px !important;
    max-width: 650px !important;
    margin: 20px auto !important;
    background: #fff;
    padding: 20px;
    border-radius: 12px;
}

.form-banner-guille input, 
.form-banner-guille textarea {
    width: 100% !important;
    padding: 12px !important;
    border: 1px solid #ccc !important;
    border-radius: 8px !important;
    display: block !important;
}

.btn-banner-pro {
    background: #000 !important;
    color: #fff !important;
    padding: 15px !important;
    border-radius: 8px !important;
    font-weight: bold !important;
    cursor: pointer !important;
    border: none !important;
}

/* --- FOOTER BAZAR GUILLE --- */
.footer {
    background-color: #2c3e50; /* Un tono oscuro elegante */
    color: white;
    padding: 40px 0;
    margin-top: 50px;
    text-align: center;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

/* BOTÓN INSTAGRAM CON DEGRADADO */
.instagram-btn {
    display: inline-block;
    padding: 12px 25px;
    border-radius: 30px;
    color: white;
    text-decoration: none;
    font-weight: bold;
    font-size: 16px;
    background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285AEB 90%);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.instagram-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

/* COPYRIGHT */
.copyright {
    font-size: 14px;
    color: #bdc3c7; /* Gris claro para que no canse la vista */
    margin: 0;
    letter-spacing: 0.5px;
}

/* Botones de navegación del Zoom */
.nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    font-size: 40px;
    padding: 15px;
    cursor: pointer;
    border-radius: 50%;
    transition: 0.3s;
    user-select: none;
    z-index: 10001;
}

.nav-btn:hover {
    background: rgba(0, 0, 0, 0.8);
}

.prev { left: 20px; }
.next { right: 20px; }

/* En celulares las hacemos un poco más chicas */
@media (max-width: 600px) {
    .nav-btn {
        font-size: 25px;
        padding: 10px;
    }
}

/* --- TÍTULOS PANEL ADMIN --- */
.admin-header h1 {
    font-size: 28px;
    color: #2c3e50;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 20px;
    font-weight: 800;
    text-align: center;
}

/* Títulos de las Secciones (Banners, Productos, etc.) */
.form-seccion h2 {
    font-size: 22px;
    color: #34495e;
    border-bottom: 2px solid #3498db;
    display: inline-block;
    padding-bottom: 5px;
    margin-bottom: 25px;
}

/* --- TÍTULO DE LA TIENDA (Header principal) --- */
.header-left .nombre {
    font-size: 24px;
    font-weight: 900;
    color: #000;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-left: 10px;
}

/* Títulos de Categorías en la Tienda */
.titulo-categoria {
    font-size: 20px;
    font-weight: bold;
    color: #ffffff;
    margin: 30px 0 15px 0;
    padding-left: 10px;
    border-left: 5px solid #000;
}

/* --- BOTÓN CERRAR SESIÓN --- */
.btn-logout {
    background-color: #e74c3c; /* Rojo elegante */
    color: white;
    text-decoration: none;
    padding: 8px 15px;
    border-radius: 5px;
    font-size: 14px;
    font-weight: bold;
    transition: background 0.3s ease, transform 0.2s ease;
    border: none;
    display: inline-block;
}

.btn-logout:hover {
    background-color: #c0392b; /* Rojo más oscuro al pasar el mouse */
    transform: scale(1.05); /* Se agranda un pelín */
}

/* --- AJUSTE DEL HEADER ADMIN --- */
.admin-header {
    display: flex;
    justify-content: space-between; /* Título a la izquierda, botón a la derecha */
    align-items: center;
    padding: 20px 40px;
    background-color: #ffffff;
    border-bottom: 2px solid #eee;
    margin-bottom: 30px;
}

.admin-header h1 {
    margin: 0; /* Quitamos el margen para que no se desalinee con el botón */
    font-size: 24px;
    color: #2c3e50;
    font-weight: 800;
}

* Contenedor principal de categorías */
.categorias-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin: 25px 0;
}

/* Botones con forma de "Chip" */
.cat-chip {
    padding: 10px 20px;
    background: #f4f4f4;
    border-radius: 30px;
    text-decoration: none;
    color: #333;
    font-weight: 600;
    border: 1px solid #ddd;
    transition: all 0.3s ease;
}

.cat-chip.activo, .cat-chip:hover {
    background: #333;
    color: #fff;
    border-color: #333;
}

/* Menú Desplegable */
.dropdown-cat {
    position: relative;
    display: inline-block;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #fff;
    min-width: 180px;
    box-shadow: 0px 8px 16px rgba(0,0,0,0.15);
    z-index: 1000;
    border-radius: 10px;
    margin-top: 8px;
    border: 1px solid #eee;
    overflow: hidden;
}

.dropdown-content a {
    color: #333;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    font-size: 14px;
}

.dropdown-content a:hover {
    background-color: #f8f9fa;
    color: #3498db;
}

/* Mostrar al pasar el mouse */
.dropdown-cat:hover .dropdown-content {
    display: block;
}

/* Contenedor principal: los centra y permite que bajen de línea si son muchos */
.categorias-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin: 25px auto;
    padding: 0 10px;
    max-width: 1200px;
}

/* El "Chip" o botón principal */
.cat-chip {
    display: inline-block;
    padding: 10px 20px;
    background: #ffffff;
    color: #333;
    text-decoration: none;
    border-radius: 30px;
    font-weight: 600;
    font-size: 14px;
    border: 1px solid #ddd;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.cat-chip.activo, .cat-chip:hover {
    background: #333;
    color: #fff;
    border-color: #333;
    transform: translateY(-2px); /* Un pequeño saltito al pasar el mouse */
}

/* Lógica del menú desplegable (Dropdown) */
.dropdown-cat {
    position: relative;
    display: inline-block;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #ffffff;
    min-width: 180px;
    box-shadow: 0px 8px 16px rgba(0,0,0,0.15);
    z-index: 1000;
    border-radius: 12px;
    margin-top: 8px;
    border: 1px solid #eee;
    padding: 5px 0;
}

/* Los links de las subcategorías */
.dropdown-content a {
    color: #444;
    padding: 10px 20px;
    text-decoration: none;
    display: block;
    font-size: 13px;
    transition: background 0.2s;
}

.dropdown-content a:hover {
    background-color: #f8f9fa;
    color: #3498db;
}

/* Mostrar el menú al pasar el mouse */
.dropdown-cat:hover .dropdown-content {
    display: block;
}