:root {
    --color-main: #001b86;
    --color-secondary: #010f46;
    --color-green: #62f600;
    --dark-bg: #111111;
    --top-banner-height: 42px;
    /* default, overridden in responsive */
    --header-height: 102px;
    /* approximate header height */
    --header-height-mobile: 132px;
    /* approximate header height on mobile */
    --nav-height: 48px;
    /* approximate navbar height */
    --nav-height-mobile: 91px;
    /* approximate navbar height on mobile*/
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
    /* Reserve space for fixed top elements to avoid overlap */
    padding-top: calc(var(--top-banner-height) + var(--header-height) + var(--nav-height));
}

main,
footer {
    padding: 0 20px;
}

/* Fixed top-banner, header and navbar so they remain visible on scroll */
.top-banner-container {
    background-color: var(--dark-bg);
    color: #ffffff;
    overflow: hidden;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--top-banner-height);
    z-index: 1080;
}

header {
    position: fixed;
    top: var(--top-banner-height);
    left: 0;
    right: 0;
    z-index: 1070;
    background: #ffffff;
}

.navbar-orange {
    position: fixed;
    top: calc(var(--top-banner-height) + var(--header-height));
    left: 0;
    right: 0;
    z-index: 1060;
}

.max-width-1200 {
    max-width: 1200px;
    margin: 0 auto;
}

.top-banner-container {
    background-color: var(--dark-bg);
    color: #ffffff;
    overflow: hidden;
    /* position defined earlier for fixed header behavior */
    white-space: nowrap;
    padding: 13px 0;
    height: var(--top-banner-height);
    font-size: 1.2rem;
    font-weight: 600;
}

.top-banner-track {
    position: absolute;
    left: 100%;
    top: 10px;
    display: flex;
    width: max-content;
    animation: marquee 19s linear infinite;
    will-change: transform;
}

/* Responsive adjustments: on small screens reduce reserved heights */
@media (max-width: 575.98px) {
    :root {
        --top-banner-height: 34px;
        --header-height: 64px;
        --nav-height: 40px;
    }

    body {
        padding-top: calc(var(--top-banner-height) + var(--header-height-mobile) + var(--nav-height-mobile));
    }

    .navbar-orange {
        top: calc(var(--top-banner-height) + var(--header-height-mobile));
    }
}

.banner-group {
    display: inline-flex;
    align-items: center;
    min-width: 100vw;
    padding-right: 6rem;
    box-sizing: border-box;
}

.banner-item {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    flex: 0 0 auto;
    line-height: 1.2;
    margin-right: 15rem;
    position: relative;
    white-space: nowrap;
}

.banner-item-inner {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.banner-separator {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    line-height: 1;
    margin-left: 0.2rem;
}

.banner-item i {
    color: var(--color-green);
}

@keyframes marquee {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

@keyframes qrPulse {

    0%,
    100% {
        border-color: #ff6600;
    }

    50% {
        border-color: #ff9966;
    }
}

@keyframes qrScan {
    0% {
        transform: scale(1);
        filter: brightness(1);
    }

    50% {
        transform: scale(1.03);
        filter: brightness(1.08);
    }

    100% {
        transform: scale(1);
        filter: brightness(1);
    }
}

/* --- Buscador y Elementos de Navegación --- */
.search-input {
    border-radius: 50px 0 0 50px !important;
    border: 1px solid #ced4da;
    border-right: none;
}

.search-clear-btn {
    background: transparent;
    border: 1px solid #ced4da;
    border-left: none;
    border-right: none;
    padding: 0 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-clear-btn i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #bbb;
    color: #fff;
    font-size: 0.6rem;
    font-weight: 700;
    transition: background 0.15s, transform 0.1s;
}

.search-clear-btn:hover i {
    background: #888;
    transform: scale(1.1);
}

.search-clear-btn:focus {
    box-shadow: none;
    outline: none;
}

.search-btn {
    border-radius: 0 50px 50px 0 !important;
    background-color: var(--color-main);
    border: 1px solid var(--color-main);
    color: white;
    padding-right: 20px;
    padding-left: 20px;
}

.search-btn:hover {
    background-color: var(--color-secondary);
    color: white;
}

.contact-icon {
    color: var(--color-main);
    font-size: 2rem;
}

/* --- Barra de Menú Naranja --- */
.navbar-orange {
    background-color: var(--color-main);
    padding: 0 20px;
}

.menu-toggle-btn {

    background-color: transparent;
    color: white;
    border-radius: 10px;
    border: 1px solid white;
    padding: 0 10px 0 0;
    font-weight: 600;
}

.menu-toggle-btn>i {
    background-color: white;
    color: var(--color-main);
    border-radius: 10px 0 0 10px;
    padding-left: 10px;
    padding-right: 5px;
}

.nav-link-custom {
    color: white !important;
    font-weight: 500;
    padding: 15px 12px !important;
    font-size: 0.95rem;
}

.nav-link-custom:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

/* --- Iconos de Usuario y Carrito --- */
.action-icon-btn {
    color: #333333;
    font-size: 1.3rem;
    position: relative;
    background: none;
    border: none;
    padding: 8px;
}

.nav-orange-icons .action-icon-btn {
    color: white;
}

.badge-count {
    position: absolute;
    top: 0;
    right: 0;
    background-color: white;
    color: #333333;
    font-size: 0.65rem;
    font-weight: bold;
    border-radius: 50%;
    width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-total {
    color: white;
    font-weight: bold;
    font-size: 0.9rem;
    margin-left: 5px;
}

/* --- ESTILOS DEL FOOTER --- */
.footer-dark {
    background: var(--color-main);
    color: #eff2ff;
    font-size: 0.95rem;
    position: relative;
    padding: ;
}

.footer-dark::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top left, rgba(98, 246, 0, 0.12), transparent 30%);
    pointer-events: none;
}

.footer-shell {
    position: relative;
    z-index: 1;
}

.footer-top {
    padding-bottom: 14px;
    margin-bottom: 16px;
}

.footer-brand-block {
    display: flex;
    align-items: center;
    gap: 14px;
}

.footer-brand-link img {
    max-width: 140px;
    filter: brightness(0) invert(1);
}

.footer-brand-title {
    margin: 0;
    font-weight: 700;
    font-size: 0.95rem;
    color: #ffffff;
}

.footer-brand-copy {
    margin: 0;
    color: rgba(233, 238, 248, 0.72);
    font-size: 0.82rem;
}

.footer-subscribe-row {
    gap: 14px;
}

.footer-subscribe-card {
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.footer-subscribe-card .form-control {
    background: transparent;
    color: #ffffff;
    border: none;
    padding: 10px 14px;
}

.footer-subscribe-card .form-control::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.footer-subscribe-card .btn {
    color: #0f1f5a;
    background: linear-gradient(135deg, #62f600, #8dff2c);
    border: none;
    font-weight: 700;
    padding: 10px 16px;
    border-radius: 999px;
}

.footer-subscribe-card .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(98, 246, 0, 0.18);
}

.text-muted-white {
    color: rgba(233, 238, 248, 0.74);
}

.contact-list li i {
    color: #62f600;
    font-size: 1.1rem;
    margin-top: 2px;
}

.schedule-text {
    font-size: 0.78rem;
    line-height: 1.5;
    display: block;
}

.footer-links li a {
    color: #d4d9e8;
    text-decoration: none;
    transition: color 0.2s ease-in-out, transform 0.2s ease-in-out;
    display: inline-block;
    padding: 1px 0;
    font-size: 0.8rem;
}

.footer-links li a:hover {
    color: #62f600;
    transform: translateX(2px);
}

.footer-content-scroll {
    overflow-x: hidden;
}

#footerCopyright {
    width: 100%;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.8);
    padding-top: 6px;
}

