/* Site de présentation : mêmes couleurs que l'application (wwwroot/css/app.css) */
:root {
    --s-ink: #0f172a;
    --s-ink-2: #1e293b;
    --s-text: #1f2937;
    --s-muted: #64748b;
    --s-faint: #94a3b8;
    --s-bg: #f4f6f9;
    --s-surface: #ffffff;
    --s-subtle: #f8fafc;
    --s-border: #e2e8f0;
    --s-border-strong: #cbd5e1;
    --s-accent: #f5a524;
    --s-accent-soft: #fff7e6;
    --s-accent-ink: #92400e;
    --s-radius: .6rem;
    --s-radius-lg: 1rem;
    --s-shadow: 0 1px 3px rgba(15, 23, 42, .08), 0 1px 2px rgba(15, 23, 42, .04);
    --s-shadow-lg: 0 24px 48px -16px rgba(15, 23, 42, .3);
    --s-nav: 60px;
    --bs-body-color: var(--s-text);
    --bs-body-font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--s-nav) + 1rem); }
body { background: var(--s-bg); -webkit-font-smoothing: antialiased; }
a { color: #2563eb; }

/* ---- barre du haut ---- */
.s-nav { position: sticky; top: 0; z-index: 50; height: var(--s-nav); display: flex; align-items: center; gap: 1rem;
    padding: 0 1.25rem; background: var(--s-ink); color: #fff; }
.s-marque { display: flex; align-items: center; gap: .6rem; color: #fff; text-decoration: none; }
.s-marque img { width: 34px; height: 34px; }
.s-marque b { display: block; font-size: .95rem; font-weight: 650; line-height: 1.1; }
.s-marque small { display: block; font-size: .64rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--s-faint); }
.s-liens { display: flex; gap: .25rem; margin-left: auto; }
.s-liens a { color: #cbd5e1; text-decoration: none; font-size: .875rem; padding: .4rem .7rem; border-radius: .4rem; }
.s-liens a:hover, .s-liens a.active { color: #fff; background: rgba(255, 255, 255, .08); }
.s-nav .btn-warning { font-weight: 600; white-space: nowrap; }
@media (max-width: 767.98px) { .s-liens { display: none; } .s-nav .btn-warning { margin-left: auto; } }

/* ---- trois colonnes : barre gauche | contenu | barre droite ---- */
.s-page { display: grid; grid-template-columns: 240px minmax(0, 1fr) 260px; gap: 2rem; max-width: 1480px; margin: 0 auto; padding: 0 1.25rem; }
.s-side { position: relative; }
.s-side-inner { position: sticky; top: var(--s-nav); height: calc(100vh - var(--s-nav)); display: flex; flex-direction: column; gap: 1rem; padding: 1.5rem 0 1.25rem; }
.s-side-scroll { overflow-y: auto; min-height: 0; scrollbar-width: thin; }
.s-main { padding: 1.5rem 0 3rem; min-width: 0; }
@media (max-width: 1199.98px) { .s-page { grid-template-columns: 210px minmax(0, 1fr) 220px; gap: 1.5rem; } }
@media (max-width: 991.98px) { .s-page { grid-template-columns: minmax(0, 1fr); } .s-side { display: none; } }

.s-sommaire-titre { font-size: .66rem; font-weight: 650; letter-spacing: .1em; text-transform: uppercase; color: var(--s-faint); margin-bottom: .5rem; }
.s-sommaire { list-style: none; padding: 0; margin: 0; font-size: .85rem; }
.s-sommaire a { display: flex; align-items: center; gap: .5rem; padding: .35rem .6rem; color: var(--s-muted); text-decoration: none; border-radius: .4rem; border-left: 2px solid transparent; }
.s-sommaire a:hover { color: var(--s-ink); background: var(--s-surface); }
.s-sommaire a.active { color: var(--s-ink); font-weight: 600; background: var(--s-surface); border-left-color: var(--s-accent); }
.s-carte { background: var(--s-surface); border: 1px solid var(--s-border); border-radius: var(--s-radius); padding: 1rem; font-size: .85rem; box-shadow: var(--s-shadow); }
.s-carte h3 { font-size: .9rem; font-weight: 650; color: var(--s-ink); margin-bottom: .5rem; }
.s-carte ul { padding-left: 1.1rem; margin: 0; color: var(--s-muted); }
.s-carte li + li { margin-top: .25rem; }

/* ---- encart publicitaire, collé en bas de chaque barre latérale ---- */
.encart-pub { margin-top: auto; flex: none; }
.encart-pub-label { display: block; font-size: .6rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--s-faint); margin-bottom: .25rem; }
.encart-pub-zone { display: flex; align-items: center; justify-content: center; gap: .45rem; height: 250px; border: 1px dashed var(--s-border-strong);
    border-radius: var(--s-radius); background: var(--s-subtle); color: var(--s-faint); font-size: .8rem; overflow: hidden; }
@media (max-height: 760px) { .encart-pub-zone { height: 120px; } }
.encart-pub-mobile { display: none; margin-top: 2.5rem; }
.encart-pub-mobile .encart-pub-zone { height: 120px; }
@media (max-width: 991.98px) { .encart-pub-mobile { display: block; } }

/* ---- accueil ---- */
.s-hero { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2rem; background: var(--s-ink); color: #fff; border-radius: var(--s-radius-lg);
    padding: 2.5rem 2.5rem 0; overflow: hidden; background-image: radial-gradient(circle at 85% 0%, #334155 0, transparent 55%); }
.s-hero .s-eyebrow { color: var(--s-accent); }
.s-hero h1 { font-size: clamp(1.8rem, 3.2vw, 2.6rem); font-weight: 700; letter-spacing: -.02em; line-height: 1.12; max-width: 22ch; text-wrap: balance; }
.s-hero p.lead { color: #cbd5e1; max-width: 60ch; font-size: 1.08rem; }
.s-hero .btn { font-weight: 600; }
.s-hero .btn-outline-light { --bs-btn-border-color: rgba(255, 255, 255, .25); }
.s-hero-points { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; font-size: .85rem; color: #cbd5e1; padding: 0; list-style: none; margin: 1.25rem 0 0; }
.s-hero-points i { color: var(--s-accent); margin-right: .3rem; }
.s-hero-capture { margin: 0 -.5rem; border-radius: .75rem .75rem 0 0; overflow: hidden; box-shadow: var(--s-shadow-lg); border: 1px solid rgba(255, 255, 255, .12); border-bottom: 0; }
.s-hero-capture img { display: block; width: 100%; height: auto; }
@media (max-width: 575.98px) { .s-hero { padding: 1.75rem 1.25rem 0; } }

.s-eyebrow { font-size: .72rem; font-weight: 650; letter-spacing: .12em; text-transform: uppercase; color: var(--s-accent-ink); margin-bottom: .5rem; }
.s-section { margin-top: 4rem; }
.s-section > h2 { font-size: 1.6rem; font-weight: 700; letter-spacing: -.015em; color: var(--s-ink); }
.s-section > p.s-intro { color: var(--s-muted); max-width: 70ch; }

.s-chiffres { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 1rem; margin-top: 1.5rem; }
.s-chiffre { background: var(--s-surface); border: 1px solid var(--s-border); border-radius: var(--s-radius); padding: 1rem 1.1rem; box-shadow: var(--s-shadow); }
.s-chiffre i { font-size: 1.3rem; color: var(--s-accent); }
.s-chiffre b { display: block; color: var(--s-ink); margin: .35rem 0 .15rem; }
.s-chiffre span { font-size: .85rem; color: var(--s-muted); }

/* une fonctionnalité : texte + capture, en alternance */
.s-fonction { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 2rem; align-items: center; margin-top: 3rem; }
.s-fonction:nth-of-type(even) { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
.s-fonction:nth-of-type(even) .s-fonction-texte { order: 2; }
.s-fonction h3 { font-size: 1.25rem; font-weight: 700; color: var(--s-ink); letter-spacing: -.01em; }
.s-fonction-icone { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 10px; margin-bottom: .75rem;
    background: var(--s-accent-soft); color: var(--s-accent-ink); border: 1px solid #fcd9a0; font-size: 1.15rem; }
.s-fonction p { color: var(--s-muted); }
.s-fonction ul { padding-left: 0; list-style: none; margin: 0; }
.s-fonction li { position: relative; padding-left: 1.5rem; margin-bottom: .4rem; font-size: .925rem; }
.s-fonction li::before { content: "\F26E"; font-family: bootstrap-icons; position: absolute; left: 0; top: 0; color: #16a34a; }
.s-capture { margin: 0; background: var(--s-surface); border: 1px solid var(--s-border); border-radius: var(--s-radius-lg); padding: .5rem; box-shadow: var(--s-shadow-lg); }
.s-capture img { display: block; width: 100%; height: auto; border-radius: .6rem; }
.s-capture.etroite { max-width: 380px; margin-inline: auto; }
.s-capture figcaption { font-size: .78rem; color: var(--s-faint); padding: .5rem .25rem 0; }
@media (max-width: 991.98px) {
    .s-fonction, .s-fonction:nth-of-type(even) { grid-template-columns: minmax(0, 1fr); gap: 1.25rem; }
    .s-fonction:nth-of-type(even) .s-fonction-texte { order: 0; }
}

.s-grille { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; margin-top: 1.5rem; }
.s-tuile { background: var(--s-surface); border: 1px solid var(--s-border); border-radius: var(--s-radius); padding: 1.1rem 1.2rem; box-shadow: var(--s-shadow); }
.s-tuile i { font-size: 1.2rem; color: var(--s-accent-ink); }
.s-tuile h4 { font-size: 1rem; font-weight: 650; color: var(--s-ink); margin: .5rem 0 .3rem; }
.s-tuile p { font-size: .875rem; color: var(--s-muted); margin: 0; }

.s-avert { display: flex; gap: 1rem; background: var(--s-accent-soft); border: 1px solid #fcd9a0; border-radius: var(--s-radius-lg); padding: 1.4rem 1.5rem; }
.s-avert > i { font-size: 1.6rem; color: #d97706; flex: none; }
.s-avert p { margin-bottom: .5rem; }
.s-avert p:last-child { margin-bottom: 0; }

.s-cta { text-align: center; background: var(--s-surface); border: 1px solid var(--s-border); border-radius: var(--s-radius-lg); padding: 2.5rem 1.5rem; box-shadow: var(--s-shadow); }
.s-cta h2 { font-weight: 700; color: var(--s-ink); }

/* ---- page de texte (mentions légales) ---- */
.s-texte { background: var(--s-surface); border: 1px solid var(--s-border); border-radius: var(--s-radius-lg); padding: 2rem 2.25rem; box-shadow: var(--s-shadow); max-width: 820px; }
.s-texte h1 { font-size: 1.8rem; font-weight: 700; color: var(--s-ink); letter-spacing: -.015em; }
.s-texte h2 { font-size: 1.1rem; font-weight: 650; color: var(--s-ink); margin-top: 2rem; padding-top: 1.25rem; border-top: 1px solid var(--s-border); }
.s-texte dl { display: grid; grid-template-columns: max-content 1fr; gap: .35rem 1.25rem; margin: 0; }
.s-texte dt { font-weight: 600; color: var(--s-muted); }
.s-texte dd { margin: 0; }
@media (max-width: 575.98px) { .s-texte { padding: 1.5rem 1.25rem; } .s-texte dl { grid-template-columns: 1fr; } .s-texte dd { margin-bottom: .5rem; } }

.s-pied { border-top: 1px solid var(--s-border); margin-top: 4rem; padding-top: 1.5rem; display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; font-size: .82rem; color: var(--s-muted); }
.s-pied a { color: var(--s-muted); }
.s-pied a:hover { color: var(--s-ink); }

/* Google AdSense (js/pub.js) : le bloc remplace « Votre annonce ici » */
.encart-pub-ads:empty { display: none; }
.encart-pub-actif .encart-pub-zone { display: none; }
.encart-pub-ads { min-height: 100px; overflow: hidden; }

/* ---- pages séparées : tuiles cliquables, fil d'Ariane, page d'une fonctionnalité, précédent / suivant ---- */
.s-tuile-lien { display: flex; flex-direction: column; text-decoration: none; color: inherit; transition: border-color .15s, box-shadow .15s, transform .15s; }
.s-tuile-lien:hover { border-color: #fcd9a0; box-shadow: var(--s-shadow-lg); transform: translateY(-2px); color: inherit; }
.s-tuile-suite { margin-top: auto; padding-top: .75rem; font-size: .85rem; font-weight: 600; color: var(--s-accent-ink); }
.s-fil { font-size: .8rem; color: var(--s-muted); margin-bottom: 1.25rem; display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; }
.s-fil a { color: var(--s-muted); }
.s-fil span { color: var(--s-ink); font-weight: 600; }
.s-fil .bi { font-size: .65rem; }
.s-fonction-page { margin-top: 0; }
.s-fonction-page h1 { font-size: clamp(1.6rem, 2.6vw, 2.2rem); font-weight: 700; color: var(--s-ink); letter-spacing: -.015em; }
.s-fonction-page .lead { color: var(--s-muted); font-size: 1.05rem; }
.s-voisines { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 3rem; }
.s-voisine { display: flex; flex-direction: column; gap: .2rem; background: var(--s-surface); border: 1px solid var(--s-border); border-radius: var(--s-radius);
    padding: .9rem 1.1rem; text-decoration: none; color: var(--s-ink); font-weight: 600; box-shadow: var(--s-shadow); }
.s-voisine:hover { border-color: #fcd9a0; color: var(--s-ink); }
.s-voisine small { font-size: .7rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--s-faint); }
.s-voisine-suiv { text-align: right; grid-column: 2; }
@media (max-width: 575.98px) { .s-voisines { grid-template-columns: 1fr; } .s-voisine-suiv { grid-column: auto; } }
/* page d'une fonctionnalité : texte puis grande capture */
.s-fonction.s-fonction-page, .s-fonction.s-fonction-page:nth-of-type(even) { grid-template-columns: minmax(0, 1fr); gap: 2rem; }
.s-fonction-page .s-fonction-texte { order: 0; max-width: 72ch; }
