/* =====================================================
   VARIABLES & RESET
   ===================================================== */

:root {
    /* Couleurs de base */
    --color-primary: #222f41;
    --color-primary-rgb: 34, 47, 65;
    --color-primary-hover: #1a2433;

    --color-secondary: #dc2626;
    --color-secondary-rgb: 220, 38, 38;
    --color-secondary-hover: #b91c1c;
   
    /* Couleurs système */
    --color-bg: #ffffff;
    --color-text: var(--color-primary);
    --color-text-light: #627691;
    --color-border: rgba(var(--color-primary-rgb), 0.12);
    
    /* Typographies */
    --font-primary: 'IBM Plex Sans', sans-serif;
    --font-secondary: 'Inter', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-secondary);
    color: var(--color-text);
    background-color: var(--color-bg);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img, video {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

button {
    border: none;
    background: none;
    cursor: pointer;
    font-family: inherit;
}

/* =====================================================
   UTILITIES
   ===================================================== */

.no-select {
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

/* Classe utilitaire accessibilité */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* =====================================================
   HEADER
   ===================================================== */

.header {
    background: var(--color-primary);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    color: white;
    padding: 1rem 1rem;
    text-align: center;
    position: relative;
}

.header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--color-secondary);
}

/* .header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 7px;
    background: var(--color-secondary);
    clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 55%, 0 100%);
} */

.header__content {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin: 0 auto;
}

.header__text {
    text-align: center;
}

.header__title {
    font-family: var(--font-primary);
    font-size: 1.6rem;
    font-weight: 800;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 2px;
    line-height: 1.1;
    animation: fadeInDown 0.6s ease-out;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.3);
}

.header__subtitle {
    font-size: 0.7rem;
    font-weight: 500;
    margin: 0.25rem 0 0 0;
    line-height: 1.3;
    opacity: 0.95;
    animation: fadeInDown 0.6s ease-out 0.1s backwards;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    white-space: nowrap;
}

.header-link {
    display: block;
}

.header-link .header {
    cursor: pointer;
}

@media (min-width: 350px) {
    .header__title {
        font-size: 1.85rem;
    }
    .header__subtitle {
        font-size: 0.8rem;
    }
}

@media (min-width: 381px) {
    .header__title {
        font-size: 2rem;
    }
    .header__subtitle {
        font-size: 0.85rem;
    }
}

@media (min-width: 576px) {
    .header__title {
        font-size: 2.2rem;
    }
    .header__subtitle {
        letter-spacing: 2.5px;
    }
    .header::before {
        height: 5px;
    }
    /* .header::before {
        height: 9px;
        clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 50%, 0 100%);
    } */
}

@media (min-width: 768px) {
    .header {
        padding: 1.2rem 1.5rem;
    }
    .header__content {
        gap: 1.5rem;
        max-width: 1000px;
    }
    .header__title {
        font-size: 2.45rem;
        letter-spacing: 3px;
    }
    .header__subtitle {
        font-size: 0.95rem;
        letter-spacing: 3.1px;
    }
    .header::before {
        height: 6px;
    }
    /* .header::before {
        height: 11px;
        clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 45%, 0 100%);
    } */
}

@media (min-width: 1024px) {
    .header {
        padding: 1.5rem 2rem;
    }
    .header__content {
        gap: 2rem;
    }
    .header__title {
        font-size: 2.8rem;
    }
    .header__subtitle {
        font-size: 1.1rem;
    }
    /* .header::before {
        height: 13px;
        clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 43%, 0 100%);
    } */
}

/* =====================================================
   LOGOS PARTENAIRES
   ===================================================== */

.partners {
    background: #ffffff;
    padding: 2rem 1.5rem 3rem 1.5rem;
    position: relative;
}

.partners::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 2rem);
    max-width: 1325px;
    height: 1px;
    background: var(--color-primary);
}

.partners__container {
    max-width: 500px;
    margin: 0 auto;
}

.partners__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    align-items: center;
    justify-items: center;
}

.partners__item {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 110px;
}

.partners__item a {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
}

.partners__logo {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    opacity: 0.85;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.partners__item a:hover .partners__logo {
    opacity: 1;
    transform: scale(1.05);
}

.partners__logo--ministere {
    max-width: 120px;
    max-height: 110px;
}

.partners__logo--carac {
    max-width: 160px;
    max-height: 65px;
}

.partners__logo--chauvel {
    max-width: 94px;
    max-height: 140px;
}

.partners__logo--ligue {
    max-width: 148px;
    max-height: 82px;
}

@media (min-width: 768px) {
    .partners__container {
        max-width: 1200px;
    }
    .partners {
        padding: 4rem 1rem;
    }
    
    .partners__grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 1rem;
    }
    
    .partners__item {
        height: 140px;
        padding: 1rem 0.5rem;
    }
    
    .partners__logo--ministere {
        max-width: 150px;
        max-height: 138px;
    }
    
    .partners__logo--carac {
        max-width: 200px;
        max-height: 80px;
    }
    
    .partners__logo--chauvel {
        max-width: 115px;
        max-height: 172px;
    }
    
    .partners__logo--ligue {
        max-width: 182px;
        max-height: 101px;
    }
}

