/* ========== 1. Base & Reset ========== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Poppins", sans-serif;
    font-optical-sizing: auto;
    font-style: normal;
    font-weight:300;
    text-rendering: optimizeLegibility;
    color:#10327F;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    width:100%;
}

body {
    font-family: 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #1b1c32;
    background-color: #fff;
    overflow-x:hidden;
}

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

a {
    color: #002c7b;
    text-decoration: none;
}

ul {
    list-style: none;
}

h1, h2, h3 {
    margin-bottom: 1rem;
}

#bandeau-entrainement {
    left:0;
    width:100%;
    font-size:1rem;
    font-weight:300;
    background:#FCE202;
    padding:0.25rem;
    text-align: center;
}

.logo-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding:1rem 2rem;
}

.social {
    position:absolute;
    right:2rem;
    top:10rem;
}

.social li {
    width:45px;
    height:45px;
    background:#F2F4F8;
    border-radius:50%;
    display:flex;
    margin-bottom:1rem;
    align-items: center;
    justify-content: center;
    transition:all 0.3s ease;
}

.social li:hover {
    background:#FCE202;
    transition:all 0.3s ease;
}

.social li img {
    width:20px;
    max-height:20px;
}

    /* ========== 2. Layout ========== */

section {
    max-width: 1500px;
    margin: 0 auto;
}

.padding {
    padding:10rem 0;
}

header {
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all 0.3s;
}

header.scrolled {
    top:-2px;
    transition: all 0.3s;
}

.logo img {
    max-height: 90px;
}

nav ul {
    display: flex;
    gap: 1.5rem;
}

nav a {
    font-weight: 500;
    padding: 0.5rem 0;
    transition: color 0.3s;
}

nav a:hover {
    color: #f7b801;
}

.btn {
    border:1px solid #10327F;
    padding: 0.5rem 5rem 0.5rem 1rem;
    border-radius: 25px;
    font-size:1rem;
    position:relative;
}
.btn::after {
    display:block;
    position:absolute;
    content:'';
    top:0;
    background:#FCE202;
    width:10px;
    height:10px;
    border-radius:50%;
}

.min-container {
    max-width: 900px;
    margin:0 auto;
    position:relative;
}

/* ========== 3. Hero (Accueil) ========== */

#accueil {
    text-align: left;
}

#accueil h1 {
    font-size:1.25rem;
    font-weight:300;
    margin-bottom: 1rem;
    background:#F2F4F8;
    display:inline-block;
    padding:1rem;
    border-radius:25px;
}

.before {
    position:relative;
}
.before::after {
    display:block;
    position:absolute;
    bottom:-15px;
    right:20px;
    content:'';
    width:100px;
    height:80px;
    background:url('uploads/trait.svg');
}

#accueil p.sous-titre {
    font-style: italic;
    color: #555;
    margin-bottom: 2rem;
}

#accueil p {
    font-size: 2.5rem;
    font-weight:300;
    @media only screen and (max-width : 767px) {
        font-size:2rem;
    }
}

.image-mask {
    mask-image: url('uploads/form1.svg');
    mask-size: cover;
    mask-repeat: no-repeat;
    -webkit-mask-image: url('uploads/form1.svg');
    -webkit-mask-size: contain;
    -webkit-mask-repeat: no-repeat;
}

.mask-2 {
    mask-image: url('uploads/form2.svg');
    -webkit-mask-image: url('uploads/form2.svg');
}

.image-mask img {
    width:100%;
    height:100%;
}