@media (min-width: 768px) {
    .footer-content {
        display: flex;
        flex-wrap: wrap;
        gap: 24px;
        align-items: flex-start;
    }

    .footer-content .accordion {
        display: flex;
        gap: 24px;
        width: 100%;
    }

    .footer-content .accordion-item {
        flex: 1 1 220px;
        min-width: 220px;
    }

    .footer-content .accordion-item .accordion-body {
        padding: 0;
    }

    .footer-content .accordion-button::after {
        display: none;
    }

    .footer-content .accordion-button>div>i {
        color: #fff;
    }
}


.footer-bottom {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    padding-top: 12px;
    color: rgba(233, 238, 248, 0.68);
    font-size: 0.78rem;
}

.footer-bottom-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

@media (max-width: 768px) {
    .footer-dark {
        padding-top: 16px;
        padding-bottom: 16px;
    }

    .footer-top {
        padding-bottom: 12px;
        margin-bottom: 12px;
    }

    .footer-subscribe-row {
        flex-direction: column;
        align-items: stretch;
    }

    .footer-content {
        padding: 0;
    }

    .footer-dark .row.g-2 {
        row-gap: 14px;
    }

    .footer-dark .col-xl-3,
    .footer-dark .col-md-6 {
        flex: 1 1 100%;
    }

    .footer-section-toggle {
        font-size: 0.92rem;
        color: #e9eef8;
        width: 100%;
        text-align: left;
    }

    .footer-section-toggle i {
        transition: transform 0.2s ease;
    }

    .footer-section .accordion-button.collapsed i {
        transform: rotate(0deg);
    }

    .footer-section .accordion-button:not(.collapsed) i {
        transform: rotate(180deg);
    }

    .footer-mobile-accordion-alt {
        flex-direction: row-reverse;
    }

    .footer-bottom-meta {
        display: none;
    }

    .footer-bottom {
        justify-content: center;
        text-align: center;
    }

    .social-icons {
        justify-content: center;
    }
}

@media (max-width: 576px) {
    .footer-dark {
        padding-top: 14px;
        padding-bottom: 14px;
    }

    .footer-brand-block {
        flex-direction: column;
        align-items: flex-start;
    }

    .footer-subscribe-card .form-control {
        padding: 3px 8px;
    }

    .footer-subscribe-card .btn {
        padding: 8px 14px;
    }

    .footer-bottom {
        font-size: 0.75rem;
    }
}

.footer-links,
.contact-list {
    gap: 10px;
}

.footer-dark .col-xl-3,
.footer-dark .col-md-6 {
    margin-bottom: 12px !important;
}

.libro-box {
    max-width: 100%;
}

@media (max-width: 576px) {
    .footer-dark {
        padding-top: 16px !important;
        padding-bottom: 12px !important;
        font-size: 0.82rem;
    }

    .footer-top {
        padding-bottom: 14px;
        margin-bottom: 14px;
    }

    .footer-brand-block {
        flex-direction: column;
        align-items: flex-start;
    }

    .footer-subscribe-row {
        align-items: stretch;
    }

    .footer-content {
        padding: 0;
    }

    .footer-dark .row.g-2 {
        row-gap: 12px;
    }

    .footer-dark .col-xl-3,
    .footer-dark .col-md-6 {
        flex: 1 1 100%;
    }

    .footer-bottom-meta {
        display: none;
    }

    .footer-bottom {
        justify-content: center;
        text-align: center;
    }

    .footer-links li a,
    .contact-list li {
        font-size: 0.78rem;
    }
}

@media (min-width: 769px) {
    .footer-dark {
        padding-top: 18px;
        padding-bottom: 14px;
    }

    .footer-top {
        padding-bottom: 10px;
        margin-bottom: 10px;
    }

    .footer-content {
        padding-top: 0;
        padding-bottom: 0;
    }

    .footer-bottom {
        padding-top: 8px;
        gap: 6px;
    }

    .footer-links,
    .contact-list {
        gap: 8px;
    }
}

.footer-links li a:hover {
    color: #62f600;
    transform: translateX(2px);
}

.libro-box {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.14);
    max-width: 260px;
}

.style-book-text {
    letter-spacing: 0.5px;
    font-family: Arial, sans-serif;
}

.social-icons a {
    transition: transform 0.2s ease, color 0.2s ease;
}

