/* ==========================================================================
   dashboard-header.css - Two-Tier Header & Theme Customizer for AniZoro Dashboards
   ========================================================================== */

:root {
    --hdr-bg: #060d19;
    --hdr-card: #0d1527;
    --hdr-input-bg: #0c1424;
    --hdr-border: rgba(255, 255, 255, 0.07);
    --hdr-border-hover: rgba(0, 255, 157, 0.3);
    --hdr-neon: #00ff9d;
    --hdr-neon-hover: #00e58d;
    --hdr-neon-glow: rgba(0, 255, 157, 0.25);
    --hdr-cyan: #00e5ff;
    --hdr-text: #ffffff;
    --hdr-muted: #94a3b8;
    --hdr-dim: #64748b;
    --hdr-danger: #ef4444;
}

/* =========================================================
   DASHBOARD TOP NAVBAR (TWO-TIER LAYOUT)
========================================================= */
.dashboard-top-navbar {
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    height: 82px !important;
    min-height: 82px !important;
    max-height: 82px !important;
    padding: 7px 28px 9px !important;
    background: var(--hdr-bg) !important;
    border-bottom: 1px solid var(--hdr-border) !important;
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 1000 !important;
    font-family: 'Outfit', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif !important;
    box-sizing: border-box !important;
    width: 100% !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    transition: background 0.3s ease, border-color 0.3s ease;
}

.main-content {
    margin-top: 62px !important;
}

/* =========================================================
   TOP TIER (BRAND LOGO, NAV ITEMS, RIGHT ACTIONS)
========================================================= */
.dash-header-top-tier {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    height: 40px;
}

/* Brand Logo */
.dash-nav-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.dash-mobile-toggle-btn {
    display: none;
    background: transparent;
    border: none;
    color: var(--hdr-muted);
    font-size: 18px;
    cursor: pointer;
    padding: 4px;
}

.dash-brand-logo-container {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    line-height: 1;
    user-select: none;
}

.dash-brand-logo {
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -0.5px;
    line-height: 1;
}

.dash-brand-ani {
    color: var(--hdr-neon);
    transition: color 0.3s ease;
}

.dash-brand-zoro {
    color: #ffffff;
}

.dash-brand-tagline {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: var(--hdr-dim);
    text-transform: uppercase;
    margin-top: 3px;
    font-family: inherit;
}

/* Primary Navigation Links */
.dash-primary-nav {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 20px;
}

.dash-nav-link {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 13px;
    font-size: 15px;
    font-weight: 500;
    color: var(--hdr-muted);
    text-decoration: none;
    border-radius: 8px;
    position: relative;
    transition: all 0.2s ease;
    background: transparent;
    border: 1px solid transparent;
    cursor: pointer;
    font-family: inherit;
    white-space: nowrap;
}

.dash-nav-link .dash-nav-icon {
    font-size: 15px;
    color: var(--hdr-dim);
    transition: color 0.2s ease;
}

.dash-nav-link:hover {
    color: #ffffff;
}

.dash-nav-link:hover .dash-nav-icon {
    color: #ffffff;
}

/* Active State (Home in screenshot) */
.dash-nav-link.active {
    background: rgba(0, 255, 157, 0.08);
    color: var(--hdr-neon);
    font-weight: 600;
    border: 1px solid rgba(0, 255, 157, 0.2);
}

.dash-nav-link.active .dash-nav-icon {
    color: var(--hdr-neon);
}

.dash-nav-indicator {
    display: none;
}

.dash-nav-link.active .dash-nav-indicator {
    display: block;
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%);
    width: 24px;
    height: 2px;
    background: var(--hdr-neon);
    border-radius: 2px;
    box-shadow: 0 0 8px var(--hdr-neon);
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

/* =========================================================
   GENRES MEGA-DROPDOWN IN NAV
========================================================= */
.dash-nav-dropdown-wrapper {
    position: relative;
    display: inline-block;
}

.dash-nav-link.dropdown-toggle .dash-nav-chevron {
    font-size: 11px;
    margin-left: 3px;
    transition: transform 0.25s ease;
}

.dash-nav-dropdown-wrapper:hover .dash-nav-chevron,
.dash-nav-dropdown-wrapper.active .dash-nav-chevron {
    transform: rotate(180deg);
}

