/* Pages simples du Temple (tournage, événements, notre histoire). */
body:has(.temple-page) #main {
    background:
        radial-gradient(circle at 88% 15%, color-mix(in srgb, var(--temple-emeraude) 16%, transparent), transparent 32rem),
        var(--temple-fond) !important;
}
body:has(.temple-page) footer {
    background: var(--temple-fond) !important;
}

.temple-page {
    overflow-x: clip;
    text-align: center;
}
.temple-page .bouton {
    display: inline-flex;
    align-items: center;
    height: auto;
    max-height: none;
    margin: 0;
    /* Compensation optique de la cursive : mêmes dimensions, capitales légèrement abaissées. */
    padding: .9em 1.6em .7em;
    text-transform: uppercase;
    font-size: clamp(1rem, 1.3vw, 1.2rem);
}

.temple-page-hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    min-height: min(78svh, 46rem);
    padding: calc(10vh + 4rem) 1rem clamp(5rem, 10vh, 7rem);
    background:
        linear-gradient(180deg, #000a 0%, #0007 45%, var(--temple-fond) 100%),
        var(--image-hero) center / cover no-repeat var(--temple-fond);
}
.temple-page-surtitre {
    color: var(--temple-beige);
    font-family: var(--font-cursive);
    letter-spacing: .12em;
    text-transform: uppercase;
    font-size: .95rem;
}
.temple-page-hero h1 {
    max-width: 18ch;
    font-weight: 400;
    font-size: clamp(2.2rem, 5vw, 4.4rem);
    line-height: 1.05;
    text-shadow: 0 .2rem 1rem #000c;
}
.temple-page-intro {
    max-width: 38rem;
    font-size: clamp(1.05rem, 1.4vw, 1.3rem);
    line-height: 1.5;
    text-shadow: 0 1px .5rem #000;
}

.temple-page-corps {
    padding: clamp(3.5rem, 7vw, 6rem) 1rem clamp(4rem, 8vw, 7rem);
}
.temple-page-chiffres {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: clamp(1.5rem, 5vw, 5rem);
    margin-bottom: clamp(2.5rem, 5vw, 4rem);
    list-style: none;
}
.temple-page-chiffres li {
    display: flex;
    flex-direction: column;
    gap: .3rem;
}
.temple-page-chiffres strong {
    color: var(--temple-emeraude);
    font-family: var(--font-cursive);
    font-size: clamp(1.8rem, 3.5vw, 2.8rem);
    font-weight: 400;
}
.temple-page-sections {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
    gap: clamp(2rem, 4vw, 3.5rem);
    width: min(100%, 72rem);
    margin: 0 auto;
}
.temple-page-sections h2 {
    font-weight: 400;
    font-size: clamp(1.4rem, 2.2vw, 1.9rem);
}
.temple-page-sections p {
    margin-top: 1.2rem;
    font-size: 1.1rem;
    line-height: 1.55;
}

@media (min-width: 761px) {
    .temple-page-tournage .temple-page-sections h2,
    .temple-page-notre-histoire .temple-page-sections h2 {
        display: block;
        width: 100%;
        max-width: 16ch;
        min-height: 2.4em;
        margin-inline: auto;
    }
}

.temple-page-action {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.2rem;
    padding: clamp(6rem, 10vw, 8rem) 1rem clamp(4rem, 8vw, 6rem);
}
.temple-page-action h2 {
    font-weight: 400;
    font-size: clamp(1.6rem, 3vw, 2.6rem);
}
.temple-page-action > p {
    max-width: 38rem;
    line-height: 1.5;
    opacity: .85;
}
.temple-page-boutons {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 1rem;
}
.temple-page-telephone {
    color: var(--temple-beige);
}
/* Bloc seul sur sa dernière ligne (grands groupes des événements) : centré sur toute la largeur. */
.temple-page-sections > div:last-child:nth-child(3n + 1) {
    grid-column: 1 / -1;
    justify-self: center;
    max-width: 44rem;
}
.temple-page-telechargements {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin-top: clamp(2.5rem, 5vw, 3.5rem);
    list-style: none;
}
/* Sans bloc final (presse), la bande de papier précède le footer : place pour son bord déchiré. */
.temple-page-corps:last-child {
    margin-bottom: clamp(4rem, 8vw, 6rem);
}
.temple-page-telechargements .bouton {
    gap: .55em;
}
/* Équilibre des colonnes : titres sur deux lignes de même hauteur (soulignés alignés), chiffres de largeur égale. */
.temple-page-sections h2 {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    min-height: 2.7em;
}
.temple-page-sections p {
    text-wrap: pretty;
}
.temple-page-chiffres li {
    flex: 0 1 13rem;
}
.temple-page-chiffres li {
    flex: 0 0 auto;
    min-width: 13rem;
}
.temple-page-chiffres strong {
    white-space: nowrap;
}
/* Lignes incomplètes centrées (5 blocs sur « Peur à la carte ») plutôt que calées à gauche. */
.temple-page-sections {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}
.temple-page-sections > div {
    flex: 0 1 21rem;
}
.temple-page-sections > div:last-child:nth-child(3n + 1) {
    flex-basis: 100%;
}
@media (max-width: 600px) {
    .temple-page-chiffres li {
        min-width: 0;
        flex: 1 1 0;
    }
    .temple-page-chiffres strong {
        white-space: normal;
        font-size: 1.6rem;
    }
}
