/**
 * Diet & Sens - Pages de contenu (pages intérieures)
 *
 * Feuille autonome : ne dépend ni de styles.css ni de Tailwind.
 * Toutes les classes sont préfixées "ds-" pour ne jamais entrer en conflit
 * avec Tailwind ou styles.css (les pages légales peuvent charger les deux).
 * Seule exception : la bannière cookies garde les classes de l'accueil
 * (.cookie-banner, .cookie-btn...) pour un balisage identique.
 *
 * Versionnement : /css/pages.css est servi avec un cache d'un an
 * "immutable" (_headers). Toute modification => incrémenter ?v= dans
 * TOUTES les pages qui le chargent.
 *
 * Sommaire
 *  0. Polices auto-hébergées
 *  1. Variables
 *  2. Base & reset léger
 *  3. Accessibilité (skip link, focus, sr-only)
 *  4. Boutons
 *  5. En-tête & navigation
 *  6. Menu mobile
 *  7. Bandeau de page (fil d'Ariane, H1, intro, méta)
 *  8. Contenu rédactionnel (prose)
 *  9. Encadrés (En bref, note, important)
 * 10. Composants (étapes, liste à coches, tableau, FAQ, cartes)
 * 11. Appels à l'action (CTA)
 * 12. Sources, avertissement, À lire aussi
 * 13. Pied de page
 * 14. Bannière cookies
 * 15. Mouvement réduit & impression
 */

/* ==========================================================================
   0. POLICES AUTO-HÉBERGÉES (/fonts, @fontsource, sous-ensemble latin)
   Mêmes graisses qu'avant avec le CDN : Cormorant Garamond 600/700,
   Montserrat 400/600. Fichiers servis avec un cache d'un an (_headers).
   ========================================================================== */