@media (min-width: 1024px) {
    .partners__item {
        height: 160px;
    }
    
    .partners__logo--ministere {
        max-width: 165px;
        max-height: 152px;
    }
    
    .partners__logo--carac {
        max-width: 220px;
        max-height: 88px;
    }
    
    .partners__logo--chauvel {
        max-width: 125px;
        max-height: 187px;
    }
    
    .partners__logo--ligue {
        max-width: 198px;
        max-height: 111px;
    }
}

/* =====================================================
   FOOTER
   ===================================================== */

.footer {
    background: var(--color-primary);
    color: white;
    text-align: center;
    padding: 1rem 0.5rem;
    font-size: 0.9rem;
    position: relative;
    line-height: 1.6;
}

.copyright-part {
    display: block;
    margin-bottom: 0.5rem;
}

.separator {
    display: none;
}

.contact-part {
    display: block;
}

.contact-label {
    display: none;
}

.contact-icon {
    font-size: 0.9em;
    margin-right: 0.4rem;
    transition: transform 0.3s ease;
}

.footer a {
    color: white;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.footer a:hover .contact-icon {
    transform: translateX(3px);
}

@media (min-width: 768px) {
    .footer { padding: 1.5rem; font-size: 0.95rem; }
    .copyright-part { display: inline; margin: 0; }
    .separator { display: inline; margin: 0 1rem; }
    .contact-part { display: inline; }
    .contact-label { display: inline; }
}

/* =====================================================
   HOME PAGE
   ===================================================== */

.home {
    max-width: 1400px;
    margin: 0 auto 1rem;
    padding: 0.5rem;
    position: relative;
}

@media (min-width: 576px) {
    .home { padding: 1rem; }
}

/* =====================================================
   BOUTON PARAMÈTRES HOME
   ===================================================== */

.settings-btn-home {
    position: absolute;
    top: 0.5rem;
    right: 0;
    width: 40px;
    height: 40px;
    background: transparent;
    color: var(--color-primary);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    z-index: 10;
}

.settings-btn-home:hover {
    color: var(--color-secondary);
    transform: rotate(90deg);
}

.settings-btn-home i {
    pointer-events: none;
}

@media (min-width: 768px) {
    .settings-btn-home { width: 44px; height: 44px; font-size: 1.4rem; }
}

@media (min-width: 1400px) {
    .settings-btn-home { right: calc((100vw - 1400px) / -2 + 10px); }
}

/* =====================================================
   SECTION AUTHOR
   ===================================================== */

.author-section {
    text-align: center;
    padding: 0.5rem;
    background: var(--color-bg);
    animation: fadeIn 0.8s ease-out;
}

.author-section__name {
    font-family: var(--font-primary);
    font-size: clamp(1.35rem, 4vw, 2.2rem);
    font-weight: 700;
    color: var(--color-primary);
    line-height: 1.1;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.author-section__name::after {
    content: '';
    display: block;
    width: 55px;
    height: 4px;
    background: var(--color-secondary);
    margin: 0.4rem auto;
}

.author-section__role {
    font-family: var(--font-secondary);
    font-size: clamp(0.85rem, 2vw, 1rem);
    font-weight: 600;
    color: var(--color-text);
    font-style: normal;
    text-transform: uppercase;
    letter-spacing: 1.4px;
}

@media (min-width: 400px) {
    .author-section__role {
        letter-spacing: 2px;
        font-size: clamp(0.85rem, 2vw, 1.1rem);
    }
}

@media (min-width: 576px) {
    .author-section__name { margin-bottom: 0.3rem; }
    .author-section__name::after { margin: 0.6rem auto; }
    .author-section__role { letter-spacing: 2.5px; }
    .author-section__name::after {height: 5px;}
}

@media (min-width: 768px) {
    .author-section { padding: 0.7rem 2rem 1rem; }
    .author-section__name::after {height: 6px;}
}

/* =====================================================
   HERO SECTION
   ===================================================== */

.hero {
    position: relative;
    margin-bottom: 0;
    animation: fadeIn 0.8s ease-out 0.2s backwards;
    padding: 0.35rem 1rem 1rem;
}

.hero__image-container {
    max-width: 700px;
    margin: 0 auto;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.2);
    position: relative;
}

.hero__image {
    width: 100%;
    height: auto;
    display: block;
}

.hero__credit {
    position: absolute;
    bottom: 6px;
    right: 6px;
    background: rgba(15, 23, 42, 0.5);
    color: white;
    font-size: 0.75rem;
    padding: 1px;
    border-radius: 8px;
    font-family: var(--font-secondary);
    font-weight: 400;
    letter-spacing: 0.5px;
    opacity: 0.95;
    z-index: 5;
}

@media (min-width: 800px) {
    .hero__image-container {
        max-width: 900px;
        aspect-ratio: 16 / 9;
    }
    
    .hero__image {
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: center 35%;
    }
}

@media (min-width: 1024px) {
    .hero {
        padding: 0.5rem 2rem 1rem;
    }
    
    .hero__image-container {
        max-width: 1000px;
        aspect-ratio: 21 / 9;
    }
    
    .hero__image {
        object-position: center 35%;
    }
    
    .hero__credit {
        font-size: 0.85rem;
        padding: 2px;
        bottom: 10px;
        right: 10px;
    }
}

/* =====================================================
   BOUTONS TOGGLE INTERACTIFS (STYLE UNIFIÉ)
   ===================================================== */

/* Style de base commun aux 3 boutons */
.hero__toggle-btn,
.media__toggle-btn,
.leaflet-control-reset-button {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: var(--color-primary) !important;
    width: 35px !important;
    height: 35px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 1rem !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2) !important;
    transition: all 0.3s ease !important;
    cursor: pointer !important;
    border: none !important;
    text-decoration: none !important;
}