.social-icons a:hover {
    transform: translateY(-3px);
    color: #62f600 !important;
}

/* --- BOTÓN FLOTANTE DE WHATSAPP --- */
.whatsapp-floating {
    position: fixed;
    bottom: 25px;
    right: 25px;
    background-color: #25d366;
    color: white;
    width: 55px;
    height: 55px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    z-index: 1050;
    transition: transform 0.2s ease, background-color 0.2s ease;
    text-decoration: none;
}

.whatsapp-floating:hover {
    transform: scale(1.1);
    color: white;
    background-color: #20ba5a;
}

@media (max-width: 768px) {
    .subscription-input-group {
        max-width: 100% !important;
    }
}

/* --- ESTILOS DE LA CUADRÍCULA HERO --- */

/* ══════════════════════════════════════════════════════════
   HERO GRID — Carrusel (izquierda) + 3 banners (derecha)
   El alto de la columna derecha iguala al carrusel.
   Cada banner lateral ocupa exactamente 1/3 del alto.
   ══════════════════════════════════════════════════════════ */
.hero-grid-wrapper {
    display: grid;
    grid-template-columns: 7fr 3fr;
    gap: 10px;
    height: auto;
    min-height: 0;
}

.hero-grid-wrapper.hero-grid-full {
    grid-template-columns: 1fr;
}

/* ── Columna izquierda: carrusel ── */
.hero-carousel-col {
    min-width: 0;
    border-radius: 10px;
    overflow: hidden;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

#heroCarousel {
    border-radius: 10px;
    overflow: hidden;
    background: #eef0f4;
    width: 100%;
    max-width: 100%;
    height: auto;
    box-sizing: border-box;
}

#heroCarousel .carousel-inner,
#heroCarousel .carousel-item,
#heroCarousel .carousel-item.active {
    height: auto;
}

#heroCarousel .carousel-item img.img-hero-cover {
    width: 100%;
    height: auto;
    aspect-ratio: auto;
    object-fit: contain;
    object-position: center;
    display: block;
    max-width: 100%;
}

/* ── Columna derecha: 3 banners apilados ── */
.hero-banners-col {
    display: flex;
    flex-direction: column;
    gap: 6px;
    height: 100%;
    min-width: 0;
    min-height: 0;
}

.hero-banner-slot {
    flex: 1 1 0;
    /* cada uno ocupa exactamente 1/3 del alto disponible */
    min-height: 0;
    /* crítico para que flex respete el límite del padre */
    border-radius: 8px;
    overflow: hidden;
    background: #e9ecef;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-banner-slot a {
    display: block;
    width: 100%;
    height: 100%;
}

.hero-banner-slot img,
.hero-banner-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.3s ease;
}

.hero-banner-slot:hover img {
    transform: scale(1.03);
}

/* ── Placeholder cuando no hay imagen ── */
.hero-banner-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #adb5bd;
    flex-direction: column;
    gap: 4px;
    font-size: .78rem;
}

.hero-banner-placeholder i {
    font-size: 1.4rem;
}

/* ══ RESPONSIVE ══════════════════════════════════════════ */

@media (max-width: 1199.98px) {
    .hero-grid-wrapper {
        height: auto;
        min-height: 0;
    }
}

@media (max-width: 991.98px) {
    .hero-grid-wrapper {
        grid-template-columns: 1fr;
        height: auto;
        gap: 8px;
    }

    .hero-carousel-col {
        width: 100%;
        max-width: 100%;
        height: auto;
    }

    #heroCarousel {
        width: 100%;
        max-width: 100%;
        height: auto;
    }

    #heroCarousel .carousel-inner,
    #heroCarousel .carousel-item,
    #heroCarousel .carousel-item.active {
        height: auto;
    }

    #heroCarousel .carousel-item img.img-hero-cover {
        width: 100%;
        height: auto;
        aspect-ratio: auto;
        object-fit: contain;
        object-position: center;
        display: block;
    }

    /* Móvil: 3 banners en fila horizontal */
    .hero-banners-col {
        flex-direction: row;
        height: 96px;
        gap: 6px;
    }

    .hero-banner-slot {
        flex: 1 1 0;
        height: 100%;
    }
}

@media (max-width: 575.98px) {

    main,
    header,
    footer {
        padding-left: 10px !important;
        padding-right: 10px !important;
    }

    .hero-carousel-col,
    #heroCarousel {
        width: 100%;
        max-width: 100%;
        height: auto;
    }

    .hero-banners-col {
        height: 72px;
    }
}

/* ── Botones de navegación del carrusel ── */

/* Efecto visual suave de escala al pasar el cursor sobre los banners */
.banner-hover-effect {
    overflow: hidden;
    border-radius: 8px;
    display: block;
    transition: transform 0.3s ease;
}

.banner-hover-effect img {
    transition: transform 0.3s ease;
    display: block;
    width: 100%;
    border-radius: 8px;
}

.banner-hover-effect:hover img {
    transform: scale(1.02);
}

/* Ocultar columna si el banner no cargó */
.banner-col-hidden {
    display: none !important;
}

/* Botones del carrusel */
.carousel-nav-btn {
    background-color: rgba(255, 255, 255, 0.9);
    color: #333333;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15);
    font-size: 1.2rem;
    transition: background-color 0.2s;
}

.carousel-nav-btn:hover {
    background-color: #ffffff;
    color: var(--color-main);
}

.carousel-indicators [data-bs-target] {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: #ffffff;
    opacity: 0.5;
}

.carousel-indicators .active {
    opacity: 1;
    background-color: var(--color-main);
}

/* Ocultar controles si solo hay 1 slide */
#heroCarousel.single-slide .carousel-control-prev,
#heroCarousel.single-slide .carousel-control-next,
#heroCarousel.single-slide .carousel-indicators {
    display: none !important;
}

/* Estilos extraídos de index.php */

