/* =========================================================
   CONVENTION JDR
   FEUILLE DE STYLE PRINCIPALE
   ========================================================= */


/* =========================================================
   RESET / BASE
   ========================================================= */

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family:
        Inter,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
    color: #202124;
    background: #ffffff;
    line-height: 1.55;
}

img {
    max-width: 100%;
}

button,
input,
textarea {
    font: inherit;
}

button {
    cursor: pointer;
}

a {
    color: inherit;
}

.container {
    width: min(1100px, 92%);
    margin: 0 auto;
}


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

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.96);
    border-bottom: 1px solid #e8e8e8;
    backdrop-filter: blur(10px);
}

.site-header__inner {
    min-height: 68px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.site-brand {
    flex-shrink: 0;
    color: #171717;
    text-decoration: none;
    font-weight: 800;
    font-size: 1.15rem;
}

.site-brand__name {
    display: block;
}

.site-nav {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 8px;
}

.site-nav a,
.nav-button {
    border: 0;
    background: transparent;
    color: #444;
    text-decoration: none;
    padding: 8px 10px;
    border-radius: 8px;
    font-size: 0.92rem;
    transition:
        background 0.2s ease,
        color 0.2s ease;
}

.site-nav a:hover,
.nav-button:hover {
    background: #f1f1f1;
    color: #000;
}

.nav-button {
    font-weight: 600;
}


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

.hero {
    padding: 50px 0;
    background:
        linear-gradient(
            135deg,
            #f3f0ff 0%,
            #ffffff 52%,
            #fff7ed 100%
        );
}

.hero__inner {
    display: grid;
    grid-template-columns:
        minmax(220px, 0.8fr)
        minmax(0, 1.2fr);

    align-items: center;

    min-height: 230px;

    gap: 50px;
}

.hero__logo-container {
    display: flex;
    align-items: center;
    justify-content: center;

    height: 230px;
}

.hero__logo {
    display: block;

    width: min(100%, 230px);
    height: 230px;

    object-fit: contain;
}

.hero__content {
    max-width: 680px;
}

.hero__title {
    margin: 8px 0 14px;

    color: #171717;

    font-size: clamp(
        2.5rem,
        6vw,
        4.5rem
    );

    line-height: 1.02;
}

.hero__subtitle {
    margin: 0 0 24px;

    color: #555;

    font-size: clamp(
        1.05rem,
        2vw,
        1.25rem
    );
}



/* =========================================================
   BOUTONS
   ========================================================= */

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    border: 0;
    border-radius: 10px;
    padding: 11px 17px;
    background: #242424;
    color: #ffffff;
    text-decoration: none;
    font-weight: 700;
    line-height: 1.2;
    transition:
        background 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.button:hover {
    background: #000000;
    transform: translateY(-1px);
    box-shadow: 0 5px 14px rgba(0, 0, 0, 0.15);
}

.button:focus-visible,
.table-filter:focus-visible,
.nav-button:focus-visible,
.modal__close:focus-visible {
    outline: 3px solid #8b7cf6;
    outline-offset: 2px;
}

.button--small {
    min-height: 38px;
    padding: 8px 13px;
    font-size: 0.85rem;
}


/* =========================================================
   SECTIONS
   ========================================================= */

.section {
    padding: 80px 0;
}

.section--alternate {
    background: #f7f7f8;
}

.section--contact {
    background: #f3f0ff;
}

.section__header {
    max-width: 760px;
    margin-bottom: 34px;
}

.section__title {
    margin: 0;
    color: #171717;
    font-size: clamp(2rem, 4vw, 2.8rem);
    line-height: 1.15;
}

.section__intro {
    margin: 12px 0 0;
    color: #666;
    font-size: 1.05rem;
}


/* =========================================================
   CONVENTION
   ========================================================= */

.convention-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.8fr);
    gap: 40px;
    align-items: start;
}

.convention-content {
    max-width: 720px;
}

.convention-content p {
    margin: 0 0 18px;
    color: #444;
}

.programme {
    padding: 26px;
    border: 1px solid #e2e2e2;
    border-radius: 16px;
    background: #ffffff;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.04);
}

.programme__title {
    margin: 0 0 22px;
    font-size: 1.6rem;
}

.programme__item {
    display: grid;
    gap: 3px;
    padding: 14px 0;
    border-top: 1px solid #eeeeee;
}

.programme__item:first-of-type {
    border-top: 0;
}

.programme__item span {
    color: #666;
    font-size: 0.92rem;
}

/* =========================================================
   LOCALISATION / ACCÈS
   ========================================================= */

.localisation-section {
    background: #f7f7f8;
}

.localisation-content {
    max-width: 820px;
}

.localisation-content > p {
    margin-top: 0;
    margin-bottom: 26px;
    color: #444;
}

