/* ═══════════════════════════════════════════════════════════════
   HAMEL TECH — Feuille de style principale
   Double thème sombre/clair via variables CSS uniquement.
   Polices : Sora (titres) + Inter (corps)
   ═══════════════════════════════════════════════════════════════ */

/* ── Google Fonts : chargé en parallèle dans <head> via <link> pour de meilleures performances ── */

/* ── Variables — Thème SOMBRE (défaut) ───────────────────────── */
:root,
[data-theme="sombre"] {
    /* Fonds */
    --bg:           #0d0d0d;
    --bg2:          #161616;
    --bg3:          #1f1f1f;
    --bg-glass:     rgba(22, 22, 22, 0.8);
    --bg-glass2:    rgba(31, 31, 31, 0.7);
    --bord:         rgba(69, 123, 157, 0.2);
    --bord-fort:    rgba(69, 123, 157, 0.45);

    /* Textes */
    --texte:        #e8e8e8;
    --texte2:       #888888;
    --texte3:       #555555;

    /* Accents */
    --cyan:         #457b9d;
    --cyan2:        #2e6080;
    --orange:       #e63946;
    --orange2:      #c0212e;

    /* Dégradé signature */
    --grad:         linear-gradient(135deg, #e63946 0%, #457b9d 100%);
    --grad-texte:   linear-gradient(135deg, #e63946 0%, #457b9d 100%);

    /* États */
    --succes:       #22c55e;
    --danger:       #ef4444;
    --attention:    #f59e0b;
    --info:         #3b82f6;

    /* Halos d'arrière-plan */
    --halo-orange:  rgba(230, 57, 70, 0.10);
    --halo-cyan:    rgba(69, 123, 157, 0.08);

    /* Ombres */
    --ombre:        0 4px 24px rgba(0,0,0,.5);
    --ombre-lg:     0 8px 48px rgba(0,0,0,.65);

    --rayon:        8px;
    --rayon-lg:     14px;
    --transition:   .2s ease;
}

/* ── Variables — Thème CLAIR ─────────────────────────────────── */
[data-theme="clair"] {
    --bg:           #f0f7ff;
    --bg2:          #e0edff;
    --bg3:          #ffffff;
    --bg-glass:     rgba(224, 237, 255, 0.8);
    --bg-glass2:    rgba(240, 247, 255, 0.85);
    --bord:         rgba(3, 105, 161, 0.15);
    --bord-fort:    rgba(3, 105, 161, 0.35);

    --texte:        #1a2744;
    --texte2:       #4a6180;
    --texte3:       #7a98b0;

    --cyan:         #0369a1;
    --cyan2:        #025483;
    --orange:       #e63946;
    --orange2:      #c0212e;

    --grad:         linear-gradient(135deg, #e63946 0%, #0369a1 100%);
    --grad-texte:   linear-gradient(135deg, #e63946 0%, #0369a1 100%);

    --succes:       #16a34a;
    --danger:       #dc2626;
    --attention:    #d97706;
    --info:         #2563eb;

    --halo-orange:  rgba(230, 57, 70, 0.07);
    --halo-cyan:    rgba(3, 105, 161, 0.07);

    --ombre:        0 4px 24px rgba(0,0,0,.08);
    --ombre-lg:     0 8px 48px rgba(0,0,0,.14);
}

/* ═══════════════════════════════════════════════════════════════
   RESET & BASE
   ═══════════════════════════════════════════════════════════════ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    background: var(--bg);
    color: var(--texte);
    min-height: 100vh;
    transition: background var(--transition), color var(--transition);
    overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--cyan); text-decoration: none; }
a:hover { color: var(--cyan2); }
button { cursor: pointer; font-family: inherit; }

:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 3px;
    border-radius: 3px;
}

/* ═══════════════════════════════════════════════════════════════
   TYPOGRAPHIE
   ═══════════════════════════════════════════════════════════════ */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Sora', system-ui, sans-serif;
    font-weight: 700;
    line-height: 1.2;
    color: var(--texte);
}

h1 { font-size: clamp(1.75rem, 4vw, 3.25rem); overflow-wrap: break-word; word-break: break-word; }
h2 { font-size: clamp(1.4rem, 3vw, 2.25rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.5rem); }
h4 { font-size: 1.1rem; }

.texte-gradient {
    background: var(--grad-texte);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

p + p { margin-top: .75rem; }
.texte-subtil { color: var(--texte2); font-size: .9rem; }
.texte-danger  { color: var(--danger); }
.texte-succes  { color: var(--succes); }
.texte-centre  { text-align: center; }

/* ═══════════════════════════════════════════════════════════════
   HALOS D'ARRIÈRE-PLAN (décoratifs, non interactifs)
   ═══════════════════════════════════════════════════════════════ */
.halos {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}
.halo {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
    opacity: .7;
    animation: pulsation 12s ease-in-out infinite alternate;
}
.halo-1 {
    width: 600px; height: 600px;
    background: var(--halo-orange);
    top: -150px; left: -200px;
    animation-delay: 0s;
}
.halo-2 {
    width: 500px; height: 500px;
    background: var(--halo-cyan);
    bottom: 10%; right: -100px;
    animation-delay: -5s;
}
.halo-3 {
    width: 400px; height: 400px;
    background: var(--halo-orange);
    top: 50%; left: 40%;
    animation-delay: -9s;
}

@keyframes pulsation {
    from { transform: scale(1) translateY(0); }
    to   { transform: scale(1.15) translateY(-30px); }
}

@media (prefers-reduced-motion: reduce) {
    .halo { animation: none; }
}

@media (max-width: 820px) {
    /* Désactivation des halos de flou sur mobile pour fluidité maximale 60/120fps */
    .halos { display: none !important; }
}

/* ═══════════════════════════════════════════════════════════════
   CONTENEUR & GRILLE
   ═══════════════════════════════════════════════════════════════ */
.conteneur {
    width: 100%;
    max-width: 1200px;
    margin-inline: auto;
    padding-inline: 1.5rem;
    position: relative;
    z-index: 1;
}

.grille {
    display: grid;
    gap: 1.5rem;
}
.grille-2  { grid-template-columns: repeat(2, 1fr); }
.grille-3  { grid-template-columns: repeat(3, 1fr); }
.grille-4  { grid-template-columns: repeat(4, 1fr); }
.grille-12 { grid-template-columns: repeat(12, 1fr); }

.col-6  { grid-column: span 6; }
.col-7  { grid-column: span 7; }
.col-5  { grid-column: span 5; }
.col-8  { grid-column: span 8; }
.col-4  { grid-column: span 4; }
.col-12 { grid-column: span 12; }

/* ═══════════════════════════════════════════════════════════════
   HEADER & NAVIGATION
   ═══════════════════════════════════════════════════════════════ */
.site-header {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 200;
    padding: .75rem 0;
    background: transparent;
    transition: background var(--transition), backdrop-filter var(--transition), box-shadow var(--transition);
}

.site-header.defilé {
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 var(--bord), var(--ombre);
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.logo-lien {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    text-decoration: none;
    border-radius: 12px;
    overflow: hidden;
}
.logo-img {
    height: 110px;
    width: auto;
    display: block;
}

.nav-principale {
    display: flex;
    align-items: center;
    gap: .25rem;
    list-style: none;
    flex: 1;
}

.nav-principale a {
    display: flex;
    align-items: center;
    gap: .4rem;
    padding: .45rem .85rem;
    border-radius: var(--rayon);
    color: var(--texte2);
    font-size: .875rem;
    font-weight: 500;
    transition: color var(--transition), background var(--transition);
    white-space: nowrap;
}
.nav-principale a:hover,
.nav-principale a.actif {
    color: var(--texte);
    background: rgba(0, 194, 203, .08);
}
.nav-principale a.actif { color: var(--cyan); }

/* Menu déroulant */
.nav-dropdown {
    position: relative;
}
.nav-dropdown > a {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
}
.nav-dropdown > a::after {
    content: '';
    display: inline-block;
    width: 0; height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid currentColor;
    margin-left: .2rem;
    vertical-align: middle;
    transition: transform var(--transition);
    opacity: .75;
}
.nav-dropdown:hover > a::after,
.nav-dropdown.ouvert > a::after {
    transform: rotate(180deg);
}

.nav-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    margin: 0 !important;
    padding: .4rem !important;
    list-style: none !important;
    list-style-type: none !important;
    background: var(--bg3);
    border: 1px solid var(--bord-fort);
    border-radius: var(--rayon-lg);
    min-width: 230px;
    box-shadow: 0 14px 35px rgba(0, 0, 0, 0.22), 0 4px 12px rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(6px);
    transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
    z-index: 300;
    pointer-events: none;
}

/* Pont invisible pour que la souris ne perde JAMAIS le hover */
.nav-dropdown-menu::before {
    content: '';
    position: absolute;
    top: -15px;
    left: 0;
    right: 0;
    height: 15px;
    background: transparent;
}

.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu,
.nav-dropdown.ouvert .nav-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(4px);
    pointer-events: auto;
}

.nav-dropdown-menu li {
    display: block !important;
    list-style: none !important;
    list-style-type: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.nav-dropdown-menu li::marker {
    display: none !important;
    content: '' !important;
}

.nav-dropdown-menu a {
    display: block;
    padding: .6rem 1rem;
    border-radius: var(--rayon);
    border-left: 2px solid transparent;
    color: var(--texte);
    font-size: .875rem;
    font-weight: 500;
    text-decoration: none;
    white-space: nowrap;
    transition: background var(--transition), color var(--transition), border-color var(--transition), padding-left var(--transition);
}

.nav-dropdown-menu a:hover,
.nav-dropdown-menu a.actif {
    background: rgba(3, 105, 161, .08);
    color: var(--cyan);
    border-left-color: var(--cyan);
    padding-left: 1.15rem;
}
[data-theme="sombre"] .nav-dropdown-menu a:hover,
[data-theme="sombre"] .nav-dropdown-menu a.actif {
    background: rgba(69, 123, 157, .12);
    color: #457b9d;
    border-left-color: #457b9d;
    padding-left: 1.15rem;
}

/* Actions header (thème + CTA) */
.header-actions {
    display: flex;
    align-items: center;
    gap: .5rem;
    flex-shrink: 0;
}

.btn-theme {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px; height: 38px;
    background: rgba(0,194,203,.08);
    border: 1px solid var(--bord);
    border-radius: var(--rayon);
    color: var(--texte2);
    transition: all var(--transition);
    cursor: pointer;
}
.btn-theme:hover {
    background: rgba(0,194,203,.15);
    color: var(--cyan);
    border-color: var(--bord-fort);
}

/* Hamburger mobile */
.btn-hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 38px; height: 38px;
    background: rgba(0,194,203,.08);
    border: 1px solid var(--bord);
    border-radius: var(--rayon);
    padding: 0 8px;
    cursor: pointer;
    transition: background var(--transition);
}
.btn-hamburger span {
    display: block;
    width: 100%; height: 2px;
    background: var(--texte2);
    border-radius: 2px;
    transition: all var(--transition);
}
.btn-hamburger:hover { background: rgba(0,194,203,.15); }
.btn-hamburger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.btn-hamburger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.btn-hamburger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Overlay mobile */
.nav-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.5);
    z-index: 190;
}
.nav-overlay.actif { display: block; }

/* Menu mobile */
.nav-mobile {
    position: fixed;
    top: 0; right: 0;
    height: 100%;
    width: min(320px, 85vw);
    background: var(--bg2);
    border-left: 1px solid var(--bord);
    z-index: 195;
    padding: 5rem 1.5rem 2rem;
    transform: translateX(100%);
    transition: transform var(--transition);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: .25rem;
}
.nav-mobile.ouvert { transform: translateX(0); }
.nav-mobile a {
    display: block;
    padding: .7rem 1rem;
    border-radius: var(--rayon);
    color: var(--texte2);
    font-weight: 500;
    font-size: .9rem;
    transition: all var(--transition);
}
.nav-mobile a:hover, .nav-mobile a.actif {
    background: rgba(0,194,203,.08);
    color: var(--cyan);
}

/* ═══════════════════════════════════════════════════════════════
   BOUTONS
   ═══════════════════════════════════════════════════════════════ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    padding: .65rem 1.5rem;
    border-radius: var(--rayon);
    font-family: 'Inter', sans-serif;
    font-size: .9rem;
    font-weight: 600;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all var(--transition);
    white-space: nowrap;
    line-height: 1.4;
}
.btn svg { width: 16px; height: 16px; flex-shrink: 0; }

/* Primaire — dégradé orange→cyan */
.btn-primaire {
    background: var(--grad);
    color: #fff;
    box-shadow: 0 4px 15px rgba(249,115,22,.25);
}
.btn-primaire:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(249,115,22,.35);
    color: #fff;
}