/* Hover UNIQUEMENT sur les appareils avec souris */
@media (hover: hover) and (pointer: fine) {
    .hero__toggle-btn:hover,
    .media__toggle-btn:hover,
    .leaflet-control-reset-button:hover {
        transform: scale(1.1) !important;
        background: white !important;
        color: var(--color-secondary) !important;
    }
}

/* Positionnement spécifique hero */
.hero__toggle-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 10;
}

/* Positionnement spécifique media */
.media__toggle-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 10;
    animation: none;
}

/* Transition des icônes */
.hero__toggle-btn i,
.media__toggle-btn i {
    transition: transform 0.3s ease;
}

/* Responsive pour les boutons toggle */
@media (min-width: 768px) {
    .hero__toggle-btn,
    .media__toggle-btn,
    .leaflet-control-reset-button {
        width: 45px !important;
        height: 45px !important;
        font-size: 1.1rem !important;
    }
    
    .hero__toggle-btn,
    .media__toggle-btn {
        top: 15px;
        right: 15px;
    }
}

/* =====================================================
   LEAFLET - BOUTON RESET VIEW
   ===================================================== */

.leaflet-control-reset {
    margin-top: 10px !important;
}

.leaflet-control-reset-button {
    line-height: 40px !important;
}

@media (min-width: 768px) {
    .leaflet-control-reset-button {
        line-height: 48px !important;
    }
}

/* =====================================================
   HERO - TOGGLE CARTE / PHOTO (INDEX.HTML)
   ===================================================== */

/* Container carte mondiale */
.hero__map-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    border-radius: 16px;
    overflow: hidden;
    display: none;
}

.hero__map {
    width: 100%;
    height: 100%;
}

/* États du toggle */
.hero__image-container--with-map {
    position: relative;
}

.hero__image-container--with-map .hero__image {
    position: relative;
    z-index: 2;
}

.hero__image-container--showing-map .hero__image {
    display: none;
}

.hero__image-container--showing-map .hero__map-container {
    display: block;
}

.hero__image-container--showing-map .hero__credit {
    display: none;
}

.hero__image-container--showing-map {
    aspect-ratio: 16/10;
}

@media (min-width: 800px) {
    .hero__image-container--showing-map {
        aspect-ratio: 16/9;
    }
}

@media (min-width: 1024px) {
    .hero__image-container--showing-map {
        aspect-ratio: 21/9;
    }
}

/* =====================================================
   GALLERY
   ===================================================== */

.gallery {
    padding: 1rem;
}

.gallery__header {
    text-align: center;
    margin-bottom: 1rem;
}

.gallery__title {
    font-family: var(--font-primary);
    font-size: clamp(1.35rem, 4vw, 2.2rem);
    font-weight: 700;
    color: var(--color-primary);
    line-height: 1.1;
    margin-bottom: 0.3rem;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.gallery__title::after {
    content: '';
    display: block;
    width: 55px;
    height: 4px;
    background: var(--color-secondary);
    margin: 0.6rem auto;
}

.gallery__subtitle {
    font-family: var(--font-secondary);
    font-size: clamp(0.85rem, 2vw, 1rem);
    font-weight: 600;
    color: var(--color-text);
    font-style: normal;
    text-transform: uppercase;
    letter-spacing: 1.4px;
    margin: 0;
}

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

.gallery__item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 
        inset 0 0 0 1px rgba(255, 255, 255, 0.1),
        inset 0 -1px 0 0 rgba(0, 0, 0, 0.1),
        0 4px 12px rgba(15, 23, 42, 0.15);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: var(--color-border);
    aspect-ratio: 3/2;
}

.gallery__item:hover {
    transform: translateY(-4px);
    box-shadow: 
        inset 0 0 0 1px rgba(255, 255, 255, 0.15),
        inset 0 -1px 0 0 rgba(0, 0, 0, 0.15),
        0 8px 24px rgba(15, 23, 42, 0.2);
}

.gallery__item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.gallery__item:hover img {
    transform: scale(1.05);
}

.gallery__overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0.3) 100%);
    padding: 0.5rem;
    color: white;
    transform: translateY(0);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.gallery__thematique {
    font-family: var(--font-primary);
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 0;
    position: relative;
    display: inline-block;
    padding-left: 1rem;
}

.gallery__thematique::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 80%;
    background: var(--color-secondary);
}

@media (hover: hover) and (pointer: fine) {
    .gallery__overlay {
        background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.3) 100%);
        transform: translateY(100%);
        padding: 0.2rem 1rem;
    }
    .gallery__item:hover .gallery__overlay { transform: translateY(0); }
    .gallery__thematique { font-size: 0.9rem; }
}

@media (hover: none) {
    .gallery__overlay { transform: translateY(0); }
}

@media (min-width: 400px) {
    .gallery__subtitle {
        letter-spacing: 2px;
        font-size: clamp(0.85rem, 2vw, 1.1rem);    
    }
}

@media (min-width: 576px) {
    .gallery { padding: 1.8rem 1.5rem; }
    .gallery__header { margin-bottom: 2.5rem; }
    .gallery__subtitle { letter-spacing: 2.5px; }
    .gallery__title::after {height: 5px;}
    .gallery__thematique::before {width: 5px;}
}

