/* ============================================
   Grupo Dos — Custom Header
   Professional, minimalist design
   ============================================ */

/* --- Reset & Base --- */
.gdos-header {
    width: 100%;
    position: relative;
    z-index: 500;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    -webkit-font-smoothing: antialiased;
}

.gdos-header *,
.gdos-header *::before,
.gdos-header *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* --- Announcement Bar --- */
.gdos-announcement {
    background: #111;
    color: #fff;
    overflow: hidden;
    white-space: nowrap;
    height: 36px;
    line-height: 36px;
    font-size: 12.5px;
    letter-spacing: 0.3px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.gdos-announcement-track {
    display: inline-flex;
    animation: gdos-marquee 60s linear infinite;
    gap: 0;
}

.gdos-announcement-item {
    padding: 0 16px;
    flex-shrink: 0;
}

.gdos-announcement-sep {
    color: rgba(255,255,255,0.3);
    font-size: 10px;
    padding: 0 4px;
    flex-shrink: 0;
}

@keyframes gdos-marquee {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.gdos-announcement:hover .gdos-announcement-track {
    animation-play-state: paused;
}

/* --- Main Header --- */
.gdos-header-main {
    background: #000;
    padding: 0 24px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.gdos-header-inner {
    display: flex;
    align-items: center;
    height: 70px;
    max-width: 1400px;
    margin: 0 auto;
    gap: 24px;
}

/* Left: Hamburger + Logo */
.gdos-header-left {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
}

/* Hamburger Button */
.gdos-hamburger {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: transparent !important;
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
    -webkit-appearance: none;
    appearance: none;
    color: #fff !important;
    cursor: pointer;
    padding: 6px 0;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.5px;
    -webkit-text-fill-color: #fff !important;
    transition: opacity 0.2s;
}

.gdos-hamburger:hover {
    opacity: 0.8;
}

.gdos-hamburger-lines {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    width: 20px;
    height: 20px;
}

.gdos-hamburger-lines span {
    display: block;
    width: 100%;
    height: 2px;
    background: #fff;
    border-radius: 1px;
    transition: transform 0.3s ease, opacity 0.3s ease;
    transform-origin: center;
}

/* Hamburger animation on active */
.gdos-hamburger.active .gdos-hamburger-lines span:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}

.gdos-hamburger.active .gdos-hamburger-lines span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.gdos-hamburger.active .gdos-hamburger-lines span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}

.gdos-quicklinks-sep {
    width: 1px;
    height: 16px;
    background: rgba(255,255,255,0.25);
    flex-shrink: 0;
}

/* Logo */
.gdos-logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.gdos-logo-desktop {
    display: block;
    height: 50px;
    width: auto;
}

.gdos-logo-mobile {
    display: none;
    height: 40px;
    width: auto;
}



/* Center: Search */
.gdos-header-center {
    flex: 1;
    max-width: 600px;
    margin: 0 auto;
    position: relative;
}

/* Right: Icons */
.gdos-header-right {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.gdos-header-icon {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #fff;
    padding: 6px 12px;
    border-radius: 8px;
    transition: background 0.2s;
    position: relative;
    gap: 2px;
}

.gdos-header-icon:hover {
    background: rgba(255,255,255,0.08);
    color: #fff;
}

.gdos-icon-label {
    font-size: 10.5px;
    color: rgba(255,255,255,0.6);
    letter-spacing: 0.2px;
    white-space: nowrap;
}

.gdos-header-icon:hover .gdos-icon-label {
    color: rgba(255,255,255,0.9);
}

/* Cart count badge */
.gdos-icon-cart svg {
    position: relative;
}

.gdos-cart-count {
    position: absolute;
    top: 0;
    left: 14px;
    background: #e53935;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    min-width: 16px;
    height: 16px;
    line-height: 16px;
    text-align: center;
    border-radius: 8px;
    padding: 0 3px;
}

.gdos-cart-count:empty {
    display: none;
}

/* Cart icon layout - total to the right */
.gdos-icon-cart {
    flex-direction: row !important;
    gap: 6px !important;
}

/* Cart subtotal label */
.gdos-cart-total {
    font-size: 13px;
    font-weight: 600;
    color: rgba(255,255,255,0.85);
    letter-spacing: 0.2px;
    white-space: nowrap;
}

.gdos-cart-total:empty {
    display: none;
}

.gdos-header-icon:hover .gdos-cart-total {
    color: #fff;
}

/* --- Quick Links Bar --- */
.gdos-quicklinks {
    background: #000;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding: 0 24px;
}

.gdos-quicklinks-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 28px;
    height: 40px;
    max-width: 1400px;
    margin: 0 auto;
}

.gdos-quicklink {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: rgba(255,255,255,0.85);
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.3px;
    transition: color 0.2s;
    white-space: nowrap;
}

.gdos-quicklink:hover {
    color: #fff;
}

.gdos-quicklink-flash {
    color: #ffd740;
    font-weight: 700;
}

.gdos-quicklink-flash:hover {
    color: #ffeb3b;
}

/* Body scroll lock when menu is open */
body.gdos-menu-open {
    position: fixed !important;
    width: 100% !important;
    overflow: hidden !important;
}

/* ============================================
   Sidebar Menu
   ============================================ */

.gdos-menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(2px);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.gdos-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

nav.gdos-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 340px;
    max-width: 90vw;
    height: 100vh;
    height: 100dvh;
    background: #fff;
    z-index: 9999;
    transform: translateX(-100%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

nav.gdos-sidebar.active {
    transform: translateX(0);
}

/* Sidebar Header */
.gdos-sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid #eee;
    flex-shrink: 0;
}

.gdos-sidebar-title {
    font-size: 18px;
    font-weight: 700;
    color: #111;
    letter-spacing: -0.3px;
}

.gdos-sidebar-close {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
    background: transparent !important;
    border: 2px solid #ccc !important;
    border-radius: 50% !important;
    cursor: pointer !important;
    color: #333 !important;
    padding: 0 !important;
    margin: 0 !important;
    -webkit-appearance: none !important;
    appearance: none !important;
    outline: none !important;
    box-shadow: none !important;
    transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.2s;
}

.gdos-sidebar-close svg {
    width: 20px !important;
    height: 20px !important;
}

.gdos-sidebar-close:hover {
    background: #f5f5f5 !important;
    border-color: #999 !important;
    color: #000 !important;
    transform: rotate(90deg);
}

/* Sidebar Search */
.gdos-sidebar-search {
    padding: 12px 20px;
    border-bottom: 1px solid #eee;
    flex-shrink: 0;
}

.gdos-sidebar-search form {
    display: flex;
    align-items: center;
    background: #f5f5f5;
    border-radius: 8px;
    overflow: hidden;
}

.gdos-sidebar-search input[type="search"] {
    flex: 1;
    background: none;
    border: none;
    outline: none;
    padding: 10px 14px;
    font-size: 14px;
    color: #333;
    font-family: inherit;
}

.gdos-sidebar-search button {
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    padding: 10px 12px;
    cursor: pointer;
    color: #999;
}

/* Sidebar Sections */
.gdos-sidebar-section {
    flex-shrink: 0;
}

.gdos-sidebar-section:not(.gdos-sidebar-links) {
    flex: 1 1 0;
    min-height: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.gdos-sidebar-section-title {
    padding: 14px 20px 8px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #999;
}

/* Menu Items */
.gdos-sidebar-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.gdos-menu-item {
    border-bottom: 1px solid #f0f0f0;
}

.gdos-menu-item > a,
.gdos-menu-item-row > a {
    display: block;
    padding: 13px 20px;
    color: #222;
    text-decoration: none;
    font-size: 14.5px;
    font-weight: 500;
    transition: background 0.15s, color 0.15s;
}

.gdos-menu-item > a:hover,
.gdos-menu-item-row > a:hover {
    background: #fafafa;
    color: #000;
}

.gdos-menu-item-row {
    display: flex;
    align-items: center;
}

.gdos-menu-item-row > a {
    flex: 1;
}

.gdos-submenu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: none;
    border: none;
    border-left: 1px solid #f0f0f0;
    cursor: pointer;
    color: #999;
    transition: background 0.15s, color 0.15s, transform 0.3s;
    flex-shrink: 0;
}

.gdos-submenu-toggle:hover {
    background: #f5f5f5;
    color: #333;
}

.gdos-submenu-toggle.active {
    transform: rotate(180deg);
    color: #333;
}

/* Submenu */
.gdos-submenu {
    list-style: none;
    padding: 0;
    margin: 0;
    background: #fafafa;
}

.gdos-submenu-item > a {
    display: block;
    padding: 10px 20px 10px 36px;
    color: #555;
    text-decoration: none;
    font-size: 13.5px;
    font-weight: 400;
    transition: background 0.15s, color 0.15s;
    border-bottom: 1px solid #f0f0f0;
}

.gdos-submenu-item > a:hover {
    background: #f0f0f0;
    color: #111;
}

/* Sidebar Bottom Links */
.gdos-sidebar-links {
    border-top: 1px solid #eee;
    padding: 12px 20px;
    flex-shrink: 0;
}

.gdos-sidebar-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 0;
    color: #444;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.15s;
}