/* Secondaire — contour */
.btn-secondaire {
    background: transparent;
    color: var(--cyan);
    border: 1px solid var(--bord-fort);
}
.btn-secondaire:hover {
    background: rgba(0,194,203,.08);
    border-color: var(--cyan);
}

/* Fantôme blanc */
.btn-fantome {
    background: rgba(255,255,255,.08);
    color: var(--texte);
    border: 1px solid rgba(255,255,255,.15);
    backdrop-filter: blur(6px);
}
.btn-fantome:hover {
    background: rgba(255,255,255,.15);
    color: var(--texte);
}

/* Danger */
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #b91c1c; transform: translateY(-1px); color: #fff; }

.btn-sm { padding: .4rem 1rem; font-size: .8rem; }
.btn-lg { padding: .85rem 2rem; font-size: 1rem; }
.btn-bloc { width: 100%; justify-content: center; }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none !important; }

/* ═══════════════════════════════════════════════════════════════
   CARTES VERRE DÉPOLI
   ═══════════════════════════════════════════════════════════════ */
.carte {
    background: var(--bg2);
    border: 1px solid var(--bord);
    border-radius: var(--rayon-lg);
    overflow: hidden;
    transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
    position: relative;
}
.carte:hover {
    border-color: transparent;
    box-shadow: var(--ombre-lg);
    transform: translateY(-4px);
}

