/*=====================================================
 * @file public/assets/css/histoire.css
 * @brief Styles du contenu de la page « Histoire et traditions ».
 *
 * Dernière modification : 18/10/2026 12:10
 * Version : 1.0.4
 *
 * Responsabilités :
 * - sections pleine largeur : qui sommes-nous (récit et fiche repères),
 *   valeurs (bande parchemin, quatre cartes, conclusion en citation),
 *   bannière (photo et trois étapes), tirs de tradition (bande vert
 *   profond, cartes alternées) ;
 * - une seule colonne sous 900 px.
 *
 * Dépendances principales :
 * - polices déclarées dans styles.css (--font-display, --font-text) ;
 * - templates/histoire/historique.php, valeurs.php, blason.php,
 *   tirs-tradition.php (la liste des Roys garde ses propres styles).
 *
 * Contraintes / remarques :
 * - texte de corps ≥ 17 px ; le doré #e3c27a n’est utilisé que sur le
 *   vert profond (1,7:1 sur blanc) ;
 * - contrastes calculés (AA) : #3a342b / parchemin 11,1:1 ; #5a5245 /
 *   parchemin 7,0:1 ; #4a4338 / parchemin 8,8:1 ; #7a5a12 / blanc 6,4:1 ;
 *   #1a7a4a / parchemin 4,8:1 ; #dfe8e1 / vert profond 9,8:1 ; #e3c27a /
 *   vert profond 7,1:1 ; #f7f3ea / vert profond 11,0:1 ;
 * - guide de lecture : cadre et titres de section → qui sommes-nous et
 *   frise → valeurs et conclusion → bannière → tirs de tradition (Saint
 *   Sébastien, Connétable, fiche technique, note) → une colonne sous 900 px.
 *====================================================*/

.histoire-page {
    --hist-green:     #1a7a4a;
    --hist-deep:      #0f3d27;
    --hist-parchment: #f7f3ea;
    --hist-rule:      #e4dccb;
    --hist-gold:      #e3c27a;   /* uniquement sur vert profond */
    --hist-eyebrow:   #7a5a12;   /* petits sur-titres sur fond clair */
    --hist-text:      #3a342b;
    --hist-strong:    #1f2a24;
    --hist-label:     #5a5245;
    --hist-caption:   #4a4338;
    --hist-pad-x:     clamp(1.25rem, 5vw, 4.5rem);
    --hist-pad-y:     clamp(2.75rem, 6vw, 4.75rem);

    padding: 0;                   /* les sections gèrent leurs marges */
    overflow: hidden;             /* bandes colorées rognées aux coins arrondis */
    color: var(--hist-strong);
}

/* ───────────────────────────────────────────────────────────────────────────
   Commun
   ───────────────────────────────────────────────────────────────────────── */
.hist-section { padding: var(--hist-pad-y) var(--hist-pad-x); }
.hist-section p { margin: 0; }
.hist-section p,
.hist-section li,
.hist-section dd {
    font-size: 1.125rem;          /* 18 px */
    line-height: 1.7;
    color: var(--hist-text);
}
.hist-band--parchment {
    background: var(--hist-parchment);
    border-top: 1px solid var(--hist-rule);
    border-bottom: 1px solid var(--hist-rule);
}
.hist-band--deep { background: var(--hist-deep); }

/* Titres de section (neutralise « section h2 » centré de styles.css) */
.hist-title {
    margin: 0;
    font-family: var(--font-display);
    font-size: clamp(2.25rem, 1.5rem + 2.4vw, 3.25rem);   /* 52 px */
    font-weight: 700;
    line-height: 1.05;
    text-align: left;
    color: var(--hist-deep);
}
.hist-section p.hist-eyebrow {
    font-size: .875rem;
    font-weight: 700;
    line-height: 1.4;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--hist-eyebrow);
}
.hist-photo {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 12px;
}
.hist-caption {
    font-size: .9375rem;          /* 15 px : légende */
    font-style: italic;
    color: var(--hist-caption);
}