.dash-nav-dropdown-wrapper:hover .dash-genres-mega-menu {
    display: flex;
}

.dash-genres-mega-menu {
    display: none;
    flex-direction: column;
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    width: 740px;
    max-width: calc(100vw - 32px);
    background: rgba(11, 18, 33, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--hdr-border-hover);
    border-radius: 16px;
    box-shadow: 0 24px 50px rgba(0, 0, 0, 0.85), 0 0 30px var(--hdr-neon-glow);
    padding: 0;
    z-index: 1050;
    overflow: hidden;
    animation: dashMegaMenuFadeIn 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.dash-genres-mega-menu.show {
    display: flex;
}

/* Triangle pointer notch aligned under Genres button */
.dash-genres-mega-menu::before {
    content: '';
    position: absolute;
    top: -6px;
    right: 36px;
    width: 12px;
    height: 12px;
    background: #0b1221;
    border-left: 1px solid var(--hdr-border-hover);
    border-top: 1px solid var(--hdr-border-hover);
    transform: rotate(45deg);
    z-index: 2;
}

@keyframes dashMegaMenuFadeIn {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 1. Mega Menu Header Bar */
.dash-genres-dropdown-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 20px;
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid var(--hdr-border);
}

.dash-genres-header-title {
    display: flex;
    align-items: center;
    gap: 10px;
}

.dash-genres-icon-badge {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: rgba(0, 255, 157, 0.1);
    border: 1px solid rgba(0, 255, 157, 0.25);
    color: var(--hdr-neon);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}

.dash-genres-title-text {
    font-size: 15.5px;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: -0.2px;
}

.dash-genres-count-pill {
    font-size: 12px;
    font-weight: 600;
    color: var(--hdr-dim);
    background: rgba(255, 255, 255, 0.05);
    padding: 2px 8px;
    border-radius: 12px;
    margin-left: 6px;
}

/* Quick Filter Search Box inside Menu */
.dash-genres-search-box {
    position: relative;
    display: flex;
    align-items: center;
    width: 230px;
}

.dash-genres-search-icon {
    position: absolute;
    left: 10px;
    font-size: 12px;
    color: var(--hdr-dim);
    pointer-events: none;
}

.dash-genres-search-box input {
    width: 100%;
    height: 32px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--hdr-border);
    border-radius: 16px;
    padding: 0 28px 0 28px;
    font-size: 13px;
    color: #ffffff;
    font-family: inherit;
    outline: none;
    transition: all 0.2s ease;
}

.dash-genres-search-box input::placeholder {
    color: var(--hdr-dim);
}

.dash-genres-search-box input:focus {
    border-color: var(--hdr-neon);
    background: rgba(0, 255, 157, 0.04);
    box-shadow: 0 0 10px var(--hdr-neon-glow);
}

.dash-genres-search-clear {
    position: absolute;
    right: 8px;
    background: transparent;
    border: none;
    color: var(--hdr-muted);
    font-size: 12px;
    cursor: pointer;
    padding: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.dash-genres-search-clear:hover {
    color: var(--hdr-neon);
}

/* 2. Popular Genres Strip */
.dash-genres-popular-strip {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    background: rgba(0, 255, 157, 0.02);
    border-bottom: 1px solid var(--hdr-border);
    flex-wrap: wrap;
}

.dash-popular-label {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    font-weight: 700;
    color: var(--hdr-neon);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.dash-popular-pills {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    flex: 1;
}

.dash-popular-pill {
    display: inline-flex;
    align-items: center;
    font-size: 12.5px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--hdr-muted);
    text-decoration: none;
    transition: all 0.18s ease;
}

.dash-popular-pill:hover {
    background: rgba(0, 255, 157, 0.15);
    border-color: var(--hdr-neon);
    color: var(--hdr-neon);
    transform: translateY(-1px);
    box-shadow: 0 0 10px var(--hdr-neon-glow);
}

/* 3. Main Columns Grid Area */
.dash-genres-columns-wrap {
    padding: 14px 20px 10px;
    max-height: 380px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 255, 157, 0.3) rgba(255, 255, 255, 0.02);
}