.cat-section-modern {
    background: linear-gradient(180deg, #fafbff 0%, #eff4ff 100%);
}

.cat-section-card {
    background: #ffffff;
    border: 1px solid rgba(15, 27, 134, 0.08);
    border-radius: 28px;
    padding: 28px;
    box-shadow: 0 16px 40px rgba(15, 27, 134, 0.08);
}

.cat-section-head {
    gap: 16px;
}

.cat-section-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(0, 27, 134, 0.08);
    color: var(--color-main);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.cat-section-text {
    margin: 8px 0 0;
    color: #5c6b85;
    max-width: 520px;
    font-size: 0.95rem;
}

.cat-section-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    color: var(--color-main);
    text-decoration: none;
}

.cat-section-link:hover {
    color: var(--color-secondary);
}

/* ════ CATEGORY SLIDER ════ */
.cat-slider-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    overflow: hidden;
}

.cat-slider-track {
    display: flex;
    gap: 18px;
    overflow-x: auto;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding: 14px 4px 16px;
    flex: 1;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.cat-slider-track::-webkit-scrollbar {
    display: none;
}

.cat-slider-btn {
    flex-shrink: 0;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid rgba(15, 27, 134, 0.12);
    background: rgba(255, 255, 255, 0.92);
    color: var(--color-main);
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 6px 16px rgba(15, 27, 134, 0.08);
    transition: transform 0.25s ease, background 0.25s ease, color 0.25s ease;
    z-index: 2;
}

.cat-slider-btn:hover {
    background: linear-gradient(135deg, var(--color-main), var(--color-secondary));
    border-color: transparent;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 10px 22px rgba(15, 27, 134, 0.2);
}

.cat-slider-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
    pointer-events: none;
}

.cat-card {
    flex-shrink: 0;
    width: 148px;
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: #ffffff;
    border: 1px solid rgba(15, 27, 134, 0.08);
    border-radius: 16px;
    padding: 18px 12px 16px;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
    box-shadow: 0 8px 18px rgba(15, 27, 134, 0.08);
}

.cat-card:hover {
    border-color: rgba(98, 246, 0, 0.6);
    box-shadow: 0 14px 26px rgba(15, 27, 134, 0.12);
    transform: translateY(-3px);
    color: inherit;
}

.cat-card-img,
.cat-card-icon {
    width: 88px;
    height: 88px;
    border-radius: 16px;
    margin-bottom: 14px;
}

.cat-card-img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #eef4ff;
    padding: 10px;
}

.cat-card-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(98, 246, 0, 0.14);
    font-size: 30px;
    color: var(--color-main);
}

.cat-card-name {
    font-size: 14px;
    font-weight: 700;
    text-align: center;
    line-height: 1.3;
    color: #101828;
    margin-bottom: 6px;
}

.cat-card-count {
    font-size: 11px;
    color: #667085;
    text-align: center;
}

/* Loading state */
.cat-slider-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    width: 100%;
}

@media (max-width: 576px) {
    .cat-card {
        width: 118px;
    }

    .cat-card-img,
    .cat-card-icon {
        width: 72px;
        height: 72px;
    }
}

.hover-lift {
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
    cursor: pointer;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1) !important;
}

.product-card {
    transition: all 0.3s ease;
}

.product-card:hover {
    box-shadow: 0 10px 25px rgba(255, 102, 0, 0.15) !important;
    border-color: rgba(255, 102, 0, 0.3) !important;
}

/* ── Product card actions ── */
.product-card .card-actions {
    opacity: 0;
    transform: translateY(6px);
    transition: all 0.25s ease;
}

.product-card:hover .card-actions {
    opacity: 1;
    transform: translateY(0);
}

.btn-cart-add {
    background-color: var(--color-main);
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 7px 14px;
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: background 0.2s;
    white-space: nowrap;
}

.btn-cart-add:hover {
    background-color: var(--color-secondary);
    color: #fff;
}

.btn-ver-mas-prod {
    background: none;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 7px 10px;
    color: #555;
    font-size: 13px;
    transition: all 0.2s;
}

.btn-ver-mas-prod:hover {
    border-color: var(--color-main);
    color: var(--color-main);
}

/* ── MENÚ LATERAL DE CATEGORÍAS ── */
.category-menu-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    z-index: 2098;
    backdrop-filter: blur(3px);
}

.category-menu-overlay.active {
    display: block;
}

.category-menu-panel {
    position: fixed;
    top: 0;
    left: 0;
    width: 40px;
    height: 100vh;
    background: #fff;
    z-index: 2099;
    display: flex;
    flex-direction: column;
    transition: width 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    border-right: 1px solid #000;
}

.category-menu-panel.expanded {
    width: min(250px, calc(100vw - 25px));
}

.category-menu-handle {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 16px 14px;
    border-bottom: 1px solid #eee;
    position: relative;
}

.category-menu-panel.expanded .category-menu-handle {
    justify-content: space-between;
}

.category-menu-title {
    font-weight: 800;
    color: var(--color-main);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.category-menu-panel:not(.expanded) .category-menu-title {
    display: none;
}

.category-menu-close-btn {
    flex-shrink: 0;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 50%;
    background: #f1f3f5;
    color: #555;
    font-size: 1.35rem;
    line-height: 1;
    cursor: pointer;
}

.category-menu-close-btn:hover {
    background: #e9ecef;
    color: #000;
}

.category-menu-panel:not(.expanded) .category-menu-close-btn {
    display: none;
}

.category-menu-list {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
}

.category-menu-list::-webkit-scrollbar {
    width: 4px;
}

.category-menu-list::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 4px;
}

.category-menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    min-width: 0;
    padding: 13px 14px;
    border-radius: 12px;
    color: #222;
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.category-menu-item:hover {
    background: rgba(0, 27, 134, 0.08);
    color: var(--color-main);
    transform: translateX(2px);
}

.category-menu-panel:not(.expanded) .category-menu-item {
    justify-content: center;
    padding: 0px 10px;
}

.category-menu-icon {
    flex: 0 0 40px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: black;
    font-size: 1.25rem;
}

.category-menu-panel:not(.expanded) .category-menu-icon {
    width: 46px;
    height: 46px;
    font-size: 1.35rem;
}

