/* CZ Signature — effets : porte du cabinet, sélecteur de DA, brillances, ticket de rendez-vous. */

/* ---------- Entrée dans le cabinet (pilotée par le défilement : --p va de 0 = fermé à 1 = ouvert) ---------- */
.cz-entry { position: relative; height: 210vh; height: 210svh; }
.cz-entry-stage { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; perspective: 1400px; background: #121318; contain: paint; }
/* Les valeurs animées (transform, opacity) sont écrites directement par fun.js sur chaque élément :
   le téléphone n'a alors que des calques à déplacer, sans recalculer la page à chaque image. */
.cz-entry-room {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; text-align: center; padding: 96px 0 48px;
  transform: scale(.86); opacity: .35; will-change: transform, opacity;
}
.cz-entry-light { position: absolute; inset: 0; pointer-events: none; background: radial-gradient(ellipse at 50% 45%, rgba(255,255,255,.9), rgba(255,255,255,0) 60%); will-change: opacity; }
.cz-entry-doors { position: absolute; inset: 0; display: flex; pointer-events: none; }
.cz-entry-doors .leaf {
  position: relative; flex: 1; background: var(--chrome); border: 1px solid #FFFFFF;
  backface-visibility: hidden; -webkit-backface-visibility: hidden; will-change: transform;
}
.cz-entry-doors .leaf::before { content: ""; position: absolute; inset: 16px; border: 1px solid var(--line); border-radius: 4px; pointer-events: none; }
.cz-entry-doors .leaf.l { transform-origin: left center; }
.cz-entry-doors .leaf.r { transform-origin: right center; }
.cz-entry-doors .glass {
  position: absolute; left: 18%; right: 18%; top: 10%; height: 46%; border-radius: 999px 999px 18px 18px; overflow: hidden;
  background: linear-gradient(160deg, rgba(255,79,163,.28), rgba(255,255,255,.55) 45%, rgba(255,79,163,.18));
  border: 2px solid #FFFFFF;
}
.cz-entry-doors .shine { /* reflet qui glisse quand on ouvre */
  position: absolute; top: 0; bottom: 0; left: 0; width: 30%; will-change: transform;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,.85), transparent); transform: translateX(-110%);
}
.cz-entry-doors .handle { position: absolute; top: 60%; width: 12px; height: 96px; border-radius: 8px; background: var(--terracotta); box-shadow: 0 4px 0 var(--btn-depth); }
.cz-entry-doors .leaf.l .handle { right: 28px; }
.cz-entry-doors .leaf.r .handle { left: 28px; }
.cz-entry-doors .plaque {
  position: absolute; left: 50%; top: 50%; width: min(360px, 78vw); padding: 20px 28px 22px; text-align: center; margin: 0;
  transform: translate(-50%, -50%); will-change: transform, opacity;
  background: rgba(255,255,255,.94); border-radius: var(--radius-lg); box-shadow: var(--shadow-soft);
}
.plaque-logo { display: block; width: 100%; max-width: 260px; margin: 0 auto; }
.plaque-logo svg { display: block; width: 100%; height: auto; }
.plaque-sub { display: block; margin-top: 6px; font-size: 15px; color: var(--ink-muted); letter-spacing: .04em; }
.cz-entry-hint {
  position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 8px;
  color: #FFFFFF; font-size: 14px; font-weight: 500; will-change: opacity;
  background: rgba(18,19,24,.78); padding: 10px 16px 12px; border-radius: var(--radius-md);
}
.cz-entry-hint i { width: 22px; height: 34px; border: 2px solid #FFFFFF; border-radius: 14px; position: relative; }
.cz-entry-hint i::after { content: ""; position: absolute; left: 50%; top: 7px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: #FFFFFF; animation: cz-wheel 1.6s ease-in-out infinite; }
@keyframes cz-wheel { 0% { transform: translateY(0); opacity: 1; } 80% { transform: translateY(12px); opacity: 0; } 100% { opacity: 0; } }

/* Logo dans l'accueil et l'en-tête */
.cz-hero-logo { display: block; width: min(440px, 82vw); margin: 0 auto; }
.cz-hero-logo svg, .cz-logo svg { display: block; width: 100%; height: auto; }
.cz-logo { display: block; width: 112px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* En-tête flottant : caché tant que les portes ne sont pas ouvertes */
.cz-header-float { position: fixed; left: 0; right: 0; top: 0; transition: transform .35s ease; }
.cz-header-float.is-hidden { transform: translateY(-110%); }

/* ---------- Brillances ---------- */
.cz-spark { position: fixed; pointer-events: none; z-index: 60; width: 14px; height: 14px; color: var(--terracotta); animation: cz-spark .9s ease-out forwards; }
.cz-spark svg { width: 100%; height: 100%; display: block; }
@keyframes cz-spark { 0% { transform: translate(0,0) scale(.2) rotate(0); opacity: 1; } 100% { transform: translate(var(--dx), var(--dy)) scale(1) rotate(90deg); opacity: 0; } }

/* Effet « dent qui brille » au survol des photos */
.cz-service img { transition: transform .4s ease, filter .4s ease; }
.cz-service:hover img { transform: scale(1.03) rotate(-1deg); filter: brightness(1.06) saturate(1.05); }

/* ---------- Ticket de rendez-vous ---------- */
.cz-ticket {
  position: relative; margin-top: var(--space-6); background: var(--blush); border-radius: var(--radius-lg);
  padding: var(--space-6); border: 2px dashed var(--field-border); animation: cz-pop .5s cubic-bezier(.2, 1.4, .4, 1);
}
.cz-ticket .t-head { font-family: var(--font-script); font-size: 30px; line-height: 36px; margin-bottom: var(--space-3); }
.cz-ticket .t-row { display: flex; justify-content: space-between; gap: var(--space-4); padding: var(--space-2) 0; border-bottom: 1px solid var(--line); }
.cz-ticket .t-row span:first-child { color: var(--ink-muted); }
.cz-ticket .t-row span:last-child { font-weight: 500; text-align: right; }
.cz-ticket .t-foot { margin-top: var(--space-4); font-size: 14px; color: var(--ink-muted); }
@keyframes cz-pop { from { transform: scale(.85) rotate(-2deg); opacity: 0; } to { transform: none; opacity: 1; } }

@media (prefers-reduced-motion: reduce) {
  .cz-entry { height: auto; } .cz-entry-stage { position: relative; height: auto; } .cz-entry-doors { display: none; }
  .cz-entry-room { position: relative; transform: none !important; opacity: 1 !important; } .cz-entry-light { display: none; }
  .cz-ticket, .cz-service img { transition: none !important; animation: none !important; }
  .cz-spark { display: none; }
}
@media (max-width: 600px) {
  .cz-entry-doors .handle { height: 60px; width: 10px; }
  .cz-entry-doors .leaf.l .handle { right: 14px; } .cz-entry-doors .leaf.r .handle { left: 14px; }
}