/* ───────────────────────────────────────────────────────────────────────────
   1. Qui sommes-nous ? — récit + fiche « Quelques repères »
   ───────────────────────────────────────────────────────────────────────── */
.hist-intro {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 22.5rem;   /* fiche 360 px */
    gap: 3.5rem;
    align-items: start;
}
.hist-intro__story { display: flex; flex-direction: column; gap: 1.375rem; }
.hist-section p.hist-lead {
    font-size: 1.3125rem;         /* 21 px */
    font-weight: 600;
    line-height: 1.6;
    color: var(--hist-strong);
}

.hist-facts {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    padding: 1.75rem;
    background: var(--hist-parchment);
    border: 1px solid var(--hist-rule);
    border-radius: 16px;
}
.hist-facts__title {
    margin: 0;
    font-family: var(--font-display);
    font-size: 1.875rem;          /* 30 px */
    font-weight: 700;
    color: var(--hist-deep);
}
.hist-facts__list { display: flex; flex-direction: column; gap: .875rem; margin: 0; }
.hist-facts__item { display: flex; flex-direction: column; gap: .125rem; }
.hist-facts__item dt,
.hist-facts__label {
    margin: 0;
    font-family: var(--font-text);
    font-size: .875rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--hist-label);
}
.hist-section .hist-facts__item dd {
    margin: 0;
    font-size: 1.0625rem;         /* 17 px */
    font-weight: 600;
    line-height: 1.5;
    color: var(--hist-strong);
}
.hist-section .hist-facts__item dd.hist-facts__year {
    font-family: var(--font-display);
    font-size: 2.5rem;            /* 40 px */
    font-weight: 700;
    line-height: 1;
    color: var(--hist-green);
}
.hist-facts__affiliation {
    display: flex;
    flex-direction: column;
    gap: .75rem;
    padding-top: 1.125rem;
    border-top: 1px solid var(--hist-rule);
}
/* Frise verticale : un filet et une pastille par étape */
.hist-timeline {
    display: flex;
    flex-direction: column;
    gap: .875rem;
    margin: 0;
    padding: 0 0 0 1.25rem;
    border-left: 3px solid #c9dccf;
    list-style: none;
}
.hist-section .hist-timeline li {
    position: relative;
    display: flex;
    flex-direction: column;
    font-size: 1.0625rem;
    line-height: 1.4;
    color: var(--hist-strong);
}
.hist-timeline li::before {
    content: "";
    position: absolute;
    top: .35em;
    left: calc(-1.25rem - 8px);
    width: 13px;
    height: 13px;
    border: 3px solid var(--hist-parchment);
    border-radius: 50%;
    background: var(--hist-green);
}
.hist-timeline span { color: var(--hist-caption); }

/* ───────────────────────────────────────────────────────────────────────────
   2. Nos valeurs — 4 cartes + conclusion en citation
   ───────────────────────────────────────────────────────────────────────── */
.hist-values { display: flex; flex-direction: column; gap: 2.25rem; }
.hist-values__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem;
}
.hist-value {
    display: flex;
    flex-direction: column;
    gap: .875rem;
    padding: 1.875rem 2rem;
    background: #fff;
    border: 1px solid #ece5d6;
    border-radius: 16px;
}
.hist-value__head { display: flex; align-items: center; gap: .875rem; }
.hist-value__icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #e8f1eb;
    color: var(--hist-green);
}
.hist-value__icon svg {
    width: 24px;
    height: 24px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.hist-value__title {
    margin: 0;
    font-family: var(--font-display);
    font-size: 1.875rem;          /* 30 px */
    font-weight: 700;
    line-height: 1.1;
    color: var(--hist-deep);
}
.hist-section .hist-value p { font-size: 1.0625rem; line-height: 1.65; }   /* 17 px */

/* Conclusion : citation sur fond vert profond */
.hist-conclusion {
    display: flex;
    flex-direction: column;
    gap: .875rem;
    margin-top: .75rem;
    padding: 2.25rem clamp(1.5rem, 4vw, 3rem);
    background: var(--hist-deep);
    border-radius: 16px;
}
.hist-conclusion__label,
.hist-quote__caption {
    margin: 0;
    font-family: var(--font-text);
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--hist-gold);
}
.hist-quote { display: flex; flex-direction: column; gap: .875rem; margin: 0; }
.hist-quote__text { margin: 0; }
.hist-section .hist-quote__text p {
    font-family: var(--font-display);
    font-size: clamp(1.5rem, 1.1rem + 1.2vw, 1.875rem);   /* 30 px */
    font-style: italic;
    font-weight: 600;
    line-height: 1.35;
    color: var(--hist-parchment);
}