.category-menu-info {
    flex: 1;
    min-width: 0;
    transition: opacity 0.2s ease;
}

.category-menu-panel:not(.expanded) .category-menu-info {
    display: none;
}

.category-menu-name {
    display: block;
    font-weight: 700;
    font-size: 0.95rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.category-menu-count {
    display: block;
    margin-top: 2px;
    font-size: 0.76rem;
    color: #888;
}

.category-menu-loading,
.category-menu-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 180px;
    color: #888;
    text-align: center;
    padding: 28px 16px;
}

/* ── CARRITO LATERAL ── */
.cart-offcanvas {
    position: fixed;
    top: 0;
    right: -420px;
    width: min(420px, 100vw);
    max-width: 100vw;
    height: 100vh;
    height: 100dvh;
    background: #fff;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    box-shadow: -6px 0 30px rgba(0, 0, 0, 0.18);
    transition: right 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.cart-offcanvas.open {
    right: 0;
}

.cart-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    z-index: 1999;
    backdrop-filter: blur(3px);
}

.cart-overlay.active {
    display: block;
}

.cart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 20px;
    border-bottom: 1px solid #eee;
    flex-shrink: 0;
}

.cart-header h5 {
    margin: 0;
    font-weight: 700;
    font-size: 1rem;
}

.cart-close-btn {
    background: none;
    border: none;
    font-size: 1.4rem;
    color: #555;
    cursor: pointer;
    line-height: 1;
}

.cart-close-btn:hover {
    color: #000;
}

.cart-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px 20px;
}

.cart-body::-webkit-scrollbar {
    width: 4px;
}

.cart-body::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 4px;
}

.cart-item {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 12px 0;
    border-bottom: 1px solid #f3f3f3;
}

.cart-item-img {
    width: 64px;
    height: 64px;
    border-radius: 8px;
    object-fit: contain;
    background: #f8f8f8;
    border: 1px solid #eee;
    padding: 4px;
    flex-shrink: 0;
}

.cart-item-info {
    flex: 1;
    min-width: 0;
}