@media (min-width: 768px) {
    .gallery__grid { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
    .gallery__title::after {height: 6px;}
    .gallery__thematique::before {width: 6px;}
}

@media (min-width: 1024px) {
    .gallery__grid { grid-template-columns: repeat(auto-fill, minmax(350px, 1fr)); gap: 2rem; }
}

/* =====================================================
   PHOTO PAGE
   ===================================================== */

.photo-page {
    max-width: 800px;
    margin: 0 auto;
    padding: 1.5rem 1.5rem 3rem 1.5rem;
}

.thematique {
    text-align: center;
    font-family: var(--font-primary);
    font-size: clamp(1.1rem, 3vw, 1.6rem);
    font-weight: 700;
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 2rem;
    padding: 1rem 1.5rem;
    background-color: rgba(15, 23, 42, 0.04);
    border-radius: 8px;
    border-left: 5px solid var(--color-secondary);
    border-right: 5px solid var(--color-secondary);
    border-bottom: 1px solid rgba(15, 23, 42, 0.1);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.03);
    position: relative;
    animation: slideInLeft 0.6s ease-out;
    overflow: hidden;
}

@media (min-width: 1024px) {
    .photo-page { padding: 2rem 2rem 4rem 2rem; }
    .thematique { border-left: 7px solid var(--color-secondary); border-right: 7px solid var(--color-secondary); }
}

/* =====================================================
   MEDIA (VIDEO/PHOTO)
   ===================================================== */

.media {
    margin-bottom: 1rem;
    animation: fadeIn 0.8s ease-out;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.media__container {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(15, 23, 42, 0.16);
    margin-bottom: 0.5rem;
    background: #000;
    aspect-ratio: 3/2;
}

.media__image,
.media__video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
    display: block;
}

.media__legend {
    font-size: clamp(0.85rem, 2.5vw, 0.95rem);
    font-style: italic;
    color: var(--color-text-light);
    text-align: center;
    padding: 0 1rem;
    margin: 0;
}

/* =====================================================
   DESCRIPTION
   ===================================================== */

.description__text {
    font-size: clamp(0.95rem, 2.5vw, 1.05rem);
    line-height: 1.7;
    margin-bottom: 1.7rem;
}

.description__text p {
    margin: 0;
}

.description__toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--color-primary);
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 0 0 1.5rem;
    position: relative;
}

.description__toggle:after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    bottom: 1.3rem;
    left: 0;
    background-color: var(--color-primary);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.description__toggle:hover {
    gap: 1rem;
}

.description__toggle:hover:after {
    width: 75%;
}