.dash-genres-columns-wrap::-webkit-scrollbar {
    width: 6px;
}

.dash-genres-columns-wrap::-webkit-scrollbar-thumb {
    background: rgba(0, 255, 157, 0.35);
    border-radius: 3px;
}

.dash-genres-columns-wrap::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02);
}

.dash-genres-columns {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2px 14px;
}

.dash-genres-col {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.dash-genre-item {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 6px 10px;
    color: var(--hdr-muted);
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.16s ease;
    white-space: nowrap;
}

.dash-genre-dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transition: all 0.16s ease;
    flex-shrink: 0;
}

.dash-genre-name {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dash-genre-item:hover {
    background: rgba(0, 255, 157, 0.09);
    color: var(--hdr-neon);
    transform: translateX(3px);
}

.dash-genre-item:hover .dash-genre-dot {
    background: var(--hdr-neon);
    box-shadow: 0 0 6px var(--hdr-neon);
    transform: scale(1.3);
}

/* No results message */
.dash-genres-no-results {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 36px 20px;
    gap: 10px;
    color: var(--hdr-dim);
    font-size: 13px;
}

.dash-genres-no-results i {
    font-size: 24px;
    color: var(--hdr-dim);
}

/* 4. Footer Strip */
.dash-genres-dropdown-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 20px;
    background: rgba(0, 0, 0, 0.25);
    border-top: 1px solid var(--hdr-border);
}

.dash-genres-footer-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13.5px;
    font-weight: 600;
    color: var(--hdr-muted);
    text-decoration: none;
    transition: all 0.15s ease;
}

.dash-genres-footer-btn:hover {
    color: #ffffff;
}

.dash-genres-footer-btn.highlight {
    color: var(--hdr-neon);
}

.dash-genres-footer-btn.highlight:hover {
    color: var(--hdr-neon-hover);
    gap: 9px;
}

@media (max-width: 820px) {
    .dash-genres-mega-menu {
        width: calc(100vw - 32px);
        right: -40px;
    }

    .dash-genres-columns {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* =========================================================
   RIGHT CONTROLS: UPLOAD, BELL, BOOKMARK, USER, THEME
========================================================= */
.dash-nav-right {
    display: flex;
    align-items: center;
    gap: 16px;
    justify-content: flex-end;
}

/* Upload Pill Button */
.dash-upload-pill-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 15px;
    border-radius: 20px;
    border: 1px solid rgba(0, 255, 157, 0.45);
    background: rgba(0, 255, 157, 0.03);
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
}

.dash-upload-pill-btn i {
    color: var(--hdr-neon);
    font-size: 14px;
    transition: transform 0.2s ease, color 0.3s ease;
}

.dash-upload-pill-btn:hover {
    background: rgba(0, 255, 157, 0.12);
    border-color: var(--hdr-neon);
    box-shadow: 0 0 12px var(--hdr-neon-glow);
    color: #ffffff;
}

.dash-upload-pill-btn:hover i {
    transform: rotate(90deg);
}

/* Icon Buttons (Bell, Bookmark, History) */
.dash-icon-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dash-icon-btn {
    color: #cbd5e1;
    font-size: 18px !important;
    line-height: 1;
    text-decoration: none;
    background: transparent;
    border: none;
    padding: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    position: relative;
}

.dash-icon-btn i,
.dash-icon-btn .fa-bell,
.dash-icon-btn .fa-bookmark,
.dash-icon-btn .fa-clock-rotate-left {
    font-size: 18px !important;
    line-height: 1 !important;
    display: inline-block;
    color: inherit;
}

.dash-icon-btn:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.06);
}

/* Notification Badge */
.dash-notif-badge {
    position: absolute;
    top: -5px;
    right: -7px;
    background: #ef4444;
    color: #ffffff;
    font-size: 10px;
    font-weight: 800;
    min-width: 17px;
    height: 17px;
    padding: 0 4px;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--hdr-bg);
    box-shadow: 0 0 8px rgba(239, 68, 68, 0.5);
    line-height: 1;
    pointer-events: none;
    z-index: 5;
    box-sizing: border-box;
}

/* User Profile Pill */
.dash-profile-pill-wrapper {
    position: relative;
}

