:root {
    --color-accent: rgba(149, 6, 6, 1);
    --color-text: rgba(223, 223, 223, 0.75);
    --color-text-hover: rgba(136, 136, 136, 1);
    --color-background: rgba(18, 18, 18, 1);
    --color-border: rgba(136, 136, 136, 1);
    --color-button-text: rgba(223, 223, 223, 1);
    --color-button-hover-bg: rgba(223, 223, 223, 1);
    --color-button-hover-text: rgba(0, 0, 0, 1);
}

/* --- Styles Généraux et Fonts --- */
* { margin: 0; padding: 0; box-sizing: border-box; }

@font-face {
    font-family: 'SFFlorencesans';
    src: url('font/SFFlorencesans.woff2') format('woff2'),
         url('font/SFFlorencesans.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'SFFlorencesans';
    src: url('font/SFFlorencesans-Bold.woff2') format('woff2'),
         url('font/SFFlorencesans-Bold.ttf') format('truetype');
    font-weight: bold;
    font-style: normal;
}
#about,
#director-frankie,
#director-vera,
#the-edge,
#skrean,
#xtra,
#contact {
    position: absolute;
    /* Pulls the anchor out of the layout, fixing the centering */

    top: 0;
    /* Positions the anchor at the very top of its parent section */

    scroll-margin-top: 80px;
    /* The modern way to tell the browser to leave space for the nav bar */
}

html { scroll-behavior: smooth; }
body { background-color: transparent; font-family: 'SFFlorencesans', sans-serif; }

/* --- Navigation --- */
.main-nav {
    position: fixed;
    top: 0;
    width: 100%;
    text-align: center;
    padding: 20px 0;
    z-index: 100;
    background: linear-gradient(to bottom, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 100%);
}

.main-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: inline-flex;
    align-items: center;
    gap: 40px;
}

.main-nav a {
    color: var(--color-accent);
    text-shadow: 0 0 4px rgba(149, 6, 6, 0.5);
    text-decoration: none;
    font-weight: normal;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-size: 14px;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.main-nav a:hover {
    color: var(--color-text-hover);
    text-shadow: none;
}

.dropdown { position: relative; }

.dropdown-content {
    display: none;
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: #000000;
    padding: 15px 25px;
    min-width: 220px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    list-style: none;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.dropdown:hover .dropdown-content { display: flex; }

.dropdown-content a {
    color: var(--color-text-hover);
    text-shadow: none;
    font-weight: normal;
    font-size: 14px;
    letter-spacing: 2px;
    text-transform: uppercase;
    transition: color 0.3s ease;
}

.dropdown-content a:hover {
    color: var(--color-text);
    background-color: transparent;
    text-shadow: none;
}

/* Menu Hamburger (caché par défaut sur desktop) */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 10px;
    position: fixed;
    top: 15px;
    right: 20px;
    z-index: 101;
    background: rgba(0,0,0,0.5);
    border-radius: 4px;
}

.hamburger span {
    width: 25px;
    height: 2px;
    background-color: var(--color-accent);
    margin: 3px 0;
    transition: 0.3s;
    box-shadow: 0 0 4px rgba(149, 6, 6, 0.5);
}

.hamburger.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
}

/* --- Fond & Overlays --- */
.background-video {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    background-image: url('assets/img/Aegir-Background.webp');
    background-color: var(--color-background);
    background-size: cover;
    background-position: center;
    animation: kenBurns 20s infinite alternate;
}

@keyframes kenBurns {
    from { transform: scale(1); }
    to { transform: scale(1.05); }
}

.grain-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    background-image: url('data:image/svg+xml,<svg viewBox="0 0 500 500" xmlns="http://www.w3.org/2000/svg"><filter id="noise"><feTurbulence baseFrequency="0.9" numOctaves="3" stitchTiles="stitch"/></filter><rect width="100%" height="100%" filter="url(%23noise)"/></svg>');
    opacity: 0.1;
    mix-blend-mode: overlay;
}

/* --- Sections & Contenu --- */
section {
    width: 100%;
    min-height: 100vh;
    position: relative;
}

.centered-section {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 40px;
}