@font-face {
    font-family: 'Cormorant Garamond';
    font-style: normal;
    font-display: swap;
    font-weight: 600;
    src: url('/fonts/cormorant-garamond-latin-600-normal.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: 'Cormorant Garamond';
    font-style: normal;
    font-display: swap;
    font-weight: 700;
    src: url('/fonts/cormorant-garamond-latin-700-normal.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: 'Montserrat';
    font-style: normal;
    font-display: swap;
    font-weight: 400;
    src: url('/fonts/montserrat-latin-400-normal.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: 'Montserrat';
    font-style: normal;
    font-display: swap;
    font-weight: 600;
    src: url('/fonts/montserrat-latin-600-normal.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ==========================================================================
   1. VARIABLES
   ========================================================================== */

:root {
    --ds-emerald-950: #022c22;
    --ds-emerald-900: #064e3b;
    --ds-emerald-800: #065f46;
    --ds-emerald-700: #047857;
    --ds-emerald-600: #059669;
    --ds-emerald-200: #a7f3d0;
    --ds-emerald-100: #d1fae5;
    --ds-emerald-50: #ecfdf5;
    --ds-gold: #d4af37;
    --ds-gold-light: #f3e5ab;
    --ds-amber-50: #fffbeb;
    --ds-amber-600: #b45309;
    --ds-amber-900: #78350f;

    --ds-bg: #faf9f6;
    --ds-surface: #ffffff;
    --ds-text: #1f2937;
    --ds-muted: #4b5563;
    --ds-subtle: #6b7280;
    --ds-border: #e5e7eb;

    --ds-font-sans: 'Montserrat', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
    --ds-font-serif: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;

    --ds-measure: 42rem; /* ~70 caractères ; en rem pour aligner bandeau et texte */
    --ds-container: 76rem;
    --ds-gutter: 16px;
    --ds-header-h: 68px;

    --ds-radius-sm: 8px;
    --ds-radius-md: 12px;
    --ds-radius-lg: 20px;
    --ds-shadow-soft: 0 10px 40px -10px rgba(0, 0, 0, 0.08);
    --ds-shadow-medium: 0 24px 50px -12px rgba(0, 0, 0, 0.14);
    --ds-ease: cubic-bezier(0.22, 1, 0.36, 1);
}

@media (min-width: 640px) {
    :root { --ds-gutter: 24px; }
}

@media (min-width: 1025px) {
    :root { --ds-gutter: 40px; --ds-header-h: 80px; }
}

/* ==========================================================================
   2. BASE & RESET LÉGER
   ========================================================================== */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body.ds-page {
    margin: 0;
    font-family: var(--ds-font-sans);
    font-size: 1rem;
    line-height: 1.7;
    color: var(--ds-text);
    background-color: var(--ds-bg);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

.ds-page img,
.ds-page svg {
    max-width: 100%;
    height: auto;
}

.ds-page h1,
.ds-page h2,
.ds-page h3,
.ds-page h4 {
    font-family: var(--ds-font-serif);
    color: var(--ds-emerald-900);
    line-height: 1.15;
    margin: 0;
}

/* Ancres : ne pas passer sous l'en-tête collant */
.ds-page [id] {
    scroll-margin-top: calc(var(--ds-header-h) + 16px);
}

.ds-container {
    width: 100%;
    max-width: var(--ds-container);
    margin-inline: auto;
    padding-inline: var(--ds-gutter);
}

/* Colonne de lecture (~70 caractères) */
.ds-narrow {
    max-width: var(--ds-measure);
    margin-inline: auto;
}

/* ==========================================================================
   3. ACCESSIBILITÉ
   ========================================================================== */

.ds-skip-link {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translate(-50%, -110%);
    white-space: nowrap;
    z-index: 10000;
    background: var(--ds-emerald-900);
    color: #fff;
    padding: 0.75rem 1.5rem;
    border-radius: 0 0 var(--ds-radius-sm) var(--ds-radius-sm);
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.2s;
}

.ds-skip-link:focus {
    transform: translate(-50%, 0);
    color: #fff;
}

.ds-sr-only {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Focus visible : anneau vert foncé (contraste suffisant sur fond clair) */
.ds-page :focus-visible {
    outline: 3px solid var(--ds-emerald-900);
    outline-offset: 3px;
    border-radius: 2px;
}

/* Sur fond sombre : anneau doré */
.ds-cta :focus-visible,
.ds-skip-link:focus-visible {
    outline-color: var(--ds-gold);
}

#main-content:focus {
    outline: none;
}

/* ==========================================================================
   4. BOUTONS
   ========================================================================== */

.ds-btn {
    position: relative;
    z-index: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    min-height: 48px;
    padding: 0.85rem 1.5rem;
    border: 1px solid transparent;
    border-radius: 2px;
    overflow: hidden;
    font-family: var(--ds-font-sans);
    font-size: 0.8125rem;
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.35s var(--ds-ease), background-color 0.35s var(--ds-ease), border-color 0.35s var(--ds-ease);
}

.ds-btn svg {
    width: 1.15em;
    height: 1.15em;
    flex-shrink: 0;
}

/* Principal : vert foncé, balayage doré au survol (comme .luxury-btn de l'accueil) */
.ds-btn--primary {
    background: var(--ds-emerald-900);
    color: #fff;
}

.ds-btn--primary::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    background: var(--ds-gold);
    transform: translateX(-101%);
    transition: transform 0.4s ease-in-out;
}

.ds-btn--primary:hover,
.ds-btn--primary:focus-visible {
    color: var(--ds-emerald-900);
}

.ds-btn--primary:hover::before,
.ds-btn--primary:focus-visible::before {
    transform: translateX(0);
}

/* Doré : pour fonds sombres */
.ds-btn--gold {
    background: var(--ds-gold);
    color: var(--ds-emerald-950);
}

.ds-btn--gold:hover,
.ds-btn--gold:focus-visible {
    background: #fff;
    color: var(--ds-emerald-900);
}

/* Contour : sur fond clair */
.ds-btn--ghost {
    background: transparent;
    color: var(--ds-emerald-900);
    border-color: var(--ds-emerald-900);
}

.ds-btn--ghost:hover,
.ds-btn--ghost:focus-visible {
    background: var(--ds-emerald-900);
    color: #fff;
}

/* Contour clair : sur fond sombre */
.ds-btn--ghost-light {
    background: transparent;
    color: #fff;
    border-color: rgba(255, 255, 255, 0.55);
}

.ds-btn--ghost-light:hover,
.ds-btn--ghost-light:focus-visible {
    background: #fff;
    color: var(--ds-emerald-900);
    border-color: #fff;
}

.ds-btn--small {
    min-height: 40px;
    padding: 0.6rem 1rem;
    font-size: 0.6875rem;
    letter-spacing: 0.1em;
}

.ds-btn--block {
    display: flex;
    width: 100%;
}

/* ==========================================================================
   5. EN-TÊTE & NAVIGATION
   ========================================================================== */

.ds-header {
    position: sticky;
    top: 0;
    z-index: 1001;
    background: rgba(250, 249, 246, 0.94);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(6, 78, 59, 0.08);
}

.ds-header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: var(--ds-header-h);
}

.ds-logo {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
    font-family: var(--ds-font-serif);
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1;
    color: var(--ds-emerald-900);
    text-decoration: none;
}

.ds-logo img {
    width: auto;
    height: 30px;
}

.ds-logo:hover {
    color: var(--ds-emerald-900);
}

.ds-gold {
    color: var(--ds-gold);
}

.ds-header__actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Navigation principale : masquée sous 1025px (menu mobile) */
.ds-nav {
    display: none;
}

.ds-nav__list {
    display: flex;
    align-items: center;
    gap: clamp(14px, 1.6vw, 28px);
    margin: 0;
    padding: 0;
    list-style: none;
}

.ds-nav__link {
    position: relative;
    display: inline-block;
    padding: 6px 0;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--ds-emerald-900);
    text-decoration: none;
    white-space: nowrap;
}

.ds-nav__link::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background: var(--ds-gold);
    transition: width 0.4s var(--ds-ease);
}

.ds-nav__link:hover {
    color: var(--ds-emerald-700);
}

.ds-nav__link:hover::after,
.ds-nav__link[aria-current]::after {
    width: 100%;
}

.ds-nav__link[aria-current] {
    font-weight: 600;
}

/* Bouton RDV de l'en-tête : visible dès 480px (sinon dans le menu mobile) */
.ds-header__cta {
    display: none;
}

@media (min-width: 480px) {
    .ds-header__cta {
        display: inline-flex;
    }
}

/* Bouton hamburger */
.ds-menu-toggle {
    position: relative;
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    width: 44px;
    height: 44px;
    padding: 0 8px;
    margin-right: -8px;
    background: transparent;
    border: 0;
    cursor: pointer;
}

.ds-menu-toggle__bar {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--ds-emerald-900);
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.ds-menu-toggle[aria-expanded="true"] .ds-menu-toggle__bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.ds-menu-toggle[aria-expanded="true"] .ds-menu-toggle__bar:nth-child(2) {
    opacity: 0;
}

.ds-menu-toggle[aria-expanded="true"] .ds-menu-toggle__bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

@media (min-width: 1025px) {
    .ds-logo {
        font-size: 1.75rem;
    }

    .ds-logo img {
        height: 34px;
    }

    .ds-nav {
        display: block;
    }

    .ds-header__actions {
        gap: clamp(16px, 2vw, 32px);
    }

    .ds-menu-toggle {
        display: none;
    }
}

/* ==========================================================================
   6. MENU MOBILE
   ========================================================================== */

.ds-mobile-menu {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    padding: calc(var(--ds-header-h) + 24px) var(--ds-gutter) 32px;
    overflow-y: auto;
    background: var(--ds-bg);
    visibility: hidden;
    opacity: 0;
    transform: translateY(-12px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s linear 0.3s;
}

.ds-mobile-menu.is-open {
    visibility: visible;
    opacity: 1;
    transform: none;
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s;
}

.ds-mobile-menu__list {
    margin: 0;
    padding: 0;
    list-style: none;
    text-align: center;
}

.ds-mobile-menu__link {
    display: block;
    padding: 0.5rem 0;
    font-family: var(--ds-font-serif);
    font-size: 2rem;
    font-weight: 600;
    line-height: 1.25;
    color: var(--ds-emerald-900);
    text-decoration: none;
}

.ds-mobile-menu__link[aria-current] {
    text-decoration: underline;
    text-decoration-color: var(--ds-gold);
    text-decoration-thickness: 2px;
    text-underline-offset: 6px;
}

.ds-mobile-menu__footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    margin-top: 28px;
}

.ds-mobile-menu__tel {
    font-weight: 600;
    color: var(--ds-emerald-800);
    text-decoration: none;
}

body.ds-menu-open {
    overflow: hidden;
}

@media (min-width: 1025px) {
    .ds-mobile-menu {
        display: none;
    }
}

/* ==========================================================================
   7. BANDEAU DE PAGE
   ========================================================================== */

.ds-page-hero {
    padding: 20px 0 36px;
    background-color: var(--ds-bg);
    background-image:
        linear-gradient(to bottom, rgba(250, 249, 246, 0.35), rgba(250, 249, 246, 0.9)),
        url('/Abstrait.webp');
    background-size: cover;
    background-position: center;
    border-bottom: 1px solid rgba(6, 78, 59, 0.08);
}

/* Fil d'Ariane */
.ds-breadcrumb {
    margin-bottom: 24px;
    font-size: 0.8125rem;
    line-height: 1.5;
    color: var(--ds-muted);
}

.ds-breadcrumb ol {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 0;
    margin: 0;
    padding: 0;
    list-style: none;
}

.ds-breadcrumb li {
    display: inline-flex;
    align-items: center;
}

/* Séparateur dessiné en CSS (non lu par les lecteurs d'écran) */
.ds-breadcrumb li + li::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    margin: 0 10px 0 8px;
    border-top: 1.5px solid currentColor;
    border-right: 1.5px solid currentColor;
    transform: rotate(45deg);
    opacity: 0.6;
}

.ds-breadcrumb a {
    color: var(--ds-emerald-700);
    text-decoration: underline;
    text-decoration-color: rgba(4, 120, 87, 0.35);
    text-underline-offset: 3px;
}

.ds-breadcrumb a:hover {
    color: var(--ds-emerald-900);
    text-decoration-color: currentColor;
}

.ds-breadcrumb [aria-current="page"] {
    font-weight: 600;
    color: var(--ds-emerald-900);
}

.ds-kicker {
    margin: 0 0 0.75rem;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--ds-emerald-700);
}

