/* Base Styles */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 68px;
}
body {
    padding-top: 68px;
}
/* Main Header Container */
.header {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(25px);
    box-shadow: var(--shadow-medium);
    border-radius: 55px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    animation: slideDown 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 8px 12px;
}
.header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 55px;
    pointer-events: none;
    z-index: -1;
}
/* Header Hidden State - Scroll Down */
.header.header-hidden {
    transform: translateX(-50%) translateY(-150%);
    opacity: 0;
}
/* Header Scrolled State */
.header.scrolled {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(30px);
    box-shadow: var(--shadow-hover);
    transform: translateX(-50%) scale(0.95);
}
/* Scroll Progress Bar */
.scroll-progress-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 12px;
    z-index: 1001;
    background: rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(10px);
}
.scroll-progress-bar {
    height: 100%;
    width: 0;
    background-size: 200% 100%;
    background: var(--dynamo-red) 0 50%;
    transition: width 0.1s ease-out;
    box-shadow: var(--shadow-medium);
    animation: gradientShift 3s ease-in-out infinite;
    position: relative;
    border-radius: 0 6px 6px 0;
}
.scroll-progress-bar::after {
    content: '';
    position: absolute;
    right: -1px;
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    background-image: url('../../img/icons/white-football-icon.png');
    background-size: contain;
    background-repeat: no-repeat;
    z-index: 1;
}
@keyframes gradientShift {
    0%, 100% {
        background-position: 0 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}
/* Navigation Container */
.nav-container {
    max-width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    margin: 0 auto;
}
/* Navigation Links */
.nav-links {
    display: flex;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 6px;
    gap: 8px;
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(15px);
    border-radius: 33px;
}
.nav-link {
    background: transparent;
    border: none;
    color: var(--dark-gray);
    padding: 8px 16px;
    border-radius: 22px;
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
    letter-spacing: 1px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    z-index: 1;
    text-decoration: none;
}
.nav-link span {
    position: absolute;
    display: block;
    width: 0;
    height: 0;
    border-radius: 50%;
    background-color: var(--dynamo-red);
    transition: width 0.4s ease-in-out, height 0.4s ease-in-out;
    transform: translate(-50%, -50%);
    z-index: -1;
}
.nav-link:hover {
    color: var(--off-white);
}
.nav-link:hover span {
    width: 200%;
    height: 165px;
}
.nav-link.active {
    color: var(--off-white);
    background: var(--dynamo-red);
}
.nav-link:focus {
    color: var(--off-white);
    outline: none;
}
.nav-link:focus span {
    width: 200%;
    height: 165px;
}
/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 9px 13px;
    z-index: 1001;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 9px;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}
.mobile-menu-toggle:hover {
    background: rgba(255, 255, 255, 0.5);
    transform: scale(1.05);
}
.mobile-menu-toggle span {
    width: 22px;
    height: 2px;
    background: var(--dynamo-red);
    margin: 2px 0;
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-6.5px, 6px);
}
.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}
.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(45deg) translate(-6.5px, -6px);
}
/* Header Logo Container */
.header-logo-container {
    display: none;
    align-items: center;
    justify-content: center;
}
/* Header Logo Link */
.header-logo-link {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}
/* Header Logo Container */
.logo-container {
    position: relative;
    width: 40px;
    height: 40px;
}
/* Header Logo Images */
.header-logo {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    opacity: 1;
}
/* Logo Red */
.header-logo-red {
    opacity: 1;
}
/* Animations */
@keyframes slideDown {
    from {
        transform: translateX(-50%) translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateX(-50%) translateY(0);
        opacity: 1;
    }
}
/* Tablet View */
@media (max-width: 768px) {
    .header {
        width: 90%;
        top: 15px;
        padding: 7px 11px;
    }
    .nav-container {
        padding: 0;
    }
    .mobile-menu-toggle {
        display: flex;
        padding: 7px 11px;
    }
    .nav-links {
        position: absolute;
        top: calc(100% + 10px);
        left: 10px;
        right: 10px;
        flex-direction: column;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(25px);
        border-radius: 22px;
        padding: 18px;
        gap: 9px;
        transform: translateY(-20px);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: var(--shadow-medium);
    }
    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    .nav-link {
        padding: 9px 18px;
        font-size: 0.88rem;
        width: 100%;
        justify-content: center;
    }
    .nav-link span {
        display: none;
    }
    .nav-link:hover,
    .nav-link:focus {
        color: var(--dark-gray);
        background: transparent;
    }
    .nav-link:hover span,
    .nav-link:focus span {
        width: 0;
        height: 0;
    }
}
/* Mobile View */
@media (max-width: 480px) {
    body {
        padding-top: 60px;
    }
    .header {
        width: 86%;
        top: 8px;
        padding: 6px 8px;
        border-radius: 40px;
        background: rgba(255, 255, 255, 0.92);
        backdrop-filter: blur(20px);
        box-shadow: var(--shadow-hover);
        display: flex;
        align-items: center;
    }
    .scroll-progress-container {
        display: none;
    }
    .nav-container {
        padding: 0;
        justify-content: space-between;
        position: relative;
        width: 100%;
        align-items: center;
    }
    .mobile-menu-toggle {
        padding: 8px 10px;
        border-radius: 8px;
        order: 1;
    }
    .mobile-menu-toggle span {
        width: 24px;
        height: 3px;
        margin: 3px 0;
    }
    .header-logo-container {
        display: flex;
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
        order: 2;
    }
    .nav-links {
        order: 3;
        left: 6px;
        right: 6px;
        top: calc(100% + 8px);
        padding: 12px;
        border-radius: 16px;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(15px);
        gap: 8px;
    }
    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    }
    .nav-link {
        background: transparent;
        border: none;
        color: var(--dark-gray);
        padding: 8px 16px;
        border-radius: 22px;
        font-family: 'Poppins', sans-serif;
        font-weight: 600;
        letter-spacing: 1px;
        font-size: 1rem;
        cursor: pointer;
        transition: all 0.3s ease;
        display: flex;
        align-items: center;
        justify-content: center;
        position: relative;
        overflow: hidden;
        z-index: 1;
        text-decoration: none;
        width: 100%;
        min-height: 44px;
    }
    .nav-link span {
        display: none;
    }
    .nav-link:hover,
    .nav-link:focus {
        color: var(--dark-gray);
        background: transparent;
    }
    .nav-link:hover span,
    .nav-link:focus span {
        width: 0; /* Prevent span expansion */
        height: 0;
    }
    .nav-link.active {
        color: var(--off-white);
        background: var(--dynamo-red);
    }
}
/* Accessibility Enhancements */
@media (prefers-reduced-motion: reduce) {
    .header,
    .nav-link {
        animation: none;
        transition: none;
    }
    html {
        scroll-behavior: auto;
    }
    .header {
        transition: transform 0.1s ease, opacity 0.1s ease;
    }
    .nav-link span {
        transition: none;
    }
    .scroll-progress-bar {
        animation: none;
        transition: none;
    }
}
/* Responsive Design - Tablet and Desktop */
@media (min-width: 481px) {
    .header-logo-container {
        display: none;
    }
}
/* Performance Optimizations */
.header {
    will-change: transform, background, box-shadow, opacity;
}
.nav-link {
    will-change: transform, color;
}
.scroll-progress-bar {
    will-change: width;
}