.description__toggle i {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.description__suite {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    padding-top: 0;
    transform-origin: top;
    transform: scaleY(0);
    transition: max-height 0.6s cubic-bezier(0, 1, 0, 1), 
                opacity 0.4s ease, 
                transform 0.4s ease, 
                padding-top 0.6s ease;
}

.description__suite.active {
    max-height: 1000px;
    opacity: 1;
    padding-top: 1rem;
    transform: scaleY(1);
    transition: max-height 1s ease-in-out, 
                opacity 0.6s ease, 
                transform 0.6s ease, 
                padding-top 0.6s ease;
}

@media (min-width: 576px) {
    .description { margin-bottom: 1rem; margin-left: auto; margin-right: auto; }
}

@media (min-width: 768px) {
    .description { max-width: 700px; }
}

/* =====================================================
   ACCORDION
   ===================================================== */

.accordion {
    margin: 0.3rem 0 3rem;
}

.accordion__item {
    margin-bottom: 1.2rem;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.accordion__header {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    background: var(--color-border);
    font-family: var(--font-primary);
    font-size: clamp(0.95rem, 2.5vw, 1.1rem);
    font-weight: 600;
    color: var(--color-primary);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: left;
}

.accordion__header:hover {
    background: var(--color-primary);
    color: white;
}

.accordion__header:hover i {
    color: white;
}

.accordion__header.active {
    background: var(--color-primary);
    color: white;
}

.accordion__header.active i {
    color: white;
}

.accordion__header i:first-child {
    font-size: 1.2em;
}

.accordion__icon {
    margin-left: auto;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.accordion__header.active .accordion__icon {
    transform: rotate(180deg);
}

.accordion__content {
    max-height: 0;
    overflow: hidden;
    padding: 0;
    border-top: 1px solid transparent;
    transition: max-height 0.4s ease-out, padding 0s 0.4s, border-top-color 0s 0.4s;
}

.accordion__content.active {
    max-height: 2000px;
    padding: 1rem 0.7rem;
    border-top-color: var(--color-border);
    transition: max-height 0.4s ease-out, padding 0s 0s, border-top-color 0s 0s;
}

.accordion__content p:not(.focus__legend):not(.focus__text):not(.focus__no-ressources) {
    line-height: 1.8;
    font-size: clamp(0.9rem, 2.5vw, 1rem);
}

/* =====================================================
   QUESTIONS
   ===================================================== */

.questions {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.question {
    padding: 1rem;
    background: rgba(15, 23, 42, 0.04);
    border-radius: 8px;
    border-left: 4px solid var(--color-secondary);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: clamp(0.9rem, 2.5vw, 1rem);
}

.question:hover {
    background: rgba(15, 23, 42, 0.08);
    transform: translateX(4px);
}

.question__main {
    position: relative;
    padding-right: 3rem;
    font-weight: 500;
    color: var(--color-primary);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.question__main i:first-child {
    color: var(--color-secondary);
    flex-shrink: 0;
}

.question__text {
    display: block;
    padding-right: 0.5rem;
}

.question.completed {
    pointer-events: none;
    opacity: 0.7;
}

.question__status {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%) scale(0);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    color: var(--color-primary);
}

.question.completed .question__status {
    opacity: 1;
    transform: translateY(-50%) scale(1);
}

/* =====================================================
   CARTE LEAFLET - STYLES GLOBAUX
   ===================================================== */

.map-container {
    width: 100%;
    height: 300px;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);
    border: 1px solid var(--color-border);
}

.map-wrapper {
    position: relative;
}

.map-zoom-hint {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(44, 62, 80, 0.8);
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    pointer-events: none;
    z-index: 400;
    animation: pulseZoom 2s ease-in-out infinite;
}

/* =====================================================
   POPUPS LEAFLET - STYLES GLOBAUX
   ===================================================== */

/* Container principal de la popup */
.leaflet-popup-content-wrapper {
    border-radius: 12px !important;
    font-family: var(--font-secondary) !important;
    padding: 0 !important;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15) !important;
    overflow: hidden;
}

/* Zone de contenu - marges augmentées pour le bouton close */
.leaflet-popup-content {
    margin: 0 !important;
    padding: 0.7rem !important;
    font-size: 0.9rem;
}

/* Bouton close repositionné à l'intérieur */
.leaflet-popup-close-button {
    top: 10px !important;
    right: 10px !important;
    width: 28px !important;
    height: 28px !important;
    font-size: 20px !important;
    line-height: 28px !important;
    text-align: center !important;
    color: var(--color-text-light) !important;
    background: rgba(255, 255, 255, 0.9) !important;
    border-radius: 50% !important;
    transition: all 0.2s ease !important;
    z-index: 10 !important;
}

.leaflet-popup-close-button:hover {
    color: var(--color-secondary) !important;
    background: white !important;
    transform: scale(1.1);
}

/* Cacher le bouton close sur la popup de la carte (page photo uniquement) */
.map-wrapper .leaflet-popup-close-button {
    display: none !important;
}

/* Flèche de la popup */
.leaflet-popup-tip-container {
    margin-top: -1px;
}

.leaflet-popup-tip {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
}

/* =====================================================
   POPUP CARTE MONDIALE (INDEX.HTML)
   ===================================================== */

.world-popup {
    min-width: 220px;
    max-width: 280px;
    padding-top: 0.5rem;
    padding-right: 1.5rem; /* Espace pour le bouton close */
}

.world-popup__country {
    font-weight: 700;
    font-size: 1.15rem;
    color: var(--color-primary);
    margin-bottom: 0.875rem;
    padding-bottom: 0.75rem;
    border-bottom: 3px solid var(--color-secondary);
    line-height: 1.3;
}

.world-popup__list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.world-popup__item {
    border-bottom: 1px solid var(--color-border);
}

.world-popup__item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.world-popup__link {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    color: var(--color-primary);
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.2s ease;
    padding: 0.25rem 0;
}

.world-popup__link:hover {
    color: var(--color-secondary);
    transform: translateX(4px);
}

.world-popup__link i {
    font-size: 0.75em;
    color: var(--color-secondary);
    flex-shrink: 0;
}

/* =====================================================
   POPUP PAGE PHOTO - AJUSTEMENT TAILLE
   ===================================================== */

.popup-location {
    text-align: center;
    padding: 0.5rem 0.25rem;
    min-width: 120px;
    max-width: 200px;
}

.popup-location__country {
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--color-primary);
    margin-bottom: 0.25rem;
    line-height: 1.3;
}

.popup-location__city {
    font-weight: 400;
    font-size: 0.9rem;
    color: var(--color-text-light);
    line-height: 1.3;
}

/* =====================================================
   FOCUS THÉMATIQUE - IMAGE ALTERNATIVE
   ===================================================== */

.focus__image-container {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(15, 23, 42, 0.16);
    margin-bottom: 0.5rem;
}

.focus__image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 12px;
}

.focus__legend {
    font-size: clamp(0.85rem, 2.5vw, 0.95rem);
    font-style: italic;
    color: var(--color-text-light);
    text-align: center;
    padding: 0 1rem;
    margin: 0 0 1rem 0;
}

/* =====================================================
   FOCUS THÉMATIQUE - TEXTE PRINCIPAL
   ===================================================== */

.focus__text {
    margin-bottom: 1.5rem;
    line-height: 1.8;
    font-size: clamp(0.9rem, 2.5vw, 1rem);
}

/* =====================================================
   TITRE "POUR ALLER PLUS LOIN"
   ===================================================== */

.focus__further {
    margin-top: 2rem;
}

.focus__further-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-family: var(--font-primary);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 3px solid var(--color-secondary);
}

.focus__further-title i {
    color: var(--color-secondary);
    font-size: 1.1em;
}

/* =====================================================
   SOUS-SECTIONS (structure commune)
   ===================================================== */

.focus__subsection {
    margin-bottom: 1rem;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.04);
    border-radius: 8px;
    border-left: 4px solid var(--color-secondary);
}

