/* Page Osark Système : le visiteur compose son application (Florian, 15/10).
   Pas de fond à points ici (c'est la marque des autres pages) : des lueurs aux couleurs des modules cochés. */
:root {
  --nuit: #050a12; --fond: #0b1622; --fond-2: #10233a; --texte: #f7f6f3; --texte-doux: #b9c4cf;
  --sarcelle: #3abcb8; --trait: rgba(247, 246, 243, .14); --police: 'Bricolage Grotesque', system-ui, sans-serif;
}
* { box-sizing: border-box; margin: 0; }
html { color-scheme: dark; scroll-behavior: smooth; }
body { background: var(--nuit); color: var(--texte); font-family: var(--police); line-height: 1.5; min-height: 100vh; overflow-x: hidden; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--sarcelle); outline-offset: 3px; border-radius: 6px; }
header, main, footer { position: relative; z-index: 1; }
.bandeau-maquette { position: relative; z-index: 1; background: #2a3a4d; color: var(--texte-doux); font-size: .78rem; text-align: center; padding: 5px 12px; }
.entete { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 18px clamp(20px, 5vw, 72px); border-bottom: 1px solid var(--trait); }
.logo { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; font-weight: 800; letter-spacing: .16em; font-size: 1.05rem; }
.logo img { height: 30px; width: auto; display: block; }
.entete nav { display: flex; gap: clamp(14px, 2vw, 30px); font-size: .95rem; font-weight: 500; }
.entete nav a { text-decoration: none; color: var(--texte-doux); padding: 6px 2px; }
.entete nav a:hover, .entete nav a[aria-current="page"] { color: var(--texte); }
.entete nav a[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--sarcelle); }
.bouton { display: inline-flex; align-items: center; gap: 10px; padding: 13px 22px; border-radius: 999px; font: 600 1rem var(--police); text-decoration: none; white-space: nowrap; border: 1.5px solid transparent; cursor: pointer; }
.bouton--plein { background: var(--sarcelle); color: #06222a; }
.bouton--plein:hover { background: #55d0cc; }
.bouton--contour { border-color: var(--trait); color: var(--texte); }
.bouton--contour:hover { border-color: var(--texte-doux); }
.entete .bouton { padding: 10px 18px; font-size: .92rem; }
.lieu { display: inline-flex; align-items: center; gap: 12px; font-size: .85rem; letter-spacing: .14em; text-transform: uppercase; color: var(--sarcelle); font-weight: 600; margin-bottom: 10px; }
.lieu::before { content: ""; width: 34px; height: 2px; background: var(--sarcelle); }

/* Lueurs du fond : une par module, allumée quand il est coché. Seule l'opacité bouge. */
.lueurs { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden;
  background:
    radial-gradient(70vmax 45vmax at 8% -6%, rgba(58, 188, 184, .14), transparent 70%),
    radial-gradient(60vmax 50vmax at 92% 18%, rgba(40, 92, 160, .16), transparent 70%),
    radial-gradient(70vmax 50vmax at 30% 105%, rgba(110, 72, 170, .10), transparent 70%),
    linear-gradient(180deg, #07121d 0%, #050a12 55%, #070b16 100%); }
/* voile très léger qui casse les aplats */
.lueurs::after { content: ""; position: absolute; inset: 0; opacity: .5;
  background: repeating-linear-gradient(115deg, rgba(255, 255, 255, .012) 0 2px, transparent 2px 6px); }
.lueurs span { position: absolute; width: 60vmax; height: 60vmax; border-radius: 50%; opacity: 0; transition: opacity .9s ease;
  background: radial-gradient(closest-side, var(--l), transparent); }
.lueurs [data-lueur="planning"] { --l: rgba(52, 178, 122, .24); left: 30%; top: -25%; }
.lueurs [data-lueur="fidelite"] { --l: rgba(227, 178, 58, .2); left: 55%; top: 10%; }
.lueurs [data-lueur="compta"] { --l: rgba(63, 124, 192, .26); left: 35%; top: 35%; }
.lueurs [data-lueur="vocal"] { --l: rgba(176, 123, 230, .24); left: 60%; top: 45%; }
.lueurs span.allumee { opacity: 1; }

/* Le configurateur : modules à gauche, tablette + téléphone qui restent visibles à droite */
.compo { max-width: 1240px; margin: 0 auto; padding: clamp(16px, 2.4vw, 30px) clamp(20px, 5vw, 72px) clamp(20px, 2.5vw, 32px);
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 4.5vw, 64px); align-items: start; }
.compo h1 { font-size: clamp(1.9rem, 3.5vw, 2.9rem); line-height: 1.05; font-weight: 800; letter-spacing: -.025em; text-wrap: balance; }
.compo__lead { margin-top: 12px; color: var(--texte-doux); font-size: clamp(1.02rem, 1.3vw, 1.18rem); max-width: 34em; }

.modules { border: 0; padding: 0; margin: clamp(18px, 2.4vw, 28px) 0 0; min-width: 0; }
.modules legend { padding: 0; margin-bottom: 10px; font-weight: 800; font-size: clamp(1.1rem, 1.6vw, 1.3rem); }
.modules__grille { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
/* Interrupteurs (Florian, 15/10) : on active le module, rien de plus ; le détail est dans la section des fiches */
.inter { position: relative; display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: 16px; cursor: pointer;
  background: rgba(16, 35, 58, .6); box-shadow: 0 0 0 1.5px var(--trait); transition: box-shadow .25s ease, background .25s ease; }
.inter input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.inter:hover { box-shadow: 0 0 0 1.5px color-mix(in srgb, var(--c) 55%, transparent); }
.inter:has(input:checked) { background: color-mix(in srgb, var(--c) 13%, #0b1622); box-shadow: 0 0 0 2px var(--c), 0 14px 30px -20px var(--c); }
.inter:has(input:focus-visible) { outline: 3px solid var(--texte); outline-offset: 3px; }
.inter__icone { flex: none; width: 36px; height: 36px; border-radius: 12px; display: grid; place-items: center;
  background: color-mix(in srgb, var(--c) 18%, transparent); color: var(--c); }
.inter__icone svg, .fiche__icone svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.inter__nom { flex: 1; font-weight: 700; font-size: 1.05rem; }
.inter__switch { flex: none; position: relative; width: 44px; height: 26px; border-radius: 99px; background: rgba(247, 246, 243, .16); transition: background .25s ease; }
.inter__switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: var(--texte);
  box-shadow: 0 2px 6px rgba(0, 0, 0, .4); transition: translate .25s cubic-bezier(.3, 1.4, .5, 1); }
.inter:has(input:checked) .inter__switch { background: var(--c); }
.inter:has(input:checked) .inter__switch::after { translate: 18px 0; }

/* Ce que fait chaque module : les fiches, allumées quand le module est activé */
.fiches { max-width: 1240px; margin: 0 auto; padding: clamp(18px, 2.5vw, 30px) clamp(20px, 5vw, 72px) 0; }
.fiches h2 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); font-weight: 800; letter-spacing: -.015em; }
.fiches__grille { margin-top: 16px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.fiche { display: flex; flex-direction: column; padding: 22px 20px 20px; border-radius: 18px; background: rgba(16, 35, 58, .55);
  box-shadow: 0 0 0 1.5px var(--trait); transition: box-shadow .3s ease, background .3s ease, opacity .3s ease; }
.fiche.active { background: color-mix(in srgb, var(--c) 11%, #0b1622); box-shadow: 0 0 0 2px var(--c), 0 22px 44px -26px var(--c); }
.fiche__icone { width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 18%, transparent); color: var(--c); }
.fiche h3 { margin-top: 14px; font-size: 1.2rem; font-weight: 800; }
.fiche p { margin-top: 6px; color: var(--texte-doux); font-size: .95rem; line-height: 1.45; }
.fiche ul { list-style: none; padding: 0; margin: 12px 0 18px; }
.fiche li { position: relative; padding-left: 16px; margin-top: 7px; font-size: .9rem; line-height: 1.4; }
.fiche li::before { content: ""; position: absolute; left: 1px; top: .55em; width: 7px; height: 7px; border-radius: 50%; background: var(--c); }
.fiche__bouton { margin-top: auto; min-height: 44px; border-radius: 99px; cursor: pointer; font: 700 .9rem var(--police);
  border: 1.5px solid color-mix(in srgb, var(--c) 60%, transparent); background: transparent; color: var(--texte); }
.fiche__bouton:hover { background: color-mix(in srgb, var(--c) 16%, transparent); }
.fiche__bouton[aria-pressed="true"] { background: var(--c); border-color: var(--c); color: #07131f; }

/* Tout se parle */
.liens { margin-top: clamp(18px, 2.4vw, 28px); }
.liens h2 { font-size: clamp(1.1rem, 1.6vw, 1.3rem); font-weight: 800; }
.liens__liste { list-style: none; padding: 0; margin-top: 12px; display: grid; gap: 8px; }
.liens__liste li { display: none; align-items: center; gap: 14px; padding: 12px 16px; border-radius: 14px; background: rgba(16, 35, 58, .6); box-shadow: 0 0 0 1px var(--trait); }
.liens__liste li.allume { display: flex; animation: lien-arrive .45s ease both; }
.liens__duo { flex: none; display: inline-flex; align-items: center; }
.liens__duo i { width: 16px; height: 16px; border-radius: 50%; background: var(--c); box-shadow: 0 0 12px var(--c); }
.liens__duo i + i { margin-left: 18px; position: relative; }
.liens__duo i + i::before { content: ""; position: absolute; right: 100%; top: 50%; width: 18px; height: 2px; margin-top: -1px; background: linear-gradient(90deg, var(--texte-doux), var(--texte)); }
.liens__liste:not(:has(.allume)) { margin-top: 0; }
.liens__vide { margin-top: 6px; color: var(--texte-doux); font-size: .95rem; }
@keyframes lien-arrive { from { opacity: 0; translate: 0 8px; } to { opacity: 1; translate: 0 0; } }

.compo__action { margin-top: clamp(18px, 2.2vw, 24px); display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.compo__action .bouton { min-height: 54px; }
.compo__compte { color: var(--texte-doux); }

/* Tablette + téléphone posé devant (comme les sites du hero de l'accueil). Les deux montrent le même écran.
   Tailles en cqw : le même accueil d'application s'adapte à chaque appareil. */
.compo__droite { position: sticky; top: 16px; }
.scene { position: relative; margin: 0 6% clamp(40px, 4vw, 54px) 0; }
.tablette { position: relative; border-radius: 22px; padding: 12px; background: #141c26;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .1), inset 0 0 0 2px #26303c, 0 30px 70px -22px rgba(0, 0, 0, .8), 0 60px 120px -50px rgba(58, 188, 184, .22); }
.telephone { position: absolute; right: -6%; bottom: -16%; width: 19%; border-radius: 20px; padding: 5px; background: #0a121c;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .12), 0 18px 40px -10px rgba(0, 0, 0, .75); }
.ecran-app { position: relative; overflow: hidden; container-type: inline-size; background: radial-gradient(110% 70% at 50% 15%, #0f2a2e 0%, #070d15 62%); }
.tablette .ecran-app { aspect-ratio: 1180 / 820; border-radius: 10px; }
.telephone .ecran-app { aspect-ratio: 390 / 844; border-radius: 15px; }

/* L'accueil de l'application (reproduit) */
.hub { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; text-align: center; transition: opacity .35s ease; }
.tablette .hub { padding-top: 9cqw; }
.telephone .hub { padding-top: 26cqw; }
.hub__logo { width: 8cqw; height: auto; filter: drop-shadow(0 0 2cqw rgba(58, 188, 184, .45)); }
.telephone .hub__logo { width: 16cqw; }
.hub__bonjour { margin-top: 1.4cqw; font-family: Georgia, serif; font-size: 1.9cqw; color: #8d99a5; }
.hub__question { margin-top: .3cqw; font-family: Georgia, serif; font-weight: 700; font-size: 2.6cqw; line-height: 1.25; color: #c9d1d8; }
.telephone .hub__bonjour { margin-top: 4cqw; font-size: 5cqw; }
.telephone .hub__question { font-size: 6cqw; max-width: 80%; }
.hub__question b { color: #fff; text-shadow: 0 0 2cqw rgba(255, 255, 255, .5); }
.hub__tuiles { margin-top: 3.5cqw; display: flex; flex-wrap: wrap; justify-content: center; gap: 1.6cqw; }
.telephone .hub__tuiles { margin-top: 8cqw; gap: 4cqw; max-width: 72cqw; }
.tuile { width: 15cqw; aspect-ratio: 1; border-radius: 1.8cqw; border: 1px solid color-mix(in srgb, var(--c) 55%, transparent);
  background: color-mix(in srgb, var(--c) 12%, #0b1219); color: #e8edf1; font: 600 1.65cqw var(--police);
  display: grid; place-items: center; align-content: center; gap: .8cqw; padding: 0; cursor: pointer; animation: tuile-arrive .45s cubic-bezier(.3, 1.5, .5, 1) both; }
.telephone .tuile { width: 34cqw; border-radius: 5cqw; font-size: 4.2cqw; gap: 2cqw; }
.tuile:hover { background: color-mix(in srgb, var(--c) 20%, #0b1219); }
.tuile__rond { width: 6cqw; aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 22%, transparent); color: var(--c); }
.telephone .tuile__rond { width: 14cqw; }
.tuile__rond svg { width: 55%; height: 55%; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
@keyframes tuile-arrive { from { opacity: 0; scale: .6; } to { opacity: 1; scale: 1; } }
.hub__vide { margin-top: 3.5cqw; padding: 1.6cqw 2.4cqw; border-radius: 1.6cqw; border: 1.5px dashed rgba(255, 255, 255, .18); color: #8d99a5; font-size: 1.6cqw; }
.telephone .hub__vide { margin-top: 8cqw; padding: 4cqw; border-radius: 4cqw; font-size: 4.4cqw; max-width: 80%; }

/* L'écran d'un module : la vraie capture de l'application, qui glisse par-dessus l'accueil */
[hidden] { display: none !important; }
.vue { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top; animation: vue-arrive .45s ease both; }
.telephone .vue { animation-delay: .08s; }
@keyframes vue-arrive { from { opacity: 0; translate: 6% 0; } to { opacity: 1; translate: 0 0; } }
.ecran-app.module-ouvert .hub { opacity: 0; pointer-events: none; }
.avenir { position: absolute; inset: 0; display: grid; place-items: center; padding: 6%; text-align: center; color: #8d99a5; font-size: 2cqw; }
.telephone .avenir { font-size: 5cqw; }

/* Comme les points du carrousel du hero : un bouton par écran */
.onglets { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 118px); width: fit-content; max-width: 100%; gap: 4px; padding: 5px; border-radius: 16px;
  background: rgba(16, 35, 58, .75); box-shadow: 0 0 0 1px var(--trait), 0 14px 30px -18px rgba(0, 0, 0, .8); }
.onglet { position: relative; min-height: 48px; padding: 0 6px; border-radius: 12px; cursor: pointer; border: 0; background: transparent;
  color: var(--texte); font: 700 .92rem var(--police); display: flex; align-items: center; justify-content: center; gap: 8px; white-space: nowrap;
  transition: background .2s ease, color .2s ease; }
.onglet::before { content: ""; flex: none; width: 9px; height: 9px; border-radius: 50%; background: var(--c, var(--sarcelle)); }
.onglet:hover { background: color-mix(in srgb, var(--c, var(--sarcelle)) 18%, transparent); }
.onglet[aria-pressed="true"] { background: var(--c, var(--sarcelle)); color: #07131f; }
.onglet[aria-pressed="true"]::before { background: #07131f; }
/* Appel au clic : le dernier module coché « respire » tant que le visiteur n'a ouvert aucun écran */
.onglet.appel { box-shadow: 0 0 0 2px var(--c); animation: appel 1.6s ease-in-out infinite; }
.onglet.appel::after { content: "Voir"; position: absolute; top: -9px; right: 6px; padding: 1px 7px; border-radius: 99px;
  background: var(--c); color: #07131f; font-size: .66rem; font-weight: 800; letter-spacing: .02em; }
@keyframes appel { 50% { box-shadow: 0 0 0 2px var(--c), 0 0 0 7px color-mix(in srgb, var(--c) 25%, transparent); } }
.onglets__titre { margin-bottom: 8px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.onglets__titre span { color: var(--sarcelle); }
.aide { margin-top: 10px; color: var(--texte-doux); font-size: .88rem; }
.tablette .tuile { box-shadow: 0 0 0 0 transparent; transition: box-shadow .2s, translate .2s; }
.tablette .tuile:hover { translate: 0 -2px; box-shadow: 0 8px 18px -8px var(--c); }

.devis { position: relative; }
.devis.devis--page { padding-top: clamp(28px, 3.5vw, 44px); }
/* La tablette ne dépasse jamais la hauteur de l'écran : tout le haut de la page tient à l'arrivée */
@media (min-width: 901px) { .scene { max-width: calc((100svh - 300px) * 1.5); } }

@media (max-width: 1100px) {
  .fiches__grille { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .entete nav { display: none; }
  /* Téléphone : l'appareil passe juste sous le titre, en plus petit, pour voir les tuiles arriver en cochant */
  .compo { display: flex; flex-direction: column; gap: 0; }
  .compo__gauche { display: contents; }
  .compo__gauche > * { order: 2; }
  .compo__gauche > .lieu, .compo__gauche > h1, .compo__gauche > .compo__lead { order: 0; }
  .compo__droite { order: 1; position: static; margin-top: 22px; }
  .compo .lieu { align-self: flex-start; }
  .scene { margin: 0 5% 44px 0; }
  .telephone { right: -6%; bottom: -16%; width: 21%; border-radius: 12px; padding: 3px; }
  .telephone .ecran-app { border-radius: 11px; }
  .tablette { padding: 7px; border-radius: 16px; }
}
@media (max-width: 560px) {
  /* une seule ligne même sur téléphone : le point passe au-dessus du nom */
  .onglet { flex-direction: column; gap: 4px; min-height: 54px; font-size: .74rem; padding: 0 2px; }
  .onglet.appel::after { top: -8px; right: 50%; translate: 50% 0; }
  .inter { padding: 10px; gap: 9px; }
  .inter__icone { width: 34px; height: 34px; }
  .inter__nom { font-size: .9rem; white-space: nowrap; }
  .inter__switch { width: 38px; height: 22px; }
  .inter__switch::after { width: 16px; height: 16px; }
  .inter:has(input:checked) .inter__switch::after { translate: 16px 0; }
  .fiches__grille { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .tuile, .vue, .liens__liste li.allume, .onglet.appel { animation: none; }
  .lueurs span, .inter__switch::after { transition: none; }
}
