/* =====================================================================
   DESIGN 2027 — couche commune à toutes les pages de camera-geneve.ch
   Ce fichier ne change AUCUN texte ni aucune balise : uniquement l'apparence.
   Il est chargé après les styles de chaque page (voir header.php).
   ===================================================================== */

:root {
    --hw-ink: #07111f;
    --hw-navy: #0b1f3a;
    --hw-blue: #00457C;
    --hw-blue-vif: #1d7fd6;
    --hw-orange: #FF6600;
    --hw-orange-clair: #ff9a4d;
    --hw-text: #1c2a3a;
    --hw-muted: #5d6b7a;
    --hw-line: #e3e8ef;
    --hw-ease: cubic-bezier(.2, .7, .2, 1);
    --text-dark: #1c2a3a;
}

/* ---------- 1. BASE : typographie et confort de lecture ---------- */
html { scroll-behavior: smooth; scroll-padding-top: 90px; -webkit-text-size-adjust: 100%; }
body { font-family: var(--font-texte); color: var(--hw-text); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; font-feature-settings: 'cv11', 'ss01'; }
h1, h2, h3, h4, h5, .btn, .nav-links a, .logo { font-family: var(--font-titre); }
h1, h2, h3 { letter-spacing: -0.022em; text-wrap: balance; }
h1 { letter-spacing: -0.032em; }
p, li { text-wrap: pretty; }
::selection { background: var(--hw-orange); color: #fff; }
:focus-visible { outline: 3px solid var(--hw-orange-clair); outline-offset: 3px; border-radius: 6px; }

/* Barre de défilement discrète (PC) */
@media (min-width: 993px) {
    html { scrollbar-color: #9fb0c3 transparent; scrollbar-width: thin; }
}

/* ---------- 2. BOUTONS ---------- */
.btn { text-transform: none; letter-spacing: 0; font-size: 0.95rem; font-weight: 700; transition: transform .3s var(--hw-ease), box-shadow .3s var(--hw-ease), background .3s, color .3s, border-color .3s; }
.btn-orange { background: linear-gradient(135deg, #ff6600, #ff8a1f); box-shadow: 0 8px 22px -8px rgba(255, 102, 0, 0.65); }
.btn-orange:hover { background: linear-gradient(135deg, #f25f00, #ff7a00); box-shadow: 0 14px 28px -10px rgba(255, 102, 0, 0.75); }
#mainHeader .nav-cta { text-transform: none !important; letter-spacing: 0 !important; font-size: 0.9rem !important; font-family: var(--font-titre) !important; padding: 11px 22px !important; }

/* ---------- 3. BARRE DU HAUT ---------- */
.top-bar { background: var(--hw-ink); font-size: 0.82rem; padding: 7px 0; border-bottom: 1px solid rgba(255, 255, 255, 0.06); }
.top-info span, .top-info a { color: rgba(255, 255, 255, 0.82); }
.top-info a:hover { color: #fff; }
.top-info i { font-size: 0.85rem; }
.lang-switch a.active { background: linear-gradient(135deg, #ff6600, #ff8a1f); }

/* ---------- 4. EN-TÊTE : toujours opaque, le contenu ne se voit jamais à travers ---------- */
header#mainHeader { background: transparent; box-shadow: none; view-transition-name: hw-header; }
/* Le fond est porté par un calque séparé pour ne pas gêner le menu mobile (position: fixed) */
header#mainHeader::before { content: ''; position: absolute; inset: 0; z-index: -1; background: #fff; border-bottom: 1px solid rgba(15, 27, 43, 0.08); transition: box-shadow .4s; }
header#mainHeader.scrolled::before { box-shadow: 0 12px 32px -16px rgba(7, 17, 31, 0.4); }

/* Logo « lune » : même forme et même halo ; il rétrécit en douceur dans la barre quand on descend
   (il reste en position absolue dans les deux états, sinon le navigateur ne peut pas animer le passage) */
header#mainHeader { transition: height .5s var(--hw-ease); }
@media (min-width: 993px) {
    #mainHeader .logo img { transition: top .5s var(--hw-ease), height .5s var(--hw-ease), width .5s var(--hw-ease), padding .5s var(--hw-ease), box-shadow .5s ease, transform .5s var(--hw-ease); will-change: height, width, top; }
    #mainHeader.scrolled .logo img { position: absolute; top: 9px; left: 0; height: 52px; width: 52px; padding: 2px; background: radial-gradient(circle at 30% 30%, rgba(255,255,255,1) 20%, rgba(245,250,255,0.9) 50%, rgba(255,255,255,0) 75%); box-shadow: 0 0 0 rgba(255, 255, 255, 0), 0 0 14px rgba(180, 220, 255, 0.55), inset 0 0 0 rgba(0,0,0,0); }
    #mainHeader .logo { transition: width .5s var(--hw-ease); }
    #mainHeader.scrolled .logo { width: 70px; }
    #mainHeader .logo a:hover img { transform: rotate(-5deg) scale(1.03); }
}

/* Menu PC : une « capsule » avec la page en cours en pastille blanche */
@media (min-width: 993px) {
    #mainHeader .nav-links { gap: 2px; padding: 5px; border-radius: 50px; background: #f0f3f8; border: 1px solid #e3e9f0; box-shadow: inset 0 1px 2px rgba(7, 17, 31, 0.04); }
    #mainHeader .nav-links > li > a { text-transform: none; letter-spacing: 0; font-weight: 600; font-size: 0.92rem; padding: 8px 15px; border-radius: 50px; color: #33465c; transition: background .25s, color .25s, box-shadow .25s; }
    #mainHeader .nav-links > li > a > i:first-child { display: none; }
    #mainHeader .nav-links > li > a::after { display: none; }
    #mainHeader .nav-links > li:hover > a { background: rgba(255, 255, 255, 0.75); color: var(--hw-blue); }
    #mainHeader .nav-links > li > a.active { background: #fff; color: var(--hw-blue); font-weight: 700; box-shadow: 0 2px 8px rgba(7, 17, 31, 0.12), 0 0 0 1px rgba(7, 17, 31, 0.04); }
    #mainHeader .pc-chevron { transition: transform .3s var(--hw-ease); }
    #mainHeader .nav-links > li:hover .pc-chevron { transform: rotate(180deg); color: var(--hw-orange) !important; }
    #mainHeader .dropdown { left: 0; top: 100%; margin-top: 0; border-radius: 16px; padding: 8px; border: 1px solid var(--hw-line); box-shadow: 0 24px 50px -20px rgba(7, 17, 31, 0.35); border-top: 10px solid transparent; background-clip: padding-box; }
    #mainHeader .dropdown li a { border-bottom: none; border-radius: 10px; padding: 10px 12px; font-weight: 600; }
    #mainHeader .dropdown li a:hover { padding-left: 12px; background: rgba(255, 102, 0, 0.08); }
    #mainHeader .nav-cta { margin-left: 12px !important; }
}
@media (min-width: 993px) and (max-width: 1280px) {
    #mainHeader .nav-links > li > a { font-size: 0.84rem; padding: 7px 10px; }
    #mainHeader .nav-cta { padding: 9px 15px !important; font-size: 0.82rem !important; margin-left: 8px !important; }
}
@media (min-width: 993px) and (max-width: 1100px) {
    #mainHeader .nav-links { gap: 0; padding: 4px; }
    #mainHeader .nav-links > li > a { font-size: 0.77rem; padding: 6px 7px; }
    #mainHeader .nav-cta { padding: 8px 11px !important; font-size: 0.76rem !important; margin-left: 4px !important; }
}

/* Mobile : vraie barre fixe avec le logo, au lieu du bouton flottant seul */
@media (max-width: 992px) {
    header#mainHeader { position: fixed; top: 0; left: 0; height: 60px; width: 100%; }
    header#mainHeader::before { box-shadow: 0 8px 24px -16px rgba(7, 17, 31, 0.45); }
    #mainHeader .navbar { align-items: center; padding: 0 16px; }
    #mainHeader .logo { display: flex; height: 60px; width: auto; }
    #mainHeader .logo img { position: static; height: 46px; width: 46px; padding: 2px; box-shadow: 0 0 18px rgba(180, 220, 255, 0.9); }
    #mainHeader .burger { top: 9px; right: 10px; background: transparent; box-shadow: none; padding: 8px; }
    #mainHeader .burger span { height: 2.5px; margin: 5.5px; }
    #mainHeader .nav-menu-wrapper { height: 100dvh; padding-top: 76px; }
    #mainHeader .nav-links > li > a { text-transform: none; letter-spacing: 0; font-weight: 700; }
    #mainHeader .mobile-toggle-btn { background: transparent; border-left: none; }
}

/* ---------- 5. TITRES DE SECTION (accueil) ---------- */
.text-center { text-align: center; }
.section-title { font-size: clamp(1.75rem, 3.4vw, 2.6rem); font-weight: 800; line-height: 1.15; color: var(--hw-ink); margin: 0 0 14px; }
.section-title.text-white-alt { color: #fff; }
.section-subtitle { font-size: 1.08rem; color: var(--hw-muted); max-width: 680px; margin: 0 auto; }
.section-subtitle.text-white-opacity { color: rgba(255, 255, 255, 0.78); }
.section-padding { padding: clamp(60px, 8vw, 104px) 0; }

/* ---------- 6. ACCUEIL : bandeau principal ---------- */
.hero { height: auto; min-height: 0; padding: 180px 0 170px; text-align: left; isolation: isolate; }
.hero-overlay { background:
    radial-gradient(700px 420px at 12% 100%, rgba(255, 102, 0, 0.20), rgba(255, 102, 0, 0) 70%),
    linear-gradient(105deg, rgba(5, 14, 28, 0.96) 0%, rgba(7, 20, 40, 0.86) 44%, rgba(0, 69, 124, 0.30) 100%); }
/* Quadrillage technique très discret */
.hero-overlay::after { content: ''; position: absolute; inset: 0; background-image: linear-gradient(rgba(255, 255, 255, 0.055) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.055) 1px, transparent 1px); background-size: 56px 56px; -webkit-mask-image: radial-gradient(900px 520px at 20% 45%, #000 0%, transparent 78%); mask-image: radial-gradient(900px 520px at 20% 45%, #000 0%, transparent 78%); }
.hero .hero-content { max-width: 1300px; width: 100%; margin: 0 auto; }
.hero-tag { display: inline-flex; align-items: center; gap: 10px; background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.22); color: #fff; padding: 7px 16px; border-radius: 50px; font-family: var(--font-titre); font-size: 0.76rem; letter-spacing: 0.16em; margin-bottom: 26px; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.hero-tag::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: #ff3b30; box-shadow: 0 0 0 0 rgba(255, 59, 48, 0.7); animation: hw-rec 1.8s ease-out infinite; }
.hero-content h1 { font-size: clamp(2.3rem, 5.4vw, 4.7rem); line-height: 1.03; font-weight: 800; letter-spacing: -0.04em; margin: 0 0 26px; max-width: 900px; text-shadow: none; color: #fff; }
@supports ((-webkit-background-clip: text) or (background-clip: text)) {
    .hero-content h1 { background: linear-gradient(100deg, #ffffff 30%, #b9d8ff 75%, #ffc89c 110%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; padding-bottom: 0.08em; }
}
.hero-content p { font-size: clamp(1.05rem, 1.5vw, 1.25rem); line-height: 1.6; color: rgba(255, 255, 255, 0.82); max-width: 640px; margin: 0 0 40px; }
.hero-buttons { justify-content: flex-start; gap: 14px; flex-wrap: wrap; }
.btn-hero-primary, .btn-hero-secondary { text-transform: none; letter-spacing: 0; font-size: 1rem; padding: 15px 28px; }
.btn-hero-primary { background: linear-gradient(135deg, #ff6600, #ff8a1f); border-color: transparent; box-shadow: 0 14px 32px -10px rgba(255, 102, 0, 0.7); }
.btn-hero-primary:hover { background: linear-gradient(135deg, #f25f00, #ff7a00); color: #fff; }
.btn-hero-secondary { background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.32); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.btn-hero-primary i { transition: transform .3s var(--hw-ease); }
.btn-hero-primary:hover i { transform: translateY(3px); }

/* Viseur de caméra (décor, PC uniquement) */
@media (min-width: 1100px) {
    .hero::after { content: ''; position: absolute; z-index: 1; right: max(4vw, calc((100vw - 1300px) / 2 + 20px)); top: 50%; width: min(34vw, 470px); aspect-ratio: 16 / 10; transform: translateY(-58%); pointer-events: none; opacity: 0.85;
        --b: rgba(255, 255, 255, 0.85); --l: 34px; --t: 2px;
        background:
            linear-gradient(var(--b), var(--b)) left top / var(--l) var(--t), linear-gradient(var(--b), var(--b)) left top / var(--t) var(--l),
            linear-gradient(var(--b), var(--b)) right top / var(--l) var(--t), linear-gradient(var(--b), var(--b)) right top / var(--t) var(--l),
            linear-gradient(var(--b), var(--b)) left bottom / var(--l) var(--t), linear-gradient(var(--b), var(--b)) left bottom / var(--t) var(--l),
            linear-gradient(var(--b), var(--b)) right bottom / var(--l) var(--t), linear-gradient(var(--b), var(--b)) right bottom / var(--t) var(--l),
            linear-gradient(rgba(255, 138, 31, 0), rgba(255, 150, 60, 0.75), rgba(255, 138, 31, 0)) center 0 / 92% 3px;
        background-repeat: no-repeat; animation: hw-scan 5s ease-in-out infinite alternate; }
}
@keyframes hw-scan { from { background-position: left top, left top, right top, right top, left bottom, left bottom, right bottom, right bottom, center 6%; } to { background-position: left top, left top, right top, right top, left bottom, left bottom, right bottom, right bottom, center 94%; } }
@keyframes hw-rec { 0% { box-shadow: 0 0 0 0 rgba(255, 59, 48, 0.7); } 100% { box-shadow: 0 0 0 10px rgba(255, 59, 48, 0); } }

/* ---------- 7. ACCUEIL : atouts (cartes posées sur le bandeau) ---------- */
.trust-bar { background: transparent; padding: 0; margin-top: -84px; margin-bottom: -84px; box-shadow: none; }
.trust-grid { grid-template-columns: repeat(4, 1fr); gap: 18px; align-items: stretch; }
.trust-item { justify-content: flex-start; background: rgba(255, 255, 255, 0.96); border: 1px solid rgba(255, 255, 255, 0.7); border-radius: 18px; padding: 20px; box-shadow: 0 20px 44px -18px rgba(7, 17, 31, 0.35); transition: transform .35s var(--hw-ease), box-shadow .35s var(--hw-ease); }
.trust-item:hover { transform: translateY(-5px); box-shadow: 0 28px 54px -20px rgba(7, 17, 31, 0.45); }
.trust-icon { width: 50px; height: 50px; border-radius: 14px; font-size: 1.2rem; margin-right: 14px; color: var(--hw-orange); background: rgba(255, 102, 0, 0.1); }
.trust-content h4 { color: var(--hw-ink); text-transform: none; letter-spacing: -0.01em; font-size: 1.02rem; font-weight: 800; line-height: 1.25; }
.trust-content p { color: var(--hw-muted); font-size: 0.86rem; margin-top: 2px; }
#services.section-padding { padding-top: calc(84px + clamp(60px, 8vw, 104px)); }
.bg-light-alt { background: linear-gradient(180deg, #f3f6fa 0%, #f8fafc 100%); border: none; }
@media (max-width: 1100px) { .trust-grid { grid-template-columns: repeat(2, 1fr); } }

@media (max-width: 992px) {
    .hero { min-height: 0; padding: 116px 0 130px; }
    .hero-content h1 { font-size: clamp(2.1rem, 9.4vw, 3rem); }
    .hero-buttons { margin: 0; max-width: none; flex-direction: column; }
    .trust-bar { margin-top: -70px; margin-bottom: -70px; }
    #services.section-padding { padding-top: 130px; }
}
@media (max-width: 560px) {
    .trust-grid { gap: 10px; }
    .trust-item { flex-direction: column; align-items: flex-start; padding: 16px 14px; border-radius: 16px; }
    .trust-icon { margin: 0 0 10px; width: 42px; height: 42px; font-size: 1.05rem; border-radius: 12px; }
    .trust-content h4 { font-size: 0.92rem; }
    .trust-content p { font-size: 0.78rem; }
}

/* ---------- 7b. ACCUEIL : la famille IA Dahua en onglets (un seul bloc à la fois) ---------- */
.feature-section { background: radial-gradient(900px 500px at 90% 0%, rgba(29, 127, 214, 0.22), rgba(0, 0, 0, 0) 70%), linear-gradient(180deg, #0a2140 0%, #071528 100%); }
.tech-divider span { background: transparent; color: rgba(255, 255, 255, 0.75); font-family: var(--font-titre); font-weight: 700; font-size: 0.8rem; letter-spacing: 0.2em; }
.tech-divider::before { display: none; }
.tech-divider { margin: 84px 0 26px; }
.feature-text h2 { line-height: 1.12; font-size: clamp(1.9rem, 3.4vw, 2.7rem); }
.wiz-tabs { display: flex; gap: 4px; padding: 5px; margin: 0 auto 26px; width: fit-content; max-width: 100%; border-radius: 50px; background: rgba(255, 255, 255, 0.07); border: 1px solid rgba(255, 255, 255, 0.12); }
.wiz-tab { display: inline-flex; align-items: center; gap: 9px; padding: 11px 22px; border: 0; border-radius: 50px; background: transparent; color: rgba(255, 255, 255, 0.72); font: 700 0.98rem var(--font-titre); cursor: pointer; white-space: nowrap; transition: background .3s, color .3s, box-shadow .3s; }
.wiz-tab i { color: var(--hw-orange-clair); font-size: 0.95rem; transition: color .3s; }
.wiz-tab:hover { color: #fff; background: rgba(255, 255, 255, 0.08); }
.wiz-tab[aria-selected="true"] { background: #fff; color: var(--hw-ink); box-shadow: 0 8px 22px -8px rgba(0, 0, 0, 0.6); }
.wiz-tab[aria-selected="true"] i { color: var(--hw-orange); }
.wiz-tab-new { width: 8px; height: 8px; border-radius: 50%; background: var(--hw-orange); box-shadow: 0 0 0 4px rgba(255, 102, 0, 0.25); }

.wiz-family-grid.wiz-tabbed { display: block; }
.wiz-tabbed > .wiz-card { display: none; }
.wiz-tabbed > .wiz-card.is-active { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: 56px; align-items: start; padding: 44px 46px 34px; border-radius: 26px; background: linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.025)); border-color: rgba(255, 255, 255, 0.12); animation: hw-tab .45s var(--hw-ease) both; }
.wiz-tabbed > .wiz-card:hover { transform: none; border-color: rgba(255, 255, 255, 0.12); box-shadow: none; }
.wiz-tabbed > .wiz-card::before { display: none; }
.wiz-tabbed > .wiz-card > * { grid-column: 1; }
.wiz-tabbed .wiz-card-head { justify-content: flex-start; gap: 14px; margin-bottom: 20px; }
.wiz-tabbed .wiz-card h3 { font-size: clamp(1.8rem, 3vw, 2.5rem); line-height: 1.08; margin-bottom: 16px; }
.wiz-tabbed .wiz-card-lead { font-size: 1.08rem; line-height: 1.65; color: rgba(255, 255, 255, 0.8); margin-bottom: 0; }
.wiz-tabbed .wiz-card-foot { margin-top: 28px; padding-top: 18px; font-size: 0.9rem; }
/* Colonne de droite : les points forts en tuiles aérées */
.wiz-tabbed > .wiz-card:not(.wiz-card-featured) > .wiz-features { grid-column: 2; grid-row: 1 / span 4; align-self: center; gap: 12px; margin: 0; }
.wiz-tabbed .wiz-features li { padding: 16px 18px; border-radius: 16px; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.08); align-items: center; transition: background .3s, transform .3s var(--hw-ease); }
.wiz-tabbed .wiz-features li:hover { background: rgba(255, 255, 255, 0.09); transform: translateX(4px); }
.wiz-tabbed .wiz-features strong { font-size: 1.02rem; }
.wiz-tabbed .wiz-features small { font-size: 0.88rem; color: rgba(255, 255, 255, 0.65); }
.wiz-tabbed .wiz-picto { width: 44px; height: 44px; border-radius: 12px; background: rgba(255, 102, 0, 0.14); border-color: rgba(255, 102, 0, 0.25); }
/* WizSeek : texte à gauche, image à droite, puis les détails en dessous */
.wiz-tabbed > .wiz-card-featured > .wiz-visual { grid-column: 2; grid-row: 1 / span 3; align-self: center; margin: 0; border-radius: 18px; }
.wiz-tabbed > .wiz-card-featured > .wiz-modes,
.wiz-tabbed > .wiz-card-featured > .wiz-ivs-note,
.wiz-tabbed > .wiz-card-featured > .wiz-features,
.wiz-tabbed > .wiz-card-featured > .wiz-card-foot { grid-column: 1 / -1; }
.wiz-tabbed .wiz-modes { margin: 36px 0 14px; gap: 14px; }
.wiz-tabbed .wiz-mode { background: rgba(255, 255, 255, 0.05); border-color: rgba(255, 255, 255, 0.08); border-radius: 18px; padding: 22px; }
.wiz-tabbed .wiz-mode p { font-size: 0.93rem; margin-bottom: 14px; }
.wiz-tabbed .wiz-examples li { font-style: normal; background: rgba(255, 255, 255, 0.07); border-color: rgba(255, 255, 255, 0.14); font-size: 0.84rem; padding: 6px 13px; }
.wiz-tabbed .wiz-ivs-note { border-left: 0; border-radius: 18px; padding: 18px 22px; align-items: center; background: rgba(255, 102, 0, 0.08); border: 1px solid rgba(255, 102, 0, 0.22); margin-bottom: 14px; }
.wiz-tabbed .wiz-ivs-note p { font-size: 0.92rem; line-height: 1.6; }
.wiz-tabbed .wiz-features.wiz-features-compact { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 0; }
@keyframes hw-tab { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@media (max-width: 992px) {
    .wiz-tabbed > .wiz-card.is-active { grid-template-columns: minmax(0, 1fr); padding: 26px 18px 22px; border-radius: 22px; }
    .wiz-tabbed > .wiz-card:not(.wiz-card-featured) > .wiz-features,
    .wiz-tabbed > .wiz-card-featured > .wiz-visual { grid-column: 1; grid-row: auto; margin-top: 24px; }
    .wiz-tabbed .wiz-card-foot { margin-top: 22px; }
    .wiz-tabbed .wiz-features.wiz-features-compact { grid-template-columns: 1fr; }
    .wiz-tabbed .wiz-ivs-note { flex-direction: column; align-items: flex-start; padding: 18px; }
    .wiz-tabs { width: 100%; }
    .wiz-tab { flex: 1; justify-content: center; padding: 11px 6px; font-size: 0.88rem; gap: 6px; }
    .tech-divider { margin: 60px 0 22px; }
}
@media (max-width: 420px) { .wiz-tab > i { display: none; } }

/* ---------- 8. PAGES INTÉRIEURES : même esprit que l'accueil ---------- */
.cs-hero h1, .inst-hero h1, .al-hero h1, .ab-hero h1, .ct-hero h1, .pv-hero h1 { letter-spacing: -0.035em; }
@media (min-width: 993px) {
    .cs-hero h1, .inst-hero h1, .al-hero h1 { font-size: clamp(2.6rem, 4vw, 3.5rem); line-height: 1.08; }
}

h1 small { letter-spacing: -0.01em; }

/* ---------- 9. MOUVEMENT : technologies natives du navigateur ---------- */
/* a) Transition fluide entre les pages (sans JavaScript) */
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: hw-vt-out .18s ease both; }
::view-transition-new(root) { animation: hw-vt-in .28s ease both; }
@keyframes hw-vt-out { to { opacity: 0; } }
@keyframes hw-vt-in { from { opacity: 0; transform: translateY(8px); } }

@media (prefers-reduced-motion: no-preference) {
    @supports (animation-timeline: view()) {
        /* b) Apparition des blocs au défilement, pilotée par le défilement lui-même */
        [data-aos]:not(.hero) { animation: hw-reveal linear both; animation-timeline: view(); animation-range: entry 0% entry 38%; }
        /* c) Barre de progression de lecture en haut de page */
        body::before { content: ''; position: fixed; z-index: 3000; top: 0; left: 0; right: 0; height: 3px; background: linear-gradient(90deg, #ff6600, #ffb347); transform-origin: 0 50%; transform: scaleX(0); animation: hw-progress linear both; animation-timeline: scroll(root); pointer-events: none; }
    }
}
@keyframes hw-reveal { from { opacity: 0; transform: translateY(30px) scale(0.985); } to { opacity: 1; transform: none; } }
@keyframes hw-progress { to { transform: scaleX(1); } }

/* Respect du réglage « réduire les animations » */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
    @view-transition { navigation: none; }
}