.focus__subsection:last-child {
    margin-bottom: 0;
}

/* Titre unifié pour toutes les sous-sections */
.focus__subsection-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-family: var(--font-primary);
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-primary);
    margin-bottom: 1rem;
}

.focus__subsection-title i {
    color: var(--color-secondary);
    font-size: 1.1em;
    width: 20px;
    text-align: center;
}

/* =====================================================
   ITEMS HARMONISÉS (Questions, Ressources, PDF)
   ===================================================== */

.focus__items-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

/* Style unifié pour tous les items */
.focus__item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.875rem 1rem;
    margin-bottom: 0.5rem;
    background: white;
    border-radius: 6px;
    font-size: clamp(0.9rem, 2.5vw, 1rem);
    line-height: 1.6;
    color: var(--color-text);
    text-decoration: none;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    transition: all 0.2s ease;
    cursor: default;
}

.focus__items-list li:last-child .focus__item,
.focus__subsection > .focus__item {
    margin-bottom: 0;
}

/* Hover unifié pour tous les items */
.focus__item:hover {
    background: #fafafa;
    transform: translateX(4px);
}

/* Items cliquables (liens) */
a.focus__item {
    cursor: pointer;
}

/* Icône flèche à gauche */
.focus__item-icon {
    color: var(--color-secondary);
    font-size: 0.85em;
    flex-shrink: 0;
    margin-top: 0.25rem;
    transition: transform 0.2s ease;
}

.focus__item:hover .focus__item-icon {
    transform: translateX(2px);
}

/* Texte de l'item */
.focus__item-text {
    flex: 1;
}

/* Indicateur secondaire (lien externe / téléchargement) */
.focus__item-external {
    color: var(--color-text-light);
    font-size: 0.75em;
    flex-shrink: 0;
    margin-top: 0.25rem;
    opacity: 0.6;
    transition: opacity 0.2s ease;
}

.focus__item:hover .focus__item-external {
    opacity: 1;
}

/* Message si pas de ressources */
.focus__no-ressources {
    font-style: italic;
    color: var(--color-text-light);
    font-size: 0.9rem;
    padding: 0.5rem 0;
    margin: 0;
}

/* =====================================================
   NAVIGATION
   ===================================================== */

.navigation {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1rem;
    margin-top: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.navigation__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem 1.5rem;
    background: var(--color-primary);
    color: white;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);
    font-size: clamp(0.85rem, 2vw, 1rem);
}

.navigation__btn:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.12);
    background: var(--color-primary-hover);
}

.navigation__btn.disabled {
    background: #95A5A6;
    opacity: 0.5;
    cursor: not-allowed;
}

.navigation__btn.disabled:hover {
    background: #95A5A6;
    transform: none;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);
}

.navigation__btn span {
    display: none;
}

.navigation__btn i {
    font-size: 1.2em;
}

@media (min-width: 768px) {
    .navigation { grid-template-columns: auto auto auto; justify-content: space-between; max-width: 100%; }
    .navigation__btn { padding: 1rem 2rem; }
    .navigation__btn span { display: inline; }
    .navigation__btn--prev { justify-self: start; }
    .navigation__btn--home { justify-self: center; }
    .navigation__btn--next { justify-self: end; }
}

/* =====================================================
   MODAL
   ===================================================== */

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    animation: fadeIn 0.3s ease-out;
}

.modal.active {
    display: block;
}

.modal__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
}

.modal__content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 12px;
    padding: 1rem;
    max-width: 90%;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 8px 32px rgba(15, 23, 42, 0.16);
    animation: scaleIn 0.3s ease-out;
}

.modal__content--settings {
    max-width: 500px;
}

.modal__close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    font-size: 1.5rem;
    color: var(--color-text-light);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    z-index: 10;
}

.modal__close:hover {
    background: var(--color-border);
    color: var(--color-secondary);
    transform: rotate(90deg);
}

.modal__section {
    background: rgba(15, 23, 42, 0.04);
    padding: 1.5rem;
    border-radius: 8px;
    border: 2px solid var(--color-border);
    margin-bottom: 1.5rem;
}

.modal__section:last-child {
    margin-bottom: 0;
}

@media (min-width: 576px) {
    .modal__content {
        padding: 1.5rem 2rem;
        max-width: 92%;
        width: 500px;
    }
}

/* =====================================================
   MODAL PARAMÈTRES
   ===================================================== */

.settings {
    text-align: center;
    padding: 0.1rem 0.5rem;
}

.settings__icon {
    font-size: 2.7rem;
    color: var(--color-secondary);
    margin-bottom: 0.5rem;
    display: block;
}

.settings__title {
    font-family: var(--font-primary);
    font-size: 1.6rem;
    color: var(--color-primary);
    margin-bottom: 1rem;
}

.settings__section {
    background: rgba(15, 23, 42, 0.04);
    padding: 1.5rem;
    border-radius: 8px;
    border: 2px solid var(--color-border);
    margin-bottom: 1.5rem;
}

.settings__label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 600;
    color: var(--color-primary);
    margin-bottom: 1rem;
    font-size: 1.05rem;
}

.settings__label i {
    color: var(--color-secondary);
    font-size: 1.1em;
}

.settings__options {
    display: flex;
    gap: 0.75rem;
}

.settings__btn {
    flex: 1;
    padding: 0.75rem 1rem;
    background: white;
    border: 2px solid var(--color-border);
    border-radius: 8px;
    font-weight: 600;
    color: var(--color-text);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
}

