/*
Theme Name: Courts dans les prés Version après festival 2025
Author: CinéJarzé et Clap et court
Version: 1.1
Description: Site du festival de courts métrage "Court dans les prés"
*/

/* -------------------------
   PALETTE DE COULEURS
   ------------------------- */
:root {
    --color-lin: rgb(237, 232, 228);
    /* #EDE8E4 */
    --color-gray: rgb(37, 32, 28);
    --color-fuschia: rgb(216, 95, 145);
    /* #D85F91 */
    --color-fuschia-60: rgb(216, 95, 145, 0.6);
    --color-pacific: rgb(224, 167, 71);
    /* #E0A747 */
    --color-carotte: rgb(228, 98, 40);
    /* #E46228 */
    --color-carotte-60: rgb(228, 98, 40, 0.6);
    --color-olive: rgb(177, 169, 63);
    /* #B1A93F */
    --color-olive-60: rgb(177, 169, 63, 0.6);

    --color-text: var(--color-lin);
    --color-text-white-background: var(--color-gray);
    --color-bg: var(--color-lin);
    --color-button_bg: var(--color-fuschia);
    --color-button_text: var(--color-lin);
    --color-button_hover: var(--color-carotte);
}

/* Utilities Colors */
.color-carotte {
    background-color: var(--color-carotte);
}

.carotte {
    color: var(--color-carotte);
}

.color-pacific {
    background-color: var(--color-pacific);
}

.color-olive {
    background-color: var(--color-olive);
}

.olive {
    color: var(--color-olive);
}

.pacific-background {
    background-color: var(--color-pacific);
}

.hover\:olive-background:hover,
.lg\:olive-background,
.sm\:olive-background,
.olive-background {
    background-color: var(--color-olive);
}

@media (min-width: 640px) {
    .olive-background\/60 {
        background-color: var(--color-olive-60);
    }
}

.lg\:fuschia-background,
.sm\:fuschia-background,
.fuschia-background {
    background-color: var(--color-fuschia);
}

@media (min-width: 640px) {
    .fuschia-background\/60 {
        background-color: var(--color-fuschia-60);
    }
}

.lg\:carotte-background,
.sm\:carotte-background,
.carotte-background {
    background-color: var(--color-carotte);
}

@media (min-width: 640px) {
    .carotte-background\/60 {
        background-color: var(--color-carotte-60);
    }
}

.lin-background {
    background-color: var(--color-lin);
}

/* Gutenberg Palette Classes */
.has-fuschia-color { color: var(--color-fuschia); }
.has-fuschia-background-color { background-color: var(--color-fuschia); }

.has-carotte-color { color: var(--color-carotte); }
.has-carotte-background-color { background-color: var(--color-carotte); }

.has-olive-color { color: var(--color-olive); }
.has-olive-background-color { background-color: var(--color-olive); }

.has-pacific-color { color: var(--color-pacific); }
.has-pacific-background-color { background-color: var(--color-pacific); }

.has-lin-color { color: var(--color-lin); }
.has-lin-background-color { background-color: var(--color-lin); }

.has-gray-color { color: var(--color-gray); }
.has-gray-background-color { background-color: var(--color-gray); }