#home .container {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100vh;
    position: absolute;
    top: 0;
    left: 0;
}

.logo, .tagline {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.logo {
    max-width: 15%;
    opacity: 0;
    animation: fadeInZoom 2.5s ease-out 4.3s forwards;
    filter: brightness(80%) blur(0.4px) drop-shadow(0 0 3px rgba(136, 136, 136, 0.3)) drop-shadow(0 0 8px rgba(136, 136, 136, 0.15));
}

@keyframes fadeInZoom {
    from {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

.tagline {
    color: var(--color-text);
    font-size: 14px;
    font-weight: bold;
    letter-spacing: 4px;
    text-transform: uppercase;
    white-space: nowrap;
    opacity: 0;
    animation: fadeInAndOut 4s ease-in-out 0.3s forwards;
    filter: brightness(80%) blur(0.4px) drop-shadow(0 0 3px rgba(136, 136, 136, 0.3)) drop-shadow(0 0 8px rgba(136, 136, 136, 0.15));
}

@keyframes fadeInAndOut {
    0% { opacity: 0; }
    33% { opacity: 1; }
    80% { opacity: 1; }
    100% { opacity: 0; }
}

.about-content {
    max-width: 650px;
    width: 90%;
    text-align: center;
    color: var(--color-text);
    z-index: 1;
    padding-top: 60px;
    padding-bottom: 60px;
}

.about-content h2, .about-content p {
    text-shadow: 0 0 3px rgba(136, 136, 136, 0.2), 0 0 8px rgba(136, 136, 136, 0.1);
}

.about-content h2 {
    font-size: 14px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 30px;
}

.about-content p {
    font-size: 14px;
    line-height: 1.7;
    margin-bottom: 1.5em;
}

/* --- Style pour les liens dans les paragraphes --- */
.about-content a {
    color: var(--color-accent);
    text-decoration: none;
    text-shadow: 0 0 4px rgba(149, 6, 6, 0.5);
    font-weight: bold;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.about-content a:hover {
    color: var(--color-text-hover);
    text-shadow: none;
}

/* --- Boutons --- */
.project-links {
    margin-top: 40px;
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.button {
    display: inline-block;
    padding: 12px 25px;
    border: 1px solid var(--color-border);
    color: var(--color-button-text);
    text-decoration: none;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 2px;
    transition: background-color 0.3s, color 0.3s;
}

.button:hover {
    background-color: var(--color-button-hover-bg);
    color: var(--color-button-hover-text);
}

/* --- SECTION RÉALISATEUR --- */
/* Spécifique aux sections réalisateurs : empiler bio et galerie verticalement */
.director-content-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

#director-frankie .about-content,
#director-vera .about-content {
    margin-bottom: 50px; /* Espace entre la bio et la galerie */
}

/* --- GALERIE VIDÉO --- */
.video-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    max-width: 650px;
    width: 90%;
}

.video-thumbnail {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    background-color: var(--color-background);
}

.video-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.video-thumbnail:hover img { transform: scale(1.05); }

.thumbnail-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    color: var(--color-button-text);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    text-align: center;
    padding: 10px;
}

.video-thumbnail:hover .thumbnail-overlay { opacity: 1; }

.video-title-overlay {
    font-family: 'SFFlorencesans', sans-serif;
    font-size: 12px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

.play-text-overlay {
    font-family: 'SFFlorencesans', sans-serif;
    font-size: 12px;
    padding: 2px 8px;
    border: 1px solid var(--color-button-text);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* --- Style pour l'affiche du film --- */
.project-poster {
    max-width: 200px;
    width: 50%;
    height: auto;
    margin: 0 auto 30px auto;
    display: block;
    cursor: pointer;
    transition: transform 0.3s ease;
    border: 1px solid rgba(136, 136, 136, 0.3);
}

.project-poster:hover {
    transform: scale(1.05);
}

/* --- SECTION XTRA / PRODUIT --- */
.product-section {
    background-color: none;
}

.product-item {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 60px;
    align-items: center;
    max-width: 900px;
    width: 90%;
    color: var(--color-text);
}

.product-image-gallery {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.main-product-image {
    width: 100%;
    height: auto;
    display: block;
    border: 1px solid rgba(136, 136, 136, 0.3);
}

.thumbnails {
    display: flex;
    gap: 10px;
}

.thumbnails img {
    width: 70px;
    height: 70px;
    object-fit: cover;
    cursor: pointer;
    border: 1px solid transparent;
    transition: border-color 0.3s ease;
}

.thumbnails img:hover, .thumbnails img.active {
    border-color: var(--color-border);
}

.product-details {
    text-align: left;
}

.product-name {
    font-size: 16px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 10px;
    color: var(--color-button-text);
}

.product-price {
    font-size: 16px;
    color: var(--color-accent);
    margin-bottom: 25px;
    font-weight: bold;
}

.product-description p {
    font-size: 14px;
    line-height: 1.7;
    margin-bottom: 1em;
    text-shadow: none;
}

.product-description a {
    color: var(--color-accent);
    text-decoration: none;
    font-weight: bold;
}

.shipping-note {
    font-size: 0.8em;
    opacity: 0.7;
}

.product-details .button {
    margin-top: 30px;
    text-align: center;
    display: inline-block;
}

/* --- SECTION CONTACT --- */
#contact {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 100px 20px;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    max-width: 500px;
    margin: 40px auto 0 auto;
}

.contact-form label {
    color: var(--color-text);
    font-size: 14px;
    letter-spacing: 1px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    text-align: left;
}

.contact-form input,
.contact-form textarea {
    background-color: rgba(18, 18, 18, 0.8);
    border: 1px solid var(--color-border);
    color: var(--color-text);
    padding: 10px 15px;
    font-family: 'SFFlorencesans', sans-serif;
    font-size: 14px;
    outline: none;
    transition: border-color 0.3s ease, background-color 0.3s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: var(--color-accent);
    background-color: rgba(30, 30, 30, 0.9);
}

.contact-form .button {
    align-self: center;
    padding: 12px 25px;
    border: 1px solid var(--color-border);
    color: var(--color-button-text);
    text-decoration: none;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 2px;
    transition: background-color 0.3s, color 0.3s;
    background: none;
    cursor: pointer;
}

.contact-form .button:hover {
    background-color: var(--color-button-hover-bg);
    color: var(--color-button-hover-text);
}
/* --- Back to Top Button --- */
#back-to-top {
    /* Positioning */
    position: fixed;
    right: 30px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 99;

    /* Styling */
    background-color: none;
    color: var(--color-accent);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);

    /* Show/Hide Transition */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease-in-out, visibility 0.3s ease-in-out, background-color 0.3s ease;
}

#back-to-top:hover {
    background-color: #c82333; /* A slightly brighter red for hover */
}

/* The class that JavaScript will add to show the button */
#back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

/* Styling the SVG arrow inside the button */
#back-to-top svg {
    fill: var(--color-button-text);
    width: 28px;
    height: 28px;
}
/* --- Responsive --- */

