/* ========================================
   ELOK Printing - Premium Navbar
   Dark Glassmorphism Design System
   Brand Color: #008fd7
   ======================================== */

/* Navbar Container - Dark Glass Effect */
.premium-navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1050;
    background: rgba(13, 19, 51, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.premium-navbar.scrolled {
    background: rgba(7, 11, 31, 0.95);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3), 0 0 40px rgba(0, 143, 215, 0.05);
}

.navbar-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px;
}

.navbar-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 72px;
    gap: 24px;
}

/* Brand Section */
.navbar-brand-wrapper {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.navbar-brand-premium {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    padding: 8px 0;
    transition: all 0.3s ease;
}

.navbar-brand-premium:hover {
    transform: translateX(2px);
}

.brand-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.brand-icon svg {
    filter: drop-shadow(0 2px 8px rgba(0, 143, 215, 0.3));
    transition: all 0.3s ease;
}

.navbar-brand-premium:hover .brand-icon svg {
    filter: drop-shadow(0 4px 12px rgba(0, 143, 215, 0.5));
    transform: scale(1.05);
}

.brand-text-wrapper {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.brand-name {
    font-family: 'Poppins', sans-serif;
    font-size: 1.375rem;
    font-weight: 800;
    line-height: 1;
    color: #ffffff;
    letter-spacing: -0.02em;
    text-shadow: 0 0 20px rgba(0, 143, 215, 0.3);
}

.brand-tagline {
    font-size: 0.6875rem;
    color: rgba(0, 168, 243, 0.8);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

/* Navigation Links */
.navbar-collapse {
    display: flex;
    flex-basis: auto;
    flex-grow: 1;
    align-items: center;
}

/* Desktop: always show menu */
@media (min-width: 992px) {
    .navbar-collapse {
        display: flex !important;
    }
    .navbar-collapse.collapse:not(.show) {
        display: flex !important;
    }
}

/* Mobile: use Bootstrap collapse behavior */
@media (max-width: 991px) {
    .navbar-collapse {
        display: none;
    }
    .navbar-collapse.collapse.show {
        display: block !important;
    }
    .navbar-collapse.collapsing {
        display: block !important;
        height: 0;
        overflow: hidden;
        transition: height 0.35s ease;
    }
}

.navbar-nav-premium {
    display: flex;
    align-items: center;
    gap: 8px;
    list-style: none;
    margin: 0;
    padding: 0;
    flex: 1;
    justify-content: center;
}

.nav-item-premium {
    position: relative;
}

.nav-link-premium {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 10px 14px;
    text-decoration: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.875rem;
    font-weight: 500;
    white-space: nowrap;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 8px;
}

.link-text {
    position: relative;
    z-index: 1;
}

.link-indicator {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #008fd7, #00a8f3);
    border-radius: 2px;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-link-premium:hover {
    color: #ffffff;
    background: rgba(0, 143, 215, 0.1);
}

.nav-link-premium:hover .link-indicator {
    width: 32px;
}

.nav-link-premium.active {
    color: #008fd7;
    font-weight: 600;
}

.nav-link-premium.active .link-indicator {
    width: 32px;
}

/* CTA Button */
.navbar-cta {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.cta-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 24px;
    background: linear-gradient(135deg, #008fd7 0%, #00a8f3 100%);
    color: #ffffff;
    font-size: 0.9375rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 10px;
    box-shadow: 0 4px 16px rgba(0, 143, 215, 0.35);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    border: none;
}

.cta-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.cta-button:hover::before {
    left: 100%;
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 143, 215, 0.5);
    color: #ffffff;
}

.cta-button i {
    font-size: 1.125rem;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: background 0.3s ease;
}

.mobile-menu-toggle:hover {
    background: rgba(0, 143, 215, 0.15);
}

.toggle-line {
    width: 24px;
    height: 2px;
    background: #008fd7;
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-menu-toggle[aria-expanded="true"] .toggle-line:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.mobile-menu-toggle[aria-expanded="true"] .toggle-line:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle[aria-expanded="true"] .toggle-line:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Mobile Actions (theme toggle + hamburger) */
.navbar-mobile-actions {
    display: none;
    align-items: center;
    gap: 8px;
}

.navbar-mobile-actions .theme-toggle {
    display: flex;
}

/* On desktop, hide the mobile-actions wrapper and show desktop toggle */
.theme-toggle-desktop {
    display: flex;
}

/* Responsive Design */
@media (max-width: 991px) {
    .navbar-content {
        flex-wrap: wrap;
    }

    /* Show mobile actions (toggle + hamburger) */
    .navbar-mobile-actions {
        display: flex;
        order: 2;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    /* Hide the desktop theme toggle inside CTA */
    .theme-toggle-desktop {
        display: none !important;
    }

    .navbar-brand-wrapper {
        order: 1;
    }

    .navbar-collapse {
        order: 3;
        width: 100%;
        margin-top: 16px;
        background: rgba(13, 19, 51, 0.95);
        border-radius: 12px;
        border: 1px solid rgba(255, 255, 255, 0.08);
    }

    [data-theme="light"] .navbar-collapse {
        background: rgba(255, 255, 255, 0.98);
        border-color: rgba(0, 0, 0, 0.06);
    }

    .navbar-nav-premium {
        flex-direction: column;
        align-items: stretch;
        gap: 4px;
        padding: 16px;
        border-top: none;
    }

    .nav-link-premium {
        flex-direction: row;
        justify-content: flex-start;
        padding: 12px 16px;
        border-radius: 8px;
    }

    .nav-link-premium:hover {
        background: rgba(0, 143, 215, 0.15);
    }

    .link-indicator {
        display: none;
    }

    .navbar-cta {
        padding: 16px;
        border-top: 1px solid rgba(255, 255, 255, 0.08);
    }

    [data-theme="light"] .navbar-cta {
        border-top-color: rgba(0, 0, 0, 0.06);
    }

    .cta-button {
        width: 100%;
        justify-content: center;
    }

    .brand-tagline {
        display: none;
    }
}

@media (max-width: 576px) {
    .navbar-container {
        padding: 0 16px;
    }

    .navbar-content {
        min-height: 64px;
    }

    .brand-name {
        font-size: 1.125rem;
    }

    .brand-icon svg {
        width: 28px;
        height: 28px;
    }

    .nav-link-premium {
        font-size: 0.875rem;
    }

    .cta-button {
        padding: 10px 20px;
        font-size: 0.875rem;
    }
}

/* Scroll Animations */
@keyframes slideDown {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.premium-navbar {
    animation: slideDown 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Accessibility */
.nav-link-premium:focus,
.cta-button:focus,
.mobile-menu-toggle:focus {
    outline: 2px solid #008fd7;
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .premium-navbar {
        border-bottom-width: 2px;
    }
    
    .nav-link-premium {
        font-weight: 600;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .premium-navbar,
    .nav-link-premium,
    .cta-button,
    .brand-icon svg {
        transition: none;
        animation: none;
    }
}

/* ========================================
   NAVBAR SEARCH & TRACKING ICONS
   ======================================== */

/* Shared icon button style */
.navbar-search-toggle,
.navbar-tracking-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    border: none;
    background: rgba(255, 255, 255, 0.07);
    color: rgba(255, 255, 255, 0.75);
    font-size: 1.2rem;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease, transform 0.15s ease;
    flex-shrink: 0;
}

.navbar-search-toggle:hover,
.navbar-tracking-btn:hover {
    background: rgba(0, 143, 215, 0.18);
    color: #008fd7;
    transform: scale(1.07);
}

.navbar-search-toggle.is-active {
    background: rgba(0, 143, 215, 0.2);
    color: #008fd7;
}

[data-theme="light"] .navbar-search-toggle,
[data-theme="light"] .navbar-tracking-btn {
    background: rgba(0, 0, 0, 0.06);
    color: rgba(0, 0, 0, 0.6);
}

[data-theme="light"] .navbar-search-toggle:hover,
[data-theme="light"] .navbar-tracking-btn:hover {
    background: rgba(0, 143, 215, 0.12);
    color: #008fd7;
}

/* ========================================
   SEARCH OVERLAY (Full-width dropdown)
   ======================================== */

.navbar-search-overlay {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    z-index: 1049;
    padding: 0;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.26s ease, transform 0.26s ease;
    pointer-events: none;
}

.navbar-search-overlay.is-open {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

/* Backdrop click zone */
.navbar-search-overlay::after {
    content: '';
    position: fixed;
    inset: 0;
    top: 72px;
    z-index: -1;
    background: rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(2px);
}

.navbar-search-box {
    background: rgba(13, 19, 51, 0.97);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 16px 24px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
}

[data-theme="light"] .navbar-search-box {
    background: rgba(255, 255, 255, 0.98);
    border-bottom-color: rgba(0, 0, 0, 0.08);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.navbar-search-form {
    display: flex;
    align-items: center;
    gap: 0;
    max-width: 720px;
    margin: 0 auto;
    height: 48px;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    overflow: hidden;
    transition: border-color 0.18s, box-shadow 0.18s, background 0.18s;
}

.navbar-search-form:focus-within {
    background: rgba(255, 255, 255, 0.1);
    border-color: #008fd7;
    box-shadow: 0 0 0 3px rgba(0, 143, 215, 0.18);
}

[data-theme="light"] .navbar-search-form {
    background: rgba(0, 0, 0, 0.04);
    border-color: rgba(0, 0, 0, 0.12);
}

[data-theme="light"] .navbar-search-form:focus-within {
    background: #fff;
    border-color: #008fd7;
    box-shadow: 0 0 0 3px rgba(0, 143, 215, 0.12);
}

.navbar-search-ico {
    flex-shrink: 0;
    padding: 0 10px 0 16px;
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.45);
    pointer-events: none;
    line-height: 1;
}

[data-theme="light"] .navbar-search-ico {
    color: rgba(0, 0, 0, 0.35);
}

.navbar-search-input {
    flex: 1;
    border: none;
    background: transparent;
    outline: none;
    padding: 0 8px 0 0;
    height: 100%;
    font-size: 0.9375rem;
    color: rgba(255, 255, 255, 0.95);
    min-width: 0;
}

[data-theme="light"] .navbar-search-input {
    color: #1a1a2e;
}

.navbar-search-input::placeholder {
    color: rgba(255, 255, 255, 0.35);
}

[data-theme="light"] .navbar-search-input::placeholder {
    color: rgba(0, 0, 0, 0.38);
}

.navbar-search-submit {
    flex-shrink: 0;
    border: none;
    background: #008fd7;
    color: #fff;
    width: 38px;
    height: 38px;
    margin: 4px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1rem;
    transition: background 0.18s, transform 0.15s;
}

.navbar-search-submit:hover {
    background: #0077b6;
    transform: scale(1.05);
}

.navbar-search-close {
    flex-shrink: 0;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.45);
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.25rem;
    transition: color 0.18s;
}

.navbar-search-close:hover {
    color: rgba(255, 255, 255, 0.9);
}

[data-theme="light"] .navbar-search-close {
    color: rgba(0, 0, 0, 0.4);
}

[data-theme="light"] .navbar-search-close:hover {
    color: rgba(0, 0, 0, 0.8);
}

/* Suggestions */
.navbar-search-suggest {
    max-width: 720px;
    margin: 8px auto 0;
    background: rgba(10, 15, 40, 0.98);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    max-height: 220px;
    overflow-y: auto;
    padding: 4px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

[data-theme="light"] .navbar-search-suggest {
    background: #fff;
    border-color: rgba(0, 0, 0, 0.1);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
}

.navbar-suggest-item {
    width: 100%;
    border: 0;
    background: transparent;
    text-align: left;
    padding: 9px 12px;
    border-radius: 7px;
    font-size: 0.875rem;
    color: rgba(240, 247, 255, 0.9);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background 0.15s ease;
}

.navbar-suggest-item::before {
    content: '\ec1d'; /* bx-search icon via content */
    font-family: 'boxicons';
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.3);
    flex-shrink: 0;
}

.navbar-suggest-item:hover {
    background: rgba(0, 143, 215, 0.15);
    color: #8dd9ff;
}

[data-theme="light"] .navbar-suggest-item {
    color: #1a1a2e;
}

[data-theme="light"] .navbar-suggest-item::before {
    color: rgba(0, 0, 0, 0.3);
}

[data-theme="light"] .navbar-suggest-item:hover {
    background: rgba(0, 143, 215, 0.08);
    color: #006fae;
}

/* Adjust overlay top on smaller navbar */
@media (max-width: 576px) {
    .navbar-search-overlay,
    .navbar-search-overlay::after {
        top: 64px;
    }
}

/* Theme toggle in mobile actions */
.navbar-mobile-actions .navbar-search-toggle,
.navbar-mobile-actions .navbar-tracking-btn {
    width: 36px;
    height: 36px;
    font-size: 1.1rem;
}