.carte-corps { padding: 1.5rem; position: relative; z-index: 1; }
.carte-entete {
    padding: 1.25rem 1.5rem 0;
    position: relative;
    z-index: 1;
}

/* Carte sans effets hover (zone de formulaire, etc.) */
.carte-statique {
    background: var(--bg2);
    border: 1px solid var(--bord);
    border-radius: var(--rayon-lg);
}
.carte-statique:hover { transform: none; box-shadow: none; }
.carte-statique::before { display: none; }
.carte-statique .carte-corps { position: static; }

/* ═══════════════════════════════════════════════════════════════
   ICÔNE-CARTE (prestations, avantages)
   ═══════════════════════════════════════════════════════════════ */
.icone-carte {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px; height: 52px;
    border-radius: 12px;
    background: var(--grad);
    color: #fff;
    flex-shrink: 0;
    margin-bottom: 1rem;
}
.icone-carte svg { width: 24px; height: 24px; }

/* ═══════════════════════════════════════════════════════════════
   ALERTES & MESSAGES
   ═══════════════════════════════════════════════════════════════ */
.alerte {
    display: flex;
    align-items: flex-start;
    gap: .75rem;
    padding: 1rem 1.25rem;
    border-radius: var(--rayon);
    font-size: .9rem;
    line-height: 1.5;
}
.alerte svg { width: 18px; height: 18px; flex-shrink: 0; margin-top: 1px; }
.alerte-succes   { background: rgba(34,197,94,.1);  border: 1px solid rgba(34,197,94,.25);  color: var(--succes); }
.alerte-danger   { background: rgba(239,68,68,.1);  border: 1px solid rgba(239,68,68,.25);  color: var(--danger); }
.alerte-attention{ background: rgba(245,158,11,.1); border: 1px solid rgba(245,158,11,.25); color: var(--attention); }
.alerte-info     { background: rgba(59,130,246,.1); border: 1px solid rgba(59,130,246,.25); color: var(--info); }