.ds-page-hero h1 {
    font-size: clamp(2.125rem, 1.45rem + 3.2vw, 3.5rem);
    font-weight: 700;
    line-height: 1.08;
    letter-spacing: -0.005em;
    text-wrap: balance;
}

.ds-lede {
    margin: 1rem 0 0;
    font-size: 1.0625rem;
    line-height: 1.65;
    color: var(--ds-text);
}

.ds-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 14px;
    margin: 1.25rem 0 0;
    font-size: 0.8125rem;
    color: var(--ds-muted);
}

.ds-meta a {
    color: var(--ds-emerald-800);
    font-weight: 600;
    text-decoration: none;
}

.ds-meta a:hover {
    text-decoration: underline;
}

.ds-meta__sep {
    display: none;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--ds-gold);
}

@media (min-width: 640px) {
    .ds-page-hero {
        padding: 28px 0 52px;
    }

    .ds-breadcrumb {
        margin-bottom: 36px;
    }

    .ds-lede {
        font-size: 1.1875rem;
    }

    .ds-meta__sep {
        display: inline-block;
    }
}

/* ==========================================================================
   8. CONTENU RÉDACTIONNEL (PROSE)
   ========================================================================== */

.ds-main {
    padding: 40px 0 64px;
}

.ds-prose {
    font-size: 1rem;
    line-height: 1.75;
    overflow-wrap: break-word;
}