.settings__btn:hover {
    border-color: var(--color-secondary);
    background: rgba(249, 115, 22, 0.05);
    transform: translateY(-2px);
}

.settings__btn.active {
    background: var(--color-secondary);
    border-color: var(--color-secondary);
    color: white;
}

.settings__checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    cursor: pointer;
    padding: 0 0.75rem 0.75rem;
    border-radius: 8px;
    text-align: left;
}

.settings__checkbox {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: var(--color-secondary);
    flex-shrink: 0;
    margin-top: 2px;
}

.settings__checkbox-text {
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--color-text);
    user-select: none;
}

.settings__warning {
    margin-top: 0.5rem;
    padding: 1rem;
    background: rgba(249, 115, 22, 0.1);
    border-left: 4px solid var(--color-secondary);
    border-radius: 4px;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    animation: slideInDown 0.3s ease-out;
}

.settings__warning i {
    color: var(--color-secondary);
    font-size: 1.2rem;
    margin-top: 0.1rem;
    flex-shrink: 0;
}

.settings__warning p {
    margin: 0;
    font-size: 0.9rem;
    color: var(--color-text);
    line-height: 1.5;
    text-align: left;
}

.settings__actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 2rem;
    padding-bottom: 0.5rem;
}

.settings__action-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.1);
}

.settings__action-btn--cancel {
    background: var(--color-primary);
    color: white;
}

.settings__action-btn--cancel:hover {
    background: var(--color-primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.3);
}

.settings__action-btn--confirm {
    background: var(--color-secondary);
    color: white;
}

.settings__action-btn--confirm:hover {
    background: var(--color-secondary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
}

@media (min-width: 576px) {
    .settings__icon {
        font-size: 3rem;
        margin-bottom: 1rem;
    }
    
    .settings__title {
        font-size: 1.8rem;
        margin-bottom: 2rem;
    }
}

/* =====================================================
   OBSERVATION (TIMER + RÉPONSE)
   ===================================================== */

.observation {
    text-align: center;
    padding-top: 0.1rem;
}

.observation__icon {
    font-size: 3rem;
    color: var(--color-secondary);
    margin-bottom: 0.9rem;
    display: block;
}

.observation__question {
    font-family: var(--font-primary);
    font-size: 1.2rem;
    color: var(--color-primary);
    margin-bottom: 0.3rem;
    line-height: 1.4;
}

.observation__timer-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 1.5rem;
}

.observation__timer-container.hidden {
    display: none;
}

.timer__circle {
    position: relative;
    width: 200px;
    height: 200px;
    margin: 0 auto;
}

.timer__svg {
    transform: rotate(-90deg);
    width: 100%;
    height: 100%;
}

.timer__bg {
    fill: none;
    stroke: var(--color-border);
    stroke-width: 8;
}

.timer__progress {
    fill: none;
    stroke: url(#gradient-timer);
    stroke-width: 8;
    stroke-linecap: round;
    stroke-dasharray: 339.292;
    stroke-dashoffset: 0;
    transition: stroke-dashoffset 1s linear;
}

.timer__number {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: var(--font-primary);
    font-size: 3rem;
    font-weight: 700;
    color: var(--color-primary);
}

.observation__answer {
    display: none;
}

.observation__answer.active {
    display: block;
    animation: fadeInUp 0.5s ease-out;
}

.observation__answer-icon {
    font-size: 3rem;
    color: var(--color-secondary);
    margin-bottom: 1.5rem;
    display: block;
}

.answer__text {
    line-height: 1.8;
    font-size: 1rem;
    text-align: left;
    padding: 0;
    margin: 0;
}

/* =====================================================
   MODAL QCM
   ===================================================== */

.qcm {
    text-align: center;
}

.qcm__instruction {
    font-size: 0.9rem;
    color: var(--color-text-light);
    text-align: center;
    margin-bottom: 1.5rem;
    font-style: italic;
}

.qcm__options {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.qcm__option {
    background: white;
    border: 2px solid var(--color-border);
    border-radius: 8px;
    padding: 0.75rem 1rem;
    text-align: left;
    font-size: 0.9rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    width: 100%;
}

.qcm__option:hover:not(.disabled):not(.selected) {
    background: white;
    transform: translateX(4px);
}

.qcm__option.disabled {
    pointer-events: none;
}

.qcm__option.selected {
    border-color: var(--color-secondary);
    background: rgba(249, 115, 22, 0.1);
    transform: translateX(4px);
}

.qcm__option.selected:hover:not(.disabled) {
    background: rgba(249, 115, 22, 0.1);
    border-color: var(--color-secondary);
    transform: translateX(4px);
}

.qcm__validate {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    margin-top: 1.5rem;
    background: var(--color-primary);
    color: white;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.2);
}

.qcm__validate:hover:not(:disabled) {
    background: var(--color-primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.3);
}

.qcm__validate:disabled {
    background: #94a3b8;
    cursor: not-allowed;
    opacity: 0.6;
}

.qcm__instruction.validated {
    display: none;
}

.qcm__options.validated {
    display: none;
}

.qcm__validate.validated {
    display: none;
}

.qcm__export-section {
    margin: 1.5rem 0;
    padding: 0 1.5rem;
}

.qcm__export-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: var(--color-primary);
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 0.75rem;
    cursor: pointer;
    position: relative;
}