.gdos-sidebar-link:hover {
    color: #000;
}

/* ============================================
   Responsive
   ============================================ */



/* Sidebar close button - force styles */
#gdos-sidebar .gdos-sidebar-close,
nav.gdos-sidebar .gdos-sidebar-close,
button.gdos-sidebar-close {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
    min-height: 40px !important;
    background: #f5f5f5 !important;
    border: none !important;
    border-radius: 50% !important;
    cursor: pointer !important;
    color: #333 !important;
    padding: 0 !important;
    margin: 0 !important;
    -webkit-appearance: none !important;
    appearance: none !important;
    outline: none !important;
    box-shadow: none !important;
    flex-shrink: 0 !important;
}

#gdos-sidebar .gdos-sidebar-close:hover,
button.gdos-sidebar-close:hover {
    background: #e8e8e8 !important;
    color: #000 !important;
}

/* Sidebar accordion toggle arrows */
.gdos-submenu-toggle {
    -webkit-appearance: none !important;
    appearance: none !important;
    outline: none !important;
    box-shadow: none !important;
}

/* Mobile hamburger - hidden on desktop */
.gdos-hamburger-mobile {
    display: none !important;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 36px;
    height: 36px;
    background: transparent !important;
    border: none !important;
    outline: none !important;
    cursor: pointer;
    padding: 0;
    gap: 5px;
    -webkit-appearance: none;
}