/* ═══════════════════════════════════════════════════════════════
   FORMULAIRES — ÉTIQUETTES FLOTTANTES
   ═══════════════════════════════════════════════════════════════ */
.champ-flottant {
    position: relative;
    margin-bottom: 1.25rem;
}
.champ-flottant label {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: .9rem;
    color: var(--texte2);
    background: transparent;
    padding: 0 .25rem;
    pointer-events: none;
    transition: all .18s ease;
    white-space: nowrap;
}
.champ-flottant textarea ~ label { top: 1rem; transform: none; }
.champ-flottant select ~ label  { top: 50%; transform: translateY(-50%); }

.champ-flottant.actif label,
.champ-flottant input:focus ~ label,
.champ-flottant textarea:focus ~ label {
    top: 0;
    transform: translateY(-50%);
    font-size: .72rem;
    color: var(--cyan);
    background: var(--bg2);
    padding: 0 .35rem;
}
.champ-flottant textarea.actif ~ label { top: 0; transform: translateY(-50%); }

input[type="text"], input[type="email"], input[type="password"],
input[type="number"], input[type="tel"], input[type="date"],
input[type="time"], input[type="url"], textarea, select {
    width: 100%;
    background: var(--bg3);
    border: 1px solid var(--bord);
    border-radius: var(--rayon);
    color: var(--texte);
    padding: .85rem 1rem;
    font-size: .9rem;
    font-family: 'Inter', sans-serif;
    line-height: 1.5;
    transition: border-color var(--transition), box-shadow var(--transition);
    appearance: none;
}
input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: var(--cyan);
    box-shadow: 0 0 0 3px rgba(0,194,203,.12);
}
textarea { resize: vertical; min-height: 120px; }
select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238baabb' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}
input::placeholder, textarea::placeholder { color: transparent; }

/* Champ standard (sans étiquette flottante) */
.champ-std { margin-bottom: 1.25rem; }
.champ-std label {
    display: block;
    font-size: .82rem;
    font-weight: 500;
    color: var(--texte2);
    margin-bottom: .4rem;
}
.champ-std .aide { font-size: .75rem; color: var(--texte2); margin-top: .3rem; }
.champ-std .erreur { font-size: .75rem; color: var(--danger); margin-top: .3rem; }

/* Pot de miel — invisible */
.pot-miel { position: absolute; left: -9999px; top: -9999px; opacity: 0; pointer-events: none; }

/* ═══════════════════════════════════════════════════════════════
   SECTIONS DE PAGE
   ═══════════════════════════════════════════════════════════════ */
.section {
    padding: 5rem 0;
    position: relative;
}
.section-titre {
    text-align: center;
    margin-bottom: 3rem;
}
.section-titre h2 {
    margin-bottom: .75rem;
}
.section-titre p {
    color: var(--texte2);
    max-width: 600px;
    margin-inline: auto;
}

.section-alt { background: var(--bg2); }
.section-fonce { background: var(--bg3); }

/* Accroche au-dessus du titre */
.surtitre {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--orange);
    margin-bottom: .75rem;
}
.surtitre::before, .surtitre::after {
    content: '';
    display: block;
    height: 1px;
    width: 24px;
    background: var(--orange);
}