.localisation-item {
    margin-bottom: 22px;
    padding: 18px 20px;

    border: 1px solid #e3e3e3;
    border-radius: 12px;

    background: #ffffff;
}

.localisation-item h3 {
    margin: 0 0 8px;

    color: #222;
    font-size: 1.05rem;
}

.localisation-item p {
    margin: 0;

    color: #555;
    line-height: 1.6;
}

.localisation-gps {
    font-size: 1.05rem;
}

.localisation-notice {
    margin-top: 26px;
    padding: 16px 20px;

    border-left: 4px solid #555;
    border-radius: 8px;

    background: #ffffff;
}

.localisation-notice p {
    margin: 0;
    color: #555;
}

/* =========================================================
   FILTRES DES TABLES
   ========================================================= */

.table-filters {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0 0 30px;
}

.table-filter {
    appearance: none;
    border: 1px solid #d4d4d4;
    border-radius: 999px;
    padding: 9px 15px;
    background: #ffffff;
    color: #444;
    font-size: 0.9rem;
    font-weight: 700;
    line-height: 1.2;
    transition:
        background 0.2s ease,
        color 0.2s ease,
        border-color 0.2s ease,
        transform 0.2s ease;
}

.table-filter:hover {
    border-color: #999;
    background: #fafafa;
    transform: translateY(-1px);
}

.table-filter.is-active {
    border-color: #242424;
    background: #242424;
    color: #ffffff;
}


/* =========================================================
   DISPONIBILITE DES TABLES PAR SESSION
   ========================================================= */

.table-date-filter {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    width: 100%;
    margin-bottom: 4px;
}

.session-table-availability {
    font-size: 0.85rem;
    font-weight: 700;
}

.session-table-availability--open {
    color: #176b3a;
}

.session-table-availability--full {
    color: #9c2f2f;
}


@media (max-width: 760px) {

    .table-date-filter {
        align-items: stretch;
        flex-direction: column;
    }

}

/* =========================================================
   LISTE HORIZONTALE DES TABLES
   ========================================================= */

.tables-scroll {
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 4px 4px 18px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}

#tables-container {
    display: flex;
    flex-wrap: nowrap;
    align-items: stretch;
    gap: 18px;
    width: max-content;
    min-width: 100%;
}

/* =========================================================
   CARTE TABLE — STYLE COMPACT
   ========================================================= */

.table-card {
    flex: 0 0 270px;
    width: 270px;
    max-width: 270px;

    display: flex;
    flex-direction: column;

    padding: 20px;

    border: 1px solid #e5e5e5;
    border-radius: 16px;

    background: #ffffff;

    box-shadow:
        0 4px 18px rgba(0, 0, 0, 0.05);

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        border-color 0.2s ease;
}

.table-card:hover {
    border-color: #d5d5d5;

    box-shadow:
        0 8px 22px rgba(0, 0, 0, 0.08);

    transform: translateY(-2px);
}


/* =========================================================
   IMAGE / ZONE JDR
   ========================================================= */

.table-card__image {
    display: block;
    width: 100%;
    height: 110px;
    object-fit: cover;
    background: #eeeeee;
}

.table-card__image--empty {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 110px;
    padding: 15px;
    background:
        linear-gradient(
            135deg,
            #eeeeee,
            #f7f7f7
        );
    color: #555;
    font-size: 1.05rem;
    font-weight: 800;
    text-align: center;
}

/* =========================================================
   PASTILLE DU JEU
   ========================================================= */

.table-card .pill {
    align-self: flex-start;

    margin-bottom: 12px;

    background: #eeeeee;
    color: #444;

    font-size: 0.75rem;
}


/* =========================================================
   TITRE
   ========================================================= */

.table-card__title {
    margin: 0 0 14px;

    color: #202124;

    font-size: 1.15rem;
    line-height: 1.25;
}


/* =========================================================
   INFORMATIONS
   ========================================================= */

.table-card .meta {
    display: grid;
    gap: 5px;

    margin-bottom: 16px;

    color: #555;

    font-size: 0.86rem;
}


/* =========================================================
   PLACES
   ========================================================= */

.places {
    margin-top: auto;
    margin-bottom: 14px;

    font-weight: 800;
    font-size: 0.9rem;
}

.places.available {
    color: #176b3a;
}

.places.full {
    color: #a11;
}

.places.gm-missing {
    color: #8a5700;
}


/* =========================================================
   ACTION
   ========================================================= */

.table-card__action {
    margin-top: 0;
}

.table-card__action .button {
    width: 100%;
}

.table-card__notice {
    display: block;

    padding: 10px;

    border-radius: 9px;

    background: #f5f5f5;

    color: #666;

    font-size: 0.82rem;
    font-weight: 700;
    text-align: center;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 760px) {

    .table-card__description {
        height: 60px;
        max-height: 60px;
        font-size: 0.84rem;
    }

}