.ds-prose > :first-child {
    margin-top: 0;
}

.ds-prose p {
    margin: 0 0 1.1em;
}

.ds-prose h2 {
    position: relative;
    margin: 2.4em 0 0.7em;
    padding-top: 0.9rem;
    font-size: 1.75rem;
    font-weight: 700;
}

/* Petit filet doré au-dessus des H2 */
.ds-prose h2::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--ds-gold);
}

.ds-prose h3 {
    margin: 1.8em 0 0.5em;
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--ds-emerald-800);
}

.ds-prose h4 {
    margin: 1.5em 0 0.4em;
    font-family: var(--ds-font-sans);
    font-size: 1rem;
    font-weight: 600;
    color: var(--ds-emerald-900);
}

.ds-prose ul,
.ds-prose ol {
    margin: 0 0 1.2em;
    padding-left: 1.35em;
}

.ds-prose li {
    margin-bottom: 0.45em;
    padding-left: 0.2em;
}

.ds-prose li::marker {
    color: var(--ds-emerald-600);
}

.ds-prose ol > li::marker {
    font-weight: 600;
}

.ds-prose strong {
    font-weight: 600;
    color: var(--ds-emerald-950);
}

/* Liens du texte courant uniquement : les liens à classe (boutons, cartes...) gèrent leur propre style */
.ds-prose a:not([class]) {
    color: var(--ds-emerald-700);
    font-weight: 500;
    text-decoration: underline;
    text-decoration-color: rgba(4, 120, 87, 0.4);
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
    transition: color 0.2s, text-decoration-color 0.2s;
}

.ds-prose a:not([class]):hover {
    color: var(--ds-emerald-900);
    text-decoration-color: var(--ds-gold);
    text-decoration-thickness: 2px;
}

.ds-prose blockquote {
    margin: 1.5em 0;
    padding: 0.25em 0 0.25em 1.25em;
    border-left: 3px solid var(--ds-gold);
    font-family: var(--ds-font-serif);
    font-size: 1.375rem;
    line-height: 1.45;
    color: var(--ds-emerald-900);
}

.ds-prose hr {
    margin: 2.5em 0;
    border: 0;
    border-top: 1px solid var(--ds-border);
}

.ds-prose figure {
    margin: 2em 0;
}

.ds-prose figure img {
    display: block;
    width: 100%;
    border-radius: var(--ds-radius-md);
}

.ds-prose figcaption {
    margin-top: 0.6em;
    font-size: 0.8125rem;
    color: var(--ds-subtle);
}

.ds-prose abbr[title] {
    text-decoration: underline dotted;
    cursor: help;
}

/* Section entière : espace avant (utile entre blocs de composants) */
.ds-section {
    margin-top: 3rem;
}

@media (max-width: 639px) {
    .ds-prose p,
    .ds-prose li {
        -webkit-hyphens: auto;
        hyphens: auto;
    }
}

@media (min-width: 640px) {
    .ds-main {
        padding: 56px 0 88px;
    }

    .ds-prose {
        font-size: 1.0625rem;
    }

    .ds-prose h2 {
        font-size: 2.125rem;
    }

    .ds-prose h3 {
        font-size: 1.5rem;
    }
}

/* ==========================================================================
   9. ENCADRÉS
   ========================================================================== */

/* « En bref » */
.ds-summary {
    margin: 0 0 2.25rem;
    padding: 1.25rem 1.25rem 1rem;
    background: var(--ds-surface);
    border: 1px solid rgba(6, 78, 59, 0.08);
    border-left: 4px solid var(--ds-gold);
    border-radius: 0 var(--ds-radius-md) var(--ds-radius-md) 0;
    box-shadow: var(--ds-shadow-soft);
}

.ds-summary__title,
.ds-prose .ds-summary__title {
    margin: 0 0 0.6rem;
    padding: 0;
    font-family: var(--ds-font-sans);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--ds-emerald-700);
}

