:root {
    --bg-dark: #060d1f;
    --bg-card: #ffffff;
    --bg-page: #f3f6f9;
    --cyan-neon: #00d2ff;
    --green-neon: #00e676;
    --green-dark: #00a859;
    --text-main: #111827;
    --text-muted: #6b7280;
    --gradient-geps: linear-gradient(135deg, #060d1f 0%, #0a2540 50%, #064e3b 100%);
    --gradient-accent: linear-gradient(90deg, #00d2ff 0%, #00e676 100%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background-color: var(--bg-page);
    color: var(--text-main);
    padding-bottom: 100px;
}

/* HEADER Y BANNER PANORÁMICO */
.store-header {
    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 18px;
}

.banner-hero {
    height: 170px;
    background:
        radial-gradient(circle at 20% 50%, rgba(0, 210, 255, 0.25) 0%, transparent 50%),
        radial-gradient(circle at 80% 30%, rgba(0, 230, 118, 0.25) 0%, transparent 50%),
        var(--gradient-geps);
    position: relative;
    overflow: hidden;
}

.banner-hero::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-accent);
}

.btn-lupa-top {
    position: absolute;
    top: 16px;
    right: 20px;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #ffffff;
    border: none;
    color: var(--bg-dark);
    font-size: 1.1rem;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s;
}

.btn-lupa-top:hover {
    transform: scale(1.08);
}

/* LOGO CIRCULAR SUPERPUESTO E INFO */
.store-info-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    position: relative;
}

.logo-wrapper {
    width: 115px;
    height: 115px;
    border-radius: 50%;
    background: var(--bg-dark);
    border: 4px solid #ffffff;
    box-shadow: 0 6px 18px rgba(0, 210, 255, 0.3);
    margin-top: -55px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.logo-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.logo-fallback {
    display: none;
    font-weight: 800;
    font-size: 1.5rem;
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.store-details {
    flex: 1;
    padding-top: 12px;
    min-width: 260px;
}

.title-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 6px;
}

.title-row h1 {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--bg-dark);
    letter-spacing: 0.3px;
}

.badge-wa {
    background: #e6f9f0;
    color: var(--green-dark);
    font-size: 0.78rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
    border: 1px solid #bbf7d0;
}

.store-bio {
    font-size: 0.88rem;
    color: var(--text-muted);
    line-height: 1.45;
    max-width: 850px;
}

/* BUSCADOR */
.search-bar-container {
    max-width: 1200px;
    margin: 15px auto 0;
    padding: 0 20px;
    display: flex;
    gap: 10px;
}

.search-bar-container input {
    flex: 1;
    padding: 10px 16px;
    border-radius: 25px;
    border: 2px solid var(--cyan-neon);
    outline: none;
    font-size: 0.9rem;
}

.search-bar-container button {
    background: var(--bg-dark);
    color: #fff;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
}

/* CATEGORÍAS CIRCULARES */
.categorias-section {
    background: #ffffff;
    padding: 18px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
    position: sticky;
    top: 0;
    z-index: 50;
}

.categorias-scroll {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: flex-start;
    gap: 24px;
    overflow-x: auto;
    scrollbar-width: none;
}

.categorias-scroll::-webkit-scrollbar {
    display: none;
}

.cat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    min-width: 85px;
    transition: transform 0.2s;
}

.cat-item:hover {
    transform: translateY(-3px);
}

.cat-circle {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    background: #f1f5f9;
    border: 2px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--bg-dark);
    transition: all 0.25s ease;
}

.cat-item span {
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--text-muted);
    text-align: center;
}

.cat-item.activo .cat-circle {
    background: var(--bg-dark);
    color: var(--green-neon);
    border: 3px solid var(--cyan-neon);
    box-shadow: 0 4px 14px rgba(0, 210, 255, 0.35);
}

.cat-item.activo span {
    color: var(--bg-dark);
    font-weight: 700;
}

/* CONTENEDOR Y GRILLA DE PRODUCTOS */
.main-container {
    max-width: 1200px;
    margin: 24px auto;
    padding: 0 20px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
}

.section-header h2 {
    font-size: 1.15rem;
    color: var(--bg-dark);
}

.count-tag {
    font-size: 0.8rem;
    background: #e0f2fe;
    color: #0369a1;
    padding: 4px 12px;
    border-radius: 15px;
    font-weight: 600;
}

.grid-productos {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 18px;
}

/* TARJETA DE PRODUCTO */
.tarjeta-producto,
.producto-card {
    background: var(--bg-card);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    border: 1px solid #eef2f6;
    position: relative;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s, box-shadow 0.2s;
}

.tarjeta-producto:hover,
.producto-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(6, 13, 31, 0.1);
}

