:root {
    --dark-1: #121212;
    --dark-2: #000000;
    --dark-3: #1a1a1a;
    --light-1: #e0e0e0;
    --light-2: #b0b0b0;
    --primaire: #c9a769;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Montserrat', sans-serif;
}



body {
    background-color: #000;
    /* Couleur de fond de base */
    background-image:
        linear-gradient(to top, rgba(201, 167, 105, 0.223), rgba(0, 0, 0, 0.815)),
        url("https://www.transparenttextures.com/patterns/asfalt-light.png");
    background-repeat: repeat;
    background-size: auto;
    background-attachment: fixed;
    /*https://www.transparenttextures.com/*/
    color: var(--light-1);
    line-height: 1.6;
    overflow-x: hidden;
    /*cursor: url('./pocheadouille.png'), auto;*/
}

/* Animation de chargement */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--dark-2);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s, visibility 0.5s;
}

.loader img {
    width: 40%;
    height: auto;
    animation: rotate 4s linear infinite;
    border-radius: 12px;
}

@keyframes rotate {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.loader.fade-out {
    opacity: 0;
    visibility: hidden;
}

#loader-3d {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: #0d0d0d;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

#dessertCanvas {
    width: 300px;
    height: 300px;
}

/* Navigation */
nav {
    position: relative;
    width: 100%;
    background-color: var(--dark-2) !important;
    /*border-bottom: 1px solid #333;*/
    z-index: 1000;
    padding: 0.5rem 2%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 0 0 12px 12px;
    margin-top: 0rem;
}

.logo-container {
    display: flex;
    align-items: center;
}

.logo-img {
    height: 80px;
    margin-right: 15px;
    border-radius: 12px;
}

.logo-text {
    font-size: 1rem;
    font-weight: 700;
    color: var(--primaire);
    letter-spacing: 1px;
}

.hamburger {
    display: none;
    cursor: pointer;
    z-index: 1001;
}

.hamburger div {
    width: 25px;
    height: 2px;
    background-color: #e0e0e0;
    margin: 5px;
    transition: all 0.3s ease;
    border-radius: 12px;
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 2rem;
    position: relative;
}

.nav-links a {
    text-decoration: none;
    color: #e0e0e0;
    font-weight: 500;
    transition: color 0.3s;
    letter-spacing: 1px;
    padding: 8px 12px;
    border-radius: 12px;
}

.nav-links a:hover {
    color: var(--primaire);
    background: rgba(201, 167, 105, 0.1);
}

/* ADMIN */
.admin-bar {
    position: relative;
    width: 100%;
    padding: 0.5rem 2%;
    display: flex;
    justify-content: space-evenly;
    align-items: center;
    margin-top: 0rem;
}

.admin-controls {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 5px;
    opacity: 0;
    transition: opacity 0.3s;
}

.gallery-item:hover .admin-controls {
    opacity: 1;
}

.edit-btn,
.delete-btn {
    border: none;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.edit-btn {
    background: #c9a769;
}

.delete-btn {
    background: #e74c3c;
}

.edit-title-input {
    width: 100%;
    padding: 8px;
    border: 1px solid #444;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.9);
    text-align: center;
    font-size: 14px;
}

.popup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
}

.popup-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #1a1a1a;
    padding: 30px;
    border-radius: 12px;
    width: 90%;
    max-width: 400px;
    color: white;
}

.popup h3 {
    color: #c9a769;
    margin-bottom: 20px;
    text-align: center;
}

.popup input,
.popup button {
    width: 100%;
    padding: 12px;
    margin: 10px 0;
    border: 1px solid #444;
    border-radius: 6px;
    background: #2a2a2a;
    color: white;
}

.popup button {
    background: #c9a769;
    border: none;
    cursor: pointer;
    font-weight: 600;
}

.message {
    padding: 10px;
    margin: 10px 0;
    border-radius: 4px;
    text-align: center;
}

.success {
    background: #27ae60;
    color: white;
}