/* fin de recopie */


/* =========================================================
   CORPS DE LA CARTE
   ========================================================= */

.table-card__body {
    padding: 20px;
}


/* =========================================================
   STATUT
   ========================================================= */

.table-card__status {
    display: inline-flex;
    align-items: center;
    min-height: 27px;
    margin-bottom: 12px;
    padding: 5px 10px;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 800;
    line-height: 1;
}

.table-card__status--open {
    background: #e5f5eb;
    color: #176b3a;
}

.table-card__status--full {
    background: #f5e5e5;
    color: #9c2f2f;
}

.table-card__status--no-gm {
    background: #fff0d9;
    color: #8a5700;
}


/* =========================================================
   JEU
   ========================================================= */

.table-card__game {
    margin: 0 0 5px;
    color: #666;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}


/* =========================================================
   TITRE
   ========================================================= */

.table-card__title {
    margin: 0 0 15px;
    color: #171717;
    font-size: 1.35rem;
    line-height: 1.2;
}


/* =========================================================
   INFORMATIONS
   ========================================================= */

.table-card__info {
    display: grid;
    gap: 6px;
    margin-bottom: 16px;
    color: #555;
    font-size: 0.9rem;
}

.table-card__info span {
    display: block;
}


/* =========================================================
   NOMBRE DE JOUEURS
   ========================================================= */

.table-card__players {
    margin-bottom: 9px;
    color: #242424;
    font-weight: 800;
}


/* =========================================================
   NIVEAU
   ========================================================= */

.table-card__level {
    display: inline-block;
    margin-bottom: 13px;
    padding: 4px 9px;
    border-radius: 7px;
    background: #f0f0f0;
    color: #555;
    font-size: 0.8rem;
    font-weight: 700;
}


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

.table-card__description {
    max-height: 96px;
    overflow: hidden;
    color: #555;
    font-size: 0.92rem;
    transition: max-height 0.3s ease;
}

.table-card__description p {
    margin: 0 0 10px;
}

.table-card__description p:last-child {
    margin-bottom: 0;
}

/*
   Lorsqu'une carte est ouverte par le JS,
   la description complète devient visible.
*/

.table-card.is-expanded .table-card__description {
    max-height: 1000px;
}


/* =========================================================
   ACTION
   ========================================================= */

.table-card__action {
    display: flex;
    align-items: center;
    min-height: 42px;
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid #eeeeee;
}

.table-card__notice {
    color: #666;
    font-size: 0.88rem;
    font-weight: 700;
}


/* =========================================================
   CHARGEMENT / MESSAGES
   ========================================================= */

#tables-container .loading,
#tables-container .message {
    grid-column: 1 / -1;
    width: 100%;
    padding: 40px 24px;
    border: 1px solid #e3e3e3;
    border-radius: 16px;
    background: #ffffff;
    color: #666;
    text-align: center;
}

#tables-container .message--error {
    border-color: #e0b5b5;
    background: #fff5f5;
    color: #9c2f2f;
}


/* =========================================================
   FAQ
   ========================================================= */

.faq-list {
    max-width: 820px;
}

.faq-item {
    border-top: 1px solid #dddddd;
}

.faq-item:last-child {
    border-bottom: 1px solid #dddddd;
}

.faq-item summary {
    position: relative;
    padding: 20px 35px 20px 0;
    color: #222;
    font-weight: 700;
    cursor: pointer;
    list-style: none;
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item summary::after {
    content: "+";
    position: absolute;
    top: 17px;
    right: 0;
    color: #666;
    font-size: 1.5rem;
    font-weight: 400;
}

.faq-item[open] summary::after {
    content: "−";
}

.faq-item p {
    margin: 0;
    padding: 0 0 20px;
    color: #666;
}


/* =========================================================
   CONTACT
   ========================================================= */

.contact-section {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
}

.contact-section .section__title {
    margin-bottom: 10px;
}

.contact-section p:last-child {
    margin-bottom: 0;
    color: #555;
}


/* =========================================================
   MODALE
   ========================================================= */

.modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(0, 0, 0, 0.55);
}

.modal.is-open {
    display: flex;
}

.modal__content {
    width: min(520px, 100%);
    max-height: 90vh;
    overflow-y: auto;
    padding: 26px;
    border-radius: 16px;
    background: #ffffff;
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.25);
}

.modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    margin-bottom: 20px;
}

.modal__header h2 {
    margin: 0;
}

.modal__close {
    width: 38px;
    height: 38px;
    border: 0;
    border-radius: 50%;
    background: #f2f2f2;
    color: #333;
    font-size: 1.5rem;
    line-height: 1;
}

.modal__close:hover {
    background: #e5e5e5;
}


/* =========================================================
   FORMULAIRE CONTACT
   ========================================================= */