.galerie-accueil {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.box-inscription {
    background: #002c7b;
    color: white;
    padding: 2rem;
    border-radius: 10px;
    position: relative;
}

.box-inscription::before {
    display:block;
    position:absolute;
    z-index:2;
    background:#FCE202;
    border-radius:50%;
    top:-10px;
    right:30px;
    content:'';
    width:20px;
    height:20px;
}

.box-inscription::after {
    display:block;
    position:absolute;
    background:white;
    z-index:1;
    border-radius:50%;
    top:-15px;
    right:25px;
    content:'';
    width:30px;
    height:30px;
}

.box-inscription * {
    color:white;
    font-weight:300;
}

.box-inscription p {
    font-size:1rem!important;
}

.box-inscription h2 {
    font-size:2rem;
    line-height:1.25;
}

.box-inscription h2::before {
    display:inline-block;
    position:relative;
    margin-right:0.5rem;
    content:'';
    width:32px;
    height:32px;
    background:url('uploads/cross.svg');
}

.btn {
    display: inline-block;
    border:1px solid #002c7b;
    color: #002c7b;
    padding: 0.6rem 1.2rem;
    margin-top: 1rem;
    border-radius: 30px;
}
.btn::after {
    display:inline-block;
    position:relative;
    margin-left:3.5rem;
    content:'';
    width:30px;
    height:19px;
    background:url('uploads/arrow-blue.svg');
    background-repeat: no-repeat;
}
.btn:hover {
    background:#10327F;
    color:white;
}

.btn-inscription {
    display: inline-block;
    border:1px solid white;
    color: white;
    padding: 0.6rem 1.2rem;
    margin-top: 1rem;
    border-radius: 30px;
}

.btn-inscription::after {
    display:inline-block;
    position:relative;
    margin-left:3.5rem;
    content:'';
    width:30px;
    height:19px;
    background:url('uploads/arrow-white.svg');
    background-repeat: no-repeat;
}

.btn-inscription:hover {
    background:white;
    color:#10327F;
}

.btn-inscription:hover::after {
    background:url('uploads/arrow-blue.svg');
}

/* ========== 4. Activités ========== */

#activites h2,.galerie-details strong {
    font-size:2rem;
    font-weight:300;
    position:relative;
}

#activites .stats {
    text-align: center;
    margin-bottom: 2rem;
}

#activites .stats ul {
    margin: 1rem 0;
}

#activites .stats ul li {
    font-size:1.5rem;
    font-weight:300;
}

#activites .galerie-activites {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
    margin-top: 2rem;
}

.galerie-details {
    position:relative;
    top:15rem;
}

.galerie-details strong::before {
    display:inline-block;
    position:absolute;
    top:-2rem;
    left:-2rem;
    content:'';
    width:127px;
    height:97px;
    background:url('uploads/rounded.svg');
    background-repeat: no-repeat;
    transform:rotate(34deg);
}

#activites figure {
    position:relative;
}

#activites figcaption {
    position:absolute;
    bottom:0;
    left:0;
    border-top-right-radius: 30px;
    background:white;
    padding:0.5rem 2rem;
}

.btn-resultats {
    display: inline-block;
    background: #002c7b;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 500;
    margin-top: 1rem;
}

.btn-blue {
    display: inline-block;
    background: #002c7b;
    color: white;
    margin-top: 1rem;
}
.btn-blue::after {
    background:url('uploads/arrow-white.svg');
}

.nav {
    text-align:right;
}

.underline {text-decoration:underline;}

/* ========== 5. Salles ========== */

.salles {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.btn-itineraire {
    display: inline-block;
    margin-top: 0.5rem;
    background: #f7b801;
    padding: 0.4rem 1rem;
    border-radius: 30px;
    color: white;
    font-weight: 500;
}

/* ========== 6. Soutiens ========== */

.sponsors {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
    margin: 2rem 0;
}

.btn-sponsor {
    display: inline-block;
    background: #002c7b;
    color: white;
    padding: 0.6rem 1.2rem;
    border-radius: 30px;
}

/* ========== defilement ========== */
#words {
    position:relative;
    height:60vh;
    display:flex;
    align-items: center;
    justify-content: center;
}

#words figure {
    max-width:33%;
    position:absolute;
    z-index:2;
    top:calc(50% - 200px);
    left:calc(50% - 200px);
    transform:rotate(10deg);
}

.container-fill {
    display: flex;
    position:relative;
    width: 100%;
}

.top {
    top:-3rem;
}

.bottom {
    bottom:-3rem;
}

.txt {
    white-space: nowrap;
    font-size: 4rem;
    animation: scrollTxt 30s linear infinite;
    font-weight:300;
}

.rev {
    white-space: nowrap;
    font-size: 4rem;
    animation: scrollTxtReverse 30s linear infinite;
    font-weight:300;
}

@keyframes scrollTxt {
    0% {
        transform: translate(0, 0);
    }
    100% {
        transform: translate(-100%, 0);
    }
}

@keyframes scrollTxtReverse {
    0% {
        transform: translate(-100%, 0);
    }
    100% {
        transform: translate(0, 0);
    }
}


/* ========== Lieux ========== */

#lieux {
    display:flex;

}

#lieux h2 {
    font-size:2rem;
    font-weight:300;
}

#lieux h3 {
    font-size:1rem;
    font-weight:300;
}

#lieux p {
    font-size:1.5rem;
    font-weight:300;
}

#lieux .flex-3 {
    width:calc(100% / 3);
}

#lieux figure {
    border-radius:1.5rem;
    overflow:hidden;
    position:relative;
    left:2rem;
}

.sponsoring {
    display:flex;
    justify-content: space-between;
}