.dash-profile-pill-btn {
    display: flex;
    align-items: center;
    gap: 9px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.09);
    cursor: pointer;
    padding: 4px 14px 4px 5px;
    border-radius: 9999px;
    transition: all 0.2s ease;
}

.dash-profile-pill-btn:hover {
    background: rgba(255, 255, 255, 0.09);
    border-color: rgba(0, 255, 157, 0.3);
}

.dash-profile-img {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    object-fit: cover;
    border: 1.5px solid rgba(0, 255, 157, 0.45);
    transition: border-color 0.3s ease;
}

.dash-profile-name {
    color: #ffffff;
    font-size: 15px;
    font-weight: 600;
    font-family: inherit;
    line-height: 1;
}

.dash-profile-arrow {
    color: var(--hdr-muted);
    font-size: 11px;
    margin-left: 3px;
    transition: transform 0.2s ease;
}

.dash-profile-pill-wrapper:hover .dash-profile-arrow {
    transform: rotate(180deg);
}

/* Guest Auth Buttons in Top Tier */
.dash-auth-buttons {
    display: flex;
    align-items: center;
    gap: 8px;
}

.dash-auth-btn {
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    padding: 7px 16px;
    border-radius: 8px;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-family: inherit;
}

.dash-login-btn {
    color: #070d19 !important;
    background: var(--hdr-neon) !important;
    border: 1px solid var(--hdr-neon) !important;
}

.dash-login-btn:hover {
    background: var(--hdr-neon-hover) !important;
    border-color: var(--hdr-neon-hover) !important;
    box-shadow: 0 0 10px var(--hdr-neon-glow);
}

.dash-register-btn {
    color: #ffffff !important;
    background: transparent !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
}

.dash-register-btn:hover {
    border-color: var(--hdr-neon) !important;
    color: var(--hdr-neon) !important;
}

/* Dropdown Panels */
.dash-dropdown-panel {
    display: none;
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    background: var(--hdr-card);
    border: 1px solid var(--hdr-border-hover);
    border-radius: 12px;
    box-shadow: 0 14px 35px rgba(0, 0, 0, 0.85);
    z-index: 99999 !important;
    overflow: hidden;
}

.dash-dropdown-panel.show {
    display: block !important;
}

.dash-profile-dropdown {
    width: 230px;
}

.dash-dropdown-profile-header {
    padding: 12px 16px;
    border-bottom: 1px solid var(--hdr-border);
    background: rgba(255, 255, 255, 0.02);
}

.dash-dropdown-profile-header .user-display {
    font-size: 15.5px;
    font-weight: 700;
    color: #ffffff;
}

.dash-dropdown-profile-header .user-role-tag {
    font-size: 12px;
    color: var(--hdr-neon);
    font-weight: 600;
    margin-top: 3px;
}

.dash-dropdown-links {
    padding: 6px 0;
}

.dash-drop-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    color: var(--hdr-muted);
    font-size: 14.5px;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.15s, color 0.15s;
}

.dash-drop-link i {
    font-size: 15px;
    width: 20px;
    text-align: center;
    color: var(--hdr-muted);
}

.dash-drop-link:hover {
    background: rgba(0, 255, 157, 0.08);
    color: var(--hdr-neon);
}

.dash-drop-link:hover i {
    color: var(--hdr-neon);
}

.dash-drop-divider {
    height: 1px;
    background: var(--hdr-border);
    margin: 6px 0;
}

.dash-drop-link.logout-link {
    color: var(--hdr-danger) !important;
}

.dash-drop-link.logout-link:hover {
    background: rgba(239, 68, 68, 0.1) !important;
    color: #f87171 !important;
}

/* Notifications Panel */
.dash-notif-panel {
    width: 340px;
    right: -20px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.85), 0 0 20px var(--hdr-neon-glow);
}

.dash-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    border-bottom: 1px solid var(--hdr-border);
}

.dash-panel-header h3 {
    margin: 0;
    font-size: 14px;
    font-weight: 700;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dash-clear-notif-btn {
    background: transparent;
    border: none;
    color: var(--hdr-neon);
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    padding: 0;
    transition: color 0.15s ease;
}

.dash-clear-notif-btn:hover {
    color: var(--hdr-neon-hover);
    text-decoration: underline;
}

.dash-notif-list {
    max-height: 290px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 255, 157, 0.3) rgba(255, 255, 255, 0.02);
}