.contact-form {
    display: grid;
    gap: 9px;
}

.contact-form label {
    margin-top: 8px;
    font-weight: 700;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    border: 1px solid #cccccc;
    border-radius: 9px;
    padding: 11px;
    background: #ffffff;
    color: #222;
}

.contact-form textarea {
    resize: vertical;
    min-height: 130px;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: #888;
    outline: 3px solid rgba(139, 124, 246, 0.15);
}


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

.site-footer {
    padding: 40px 0;
    background: #202124;
    color: #dddddd;
}

.site-footer__inner {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 40px;
}

.site-footer p {
    max-width: 500px;
    margin: 8px 0 0;
    color: #aaa;
}

.site-footer__links {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

.site-footer__links a {
    color: #ddd;
    text-decoration: none;
}

.site-footer__links a:hover {
    color: #ffffff;
    text-decoration: underline;
}


/* =========================================================
   RESPONSIVE — TABLETTE
   ========================================================= */
@media (max-width: 900px) {

    .hero__inner {
        grid-template-columns: 1fr;
        min-height: 0;
        gap: 25px;
        text-align: center;
    }

    .hero__logo-container {
        height: 180px;
    }

    .hero__logo {
        width: 180px;
        height: 180px;
    }

    .hero__content {
        margin: 0 auto;
    }

    .hero__title {
        font-size: clamp(
            2.3rem,
            12vw,
            3.5rem
        );
    }

}

/* =========================================================
   RESPONSIVE — MOBILE
   ========================================================= */

@media (max-width: 760px) {

    .container {
        width: min(100% - 32px, 1100px);
    }

    .site-header__inner {
        align-items: flex-start;
        flex-direction: column;
        padding: 12px 0;
    }

    .site-nav {
        width: 100%;
        justify-content: flex-start;
        gap: 4px;
    }

    .site-nav a,
    .nav-button {
        padding: 7px 8px;
        font-size: 0.84rem;
    }

    .hero {
        padding: 60px 0;
    }

    .hero__title {
        font-size: clamp(2.3rem, 12vw, 3.5rem);
    }

    .hero__subtitle {
        font-size: 1.05rem;
    }

    .section {
        padding: 55px 0;
    }

    .section__header {
        margin-bottom: 26px;
    }

    .table-filters {
        gap: 8px;
    }

    .table-filter {
        padding: 8px 12px;
        font-size: 0.82rem;
    }

    #tables-container {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .table-card__image {
        height: 165px;
    }

    .table-card__body {
        padding: 17px;
    }

    .table-card__title {
        font-size: 1.25rem;
    }

    .contact-section {
        align-items: flex-start;
        flex-direction: column;
    }

    .site-footer__inner {
        flex-direction: column;
        gap: 25px;
    }

    .site-footer__links {
        gap: 12px;
    }

}


/* =========================================================
   PETITS ECRANS
   ========================================================= */

@media (max-width: 420px) {

    .site-nav {
        gap: 2px;
    }

    .site-nav a,
    .nav-button {
        padding: 6px;
        font-size: 0.78rem;
    }

    .hero {
        padding: 45px 0;
    }

    .table-filter {
        width: 100%;
        text-align: center;
    }

    .table-card__image {
        height: 145px;
    }

}
/* =========================================================
   INFORMATIONS AU SURVOL
   ========================================================= */

.table-card {
    position: relative;
}


/*
   Zone cachée par défaut.
*/

.table-card__hover-content {
    max-height: 0;
    overflow: hidden;
    opacity: 0;

    transition:
        max-height 0.25s ease,
        opacity 0.2s ease,
        margin-top 0.25s ease;
}


/*
   Affichage au survol.
*/

/* =========================================================
   ZONE D'OUVERTURE DE LA CARTE
   ========================================================= */

.table-card__expand-zone {
    cursor: pointer;
}


/* =========================================================
   INFORMATIONS AU SURVOL
   ========================================================= */

.table-card__hover-content {
    max-height: 0;
    overflow: hidden;
    opacity: 0;

    transition:
        max-height 0.25s ease,
        opacity 0.2s ease,
        margin-top 0.25s ease;
}


/*
   Seule la zone titre → informations
   déclenche l'affichage.
*/

.table-card__expand-zone:hover
.table-card__hover-content,

.table-card.is-expanded
.table-card__hover-content {
    max-height: 500px;
    margin-top: 14px;
    opacity: 1;
}


/* =========================================================
   PLACES ET BOUTON
   ========================================================= */

.places,
.table-card__action {
    position: relative;
    z-index: 2;
}


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

.table-card__description {
    padding-top: 14px;
    border-top: 1px solid #eeeeee;

    color: #555;
    font-size: 0.86rem;
    line-height: 1.5;
}