.gdos-hamburger-mobile span {
    display: block;
    width: 20px;
    height: 2px;
    background: #fff;
    border-radius: 1px;
    transition: transform 0.3s ease, opacity 0.3s ease;
    transform-origin: center;
}

.gdos-hamburger-mobile.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.gdos-hamburger-mobile.active span:nth-child(2) {
    opacity: 0;
}

.gdos-hamburger-mobile.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 768px) {
    .gdos-cart-total { display: none !important; }
    .gdos-header-main {
        padding: 0 14px 12px;
    }

    .gdos-header-inner {
        height: auto;
        gap: 0;
        flex-wrap: wrap;
        padding-top: 10px;
    }

    .gdos-header-left {
        display: flex;
        align-items: center;
        justify-content: center;
        flex: 1;
    }

    .gdos-logo-desktop {
        display: none;
    }

    .gdos-logo-mobile {
        display: block;
        height: 55px;
    }

    /* Show mobile hamburger */
    .gdos-hamburger-mobile {
        display: flex !important;
    }

    .gdos-header-right {
        flex: 0 0 auto;
    }

    /* Search as second row, inside the header background */
    .gdos-header-center {
        display: block !important;
        order: 10;
        flex: none;
        width: 100%;
        max-width: 100%;
        margin: 10px 0 0;
        padding: 0;
    }

    .gdos-search-form {
        height: 42px;
        border-radius: 10px;
        background: rgba(255,255,255,0.12) !important;
        border-color: rgba(255,255,255,0.18) !important;
    }

    .gdos-search-form:focus-within {
        background: rgba(255,255,255,0.97) !important;
    }

    .gdos-search-input {
        font-size: 16px;
        height: 42px;
    }

    .gdos-search-dropdown {
        min-width: unset;
        border-radius: 10px;
        left: 0;
        right: 0;
        width: 100%;
    }

    .gdos-icon-label {
        display: none;
    }

    .gdos-icon-account,
    .gdos-icon-wishlist {
        display: none;
    }

    .gdos-header-icon {
        padding: 6px 8px;
    }

    .gdos-quicklinks {
        display: none;
    }

    .gdos-announcement {
        height: 32px;
        line-height: 32px;
        font-size: 11px;
    }

    /* Sidebar full width on mobile */
    nav.gdos-sidebar {
        width: 100%;
        max-width: 100vw;
    }
}

@media (max-width: 480px) {
    .gdos-header-main {
        padding: 0 12px 10px;
    }

    .gdos-logo-mobile {
        height: 48px;
    }

    .gdos-hamburger-mobile {
        width: 32px;
        height: 32px;
    }

    .gdos-hamburger-mobile span {
        width: 18px;
    }

    .gdos-search-form {
        height: 40px;
    }

    .gdos-search-input {
        height: 40px;
        font-size: 16px;
    }

    .gdos-search-dropdown {
        left: 0;
        right: 0;
        width: 100%;
    }
}

/* --- Fix body spacing when header is present --- */
body.gdos-has-header {
    padding-top: 0;
}

/* Hide Woodmart header elements that might still render */
.whb-header,
.whb-sticked,
.whb-clone {
    display: none !important;
}

/* === Custom Search Bar === */
.gdos-search-wrap {
    position: relative;
    width: 100%;
}

