/* ==========================================================================
   ElectroPC — Header Styles (diseño tipo web-epc)
   2 filas: Logo+Search+Actions | Nav pills + mega dropdown
   ========================================================================== */

/* ---- Site Header container ---- */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: var(--z-sticky, 100);
    background: var(--color-header-bg, rgba(10, 10, 20, 0.95));
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--color-border-light, rgba(255,255,255,0.06));
    transition: background 0.3s, box-shadow 0.3s;
}

/* Cuando la admin bar de WP está activa (logueado) */
.admin-bar .site-header {
    top: 32px;
}

@media (max-width: 782px) {
    .admin-bar .site-header {
        top: 46px; /* admin bar mobile es 46px */
    }
}

/* Compensar altura del header fijo (dinámico via JS) */
body {
    padding-top: var(--electropc-header-offset, 110px);
}

[data-theme="light"] .site-header {
    background: rgba(255, 255, 255, 0.97);
    border-bottom-color: var(--color-border, #e5e7eb);
}

.site-header.is-scrolled {
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.15);
}

/* ==========================================================================
   ROW 1: Logo — Search — Actions
   ========================================================================== */
.header-top {
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

[data-theme="light"] .header-top {
    border-bottom-color: var(--color-border, #e5e7eb);
}

.header-top__inner {
    display: flex;
    align-items: center;
    gap: var(--space-6, 1.5rem);
    height: 64px;
}

/* ---- Logo ---- */
.site-branding {
    flex-shrink: 0;
}

.site-branding a {
    display: flex;
    align-items: center;
}

.site-branding img {
    height: 38px;
    width: auto;
}

/* Logo switch claro/oscuro */
.logo-dark { display: block; }
.logo-light { display: none; }
[data-theme="light"] .logo-dark { display: none; }
[data-theme="light"] .logo-light { display: block; }

/* ---- Search Bar ---- */
.header-search {
    flex: 1;
    max-width: 560px;
    margin: 0 auto;
}

.header-search__form {
    position: relative;
    display: flex;
    align-items: center;
}

.header-search__icon {
    position: absolute;
    left: 14px;
    display: flex;
    color: rgba(255, 255, 255, 0.4);
    pointer-events: none;
}

[data-theme="light"] .header-search__icon {
    color: var(--color-text-muted, #999);
}

.header-search__input {
    width: 100%;
    padding: 10px 16px 10px 42px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-full, 999px);
    font-size: 14px;
    color: #fff;
    outline: none;
    transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}

.header-search__input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.header-search__input:focus {
    border-color: var(--color-primary, #0064FF);
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 0 0 3px rgba(0, 100, 255, 0.15);
}

[data-theme="light"] .header-search__input {
    background: var(--color-bg, #f5f5f5);
    border-color: var(--color-border, #e5e7eb);
    color: var(--color-text, #1a1a2e);
}

[data-theme="light"] .header-search__input::placeholder {
    color: var(--color-text-muted, #999);
}

[data-theme="light"] .header-search__input:focus {
    background: #fff;
    border-color: var(--color-primary, #0064FF);
}

/* ---- FiboSearch Integration ---- */
.header-search .dgwt-wcas-search-wrapp {
    width: 100%;
    max-width: 100%;
}

.header-search .dgwt-wcas-search-wrapp .dgwt-wcas-sf-wrapp {
    border-radius: var(--radius-full, 999px) !important;
    overflow: hidden;
}

.header-search .dgwt-wcas-search-wrapp input[type="search"].dgwt-wcas-search-input {
    width: 100%;
    padding: 10px 16px 10px 42px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-full, 999px);
    font-size: 14px;
    color: #fff;
    outline: none;
    height: auto;
    box-shadow: none;
    transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}

.header-search .dgwt-wcas-search-wrapp input[type="search"].dgwt-wcas-search-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.header-search .dgwt-wcas-search-wrapp input[type="search"].dgwt-wcas-search-input:focus {
    border-color: var(--color-primary, #0064FF);
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 0 0 3px rgba(0, 100, 255, 0.15);
}

[data-theme="light"] .header-search .dgwt-wcas-search-wrapp input[type="search"].dgwt-wcas-search-input {
    background: var(--color-bg, #f5f5f5);
    border-color: var(--color-border, #e5e7eb);
    color: var(--color-text, #1a1a2e);
}

[data-theme="light"] .header-search .dgwt-wcas-search-wrapp input[type="search"].dgwt-wcas-search-input::placeholder {
    color: var(--color-text-muted, #999);
}

[data-theme="light"] .header-search .dgwt-wcas-search-wrapp input[type="search"].dgwt-wcas-search-input:focus {
    background: #fff;
    border-color: var(--color-primary, #0064FF);
}

/* FiboSearch submit button */
.header-search .dgwt-wcas-search-wrapp .dgwt-wcas-search-submit,
.header-search .dgwt-wcas-search-wrapp .dgwt-wcas-ico-magnifier-handler {
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.4);
    border-radius: 0 var(--radius-full, 999px) var(--radius-full, 999px) 0;
}

[data-theme="light"] .header-search .dgwt-wcas-search-wrapp .dgwt-wcas-search-submit,
[data-theme="light"] .header-search .dgwt-wcas-search-wrapp .dgwt-wcas-ico-magnifier-handler {
    color: var(--color-text-muted, #999);
}

/* FiboSearch autocomplete dropdown */
.dgwt-wcas-suggestions-wrapp {
    background: var(--color-surface, #1e1e2e) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: var(--radius-2xl, 16px) !important;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4) !important;
    overflow: hidden;
    margin-top: 8px !important;
}

[data-theme="light"] .dgwt-wcas-suggestions-wrapp {
    background: #fff !important;
    border-color: var(--color-border, #e5e7eb) !important;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12) !important;
}

.dgwt-wcas-suggestion {
    padding: 10px 16px !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
    color: rgba(255, 255, 255, 0.8) !important;
    transition: background 0.15s !important;
}

.dgwt-wcas-suggestion:hover,
.dgwt-wcas-suggestion.dgwt-wcas-suggestion-selected {
    background: rgba(255, 255, 255, 0.06) !important;
    color: #fff !important;
}

[data-theme="light"] .dgwt-wcas-suggestion {
    color: var(--color-text, #1a1a2e) !important;
    border-bottom-color: var(--color-border, #e5e7eb) !important;
}

[data-theme="light"] .dgwt-wcas-suggestion:hover,
[data-theme="light"] .dgwt-wcas-suggestion.dgwt-wcas-suggestion-selected {
    background: var(--color-bg, #f5f5f5) !important;
    color: var(--color-primary, #0064FF) !important;
}

.dgwt-wcas-st {
    font-size: 13px !important;
    font-weight: 500 !important;
}

.dgwt-wcas-sp {
    font-size: 12px !important;
    color: var(--color-primary, #0064FF) !important;
    font-weight: 600 !important;
}

.dgwt-wcas-suggestion .dgwt-wcas-si {
    border-radius: var(--radius-md, 8px) !important;
    overflow: hidden;
}

/* Mobile search FiboSearch */
.mobile-nav__search .dgwt-wcas-search-wrapp {
    width: 100%;
}

.mobile-nav__search .dgwt-wcas-search-wrapp input[type="search"].dgwt-wcas-search-input {
    border-radius: var(--radius-full, 999px);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    font-size: 14px;
    padding: 10px 16px 10px 42px;
}

[data-theme="light"] .mobile-nav__search .dgwt-wcas-search-wrapp input[type="search"].dgwt-wcas-search-input {
    background: var(--color-bg, #f5f5f5);
    border-color: var(--color-border, #e5e7eb);
    color: var(--color-text, #1a1a2e);
}

/* ---- Header Actions (right) ---- */
.header-actions {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

.header-actions__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 40px;
    padding: 0 10px;
    border-radius: var(--radius-lg, 10px);
    color: rgba(255, 255, 255, 0.7);
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s;
    position: relative;
    background: transparent;
    border: none;
    cursor: pointer;
    text-decoration: none;
    white-space: nowrap;
}

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

[data-theme="light"] .header-actions__btn {
    color: var(--color-text-secondary, #666);
}

[data-theme="light"] .header-actions__btn:hover {
    background: var(--color-surface-hover, rgba(0,0,0,0.04));
    color: var(--color-text, #1a1a2e);
}

.header-actions__btn svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.header-actions__label {
    display: inline;
}

/* Cart count badge */
.header-actions__cart-count {
    position: absolute;
    top: 2px;
    right: 2px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--color-accent, #CC1CF7), var(--color-primary, #0064FF));
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.header-actions__cart-count.is-empty {
    display: none;
}

/* ---- Header Cart Drawer ---- */
.header-cart-overlay {
    position: fixed;
    inset: 0;
    background: rgba(9, 11, 18, 0.55);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    z-index: 260;
}

.header-cart-overlay.is-open {
    opacity: 1;
    visibility: visible;
}

.header-cart-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(420px, 94vw);
    z-index: 270;
    pointer-events: none;
}

.header-cart-drawer__panel {
    position: relative;
    width: 100%;
    height: 100%;
    background: var(--color-surface, #fff);
    border-left: 1px solid var(--color-border, #e5e7eb);
    box-shadow: -18px 0 40px rgba(0, 0, 0, 0.18);
    transform: translateX(100%);
    transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
    display: flex;
    flex-direction: column;
    pointer-events: auto;
}

.header-cart-drawer.is-open {
    pointer-events: auto;
}

.header-cart-drawer.is-open .header-cart-drawer__panel {
    transform: translateX(0);
}

.header-cart-drawer__close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    border-radius: var(--radius-md, 8px);
    border: none;
    background: transparent;
    color: var(--color-text-muted, #6b7280);
    cursor: pointer;
    z-index: 2;
}

.header-cart-drawer__close:hover {
    background: var(--color-bg, #f3f4f6);
    color: var(--color-text, #111827);
}

.header-cart-drawer__content {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.header-cart-drawer__header {
    padding: 16px 16px;
    border-bottom: 1px solid var(--color-border, #e5e7eb);
}

.header-cart-drawer__title {
    margin: 0;
    font-size: 24px;
    font-weight: 800;
    color: var(--color-text, #111827);
}

.header-cart-drawer__body {
    flex: 1;
    overflow-y: auto;
    padding: 10px 12px;
}

.header-cart-item {
    display: grid;
    grid-template-columns: 70px 1fr auto;
    gap: 10px;
    padding: 10px;
    border-radius: var(--radius-lg, 12px);
    border: 1px solid var(--color-border, #e5e7eb);
    background: var(--color-bg, #f8fafc);
    margin-bottom: 10px;
}

.header-cart-item__thumb {
    width: 70px;
    height: 70px;
    border-radius: var(--radius-md, 8px);
    overflow: hidden;
    background: #fff;
}

.header-cart-item__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.header-cart-item__name {
    margin: 0 0 6px;
    font-size: 14px;
    line-height: 1.35;
    font-weight: 600;
}

.header-cart-item__name a {
    color: var(--color-text, #111827);
    text-decoration: none;
}

.header-cart-item__meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    font-size: 13px;
    color: var(--color-text-muted, #6b7280);
}

.header-cart-item__price {
    font-weight: 700;
    color: var(--color-text, #111827);
}

.header-cart-item__remove {
    width: 24px;
    height: 24px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text-muted, #6b7280);
    text-decoration: none;
}

.header-cart-item__remove:hover {
    background: #fee2e2;
    color: #dc2626;
}

.header-cart-drawer__footer {
    border-top: 1px solid var(--color-border, #e5e7eb);
    padding: 12px;
    background: var(--color-surface, #fff);
}

.header-cart-summary {
    margin-bottom: 10px;
}

.header-cart-summary__row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    color: var(--color-text-muted, #6b7280);
    margin-bottom: 6px;
}

.header-cart-summary__row strong {
    color: var(--color-text, #111827);
}

.header-cart-summary__row .is-success {
    color: #16a34a;
}

.header-cart-summary__row.is-total {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--color-border, #e5e7eb);
    font-size: 18px;
    font-weight: 700;
    color: var(--color-text, #111827);
}

.header-cart-drawer__actions {
    display: grid;
    gap: 8px;
}

.header-cart-drawer__actions .btn {
    justify-content: center;
}

.header-cart-drawer__empty-btn {
    text-align: center;
    font-size: 13px;
    color: var(--color-text-muted, #6b7280);
    text-decoration: none;
    padding-top: 4px;
}

.header-cart-drawer__empty-btn:hover {
    color: #dc2626;
}

.header-cart-drawer__empty {
    margin: auto;
    width: calc(100% - 32px);
    border: 1px solid var(--color-border, #e5e7eb);
    border-radius: var(--radius-xl, 14px);
    padding: 18px;
    text-align: center;
}

.header-cart-drawer__empty p {
    margin: 0 0 12px;
    color: var(--color-text-muted, #6b7280);
}

@media (max-width: 768px) {
    .header-cart-drawer {
        width: min(380px, 96vw);
    }

    .header-cart-drawer__title {
        font-size: 20px;
    }
}

/* ---- Theme Toggle ---- */
.theme-toggle {
    width: 40px;
    padding: 0;
}

.theme-toggle .icon-sun,
.theme-toggle .icon-moon {
    display: flex;
    align-items: center;
    justify-content: center;
}

[data-theme="dark"] .theme-toggle .icon-sun { display: flex; }
[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
[data-theme="light"] .theme-toggle .icon-sun { display: none; }
[data-theme="light"] .theme-toggle .icon-moon { display: flex; }

/* ==========================================================================
   ROW 2: Navigation Pills + Mega Dropdown
   ========================================================================== */
.header-nav {
    position: relative;
}

.header-nav__inner {
    display: flex;
    align-items: center;
    justify-content: center;
}

.main-navigation {
    width: 100%;
    display: flex;
    justify-content: center;
}

/* Nav pills list */
.nav-pills {
    display: flex;
    align-items: center;
    gap: 4px;
    list-style: none;
    padding: 8px 0;
    margin: 0;
}

.nav-pills__item {
    position: relative;
}

/* Individual pill */
.nav-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: var(--radius-full, 999px);
    font-size: 13px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: all 0.2s;
    white-space: nowrap;
    border: 1px solid transparent;
    background: transparent;
    cursor: pointer;
    line-height: 1.2;
    font-family: inherit;
}

.nav-pill svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    opacity: 0.7;
}

.nav-pill:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.1);
}

.nav-pill:hover svg {
    opacity: 1;
}

/* Active pill */
.nav-pills__item.is-active .nav-pill,
.nav-pill.is-active {
    color: #fff;
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.15);
}

/* Light mode pills */
[data-theme="light"] .nav-pill {
    color: var(--color-text-secondary, #555);
}

[data-theme="light"] .nav-pill:hover {
    color: var(--color-text, #1a1a2e);
    background: rgba(0, 0, 0, 0.05);
    border-color: var(--color-border, #e5e7eb);
}

[data-theme="light"] .nav-pills__item.is-active .nav-pill,
[data-theme="light"] .nav-pill.is-active {
    color: var(--color-primary, #0064FF);
    background: rgba(0, 100, 255, 0.08);
    border-color: rgba(0, 100, 255, 0.2);
}

/* Dropdown toggle pill */
.nav-pill--dropdown {
    font-family: inherit;
}

.nav-pill--dropdown svg:last-child {
    width: 14px;
    height: 14px;
    margin-left: -2px;
    transition: transform 0.2s;
}

.nav-pill--dropdown[aria-expanded="true"] svg:last-child {
    transform: rotate(180deg);
}

.nav-pill--dropdown[aria-expanded="true"] {
    color: #fff;
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.15);
}

[data-theme="light"] .nav-pill--dropdown[aria-expanded="true"] {
    color: var(--color-primary, #0064FF);
    background: rgba(0, 100, 255, 0.08);
    border-color: rgba(0, 100, 255, 0.2);
}

/* CTA pill — gradient */
.nav-pill--cta {
    background: linear-gradient(135deg, var(--color-secondary, #A130FF), var(--color-accent, #CC1CF7));
    color: #fff;
    font-weight: 600;
    border-color: transparent;
    box-shadow: 0 2px 12px rgba(161, 48, 255, 0.3);
}

.nav-pill--cta:hover {
    box-shadow: 0 4px 20px rgba(161, 48, 255, 0.5);
    transform: translateY(-1px);
    color: #fff;
    background: linear-gradient(135deg, var(--color-secondary, #A130FF), var(--color-accent, #CC1CF7));
    border-color: transparent;
}

.nav-pill--cta svg {
    opacity: 1;
}

[data-theme="light"] .nav-pill--cta {
    background: linear-gradient(135deg, var(--color-secondary, #A130FF), var(--color-accent, #CC1CF7));
    color: #fff;
    border-color: transparent;
}

[data-theme="light"] .nav-pill--cta:hover {
    color: #fff;
    background: linear-gradient(135deg, var(--color-secondary, #A130FF), var(--color-accent, #CC1CF7));
    border-color: transparent;
}

/* ==========================================================================
   MEGA DROPDOWN
   ========================================================================== */
.mega-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    width: 420px;
    background: var(--color-surface, #1e1e2e);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-2xl, 16px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4), 0 0 40px rgba(0, 100, 255, 0.05);
    padding: 0;
    z-index: var(--z-dropdown, 200);
    opacity: 0;
    visibility: hidden;
    transform: translateX(-50%) translateY(8px);
    transition: opacity 0.2s, visibility 0.2s, transform 0.2s;
    overflow: hidden;
}

.mega-dropdown.is-open {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

[data-theme="light"] .mega-dropdown {
    background: #fff;
    border-color: var(--color-border, #e5e7eb);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(0,0,0,0.04);
}

/* Header */
.mega-dropdown__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

[data-theme="light"] .mega-dropdown__header {
    border-bottom-color: var(--color-border, #e5e7eb);
}

.mega-dropdown__title {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(255, 255, 255, 0.4);
}

[data-theme="light"] .mega-dropdown__title {
    color: var(--color-text-muted, #999);
}

.mega-dropdown__viewall {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    font-weight: 600;
    color: var(--color-primary, #0064FF);
    text-decoration: none;
    transition: gap 0.2s;
}

.mega-dropdown__viewall:hover {
    gap: 8px;
    color: var(--color-primary, #0064FF);
}

.mega-dropdown__viewall svg {
    width: 14px;
    height: 14px;
}

/* Grid */
.mega-dropdown__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2px;
    padding: 8px;
}

.mega-dropdown__item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border-radius: var(--radius-lg, 10px);
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.15s;
}

.mega-dropdown__item:hover {
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
}

[data-theme="light"] .mega-dropdown__item {
    color: var(--color-text, #1a1a2e);
}

[data-theme="light"] .mega-dropdown__item:hover {
    background: var(--color-bg, #f5f5f5);
    color: var(--color-primary, #0064FF);
}

.mega-dropdown__item svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    color: rgba(255, 255, 255, 0.35);
    transition: color 0.15s;
}

.mega-dropdown__item:hover svg {
    color: var(--color-primary, #0064FF);
}

[data-theme="light"] .mega-dropdown__item svg {
    color: var(--color-text-muted, #999);
}

/* Footer */
.mega-dropdown__footer {
    padding: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

[data-theme="light"] .mega-dropdown__footer {
    border-top-color: var(--color-border, #e5e7eb);
}

.mega-dropdown__explore {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px;
    border-radius: var(--radius-lg, 10px);
    background: rgba(255, 255, 255, 0.04);
    color: rgba(255, 255, 255, 0.6);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
}

.mega-dropdown__explore:hover {
    background: rgba(0, 100, 255, 0.1);
    color: var(--color-primary, #0064FF);
}

[data-theme="light"] .mega-dropdown__explore {
    background: var(--color-bg, #f5f5f5);
    color: var(--color-text-secondary, #555);
}

[data-theme="light"] .mega-dropdown__explore:hover {
    background: rgba(0, 100, 255, 0.08);
    color: var(--color-primary, #0064FF);
}

.mega-dropdown__explore svg {
    width: 16px;
    height: 16px;
}

/* ==========================================================================
   MOBILE
   ========================================================================== */

/* ---- Mobile Menu Toggle ---- */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-lg, 10px);
    color: rgba(255, 255, 255, 0.7);
    background: transparent;
    border: none;
    cursor: pointer;
    gap: 5px;
    transition: background 0.2s;
}

[data-theme="light"] .mobile-menu-toggle {
    color: var(--color-text, #1a1a2e);
}

.mobile-menu-toggle:hover {
    background: rgba(255, 255, 255, 0.08);
}

[data-theme="light"] .mobile-menu-toggle:hover {
    background: rgba(0, 0, 0, 0.04);
}

.mobile-menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    background: currentColor;
    border-radius: 1px;
    transition: all 0.3s;
}

.mobile-menu-toggle.is-active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}
.mobile-menu-toggle.is-active span:nth-child(2) {
    opacity: 0;
}
.mobile-menu-toggle.is-active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ---- Mobile Nav Panel ---- */
.mobile-nav {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(400px, 90vw);
    background: var(--color-surface, #1a1a2e);
    z-index: var(--z-modal, 300);
    box-shadow: -10px 0 40px rgba(0, 0, 0, 0.4);
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
    flex-direction: column;
}

[data-theme="light"] .mobile-nav {
    background: #fff;
}

.mobile-nav.is-open {
    display: flex;
    transform: translateX(0);
    animation: slide-in-right 0.3s ease forwards;
}

@keyframes slide-in-right {
    from { transform: translateX(100%); }
    to   { transform: translateX(0); }
}

.mobile-nav__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

[data-theme="light"] .mobile-nav__header {
    border-bottom-color: var(--color-border, #e5e7eb);
}

.mobile-nav__header img {
    height: 30px;
    width: auto;
}

.mobile-nav__close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: var(--radius-lg, 10px);
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    transition: all 0.2s;
}

[data-theme="light"] .mobile-nav__close {
    color: var(--color-text-muted, #999);
}

.mobile-nav__close:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.mobile-nav__close svg {
    width: 20px;
    height: 20px;
}

/* Search in mobile */
.mobile-nav__search {
    padding: 12px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

[data-theme="light"] .mobile-nav__search {
    border-bottom-color: var(--color-border, #e5e7eb);
}

/* Links */
.mobile-nav__menu {
    padding: 12px 16px;
    flex: 1;
}

.mobile-nav__link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 12px;
    font-size: 15px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    border-radius: var(--radius-lg, 10px);
    transition: all 0.15s;
}

.mobile-nav__link:hover {
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
}

[data-theme="light"] .mobile-nav__link {
    color: var(--color-text, #1a1a2e);
}

[data-theme="light"] .mobile-nav__link:hover {
    background: var(--color-bg, #f5f5f5);
    color: var(--color-primary, #0064FF);
}

.mobile-nav__link svg {
    width: 20px;
    height: 20px;
    opacity: 0.5;
    flex-shrink: 0;
}

.mobile-nav__footer {
    padding: 16px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

[data-theme="light"] .mobile-nav__footer {
    border-top-color: var(--color-border, #e5e7eb);
}

/* Overlay */
.mobile-nav-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: calc(var(--z-modal, 300) - 1);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.mobile-nav-overlay.is-open {
    display: block;
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 1024px) {
    .mobile-menu-toggle {
        display: flex;
    }

    .header-nav {
        display: none;
    }

    .header-actions__label {
        display: none;
    }

    .header-search {
        max-width: 400px;
    }
}

@media (max-width: 768px) {
    .header-top__inner {
        height: 56px;
        gap: var(--space-3, 0.75rem);
    }

    .header-search {
        max-width: none;
        flex: 1;
    }

    .site-branding img {
        height: 30px;
    }

    .header-actions__account {
        display: none;
    }
}

@media (max-width: 480px) {
    .header-search {
        display: none;
    }

    .header-top__inner {
        justify-content: space-between;
    }
}