#css-infinite-carousel {padding:5rem 0;overflow-x:visible;--speed: 60s; --gap: 2em; --play-state: running; --dir: normal; --radius: 1rem; --pad: 0px; margin-top: 35px; display: flex; gap: var(--gap);}
#css-infinite-carousel .ticker {display: flex; align-items: center; justify-content: space-around; flex-shrink: 0; gap: var(--gap); min-width: 100%; animation: slide var(--speed) linear infinite; animation-play-state: var(--play-state); animation-direction: var(--dir);}
#css-infinite-carousel .ticker img {width: auto;max-height:100px;max-width:140px; flex-shrink: 0; border-radius: var(--radius); padding: var(--pad); transition: all 0.3s linear;}
@keyframes slide {0% {transform: translateX(0);} 100% {transform: translateX(calc(-100% - 1em));}}


/* ========== 7. Footer ========== */

footer {
    background: #f9f9f9;
    padding: 2rem;
    text-align: center;
    font-size: 0.9rem;
    color: #555;
    margin-top: 3rem;
    border-top-left-radius: 2rem;
    border-top-right-radius: 2rem;
}

.contact-infos {
   display:flex;
    align-items:center;
    justify-content: center;
}

.contact-infos-content {
    display:flex;
    width:33%;
}

.contact-infos-details {
    text-align: left;
    margin-left:1rem;
}

.contact-infos-details p {
    font-size:0.9rem;
}

.contact-infos-content picture img {
    height:70px;
    max-width: 90px;
}

.scroll-container {
    position: relative;
}

.volant {
    position: absolute;
    bottom: -15rem;
    right: -15rem;
    width: 30rem;
    transform-origin: center;
}

/* Fond overlay */
#popup-creneaux {
    display: none; /* caché par défaut */
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    overflow: auto;
}

/* Contenu de la popup */
.popup-content {
    background-color: #fff;
    margin: 10% auto;
    padding: 20px;
    width: 90%;
    max-width: 500px;
    border-radius: 8px;
    position: relative;
}

.schedule {
    display: grid;
    gap: 16px;
    font-family: system-ui, sans-serif;
}
.card {
    background: #f8f9ff;
    border: 1px solid #e0e2f0;
    border-radius: 14px;
    padding: 14px 16px;
    box-shadow: 0 2px 6px rgba(0,0,0,.05);
    transition: transform .2s;
}
.card:hover { transform: translateY(-2px); }
.card h3 {
    margin: 0 0 6px;
    font-size: 17px;
    color: #1d1e3a;
}
.meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 8px;
    font-size: 14px;
    color: #555;
}
.meta span {
    background: #eef0ff;
    border-radius: 10px;
    padding: 2px 8px;
}
.price {
    font-weight: bold;
    font-size: 15px;
    color: #fff;
    background: linear-gradient(90deg,#002c7b,#ffffff);
    padding: 4px 10px;
    border-radius: 8px;
}
.note {
    font-size: 13px;
    color: #777;
    margin-top: 6px;
}


/* morphing */

@media only screen and (max-width : 767px) {
    #bandeau-entrainement {
        padding:0.5rem;
    }
    .social {
        position:relative;
        top:auto;
        right:auto;
        display:flex;
        gap:1rem;
    }
    #accueil h1 {
        margin-top:2rem;
    }
   section {
       margin: 0 2rem;
   }
    #lieux {
        flex-direction:column;
    }
    #lieux figure {
        left: 0;
    }
    .padding {
        padding:0;
    }
    #lieux .flex-3 {
        width:100%;
    }
    #activites .galerie-activites {
        grid-template-columns: repeat(1, 1fr);
    }
    #activites h2,.galerie-details strong {
        font-size:1.5rem;
    }
    .galerie-details {
        top:auto;
    }
    #activites .stats {
        text-align: left;
    }
    #words figure {
        top:auto;
        left:auto;
        max-width:75%;
    }
    .btn::after {
        margin-left:1rem;
    }
    .rev,.txt {
        font-size:3rem;
    }
    #css-infinite-carousel {
        margin-top:auto;
    }
    .sponsoring {
        flex-direction: column;
        align-items: flex-start;
    }
    #soutiens {
        margin-top:5rem;
    }
    .contact-infos {
        flex-direction: column;
        gap:2rem;
    }
    .contact-infos-content {
        width:100%;
        justify-content: center;
        align-items: center;
        flex-direction: column;
    }
    .contact-infos-details {
        text-align:center;
        margin-left:0;
    }
    #css-infinite-carousel {
    --speed: 20s;
    }
}