.ds-prose .ds-summary__title::before {
    display: none;
}

.ds-summary ul {
    margin-bottom: 0.25rem;
}

/* Note d'information */
.ds-note {
    margin: 1.75em 0;
    padding: 1rem 1.25rem;
    background: var(--ds-emerald-50);
    border-left: 4px solid var(--ds-emerald-600);
    border-radius: 0 var(--ds-radius-sm) var(--ds-radius-sm) 0;
    font-size: 0.9375rem;
}

/* À retenir / important (ex. prescription médicale) */
.ds-note--important {
    background: var(--ds-amber-50);
    border-left-color: var(--ds-amber-600);
    color: var(--ds-amber-900);
}

.ds-note--important strong {
    color: var(--ds-amber-900);
}

.ds-note > :last-child,
.ds-summary > :last-child {
    margin-bottom: 0;
}

.ds-note__title {
    display: block;
    margin-bottom: 0.25rem;
    font-weight: 600;
}

@media (min-width: 640px) {
    .ds-summary {
        padding: 1.5rem 1.75rem 1.25rem;
    }
}

/* ==========================================================================
   10. COMPOSANTS
   ========================================================================== */

/* Liste à coches */
.ds-prose .ds-checklist,
.ds-checklist {
    padding-left: 0;
    list-style: none;
}

.ds-checklist li {
    position: relative;
    padding-left: 2rem;
}

.ds-checklist li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.3em;
    width: 1.2rem;
    height: 1.2rem;
    border-radius: 50%;
    background: var(--ds-emerald-100) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%23047857'%3E%3Cpath fill-rule='evenodd' d='M16.7 5.3a1 1 0 010 1.4l-8 8a1 1 0 01-1.4 0l-4-4a1 1 0 011.4-1.4L8 12.6l7.3-7.3a1 1 0 011.4 0z' clip-rule='evenodd'/%3E%3C/svg%3E") center / 0.8rem no-repeat;
}

/* Étapes numérotées */
.ds-prose .ds-steps,
.ds-steps {
    padding-left: 0;
    list-style: none;
    counter-reset: ds-step;
}

.ds-steps > li {
    position: relative;
    min-height: 2.25rem;
    margin-bottom: 1.25em;
    padding-left: 3.25rem;
    counter-increment: ds-step;
}

.ds-steps > li::before {
    content: counter(ds-step, decimal-leading-zero);
    position: absolute;
    left: 0;
    top: -0.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border: 1px solid var(--ds-gold);
    border-radius: 50%;
    font-family: var(--ds-font-serif);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--ds-emerald-900);
    background: var(--ds-surface);
}

.ds-steps__title {
    display: block;
    font-weight: 600;
    color: var(--ds-emerald-900);
}

/* Tableau (tarifs) : défilement horizontal interne si nécessaire */
.ds-table-wrap {
    margin: 1.5em 0 2em;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    background: var(--ds-surface);
    border: 1px solid var(--ds-border);
    border-radius: var(--ds-radius-md);
}

.ds-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9375rem;
    line-height: 1.5;
}

.ds-table caption {
    padding: 0.9rem 1rem 0;
    text-align: left;
    font-size: 0.8125rem;
    color: var(--ds-subtle);
    caption-side: bottom;
    padding-bottom: 0.9rem;
}

.ds-table th,
.ds-table td {
    padding: 0.85rem 1rem;
    text-align: left;
    vertical-align: top;
    border-bottom: 1px solid var(--ds-border);
}

.ds-table thead th {
    background: var(--ds-emerald-50);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ds-emerald-800);
}

.ds-table tbody tr:last-child th,
.ds-table tbody tr:last-child td {
    border-bottom: 0;
}

.ds-table tbody th {
    font-weight: 600;
    color: var(--ds-emerald-950);
}

.ds-table .ds-num {
    text-align: right;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

/* FAQ (details/summary) : le texte visible doit être identique au JSON-LD FAQPage */
.ds-faq {
    margin: 1.5em 0 2em;
    border-top: 1px solid var(--ds-border);
}

.ds-faq__item {
    border-bottom: 1px solid var(--ds-border);
}

.ds-faq__question {
    position: relative;
    display: block;
    padding: 1.1rem 2.5rem 1.1rem 0;
    font-weight: 600;
    line-height: 1.45;
    color: var(--ds-emerald-900);
    cursor: pointer;
    list-style: none;
}

.ds-faq__question::-webkit-details-marker {
    display: none;
}

.ds-faq__question::after {
    content: '';
    position: absolute;
    right: 0.5rem;
    top: 1.45rem;
    width: 9px;
    height: 9px;
    border-right: 2px solid var(--ds-emerald-700);
    border-bottom: 2px solid var(--ds-emerald-700);
    transform: rotate(45deg);
    transition: transform 0.25s ease;
}

.ds-faq__item[open] > .ds-faq__question::after {
    transform: translateY(4px) rotate(-135deg);
}

.ds-faq__question:hover {
    color: var(--ds-emerald-700);
}

.ds-faq__answer {
    padding: 0 0 1.1rem;
}

.ds-faq__answer > :last-child {
    margin-bottom: 0;
}

/* Grille de cartes liées (/prestations/, « À lire aussi ») */
.ds-card-grid,
.ds-prose .ds-card-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin: 1.5em 0 2em;
    padding: 0;
    list-style: none;
}