.gdos-search-form {
    display: flex;
    align-items: center;
    background: rgba(255,255,255,0.08);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 12px;
    height: 46px;
    border: 1px solid rgba(255,255,255,0.15);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.gdos-search-form:focus-within {
    background: rgba(255,255,255,0.97);
    border-color: rgba(0,0,0,0.08);
    box-shadow: 0 8px 32px rgba(0,0,0,0.12), 0 2px 8px rgba(0,0,0,0.06);
}

.gdos-search-icon {
    flex-shrink: 0;
    margin-left: 16px;
    color: rgba(255,255,255,0.4);
    transition: color 0.3s ease;
    pointer-events: none;
}

.gdos-search-form:focus-within .gdos-search-icon {
    color: #999;
}

.gdos-search-input {
    flex: 1;
    background: transparent !important;
    border: none !important;
    outline: none !important;
    color: rgba(255,255,255,0.9);
    -webkit-text-fill-color: rgba(255,255,255,0.9);
    font-size: 14px;
    font-weight: 400;
    padding: 0 12px;
    height: 46px;
    letter-spacing: 0.2px;
    font-family: inherit;
    transition: color 0.3s ease;
    caret-color: transparent;
}

.gdos-search-form:focus-within .gdos-search-input {
    color: #222;
    -webkit-text-fill-color: #222;
    caret-color: #222;
}

.gdos-search-input::placeholder {
    color: rgba(255,255,255,0.35);
    -webkit-text-fill-color: rgba(255,255,255,0.35);
    font-weight: 300;
    transition: color 0.3s ease;
}

.gdos-search-form:focus-within .gdos-search-input::placeholder {
    color: #bbb;
    -webkit-text-fill-color: #bbb;
}

.gdos-search-clear {
    display: none;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    margin-right: 8px;
    font-size: 20px;
    color: #999;
    cursor: pointer;
    border-radius: 50%;
    transition: background 0.15s, color 0.15s;
    flex-shrink: 0;
    line-height: 1;
}

.gdos-search-clear.visible {
    display: flex;
}

.gdos-search-clear:hover {
    background: #f0f0f0;
    color: #555;
}

/* === Search Dropdown === */
.gdos-search-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    z-index: 99999;
    display: none;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.18), 0 4px 20px rgba(0,0,0,0.1);
    border: 1px solid rgba(0,0,0,0.06);
    overflow: hidden;
    max-height: 520px;
    overflow-y: auto;

}

.gdos-search-dropdown.active {
    display: block;
}



/* Header "Productos" */
.gdos-search-header {
    padding: 14px 20px 10px;
    border-bottom: 1px solid #f0f0f0;
}

.gdos-search-header span {
    font-size: 11.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: #888;
}

/* Results list */
.gdos-search-list {
    padding: 4px 0;
}

.gdos-search-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 20px;
    text-decoration: none;
    transition: background 0.12s ease;
    cursor: pointer;
    border-bottom: 1px solid rgba(0,0,0,0.04);
    position: relative;
}

.gdos-search-item:last-child {
    border-bottom: none;
}

.gdos-search-item:hover {
    background: #f8f9fa;
}

.gdos-search-item-img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    border-radius: 8px;
    background: #f8f8f8;
    flex-shrink: 0;
    border: 1px solid #eee;
    padding: 4px;
}

.gdos-search-item-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.gdos-search-item-title {
    font-size: 14px;
    font-weight: 500;
    color: #222;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.gdos-search-item-price {
    font-size: 15px;
    font-weight: 700;
    color: #e53935;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.gdos-search-item-price del {
    color: #bbb;
    font-weight: 400;
    font-size: 13px;
    text-decoration: line-through;
}

.gdos-search-item-price strong {
    color: #e53935;
    font-weight: 700;
}

.gdos-search-item-badge {
    flex-shrink: 0;
    background: #e53935;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    padding: 3px 6px;
    border-radius: 4px;
    line-height: 1;
    align-self: center;
    margin-left: auto;
}

/* View all results */
.gdos-search-viewall {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 16px 20px;
    background: #fafafa;
    color: #555;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    border-top: 1px solid #eee;
    transition: background 0.15s, color 0.15s;
}

.gdos-search-viewall:hover {
    background: #f0f0f0;
    color: #000;
}

/* Loading state */
.gdos-search-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 32px 16px;
    color: #999;
    font-size: 13px;
}

.gdos-search-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid #eee;
    border-top-color: #999;
    border-radius: 50%;
    animation: gdos-spin 0.6s linear infinite;
}

@keyframes gdos-spin {
    to { transform: rotate(360deg); }
}

/* Empty state */
.gdos-search-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 32px 16px;
    color: #999;
    font-size: 13px;
    text-align: center;
}

.gdos-search-empty p {
    margin: 0;
}

.gdos-search-empty strong {
    color: #555;
}



/* Cart sidebar - Ver Carrito button hover fix */
.cart-widget-side .woocommerce-mini-cart__buttons .button.wc-forward:not(.checkout) {
    --btn-color-hover: #fff;
    --btn-bgcolor-hover: #333;
    --btn-brd-color-hover: #333;
}