.cart-item-name {
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cart-item-price {
    font-size: 14px;
    font-weight: 700;
    color: var(--color-main);
    margin-top: 2px;
}

.cart-qty-control {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 6px;
}

.cart-qty-btn {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 1px solid #ddd;
    background: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
    transition: background 0.15s;
}

.cart-qty-btn:hover {
    background: #e0e0e0;
}

.cart-qty-val {
    font-size: 14px;
    font-weight: 600;
    min-width: 20px;
    text-align: center;
}

.cart-item-del {
    color: #bbb;
    cursor: pointer;
    font-size: 16px;
    margin-left: 4px;
}

.cart-item-del:hover {
    color: #e53;
}

.cart-empty {
    text-align: center;
    padding: 60px 20px;
    color: #aaa;
}

.cart-empty i {
    font-size: 3rem;
    margin-bottom: 12px;
    display: block;
}

.cart-footer {
    padding: 16px 20px;
    border-top: 1px solid #eee;
    flex-shrink: 0;
}

.cart-subtotal {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 15px;
    margin-bottom: 14px;
}

.cart-subtotal .label {
    color: #555;
}

.cart-subtotal .value {
    font-size: 18px;
    font-weight: 700;
    color: #111;
}

.btn-checkout {
    width: 100%;
    padding: 13px;
    background-color: var(--color-main);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    transition: background 0.2s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-checkout:hover {
    background: var(--color-secondary);
    color: #fff;
}

.btn-checkout:disabled {
    opacity: .55;
    cursor: not-allowed;
}

.cart-page-summary-actions .btn-checkout,
.cart-page-summary-actions .btn {
    flex: 1 1 0;
    width: auto;
}

@media (max-width: 575.98px) {
    .cart-page-summary-actions {
        flex-direction: column !important;
    }

    .cart-page-summary-actions .btn-checkout,
    .cart-page-summary-actions .btn {
        width: 100%;
    }
}




/* ── RUTA CARRITO ── */
.cart-page-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 24px;
    align-items: start;
}

.cart-page-panel,
.cart-page-summary {
    background: #fff;
    border: 1px solid #eef0f3;
    border-radius: 18px;
    box-shadow: 0 12px 30px rgba(0, 27, 134, .06);
}

.cart-page-panel {
    padding: 24px;
}

.cart-page-section-title {
    padding-bottom: 18px;
    border-bottom: 1px solid #eef0f3;
    margin-bottom: 18px;
}

.cart-page-items {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.cart-page-item {
    display: grid;
    grid-template-columns: 86px minmax(0, 1fr) auto;
    gap: 16px;
    align-items: center;
    padding: 16px;
    border: 1px solid #eef0f3;
    border-radius: 16px;
    background: #fff;
}

.cart-page-item img {
    width: 86px;
    height: 86px;
    object-fit: contain;
    border-radius: 14px;
    background: #f8f9fb;
    border: 1px solid #eef0f3;
    padding: 8px;
}

.cart-page-item-info h6 {
    margin: 0 0 6px;
    font-size: 1rem;
    color: var(--color-secondary);
    font-weight: 800;
}

.cart-page-item-price {
    color: #777;
    font-size: .9rem;
}

.cart-page-item-subtotal {
    margin-top: 8px;
    color: var(--color-main);
    font-size: 1.05rem;
    font-weight: 800;
}

.cart-page-item-controls {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
}

.cart-page-remove {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid #e53;
    background: #fff5f5;
    color: #e53;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.cart-page-remove:hover {
    background: #e53;
    color: #fff;
}

.cart-page-empty {
    text-align: center;
    padding: 64px 24px;
    color: #999;
}

.cart-page-empty i {
    font-size: 3rem;
    color: var(--color-main);
    margin-bottom: 12px;
    display: block;
}

.cart-page-empty h5 {
    color: var(--color-secondary);
    font-weight: 800;
}

.cart-page-summary {
    position: sticky;
    top: 92px;
    padding: 24px;
    background: linear-gradient(180deg, #fff 0%, #f7f8fb 100%);
}

.cart-page-summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #eef0f3;
    color: #666;
}

.cart-page-summary-row strong {
    color: var(--color-secondary);
}

.cart-page-note {
    color: #888;
    font-size: .85rem;
    line-height: 1.5;
    margin: 14px 0 0;
}

@media(max-width:991px) {
    .cart-page-grid {
        grid-template-columns: 1fr;
    }

    .cart-page-summary {
        position: static;
    }
}

@media(max-width:575px) {
    .cart-page-item {
        grid-template-columns: 72px minmax(0, 1fr);
    }

    .cart-page-item img {
        width: 72px;
        height: 72px;
    }

    .cart-page-item-controls {
        grid-column: 1 / -1;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
}

/* ── MODAL DETALLE PRODUCTO (moderno) ── */
.modal-detalle-moderno {
    max-width: 1140px;
}

.modal-detalle-content {
    border-radius: 16px;
    overflow: hidden;
    background: #fff;
}

.modal-close-btn {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: #fff;
    color: #333;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.10);
    transition: transform 0.15s ease;
    z-index: 5;
}

.modal-close-btn:hover {
    transform: scale(1.05);
    background: #f5f5f5;
}

.detalle-layout {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: 0;
}

.detalle-gallery {
    background: #f7f7f9;
    padding: 24px;
}

.detalle-main-img-wrap {
    background: #fff;
    border-radius: 12px;
    padding: 16px;
    height: 360px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.04);
}

.detalle-main-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.detalle-thumbnails {
    display: flex;
    gap: 10px;
    margin-top: 14px;
    flex-wrap: wrap;
}

.detalle-thumb {
    width: 68px;
    height: 68px;
    object-fit: cover;
    border-radius: 10px;
    border: 2px solid transparent;
    cursor: pointer;
    background: #fff;
    padding: 4px;
    transition: border-color 0.15s ease, transform 0.15s ease;
}

.detalle-thumb:hover {
    border-color: #cbd5e1;
    transform: translateY(-2px);
}

.detalle-thumb.active {
    border-color: var(--color-main);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.06);
}

.detalle-info {
    padding: 28px 28px 22px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.detalle-badge-descuento {
    background: #e53;
    color: #fff;
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 999px;
    font-weight: 700;
    align-self: flex-start;
}

.detalle-nombre {
    font-size: 1.35rem;
    font-weight: 800;
    line-height: 1.25;
    margin: 0;
}

.detalle-precio-block {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.detalle-precio-tachado {
    font-size: 0.95rem;
    color: #94a3b8;
    text-decoration: line-through;
}

.detalle-precio-final {
    font-size: 1.7rem;
    font-weight: 800;
    color: var(--color-main);
}

.detalle-disponibilidad {
    font-size: 0.85rem;
}

.detalle-stock-ok {
    color: #16a34a;
    font-weight: 600;
}

.detalle-stock-no {
    color: #dc2626;
    font-weight: 600;
}

.detalle-descripcion {
    color: #475569;
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}

.detalle-caracteristicas {
    background: #f8fafc;
    border-radius: 10px;
    padding: 12px 14px;
}

.detalle-caract-titulo {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #64748b;
    margin: 0 0 8px;
    font-weight: 700;
}

.detalle-caract-lista {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 6px;
}

.detalle-caract-lista li {
    font-size: 0.9rem;
    color: #334155;
}

.detalle-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.detalle-cantidad-wrap {
    display: flex;
    align-items: center;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
}

.detalle-btn-cantidad {
    width: 40px;
    height: 40px;
    border: none;
    background: transparent;
    color: #0f172a;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.15s ease;
}

.detalle-btn-cantidad:hover {
    background: #f1f5f9;
}

.detalle-cantidad-wrap input {
    width: 48px;
    text-align: center;
    font-weight: 700;
    border: none;
    outline: none;
    color: #0f172a;
}

.detalle-btn-agregar {
    flex: 1;
    height: 44px;
    border: none;
    border-radius: 10px;
    background: var(--color-secondary);
    color: #fff;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.detalle-btn-agregar:hover {
    background: #020d35;
}

.detalle-btn-favorito {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #64748b;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.detalle-btn-favorito:hover {
    color: #e11d48;
    border-color: #fda4af;
    background: #fff1f2;
}

.detalle-btn-favorito.fav-active,
.detalle-btn-favorito.fav-active:hover {
    color: #fff;
    border-color: #e11d48;
    background: #e11d48;
    box-shadow: 0 8px 18px rgba(225, 29, 72, 0.18);
    transform: translateY(-1px);
}

.detalle-btn-favorito.fav-active i {
    color: #fff;
}

.detalle-info-extra {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.detalle-info-item {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #f8fafc;
    border-radius: 10px;
    padding: 10px 12px;
    font-size: 0.85rem;
    color: #334155;
}

.detalle-info-item i {
    color: var(--color-main);
    font-size: 1rem;
}

/* Relacionados */
.detalle-relacionados {
    border-top: 1px solid #e2e8f0;
    padding: 18px 24px 22px;
    background: #fafafa;
}

.detalle-rel-titulo {
    font-weight: 800;
    color: #0f172a;
    font-size: 1rem;
}

.detalle-rel-track {
    display: flex;
    gap: 14px;
    overflow-x: auto;
    padding-bottom: 6px;
    scroll-behavior: smooth;
}

.detalle-rel-card {
    min-width: 208px;
    max-width: 208px;
    background: #fff;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.detalle-rel-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
    border-color: #cbd5e1;
}

.detalle-rel-img-wrap {
    height: 150px;
    background: #f7f7f9;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
}

.detalle-rel-img-wrap img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.detalle-rel-body {
    padding: 10px 12px 12px;
}

.detalle-rel-nombre {
    font-size: 0.85rem;
    font-weight: 700;
    color: #0f172a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.detalle-rel-precio {
    font-size: 0.9rem;
    font-weight: 800;
    color: var(--color-main);
    margin-top: 4px;
}

.detalle-rel-nav {
    display: flex;
    gap: 8px;
}

.detalle-rel-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #334155;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.detalle-rel-btn:hover {
    background: #f1f5f9;
    border-color: #cbd5e1;
}

/* Responsive modal */
@media(max-width: 991px) {
    .detalle-layout {
        grid-template-columns: 1fr;
    }

    .detalle-gallery {
        padding: 16px;
    }

    .detalle-main-img-wrap {
        height: 260px;
    }

    .detalle-info {
        padding: 18px;
    }
}

@media(max-width: 576px) {
    .modal-detalle-moderno {
        max-width: min(100vw - 16px, 420px);
        margin: 8px auto;
    }

    .modal-detalle-content {
        border-radius: 18px;
        max-height: calc(100dvh - 16px);
        overflow: hidden;
    }

    #modalProductoDetalle .modal-dialog {
        align-items: center;
        height: 100dvh;
    }

    #modalProductoDetalle .modal-body {
        padding: 10px;
    }

    .detalle-layout {
        gap: 0;
    }

    .detalle-gallery {
        padding: 12px 12px 8px;
    }

    .detalle-main-img-wrap {
        height: 170px;
        padding: 10px;
        border-radius: 10px;
    }

    .detalle-thumbnails {
        gap: 8px;
        margin-top: 10px;
    }

    .detalle-thumb {
        width: 48px;
        height: 48px;
        border-radius: 8px;
    }

    .detalle-info {
        padding: 12px 12px 10px;
        gap: 8px;
    }

    .detalle-badge-descuento {
        font-size: 11px;
        padding: 3px 8px;
    }

    .detalle-nombre {
        font-size: 0.98rem;
        line-height: 1.2;
    }

    .detalle-precio-tachado {
        font-size: 0.82rem;
    }

    .detalle-precio-final {
        font-size: 1.05rem;
    }

    .detalle-descripcion {
        font-size: 0.78rem;
        line-height: 1.45;
    }

    .detalle-caracteristicas {
        padding: 10px 12px;
        border-radius: 8px;
    }

    .detalle-caract-titulo {
        font-size: 0.7rem;
        margin-bottom: 6px;
    }

    .detalle-caract-lista li {
        font-size: 0.78rem;
    }

    .detalle-actions {
        gap: 8px;
        flex-wrap: wrap;
    }

    .detalle-cantidad-wrap {
        border-radius: 8px;
    }

    .detalle-btn-cantidad {
        width: 34px;
        height: 34px;
        font-size: 0.9rem;
    }

    .detalle-cantidad-wrap input {
        width: 42px;
        font-size: 0.85rem;
    }

    .detalle-btn-agregar {
        height: 38px;
        font-size: 0.85rem;
        border-radius: 8px;
    }

    .detalle-btn-favorito {
        width: 38px;
        height: 38px;
        border-radius: 8px;
    }

    .detalle-info-extra {
        grid-template-columns: 1fr;
        gap: 6px;
    }

    .detalle-info-item {
        padding: 8px 10px;
        font-size: 0.75rem;
        border-radius: 8px;
    }

    .detalle-relacionados {
        padding: 12px 12px 14px;
    }

    .detalle-rel-titulo {
        font-size: 0.9rem;
    }

    .detalle-rel-card {
        min-width: 144px;
        max-width: 144px;
    }

    .detalle-rel-img-wrap {
        height: 108px;
        padding: 8px;
    }

    .detalle-rel-body {
        padding: 8px 10px 10px;
    }

    .detalle-rel-nombre {
        font-size: 0.76rem;
    }

    .detalle-rel-precio {
        font-size: 0.82rem;
    }

    .detalle-rel-btn {
        width: 28px;
        height: 28px;
    }
}

@media(max-width: 390px) {
    .modal-detalle-moderno {
        max-width: calc(100vw - 10px);
        margin: 5px auto;
    }

    .modal-detalle-content {
        border-radius: 16px;
        max-height: calc(100dvh - 10px);
    }

    #modalProductoDetalle .modal-body {
        padding: 8px;
    }

    .detalle-gallery {
        padding: 10px 10px 6px;
    }

    .detalle-main-img-wrap {
        height: 150px;
        padding: 8px;
    }

    .detalle-thumb {
        width: 42px;
        height: 42px;
    }

    .detalle-info {
        padding: 10px 10px 8px;
        gap: 7px;
    }

    .detalle-nombre {
        font-size: 0.92rem;
    }

    .detalle-precio-final {
        font-size: 0.98rem;
    }

    .detalle-descripcion {
        font-size: 0.74rem;
    }

    .detalle-btn-agregar {
        height: 36px;
        font-size: 0.8rem;
    }

    .detalle-btn-favorito {
        width: 36px;
        height: 36px;
    }

    .detalle-rel-card {
        min-width: 132px;
        max-width: 132px;
    }

    .detalle-rel-img-wrap {
        height: 98px;
    }
}


