/* Header Styles - Professional & Unique Design */

#main-header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    background-color: transparent;
}

#main-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    background: linear-gradient(to bottom, rgba(0,0,0,0.7), rgba(0,0,0,0.5));
    transition: opacity 0.4s ease;
    z-index: -1;
}

#main-header.scrolled::before {
    opacity: 1;
}

.nav-container {
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0.8rem 1.5rem;
    position: relative;
    transition: all 0.4s ease;
}

#main-header.scrolled .nav-container {
    padding: 0.4rem 1.5rem;
}

.nav-left, .nav-right {
    display: flex;
    align-items: center;
    position: relative;
    z-index: 2;
}

.logo-container {
    padding: 0 1rem;
    z-index: 3;
    position: relative;
}

.logo {
    height: 110px;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.5));
}

.logo:hover {
    transform: scale(1.05);
    filter: drop-shadow(0 0 10px rgba(255, 65, 54, 0.7));
}

#main-header.scrolled .logo {
    height: 70px;
}

@keyframes redFlash {
    0% { filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.5)); }
    50% { filter: drop-shadow(0 0 15px rgba(255, 65, 54, 0.9)); }
    100% { filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.5)); }
}

.nav-button {
    color: #f5f5f5;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.1rem;
    letter-spacing: 2px;
    padding: 0.6rem 0.8rem;
    margin: 0 0.2rem;
    border: 2px solid transparent;
    position: relative;
    transition: all 0.3s ease;
    text-transform: uppercase;
    font-family: 'Sawarabi Mincho', serif;
}

.nav-button::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background-color: #ff4136;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-button:hover {
    color: #ff4136;
}

.nav-button:hover::after {
    width: 70%;
}

.shop-button {
    background-color: #ff4136;
    color: #fff;
    border-radius: 4px;
    padding: 0.6rem 1rem;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(255, 65, 54, 0.3);
}

.shop-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: all 0.4s ease;
}

.shop-button:hover {
    background-color: #e03026;
    border-color: transparent;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(255, 65, 54, 0.4);
}

.shop-button:hover::after {
    width: 0;
}

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

/* Hamburger menu for mobile */
.mobile-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001;
}

.hamburger-line {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px 0;
    background-color: #fff;
    transition: all 0.3s ease;
}

/* Responsive design for header */
@media (max-width: 768px) {
    .mobile-toggle {
        display: block;
        position: absolute;
        right: 1rem;
        top: 1.5rem;
        z-index: 1002;
    }
    
    .nav-container {
        flex-direction: column;
        padding: 0.5rem;
    }
    
    .logo-container {
        margin: 0.5rem 0;
        z-index: 1001;
    }
    
    .logo {
        height: 90px;
    }
    
    #main-header.scrolled .logo {
        height: 60px;
    }
    
    /* Menu mobile unifié */
    .nav-left, .nav-right {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background-color: rgba(0, 0, 0, 0.95);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 2rem;
        transition: all 0.4s ease;
        z-index: 1000;
    }
    
    /* Disposition des éléments de navigation */
    .nav-open .nav-left,
    .nav-open .nav-right {
        right: 0;
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.5);
    }
    
    .nav-open .nav-left {
        top: 0;
        padding-bottom: 10px;
        justify-content: flex-end;
        height: 50vh;
    }
    
    .nav-open .nav-right {
        top: 50vh;
        padding-top: 10px;
        height: 50vh;
        justify-content: flex-start;
    }
    
    /* Amélioration des boutons de navigation */
    .nav-button {
        margin: 0.5rem 0;
        font-size: 1.2rem;
        padding: 0.8rem 1.5rem;
        width: 200px;
        text-align: center;
        border-radius: 5px;
        transition: all 0.3s ease;
    }
    
    .nav-button:hover {
        background-color: rgba(255, 65, 54, 0.2);
        transform: translateY(-3px);
    }
    
    /* Style spécial pour le bouton Shop */
    .shop-button {
        margin-top: 0.8rem;
        padding: 1rem 1.5rem;
        background-color: #ff4136;
    }
    
    .shop-button:hover {
        background-color: #e03026;
        transform: translateY(-3px);
    }
    
    /* Overlay sombre pour le reste de la page quand menu ouvert */
    .nav-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.5);
        z-index: 999;
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
    }
    
    .nav-open .nav-overlay {
        opacity: 1;
        visibility: visible;
    }
    
    /* Animation améliorée du hamburger */
    .nav-open .hamburger-line:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
        background-color: #ff4136;
    }
    
    .nav-open .hamburger-line:nth-child(2) {
        opacity: 0;
    }
    
    .nav-open .hamburger-line:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -7px);
        background-color: #ff4136;
    }
    
    /* Effet de fondu pour les éléments du menu */
    .nav-button {
        opacity: 0;
        transform: translateY(20px);
        transition: opacity 0.4s ease, transform 0.4s ease, color 0.3s ease, background-color 0.3s ease;
        transition-delay: 0.1s;
    }
    
    .nav-open .nav-button {
        opacity: 1;
        transform: translateY(0);
    }
    
    /* Délais d'animation séquentiels pour les boutons */
    .nav-open .nav-button:nth-child(1) {
        transition-delay: 0.1s;
    }
    
    .nav-open .nav-button:nth-child(2) {
        transition-delay: 0.2s;
    }
    
    .nav-open .nav-right .nav-button:nth-child(1) {
        transition-delay: 0.3s;
    }
    
    .nav-open .nav-right .shop-button {
        transition-delay: 0.4s;
    }
    
    /* Répartition verticale pour les petits écrans */
    @media (max-height: 600px) {
        .nav-open .nav-left, 
        .nav-open .nav-right {
            height: auto;
            position: absolute;
            top: 50%;
            transform: translateY(-50%);
            padding: 0.5rem;
            gap: 10px;
        }
        
        .nav-open .nav-left {
            top: 40%;
        }
        
        .nav-open .nav-right {
            top: 60%;
        }
        
        .nav-button {
            margin: 0.3rem 0;
        }
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .logo {
        height: 90px;
    }
    
    #main-header.scrolled .logo {
        height: 60px;
    }
    
    .nav-button {
        padding: 0.5rem 0.5rem;
        margin: 0 0.1rem;
        font-size: 0.8rem;
    }
}