/*
 * Custom code goes here.
 * A template should always ship with an empty custom.css
 */

/* Neutralizar stacking contexts que atrapan el menú mobile
   - #header { z-index: 100 } atrapa el menú cuando no está sticky
   - #mobile-header-sticky { z-index: 5000 } lo atrapa cuando está sticky
   Sin z-index, position:fixed igual funciona para sticky — solo pierde la
   competencia contra otros elementos posicionados, que no existen en esta página */
#header {
    z-index: initial !important;
}

#mobile-header-sticky.stuck-down,
#mobile-header-sticky.stuck-up.visible-stuck-up,
#mobile-header-sticky.stuck-up.visible-stuck-up-scroll {
    z-index: initial !important;
}

/* El menú ya tiene z-index:5005 en theme.css — ahora aplica en root context */

/* Touchspin horizontal en carrito */
.cart-items .bootstrap-touchspin {
    max-width: 120px;
    flex-wrap: nowrap;
}

.cart-items .bootstrap-touchspin .btn-touchspin {
    height: auto;
    min-height: 38px;
    padding: 0 10px;
    line-height: 1;
    flex-shrink: 0;
}

.cart-items .bootstrap-touchspin input {
    min-width: 0;
    text-align: center;
}

/* Barra de búsqueda mobile siempre visible */
.mobile-search-bar {
    padding: 8px 0 10px;
}

.mobile-search-bar .input-group {
    background: #f5f5f5;
    border-radius: 6px;
    overflow: hidden;
}

.mobile-search-bar .form-search-control {
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 9px 12px;
    font-size: 14px;
}

.mobile-search-bar .form-search-control:focus {
    background: transparent;
    box-shadow: none;
}

.mobile-search-bar .search-btn {
    background: transparent;
    border: none;
    padding: 0 14px;
    color: #555;
    font-size: 15px;
}

/* Overlay */
#mobile-menu-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 5003;
    opacity: 0;
    transition: opacity 0.3s ease;
}

#mobile-menu-overlay.is-active {
    display: block;
    opacity: 1;
}