.ds-card-grid > li {
    margin: 0;
    padding: 0;
}

.ds-card {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 1.4rem 1.4rem 1.25rem;
    background: var(--ds-surface);
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: var(--ds-radius-lg);
    box-shadow: var(--ds-shadow-soft);
    transition: transform 0.35s var(--ds-ease), box-shadow 0.35s var(--ds-ease), border-color 0.35s var(--ds-ease);
}

.ds-card:hover,
.ds-card:focus-within {
    transform: translateY(-4px);
    border-color: var(--ds-gold);
    box-shadow: var(--ds-shadow-medium);
}

.ds-card__title,
.ds-prose .ds-card__title {
    margin: 0 0 0.4rem;
    padding: 0;
    font-family: var(--ds-font-serif);
    font-size: 1.375rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--ds-emerald-900);
}

.ds-prose .ds-card__title::before {
    display: none;
}

/* Lien étendu à toute la carte */
.ds-card__link,
.ds-prose .ds-card__link {
    color: inherit;
    font-weight: inherit;
    text-decoration: none;
}

.ds-card__link::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
}

.ds-card__text {
    flex: 1;
    margin: 0 0 0.9rem;
    font-size: 0.9375rem;
    line-height: 1.6;
    color: var(--ds-muted);
}

.ds-prose .ds-card__text {
    margin: 0 0 0.9rem;
}

.ds-card__more {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ds-emerald-700);
}

.ds-card__more::after {
    content: '→';
    transition: transform 0.3s var(--ds-ease);
}

.ds-card:hover .ds-card__more::after {
    transform: translateX(4px);
}

@media (min-width: 640px) {
    .ds-card-grid,
    .ds-prose .ds-card-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
}

/* 3 colonnes : à réserver aux grilles hors colonne de lecture (ex. /prestations/) */
@media (min-width: 1025px) {
    .ds-card-grid--3,
    .ds-prose .ds-card-grid--3 {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* ==========================================================================
   11. APPELS À L'ACTION
   ========================================================================== */

/* CTA de fin de page */
.ds-cta {
    position: relative;
    overflow: hidden;
    margin: 3.5rem 0 0;
    padding: 2rem 1.25rem;
    color: #fff;
    background: linear-gradient(135deg, var(--ds-emerald-800) 0%, var(--ds-emerald-900) 55%, var(--ds-emerald-950) 100%);
    border-radius: var(--ds-radius-lg);
    box-shadow: var(--ds-shadow-medium);
}

/* Cercles décoratifs (comme le bloc visio de l'accueil) */
.ds-cta::before,
.ds-cta::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}

.ds-cta::before {
    top: -110px;
    right: -90px;
    width: 260px;
    height: 260px;
    background: rgba(16, 185, 129, 0.14);
}

.ds-cta::after {
    bottom: -70px;
    left: -50px;
    width: 140px;
    height: 140px;
    background: rgba(212, 175, 55, 0.12);
}

.ds-cta > * {
    position: relative;
    z-index: 1;
}

.ds-cta__title,
.ds-prose .ds-cta__title {
    margin: 0 0 0.6rem;
    padding: 0;
    font-family: var(--ds-font-serif);
    font-size: 1.875rem;
    font-weight: 700;
    line-height: 1.15;
    color: #fff;
}

.ds-prose .ds-cta__title::before {
    display: none;
}

.ds-cta__text,
.ds-prose .ds-cta__text {
    margin: 0 0 1.5rem;
    font-size: 1rem;
    line-height: 1.65;
    color: var(--ds-emerald-100);
}

.ds-cta a:not(.ds-btn) {
    color: #fff;
    font-weight: 600;
    text-decoration: underline;
    text-decoration-color: rgba(243, 229, 171, 0.6);
    text-underline-offset: 3px;
}

.ds-cta a:not(.ds-btn):hover {
    color: var(--ds-gold-light);
    text-decoration-color: var(--ds-gold-light);
}

.ds-cta__actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.ds-cta__contact,
.ds-prose .ds-cta__contact {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 20px;
    margin: 1.4rem 0 0;
    padding: 0;
    list-style: none;
    font-size: 0.9375rem;
    color: var(--ds-emerald-100);
}

.ds-cta__contact li {
    margin: 0;
    padding: 0;
}

.ds-cta__lamal,
.ds-prose .ds-cta__lamal {
    margin: 1.25rem 0 0;
    padding-top: 1.1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    font-size: 0.875rem;
    line-height: 1.55;
    color: var(--ds-emerald-100);
}

@media (min-width: 640px) {
    .ds-cta {
        padding: 2.75rem 2.5rem;
    }

    .ds-cta__title,
    .ds-prose .ds-cta__title {
        font-size: 2.25rem;
    }

    .ds-cta__actions {
        flex-direction: row;
        flex-wrap: wrap;
    }
}

/* Rappel à mi-page (pages longues) */
.ds-cta-inline {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin: 2.5em 0;
    padding: 1.25rem;
    background: var(--ds-emerald-50);
    border: 1px solid var(--ds-emerald-100);
    border-radius: var(--ds-radius-md);
}

.ds-cta-inline__text,
.ds-prose .ds-cta-inline__text {
    margin: 0;
    font-weight: 500;
    line-height: 1.5;
    color: var(--ds-emerald-950);
}

.ds-cta-inline__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 18px;
}