.error {
    background: #e74c3c;
    color: white;
}

/* intro Section */
.intro {
    height: 100vh;
    display: flex;
    align-items: center;
    padding: 0 10%;
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    margin: 20px;
    margin-top: 80px;

}

.intro::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(18, 18, 18, 0.9), rgba(18, 18, 18, 0.5)),
        url('./img/tartefraise.jpg') no-repeat center center/cover;
    z-index: -1;
    border-radius: 12px;
}

.intro-content {
    max-width: 600px;
    animation: fadeIn 1.5s ease-out;
    background: rgba(18, 18, 18, 0.7);
    padding: 40px;
    border-radius: 12px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.intro h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    background: linear-gradient(45deg, #eceaea, #c9a769);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.intro p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: #b0b0b0;
}

.btn {
    display: inline-block;
    background: transparent;
    color: var(--primaire);
    padding: 0.8rem 1.5rem;
    border: 2px solid var(--primaire);
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    letter-spacing: 1px;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--primaire);
    transition: all 0.3s;
    z-index: -1;
}

.btn:hover {
    color: var(--light-2);
}

.btn:hover::before {
    left: 0;
}

/* Section Présentation */
.presentation {
    padding: 8rem 10%;
    display: flex;
    align-items: center;
    background-color: var(--dark-3);
    border-radius: 12px;
    margin: 20px;
}

.presentation-img {
    flex: 1;
    padding-right: 0.5rem;
    position: relative;
}

.presentation-img::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    top: -20px;
    left: -20px;
    z-index: -1;
    border-radius: 12px;
}

.presentation-img img {
    width: 100%;
    filter: grayscale(40%);
    transition: filter 0.3s;
    border-radius: 12px;
}

.presentation-img:hover img {
    filter: grayscale(0%);
}

.presentation-text {
    flex: 1;
}

/*test pourquoi nous*/

.section.light {
    background: transparent;
    color: #111;
}

.features {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    gap: 2rem;
}

#atouts {
    background-color: #1a1a1a;
    background-image: url("https://www.transparenttextures.com/patterns/fresh-snow.png");
    /* This is mostly intended for prototyping; please download the pattern and re-host for production environments. Thank you! */
}

.feature {
    max-width: 300px;
    background: #333;
    padding: 2rem;
    border-radius: 12px;
    color: #f1f1f1;
    transition: box-shadow 0.3s;
}

.feature:hover {
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.418);
    transform: translateY(-5px);
}

/*fin de teste*/

.section-title {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--primaire);
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    width: 50%;
    height: 2px;
    background: var(--primaire);
    bottom: -10px;
    left: 0;
    border-radius: 12px;
}

.presentation-text p {
    margin-bottom: 1.5rem;
    color: #b0b0b0;
}

/* Galerie */
.gallery {
    padding: 8rem 10%;
    text-align: center;
    background-color: var(--dark-1);
    border-radius: 12px;
    margin: 20px;
}

.gallery h2 {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: linear-gradient(45deg, #eceaea, #c9a769);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.gallery-item {
    overflow: hidden;
    position: relative;
    border-radius: 12px;
}

.gallery-item img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    transition: transform 0.5s, filter 0.3s;
    filter: brightness(0.8);
    border-radius: 12px;
}

.gallery-item:hover img {
    transform: scale(1.05);
    filter: brightness(1);
}

.gallery-item-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 1rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    color: white;
    transform: translateY(100%);
    transition: transform 0.3s;
    border-radius: 0 0 12px 12px;
}

.gallery-item:hover .gallery-item-caption {
    transform: translateY(0);
}

/* Partenaires */
.partners {
    padding: 8rem 10%;
    background-color: var(--dark-3);
    border-radius: 12px;
    margin: 20px;
}

.partners h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #fff;
}

.partners-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
}

.partner-card {
    background: #252525;
    padding: 2rem;
    border-radius: 12px;
    transition: transform 0.3s;
    text-align: center;
}