.qcm__export-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0.5rem;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--color-primary);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.qcm__export-link:hover {
    color: var(--color-secondary);
}

.qcm__export-link:hover::after {
    width: 60%;
    background-color: var(--color-secondary);
}

.qcm__export-link i {
    font-size: 1.1em;
}

.qcm__progress-item {
    margin-bottom: 1.5rem;
}

.qcm__progress-item:last-child {
    margin-bottom: 0;
}

.qcm__progress-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--color-primary);
}

.qcm__progress-bar {
    width: 100%;
    height: 12px;
    background: var(--color-border);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.qcm__progress-fill {
    height: 100%;
    background: var(--color-secondary);
    border-radius: 10px;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 0 10px rgba(249, 115, 22, 0.3);
}

.qcm__continue {
    margin-top: 0.5rem;
    padding: 1rem 2rem;
    background: var(--color-primary);
    color: white;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.qcm__continue:hover {
    background: var(--color-primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.3);
}

/* =====================================================
   MODAL QCM - OPTION "AUTRE"
   ===================================================== */

.qcm__other {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0;
    cursor: pointer;
}

.qcm__other-checkbox {
    width: 18px;
    height: 18px;
    cursor: pointer;
    flex-shrink: 0;
    appearance: none;
    -webkit-appearance: none;
    border: 2px solid var(--color-border);
    border-radius: 3px;
    position: relative;
    transition: all 0.2s ease;
}

.qcm__other-checkbox:hover {
    border-color: var(--color-secondary);
}

.qcm__other-checkbox:checked {
    border-color: var(--color-secondary);
    background: white;
}

.qcm__other-checkbox:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--color-secondary);
    font-size: 14px;
    font-weight: bold;
}

.qcm__other-label {
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--color-text);
    user-select: none;
}

.qcm__other-textarea {
    width: 100%;
    min-height: 80px;
    padding: 0.75rem 1rem;
    background: white;
    border: 2px solid var(--color-secondary);
    border-radius: 8px;
    font-family: var(--font-secondary);
    font-size: 0.9rem;
    resize: vertical;
    transition: background 0.3s ease;
}

.qcm__other-textarea:focus {
    outline: none;
    background: rgba(249, 115, 22, 0.02);
}

.qcm__other-textarea::placeholder {
    color: #94a3b8;
    font-style: italic;
}

/* =====================================================
   MODAL DE COMPLÉTION
   ===================================================== */

.completion {
    text-align: center;
    padding: 2rem 1rem;
}

.completion__icon {
    font-size: 4rem;
    color: var(--color-primary);
    margin-bottom: 1.5rem;
    display: block;
    animation: bounceIn 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.completion__icon--trophy {
    color: var(--color-secondary);
}

.completion__icon--secondary {
    color: var(--color-secondary) !important;
}

.completion__title {
    font-family: var(--font-primary);
    font-size: 1.8rem;
    color: var(--color-primary);
    margin-bottom: 1rem;
}

.completion__message {
    font-size: 1.05rem;
    line-height: 1.6;
    color: var(--color-text);
    margin-bottom: 2rem;
}

.completion__progress {
    margin: 0;
}

.progress__text {
    display: block;
    font-weight: 600;
    color: var(--color-primary);
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
}

.progress__bar {
    width: 100%;
    height: 12px;
    background: var(--color-border);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.progress__fill {
    height: 100%;
    background: var(--color-secondary);
    border-radius: 10px;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 0 10px rgba(249, 115, 22, 0.3);
}

.completion__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    margin: 0.5rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.1);
}

.completion__btn--focus {
    background: var(--color-primary);
    color: white;
}

.completion__btn--focus:hover {
    background: var(--color-primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.3);
}

.completion__btn--next {
    background: var(--color-secondary);
    color: white;
}

.completion__btn--next:hover {
    background: var(--color-secondary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
}

.completion__btn--home {
    background: var(--color-primary);
    color: white;
}

.completion__btn--home:hover {
    background: var(--color-primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.3);
}

.completion__btn--reset {
    background: var(--color-secondary);
    color: white;
}

.completion__btn--reset:hover {
    background: var(--color-secondary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
}

.completion--final {
    padding: 3rem 1.5rem;
}

.completion__stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin: 0;
}

.stat {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat__number {
    font-size: 3rem;
    font-weight: 700;
    font-family: var(--font-primary);
    color: var(--color-secondary);
    line-height: 1;
}

.stat__label {
    font-size: 0.9rem;
    color: var(--color-text-light);
    margin-top: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.completion__quote {
    font-style: italic;
    color: var(--color-text-light);
    margin: 0;
    line-height: 1.6;
}

.completion__quote em {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.9rem;
}

.completion__actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 2rem;
}

@media (min-width: 576px) {
    .completion__actions {
        flex-direction: row;
        justify-content: center;
    }
}

/* =====================================================
   ANIMATIONS
   ===================================================== */

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-30px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes slideInDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

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

@keyframes bounceIn {
    0% { opacity: 0; transform: scale(0.3); }
    50% { opacity: 1; transform: scale(1.05); }
    70% { transform: scale(0.9); }
    100% { transform: scale(1); }
}

@keyframes pulseZoom {
    0%, 100% { transform: scale(1); opacity: 0.8; }
    50% { transform: scale(1.1); opacity: 1; }
}