/* --- ESTILOS ADICIONALES PARA PRODUCT CARD PREMIUM --- */
.product-card {
    background-color: #ffffff;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(255, 102, 0, 0.12) !important;
}

.product-actions-vertical {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 10;
    transition: opacity 0.2s ease;
    opacity: 0;
    pointer-events: none;
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    padding: 6px;
}

.product-card:hover .product-actions-vertical {
    opacity: 1;
    pointer-events: auto;
}

.product-actions-vertical .action-btn {
    background: #fff;
    border: none;
    border-radius: 6px;
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #444;
    font-size: 1.1rem;
    transition: all 0.2s ease;
    cursor: pointer;
}

.product-actions-vertical .action-btn:hover {
    background-color: var(--color-main);
    color: #fff;
}

.product-actions-vertical .action-btn.fav-active,
.product-actions-vertical .action-btn.fav-active:hover {
    background-color: #e11d48;
    color: #fff;
}

.product-actions-vertical .action-btn.fav-active i {
    color: #fff;
}

.img-hover-zoom {
    transition: transform 0.5s ease !important;
}

.product-card:hover .img-hover-zoom {
    transform: scale(1.06);
}

.btn-cart-add-dynamic {
    background-color: var(--color-secondary);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    height: 40px;
    width: 100%;
    cursor: pointer;
}

