/* Centre Auto 360 · propositions de logo : loader « plan » puis logos finaux animés */

@font-face { font-family: "Montserrat"; src: url("polices/montserrat-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Montserrat"; src: url("polices/montserrat-800.woff2") format("woff2"); font-weight: 800; font-display: swap; }
@font-face { font-family: "Montserrat"; src: url("polices/montserrat-900.woff2") format("woff2"); font-weight: 900; font-display: swap; }
@font-face { font-family: "Barlow"; src: url("polices/barlow-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Barlow"; src: url("polices/barlow-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }

:root { --rouge: #b20808; --noir: #0b0b0c; --plan: #1747b8; --trait: #eaf2ff; --ease: cubic-bezier(.22, 1, .36, 1); }
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; background: #fff; color: var(--noir); font: 400 16px/1.5 Barlow, system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
body.loading { overflow: hidden; }
.defs { position: absolute; width: 0; height: 0; overflow: hidden; }
svg { display: block; }

/* Couleurs des logos : pilotées par variables, héritées jusque dans les <use> */
.r { fill: var(--lr, #b20808); }
.n { fill: var(--ln, #000); }
.masque { --lr: #fff; --ln: #fff; }
.balayage { opacity: 0; }

/* ---- Plan (phase loader), repris de la présentation NORVA ---- */
#bp { position: fixed; inset: 0; z-index: 0; background-color: var(--plan);
  background-image: linear-gradient(rgba(255,255,255,.22) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.22) 1px, transparent 1px),
    linear-gradient(rgba(255,255,255,.08) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.08) 1px, transparent 1px);
  background-size: 120px 120px, 120px 120px, 24px 24px, 24px 24px; }
@media (max-width: 600px) { #bp { background-size: 80px 80px, 80px 80px, 16px 16px, 16px 16px; } }
#bp::after { content: ""; position: absolute; inset: 0; background: radial-gradient(ellipse at center, transparent 40%, rgba(5, 20, 70, .55)); }
#bp > * { position: absolute; color: var(--trait); font: 500 10px/1.5 Montserrat, Arial, sans-serif; letter-spacing: .18em; }
.bp-ruler { opacity: 0; }
.bp-rx { left: 28px; right: 0; top: 0; height: 22px; border-bottom: 1px solid rgba(234,242,255,.5);
  background: repeating-linear-gradient(90deg, rgba(234,242,255,.7) 0 1px, transparent 1px 10px) bottom/100% 6px no-repeat,
              repeating-linear-gradient(90deg, rgba(234,242,255,.9) 0 1px, transparent 1px 100px) bottom/100% 14px no-repeat; }
.bp-ry { top: 22px; bottom: 0; left: 0; width: 28px; border-right: 1px solid rgba(234,242,255,.5);
  background: repeating-linear-gradient(0deg, rgba(234,242,255,.7) 0 1px, transparent 1px 10px) right/6px 100% no-repeat,
              repeating-linear-gradient(0deg, rgba(234,242,255,.9) 0 1px, transparent 1px 100px) right/14px 100% no-repeat; }
.bp-reg { width: 34px; height: 34px; opacity: 0; border: 1px solid rgba(234,242,255,.8); border-radius: 50%; }
.bp-reg::before, .bp-reg::after { content: ""; position: absolute; background: var(--trait); }
.bp-reg::before { left: 50%; top: 0; bottom: 0; width: 1px; }
.bp-reg::after { top: 50%; left: 0; right: 0; height: 1px; }
.r1 { top: 40px; left: 46px; } .r2 { top: 40px; right: 18px; } .r3 { bottom: 18px; left: 46px; } .r4 { bottom: 18px; right: 18px; }
.bp-scan { left: 0; right: 0; top: 0; height: 120px; background: linear-gradient(180deg, transparent, rgba(234,242,255,.10) 85%, rgba(234,242,255,.5) 100%); opacity: 0; }
.bp-sketch { inset: 0; width: 100%; height: 100%; opacity: .35; }
.bp-specs { top: 66px; left: 52px; width: 230px; opacity: 0; }
.bp-specs b { display: block; font-weight: 800; letter-spacing: .22em; border-bottom: 1px solid rgba(234,242,255,.5); padding-bottom: 6px; margin-bottom: 10px; }
.bp-specs span { display: block; opacity: .6; margin: 12px 0 4px; }
.bp-specs p { margin: 4px 0; display: flex; gap: 8px; align-items: center; min-height: 15px; }
.bp-specs i { width: 12px; height: 12px; border: 1px solid var(--trait); transform: scale(0); }
.bp-specs em, .bp-block em { font-style: normal; }
.bp-coord { top: 66px; right: 28px; display: flex; flex-direction: column; align-items: flex-end; gap: 2px; opacity: 0; }
.bp-coord b { font-weight: 800; display: inline-block; min-width: 62px; text-align: right; }
.bp-block { right: 28px; bottom: 64px; width: 290px; border: 1px solid rgba(234,242,255,.8); opacity: 0; }
.bp-block > div { display: flex; gap: 8px; border-top: 1px solid rgba(234,242,255,.45); padding: 5px 8px; min-height: 24px; }
.bp-block span { opacity: .6; min-width: 58px; }
.bp-block .bk-t { border-top: 0; font: 900 italic 17px/1.2 Montserrat, Arial, sans-serif; letter-spacing: .12em; padding: 8px; }
.bp-steps { left: 50%; bottom: 22px; transform: translateX(-50%); display: flex; gap: 18px; white-space: nowrap; }
.bp-steps span { opacity: .25; transition: opacity .4s; }
.bp-steps span.on { opacity: 1; }
@media (max-width: 900px) { .bp-specs, .bp-block { display: none; } .bp-steps { gap: 10px; font-size: 8px; } }
@media (max-width: 500px) { .bp-coord { top: 46px; font-size: 8px; } .bp-steps span:not(.on) { display: none; } }

#loader { position: fixed; inset: 0; z-index: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: clamp(18px, 5vh, 54px); padding: 70px 20px 60px; }
.ld-logos { display: flex; flex-direction: column; align-items: center; gap: clamp(18px, 4.5vh, 46px); width: min(540px, 80vw, calc(100vh - 300px)); width: min(540px, 80vw, calc(100svh - 300px)); }
.ld-logo { position: relative; width: 100%; display: flex; justify-content: center; }
.ld-logo .logo { width: 100%; height: auto; overflow: visible; }
.ld-logo span { position: absolute; left: -46px; top: 50%; transform: translateY(-50%); font: 900 italic 22px/1 Montserrat, Arial, sans-serif; color: var(--trait); opacity: 0; }
@media (max-width: 700px) { .ld-logo span { left: -4px; top: -14px; transform: none; font-size: 14px; } }
.bar { flex: none; width: min(180px, 40vw); height: 2px; background: rgba(255,255,255,.25); overflow: hidden; }
.bar i { display: block; height: 100%; width: 0; background: var(--trait); }
.passer { position: fixed; right: 24px; bottom: 54px; z-index: 3; background: none; border: 1px solid rgba(234,242,255,.5); color: var(--trait); font: 800 10px/1 Montserrat, Arial, sans-serif; letter-spacing: .2em; text-transform: uppercase; padding: 10px 16px; cursor: pointer; }
.passer:hover { background: rgba(234,242,255,.12); }
@media (max-width: 900px) { .passer { bottom: 46px; right: 16px; } }

/* Traits du plan : contour blanc qui se dessine, puis remplissage aux couleurs */
/* (état de départ posé en attributs par presentation.js : Motion anime les attributs SVG, qu'une règle CSS écraserait) */
.couleur .ld-logo span { color: var(--noir); }
.couleur .bar { background: #e6e6e6; }
.couleur .bar i { background: var(--rouge); }
.couleur .passer { color: var(--noir); border-color: #cfcfcf; }

/* ---- Logos finaux ---- */
#finals { display: none; }
.finals-on #finals { display: block; }
.finals-on #loader, .finals-on #bp { display: none !important; }
.entete-finals { padding: clamp(48px, 9vh, 90px) 20px 10px; text-align: center; }
.entete-finals p { margin: 0 0 10px; font: 800 12px/1 Montserrat, Arial, sans-serif; letter-spacing: .28em; text-transform: uppercase; color: var(--rouge); }
.entete-finals h1 { margin: 0; font: 900 italic clamp(28px, 5vw, 54px)/1.05 Montserrat, Arial, sans-serif; text-transform: uppercase; letter-spacing: -.01em; }

.final { position: relative; min-height: 88vh; min-height: 88svh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: clamp(26px, 5vh, 50px); padding: 60px 20px; background: #fff; transition: background-color .6s var(--ease); overflow: hidden; }
.final + .final { border-top: 1px solid #ececee; }
.final-tete { display: flex; align-items: baseline; gap: 14px; }
.lettre { font: 900 italic 15px/1 Montserrat, Arial, sans-serif; color: #fff; background: var(--rouge); padding: 8px 11px; transition: background-color .6s, color .6s; }
.nom { font: 800 12px/1 Montserrat, Arial, sans-serif; letter-spacing: .24em; text-transform: uppercase; color: #6b6f76; transition: color .6s; }
.final-logo { width: min(980px, 92vw); display: flex; justify-content: center; }
.final-logo .logo { width: 100%; height: auto; max-height: 50vh; overflow: visible; }
.fonds { display: flex; gap: 0; border: 1px solid #d9dbdf; transition: border-color .6s; }
.fonds button { background: none; border: 0; padding: 11px 18px; font: 800 10px/1 Montserrat, Arial, sans-serif; letter-spacing: .2em; text-transform: uppercase; color: #6b6f76; cursor: pointer; transition: background-color .3s, color .3s; }
.fonds button + button { border-left: 1px solid #d9dbdf; }
.fonds button[aria-pressed="true"] { background: var(--noir); color: #fff; }

.final[data-fond="noir"] { background: var(--noir); --ln: #fff; }
.final[data-fond="rouge"] { background: var(--rouge); --ln: #fff; --lr: #fff; }
.final[data-fond="noir"] .nom, .final[data-fond="rouge"] .nom { color: rgba(255,255,255,.7); }
.final[data-fond="rouge"] .lettre { background: #fff; color: var(--rouge); }
.final[data-fond="noir"] .fonds, .final[data-fond="rouge"] .fonds { border-color: rgba(255,255,255,.35); }
.final[data-fond="noir"] .fonds button, .final[data-fond="rouge"] .fonds button { color: rgba(255,255,255,.75); }
.final[data-fond="noir"] .fonds button + button, .final[data-fond="rouge"] .fonds button + button { border-left-color: rgba(255,255,255,.35); }
.final[data-fond="noir"] .fonds button[aria-pressed="true"], .final[data-fond="rouge"] .fonds button[aria-pressed="true"] { background: #fff; color: var(--noir); }

/* Animations en boucle des logos finaux */
.anime .seg { animation: graduation 3.2s var(--ease) infinite; animation-delay: calc(var(--i) * 90ms); }
@keyframes graduation { 0%, 100% { fill-opacity: 1; } 18% { fill-opacity: .18; } 36% { fill-opacity: 1; } }
.anime .balayage { opacity: 1; animation: balayer 4.8s cubic-bezier(.45, 0, .2, 1) infinite; }
@keyframes balayer { 0% { transform: translateX(0) skewX(-18deg); } 55%, 100% { transform: translateX(var(--course, 600px)) skewX(-18deg); } }
.final[data-fond="blanc"] .anime .balayage { mix-blend-mode: normal; }

.pied { padding: 40px 20px 50px; text-align: center; font: 500 11px/1.6 Montserrat, Arial, sans-serif; letter-spacing: .08em; color: #8b8f96; border-top: 1px solid #ececee; }

/* Protection (reprise de NORVA) */
html:not(.print-ok) body { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
html:not(.print-ok) svg { -webkit-user-drag: none; }
html.veil body > * { filter: blur(28px) !important; transition: filter .15s; }
@media print { html:not(.print-ok) body { display: none !important; } }

@media (prefers-reduced-motion: reduce) {
  .anime .seg, .anime .balayage { animation: none; }
  .anime .balayage { opacity: 0; }
}