.ds-cta-inline__tel,
.ds-prose .ds-cta-inline__tel {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    min-height: 44px;
    font-weight: 600;
    color: var(--ds-emerald-800);
    text-decoration: none;
}

.ds-cta-inline__tel svg {
    width: 1.1em;
    height: 1.1em;
}

.ds-cta-inline__tel:hover {
    color: var(--ds-emerald-950);
    text-decoration: underline;
}

@media (min-width: 640px) {
    .ds-cta-inline {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        padding: 1.25rem 1.5rem;
    }

    .ds-cta-inline__actions {
        flex-shrink: 0;
    }
}

/* ==========================================================================
   12. SOURCES, AVERTISSEMENT, À LIRE AUSSI
   ========================================================================== */

.ds-related {
    margin-top: 3.5rem;
}

.ds-related__title,
.ds-sources__title {
    margin: 0 0 1rem;
    font-family: var(--ds-font-serif);
    font-size: 1.625rem;
    font-weight: 700;
    color: var(--ds-emerald-900);
}

.ds-sources {
    margin-top: 3.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--ds-border);
    font-size: 0.875rem;
    line-height: 1.6;
    color: var(--ds-muted);
}

.ds-sources__title {
    font-size: 1.25rem;
}

.ds-sources ol {
    margin: 0;
    padding-left: 1.25em;
}

.ds-sources li {
    margin-bottom: 0.5em;
}

.ds-sources a {
    color: var(--ds-emerald-700);
    text-decoration: underline;
    text-decoration-color: rgba(4, 120, 87, 0.35);
    text-underline-offset: 2px;
    overflow-wrap: anywhere;
}

.ds-sources a:hover {
    color: var(--ds-emerald-900);
}

/* Indication visuelle des liens externes (texte SR à ajouter dans le HTML) */
.ds-ext::after {
    content: '';
    display: inline-block;
    width: 0.7em;
    height: 0.7em;
    margin-left: 0.25em;
    vertical-align: baseline;
    background: currentColor;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M7 17L17 7M9 7h8v8'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M7 17L17 7M9 7h8v8'/%3E%3C/svg%3E") center / contain no-repeat;
}

.ds-disclaimer {
    margin: 1.25rem 0 0;
    font-size: 0.8125rem;
    font-style: italic;
    color: var(--ds-subtle);
}

/* ==========================================================================
   13. PIED DE PAGE
   ========================================================================== */

.ds-footer {
    padding: 48px 0 28px;
    background: var(--ds-surface);
    border-top: 1px solid var(--ds-border);
    font-size: 0.875rem;
    line-height: 1.6;
    color: var(--ds-muted);
}

.ds-footer__grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 36px;
}

.ds-footer__brand {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 1rem;
    font-family: var(--ds-font-serif);
    font-size: 1.625rem;
    font-weight: 700;
    line-height: 1;
    color: var(--ds-emerald-900);
    text-decoration: none;
}

.ds-footer__brand img {
    width: auto;
    height: 38px;
}

.ds-footer__brand:hover {
    color: var(--ds-emerald-900);
}

.ds-footer address {
    margin: 0 0 0.9rem;
    font-style: normal;
}

.ds-page .ds-footer__title {
    margin: 0 0 1rem;
    font-family: var(--ds-font-sans);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--ds-emerald-800);
}

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

.ds-footer__links li {
    margin: 0 0 0.55rem;
}

.ds-footer a {
    color: var(--ds-muted);
    text-decoration: none;
}

.ds-footer a:hover {
    color: var(--ds-emerald-900);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.ds-footer__contact a {
    color: var(--ds-emerald-800);
    font-weight: 500;
}

.ds-footer__langs {
    margin: 0.9rem 0 0;
    font-size: 0.8125rem;
}

/* Horaires */
.ds-hours {
    margin: 0;
    padding: 0;
    list-style: none;
    max-width: 320px;
}

.ds-hours li {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 0.45rem 0;
    border-bottom: 1px solid #f3f4f6;
}

.ds-hours li:last-child {
    border-bottom: 0;
}

.ds-hours__time {
    font-weight: 500;
    font-variant-numeric: tabular-nums;
    color: var(--ds-emerald-800);
}

.ds-hours__closed {
    color: var(--ds-subtle);
}

/* Badge ASDD / SVDE */
.ds-badge {
    display: inline-block;
    margin-top: 1.25rem;
    padding: 0.85rem 1rem;
    background: var(--ds-emerald-50);
    border: 1px solid var(--ds-emerald-100);
    border-radius: var(--ds-radius-md);
}

.ds-badge__label {
    display: block;
    margin-bottom: 0.4rem;
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ds-emerald-700);
}