.dash-notif-list::-webkit-scrollbar {
    width: 5px;
}

.dash-notif-list::-webkit-scrollbar-thumb {
    background: rgba(0, 255, 157, 0.3);
    border-radius: 3px;
}

.notif-dropdown-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 11px 16px;
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    transition: background 0.15s ease;
}

.notif-dropdown-item:hover {
    background: rgba(255, 255, 255, 0.04);
}

.notif-dropdown-item.unread {
    background: rgba(0, 255, 157, 0.04);
}

.notif-dropdown-item.unread .notif-dropdown-title {
    color: #ffffff;
    font-weight: 600;
}

.notif-dropdown-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(0, 255, 157, 0.1);
    color: var(--hdr-neon);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    flex-shrink: 0;
    margin-top: 2px;
}

.notif-dropdown-body {
    flex: 1;
    min-width: 0;
}

.notif-dropdown-title {
    font-size: 14px;
    color: #e2e8f0;
    font-weight: 500;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.notif-dropdown-desc {
    font-size: 12.5px;
    color: var(--hdr-muted);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 3px;
}

.notif-dropdown-time {
    font-size: 11.5px;
    color: var(--hdr-dim);
}

.notif-dropdown-empty {
    padding: 28px 16px;
    text-align: center;
    color: var(--hdr-dim);
    font-size: 13.5px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.notif-dropdown-empty i {
    font-size: 22px;
    color: var(--hdr-dim);
}

.dash-panel-footer {
    padding: 10px;
    text-align: center;
    border-top: 1px solid var(--hdr-border);
    background: rgba(255, 255, 255, 0.02);
}

.dash-panel-footer a {
    color: var(--hdr-muted);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.15s ease;
}

.dash-panel-footer a:hover {
    color: var(--hdr-neon);
}

/* =========================================================
   THEME CUSTOMIZER BUTTON
========================================================= */
.dash-theme-customizer-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    cursor: pointer;
    color: var(--hdr-neon);
    font-size: 15px;
    transition: all 0.2s ease;
}

.dash-theme-customizer-btn:hover {
    background: rgba(0, 255, 157, 0.12);
    border-color: var(--hdr-neon);
    box-shadow: 0 0 12px var(--hdr-neon-glow);
    transform: rotate(25deg);
}

/* =========================================================
   BOTTOM TIER: CENTERED SEARCH BAR
========================================================= */
.dash-header-bottom-tier {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    margin-top: 4px;
    position: relative;
}

.dash-search-container {
    position: relative;
    width: 100%;
    max-width: 460px;
}

.dash-search-form {
    display: flex;
    align-items: center;
    width: 100%;
    height: 36px;
    background: var(--hdr-input-bg);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 9px;
    transition: all 0.2s ease;
    padding: 2px 2px 2px 14px;
    box-sizing: border-box;
}

.dash-search-form:focus-within {
    border-color: var(--hdr-neon);
    box-shadow: 0 0 12px var(--hdr-neon-glow);
}

.dash-search-icon {
    color: var(--hdr-dim);
    font-size: 14px;
    margin-right: 9px;
    flex-shrink: 0;
}

#dashSearchInput {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: #ffffff;
    font-family: inherit;
    font-size: 14px;
    font-weight: 400;
    min-width: 0;
    padding: 0;
}

#dashSearchInput::placeholder {
    color: #526175;
}

.dash-search-kbd {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 5px;
    padding: 2px 7px;
    font-size: 11.5px;
    font-weight: 600;
    color: #64748b;
    font-family: inherit;
    margin-right: 6px;
    white-space: nowrap;
    flex-shrink: 0;
    user-select: none;
}

.dash-search-submit-btn {
    width: 30px;
    height: 30px;
    background: var(--hdr-neon);
    border: none;
    border-radius: 7px;
    color: #070d19;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.dash-search-submit-btn:hover {
    background: var(--hdr-neon-hover);
    box-shadow: 0 0 10px var(--hdr-neon-glow);
    transform: scale(1.03);
}