.table-card__description p {
    margin: 0 0 8px;
}

.table-card__description p:last-child {
    margin-bottom: 0;
}

.table-card__description-empty {
    color: #888;
    font-style: italic;
}


/* =========================================================
   LISTE DES INSCRITS
   ========================================================= */

.table-card__participants {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid #eeeeee;
}

.table-card__participants-title {
    margin-bottom: 6px;

    color: #333;

    font-size: 0.78rem;
    font-weight: 800;

    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.table-card__participants-list {
    display: grid;
    gap: 3px;

    margin: 0;
    padding: 0;

    list-style: none;

    color: #555;
    font-size: 0.82rem;
}

.table-card__participants-list li::before {
    content: "•";
    margin-right: 6px;
    color: #999;
}

.table-card__participants-empty {
    color: #999;
    font-size: 0.82rem;
    font-style: italic;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 760px) {

    /*
       Sur mobile, le clic ouvre la carte.
       On ne dépend donc pas uniquement du hover.
    */

    .table-card__hover-content {
        transition:
            max-height 0.25s ease,
            opacity 0.2s ease;
    }

    .table-card:hover .table-card__hover-content {
        max-height: 0;
        margin-top: 0;
        opacity: 0;
    }

    .table-card.is-expanded .table-card__hover-content {
        max-height: 500px;
        margin-top: 14px;
        opacity: 1;
    }

}

/* =========================================================
   FORMULAIRE MJ
   ========================================================= */

.contact-form select {
    width: 100%;
    border: 1px solid #cccccc;
    border-radius: 9px;
    padding: 11px;
    background: #ffffff;
    color: #222;
}

.mj-form__message {
    min-height: 22px;
    font-size: 0.88rem;
    font-weight: 700;
}

.mj-form__message--success {
    color: #176b3a;
}

.mj-form__message--error {
    color: #9c2f2f;
}


/* =========================================================
   INFOS TABLE - FORMULAIRE MJ
   ========================================================= */

.mj-signup-table-info {
    display: grid;
    gap: 4px;

    margin-bottom: 22px;
    padding: 14px 16px;

    border-radius: 10px;

    background: #f5f5f5;
}

.mj-signup-table-info strong {
    color: #222;
}

.mj-signup-table-info span {
    color: #444;
}

.mj-signup-table-info small {
    color: #777;
    font-size: 0.82rem;
}

/* =========================================================
   FILTRE DATE DE CONVENTION
   ========================================================= */

.table-date-filter {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    margin-bottom: 4px;
}

.table-date-filter label {
    flex-shrink: 0;
    color: #555;
    font-size: 0.85rem;
    font-weight: 700;
}

.table-date-filter select {
    min-width: 300px;
    max-width: 100%;

    border: 1px solid #d4d4d4;
    border-radius: 10px;

    padding: 9px 12px;

    background: #ffffff;
    color: #444;

    font: inherit;
    font-size: 0.9rem;
    font-weight: 700;

    cursor: pointer;
}

.table-date-filter select:focus {
    border-color: #888;
    outline: 3px solid rgba(139, 124, 246, 0.15);
}


/* Inscriptions fermées */

.places.registration-closed {
    color: #9c2f2f;
}


@media (max-width: 760px) {

    .table-date-filter {
        align-items: stretch;
        flex-direction: column;
    }

    .table-date-filter select {
        width: 100%;
        min-width: 0;
    }

}

.table-card__participant-role {
    display: inline-block;
    min-width: 48px;
    margin-right: 6px;
    padding: 2px 6px;
    border-radius: 5px;
    background: #eeeeee;
    color: #555;
    font-size: 0.7rem;
    font-weight: 800;
    text-align: center;
    text-transform: uppercase;
}

#player-signup-modal .mj-signup-table-info {
    margin-bottom: 22px;
}


/* =========================================================
   DESCRIPTION DES TABLES
   ========================================================= */

.table-card__description {
    height: 120px;
    max-height: 120px;

    overflow-y: auto;
    overflow-x: hidden;

    padding-right: 12px;

    color: #555;
    font-size: 0.86rem;
    line-height: 1.45;

    scrollbar-width: auto;
    scrollbar-color: #888 #eeeeee;
}


/* Paragraphes */

.table-card__description p {
    margin: 0 0 8px;
}

.table-card__description p:last-child {
    margin-bottom: 0;
}


/* Description vide */

.table-card__description-empty {
    color: #888;
    font-style: italic;
}


/* =========================================================
   BARRE DE DEFILEMENT — CHROME / EDGE / SAFARI
   ========================================================= */

.table-card__description::-webkit-scrollbar {
    width: 12px;
}

.table-card__description::-webkit-scrollbar-track {
    background: #eeeeee;
    border-radius: 8px;
}