.partner-card:hover {
    transform: translateY(-10px);
}

.partner-img {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: 50%;
    margin: 0 auto 1.5rem;
    border: 3px solid var(--primaire);
}

.partner-card h3 {
    color: var(--primaire);
    margin-bottom: 1rem;
}

.partner-card p {
    color: #b0b0b0;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

.partner-link {
    color: var(--primaire);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s;
}

.partner-link:hover {
    color: #fff;
    text-decoration: underline;
}

.cta-final {
    height: 90vh;
    background: linear-gradient(to bottom, var(--clair), var(--gris-clair));
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.cta-final-content {
    max-width: 700px;
    animation: fadeUp 1s ease;
}

.cta-final h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    font-family: 'Playfair Display', serif;
}

.cta-final p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: var(--gris);
}


/* Footer */
footer {
    background-color: #0d0d0d;
    color: #b0b0b0;
    padding: 5rem 10% 2rem;
    border-radius: 12px 12px 0 0;
    margin-top: 40px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 2rem;
    margin-bottom: 3rem;
    border-bottom: 1px solid #333;
    padding-bottom: 3rem;
}

.footer-section {
    flex: 1;
    min-width: 300px;
    margin-bottom: 2rem;
}

.footer-section:nth-child(2) {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.footer-section h3 {
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
    color: var(--primaire);
    letter-spacing: 1px;
}

.footer-section p,
.footer-section a {
    color: #b0b0b0;
    text-decoration: none;
    display: block;
    margin-bottom: 0.8rem;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: var(--primaire);
}

.allergenes-link {
    color: var(--primaire);
    text-decoration: underline;
}

.social-icons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 1rem;
}

.social-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid #333;
    color: #b0b0b0;
    transition: all 0.3s;
    border-radius: 50%;
}

.social-icons a:hover {
    border-color: var(--primaire);
    color: var(--primaire);
    transform: translateY(-3px);
}

.copyright {
    text-align: center;
    padding-top: 2rem;
    color: #666;
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 992px) {
    .hamburger {
        display: block;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        background-color: #0d0d0d;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        transition: right 0.5s ease;
        border-left: 1px solid #333;
        border-radius: 12px 0 0 12px;
    }



    .nav-links li {
        margin: 1.5rem 0;
    }

    .nav-active {
        right: 0;
    }

    .toggle .line1 {
        transform: rotate(-45deg) translate(-5px, 6px);
    }

    .toggle .line2 {
        opacity: 0;
    }

    .toggle .line3 {
        transform: rotate(45deg) translate(-5px, -6px);
    }

    .intro {
        margin: 10px;
        margin-top: 80px;
    }

    .intro h1 {
        font-size: 2.8rem;
    }

    .presentation,
    .gallery,
    .partners {
        margin: 10px;
    }

    .presentation {
        flex-direction: column;
    }

    .presentation-img {
        padding-right: 0;
        margin-bottom: 1rem;
    }

    .presentation-img::before {
        display: none;
    }
}

@media (max-width: 576px) {
    .intro h1 {
        font-size: 2.2rem;
    }

    .intro p {
        font-size: 1rem;
    }

    .section-title {
        font-size: 1.8rem;
    }

    /*
    .logo-text {
        font-size: 1.4rem;
    }
*/
    .logo-img {
        height: 80px;
    }
}

footer a {
    text-decoration: none;
    color: var(--light-2);
}

.footer-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
}

.footer-form input,
.footer-form textarea {
    background: #1a1a1a;
    border: 1px solid #333;
    padding: 0.8rem 1rem;
    border-radius: 8px;
    color: #e0e0e0;
    font-size: 1rem;
    resize: none;
}

.footer-form input::placeholder,
.footer-form textarea::placeholder {
    color: #888;
}

.footer-form input:focus,
.footer-form textarea:focus {
    outline: none;
    border-color: var(--primaire);
    background-color: #111;
}

/* === ANIMATIONS JS === */
[data-gsap] {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}