.prod-foto-box {
    width: 100%;
    height: 195px;
    background: #ffffff;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    overflow: hidden;
}

.prod-img,
.producto-img {
    width: 100%;
    height: 195px;
    object-fit: contain;
    padding: 8px;
    background: #ffffff;
    border-bottom: 1px solid #f1f5f9;
}

.prod-cuerpo,
.producto-info {
    padding: 14px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.prod-codigo,
.producto-cat-tag {
    font-size: 0.68rem;
    text-transform: uppercase;
    font-weight: 700;
    color: #0284c7;
    margin-bottom: 4px;
}

.prod-nombre,
.producto-titulo {
    font-size: 0.92rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 6px;
    cursor: pointer;
    line-height: 1.3;
    flex: 1;
}

.producto-desc {
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.35;
    margin-bottom: 12px;
    flex: 1;
}

.prod-precio,
.producto-precio {
    font-size: 1.08rem;
    font-weight: 800;
    color: var(--green-dark);
    margin-bottom: 10px;
}

.prod-acciones {
    display: flex;
    gap: 8px;
}

.btn-ver-detalle {
    flex: 1;
    padding: 8px 10px;
    border-radius: 10px;
    border: 1.5px solid #cbd5e1;
    background: #f8fafc;
    color: var(--bg-dark);
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-ver-detalle:hover {
    background: #e2e8f0;
}

.btn-agregar-carrito {
    flex: 1;
    padding: 8px 10px;
    border-radius: 10px;
    border: none;
    background: var(--bg-dark);
    color: var(--green-neon);
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.2s, background 0.2s;
}

.btn-agregar-carrito:hover {
    background: #0a2540;
    transform: translateY(-1px);
}

.producto-cuerpo-click {
    display: flex;
    flex-direction: column;
    flex: 1;
    cursor: pointer;
}

.btn-add-plus {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #ffffff;
    border: 1.5px solid #e5e7eb;
    color: var(--bg-dark);
    font-size: 1.2rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.12);
    z-index: 5;
    transition: all 0.2s;
}

.btn-add-plus:hover {
    background: var(--green-neon);
    color: var(--bg-dark);
    border-color: var(--green-neon);
    transform: scale(1.1);
}

/* MASCOTA VIRTUAL ALINEADA CON CARRITO Y WHATSAPP */
.mascota {
    position: fixed;
    bottom: 164px;
    right: 0px;
    width: 102px;
    z-index: 1200;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: all 0.95s cubic-bezier(0.34, 1.56, 0.64, 1);
    pointer-events: none;
}

.mascota-sprite {
    width: 96px;
    height: 96px;
    object-fit: contain;
    background: transparent;
    border: none;
    border-radius: 0;
    box-shadow: none;
    filter: none;
    animation: respirarMascota 2.2s infinite ease-in-out;
}

.mascota-globo {
    background: var(--bg-dark);
    color: #ffffff;
    font-size: 0.66rem;
    font-weight: 500;
    line-height: 1.25;
    text-align: center;
    padding: 5px 8px;
    border-radius: 12px;
    border: 1.5px solid var(--green-neon);
    margin-bottom: 5px;
    width: 96px;
    white-space: normal;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

@keyframes respirarMascota {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-4px); }
}

/* BOTONES FLOTANTES INFERIORES */
.flotantes-derecha {
    position: fixed;
    bottom: 20px;
    right: 22px;
    display: flex;
    flex-direction: column-reverse;
    align-items: center;
    gap: 12px;
    z-index: 1050;
}

.btn-wa-flotante,
.btn-carrito-flotante {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    cursor: pointer;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.22);
    transition: transform 0.2s;
    text-decoration: none;
}

.btn-wa-flotante {
    background: #25d366;
    color: #ffffff;
}

.btn-carrito-flotante {
    background: var(--bg-dark);
    color: var(--cyan-neon);
    border: 2px solid var(--green-neon);
    position: relative;
}

.btn-wa-flotante:hover,
.btn-carrito-flotante:hover {
    transform: scale(1.08);
}

#contador-carrito {
    position: absolute;
    top: -4px;
    right: -4px;
    background: var(--green-neon);
    color: var(--bg-dark);
    font-size: 0.78rem;
    font-weight: 800;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* MODALES */
.oculto {
    display: none !important;
}