.table-card__description::-webkit-scrollbar-thumb {
    background: #888888;
    border-radius: 8px;
    border: 2px solid #eeeeee;
}

.table-card__description::-webkit-scrollbar-thumb:hover {
    background: #666666;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 760px) {

    .table-card__description {
        height: 120px;
        max-height: 120px;

        padding-right: 14px;

        font-size: 0.84rem;

        /*
         * Barre suffisamment large pour être
         * visible et utilisable au doigt.
         */
        scrollbar-width: auto;
    }

    .table-card__description::-webkit-scrollbar {
        width: 14px;
    }

    .table-card__description::-webkit-scrollbar-thumb {
        background: #777777;
        border-width: 2px;
    }

}



/* =========================================================
   PROGRAMME
   ========================================================= */

.programme-section {
    padding-top: 55px;
    padding-bottom: 55px;
}


/* ---------------------------------------------------------
   Informations générales
   --------------------------------------------------------- */

.programme-intro {
    margin-bottom: 24px;
    padding: 18px 22px;

    border-left: 4px solid #242424;
    border-radius: 10px;

    background: #f5f5f5;
}

.programme-intro p {
    margin: 0 0 8px;
}

.programme-intro p:last-child {
    margin-bottom: 0;
}


/* ---------------------------------------------------------
   Zone défilante du programme
   --------------------------------------------------------- */

.programme-section > .container {
    position: relative;
}

.programme-day {
    max-height: 560px;

    overflow-y: auto;
    overflow-x: hidden;

    margin-bottom: 26px;
    padding: 24px 28px 28px;

    border: 1px solid #e3e3e3;
    border-radius: 16px;

    background: #ffffff;

    box-shadow:
        0 4px 18px rgba(0, 0, 0, 0.05);

    scrollbar-width: auto;
    scrollbar-color: #888 #eeeeee;
}


/* ---------------------------------------------------------
   Barre de défilement
   --------------------------------------------------------- */

.programme-day::-webkit-scrollbar {
    width: 14px;
}

.programme-day::-webkit-scrollbar-track {
    background: #eeeeee;
    border-radius: 8px;
}

.programme-day::-webkit-scrollbar-thumb {
    background: #888888;
    border: 2px solid #eeeeee;
    border-radius: 8px;
}

.programme-day::-webkit-scrollbar-thumb:hover {
    background: #666666;
}


/* ---------------------------------------------------------
   Titres des journées
   --------------------------------------------------------- */

.programme-day__title {
    position: sticky;
    top: 0;
    z-index: 5;

    margin: -24px -28px 22px;
    padding: 18px 28px;

    border-bottom: 1px solid #e5e5e5;

    background: rgba(255, 255, 255, 0.97);

    color: #171717;

    font-size: 1.65rem;
    line-height: 1.2;

    backdrop-filter: blur(6px);
}


/* ---------------------------------------------------------
   Liste des événements
   --------------------------------------------------------- */

.programme-list {
    display: grid;
    gap: 12px;
}


/* ---------------------------------------------------------
   Événement
   --------------------------------------------------------- */

.programme-item {
    padding: 14px 16px;

    border-left: 4px solid #555;
    border-radius: 8px;

    background: #f8f8f8;
}

.programme-item > strong {
    display: block;

    margin-bottom: 5px;

    color: #222;

    font-size: 0.9rem;
}

.programme-item p {
    margin: 0 0 8px;

    color: #555;

    font-size: 0.92rem;
    line-height: 1.55;
}

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

.programme-item h4 {
    margin: 10px 0;

    color: #222;

    font-size: 1.05rem;
    line-height: 1.35;
}


/* ---------------------------------------------------------
   Activités de l'après-midi
   --------------------------------------------------------- */

.programme-subsection {
    margin-top: 28px;
    padding-top: 22px;

    border-top: 1px solid #e5e5e5;
}

.programme-subsection > h4 {
    margin: 0 0 16px;

    color: #222;

    font-size: 1.2rem;
}


/* ---------------------------------------------------------
   Activité
   --------------------------------------------------------- */

.programme-activity {
    margin-bottom: 18px;
    padding: 14px 16px;

    border-radius: 10px;

    background: #fafafa;
}

.programme-activity:last-child {
    margin-bottom: 0;
}

.programme-activity h5 {
    margin: 0 0 8px;

    color: #222;

    font-size: 0.98rem;
}

.programme-activity p {
    margin: 0 0 8px;

    color: #555;

    font-size: 0.9rem;
    line-height: 1.5;
}