.dash-search-suggestions {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    background: var(--hdr-card);
    border: 1px solid var(--hdr-border-hover);
    border-radius: 10px;
    z-index: 9999;
    max-height: 350px;
    overflow-y: auto;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.75);
    padding: 6px 0;
}

/* =========================================================
   THEME CUSTOMIZER MODAL OVERLAY & POPUP
========================================================= */
.theme-customizer-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(3, 7, 18, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 10500;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    box-sizing: border-box;
    animation: themeFadeIn 0.2s ease;
}

@keyframes themeFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.theme-customizer-modal-box {
    width: 100%;
    max-width: 480px;
    background: #0d1527;
    border: 1px solid rgba(0, 255, 157, 0.25);
    border-radius: 16px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.9), 0 0 30px rgba(0, 255, 157, 0.1);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: themeScaleIn 0.2s ease;
    font-family: 'Outfit', 'Inter', sans-serif;
}

@keyframes themeScaleIn {
    from {
        transform: scale(0.95);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

.theme-customizer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 22px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.02);
}

.theme-header-title-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
}

.theme-header-icon-box {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(0, 255, 157, 0.1);
    border: 1px solid rgba(0, 255, 157, 0.3);
    color: var(--hdr-neon);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}

.theme-modal-title {
    margin: 0;
    font-size: 17px;
    font-weight: 700;
    color: #ffffff;
}

.theme-modal-subtitle {
    margin: 2px 0 0;
    font-size: 12px;
    color: var(--hdr-muted);
}

.theme-modal-close-btn {
    background: none;
    border: none;
    color: #94a3b8;
    font-size: 26px;
    cursor: pointer;
    padding: 0 4px;
    line-height: 1;
    transition: color 0.15s;
}

.theme-modal-close-btn:hover {
    color: #ffffff;
}

.theme-customizer-body {
    padding: 20px 22px;
    display: flex;
    flex-direction: column;
    gap: 18px;
    max-height: 70vh;
    overflow-y: auto;
}

.theme-section {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.theme-section-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #e2e8f0;
}

.theme-section-label i {
    color: var(--hdr-neon);
    font-size: 13px;
}

/* Mode Options */
.theme-mode-options {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.theme-mode-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 12px 8px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    color: var(--hdr-muted);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
}

.theme-mode-card i {
    font-size: 18px;
}

.theme-mode-card:hover {
    background: rgba(255, 255, 255, 0.06);
    color: #ffffff;
}

.theme-mode-card.active {
    background: rgba(0, 255, 157, 0.1);
    border-color: var(--hdr-neon);
    color: var(--hdr-neon);
    box-shadow: 0 0 14px var(--hdr-neon-glow);
}

/* Color Swatches Grid */
.theme-palette-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 8px;
}

.theme-color-swatch {
    width: 100%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: var(--swatch-color);
    border: 2px solid transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #070d19;
    font-size: 11px;
    transition: transform 0.2s, box-shadow 0.2s;
    outline: none;
    padding: 0;
}

.theme-color-swatch i {
    display: none;
}

.theme-color-swatch:hover {
    transform: scale(1.15);
    box-shadow: 0 0 10px var(--swatch-color);
}

.theme-color-swatch.active {
    transform: scale(1.18);
    border-color: #ffffff;
    box-shadow: 0 0 14px var(--swatch-color);
}

.theme-color-swatch.active i {
    display: block;
}

/* Custom Hex Picker */
.theme-custom-picker-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 4px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 8px;
}

.picker-label {
    font-size: 12px;
    color: var(--hdr-muted);
}

.picker-input-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
}

.native-color-picker {
    width: 28px;
    height: 28px;
    border: none;
    border-radius: 6px;
    background: transparent;
    cursor: pointer;
    padding: 0;
}

.hex-text-input {
    width: 78px;
    background: #070d19;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 6px;
    color: #ffffff;
    font-size: 12px;
    font-family: monospace;
    font-weight: 600;
    padding: 4px 8px;
    text-transform: uppercase;
    outline: none;
}

.hex-text-input:focus {
    border-color: var(--hdr-neon);
}