/* Tablettes en paysage et petits écrans desktop */
@media (max-width: 1024px) {
    .main-nav ul {
        gap: 25px;
    }
    
    .main-nav a {
        font-size: 12px;
    }
    
    .product-item {
        gap: 40px;
        max-width: 800px;
    }
}

/* Tablettes en portrait et grands mobiles en paysage */
@media (max-width: 900px) {
    #director-frankie, #director-vera { 
        padding: 80px 20px; 
    }
    
    .about-content {
        padding-top: 80px;
        padding-bottom: 40px;
    }
    
    .main-nav {
        padding: 15px 0;
    }
    
    .main-nav ul {
        gap: 20px;
        flex-wrap: wrap;
        padding: 0 10px;
    }
}

/* Tablettes en portrait et mobiles en paysage */
@media (max-width: 768px) {
    .video-gallery { 
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .about-content { 
        font-size: 15px;
        max-width: 90%;
    }
    
    .logo { 
        max-width: 40%;
    }
    
    .tagline { 
        width: 90%; 
        text-align: center; 
        white-space: normal; 
        font-size: 12px;
        padding: 0 20px;
    }
    
    .product-item {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .product-details {
        text-align: center;
    }
    
    .product-details .button {
        display: block;
        margin: 30px auto 0;
    }
    
    .thumbnails {
        justify-content: center;
    }
    /* --- Add this to your @media (max-width: 768px) block --- */

/* 1. Show the hamburger icon on mobile */
.hamburger {
    display: flex; /* Makes the icon visible */
}

/* 2. Hide the navigation list by default on mobile and style it as an overlay */
.main-nav ul {
    display: none; /* Hide the menu by default */
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: var(--color-background); /* Give it a solid background */
    flex-direction: column; /* Stack links vertically */
    justify-content: center; /* Center them on the screen */
    align-items: center;
    gap: 30px; /* Add space between links for easy tapping */
}

/* 3. Show the menu when the .active class is added by JavaScript */
.main-nav ul.active {
    display: flex; /* This makes the menu appear */
}

/* A single, clean rule for the mobile dropdown content */
.dropdown-content {
    position: static;
    background-color: transparent;
    box-shadow: none;
    display: none; 
    align-items: center;
    padding: 15px 20px 0; /* Merged padding (top, sides, bottom) */
    gap: 10px;
    min-width: 180px;
}

/* Show dropdown content when its parent has the .active class from JS */
.dropdown.active .dropdown-content {
    display: flex;
}
    
    
    .project-links {
        flex-direction: column;
        gap: 15px;
    }
    
    .button {
        width: 100%;
        max-width: 280px;
    }
    
    .project-poster {
        max-width: 180px;
        width: 60%;
    }
    
    .centered-section {
        padding: 0 20px;
    }
    
    #contact {
        padding: 80px 20px;
    }
}

/* Mobiles en paysage */
@media (max-width: 667px) and (orientation: landscape) {
    section {
        min-height: auto;
    }
    
    .about-content {
        padding-top: 100px;
        padding-bottom: 60px;
    }
    
    .video-gallery {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }
    
    .logo {
        max-width: 25%;
    }
    
    #home .container {
        height: 100vh;
        min-height: 500px;
    }
}