.programme-activity p:last-child {
    margin-bottom: 0;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 760px) {

    .programme-section {
        padding-top: 45px;
        padding-bottom: 45px;
    }

    .programme-intro {
        padding: 15px 17px;
    }

    .programme-day {
        max-height: 500px;

        padding: 20px 17px 22px;

        border-radius: 14px;
    }

    .programme-day::-webkit-scrollbar {
        width: 14px;
    }

    .programme-day__title {
        margin: -20px -17px 18px;
        padding: 16px 17px;

        font-size: 1.4rem;
    }

    .programme-item {
        padding: 12px 13px;
    }

    .programme-item p {
        font-size: 0.88rem;
    }

    .programme-subsection {
        margin-top: 22px;
        padding-top: 18px;
    }

}

/* =========================================================
   EDITEUR DE DESCRIPTION
   ========================================================= */

.rich-editor {
    width: 100%;

    border: 1px solid #cccccc;
    border-radius: 9px;

    background: #ffffff;

    overflow: hidden;
}


.rich-editor__toolbar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 5px;

    padding: 7px;

    border-bottom: 1px solid #dddddd;

    background: #f7f7f7;
}


.rich-editor__button {
    min-width: 34px;
    min-height: 32px;

    padding: 5px 9px;

    border: 1px solid #d5d5d5;
    border-radius: 6px;

    background: #ffffff;
    color: #333333;

    cursor: pointer;
}


.rich-editor__button:hover {
    background: #eeeeee;
}


.rich-editor__button:focus-visible {
    outline: 2px solid #8b7cf6;
    outline-offset: 1px;
}


.rich-editor__color {
    position: relative;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 34px;
    height: 32px;

    border: 1px solid #d5d5d5;
    border-radius: 6px;

    background: #ffffff;

    color: #222222;
    font-weight: 800;

    cursor: pointer;

    overflow: hidden;
}


.rich-editor__color input {
    position: absolute;
    inset: 0;

    width: 100%;
    height: 100%;

    opacity: 0;

    cursor: pointer;
}


.rich-editor__area {
    min-height: 150px;
    max-height: 260px;

    overflow-y: auto;

    padding: 12px;

    color: #222222;

    line-height: 1.55;

    outline: none;
}


.rich-editor__area:empty::before {
    content: attr(data-placeholder);

    color: #999999;

    pointer-events: none;
}


.rich-editor__area:focus {
    box-shadow:
        inset 0 0 0 2px rgba(
            139,
            124,
            246,
            0.12
        );
}


.rich-editor__area p {
    margin: 0 0 8px;
}


.rich-editor__area ul,
.rich-editor__area ol {
    margin-top: 8px;
    margin-bottom: 8px;
    padding-left: 25px;
}


@media (max-width: 760px) {

    .rich-editor__toolbar {
        gap: 4px;
    }

    .rich-editor__button {
        min-width: 32px;
        min-height: 32px;
        padding: 5px 8px;
    }

    .rich-editor__area {
        min-height: 140px;
        max-height: 240px;
    }

}


/* =========================================================
   BARRES DE PROGRESSION
   ========================================================= */

.capacity-progress {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    width: 100%;
}

.capacity-progress__bar {
    position: relative;
    width: 100%;
    height: 10px;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.12);
}

.capacity-progress__fill {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: currentColor;
    transition: width 0.25s ease;
}

.capacity-progress__text {
    font-size: 0.9rem;
    line-height: 1.2;
}


/* Barre dans les cartes */
.table-card__participants {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}


/* Mobile */
@media (max-width: 640px) {

    .capacity-progress__bar {
        height: 12px;
    }

    .capacity-progress__text {
        font-size: 0.95rem;
    }

    .table-card__participants small {
        font-size: 0.9rem;
    }
}

/* =========================================================
   LIENS RÉSEAUX SOCIAUX
   ========================================================= */

.social-links .social-link {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;

    margin-left: 0.25rem;
    padding: 0.15rem 0.4rem;

    color: #155ea8;
    background: rgba(255, 255, 255, 0.35);

    border-radius: 0.35rem;

    font-weight: 700;
    text-decoration: none;

    transition:
        color 0.2s ease,
        background-color 0.2s ease;
}

.social-links .social-link:hover,
.social-links .social-link:focus-visible {
    color: #0b3f73;
    background: rgba(255, 255, 255, 0.7);
    text-decoration: underline;
}

.social-links .social-link span {
    font-size: 0.9em;
    line-height: 1;
}

/* =========================================================
   HIÉRARCHIE TITRE / TYPE DE JEU surcharge
   ========================================================= */

.table-card .pill {
    font-size: 0.95rem;
    font-weight: 700;
    padding: 0.35rem 0.65rem;
}

.table-card__title {
    font-size: 1.15rem;
    line-height: 1.25;
    font-weight: 600;
}

@media (max-width: 640px) {

    .table-card .pill {
        font-size: 0.9rem;
    }

    .table-card__title {
        font-size: 1.05rem;
    }

}

/* =========================================================
   EN-TÊTE DE CARTE : TYPE DE JEU + MODIFICATION
   ========================================================= */

