/* --- BUSCADO MOBILE --- */


@media (max-width: 768px) {
    .search-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: white;
        z-index: 99999;
        overflow-y: auto;
        padding-bottom: 80px;
    }

    .search-header {
        display: flex;
        gap: 10px;
        padding: 10px;
        border-bottom: 1px solid #eee;
        background: white;
        position: sticky;
        top: 0;
        z-index: 100000;
    }
}

/* --- INTRO --- */

.frase-secundaria {
    display: block;
    margin-top: 10px;
    font-weight: 400;
    font-size: 1.4rem;
    font-family: 'Roboto', sans-serif;
}

/* ============================================================
   TODO LO QUE SIGUE ES DEL MICROSITIO / PANEL (NO TOCAR)
   ============================================================ */

/* BOTÓN FLOTANTE WHATSAPP */
.whatsapp-float {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: var(--color-primario) !important;
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    text-align: center;
    font-size: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    z-index: 999;
    transition: transform 0.2s ease-in-out;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    color: white;
}

/* IMÁGENES DE PRODUCTOS */

.producto-card img,
.categoria-card img {
    height: 160px;
    object-fit: cover;
    width: 100%;
    border-radius: 6px;
}

section {
  background: transparent !important;
}


.card {
  background: var(--bg-card) !important;
  border: 1px solid var(--border-soft);
  border-radius: 14px;
}

.card {
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}


.btn-consultar {
  background-color: var(--color-primario);
  color: #000;
  border: none;
}

.producto-img-principal {
    max-height: 300px;
    width: auto;
}

.preview-principal-container {
    text-align: center;
    margin: 20px 0;
}

.preview-principal-img {
    max-width: 260px;
    /* tamaño ideal para panel */
    width: auto;
    height: auto;
    border-radius: 25px;
    border: 1px solid #e5e5e5;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    padding: 6px;
    background: #fff;
}

.contenedor-imagen-principal {
    width: 260px;
    /* tamaño real del contenedor */
    margin: 0 auto;
    /* centrado */
}

.img-principal {
    width: 30%;
    /* se adapta al contenedor */
    height: auto;
    border-radius: 12px;
    border: 1px solid #e5e5e5;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    padding: 6px;
    background: #fff;
}


.foto-principal {
    max-width: 300px;
    /* o el tamaño que quieras */
    height: auto;
}


@media (max-width: 576px) {
    .producto-card img {
        height: 130px;
    }
}


/* CONTENEDOR DE IMAGEN (SIEMPRE EXISTE) */
.img-container {
    position: relative;
    height: 160px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card);
    border-radius: 6px;
    overflow: hidden;
}

/* IMAGEN */
.img-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* RESPONSIVE */
@media (max-width: 576px) {
    .img-container {
        height: 130px;
    }
}

/* 🔥 RIBBON DESCUENTO */
.ribbon-descuento {
    position: absolute;
    top: 8px;
    left: 8px;
    background: linear-gradient(135deg, #ff3b3b, #ff6b6b);
    color: #fff;
    font-size: 1.2rem;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 8px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.25);
    z-index: 5;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* efecto sutil */
.ribbon-descuento::before {
    content: "🔥";
}




/* NAVBAR */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(8px);
    background-color: transparent;
}


.theme-dark .navbar {
  background-color: rgba(18, 18, 18, 0.9) !important;
}

.theme-light .navbar {
    background-color: rgba(255,255,255,0.9);
}


/* SUBRAYADO ANIMADO */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0%;
    height: 2px;
    background-color: var(--color-primario);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* BOTONES */
.btn-primary,
.btn-outline-primary:hover {
    background-color: var(--color-primario) !important;
    border-color: var(--color-primario) !important;
}

.btn-outline-primary {
    color: var(--color-primario);
    border-color: var(--color-primario);
}

.btn-outline-primary:hover {
    background-color: var(--color-primario);
    color: white;
}


/* LINKS ACTIVOS */
.nav-link.active,
.nav-link:hover {
    color: var(--color-primario) !important;
}


/* ============================
   PROMOS — SCROLL HORIZONTAL
   ============================ */

.promos-scroll {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    padding: 10px 5px 20px;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.promos-scroll::-webkit-scrollbar {
    height: 6px;
}

.promos-scroll::-webkit-scrollbar-thumb {
    background: var(--color-primario);
    border-radius: 4px;
}

/* ============================
   TARJETA DE PROMO
   ============================ */

.promo-card {
    min-width: 280px;
    background: var(--bg-card) !important;
    border: 1px solid var(--border-soft);
    border-radius: 14px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    scroll-snap-align: start;
    position: relative;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.promo-card-h {
  background: var(--bg-card) !important;
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

/* Franja superior PROMO */
.promo-ribbon {
    background: var(--color-primario);
    color: white;
    font-weight: bold;
    padding: 6px 12px;
    font-size: 0.9rem;
    text-align: center;
    letter-spacing: 0.5px;
}

/* Imagen */
.promo-img img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
}

/* Contenido */
.promo-content {
    padding: 16px;
    text-align: center;
}

.promo-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 6px;
    color: #222;
}

.promo-desc {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 12px;
    line-height: 1.3;
}

.promo-price {
    font-size: 1.6rem;
    font-weight: bold;
    color: var(--color-primario);
    margin-bottom: 16px;
}

.card-img-top {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-bottom: 1px solid #eee;
}