/* Background Tones */
.theme-bg-tones {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.theme-tone-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    color: var(--hdr-muted);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
}

.tone-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    flex-shrink: 0;
}

.theme-tone-btn:hover {
    background: rgba(255, 255, 255, 0.06);
    color: #ffffff;
}

.theme-tone-btn.active {
    border-color: var(--hdr-neon);
    color: var(--hdr-neon);
    background: rgba(0, 255, 157, 0.06);
}

/* Glow Toggle */
.theme-toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 10px;
}

.toggle-title {
    font-size: 13px;
    font-weight: 600;
    color: #ffffff;
}

.toggle-subtitle {
    font-size: 11px;
    color: var(--hdr-dim);
    margin-top: 2px;
}

.theme-switch {
    position: relative;
    display: inline-block;
    width: 40px;
    height: 22px;
    flex-shrink: 0;
}

.theme-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.theme-switch-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #334155;
    transition: .2s;
    border-radius: 22px;
}

.theme-switch-slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .2s;
    border-radius: 50%;
}

.theme-switch input:checked+.theme-switch-slider {
    background-color: var(--hdr-neon);
}

.theme-switch input:checked+.theme-switch-slider:before {
    transform: translateX(18px);
    background-color: #070d19;
}

/* Footer Buttons */
.theme-customizer-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 22px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.02);
}

.theme-btn-reset {
    background: transparent;
    border: none;
    color: var(--hdr-muted);
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: inherit;
    transition: color 0.15s;
}

.theme-btn-reset:hover {
    color: #ffffff;
}

.theme-btn-done {
    background: var(--hdr-neon);
    border: none;
    border-radius: 8px;
    color: #070d19;
    font-size: 13px;
    font-weight: 700;
    padding: 7px 18px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: inherit;
    transition: all 0.2s ease;
}

.theme-btn-done:hover {
    background: var(--hdr-neon-hover);
    box-shadow: 0 0 12px var(--hdr-neon-glow);
    transform: translateY(-1px);
}

/* =========================================================
   THEME ADAPTATION STYLES (WHEN CUSTOMIZER IS ACTIVE)
========================================================= */
/* OLED Black Mode */
body.theme-mode-oled {
    background-color: #000000 !important;
}

body.theme-mode-oled .creator-sidebar,
body.theme-mode-oled .admin-container .sidebar,
body.theme-mode-oled .dashboard-top-navbar {
    background: #000000 !important;
    border-color: #1a1a1a !important;
}

body.theme-mode-oled .card,
body.theme-mode-oled .studio-card,
body.theme-mode-oled .kpi-metric-card,
body.theme-mode-oled .overview-card {
    background: #050505 !important;
    border-color: #1a1a1a !important;
}

/* Clean Light Mode */
body.theme-mode-light {
    background-color: #f8fafc !important;
    color: #0f172a !important;
}

body.theme-mode-light .creator-sidebar,
body.theme-mode-light .admin-container .sidebar,
body.theme-mode-light .dashboard-top-navbar {
    background: #ffffff !important;
    border-color: #e2e8f0 !important;
}

body.theme-mode-light .dash-brand-zoro,
body.theme-mode-light .dash-profile-name {
    color: #0f172a !important;
}

body.theme-mode-light .dash-nav-link,
body.theme-mode-light .dash-icon-btn {
    color: #475569 !important;
}

body.theme-mode-light .dash-search-form {
    background: #f1f5f9 !important;
    border-color: #cbd5e1 !important;
}

body.theme-mode-light #dashSearchInput {
    color: #0f172a !important;
}

body.theme-mode-light .card,
body.theme-mode-light .studio-card,
body.theme-mode-light .kpi-metric-card {
    background: #ffffff !important;
    border-color: #e2e8f0 !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05) !important;
}

/* Responsive Adjustments */
@media (max-width: 1180px) {
    .dash-primary-nav {
        gap: 2px;
        margin-left: 10px;
    }

    .dash-nav-link {
        padding: 5px 8px;
        font-size: 12px;
    }
}