/* Mobiles en portrait */
@media (max-width: 480px) {
    .video-gallery { 
        grid-template-columns: 1fr;
        gap: 15px;
        max-width: 100%;
    }
    
    .logo {
        max-width: 60%;
    }
    
    .tagline {
        font-size: 11px;
        letter-spacing: 2px;
    }
    
    .about-content {
        font-size: 14px;
        padding-top: 100px;
    }
    
    .about-content h2 {
        font-size: 13px;
        margin-bottom: 20px;
    }

    
    .main-nav a {
        letter-spacing: 1px;
    }
    
    .dropdown-content {
        min-width: 150px;
        font-size: 11px;
    }
    
    .project-poster {
        max-width: 150px;
        width: 70%;
    }
    
    .product-name {
        font-size: 14px;
    }
    
    .product-price {
        font-size: 14px;
    }
    
    .product-description p {
        font-size: 13px;
    }
    
    .thumbnails img {
        width: 60px;
        height: 60px;
    }
    
    .button {
        font-size: 11px;
        padding: 10px 20px;
    }
    
    .contact-form {
        max-width: 100%;
    }
    
    .contact-form label {
        font-size: 13px;
    }
    
    .contact-form input,
    .contact-form textarea {
        font-size: 13px;
    }
}

/* Petits mobiles en portrait */
@media (max-width: 375px) {
    .logo {
        max-width: 70%;
    }
    
    .main-nav ul {
        gap: 8px;
        font-size: 9px;
    }
    
    .about-content {
        font-size: 13px;
    }
    
    .video-thumbnail {
        aspect-ratio: 16 / 10;
    }
    
    .product-item {
        gap: 20px;
    }
    
    .thumbnails img {
        width: 50px;
        height: 50px;
    }
}

/* Très petits mobiles */
@media (max-width: 320px) {
    .main-nav {
        padding: 10px 0;
    }
    
    .main-nav ul {
        gap: 6px;
        font-size: 8px;
    }
    
    .logo {
        max-width: 75%;
    }
    
    .about-content {
        font-size: 12px;
        padding-top: 90px;
    }
    
    .button {
        font-size: 10px;
        padding: 8px 15px;
    }
}