.btn-cart-add-dynamic .btn-icon {
    display: none;
    font-size: 1.2rem;
}

.btn-cart-add-dynamic .btn-text {
    display: inline-block;
}

.btn-cart-add-dynamic:hover {
    background-color: var(--color-main);
}

.product-card:hover .btn-cart-add-dynamic {
    background-color: var(--color-secondary);
}

.product-card:hover .btn-cart-add-dynamic .btn-text {
    display: none;
}

.product-card:hover .btn-cart-add-dynamic .btn-icon {
    display: inline-block;
}

/*PERZONALISADO  MANUAL*/
@media (max-width: 576px) {

    main,
    header,
    footer {
        padding: 0 10px;
    }

    .category-menu-panel {
        transform: translateX(-100%);
        width: 0;
        min-width: 0;
        overflow: hidden;
        transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1), width 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .category-menu-panel.expanded {
        transform: translateX(0);
        width: min(270px, calc(100vw - 20px));
    }

    .navbar-secondary {
        display: flex !important;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        -ms-overflow-style: none;
        flex-wrap: nowrap !important;
    }

    .navbar-secondary ul {
        flex-wrap: nowrap !important;
    }


}

/* ── Modal Detalle Producto — Responsive ── */
#modalProductoDetalle .modal-dialog {
    max-width: 95vw;
}

#modalProductoDetalle .modal-content {
    border-radius: 14px;
}

#modalProductoDetalle .modal-body {
    padding: 16px;
}

#modalProductoDetalle .carousel-item img,
#modalProductoDetalle .carousel-item video {
    max-height: 300px;
    object-fit: contain;
}

@media (max-width: 576px) {
    .accordion-item  {
        border-bottom: var(--bs-border-width) var(--bs-border-style) rgba(255, 255, 255, 0.45) !important;
    }

    #modalProductoDetalle .modal-dialog {
        margin: 10px auto;
        max-width: 100%;
    }

    #modalProductoDetalle .modal-content {
        border-radius: 10px;
    }

    #modalProductoDetalle .modal-body {
        padding: 12px;
    }

    #modalProductoDetalle .carousel-item img,
    #modalProductoDetalle .carousel-item video {
        max-height: 220px;
    }

    #modalProductoDetalle .col-lg-5,
    #modalProductoDetalle .col-lg-7 {
        width: 100%;
        flex: 0 0 100%;
    }
}

/* ════════════════════════════════════════════════
   BUSCADOR DEL HEADER — estilos del panel de resultados
   ════════════════════════════════════════════════ */

/* Cabecera del panel: "N resultados para '...'" */
.search-results-header {
    padding: 8px 14px;
    font-size: 0.78rem;
    color: #666;
    border-bottom: 1px solid #f0f0f5;
    background: #fafafa;
    border-radius: 6px 6px 0 0;
}

/* Lista de tarjetas */
.search-results-list {
    display: flex;
    flex-direction: column;
}

/* Tarjeta individual */
.search-result-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    cursor: pointer;
    transition: background 0.15s;
    border-bottom: 1px solid #f4f4f8;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover {
    background: #f5f7ff;
}

/* Imagen */
.sr-img-wrap {
    position: relative;
    flex-shrink: 0;
    width: 54px;
    height: 54px;
    border-radius: 6px;
    overflow: hidden;
    background: #f0f0f5;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sr-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Badge descuento sobre imagen */
.sr-badge {
    position: absolute;
    top: 2px;
    left: 2px;
    background: var(--color-main, #001b86);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 1px 5px;
    border-radius: 4px;
    line-height: 1.4;
    z-index: 1;
}

/* Cuerpo de texto */
.sr-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.sr-nombre {
    font-size: 0.84rem;
    font-weight: 600;
    color: #222;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Stock */
.sr-stock {
    font-size: 0.72rem;
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.sr-stock.ok {
    color: #198754;
}

.sr-stock.out {
    color: #dc3545;
}

/* Precios */
.sr-prices {
    display: flex;
    align-items: baseline;
    gap: 6px;
}

.sr-price-old {
    font-size: 0.72rem;
    color: #aaa;
    text-decoration: line-through;
}

.sr-price-new {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--color-main, #001b86);
}

/* Botón agregar al carrito */
.sr-btn-cart {
    flex-shrink: 0;
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 8px;
    background: var(--color-main, #001b86);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.15s, transform 0.1s;
}

.sr-btn-cart:hover:not(:disabled) {
    background: var(--color-secondary, #010f46);
    transform: scale(1.05);
}

.sr-btn-cart:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Sin resultados */
.search-no-results {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
    color: #aaa;
    gap: 8px;
}

.search-no-results i {
    font-size: 1.8rem;
}

.search-no-results p {
    font-size: 0.85rem;
    margin: 0;
    text-align: center;
    color: #888;
}

/* Skeleton loader */
.search-result-skeleton {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    border-bottom: 1px solid #f4f4f8;
}

.sr-skel-img {
    width: 54px;
    height: 54px;
    border-radius: 6px;
    background: linear-gradient(90deg, #eee 25%, #f5f5f5 50%, #eee 75%);
    background-size: 200% 100%;
    animation: sr-shimmer 1.2s infinite;
    flex-shrink: 0;
}

.sr-skel-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.sr-skel-line {
    height: 11px;
    border-radius: 4px;
    background: linear-gradient(90deg, #eee 25%, #f5f5f5 50%, #eee 75%);
    background-size: 200% 100%;
    animation: sr-shimmer 1.2s infinite;
}

.sr-skel-line.short {
    width: 55%;
}

.sr-skel-line.price {
    width: 35%;
    height: 14px;
}

@keyframes sr-shimmer {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

/*EXTRA PESONALIZADO*/
.accordion-item {
    background-color: transparent !important;
}

.accordion-item .fs-6 {
    font-size: 0.85rem !important;
    font-weight: 600 !important;
}

#footerAccordion .accordion-button::after {
    filter: brightness(0) invert(1);
}