.ds-badge img {
    display: block;
    width: auto;
    height: 44px;
}

.ds-footer__bottom {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 40px;
    padding-top: 22px;
    border-top: 1px solid var(--ds-border);
    font-size: 0.8125rem;
    color: var(--ds-subtle);
}

.ds-footer__bottom p {
    margin: 0;
}

.ds-footer__legal {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 18px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.ds-footer__legal a,
.ds-linklike {
    color: var(--ds-subtle);
}

.ds-linklike {
    padding: 0;
    background: none;
    border: 0;
    font: inherit;
    cursor: pointer;
}

.ds-linklike:hover {
    color: var(--ds-emerald-900);
    text-decoration: underline;
    text-underline-offset: 3px;
}

@media (min-width: 640px) {
    .ds-footer__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 40px 48px;
    }
}

@media (min-width: 1025px) {
    .ds-footer {
        padding: 64px 0 32px;
    }

    .ds-footer__grid {
        grid-template-columns: 1.4fr 1fr 1fr 1.1fr;
    }

    .ds-footer__bottom {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
}

/* ==========================================================================
   14. BANNIÈRE COOKIES (mêmes classes et IDs que l'accueil)
   ========================================================================== */

.cookie-banner {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    padding: 1.25rem var(--ds-gutter);
    background: rgba(255, 255, 255, 0.98);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
    transform: translateY(100%);
    visibility: hidden;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), visibility 0s linear 0.4s;
}

.cookie-banner.visible {
    transform: translateY(0);
    visibility: visible;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), visibility 0s;
}

.cookie-banner-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    max-width: 1200px;
    margin: 0 auto;
}

.cookie-banner-text {
    flex: 1;
}

.cookie-banner-text h4 {
    margin: 0 0 0.4rem;
    font-family: var(--ds-font-serif);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--ds-emerald-900);
}

.cookie-banner-text p {
    margin: 0;
    font-size: 0.875rem;
    line-height: 1.5;
    color: var(--ds-muted);
}

.cookie-banner-text .cookie-links {
    margin-top: 0.5rem;
    font-size: 0.75rem;
    color: var(--ds-subtle);
}

.cookie-banner-text a {
    color: var(--ds-subtle);
    text-decoration: underline;
}

.cookie-banner-text a:hover {
    color: var(--ds-emerald-900);
}

.cookie-banner-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    flex-shrink: 0;
}

.cookie-btn {
    flex: 1 1 auto;
    min-height: 44px;
    padding: 0.75rem 1.25rem;
    border: none;
    border-radius: var(--ds-radius-sm);
    font-family: var(--ds-font-sans);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

.cookie-btn-accept {
    background: linear-gradient(135deg, var(--ds-gold) 0%, #c9a227 100%);
    color: #1a1a1a;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.35);
}

.cookie-btn-accept:hover {
    background: linear-gradient(135deg, #e6c447 0%, var(--ds-gold) 100%);
}

.cookie-btn-decline {
    background: transparent;
    color: var(--ds-emerald-900);
    border: 1px solid var(--ds-emerald-900);
}

.cookie-btn-decline:hover {
    background: rgba(6, 78, 59, 0.06);
}

@media (min-width: 768px) {
    .cookie-banner-content {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }

    .cookie-btn {
        flex: 0 0 auto;
    }
}

/* ==========================================================================
   15. MOUVEMENT RÉDUIT & IMPRESSION
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .ds-page *,
    .ds-page *::before,
    .ds-page *::after {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }

    .ds-card:hover,
    .ds-card:focus-within {
        transform: none;
    }
}

@media (prefers-contrast: more) {
    .ds-btn {
        border: 2px solid currentColor;
    }
}

@media print {
    .ds-header,
    .ds-mobile-menu,
    .ds-skip-link,
    .cookie-banner,
    .ds-cta__actions,
    .ds-cta-inline,
    .ds-related,
    .ds-footer__grid > :not(:first-child) {
        display: none !important;
    }

    body.ds-page {
        background: #fff;
        font-size: 11pt;
    }

    .ds-page-hero {
        background: none;
        padding: 0 0 12pt;
    }

    .ds-cta {
        color: #000;
        background: none;
        box-shadow: none;
        border: 1px solid #999;
    }

    .ds-cta__title,
    .ds-cta__text,
    .ds-cta__contact,
    .ds-cta__lamal,
    .ds-cta a:not(.ds-btn) {
        color: #000 !important;
    }

    .ds-sources a::after {
        content: ' (' attr(href) ')';
        font-size: 9pt;
    }
}