.table-card__topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    width: 100%;
}


.table-card__edit {
    flex: 0 0 auto;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 2rem;
    height: 2rem;

    padding: 0;

    border: 1px solid rgba(0, 0, 0, 0.15);
    border-radius: 0.4rem;

    background: rgba(255, 255, 255, 0.55);

    color: inherit;

    font-size: 0.95rem;
    line-height: 1;

    cursor: pointer;

    transition:
        background-color 0.2s ease,
        transform 0.2s ease;
}


.table-card__edit:hover,
.table-card__edit:focus-visible {
    background: rgba(255, 255, 255, 0.9);
    transform: scale(1.05);
}


.table-card__edit:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

/* =========================================================
   SECTIONS REPLIABLES
   ========================================================= */

.fold-section {
    width: 100%;
}

.fold-section__summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;

    cursor: pointer;
    list-style: none;

    padding: 0.75rem 0;
}

.fold-section__summary::-webkit-details-marker {
    display: none;
}

.fold-section__summary h2 {
    margin: 0;
}

.fold-section__icon {
    flex: 0 0 auto;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 2rem;
    height: 2rem;

    border-radius: 50%;
    border: 1px solid currentColor;

    font-size: 1.25rem;
    font-weight: 600;
    line-height: 1;
}

.fold-section__icon::before {
    content: "+";
}

.fold-section[open] > .fold-section__summary
.fold-section__icon::before {
    content: "−";
}

.fold-section__summary:hover {
    opacity: 0.85;
}

.fold-section__summary:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 4px;
    border-radius: 4px;
}

.fold-section__content {
    padding-top: 0.75rem;
    padding-bottom: 1rem;
}


/* Sponsors et partenaires */

.sponsors-section .sponsors-grid {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
}


/* Mobile */

@media (max-width: 640px) {

    .fold-section__summary {
        padding: 0.65rem 0;
        gap: 0.75rem;
    }

    .fold-section__summary h2 {
        font-size: 1.2rem;
    }

    .fold-section__icon {
        width: 1.8rem;
        height: 1.8rem;
    }

}

/* =========================================================
   RÉDUIRE L'ESPACE ENTRE ACCUEIL, GÉNÉRAL ET PROGRAMME
   ========================================================= */

/* Bas de l'accueil */
#accueil.hero {
    padding-bottom: 1.5rem;
}

/* Section informations générales */
#general.section {
    padding-top: 1rem;
    padding-bottom: 1rem;
}

/* Paragraphes des informations générales */
#general.programme-intro p {
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
}

/* Haut de la section programme */
#programme.programme-section {
    padding-top: 0.5rem;
}

/* Haut de la section programme */
#programme.programme-section {
    padding-top: 0.5rem;
}

/* Haut de la section tables */
#programme.tables {
    padding-top: 0.5rem;
}

/* Haut de la section localisaiton */
#programme.localisation {
    padding-top: 0.5rem;
}

/* Haut de la section sponsor */
#programme.sponsors {
    padding-top: 0.5rem;
}


/* Adaptation mobile */
@media (max-width: 640px) {

    #accueil.hero {
        padding-bottom: 1rem;
    }

    #general.section {
        padding-top: 0.5rem;
        padding-bottom: 0.5rem;
    }

    #programme.programme-section {
        padding-top: 0.5rem;
    }
   
   #programme.tables {
       padding-top: 0.5rem;
   }
   
   
   #programme.localisation {
       padding-top: 0.5rem;
   }   
   
   #programme.sponsors {
       padding-top: 0.5rem;
   }
}

.table-edit-new-code {
    margin-top: 1rem;
    padding: 1rem;
    border: 1px solid currentColor;
    border-radius: 0.5rem;
    overflow-wrap: anywhere;
}

.table-edit-new-code code {
    display: block;
    margin-top: 0.5rem;
    padding: 0.75rem;
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-align: center;
    user-select: all;
}

/* =========================================================
   CODE DANS LA MODALE DE CONFIRMATION
   ========================================================= */

.operation-result__code-box {
    margin: 1rem 0;
    padding: 1rem;

    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 0.5rem;

    text-align: center;
}

.operation-result__code {
    display: block;
    margin: 0.75rem 0;

    padding: 0.8rem;

    border-radius: 0.35rem;

    background: rgba(255, 255, 255, 0.1);

    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: 0.12em;

    overflow-wrap: anywhere;
    user-select: all;
}

.operation-result__actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 1.25rem;
}


/* Statistiques discrètes dans le pied de page */
.site-footer__stats {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.25rem 0.5rem;
    margin: 0.5rem 0 0;
    font-size: 0.75rem;
    line-height: 1.4;
    opacity: 0.7;
}

.site-footer__stats strong {
    font-weight: 600;
}

.site-footer__stats-separator {
    opacity: 0.6;
}