@media (max-width: 1279px) {
    .dashboard-top-navbar {
        padding: 8px 16px 10px !important;
    }

    .dash-primary-nav {
        display: none;
    }

    .dash-primary-nav.mobile-open {
        display: flex;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 4px;
        margin: 0;
        padding: 10px 16px 14px;
        background: var(--hdr-bg);
        border-bottom: 1px solid var(--hdr-border);
        box-shadow: 0 14px 24px rgba(0, 0, 0, 0.45);
        max-height: calc(100vh - 82px);
        overflow-y: auto;
        z-index: 1001;
    }

    .dash-primary-nav.mobile-open .dash-nav-link {
        width: 100%;
        justify-content: flex-start;
        padding: 10px 12px;
    }

    .dash-primary-nav.mobile-open .dash-nav-dropdown-wrapper {
        width: 100%;
    }

    .dash-primary-nav.mobile-open .dash-nav-dropdown-wrapper:hover .dash-genres-mega-menu {
        display: none;
    }

    .dash-primary-nav.mobile-open .dash-nav-dropdown-wrapper .dash-genres-mega-menu {
        position: static;
        width: 100%;
        max-width: none;
        max-height: 55vh;
        margin: 4px 0 8px;
        border-radius: 10px;
        box-shadow: none;
        overflow-x: hidden;
        overflow-y: auto;
        overscroll-behavior: contain;
    }

    .dash-primary-nav.mobile-open .dash-nav-dropdown-wrapper .dash-genres-mega-menu.show {
        display: flex;
    }

    .dash-primary-nav.mobile-open .dash-genres-columns-wrap {
        max-height: none;
        overflow: visible;
    }

    .dash-primary-nav.mobile-open .dash-genres-mega-menu::before {
        display: none;
    }

    .dash-mobile-toggle-btn {
        display: block;
    }
}

@media (max-width: 768px) {
    .dashboard-top-navbar {
        height: 96px !important;
        min-height: 96px !important;
        max-height: 96px !important;
        padding: 8px 12px !important;
    }

    .main-content {
        margin-top: 76px !important;
    }

    .dash-header-top-tier {
        flex: 0 0 40px;
        height: 40px;
        gap: 8px;
    }

    .dash-nav-left {
        flex: 0 1 auto;
        min-width: 0;
        gap: 8px;
    }

    .dash-nav-right {
        flex: 0 0 auto;
        min-width: 0;
        gap: 5px;
    }

    .dash-profile-name {
        display: none;
    }

    .dash-upload-pill-btn span {
        display: none;
    }

    .dash-upload-pill-btn {
        padding: 5px 8px;
        border-radius: 50%;
    }

    .dash-search-container {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    .dash-brand-logo {
        font-size: 21px;
    }

    .dash-brand-tagline {
        font-size: 8px;
        letter-spacing: 1px;
    }

    .dash-nav-right .dash-upload-pill-btn,
    .dash-nav-right .dash-register-btn,
    .dash-theme-customizer-btn {
        display: none !important;
    }

    .dash-nav-right .dash-icon-btn {
        width: 28px;
        height: 28px;
        padding: 4px;
    }

    .dash-profile-pill-btn {
        padding: 2px;
        background: transparent;
        border-color: transparent;
    }

    .dash-profile-arrow {
        display: none;
    }

    .dash-primary-nav.mobile-open {
        max-height: calc(100vh - 96px);
    }
}

@media (max-width: 360px) {
    .dashboard-top-navbar {
        padding-right: 10px !important;
        padding-left: 10px !important;
    }

    .dash-nav-right {
        gap: 3px;
    }

    .dash-icon-btn {
        font-size: 16px !important;
    }
}

/* =========================================================
   INTEGRATION WITH ADMIN / STUDIO DASHBOARD CONTAINER
========================================================= */
.admin-container.has-top-dashboard-header {
    min-height: calc(100vh - 82px) !important;
}

.admin-container.has-top-dashboard-header .sidebar {
    top: 82px !important;
    height: calc(100vh - 82px) !important;
    z-index: 990 !important;
}

.admin-container.has-top-dashboard-header .main-content {
    min-height: calc(100vh - 82px) !important;
}

@media (max-width: 1024px) {
    .admin-container.has-top-dashboard-header .sidebar {
        top: 82px !important;
        height: calc(100vh - 82px) !important;
    }
}