.has-white-color { color: #ffffff; }
.has-white-background-color { background-color: #ffffff; }

.has-black-color { color: #000000; }
.has-black-background-color { background-color: #000000; }

.flex-2 {
    flex: 2 1 0%;
}

/* -------------------------
    TYPOGRAPHIES
    ------------------------- */
@font-face {
    font-family: 'PetalaPro-SemiBold';
    src: url("./assets/fonts/PetalaPro-SemiBold/PetalaPro-SemiBold.eot");
    src: url("./assets/fonts/PetalaPro-SemiBold/PetalaPro-SemiBold.eot?#iefix")format("embedded-opentype"),
        url("./assets/fonts/PetalaPro-SemiBold/PetalaPro-SemiBold.woff2")format("woff2"),
        url("./assets/fonts/PetalaPro-SemiBold/PetalaPro-SemiBold.woff")format("woff"),
        url("./assets/fonts/PetalaPro-SemiBold/PetalaPro-SemiBold.ttf")format("truetype"),
        url("./assets/fonts/PetalaPro-SemiBold/PetalaPro-SemiBold.svg#PetalaPro-SemiBold")format("svg");
}

@font-face {
    font-family: 'Petala Pro';
    src: url("./assets/fonts/PetalaPro/PetalaPro.eot");
    src: url("./assets/fonts/PetalaPro/PetalaPro.eot?#iefix")format("embedded-opentype"),
        url("./assets/fonts/PetalaPro/PetalaPro.woff2")format("woff2"),
        url("./assets/fonts/PetalaPro/PetalaPro.woff")format("woff"),
        url("./assets/fonts/PetalaPro/PetalaPro.ttf")format("truetype"),
        url("./assets/fonts/PetalaPro/PetalaPro.svg#PetalaPro-SemiBold")format("svg");
}

@font-face {
    font-family: 'Cheddar Gothic Rough';
    src: url('./assets/fonts/CheddarGothicRough-Regular.otf') format('opentype');
    font-weight: normal;
}

@font-face {
    font-family: 'Laurel-wreath';
    src: url("./assets/fonts/Laurel wreath.ttf")format("truetype");
}

/* -------------------------
    HTML elements
    ------------------------- */
body {
    margin: 0;
    font-family: 'Petala Pro', sans-serif;
    background: #f5f5f5;
}

h3,
h2,
h1 {
    font-family: 'PetalaPro-SemiBold', sans-serif;
    color: var(--color-text);
    margin: 0.5em 0;
}

.white-background h3,
.white-background h2,
.white-background h1 {
    font-family: 'PetalaPro-SemiBold', sans-serif;
    color: var(--color-text-white-background);
    margin: 0.5em 0;
}

html h1 {
    font-size: 2.5rem;
    line-height: 1;
}

html h2 {
    font-size: 2rem;
}

html h3 {
    font-size: 1.5rem;
}

.Laurel-wreath {
    font-family: 'Laurel-wreath';
}

main {
    /* margin-top: -35px; */
    clip-path: unset;
}

/* Common Section Styles */
section {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
    min-height: 830px;
    height: 100vh;
}

section {
    min-height: 60vh;
}


/* Force le header en mode menu sticky sur les pages internes */
body:not(.home) .header {
    position: sticky;
    top: 0;
    width: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    padding: 10px 0;
}

body:not(.home) .header .nav-links {
    justify-content: center;
}


/* ------------------
   Images génériques
   ------------------- */
.ImageCentre {
    background-image: url('./assets/LS_VacheBlanche.png');
    background-size: 100px;
    background-position: center;
    background-repeat: repeat;
    width: 100%;
    height: 100%;
    display: block;
}


section.titre .section-text {
    padding: 1em 5% 0em 5%;
    font-size: clamp(0.1rem, 4vw, 1.5rem);
    text-align: start;
    align-content: start;
}

section:nth-child(even) {
    flex-direction: row-reverse;
}

.section-text {
    flex: 1;
    padding: 8em 10% 0em 10%;
    font-size: clamp(0.1rem, 4vw, 1.5rem);
    transform: translateY(30px);
    transition: all 0.6s ease-out;
    color: #fff;
    align-content: center;
    line-height: 1.3;
}

.section-image {
    flex: 1;
    text-align: center;
    line-height: unset;
    overflow: hidden;
    position: relative;
}

.section-image img {
    max-width: 100%;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.immgDateEvenement {
    position: absolute;
    right: 0px;
    bottom: 0px;
    height: 200px;
}

section.angled::before {
    content: "";
    position: absolute;
    top: -50px;
    left: 0;
    width: 100%;
    height: 100px;
    background: inherit;
    clip-path: polygon(0 100%, 100% 0, 100% 100%, 0% 100%);
    z-index: 0;
}

.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Animations Scroll */
.animate-fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

/* Responsive Common */
@media (max-width: 768px) {
    section {
        flex-direction: column;
        height: auto;
        line-height: 1.5em;
    }

    .section-text {
        padding: 2em 5% 0.5em 5%;
        font-size: 0.7em;
        transform: none;
        text-align: center;
        line-height: 1.5em;
    }

    .section-image {
        width: 100%;
        height: auto;
        margin-bottom: 1em;
    }

    .section-image img {
        width: 100%;
        height: 30vh;
        object-fit: cover;
        display: block;
    }

    .immgDateEvenement {
        position: absolute;
        right: 0px;
        bottom: 0px;
        height: 100px;
    }
}

/* ------------------
   Style pour le bouton Back to Top
  ------------------- */
#back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background-color: var(--color-button_bg);
    color: var(--color-button_text);
    width: 3rem;
    height: 3rem;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.3s, visibility 0.3s;
    opacity: 0;
    visibility: hidden;
    z-index: 99;
    border: 0;
}

#back-to-top.opacity-100.visible {
    opacity: 1;
    visibility: visible;
}

#back-to-top.opacity-0.invisible {
    opacity: 0;
    visibility: hidden;
}

#back-to-top:hover {
    background-color: var(--color-button_hover);
}

/* Language Toggle */
.language-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.8);
    border-radius: 25px;
    padding: 10px;
    display: flex;
    gap: 10px;
    opacity: 0.8;
}

.lang-btn {
    padding: 8px 15px;
    background: transparent;
    color: #fff;
    border: 2px solid #fff;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.lang-btn.active {
    background: #fff;
    color: #2c3e50;
}

.lang-btn:hover {
    background: #fff;
    color: #2c3e50;
}

/* Misc / Debug */
.debug {
    border: 2px solid red;
}

.debug>div {
    border: 3px dashed #d85f91;
}


/* Images génériques (utilisées pour plusieurs sections si non déplacées) */
.ImageCentre {
    background-image: url('./assets/LS_VacheBlanche.png');
    background-size: 100px;
    background-position: center;
    background-repeat: repeat;
    width: 100%;
    height: 100%;
    display: block;
}