/* SPN UX MOBILE FIX 2026-10-24 — injecté par server/webhook-server.js html() (SPN uniquement)
   Rollback : /opt/spn/backups/ux-mobile-20261024/ROLLBACK.sh
   Objectif : sur mobile, au plus menu + 1 barre CTA basse ; aucune règle SEO touchée. */

/* (b) barre CTA basse : un seul décalage cookie (bottom:0 + margin-bottom:--cmp-h).
   La page Noche posait bottom:var(--cmp-h) ET margin-bottom:var(--cmp-h) => barre remontée au milieu, sur le H1. */
html body #mob-cta-bar{bottom:0!important;margin-bottom:var(--cmp-h,0px)!important}
html{scroll-padding-top:72px}

/* (d) /cours-prives : le bouton flottant doublonne la barre basse (.mbar) et recouvre les tags disciplines */
html body .floatcta{display:none!important}

/* (e) cibles tactiles >= 44px pour le menu principal et le CTA du menu */
html body .spn-nav .nav-link,html body .spn-nav .nav-cta,html body nav.nav a.btn{min-height:44px;display:inline-flex;align-items:center;box-sizing:border-box}
html body .nav-drawer a{min-height:44px}

/* (c) titres d'événements de la billetterie mobile : retour à la ligne au lieu de « … » */
html body .mb-ev-t b{white-space:normal!important;overflow:visible!important;text-overflow:clip!important;line-height:1.2}

/* (f) lien retour accueil (pages autonomes sans menu) */
.spn-back{position:absolute;top:10px;left:10px;z-index:50;display:inline-flex;align-items:center;min-height:44px;padding:0 14px;border-radius:999px;background:rgba(9,5,14,.72);border:1px solid rgba(245,237,224,.22);color:#f5ede0!important;font:600 13px/1 Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;text-decoration:none!important;backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px)}
.spn-back:hover{background:rgba(9,5,14,.9)}

@media (max-width:640px){
  /* (a1) bandeau d'annonce : n'est plus collant — il défile avec la page, sous le menu */
  html body #announce-bar{position:absolute!important;top:60px!important;z-index:999!important;animation:none!important}
  html body.has-announce nav.spn-nav,html body #announce-bar ~ * nav.spn-nav{top:0!important}
  /* (a2) une seule barre basse : la barre « sticky-book » (doublon de #mob-cta-bar) est coupée sur mobile */
  html body #sticky-book{display:none!important}
  /* (a3) bandeau cookies : bottom sheet compacte (texte défilant, boutons sur une ligne) */
  html body #spn-cmp{padding:10px 12px calc(8px + env(safe-area-inset-bottom,0px))!important;max-height:52vh!important}
  html body #spn-cmp .spn-cmp-h{font-size:14px!important;margin:0 0 2px!important}
  html body #spn-cmp .spn-cmp-p{font-size:12px!important;line-height:1.38!important;max-height:5.6em;overflow-y:auto;margin:0 0 8px!important}
  html body #spn-cmp .spn-cmp-btns{gap:6px!important}
  html body #spn-cmp .spn-cmp-btns .spn-cmp-b{min-height:44px;padding:6px 4px!important;font-size:13px!important}
  /* (a4) bouton chat : masqué quand une barre CTA basse existe ou quand le bandeau cookies est ouvert ;
     sinon décalé au-dessus du bandeau. Le chat reste ouvrable (ASK SPN, élément cliqué par script). */
  html body:has(#mob-cta-bar) #knzo-chat-btn,
  html body:has(.mbar) #knzo-chat-btn,
  html body:has(.kse-bar.is-visible) #knzo-chat-btn,
  html body:has(#spn-cmp:not([hidden])) #knzo-chat-btn{display:none!important}
  html body #knzo-chat-btn{bottom:calc(var(--cmp-h,0px) + 16px + env(safe-area-inset-bottom,0px))!important}
  .spn-back{top:8px;left:8px;padding:0 12px;font-size:12px}
}
/* ks-experience : le haut du héros est occupé (pastille) => lien retour dans le flux, pas en surimpression */
html body.kse-body > .spn-back{position:relative;top:auto;left:auto;display:flex;width:max-content;margin:8px 0 0 10px}

/* UX_LOT2_20261024 — cibles tactiles >= 44 px (accueil) + comblement écart barre d'annonce / menu desktop. Rollback : /opt/spn/backups/ux-lot2-20261024/ROLLBACK.sh */
@media (max-width:640px){
  html body .events-filter-bar .efil{min-height:44px!important;display:inline-flex!important;align-items:center;justify-content:center}
  html body .spn-pulse-action{min-height:44px!important;display:inline-flex!important;align-items:center;justify-content:center}
  html body .disc-badges-strip .db-badge{min-height:44px!important;display:inline-flex!important;align-items:center}
}
@media (min-width:641px){
  html body #announce-bar{min-height:42px;box-sizing:border-box}
}

/* UX_LOT3_20261024 — sélecteur de date du formulaire de réservation : ne déborde plus. Rollback : /opt/spn/backups/ux-lot3-20261024/ROLLBACK.sh */
html body select#sh-date{width:100%!important;max-width:100%!important;min-width:0!important;box-sizing:border-box!important;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}