/* ═══════════════════════════════════════════════════════════════
   HERO
   ═══════════════════════════════════════════════════════════════ */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 8rem 0 5rem;
    position: relative;
    overflow: hidden;
}

.hero-contenu {
    max-width: 650px;
}
.hero-contenu h1 {
    margin-bottom: 1.25rem;
}
.hero-contenu p {
    font-size: 1.1rem;
    color: var(--texte2);
    margin-bottom: 2rem;
    max-width: 520px;
}
.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .75rem;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    background: rgba(0,194,203,.08);
    border: 1px solid var(--bord);
    border-radius: 99px;
    padding: .35rem 1rem;
    font-size: .78rem;
    font-weight: 600;
    color: var(--cyan);
    margin-bottom: 1.25rem;
}
.hero-badge::before {
    content: '';
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--cyan);
    box-shadow: 0 0 6px var(--cyan);
    animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: .5; transform: scale(.75); }
}

/* ═══════════════════════════════════════════════════════════════
   FIL D'ARIANE
   ═══════════════════════════════════════════════════════════════ */
.fil-ariane {
    padding: 1rem 0;
    margin-bottom: .5rem;
}
.fil-ariane ol {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: .25rem;
    align-items: center;
    font-size: .82rem;
    color: var(--texte2);
}
.fil-ariane a { color: var(--texte2); }
.fil-ariane a:hover { color: var(--cyan); }
.fil-ariane [aria-current="page"] { color: var(--cyan); font-weight: 500; }

/* ═══════════════════════════════════════════════════════════════
   BLOCS DE CONTENU (page.php)
   ═══════════════════════════════════════════════════════════════ */
.contenu-blocs { max-width: 780px; }

.bloc-texte { margin-bottom: 2rem; }
.bloc-texte p { color: var(--texte2); line-height: 1.8; }
.bloc-texte ul, .bloc-texte ol {
    padding-left: 1.5rem;
    color: var(--texte2);
    line-height: 1.8;
}
.bloc-texte li + li { margin-top: .35rem; }
.bloc-texte a { color: var(--cyan); }

.bloc-image { margin-bottom: 2rem; }
.bloc-image img {
    width: 100%;
    border-radius: var(--rayon-lg);
    border: 1px solid var(--bord);
}
.bloc-image figcaption {
    font-size: .8rem;
    color: var(--texte2);
    margin-top: .5rem;
    text-align: center;
}

.bloc-cta {
    background: var(--bg2);
    border: 1px solid var(--bord);
    border-radius: var(--rayon-lg);
    padding: 2rem;
    text-align: center;
    margin-bottom: 2rem;
}

.bloc-separateur {
    border: none;
    border-top: 1px solid var(--bord);
    margin: 2rem 0;
}

/* Image absente */
.img-absente {
    width: 100%;
    aspect-ratio: 16/9;
    background: repeating-linear-gradient(
        45deg,
        var(--bg3) 0px,
        var(--bg3) 8px,
        var(--bg2) 8px,
        var(--bg2) 16px
    );
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .75rem;
    color: var(--texte3);
    font-size: .85rem;
}
.img-absente svg { width: 32px; height: 32px; opacity: .4; }

/* ═══════════════════════════════════════════════════════════════
   ACCORDÉON FAQ
   ═══════════════════════════════════════════════════════════════ */
.accordeon {
    display: flex;
    flex-direction: column;
    gap: .75rem;
}
.accordeon-item {
    background: var(--bg2);
    border: 1px solid var(--bord);
    border-radius: var(--rayon-lg);
    overflow: hidden;
}
.accordeon-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.1rem 1.5rem;
    background: none;
    border: none;
    color: var(--texte);
    font-size: 1rem;
    font-weight: 600;
    font-family: 'Sora', sans-serif;
    text-align: left;
    cursor: pointer;
    transition: color var(--transition);
}
.accordeon-btn:hover { color: var(--cyan); }
.accordeon-btn svg {
    width: 18px; height: 18px;
    flex-shrink: 0;
    color: var(--cyan);
    transition: transform var(--transition);
}
.accordeon-btn[aria-expanded="true"] svg { transform: rotate(45deg); }
.accordeon-panel {
    max-height: 0;
    overflow: hidden;
    transition: max-height .3s ease;
}
.accordeon-panel-inner {
    padding: 0 1.5rem 1.25rem;
    color: var(--texte2);
    line-height: 1.7;
}

/* ═══════════════════════════════════════════════════════════════
   BADGES / STATUTS
   ═══════════════════════════════════════════════════════════════ */
