/**
 * GenuVerity Shared Components CSS
 */

:root {
    --navbar-height: 72px;
    --navbar-bg-opacity: 0.7;
    --navbar-bg-blur: 40px;
    --footer-bg-opacity: 0.8;
}

/* Navbar Base */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--navbar-height);
    background: rgba(5, 10, 20, var(--navbar-bg-opacity)) !important;
    backdrop-filter: blur(var(--navbar-bg-blur)) !important;
    -webkit-backdrop-filter: blur(var(--navbar-bg-blur)) !important;
    border-bottom: 1px solid transparent;
    display: grid;
    grid-template-columns: 60px minmax(200px, 1fr) auto;
    align-items: center;
    padding: 0 40px;
    gap: 24px;
    z-index: 1000;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.navbar-scrolled {
    background: rgba(5, 10, 20, var(--navbar-bg-opacity));
    backdrop-filter: blur(var(--navbar-bg-blur));
    border-bottom-color: var(--border-color);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

/* Logo & Branding */
.navbar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.navbar-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 700;
    font-size: 1.25rem;
}

.navbar-logo-wrapper {
    position: relative;
    width: 40px;
    height: 40px;
}

/* Scroll Progress Bar */
.navbar::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    height: 2px;
    background: var(--accent-cyan);
    width: var(--scroll-progress, 0%);
    transition: width 0.1s linear;
    box-shadow: 0 0 10px var(--accent-cyan);
    z-index: 1001;
}

/* Searchlight Animation (Matching Landing Page) */
.ss-nav {
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    pointer-events: none;
}

.ss-nav::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: conic-gradient(from 0deg at 50% 50%, transparent 0deg, rgba(59, 130, 246, 0.3) 30deg, transparent 60deg);
    animation: sweep-30 4s ease-in-out infinite alternate;
}

@keyframes sweep-30 {
    from {
        transform: rotate(-20deg);
    }

    to {
        transform: rotate(20deg);
    }
}

.g-icon-nav {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 300;
    /* Thin style */
    font-family: 'Inter', sans-serif;
    font-size: 1.8rem;
    /* Restored size */
    line-height: 1;
    z-index: 2;
}

/* Hide full text logo, user wants just the G icon */
.logo-text {
    display: none;
}

/* Navbar Search */
.navbar-center {
    display: flex;
    justify-content: center;
}

/* === FOOTER === */
.footer {
    margin-top: 80px;
    padding: 60px 0;
    text-align: center;
    border-top: 1px solid var(--border-color);
    background: rgba(5, 10, 20, var(--footer-bg-opacity));
    position: relative;
    z-index: 10;
}

/* Footer Logo with Animation */
.footer-logo-wrapper {
    position: relative;
    display: inline-block;
    padding: 8px 16px;
    margin-bottom: 8px;
}

.ss-footer {
    position: absolute;
    inset: -6px;
    border-radius: 40px;
    pointer-events: none;
}

.ss-footer::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 40px;
    background: conic-gradient(from 0deg at 50% 50%, transparent 0deg, rgba(59, 130, 246, 0.1) 30deg, transparent 60deg);
    animation: sweep-30 4s ease-in-out infinite alternate;
}

/* === SEARCH OVERLAY (Critical - prevents blur artifact) === */
.search-overlay {
    position: fixed;
    inset: 0;
    background: rgba(5, 10, 20, 0.95);
    backdrop-filter: blur(20px);
    z-index: 2000;
    display: none;
    align-items: flex-start;
    justify-content: center;
    padding: 120px 24px 24px;
}

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

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

.search-input-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 24px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    margin-bottom: 24px;
}

.search-input-large {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 1.25rem;
    font-family: inherit;
    outline: none;
}

.search-input-large::placeholder {
    color: var(--text-muted);
}

/* === SEARCH OVERLAY FIX === */
/* Ensure search overlay appears above carousel cards */
.search-overlay {
    z-index: 9999 !important;
}

.carousel-section {
    z-index: 1 !important;
}

/* Hero search dropdown fix */
.hero-search {
    position: relative;
    z-index: 100 !important;
}

.nexus-dropdown {
    z-index: 10000 !important;
}