.modal {
    position: fixed;
    inset: 0;
    background: rgba(6, 13, 31, 0.75);
    backdrop-filter: blur(4px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.modal-contenido {
    background: #ffffff;
    width: 100%;
    max-width: 450px;
    border-radius: 22px;
    padding: 22px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    max-height: 90vh;
    overflow-y: auto;
}

.modal-detalle-box {
    max-width: 660px;
    width: 94%;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 12px;
    margin-bottom: 14px;
}

.cerrar {
    background: #f3f4f6;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
}

/* GALERÍA Y DETALLE DEL PRODUCTO */
.galeria-producto {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 14px;
}

.foto-principal-wrapper {
    position: relative;
    width: 100%;
    height: 330px;
    border-radius: 16px;
    overflow: hidden;
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    touch-action: pan-y;
    user-select: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.detalle-foto-grande {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 10px;
    display: block;
    user-select: none;
    -webkit-user-drag: none;
    pointer-events: none;
}

.btn-flecha-foto {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1.5px solid var(--cyan-neon);
    background: rgba(6, 13, 31, 0.82);
    color: #ffffff;
    font-size: 0.95rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 6;
    transition: transform 0.2s, background 0.2s, color 0.2s;
}

.btn-flecha-foto:hover {
    background: var(--green-neon);
    color: var(--bg-dark);
    border-color: var(--green-neon);
    transform: translateY(-50%) scale(1.08);
}

.btn-flecha-izq {
    left: 12px;
}

.btn-flecha-der {
    right: 12px;
}

.contador-fotos-badge {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(6, 13, 31, 0.8);
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 600;
    padding: 3px 9px;
    border-radius: 12px;
    border: 1px solid rgba(0, 210, 255, 0.45);
    z-index: 5;
}

.miniaturas-fila {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 4px;
}

.miniatura-img {
    width: 72px;
    height: 72px;
    object-fit: contain;
    padding: 4px;
    background: #ffffff;
    border-radius: 12px;
    cursor: pointer;
    border: 2px solid #e2e8f0;
    opacity: 0.75;
    transition: all 0.2s;
    flex-shrink: 0;
}

.miniatura-img:hover,
.miniatura-img.activa {
    opacity: 1;
    border-color: var(--cyan-neon);
    transform: translateY(-2px);
}

.detalle-titulo {
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--bg-dark);
    margin-bottom: 6px;
}

.detalle-precio-tag {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--green-dark);
    margin-bottom: 10px;
}

#detalle-descripcion {
    display: flex;
    flex-direction: column;
    gap: 8px;
    line-height: 1.45;
}

#detalle-descripcion .desc-titulo {
    font-weight: 700;
    margin-top: 4px;
}

#detalle-descripcion .desc-item {
    padding-left: 8px;
}

#detalle-descripcion .desc-nota {
    margin-top: 6px;
    padding: 8px 10px;
    border-radius: 8px;
    background: #fff8e7;
}

.detalle-acciones {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.btn-volver {
    flex: 1;
    min-width: 170px;
    padding: 13px 14px;
    border-radius: 14px;
    border: 1.5px solid #cbd5e1;
    background: #f8fafc;
    color: var(--bg-dark);
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    transition: background 0.2s;
}

.btn-volver:hover {
    background: #e2e8f0;
}

.btn-agregar-detalle {
    flex: 1;
    min-width: 170px;
    padding: 13px 14px;
    border-radius: 14px;
    background: var(--bg-dark);
    color: var(--green-neon);
    border: 2px solid var(--cyan-neon);
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    transition: transform 0.2s;
}

.btn-agregar-detalle:hover {
    transform: scale(1.02);
}

/* CARRITO */
.item-carrito {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid #f1f5f9;
}

.item-carrito > div:first-child {
    flex: 1;
    min-width: 0;
}

.controles-cant {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    white-space: nowrap;
}

.controles-cant button {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 1px solid #d1d5db;
    background: #fff;
    cursor: pointer;
    font-weight: 700;
}

.resumen-total {
    display: flex;
    justify-content: space-between;
    font-size: 1.15rem;
    margin: 14px 0;
    padding: 12px;
    background: #f0fdf4;
    border-radius: 12px;
    color: var(--bg-dark);
}

.form-checkout {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.form-checkout label {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--bg-dark);
}

.form-checkout input,
.form-checkout select {
    padding: 11px 14px;
    border-radius: 12px;
    border: 1.5px solid #d1d5db;
    font-size: 0.88rem;
}

.aviso-asesor {
    background: #f0f9ff;
    border-left: 4px solid var(--cyan-neon);
    color: #0f172a;
    font-size: 0.78rem;
    line-height: 1.45;
    padding: 10px 12px;
    border-radius: 10px;
    margin-top: 2px;
}

.aviso-asesor i {
    color: #0284c7;
    margin-right: 4px;
}

.btn-enviar-wa {
    margin-top: 6px;
    padding: 14px;
    border-radius: 14px;
    border: none;
    background: #25d366;
    color: #ffffff;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 6px 16px rgba(37, 211, 102, 0.35);
}