.badge {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    padding: .2em .65em;
    border-radius: 99px;
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .4px;
    text-transform: uppercase;
}
.badge-cyan    { background: rgba(0,194,203,.1);  color: var(--cyan);    border: 1px solid rgba(0,194,203,.2); }
.badge-orange  { background: rgba(249,115,22,.1); color: var(--orange);  border: 1px solid rgba(249,115,22,.2); }
.badge-succes  { background: rgba(34,197,94,.1);  color: var(--succes);  border: 1px solid rgba(34,197,94,.2); }
.badge-danger  { background: rgba(239,68,68,.1);  color: var(--danger);  border: 1px solid rgba(239,68,68,.2); }

/* ═══════════════════════════════════════════════════════════════
   AVERTISSEMENT LÉGAL (simulateur)
   ═══════════════════════════════════════════════════════════════ */
.avertissement-legal {
    background: rgba(245,158,11,.06);
    border: 1px solid rgba(245,158,11,.25);
    border-radius: var(--rayon-lg);
    padding: 1.25rem 1.5rem;
    color: var(--attention);
    font-size: .875rem;
    line-height: 1.6;
    display: flex;
    align-items: flex-start;
    gap: .75rem;
}
.avertissement-legal svg { width: 20px; height: 20px; flex-shrink: 0; margin-top: 1px; }

/* ═══════════════════════════════════════════════════════════════
   PAGINATION
   ═══════════════════════════════════════════════════════════════ */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .35rem;
    flex-wrap: wrap;
    margin-top: 2rem;
}
.pagination a, .pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.2rem;
    height: 2.2rem;
    padding: 0 .5rem;
    border-radius: var(--rayon);
    font-size: .85rem;
    font-weight: 500;
    text-decoration: none;
    border: 1px solid var(--bord);
    color: var(--texte2);
    transition: all var(--transition);
}
.pagination a:hover { background: var(--bg2); color: var(--texte); }
.pagination .courant { background: var(--grad); color: #fff; border: none; font-weight: 700; }
.pagination .desactive { opacity: .35; pointer-events: none; }

/* ═══════════════════════════════════════════════════════════════
   ANIMATION AU SCROLL
   ═══════════════════════════════════════════════════════════════ */
[data-reveal] {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity .6s ease, transform .6s ease;
}
[data-reveal].visible {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    [data-reveal] { opacity: 1; transform: none; }
}

/* ═══════════════════════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════════════════════ */
.site-footer {
    background: var(--bg2);
    border-top: 1px solid var(--bord);
    padding: 4rem 0 2rem;
    margin-top: auto;
}

.footer-grille {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-logo-wrap {
    display: inline-flex;
    background: var(--logo-bg);
    border-radius: 10px;
    padding: 4px;
    overflow: hidden;
    margin-bottom: .75rem;
}
.footer-logo-img {
    height: 52px;
    width: auto;
    display: block;
}

.footer-desc {
    font-size: .85rem;
    color: var(--texte2);
    line-height: 1.6;
    margin-top: .5rem;
}

.footer-titre {
    font-family: 'Sora', sans-serif;
    font-size: .8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--texte2);
    margin-bottom: 1rem;
}

.footer-liens {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: .5rem;
}
.footer-liens a {
    font-size: .85rem;
    color: var(--texte2);
    transition: color var(--transition);
}
.footer-liens a:hover { color: var(--cyan); }

.footer-contact-item {
    display: flex;
    align-items: flex-start;
    gap: .5rem;
    font-size: .85rem;
    color: var(--texte2);
    margin-bottom: .6rem;
}
.footer-contact-item svg { width: 14px; height: 14px; flex-shrink: 0; color: var(--cyan); margin-top: 3px; }
.footer-contact-item a { color: var(--texte2); }
.footer-contact-item a:hover { color: var(--cyan); }

.footer-reseaux {
    display: flex;
    gap: .5rem;
    margin-top: 1rem;
}
.footer-reseaux a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px; height: 36px;
    border-radius: var(--rayon);
    background: rgba(0,194,203,.06);
    border: 1px solid var(--bord);
    color: var(--texte2);
    transition: all var(--transition);
}
.footer-reseaux a:hover {
    background: rgba(0,194,203,.12);
    color: var(--cyan);
    border-color: var(--bord-fort);
}
.footer-reseaux svg { width: 16px; height: 16px; }

