/* header-icons.css - Estilos para iconos de buscar, usuario y carrito */
/* SOLO afecta a .header-actions - No modifica otros elementos */

.header-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

/* Ocultar el botón naranja de Solicitar Soporte */
.header-actions .nav-cta {
    display: none !important;
}

/* Ocultar iconos clonados en desktop */
.mobile-header-icons {
    display: none !important;
}

/* Iconos del header */
.header-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    border: none;
    background: #21485D;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    color: white;
    text-decoration: none;
}

.header-icon:hover {
    background-color: #1B3A4B;
    color: #22d3ee;
}

.header-icon svg {
    width: 24px;
    height: 24px;
    stroke: currentColor;
    stroke-width: 1.5;
    fill: none;
}

/* Badge del carrito */
.header-icon .cart-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    background: var(--accent-color, #1D4ED8);
    color: white;
    font-size: 0.7rem;
    font-weight: 700;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.header-icon .cart-badge:empty,
.header-icon .cart-badge[data-count="0"] {
    display: none;
}

/* Search overlay (para cuando se implemente) */
.search-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9998;
}

.search-overlay.active {
    display: block;
}

.search-modal {
    position: fixed;
    top: 80px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 540px;
    background: transparent;
    z-index: 9999;
    display: none;
}

.search-modal.active {
    display: block;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.search-modal .search-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.search-modal input {
    width: 100%;
    padding: 0.85rem 2.5rem 0.85rem 1.2rem;
    font-size: 1rem;
    border: none;
    border-radius: 50px;
    outline: none;
    background: white;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.25);
    box-sizing: border-box;
}

.search-modal input:focus {
    box-shadow: 0 8px 30px rgba(30, 64, 175, 0.3);
}

.search-modal .search-close {
    position: absolute;
    right: 0.6rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
    color: #9ca3af;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-modal .search-close:hover {
    color: #374151;
}

.search-modal #searchResults:not(:empty) {
    background: white;
    border-radius: 12px;
    margin-top: 8px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

/* Responsive - Mobile: ocultar iconos del header, mostrar dentro del menú */
@media (max-width: 768px) {
    .header-actions {
        display: none !important;
    }

    .nav-links .mobile-header-icons {
        display: flex !important;
        justify-content: center;
        gap: 12px;
        padding: 15px 0 5px;
        margin-top: 5px;
        border-top: 1px solid rgba(0, 0, 0, 0.08);
        width: 100%;
    }

    .nav-links .mobile-header-icons .header-icon {
        width: 40px;
        height: 40px;
        color: white !important;
        background: #21485D !important;
    }

    .nav-links .mobile-header-icons .header-icon svg {
        width: 22px;
        height: 22px;
        stroke: white !important;
    }
}