/* ───────────────────────────────────────────────────────────────────────────
   3. Notre blason — photo + 3 étapes
   ───────────────────────────────────────────────────────────────────────── */
.hist-blason {
    display: grid;
    grid-template-columns: minmax(0, 27.5rem) minmax(0, 1fr);   /* photo 440 px */
    gap: 4rem;
    align-items: start;
}
.hist-blason__figure { display: flex; flex-direction: column; gap: .75rem; margin: 0; }
.hist-blason__figure .hist-photo {
    padding: 1.5rem;
    background: var(--hist-parchment);
    border-radius: 16px;
}
.hist-blason__text { display: flex; flex-direction: column; gap: 1.375rem; }

.hist-steps {
    display: flex;
    flex-direction: column;
    gap: 1.125rem;
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: hist-step;
}
.hist-steps li {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
    counter-increment: hist-step;
}
.hist-steps li::before {
    content: counter(hist-step);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border: 2px solid var(--hist-green);
    border-radius: 50%;
    color: var(--hist-green);
    font-family: var(--font-display);
    font-size: 1.375rem;
    font-weight: 700;
    /* Chiffres « alignés » (hauteur des capitales) : les chiffres
       elzéviriens par défaut de Cormorant (1 et 2 petits, 3 qui descend)
       paraissent décentrés dans le cercle. */
    font-variant-numeric: lining-nums;
    line-height: 1;
}
.hist-steps li:last-child::before { background: var(--hist-green); color: #fff; }
.hist-section .hist-steps p { padding-top: .5rem; line-height: 1.65; }

/* ───────────────────────────────────────────────────────────────────────────
   4. Les tirs de tradition — bande vert profond, cartes alternées
   ───────────────────────────────────────────────────────────────────────── */
.hist-shoots { display: flex; flex-direction: column; gap: 2.5rem; }
.hist-shoots__intro { display: flex; flex-direction: column; gap: .875rem; max-width: 51.25rem; }
.hist-shoots__intro .hist-title { color: var(--hist-parchment); }
.hist-section .hist-shoots__intro p { font-size: 1.1875rem; line-height: 1.6; color: #dfe8e1; }

.hist-shoot {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 21.25rem;   /* média 340 px */
    gap: 2.5rem;
    align-items: start;
    padding: clamp(1.5rem, 3.5vw, 2.5rem);
    background: var(--hist-parchment);
    border-radius: 18px;
}
/* Saint Sébastien : image à gauche (l’ordre de lecture reste texte puis image) */
.hist-shoot--media-first { grid-template-columns: 21.25rem minmax(0, 1fr); }
.hist-shoot--media-first .hist-shoot__media { grid-column: 1; grid-row: 1; }
.hist-shoot--media-first .hist-shoot__body { grid-column: 2; grid-row: 1; }

.hist-shoot__body { display: flex; flex-direction: column; gap: 1rem; }
.hist-section p.hist-pill {
    align-self: flex-start;
    padding: .3rem .75rem;
    border-radius: 14px;
    background: var(--hist-deep);
    color: var(--hist-parchment);
    font-size: .875rem;
    font-weight: 700;
    line-height: 1.3;
}
.hist-shoot__title {
    margin: 0;
    font-family: var(--font-display);
    font-size: clamp(2rem, 1.5rem + 1.4vw, 2.5rem);   /* 40 px */
    font-weight: 700;
    line-height: 1.1;
    color: var(--hist-deep);
}
.hist-section .hist-shoot p { font-size: 1.0625rem; }            /* 17 px */
.hist-section .hist-shoot p.hist-shoot__lead {
    font-size: 1.1875rem;
    font-weight: 600;
    line-height: 1.6;
    color: var(--hist-strong);
}
.hist-shoot__subtitle {
    margin: .375rem 0 0;
    font-family: var(--font-text);
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--hist-deep);
}
/* Tir du Connétable : phrase d’origine mise en avant, mots inchangés */
.hist-pullquote {
    margin: .25rem 0;
    padding: .25rem 0 .25rem 1.25rem;
    border-left: 3px solid #b8892b;
}
.hist-section .hist-shoot .hist-pullquote p {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-style: italic;
    font-weight: 600;
    line-height: 1.35;
    color: var(--hist-deep);
}
/* Fiche technique */
.hist-sheet {
    display: grid;
    grid-template-columns: 9.375rem minmax(0, 1fr);
    gap: .625rem 1rem;
    margin: .5rem 0 0;
    padding: 1.25rem 1.375rem;
    background: #fff;
    border-radius: 12px;
}
.hist-sheet dt {
    font-size: 1.0625rem;
    font-weight: 700;
    line-height: 1.5;
    color: var(--hist-label);
}
.hist-section .hist-sheet dd {
    margin: 0;
    font-size: 1.0625rem;
    line-height: 1.5;
    color: var(--hist-strong);
}

.hist-shoot__media { display: flex; flex-direction: column; gap: 1rem; }
.hist-shoot__media--pair {                /* deux photos en hauteur, côte à côte */
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .75rem;
}
.hist-shoot__figure { display: flex; flex-direction: column; gap: .5rem; margin: 0; }

/* Note sur le règlement interne */
.hist-section p.hist-note {
    display: flex;
    align-items: center;
    gap: .75rem;
    font-size: 1.0625rem;
    color: #dfe8e1;
}
.hist-note svg {
    flex: 0 0 auto;
    width: 22px;
    height: 22px;
    fill: none;
    stroke: var(--hist-gold);
    stroke-width: 2;
    stroke-linecap: round;
}

/* ───────────────────────────────────────────────────────────────────────────
   5. Les Roys : même espace qu’avant (styles propres à roys.php)
   ───────────────────────────────────────────────────────────────────────── */
.histoire-roys { padding: 1.5rem 1rem; }

/* ───────────────────────────────────────────────────────────────────────────
   Une seule colonne sous 900 px
   ───────────────────────────────────────────────────────────────────────── */
@media (max-width: 899.98px) {
    .hist-intro,
    .hist-blason,
    .hist-shoot,
    .hist-shoot--media-first { grid-template-columns: minmax(0, 1fr); gap: 2rem; }
    .hist-values__grid { grid-template-columns: minmax(0, 1fr); }

    /* Photo au-dessus du texte */
    .hist-shoot .hist-shoot__media,
    .hist-shoot--media-first .hist-shoot__media { grid-column: 1; grid-row: 1; }
    .hist-shoot .hist-shoot__body,
    .hist-shoot--media-first .hist-shoot__body { grid-column: 1; grid-row: 2; }
    .hist-shoot__media .hist-photo {
        max-height: 26rem;
        object-fit: contain;
        background: #efe8d8;
    }
    .hist-blason__figure { max-width: 32rem; }
}
@media (max-width: 575.98px) {
    .hist-sheet { grid-template-columns: minmax(0, 1fr); gap: .125rem; }
    .hist-sheet dd + dt { margin-top: .5rem; }
    .hist-value { padding: 1.5rem 1.25rem; }
}