.footer-bas {
    border-top: 1px solid var(--bord);
    padding-top: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: .78rem;
    color: var(--texte3);
}
.footer-bas a { color: var(--texte3); }
.footer-bas a:hover { color: var(--cyan); }

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE — 1024px
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 1024px) {
    .footer-grille { grid-template-columns: 1fr 1fr; gap: 2rem; }
    .grille-4 { grid-template-columns: repeat(2, 1fr); }
    .col-7, .col-8 { grid-column: span 12; }
    .col-5, .col-4 { grid-column: span 12; }
    .grille-12 { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE — 820px (hamburger)
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 820px) {
    .nav-principale { display: none; }
    .btn-hamburger { display: flex; }
    .grille-3 { grid-template-columns: repeat(2, 1fr); }
    .section { padding: 3.5rem 0; }
    .hero { padding: 6rem 0 3.5rem; }
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE — 560px
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 560px) {
    .conteneur { padding-inline: 1rem; }
    .grille-2, .grille-3, .grille-4 { grid-template-columns: 1fr; }
    .footer-grille { grid-template-columns: 1fr; gap: 2rem; }
    .btn { width: 100%; justify-content: center; }
    .hero-actions .btn { width: auto; min-width: 0; }
    h1 { font-size: 1.9rem; }
    h2 { font-size: 1.5rem; }
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE — 360px
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 360px) {
    .btn { font-size: .82rem; padding: .6rem 1rem; }
    .logo-img { height: 75px; }
    .section { padding: 2.5rem 0; }
}

/* ═══════════════════════════════════════════════════════════════
   UTILITAIRES
   ═══════════════════════════════════════════════════════════════ */
.mt-1 { margin-top: .5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: .5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.flex { display: flex; }
.flex-centre { align-items: center; }
.flex-entre { justify-content: space-between; }
.gap-1 { gap: .5rem; }
.gap-2 { gap: 1rem; }
.sr-only {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
}

/* Page principale (espace header fixe) */
.page-principale { padding-top: 80px; }

/* ═══════════════════════════════════════════════════════════════
   SIMULATEUR DE CHANTIER
   ═══════════════════════════════════════════════════════════════ */

/* ── Progression ─────────────────────────────────────────────── */
.sim-progression {
    margin-bottom: 2rem;
}
.sim-prog-barre {
    height: 4px;
    background: var(--bord);
    border-radius: 99px;
    margin-bottom: .6rem;
    overflow: hidden;
}
.sim-prog-remplissage {
    height: 100%;
    background: var(--grad);
    border-radius: 99px;
    transition: width .4s ease;
}
.sim-prog-etiquettes {
    display: flex;
    justify-content: space-between;
    font-size: .75rem;
    color: var(--texte2);
    font-family: 'Inter', sans-serif;
}
.sim-prog-etiquettes [data-etape] {
    transition: color .2s;
    text-align: center;
    flex: 1;
}
.sim-prog-etiquettes [data-etape].actif {
    color: var(--cyan);
    font-weight: 600;
}
.sim-prog-etiquettes [data-etape].fait {
    color: var(--succes);
}

/* ── Conteneur étapes ───────────────────────────────────────── */
#sim-conteneur {
    background: var(--bg2);
    border: 1px solid var(--bord);
    border-radius: var(--rayon-lg);
    padding: 2rem;
    margin-bottom: 1.5rem;
    min-height: 300px;
}

/* ── Titres ─────────────────────────────────────────────────── */
.sim-h2 {
    font-family: 'Sora', sans-serif;
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 1.25rem;
}

/* ── Grille 2 colonnes simulateur ───────────────────────────── */
.sim-grille-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-bottom: 1rem;
}
@media (max-width: 560px) {
    .sim-grille-2 { grid-template-columns: 1fr; }
}

/* ── Champs simulateur ──────────────────────────────────────── */
.sim-label {
    display: block;
    font-size: .85rem;
    font-weight: 500;
    color: var(--texte2);
    margin-bottom: .35rem;
    font-family: 'Inter', sans-serif;
}
.sim-input, .sim-select {
    width: 100%;
    padding: .6rem .85rem;
    background: var(--bg3);
    border: 1px solid var(--bord-fort);
    border-radius: var(--rayon);
    color: var(--texte);
    font-family: 'Inter', sans-serif;
    font-size: .9rem;
    transition: border-color .2s, box-shadow .2s;
    box-sizing: border-box;
    appearance: none;
}
.sim-input:focus, .sim-select:focus {
    outline: none;
    border-color: var(--cyan);
    box-shadow: 0 0 0 3px rgba(69, 123, 157, .18);
}
.sim-select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23888' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right .75rem center;
    padding-right: 2rem;
    cursor: pointer;
}

/* ── Erreurs de validation ───────────────────────────────────── */
.sim-erreur {
    color: var(--danger);
    font-size: .8rem;
    margin-top: .3rem;
    font-family: 'Inter', sans-serif;
}

/* ── Choix type de bien ─────────────────────────────────────── */
.sim-choix-grille {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: .75rem;
    margin-bottom: 1rem;
}
.sim-choix {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .6rem;
    padding: 1.25rem .75rem;
    background: var(--bg3);
    border: 2px solid var(--bord);
    border-radius: var(--rayon-lg);
    cursor: pointer;
    transition: border-color .2s, background .2s, transform .15s;
    text-align: center;
}
.sim-choix:hover {
    border-color: var(--cyan);
    background: var(--bg-glass2);
}
.sim-choix.selectionne {
    border-color: var(--cyan);
    background: rgba(69, 123, 157, .12);
    box-shadow: 0 0 0 3px rgba(69, 123, 157, .15);
}
.sim-choix-icone {
    width: 48px; height: 48px;
    color: var(--cyan);
}
.sim-choix-icone svg { width: 100%; height: 100%; }
.sim-choix-label {
    font-size: .8rem;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    color: var(--texte);
    line-height: 1.3;
}