.navbar-search-container {
    position: relative;
    display: flex;
    align-items: center;
    background: rgba(17, 24, 39, 0.8);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 0 16px;
    height: 40px;
    width: 100%;
    max-width: 300px;
    opacity: 1;
    pointer-events: all;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.navbar-search-input {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    width: 100%;
    max-width: 400px;
    transition: all 0.3s ease;
}

.navbar-search-container:focus-within {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--accent-cyan);
    box-shadow: 0 0 15px rgba(6, 182, 212, 0.2);
}

.navbar-search-input {
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 0.95rem;
    width: 100%;
    outline: none;
    margin-left: 10px;
    font-family: 'Inter', sans-serif;
}

/* Navbar Search Dropdown */

.nexus-dropdown {
    position: absolute;
    top: 50px;
    left: 0;
    width: 300px;
    background: rgba(10, 15, 30, 0.95);
    backdrop-filter: blur(40px);
    -webkit-backdrop-filter: blur(40px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 16px;
    opacity: 0;
    transform: translateY(-15px) scale(0.98);
    pointer-events: none;
    transition: all 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8);
    z-index: 10000;
    max-height: 450px;
    overflow-y: auto;
}

.nexus-dropdown.open {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

/* === PREMIUM BUTTONS === */
.btn-premium-glass {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 50px;
    color: #fff;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    backdrop-filter: blur(4px);
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.1);
}

.btn-premium-glass::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;
}

.btn-premium-glass:hover {
    background: rgba(59, 130, 246, 0.25);
    border-color: rgba(59, 130, 246, 0.6);
    transform: translateY(-2px);
    box-shadow: 0 0 25px rgba(59, 130, 246, 0.3);
}

.btn-premium-glass:hover::before {
    left: 100%;
}

.btn-premium-glass.cyan {
    background: rgba(6, 182, 212, 0.1);
    border-color: rgba(6, 182, 212, 0.3);
    box-shadow: 0 0 15px rgba(6, 182, 212, 0.1);
}

.btn-premium-glass.cyan:hover {
    background: rgba(6, 182, 212, 0.25);
    border-color: rgba(6, 182, 212, 0.6);
    box-shadow: 0 0 25px rgba(6, 182, 212, 0.3);
}

.pulsing-cta {
    animation: pulse-glow 2s ease-in-out infinite;
}

@keyframes pulse-glow {

    0%,
    100% {
        box-shadow: 0 0 15px rgba(59, 130, 246, 0.1);
    }

    50% {
        box-shadow: 0 0 30px rgba(59, 130, 246, 0.3);
    }
}

/* Navbar Right */
.navbar-right {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    overflow: visible;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s;
}

.nav-link:hover {
    color: #fff;
}

/* Premium Buttons */
.btn-premium-glass {
    padding: 8px 20px;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 50px;
    color: #fff;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    backdrop-filter: blur(4px);
    transition: all 0.3s;
}

.btn-premium-glass:hover {
    background: rgba(59, 130, 246, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.pulsing-cta {
    animation: cta-pulse 2s infinite;
}

@keyframes cta-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.4);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(59, 130, 246, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(59, 130, 246, 0);
    }
}

/* Mobile Hamburger */
.navbar-hamburger {
    display: none;
    background: none;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 8px;
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    inset: 0;
    background: rgba(5, 10, 20, 0.98);
    backdrop-filter: blur(20px);
    z-index: 2000;
    display: none;
    flex-direction: column;
    padding: 24px;
}

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

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

.menu-close {
    background: none;
    border: none;
    color: #fff;
    cursor: pointer;
    font-size: 1.5rem;
}

.mobile-menu-links {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.mobile-menu-links a {
    color: #fff;
    text-decoration: none;
    font-size: 1.25rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Responsive */
@media (max-width: 1024px) {
    .navbar {
        grid-template-columns: 50px 1fr auto;
        padding: 0 20px;
        gap: 16px;
    }

    .navbar-right {
        gap: 4px;
    }
}

@media (max-width: 768px) {
    .logo-text {
        display: none;
    }

    .navbar-right {
        display: none;
    }

    .navbar-hamburger {
        display: block;
    }

    .navbar-search-container {
        max-width: calc(100% - 48px);
        min-width: 200px;
        margin: 0 8px;
    }
}