/* ── Pièces – saisie ─────────────────────────────────────────── */
.sim-piece-saisie {
    background: var(--bg3);
    border: 1px solid var(--bord);
    border-radius: var(--rayon);
    padding: 1.25rem;
    margin-bottom: 1rem;
}
.sim-piece-titre {
    display: flex;
    align-items: center;
    gap: .5rem;
    font-family: 'Sora', sans-serif;
    font-weight: 700;
    font-size: .95rem;
    margin-bottom: .9rem;
    color: var(--cyan);
}

/* ── Navigation ─────────────────────────────────────────────── */
.sim-navigation {
    display: flex;
    align-items: center;
    gap: .75rem;
    flex-wrap: wrap;
}

/* ── Spinner ─────────────────────────────────────────────────── */
.sim-spinner {
    width: 40px; height: 40px;
    border: 3px solid var(--bord);
    border-top-color: var(--cyan);
    border-radius: 50%;
    animation: sim-spin .7s linear infinite;
    margin: 0 auto;
}
@keyframes sim-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
    .sim-spinner { animation: none; opacity: .5; }
}

/* ── Résultats – pièces ─────────────────────────────────────── */
.sim-pieces-grille {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: .75rem;
    margin-bottom: 1.5rem;
}
.sim-piece-res {
    background: var(--bg3);
    border: 1px solid var(--bord);
    border-radius: var(--rayon);
    padding: 1rem;
}
.sim-piece-res-nom {
    font-weight: 600;
    font-size: .9rem;
    margin-bottom: .15rem;
    font-family: 'Sora', sans-serif;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.sim-piece-res-surface {
    font-size: .78rem;
    color: var(--texte2);
    margin-bottom: .5rem;
}
.sim-piece-res-puissance {
    font-size: 1.1rem;
    font-family: 'Sora', sans-serif;
    margin-bottom: .5rem;
}
.sim-piece-res-barre {
    height: 4px;
    background: var(--bord);
    border-radius: 99px;
    overflow: hidden;
}
.sim-piece-res-remplissage {
    height: 100%;
    border-radius: 99px;
    transition: width .5s ease;
}

/* ── Résultats – total ──────────────────────────────────────── */
.sim-res-total {
    margin-bottom: 1.5rem;
}
.sim-res-total-inner {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 1rem;
}
.sim-res-stat {
    background: var(--bg3);
    border: 1px solid var(--bord);
    border-radius: var(--rayon);
    padding: 1.1rem 1.25rem;
    text-align: center;
}
.sim-res-stat-val {
    font-family: 'Sora', sans-serif;
    font-size: 1.6rem;
    font-weight: 800;
    background: var(--grad-texte);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: .25rem;
}
.sim-res-stat-lbl {
    font-size: .78rem;
    color: var(--texte2);
    line-height: 1.3;
}

/* ── Budget ─────────────────────────────────────────────────── */
.sim-budget-carte {
    background: linear-gradient(135deg, rgba(230,57,70,.07) 0%, rgba(69,123,157,.07) 100%);
    border: 1px solid var(--bord);
    border-radius: var(--rayon-lg);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}
.sim-budget-montant {
    display: flex;
    align-items: center;
    gap: .75rem;
    flex-wrap: wrap;
    font-family: 'Sora', sans-serif;
    font-size: 1.8rem;
    font-weight: 800;
}
.sim-budget-sep {
    color: var(--texte3);
}

/* ── Section 3D ─────────────────────────────────────────────── */
.sim-3d-section {
    background: var(--bg3);
    border: 1px solid var(--bord);
    border-radius: var(--rayon-lg);
    padding: 1.5rem;
    margin-top: 1.5rem;
}
.sim-3d-conteneur {
    min-height: 260px;
    border-radius: var(--rayon);
    overflow: hidden;
    background: var(--bg2);
    border: 1px solid var(--bord);
    color: var(--texte);
}
.sim-3d-conteneur canvas {
    display: block;
    width: 100% !important;
}
#sim-2d-plan svg {
    color: var(--texte);
}

/* ── Légende couleurs ───────────────────────────────────────── */
.sim-legende {
    display: flex;
    flex-wrap: wrap;
    gap: .6rem 1.2rem;
    margin-top: .75rem;
    font-size: .78rem;
    font-family: 'Inter', sans-serif;
    color: var(--texte2);
}
.sim-leg-item {
    display: flex;
    align-items: center;
    gap: .35rem;
}
.sim-leg-coul {
    display: inline-block;
    width: 12px; height: 12px;
    border-radius: 3px;
    flex-shrink: 0;
}
