/* ==========================================================================
   Tapage · feuille de style
   --------------------------------------------------------------------------
   Interface d'app native, claire et épurée :
   - Fond gris bleuté #F4F6F8, cartes blanches, anthracite #212528 pour tout ce
     qui est actif (pilules, boutons, barre d'onglets), texte quasi noir
   - Typo Satoshi : titres en Medium (500), texte en Regular (400)
     échelle 26 · 24 · 22 · 21 · 18 · 17 · 16 · 15 · 14
   - Rayons : 32 (feuilles) · 28 (pile) · 26 (cartes) · 20 (photos) · 14 (vignettes) · pilule
   - Ronds : 50 (boutons) · 52 (onglet actif) · barre d'onglets 66 de haut
   - Mouvement : transform + opacity, courbes expo et ressorts
   - Responsive : mobile d'abord · ≥ 640 tablette · ≥ 1024 barre latérale
   ========================================================================== */

@font-face {
  font-family: "Satoshi";
  src: url("../fonts/satoshi-variable.woff2") format("woff2");
  font-weight: 300 900;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  --bg: #F4F6F8;
  --surface: #FFFFFF;
  --ink: #212528;
  --ink-2: #33383C;
  --text: #0E1012;
  --text-2: #565D63;
  --text-3: #687078;
  --desc: #2A2C2E;
  --line: #E3E5E7;
  --line-2: #D5D8DB;
  --handle: #DCDEE0;
  --control: #7C838A;
  --accent: #A820B0;
  --ok: #187A45;
  --ok-soft: #E6F5EC;
  --danger: #C7343A;
  --danger-soft: #FDECEC;
  --warn: #925D00;
  --warn-soft: #FFF3DC;

  --radius-field: 16px;
  --radius-card: 24px;
  --radius-panel: 32px;
  --radius-pill: 999px;
  --control-h: 52px;
  --section-gap: 36px;
  --section-inset: 16px;
  --gutter: 20px;
  --app-w: 600px;
  --side-w: 280px;
  --tabbar-h: 66px;
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --deck-h: clamp(340px, calc(100svh - 440px), 470px);

  --font: "Satoshi", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-expo: cubic-bezier(.19, 1, .22, 1);
  --spring: cubic-bezier(.22, 1, .36, 1);
  --glide: cubic-bezier(.22, 1, .36, 1);

  --sh-card: 0 1px 2px rgba(16, 24, 40, .03), 0 12px 32px -22px rgba(16, 24, 40, .16);
  --sh-float: 0 22px 44px -18px rgba(16, 24, 40, .45);
}

/* ---------- Base ---------- */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--bg); scroll-behavior: smooth; }
body {
  margin: 0; min-height: 100dvh;
  background: var(--bg); color: var(--text);
  font: 400 16px/1.5 var(--font);
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; -webkit-user-drag: none; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; letter-spacing: inherit; }
button { cursor: pointer; }
button, .btn, .tab, .chip, .tab-pill, .circle-btn, .square-btn { -webkit-user-select: none; user-select: none; touch-action: manipulation; }
h1, h2, h3, p, ul, dl, dd { margin: 0; }
h1, h2, h3 { font-weight: 500; text-wrap: balance; }
b, strong { font-weight: 500; }
ul { padding: 0; list-style: none; }
small { font-size: 13px; }
[hidden] { display: none !important; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
/* Lien d'évitement : invisible jusqu'au premier Tab */
.skip-link { position: fixed; z-index: 100; top: 10px; left: 10px; padding: 12px 18px; border-radius: var(--radius-pill); background: var(--ink); color: #fff; font-weight: 500; transform: translateY(-160%); transition: transform .2s var(--ease-out); }
.skip-link:focus { transform: none; outline-color: var(--accent); }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 12px; }
::selection { background: var(--ink); color: #fff; }

.ic { width: 24px; height: 24px; flex: none; }
.ic-sm { width: 16px; height: 16px; }
.muted { color: var(--text-2); }
.neg { color: var(--danger); }
.pos { color: var(--ok); }
.warn { color: var(--warn); }
.sep, .dot-sep { display: inline-block; flex: none; width: 4px; height: 4px; margin: 0 9px; border-radius: 50%; background: #B4B6B9; vertical-align: middle; }

/* Lien souligné, comme « Read more » / « See all » */
.u-link, .link { padding: 0; border: 0; background: none; color: var(--text); font-size: 14px; font-weight: 500; line-height: 1.5; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; transition: opacity .2s; }
.u-link:hover, .link:hover { opacity: .6; }
.u-static, .u-static:hover { opacity: 1; text-decoration: none; }
.u-link .ic { width: 16px; height: 16px; margin-right: 6px; vertical-align: -2px; }

/* Lien qui rend toute la carte cliquable */
.stretched::after { content: ""; position: absolute; inset: 0; z-index: 1; border-radius: inherit; }

.press { transition: transform .5s var(--spring); }
.press:active { transform: scale(.97); transition-duration: .12s; transition-timing-function: var(--ease-out); }

.btn, .chip, .tab-pill, .circle-btn, .square-btn, .action, .row-link, .nav-link, .icon-btn, .filter-btn, .menu-tile, .menu-row { position: relative; }

/* ---------- Transitions entre pages ---------- */

/* La page sortante s'efface, la nouvelle monte en fondu ; les barres fixes ne bougent pas. */
@media (prefers-reduced-motion: no-preference) { @view-transition { navigation: auto; } }
.tabbar { view-transition-name: tabbar; }
.cta-bar { view-transition-name: ctabar; }
.sidebar { view-transition-name: sidebar; }

::view-transition-group(*) { animation-duration: .3s; }
::view-transition-old(root) { animation: vt-page-out .18s var(--ease-out) both; }
::view-transition-new(root) { animation: vt-page-in .38s var(--ease-out) .06s both; }
/* Barre d'onglets des deux côtés : la nouvelle (vivante) prend le relais, son rond glisse. */
::view-transition-old(tabbar):not(:only-child), ::view-transition-old(ctabar):not(:only-child) { display: none; }
::view-transition-new(tabbar):not(:only-child), ::view-transition-new(ctabar):not(:only-child) { animation: none; }
::view-transition-old(tabbar):only-child, ::view-transition-old(ctabar):only-child { animation: vt-out .12s linear both; }
::view-transition-new(tabbar):only-child, ::view-transition-new(ctabar):only-child { animation: vt-in .2s ease-out both; }
@keyframes vt-out { to { opacity: 0; } }
@keyframes vt-in { from { opacity: 0; } }
@keyframes vt-page-out { to { opacity: 0; transform: scale(.985); } }
@keyframes vt-page-in { from { opacity: 0; transform: translateY(14px); } }
/* Navigateurs sans transitions entre pages : le contenu entre quand même en douceur. */
@supports not (view-transition-name: none) { .motion .app { animation: vt-page-in .38s var(--ease-out) backwards; } }
@keyframes fade { from { opacity: 0; } }
@keyframes fade-out { to { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: scale(.6); } }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }

/* Images : fondu net quand elles arrivent */
img.cover, .photo img { transition: opacity .3s ease-out; }
img.is-loading { opacity: 0; }

/* ---------- Coque ---------- */

.app { width: 100%; max-width: var(--app-w); margin: 0 auto; padding: 0 var(--gutter) 48px; }
.has-tabs .app { padding-bottom: calc(var(--tabbar-h) + var(--safe-b) + 44px); }
.has-cta .app { padding-bottom: calc(60px + var(--safe-b) + 44px); }
.is-wide { --app-w: 1120px; }

/* En-tête : rond · titre centré + sous-titre · rond */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: grid; grid-template-columns: minmax(50px, 1fr) minmax(0, max-content) minmax(50px, 1fr); align-items: center; gap: 12px;
  padding: max(calc(var(--safe-t) + 4px), 14px) var(--gutter) 10px;
  transition: background-color .3s, box-shadow .3s;
}
.topbar.is-scrolled { background: rgba(244, 246, 248, .97); box-shadow: 0 1px 0 rgba(16, 24, 40, .06); }
.topbar-side { display: flex; align-items: center; gap: 8px; }
.topbar-right { justify-content: flex-end; }
.topbar-center { min-width: 0; text-align: center; }
.topbar-title { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font: 600 22px/1.25 var(--font); color: var(--text); }
.topbar-sub { margin-top: 3px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 14px; line-height: 1.3; color: var(--text-3); }
.topbar .btn-sm { height: 50px; border-radius: 25px; }

.circle-btn, .square-btn {
  display: grid; place-items: center; flex: none;
  width: 48px; height: 48px; padding: 0; border: 0; border-radius: 50%;
  background: var(--surface); color: var(--text);
  transition: transform .45s var(--spring), background-color .2s, box-shadow .3s;
}
.circle-btn .ic, .square-btn .ic { width: 22px; height: 22px; }
.circle-btn:active, .square-btn:active { transform: scale(.88); transition-duration: .1s; }
.has-dot::after { content: ""; position: absolute; top: 12px; right: 13px; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 2px #fff; }
.dark-circle { display: grid; place-items: center; flex: none; width: 50px; height: 50px; border-radius: 50%; background: var(--ink); color: #fff; }
.dark-circle .ic { width: 22px; height: 22px; }

/* Logo : la bouche + le nom, côte à côte, centrés sur la hauteur du nom */
.brand { display: inline-flex; align-items: center; gap: 9px; flex: none; color: var(--ink); }
.brand img { display: block; width: auto; }
.brand-mark { height: 30px; }
.brand-name { height: 21px; margin-top: 3px; }
/* Logo sans fond dans les en-têtes mobiles */
.brand-pill { height: 50px; padding: 0; background: transparent; transition: transform .3s var(--ease-out); }
.brand-pill:active { transform: scale(.96); }
.brand-pill .brand-mark { height: 30px; }
.brand-pill .brand-name { height: 20px; }
.navbar-action { display: inline-flex; align-items: center; height: 50px; padding: 0 6px; font-size: 16px; text-decoration: underline; text-underline-offset: 5px; }

/* Barre d'onglets : pilule anthracite, un rond blanc glisse sous l'onglet actif */
.tabbar {
  position: fixed; z-index: 30; left: 50%; bottom: max(calc(var(--safe-b) + 6px), 14px);
  display: flex; align-items: center;
  width: min(calc(100% - 64px), 300px); height: var(--tabbar-h); padding: 7px;
  border-radius: 33px; background: var(--ink);
  box-shadow: 0 18px 36px -16px rgba(16, 24, 40, .5);
  transform: translateX(-50%);
}
.tab-indicator { position: absolute; top: 7px; bottom: 7px; left: 7px; width: calc((100% - 14px) / 4); transform: translateX(calc(var(--i, 0) * 100%)); transition: transform .56s cubic-bezier(.3, 1.25, .5, 1); pointer-events: none; }
.tab-indicator::before { content: ""; position: absolute; top: 0; bottom: 0; left: 50%; width: 52px; margin-left: -26px; border-radius: 50%; background: #fff; }
.tab { position: relative; z-index: 1; display: grid; place-items: center; flex: 1; height: 52px; padding: 0; border: 0; border-radius: var(--radius-card); background: transparent; color: #fff; transition: color .3s var(--ease-out), transform .45s var(--spring); }
.tab:active { transform: scale(.88); transition-duration: .12s; }
.tab-ic { width: 23px; height: 23px; }
.tab.is-active { color: var(--ink); transition-delay: .08s; }
.tab.has-dot::after { top: 12px; right: calc(50% - 17px); box-shadow: 0 0 0 2px var(--ink); }

/* Bouton d'action (réserver, payer) : la grande pilule du bas */
.cta-bar { position: fixed; z-index: 30; left: 0; right: 0; bottom: max(calc(var(--safe-b) + 6px), 16px); padding: 0 var(--gutter); pointer-events: none; }
.cta-inner { display: flex; align-items: center; gap: 10px; max-width: calc(var(--app-w) - 2 * var(--gutter)); margin: 0 auto; pointer-events: auto; }
.cta-inner > .btn, .cta-inner > form { flex: 1; }
.cta-inner .btn { height: 60px; border-radius: 30px; font-size: 18px; font-weight: 500; box-shadow: 0 18px 32px -14px rgba(16, 24, 40, .55); }
.cta-inner form .btn { width: 100%; }
.btn-dot { display: inline-block; width: 4px; height: 4px; margin: 0 4px; border-radius: 50%; background: currentColor; opacity: .55; }

/* ---------- Menu : feuille qui monte du bas ---------- */

.menu-sheet { position: fixed; inset: 0; width: auto; max-width: none; height: auto; max-height: none; margin: 0; padding: 0; border: 0; background: transparent; color: var(--text); overflow: hidden; overflow: clip; outline: none; }
.menu-sheet[open] { display: flex; align-items: flex-end; justify-content: center; }
.menu-sheet::backdrop { background: rgba(14, 16, 18, .4); animation: fade .35s var(--ease-out); }
.menu-sheet.is-closing::backdrop { animation: fade-out .3s ease-in forwards; }
.menu-panel { position: relative; width: 100%; max-width: 560px; max-height: calc(100vh - 40px); max-height: calc(100dvh - var(--safe-t) - 24px); overflow-y: auto; overscroll-behavior: contain; padding: 30px var(--gutter) calc(var(--safe-b) + 22px); background: var(--surface); border-radius: 32px 32px 0 0; box-shadow: 0 -20px 40px -24px rgba(16, 24, 40, .3); will-change: transform; backface-visibility: hidden; }
.menu-panel:focus { outline: none; }
.menu-handle { position: absolute; top: 9px; left: 50%; width: 56px; height: 4px; margin-left: -28px; border-radius: 4px; background: var(--handle); }
.menu-user { display: flex; align-items: center; gap: 14px; padding: 12px 16px 12px 12px; border-radius: var(--radius-card); background: var(--bg); }
.menu-user > span:not(.uav) { flex: 1; min-width: 0; }
.menu-user b { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 17px; }
.menu-user small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 14px; color: var(--text-3); }
.menu-user-chev { width: 20px; height: 20px; }
.menu-guest { padding: 18px; border-radius: var(--radius-card); background: var(--bg); }
.menu-guest b { font-size: 19px; }
.menu-guest p { margin-top: 4px; font-size: 15px; color: var(--text-2); }
.menu-guest-actions { display: flex; gap: 8px; margin-top: 14px; }
.menu-guest-actions .btn { flex: 1; }
.menu-guest-actions .btn-soft { background: var(--surface); }
.menu-tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 10px; }
.menu-tile { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 14px 4px 12px; border-radius: var(--radius-card); background: var(--bg); font-size: 13.5px; color: var(--text); transition: transform .45s var(--spring), background-color .2s; }
.menu-tile:active { transform: scale(.94); }
.menu-tile-ic { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; background: var(--surface); }
.menu-tile-ic .ic { width: 21px; height: 21px; }
.menu-tile.has-dot::after { top: 14px; right: calc(50% - 26px); }
.menu-group { margin: 22px 6px 8px; font-size: 14px; color: var(--text-3); }
.menu-list { overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-card); }
.menu-row { display: flex; align-items: center; gap: 12px; min-height: 58px; padding: 8px 16px 8px 10px; font-size: 16px; }
.menu-row + .menu-row { border-top: 1px solid var(--line); }
.menu-row > span:nth-child(2) { flex: 1; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.menu-row-ic { display: grid; place-items: center; width: 40px; height: 40px; flex: none; border-radius: 50%; background: var(--bg); }
.menu-row-ic .ic { width: 19px; height: 19px; }
.menu-row .chev { width: 18px; height: 18px; color: var(--text-3); }
.menu-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 20px; padding: 0 6px; font-size: 14px; color: var(--text-2); }
.menu-foot a { text-decoration: underline; text-underline-offset: 4px; }
.menu-logout { display: inline-flex; align-items: center; gap: 8px; padding: 0; border: 0; background: none; color: var(--danger); font-size: 15px; }
.menu-logout .ic { width: 18px; height: 18px; }

/* Navigation complète (barre latérale ordinateur) */
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav-group { margin: 22px 14px 6px; font-size: 13px; color: var(--text-3); }
.nav-group:first-child { margin-top: 0; }
.nav-link { display: flex; align-items: center; gap: 12px; width: 100%; height: 48px; padding: 0 16px; border: 0; border-radius: var(--radius-card); background: transparent; color: var(--text-2); font-size: 15.5px; text-align: left; transition: background-color .2s, color .2s; }
.nav-link .ic { width: 21px; height: 21px; }
.nav-link > span { min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.nav-link:hover { background: var(--bg); color: var(--text); }
.nav-link.is-active { background: var(--ink); color: #fff; }
.nav-danger, .nav-danger .ic { color: var(--danger); }
.nav-dot { margin-left: auto; width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--accent); }
.nav-badge { margin-left: auto; min-width: 22px; height: 22px; padding: 0 7px; border-radius: 11px; background: var(--accent); color: #fff; font-size: 12px; font-weight: 500; line-height: 22px; text-align: center; font-variant-numeric: tabular-nums; }
.nav-link.is-active .nav-badge { background: #fff; color: var(--ink); }

.sidebar { display: none; }
.sidebar-brand { gap: 11px; height: 44px; }
.sidebar-brand .brand-mark { height: 38px; }
.sidebar-brand .brand-name { height: 26px; margin-top: 4px; }
.sidebar-user { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: var(--radius-card); background: var(--bg); }
.sidebar-user > span:last-child { min-width: 0; }
.sidebar-user b { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 14.5px; }
.sidebar-user small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; color: var(--text-3); }

/* Avatars : initiales sur un dégradé propre à chaque compte */
.uav { display: grid; place-items: center; flex: none; width: 44px; height: 44px; border-radius: 50%; background: hsl(var(--h) 28% 90%); color: var(--ink); font-size: 15px; font-weight: 600; letter-spacing: .02em; }
.uav .ic { width: 22px; height: 22px; }
.uav-lg { width: 52px; height: 52px; font-size: 17px; }
.uav-xl { width: 76px; height: 76px; font-size: 25px; }
.uav-guest { background: var(--surface); color: var(--text); text-shadow: none; }
.avatar { display: grid; place-items: center; width: 40px; height: 40px; flex: none; border-radius: 50%; background: var(--ink); color: #fff; font-size: 14px; font-weight: 500; }
.avatar .ic { width: 18px; height: 18px; }
.avatar-sm { width: 36px; height: 36px; font-size: 12.5px; }
.avatar.is-off { background: var(--line); color: var(--text-3); }

/* Toasts */
.toasts { position: fixed; top: max(calc(var(--safe-t) + 10px), 14px); left: 0; right: 0; z-index: 70; display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 0 14px; pointer-events: none; }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 12px; width: 100%; max-width: 400px; padding: 9px; border-radius: 30px; background: var(--ink); color: #fff; box-shadow: var(--sh-float); font-size: 15px; animation: toast-in .7s var(--spring) both; }
.toast.is-leaving { animation: toast-out .22s ease-in forwards; }
.toast-ic { display: grid; place-items: center; width: 34px; height: 34px; flex: none; border-radius: 50%; background: #fff; color: var(--ok); }
.toast-ic .ic { width: 17px; height: 17px; }
.toast[data-type="error"] .toast-ic { color: var(--danger); }
.toast[data-type="info"] .toast-ic { color: var(--ink); }
.toast-msg { flex: 1; min-width: 0; }
.toast-close { display: grid; place-items: center; width: 34px; height: 34px; flex: none; border: 0; border-radius: 50%; background: transparent; color: rgba(255, 255, 255, .55); }
.toast-close:hover { background: rgba(255, 255, 255, .1); color: #fff; }
.toast-close .ic { width: 14px; height: 14px; }
@keyframes toast-in { from { opacity: 0; transform: translateY(-28px) scale(.9); } }
@keyframes toast-out { to { opacity: 0; transform: translateY(-10px) scale(.96); } }

/* ---------- Typographie ---------- */

.hello { padding-top: max(calc(var(--safe-t) + 4px), 16px); margin-bottom: 20px; }
.hello-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 20px; }
.hello-text { min-width: 0; }
.hello-title { font: 600 28px/1.2 var(--font); letter-spacing: -.025em; color: var(--text); }
.hello-sub { margin-top: 6px; font-size: 15px; line-height: 1.5; color: var(--text-2); }
.hello-avatar { position: relative; flex: none; border-radius: 50%; box-shadow: 0 0 0 2px var(--surface); transition: transform .5s var(--spring); }
.hello-avatar:active { transform: scale(.9); }
.hello-avatar.has-dot::after { top: 1px; right: 1px; }

.page-intro { margin: 10px 0 22px; }
.topbar.is-pushed ~ .app .page-intro .page-title { display: none; }
.topbar.is-pushed ~ .app .page-intro { margin-top: 0; }
.page-kicker { margin-bottom: 4px; font-size: 15px; color: var(--text-2); }
.page-title { font: 600 28px/1.2 var(--font); letter-spacing: -.025em; }
.page-sub { margin-top: 2px; font-size: 15px; color: var(--text-2); }
.lead-title, .title-lg { margin: 28px 0 16px; font: 600 22px/1.3 var(--font); letter-spacing: -.02em; }
.title-md { margin: 26px 0 14px; font: 600 21px/1.3 var(--font); }
.title-sm { margin: 22px 0 12px; font: 600 18px/1.3 var(--font); }
.title-sm small, .title-md small { margin-left: 6px; font-size: 14px; color: var(--text-3); }
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 16px; margin: var(--section-gap) 0 var(--section-inset); }
.section-head h2 { font: 600 22px/1.3 var(--font); letter-spacing: -.02em; }
.section-title { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 16px; margin: 28px 0 14px; font: 600 20px/1.3 var(--font); letter-spacing: -.015em; }
.section-title small { font-size: 14px; color: var(--text-3); }
.section-note { font-size: 14px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.subhead { margin: 26px 6px 10px; font-size: 14px; color: var(--text-3); }
.overline { margin-bottom: 6px; font-size: 14px; color: var(--text-3); }
.meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; font-size: 14px; color: var(--text-3); }
.meta-line { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.prose { max-width: 62ch; color: var(--desc); font-size: 16px; line-height: 1.6; }
.desc { margin-top: 24px; color: var(--desc); font-size: 16px; line-height: 1.6; }
.desc.is-clamped, .prose.is-clamped { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.read-more { display: inline-block; margin-top: 9px; }
.footnote { margin: 12px 6px 0; font-size: 14px; line-height: 1.5; color: var(--text-3); }
.footnote a { color: var(--text); text-decoration: underline; text-underline-offset: 3px; }
.footnote-center { margin: 22px 0; text-align: center; }
.footnote .ic { width: 15px; height: 15px; margin-right: 5px; vertical-align: -2px; }
.lead { margin: -6px 0 12px; font-size: 15px; }


/* ---------- Surfaces ---------- */

.card { padding: 20px; background: var(--surface); border-radius: var(--radius-card); }
.notice { display: flex; align-items: flex-start; gap: 12px; margin: 16px 0; padding: 14px 16px; border-radius: 22px; font-size: 14.5px; line-height: 1.5; }
.notice .ic { width: 20px; height: 20px; margin-top: 1px; }
.notice-danger { background: var(--danger-soft); color: #B4232A; }
.notice-info { background: var(--surface); color: var(--desc); }
.paper .notice-info { background: var(--bg); }
.notice-admin { background: var(--warn-soft); color: #7A4D00; }
.empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 48px 20px; text-align: center; }
.empty-page { min-height: 52dvh; justify-content: center; }
.empty h2 { font: 600 20px/1.3 var(--font); }
.empty p { max-width: 300px; margin-bottom: 18px; font-size: 15px; color: var(--text-2); }
.empty-ic { display: grid; place-items: center; width: 64px; height: 64px; margin-bottom: 8px; border-radius: 50%; background: var(--surface); color: var(--ink); }
.paper .empty-ic { background: var(--bg); }
.empty-ic .ic { width: 28px; height: 28px; }
.cta-card { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-top: var(--section-gap); padding: 24px; border-radius: var(--radius-card); background: var(--surface); }
.paper .cta-card { background: var(--bg); }
.cta-card b { font-size: 17px; }
.cta-card p { margin-top: 2px; font-size: 14px; color: var(--text-2); }
.panel-empty { padding: 18px 4px; font-size: 15px; color: var(--text-2); }

/* ---------- Boutons ---------- */

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: var(--control-h); padding: 12px 24px; border: 0; border-radius: var(--radius-pill); background: var(--surface); color: var(--text); font: 500 16px/1.3 var(--font); text-align: center; transition: transform .2s var(--ease-out), background-color .2s, box-shadow .2s, opacity .2s; }
.btn:active:not(:disabled) { transform: scale(.95); transition-duration: .1s; }
.btn:disabled { opacity: .45; cursor: default; }
.btn .ic { width: 20px; height: 20px; }
.btn-block { width: 100%; }
.btn-sm { min-height: 44px; padding: 10px 16px; font-size: 14px; }
.btn-sm .ic { width: 17px; height: 17px; }
.btn-primary { background: var(--ink); color: #fff; }
.btn-soft { background: var(--bg); color: var(--text); }
.btn-ghost { background: transparent; color: var(--text); box-shadow: inset 0 0 0 1px var(--line-2); }
.btn-ghost-danger { background: transparent; color: var(--danger); box-shadow: inset 0 0 0 1px rgba(229, 72, 77, .3); }
.form .btn-block { margin-top: 24px; }
@media (hover: hover) {
  .btn-primary:not(:disabled):hover { background: #000; }
  .btn-soft:not(:disabled):hover { background: #EAEDF0; }
  .btn-ghost:not(:disabled):hover { box-shadow: inset 0 0 0 1px var(--text-3); }
  .btn-ghost-danger:not(:disabled):hover { background: var(--danger-soft); }
}

.glass-btn { display: grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .95); color: var(--text); }
.glass-btn .ic { width: 19px; height: 19px; }
.glass-btn-sm { width: 28px; height: 28px; }
.glass-btn-sm .ic { width: 13px; height: 13px; }
.icon-btn { display: grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 50%; background: transparent; color: var(--text-2); transition: background-color .15s, color .15s; }
.icon-btn:hover { background: var(--bg); color: var(--text); }
.icon-btn .ic { width: 19px; height: 19px; }
.icon-btn-accent, .icon-btn-accent:hover { background: var(--ink); color: #fff; }

/* Pastille cerclée, comme « ☆ 5.0 » */
.pill-line { display: inline-flex; align-items: center; gap: 5px; flex: none; height: 30px; padding: 0 11px 0 9px; border: 1px solid var(--line-2); border-radius: 15px; color: var(--text); font-size: 15px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.pill-line .ic { width: 17px; height: 17px; }

/* ---------- Filtres en pilules ---------- */

.chips { display: flex; gap: 8px; margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter) 2px; overflow-x: auto; scroll-padding-inline: var(--gutter); scrollbar-width: none; }
.chips::-webkit-scrollbar, .tabs::-webkit-scrollbar { display: none; }
.chip { display: inline-flex; align-items: center; gap: 8px; flex: none; min-height: 44px; padding: 0 18px; border: 0; border-radius: var(--radius-pill); background: var(--surface); color: var(--text-2); font: 500 14px/1.3 var(--font); transition: background-color .2s, color .2s, transform .2s var(--ease-out); }
.chip .ic { width: 16px; height: 16px; }
.chip:active { transform: scale(.92); }
.chip.is-active { background: var(--ink); color: #fff; }
.chip-count { margin-left: 2px; font-size: 13px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.chip.is-active .chip-count { color: rgba(255, 255, 255, .75); }
.chips-filter { margin-top: 12px; }

/* Onglets en pilules */
.tabs { display: flex; gap: 8px; margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter) 2px; overflow-x: auto; scrollbar-width: none; }
.tab-pill { display: inline-flex; align-items: center; gap: 8px; flex: none; min-height: 44px; padding: 0 18px; border: 0; border-radius: var(--radius-pill); background: var(--surface); color: var(--text-2); font: 500 14px/1.3 var(--font); transition: background-color .2s, color .2s; }
.paper .tab-pill { background: var(--bg); }
.tab-pill:active { transform: scale(.94); }
.tab-pill.is-active { background: var(--ink); color: #fff; }
.sheet .tabs { margin-top: 0; }
.tab-panel + .tab-panel { margin-top: 8px; }
.tabs-js .tab-panel[data-inactive] { display: none; }
.tab-panel.is-entering { animation: panel-in .25s ease-out; }
@keyframes panel-in { from { opacity: 0; } }

/* ---------- Recherche ---------- */

.searchbar { display: flex; align-items: center; gap: 12px; height: 56px; padding: 0 6px 0 18px; border-radius: var(--radius-pill); background: var(--surface); color: var(--text); transition: box-shadow .2s; }
.searchbar + .tabs { margin-top: 14px; }
.searchbar:focus-within { box-shadow: 0 0 0 1.5px var(--ink); }
.searchbar > .ic { width: 22px; height: 22px; color: var(--text-2); }
.searchbar input { flex: 1; min-width: 0; height: 100%; padding: 0; border: 0; outline: 0; background: transparent; color: var(--text); font-size: 16px; }
.searchbar input::placeholder { color: var(--text-2); opacity: 1; }
.searchbar input::-webkit-search-cancel-button { display: none; }
.filter-btn { display: grid; place-items: center; width: 44px; height: 44px; flex: none; border-radius: 50%; background: var(--ink); color: #fff; transition: transform .2s var(--ease-out); }
.filter-btn:active { transform: scale(.96); }
.filter-btn .ic { width: 20px; height: 20px; }
.filter-count { position: absolute; top: -3px; right: -3px; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--accent); color: #fff; font-size: 11.5px; font-weight: 500; line-height: 20px; text-align: center; box-shadow: 0 0 0 2px var(--surface); }

/* Feuille de filtres : mêmes pilules que partout, bouton collé en bas */
.filter-panel { display: flex; flex-direction: column; padding-bottom: 0; }
.filter-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 6px; }
.filter-head h2 { font: 600 24px/1.25 var(--font); }
.filter-head .u-link { font-size: 15px; }
.filter-group { min-width: 0; margin: 18px 0 0; padding: 0; border: 0; }
.filter-group legend { padding: 0; font-size: 15px; color: var(--text-2); }
.filter-group legend small { margin-left: 4px; color: var(--text-3); }
.filter-group .segmented { flex-wrap: wrap; margin-top: 10px; }
.filter-panel .segmented span { background: var(--bg); }
.filter-switch { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 20px; padding: 14px 16px; border-radius: 22px; background: var(--bg); cursor: pointer; }
.filter-switch b { display: block; font-size: 16px; }
.filter-switch small { display: block; margin-top: 1px; font-size: 13.5px; color: var(--text-3); }
.filter-foot { position: sticky; bottom: 0; margin: 22px calc(var(--gutter) * -1) 0; padding: 12px var(--gutter) calc(var(--safe-b) + 16px); background: linear-gradient(rgba(255, 255, 255, 0), #fff 30%); }
.filter-foot .btn { height: 58px; font-size: 17px; }

.search { display: flex; align-items: center; gap: 8px; height: 50px; margin-bottom: 12px; padding: 0 5px 0 16px; border-radius: 25px; background: var(--surface); color: var(--text-3); }
.search:focus-within { box-shadow: 0 0 0 1.5px var(--ink); }
.search .ic { width: 19px; height: 19px; }
.search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--text); font-size: 16px; }
.search .btn-sm { height: 40px; }

/* ---------- Images ---------- */

.cover { width: 100%; height: 100%; object-fit: cover; }
.cover-none { display: grid; place-items: center; background: radial-gradient(120% 100% at 100% 0%, #4A5054 0%, transparent 65%), var(--ink); }
.cover-none span { font: 500 40px/1 var(--font); color: rgba(255, 255, 255, .85); }

/* ---------- Pile de cartes (accueil) ---------- */

.home-next, .page-actions, .deck-nav, .story-meta { display: none; }

.deck-stage { position: relative; }
#a-venir { scroll-margin-top: 90px; }
.deck { position: relative; height: var(--deck-h); margin: 22px -6px 0; touch-action: pan-y; }
/* Sans JavaScript : défilement horizontal simple */
.deck:not(.is-stacked) { display: flex; gap: 12px; margin: 22px calc(var(--gutter) * -1) 0; padding: 0 var(--gutter) 6px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.deck:not(.is-stacked)::-webkit-scrollbar { display: none; }
.deck:not(.is-stacked) > .deck-card { flex: none; width: 86%; height: 100%; scroll-snap-align: center; }
.deck.is-stacked > .deck-card { position: absolute; top: 0; bottom: 0; left: 18px; right: 18px; will-change: transform; transition: transform .55s var(--glide), opacity .4s var(--ease-out); }
.deck.is-dragging > .deck-card { transition: none; }
.deck.is-stacked > .deck-card[data-pos="hidden"] { pointer-events: none; }
.deck.is-empty { display: none; }

.deck-card { position: relative; overflow: hidden; isolation: isolate; border-radius: 28px; background: var(--ink); color: #fff; box-shadow: 0 30px 40px -26px rgba(16, 24, 40, .6), 0 2px 6px rgba(16, 24, 40, .06); -webkit-user-select: none; user-select: none; }
.deck-card > .cover { position: absolute; inset: 0; z-index: -2; }
.deck-card::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(8, 10, 12, 0) 38%, rgba(8, 10, 12, .32) 56%, rgba(8, 10, 12, .84) 80%, rgba(8, 10, 12, .95) 100%); pointer-events: none; }
.deck-body { position: absolute; left: 16px; right: 16px; bottom: 16px; }
.deck-kicker { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 15px; color: rgba(255, 255, 255, .86); }
.deck-title { margin-top: 1px; font: 600 22px/1.25 var(--font); color: #fff; }
.deck-title a { color: inherit; }
.deck-meta { display: flex; align-items: center; gap: 12px; margin-top: 9px; font-size: 14px; color: rgba(255, 255, 255, .72); font-variant-numeric: tabular-nums; }
.deck-pill { display: inline-flex; align-items: center; gap: 5px; height: 28px; padding: 0 11px 0 9px; border: 1px solid rgba(255, 255, 255, .42); border-radius: 14px; color: #fff; font-size: 15px; white-space: nowrap; }
.deck-pill .ic { width: 16px; height: 16px; }
.deck-cta { display: flex; align-items: center; height: 58px; margin-top: 14px; padding: 0 4px 0 0; border-radius: 29px; background: rgba(255, 255, 255, .17); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06); backdrop-filter: blur(16px) saturate(140%); -webkit-backdrop-filter: blur(16px) saturate(140%); pointer-events: none; }
.deck-cta > span:first-child { flex: 1; padding-left: 50px; text-align: center; font-size: 16px; font-weight: 500; }
@media (hover: none) { .deck-cta { background: rgba(255, 255, 255, .2); backdrop-filter: none; -webkit-backdrop-filter: none; } }
.deck-cta-go { display: grid; place-items: center; width: 50px; height: 50px; flex: none; border-radius: 50%; background: #fff; color: var(--text); transition: transform .5s var(--spring); }
.deck-cta-go .ic { width: 22px; height: 22px; }
.deck-card:hover .deck-cta-go { transform: translateX(-3px); }
/* Téléphone : « Voir plus » à glisser. Le rond part de la gauche et se tire jusqu'au bout (app.js).
   z-index 2 : au-dessus du lien qui couvre la carte, sinon le doigt attrape la pile. */
.deck:not(.is-slider) .deck-cta { position: relative; z-index: 2; padding: 0 0 0 4px; pointer-events: auto; touch-action: none; cursor: grab; }
.deck:not(.is-slider) .deck-cta > span:first-child { padding: 0 50px 0 0; opacity: calc(1 - var(--pulled, 0) * 1.4); transition: opacity .4s var(--ease-out); }
.deck:not(.is-slider) .deck-cta-go { order: -1; transform: translateX(var(--pull, 0px)); transition: transform .55s var(--spring); }
.deck:not(.is-slider) .deck-card:hover .deck-cta-go { transform: translateX(var(--pull, 0px)); }
.deck:not(.is-slider) .deck-cta.is-pulling, .deck:not(.is-slider) .deck-cta.is-pulling > span { cursor: grabbing; transition: none; }
.deck:not(.is-slider) .deck-cta.is-done .deck-cta-go { transition-duration: .22s; transition-timing-function: var(--ease-out); }
/* Carte « rien de plus pour le moment » : pas de photo, un fond sombre et doux */
.deck-fill { background: radial-gradient(120% 80% at 85% 0%, rgba(168, 32, 176, .32), transparent 60%), radial-gradient(90% 70% at 0% 100%, rgba(255, 255, 255, .1), transparent 60%), var(--ink); }
.deck-fill::after { display: none; }
.deck-fill-ic { position: absolute; top: 20px; left: 20px; display: grid; place-items: center; width: 60px; height: 60px; border-radius: 50%; background: rgba(255, 255, 255, .12); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16); color: #fff; }
.deck-fill-ic .ic { width: 26px; height: 26px; }
.deck-fill-text { margin-top: 8px; font-size: 15px; line-height: 1.45; color: rgba(255, 255, 255, .74); }
.deck.is-slider > .deck-fill { display: none; }

/* ---------- Cœur (favori) ---------- */

.fav { position: absolute; z-index: 3; margin: 0; }
.fav-btn { position: relative; display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; background: var(--surface); color: var(--text); transition: transform .2s var(--ease-out), background-color .2s; }
.fav-btn .ic { width: 20px; height: 20px; transition: transform .2s var(--ease-out); }
.fav-btn:active { transform: scale(.86); }
.fav-btn.is-on { --heart-fill: currentColor; }
.fav-btn.is-on .ic { animation: heart-pop .55s var(--spring); }
@keyframes heart-pop { 30% { transform: scale(1.35); } 60% { transform: scale(.9); } }
.fav-white { top: 12px; right: 12px; }
.fav-glass { top: 16px; right: 16px; }
.fav-glass .fav-btn { width: 48px; height: 48px; background: rgba(14, 16, 18, .22); color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .38); }
.fav-glass .fav-btn .ic { width: 22px; height: 22px; }
.fav-circle { position: static; }
.fav-burst { position: absolute; inset: 0; pointer-events: none; }
.fav-burst i { position: absolute; left: 50%; top: 50%; width: 5px; height: 5px; margin: -2.5px; border-radius: 50%; background: currentColor; animation: burst .6s var(--ease-out) forwards; }
@keyframes burst { from { transform: rotate(var(--r)) translateY(0) scale(1); opacity: 1; } to { transform: rotate(var(--r)) translateY(-26px) scale(.2); opacity: 0; } }

/* ---------- Cartes « à venir » ---------- */

.rail { display: flex; gap: 12px; margin: 0 calc(var(--gutter) * -1); padding: 2px var(--gutter) 26px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding: var(--gutter); scrollbar-width: none; }
.rail::-webkit-scrollbar { display: none; }
.rail > * { flex: none; scroll-snap-align: start; }

.tour { position: relative; display: flex; flex-direction: column; width: 303px; padding: 8px; background: var(--surface); border-radius: var(--radius-card); box-shadow: var(--sh-card); transition: transform .55s var(--spring), box-shadow .35s; }
.tour-media { position: relative; height: auto; aspect-ratio: 16 / 10; overflow: hidden; border-radius: var(--radius-field); background: var(--line); }
.tour-media .cover { transition: transform 1s var(--ease-expo); }
.tour:hover .tour-media .cover { transform: scale(1.05); }
.tour-body { display: flex; flex: 1; flex-direction: column; padding: 16px 12px 12px; }
.tour-title { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font: 600 18px/1.35 var(--font); letter-spacing: -.015em; }
.tour-title a { color: inherit; }
.tour-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 0; margin-top: 6px; font-size: 14px; color: var(--text-2); }
.tour-meta span { overflow: hidden; text-overflow: ellipsis; }
.tour-rate { display: flex; align-items: center; gap: 5px; margin-top: auto; padding: 20px 42px 0 0; font-size: 13px; color: var(--text-3); white-space: nowrap; }
.tour-rate .ic { width: 17px; height: 17px; color: var(--text-2); }
.tour-rate b { font-size: 14px; color: var(--text); font-weight: 500; font-variant-numeric: tabular-nums; }
.tour-go { position: absolute; z-index: 2; right: 16px; bottom: 16px; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--bg); color: var(--ink); pointer-events: none; transition: transform .2s var(--ease-out); }
.tour-go .ic { width: 19px; height: 19px; }
.tour:hover .tour-go { transform: translateX(3px); }
.tour:active { transform: scale(.98); }
.tour-fill, .home-next-fill { display: none; }
/* Piège à robots des formulaires publics : hors écran, ignoré des lecteurs d'écran */
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
/* Téléphone : la tuile termine le rail quand il n'y a qu'une ou deux soirées */
@media (max-width: 1023px) {
  .rail-tours.is-few > .tour-fill { display: flex; flex-direction: column; justify-content: center; gap: 8px; width: 303px; padding: 28px 24px; border-radius: var(--radius-card); background: var(--surface); box-shadow: inset 0 0 0 1.5px var(--line-2); }
  .rail-tours.is-few .tour-fill-ic { display: grid; place-items: center; width: 52px; height: 52px; margin-bottom: 6px; border-radius: 50%; background: var(--bg); color: var(--ink); }
  .rail-tours.is-few .tour-fill-ic .ic { width: 24px; height: 24px; }
  .rail-tours.is-few .tour-fill-title { font: 600 18px/1.3 var(--font); }
  .rail-tours.is-few .tour-fill-text { font-size: 14px; line-height: 1.45; color: var(--text-2); }
  .rail-tours.is-few .tour-fill-actions { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; margin-top: 10px; }
}
.grid-cards { display: grid; grid-template-columns: 1fr; gap: 12px; }
.grid-cards .tour { width: auto; }
.grid-cards .tour-media { height: auto; aspect-ratio: 16 / 10; }

/* Ligne de soirée (façon programme) */
.list-rows { display: flex; flex-direction: column; gap: 10px; }
.row-event { display: flex; align-items: center; gap: 16px; padding: 12px 18px 12px 12px; background: var(--surface); border-radius: var(--radius-card); }
.row-event-media { width: 100px; height: 76px; flex: none; overflow: hidden; border-radius: 14px; }
.row-event-media img { transition: transform .9s var(--ease-expo); }
.row-event-media .cover-none span { font-size: 26px; }
.row-event-body { flex: 1; min-width: 0; }
.row-event-date { font-size: 14px; color: var(--text-3); }
.row-event-body h3 { margin: 1px 0 2px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font: 500 16px/1.4 var(--font); }
.row-event-foot { display: flex; align-items: center; font-size: 14px; color: var(--text-3); }
.row-event-foot b { font-weight: 500; color: var(--text); font-variant-numeric: tabular-nums; }
.row-event-chev { display: grid; place-items: center; width: 24px; height: 24px; flex: none; color: var(--text); transition: transform .45s var(--spring); }
.row-event-chev .ic { width: 22px; height: 22px; }
.filter-empty { padding: 24px; text-align: center; font-size: 15px; color: var(--text-2); }

.memory { position: relative; width: 170px; aspect-ratio: 3 / 4; overflow: hidden; isolation: isolate; border-radius: var(--radius-card); background: var(--ink); transition: transform .6s var(--spring); }
.memory > .cover { position: absolute; inset: 0; z-index: -1; transition: transform 1s var(--ease-expo); }
.memory:hover > .cover { transform: scale(1.05); }
.memory::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(to top, rgba(8, 10, 12, .88), rgba(8, 10, 12, .5) 40%, transparent 70%); }
.memory-body { position: absolute; z-index: 1; left: 14px; right: 14px; bottom: 14px; color: #fff; }
.memory-body h3 { font: 500 16px/1.25 var(--font); }
.memory-body p { margin-top: 2px; font-size: 13px; color: rgba(255, 255, 255, .88); }

/* Jauge */
.meter-wrap { flex: 1; min-width: 0; margin-top: 14px; }
.meter { height: 6px; overflow: hidden; border-radius: 3px; background: rgba(16, 24, 40, .08); }
.meter span { display: block; height: 100%; border-radius: inherit; background: var(--ink); transition: width 1.4s var(--ease-expo); }
.meter.is-hot span { background: #F2A516; }
.meter.is-full span { background: var(--text-3); }
.meter-label { margin-top: 8px; font-size: 14px; color: var(--text-3); }
.meter.is-hot + .meter-label { color: var(--warn); }

/* ---------- Photo + feuille qui remonte (soirée, asso) ---------- */

.hero { position: relative; height: 276px; margin: 0 calc(var(--gutter) * -1); overflow: hidden; background: var(--ink); }
.hero-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-plain { background: radial-gradient(120% 120% at 100% 0%, #4A5054, transparent 60%), var(--ink); }
.hero-bar { position: absolute; z-index: 4; left: var(--gutter); right: var(--gutter); top: max(var(--safe-t), 14px); display: flex; justify-content: space-between; }
.hero-bar .fav-btn, .hero-bar .circle-btn { width: 50px; height: 50px; }
.hero-bar .fav-btn .ic, .topbar .fav-btn .ic { width: 25px; height: 25px; }

.sheet { position: relative; z-index: 2; margin: -32px calc(var(--gutter) * -1) 0; padding: 30px var(--gutter) 0; border-radius: 32px 32px 0 0; background: var(--bg); }
.sheet::before { content: none; }
.sheet-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.sheet-title { min-width: 0; font: 600 28px/1.2 var(--font); letter-spacing: -.025em; overflow-wrap: anywhere; }
.sheet-title .verified { width: 21px; height: 21px; margin-left: 6px; vertical-align: -2px; }
.sheet-head .pill-line { margin: 0; }
.sheet-line { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; margin-top: 16px; }
.sheet-org { display: inline-flex; align-items: center; gap: 8px; min-width: 0; max-width: 100%; font-size: 15px; color: var(--text); }
.sheet-org > span:last-child { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.sheet-org .org-avatar-xs { width: 22px; height: 22px; font-size: 8px; }
.sheet-line .u-link { flex: none; transform: none; font-size: 14px; }
.org-insta { margin-top: 14px; }

/* ---------- Feuille blanche (écrans « programme ») ---------- */

.paper { position: relative; margin: 16px 0 0; padding: 24px 20px; background: var(--surface); border-radius: var(--radius-card); }
.paper::before { content: none; }
.has-tabs .paper { padding-bottom: 24px; }
.has-cta .paper { padding-bottom: 24px; }
.paper > .title-md:first-child, .paper > .page-intro:first-child { margin-top: 0; }

/* Accordéon (jour par jour) */
.accs { display: flex; flex-direction: column; gap: 10px; }
.acc { border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--surface); transition: background-color .35s var(--ease-out), border-color .35s; }
.acc[open] { border-color: var(--line); border-radius: var(--radius-card); background: var(--surface); }
.sheet .acc { border-color: transparent; background: var(--surface); }
.acc-head { display: flex; align-items: center; gap: 16px; padding: 14px 18px 14px 14px; cursor: pointer; list-style: none; border-radius: inherit; }
.acc-head::-webkit-details-marker { display: none; }
.acc-head::marker { content: ""; }
.acc-thumb { position: relative; display: block; width: 100px; height: 76px; flex: none; overflow: hidden; border-radius: 14px; background: var(--bg); }
.acc-thumb .cover { position: absolute; inset: 0; }
.acc-thumb .cover-none span { font-size: 26px; }
.acc-thumb-ic { display: grid; place-items: center; width: 100%; height: 100%; background: var(--bg); color: var(--text); }
.acc[open] .acc-thumb-ic { background: var(--surface); }
.sheet .acc .acc-thumb-ic { background: var(--bg); }
.acc-thumb-ic .ic { width: 28px; height: 28px; }
.acc-titles { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.acc-titles small { font-size: 14px; color: var(--text-3); }
.acc-titles b { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 16px; font-weight: 500; line-height: 1.4; color: var(--text); }
.acc-chev { width: 22px; height: 22px; color: var(--text); transition: transform .5s var(--spring); }
.acc[open] .acc-chev { transform: rotate(180deg); }
.acc-body { padding: 4px 18px 20px; }
.acc-body .meter-wrap { margin-top: 16px; }
.acc-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.acc-actions form { display: contents; }
.acc-cta { margin-top: 16px; height: 50px; border-radius: 25px; font-size: 16px; }
.acc-note { margin-top: 12px; font-size: 13.5px; line-height: 1.5; color: var(--text-3); }
.acc-static { padding: 18px 18px 20px; border-radius: var(--radius-card); background: var(--bg); }
.acc-static + .acc-static, .accs + .acc-static { margin-top: 10px; }
.acc-static h3 { font: 600 17px/1.35 var(--font); }
.acc-static > p { margin: 4px 0 14px; font-size: 14.5px; }
.acc-static .u-link { display: inline-block; margin-top: 14px; font-size: 16px; }

.pairs { display: flex; flex-direction: column; gap: 12px; }
.pairs > div { min-width: 0; }
.pairs dt { font-size: 14px; line-height: 1.35; color: var(--text-3); }
.pairs dd { margin: 0; font-size: 16px; line-height: 1.5; color: var(--text); }
.pairs-amounts > div { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.pairs-amounts dd { font-variant-numeric: tabular-nums; }
.pairs-amounts .is-total { padding-top: 12px; border-top: 1px solid var(--line); }
.pairs-amounts .is-total dt { color: var(--text); font-size: 16px; }
.pairs-amounts .is-total dd { font-size: 18px; font-weight: 500; }

/* ---------- Infos de soirée ---------- */

.facts { display: flex; flex-direction: column; margin-top: 16px; padding: 4px 18px; background: var(--surface); border-radius: var(--radius-card); }
.facts li { display: flex; align-items: center; gap: 14px; padding: 14px 0; }
.facts li + li { border-top: 1px solid var(--line); }
.facts li > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.facts b { font-size: 16px; }
.facts span:not(.fact-ic) { font-size: 14px; color: var(--text-3); }
.fact-ic { display: grid; place-items: center; width: 44px; height: 44px; flex: none; border-radius: 50%; background: var(--bg); color: var(--text); }
.fact-ic .ic { width: 20px; height: 20px; }
.fact-link { flex: none; padding: 10px 16px; border-radius: 20px; background: var(--ink); color: #fff; font-size: 14px; }
.crowd { display: flex; flex-direction: column; gap: 14px; margin-top: 16px; }
.crowd-head { display: flex; align-items: flex-end; justify-content: space-between; }
.crowd-num { font: 600 32px/1 var(--font); font-variant-numeric: tabular-nums; }
.crowd-num small { font-size: 16px; color: var(--text-3); }
.access { display: flex; flex-direction: column; gap: 12px; }
.access li { display: flex; align-items: flex-start; gap: 12px; font-size: 15px; color: var(--desc); }
.access .ic { margin-top: 3px; }

.rail-photos .photo { width: 250px; aspect-ratio: 4 / 3; }
.photo { position: relative; padding: 0; border: 0; overflow: hidden; border-radius: 20px; background: #E9ECEF; }
.photo img { width: 100%; height: 100%; object-fit: cover; }
.photo:hover img { transform: scale(1.04); }
.album { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; overflow: hidden; border-radius: var(--radius-card); }

/* Soirée : date et lieu */
.event-facts { display: flex; flex-direction: column; gap: 10px; margin: 20px 0 0; padding: 0; list-style: none; }
.event-facts li { display: flex; align-items: center; gap: 14px; min-width: 0; }
.fact-ic { display: grid; place-items: center; width: 46px; height: 46px; flex: none; border-radius: 14px; background: var(--surface); color: var(--ink); }
.fact-ic .ic { width: 21px; height: 21px; }
.fact-txt { display: flex; flex-direction: column; min-width: 0; }
.fact-txt b { overflow: hidden; font-size: 16px; font-weight: 500; line-height: 1.35; white-space: nowrap; text-overflow: ellipsis; }
.fact-txt small { overflow: hidden; font-size: 14px; line-height: 1.4; color: var(--text-2); white-space: nowrap; text-overflow: ellipsis; }

/* Encart de réservation : ordinateur uniquement (sur mobile, la barre du bas) */
.ev-book { display: none; }
.ev-more .section-head { margin-top: var(--section-gap); }
.album .photo { aspect-ratio: 1; border-radius: 0; }

.lightbox { width: 100vw; height: 100dvh; max-width: 100vw; max-height: 100dvh; padding: 0; border: 0; background: rgba(10, 12, 14, .92);  }
.lightbox[open] { display: grid; place-items: center; animation: fade .25s; }
.lightbox img { max-width: 100%; max-height: 100%; object-fit: contain; }
.lightbox .glass-btn { position: absolute; top: max(calc(var(--safe-t) + 10px), 16px); right: 16px; }

/* ---------- Notifications ---------- */

.notifs { display: flex; flex-direction: column; gap: 10px; }
.notif { display: flex; align-items: center; gap: 14px; padding: 12px 16px 12px 12px; border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--surface); }
.notif-ic { display: grid; place-items: center; width: 64px; height: 56px; flex: none; border-radius: 14px; background: var(--bg); color: var(--text); }
.notif-ic .ic { width: 23px; height: 23px; }
.tone-accent { background: var(--ink); color: #fff; }
.tone-warn { background: var(--warn-soft); color: var(--warn); }
.notif-body { flex: 1; min-width: 0; }
.notif-body b { display: block; font-size: 16px; line-height: 1.35; }
.notif-body small { display: block; margin-top: 2px; font-size: 14px; color: var(--text-3); }
.notif-chev { width: 20px; height: 20px; color: var(--text); }

/* ---------- Listes groupées et formulaires ---------- */

.group { overflow: hidden; background: var(--surface); border-radius: var(--radius-card); }
.paper .group { border: 1px solid var(--line); border-radius: var(--radius-field); }
.group + .group { margin-top: 12px; }
.row { position: relative; display: flex; align-items: center; gap: 12px; min-height: 60px; padding: 14px 20px; font-size: 16px; }
.row + .row::before, .field + .field::before, .row + .field::before, .field + .row::before, .field-error + .field::before { content: ""; position: absolute; top: 0; left: 20px; right: 20px; height: 1px; background: var(--line); }
.row > span:first-child { flex: 1; min-width: 0; }
.row > span b { display: block; font-weight: 500; }
.row > span small { display: block; margin-top: 2px; line-height: 1.45; color: var(--text-3); font-size: 14px; }
.row > b { font-weight: 500; font-variant-numeric: tabular-nums; }
.row-total { background: var(--bg); }
.row-total > span { font-weight: 500; }
.row-total > b { font-size: 18px; }
.row-link { transition: background-color .2s; }
.row-link > span { flex: 1; }
.row-link > .ic:last-child, .row-link .chev { width: 20px; height: 20px; color: var(--text); transition: transform .4s var(--spring); }
.row-link .row-ic, .row-ic { width: 22px; height: 22px; color: var(--text); }
.row-link:active { background: var(--bg); }

.field { position: relative; display: flex; align-items: center; gap: 12px; min-height: 60px; padding: 0 20px; }
.field > span { width: 110px; flex: none; font-size: 15px; color: var(--text-3); }
.field input, .field textarea { flex: 1; min-width: 0; width: 100%; padding: 18px 0; border: 0; outline: 0; background: transparent; font-size: 16px; }
.field input::placeholder, .field textarea::placeholder, .row-form input::placeholder { color: var(--text-3); }
.field:focus-within > span { color: var(--text); }
.field-area { align-items: flex-start; }
.field-area > span { padding-top: 19px; }
.field-area textarea { resize: vertical; line-height: 1.55; }
.field.has-error > span { color: var(--danger); }
.field-error { margin: 8px 20px 0; font-size: 13.5px; color: var(--danger); }
.group .field-error { margin: 0; padding: 0 20px 12px; }
.row-form input { flex: 1; min-width: 0; padding: 8px 0; border: 0; outline: 0; background: transparent; font-size: 16px; }
.row-form .amount { flex: 0 0 96px; text-align: right; font-variant-numeric: tabular-nums; }
.row-form select { flex: 1; min-width: 0; }
.row-form select + select { flex: 0 0 auto; }

.row-switch { cursor: pointer; }
.switch { appearance: none; -webkit-appearance: none; position: relative; flex: none; width: 52px; height: 32px; margin: 0; border-radius: 16px; background: #E1E4E7; box-shadow: inset 0 0 0 1.5px var(--control); cursor: pointer; transition: background-color .3s var(--ease-out), box-shadow .3s; }
.switch:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 26px; height: 26px; border-radius: 13px; background: #fff; box-shadow: 0 2px 6px rgba(16, 24, 40, .18); transition: transform .5s var(--spring), width .3s var(--ease-out); }
.switch:active::after { width: 32px; }
.switch:checked { background: var(--ink); box-shadow: none; }
.switch:checked::after { transform: translateX(20px); }
.switch:checked:active::after { transform: translateX(14px); }

.check { display: flex; align-items: center; gap: 12px; cursor: pointer; font-size: 15px; }
.check input { position: absolute; opacity: 0; pointer-events: none; }
.check-box { display: grid; place-items: center; width: 24px; height: 24px; flex: none; border: 1.5px solid var(--control); border-radius: 8px; background: #fff; color: transparent; transition: background-color .2s, border-color .2s, color .2s, transform .4s var(--spring); }
.check-box .ic { width: 15px; height: 15px; }
.check input:checked + .check-box { border-color: var(--ink); background: var(--ink); color: #fff; transform: scale(1.08); }
.check input:focus-visible + .check-box { outline: 2px solid var(--ink); outline-offset: 2px; }

.segmented, .switcher { display: flex; gap: 8px; margin-top: 16px; }
.segmented label { flex: none; }
.segmented input { position: absolute; opacity: 0; }
.segmented span, .switcher a { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 36px; padding: 0 21px; border-radius: 18px; background: var(--surface); color: var(--text-2); font-size: 15px; cursor: pointer; transition: background-color .3s, color .25s; }
.paper .segmented span { background: var(--bg); }
.segmented input:checked + span, .switcher a.is-active { background: var(--ink); color: #fff; }
.segmented input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 2px; }

select { appearance: none; -webkit-appearance: none; padding: 10px 36px 10px 16px; border: 0; border-radius: 20px; background: var(--bg) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230E1012' stroke-width='1.8' stroke-linecap='round'%3E%3Cpath d='M6 9.5l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center / 16px; font-size: 15px; }
.field select { flex: 1; padding: 16px 32px 16px 0; border-radius: 0; background-color: transparent; background-position: right 0 center; font-size: 16px; }

/* ---------- Réservation ---------- */

.mini-event { display: flex; align-items: center; gap: 16px; margin: 8px 0; padding: 12px; background: var(--surface); border-radius: var(--radius-card); }
.mini-event-media { width: 100px; height: 76px; flex: none; overflow: hidden; border-radius: 14px; }
.mini-event-media .cover-none span { font-size: 24px; }
.mini-event h1 { margin-bottom: 2px; font: 600 18px/1.3 var(--font); }
.consent-card { margin-top: 12px; }
.consent-card .group { margin-top: 14px; border: 0; }
.consent-card .btn-block { margin-top: 16px; }
.rules { margin-top: 10px; }
.rules ul { display: flex; flex-direction: column; gap: 8px; margin: 12px 0 16px; padding-left: 20px; list-style: disc; font-size: 15px; color: var(--desc); }
.rules li::marker { color: var(--text-3); }
.fake-card { display: flex; flex-direction: column; justify-content: space-between; aspect-ratio: 1.586; max-width: 400px; margin: 8px auto 24px; padding: 22px 24px; border-radius: var(--radius-card); background: radial-gradient(120% 120% at 100% 0%, #4A5054, transparent 60%), var(--ink); color: #fff; box-shadow: var(--sh-float); }
.fake-card-top { display: flex; align-items: center; justify-content: space-between; font: 500 20px/1 var(--font); }
.fake-card-num { font-size: 19px; letter-spacing: .14em; font-variant-numeric: tabular-nums; }
.fake-card-foot { display: flex; gap: 24px; font-size: 13px; color: rgba(255, 255, 255, .65); }

/* ---------- Billets ---------- */

.stubs { display: flex; flex-direction: column; gap: 10px; }
.stub { display: flex; align-items: center; padding: 12px; background: var(--surface); border-radius: var(--radius-card); }
.stub-date { display: flex; flex-direction: column; align-items: center; justify-content: center; width: 64px; height: 64px; flex: none; margin-right: 14px; border-radius: 16px; background: var(--ink); color: rgba(255, 255, 255, .7); font-size: 12px; text-transform: uppercase; }
.stub-date b { font-size: 22px; line-height: 1; color: #fff; font-variant-numeric: tabular-nums; }
.stub-body { flex: 1; min-width: 0; }
.stub-body h3 { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font: 500 16px/1.35 var(--font); }
.stub-status { display: inline-flex; margin-top: 6px; padding: 3px 10px; border-radius: 12px; background: var(--bg); font-size: 12.5px; }
.stub-go { display: grid; place-items: center; width: 36px; }
.stub.is-past .stub-date { background: var(--bg); color: var(--text-3); }
.stub.is-past .stub-date b { color: var(--text-2); }

.success { display: flex; align-items: center; gap: 12px; margin: 0 0 20px; padding: 10px 18px 10px 10px; border-radius: 30px; background: var(--bg); }
.success-ic { display: grid; place-items: center; width: 42px; height: 42px; flex: none; border-radius: 50%; background: var(--ok); color: #fff; animation: pop .7s var(--spring) .2s both; }
.success-ic .ic { width: 20px; height: 20px; }
.success div { display: flex; flex-direction: column; }
.success b { font-size: 16px; }
.success span { font-size: 14px; color: var(--text-2); }
.confetti { position: fixed; inset: 0; z-index: 80; pointer-events: none; }

/* Le billet : carte grise sur la feuille blanche, perforée, QR code */
.ticket { position: relative; max-width: 380px; margin: 0 auto; transition: margin .6s var(--spring); }
.ticket-main { position: relative; padding: 8px 8px 20px; border-radius: 28px 28px 0 0; background: var(--bg); overflow: hidden; }
.ticket-eye { position: relative; height: 176px; overflow: hidden; border-radius: 20px; background: var(--ink); }
.ticket-eye img, .ticket-eye > span:first-child { display: block; width: 100%; height: 100%; object-fit: cover; }
.ticket-brand { position: absolute; left: 12px; top: 12px; padding: 7px 12px; border-radius: 15px; background: rgba(255, 255, 255, .92); font-size: 13px; font-weight: 500; }
.ticket-title { margin: 16px 10px 0; font: 600 24px/1.2 var(--font); }
.ticket-sub { margin: 3px 10px 0; font-size: 15px; color: var(--text-3); }
.ticket-pairs { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 12px; margin: 18px 10px 0; }
.ticket-pairs .is-wide { grid-column: 1 / -1; }
.ticket-pairs dt { font-size: 14px; color: var(--text-3); }
.ticket-pairs dd { margin: 1px 0 0; font-size: 16px; }
.ticket-perf { position: relative; height: 0; }
.ticket-perf::before { content: ""; position: absolute; z-index: 1; left: 26px; right: 26px; top: -1px; border-top: 2px dashed var(--line-2); }
.ticket-stub { position: relative; display: flex; flex-direction: column; align-items: center; padding: 22px 20px 24px; border-radius: 0 0 28px 28px; background: var(--bg); }
.ticket-label { font-size: 14px; color: var(--text-3); }
.ticket-num { margin: 2px 0 16px; font-size: 17px; font-weight: 500; letter-spacing: .12em; font-variant-numeric: tabular-nums; }
.qr { width: 212px; height: 212px; padding: 16px; border-radius: var(--radius-card); background: #fff; }
.qr svg { display: block; width: 100%; height: 100%; }
/* Paiements de l'asso (Stripe Connect) */
.pay-card { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; padding: 24px 22px; border-radius: var(--radius-card); background: var(--surface); box-shadow: var(--sh-card); }
.pay-card h2 { font: 600 20px/1.3 var(--font); }
.pay-card p { font-size: 15px; line-height: 1.55; color: var(--text-2); }
.pay-card form { margin-top: 8px; }
.pay-card-ic { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; background: var(--bg); color: var(--ink); }
.pay-card-ic .ic { width: 24px; height: 24px; }
.pay-card-ic.is-warn { background: var(--warn-soft); color: var(--warn); }
.pay-card-ic.is-ok { background: var(--ok-soft); color: var(--ok); }
.pay-steps { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; counter-reset: step; }
.pay-steps li { position: relative; padding: 16px 18px 16px 58px; border-radius: var(--radius-card); background: var(--surface); font-size: 15px; line-height: 1.5; color: var(--text-2); counter-increment: step; }
.pay-steps li::before { content: counter(step); position: absolute; left: 18px; top: 15px; display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--ink); color: #fff; font-size: 13px; font-weight: 600; }
.pay-steps b { display: block; color: var(--text); font-weight: 500; }
.row-note { display: block; margin-top: 2px; font-size: 13px; color: var(--warn); }
/* Activation de la double authentification (admins) */
.mfa-setup { display: flex; flex-direction: column; align-items: center; gap: 4px; margin: 4px 0 20px; text-align: center; }
.mfa-qr { box-shadow: inset 0 0 0 1px var(--line); }
.mfa-key { display: inline-block; margin-top: 6px; padding: 6px 12px; border-radius: 10px; background: var(--bg); color: var(--text); font: 600 15px/1.4 ui-monospace, Menlo, Consolas, monospace; letter-spacing: .06em; user-select: all; }
.admit { margin-top: 18px; padding: 11px 20px; border-radius: 20px; background: var(--ink); color: #fff; font-size: 14px; }
.ticket .qr { transition: opacity .6s var(--ease); }
.ticket.is-used .qr { opacity: .18; }
.stamp { position: absolute; top: 48%; left: 50%; transform: translate(-50%, -50%) rotate(-6deg); padding: 11px 20px; border-radius: 22px; background: var(--danger); color: #fff; font-size: 14px; font-weight: 500; box-shadow: var(--sh-float); }

/* Billet vivant : il se balance comme du papier, le talon plie sur la perforation, un reflet glisse.
   motion.js pose --rx/--ry (inclinaison), --flex (pli du talon), --mx/--my (lumière) et --lift. */
.ticket.is-live { --rx: 0; --ry: 0; --flex: 0; --mx: 50; --my: 30; --lift: 0; perspective: 900px; touch-action: pan-y; filter: drop-shadow(calc(var(--ry) * -0.9px) calc(14px + var(--lift) * 10px) calc(18px + var(--lift) * 14px) rgba(16, 24, 40, calc(.10 + var(--lift) * .08))); }
.ticket.is-live .ticket-inner { transform: rotateX(calc(var(--rx) * 1deg)) rotateY(calc(var(--ry) * 1deg)) translateZ(calc(var(--lift) * 18px)); transform-style: preserve-3d; will-change: transform; }
.ticket.is-live .ticket-stub { transform: rotateX(calc(var(--flex) * 1deg)); transform-origin: 50% 0; overflow: hidden; }
.ticket.is-live .ticket-perf { transform: translateZ(1px); }
.ticket.is-live .ticket-main::after, .ticket.is-live .ticket-stub::after { content: ""; position: absolute; inset: 0; z-index: 2; border-radius: inherit; pointer-events: none; }
/* Reflet satiné : une bande claire qui suit la lumière + un léger irisé, en lumière douce pour ne pas gêner le scan du QR */
.ticket.is-live .ticket-main::after { background: radial-gradient(70% 55% at calc(var(--mx) * 1%) calc(var(--my) * 1%), rgba(255, 255, 255, calc(.38 + var(--lift) * .22)), transparent 70%), linear-gradient(115deg, transparent calc(var(--mx) * 1% - 28%), rgba(255, 255, 255, .5) calc(var(--mx) * 1% - 6%), rgba(190, 220, 255, .28) calc(var(--mx) * 1%), rgba(255, 200, 240, .22) calc(var(--mx) * 1% + 8%), transparent calc(var(--mx) * 1% + 30%)); mix-blend-mode: soft-light; }
.ticket.is-live .ticket-stub::after { background: radial-gradient(70% 90% at calc(var(--mx) * 1%) calc(var(--my) * 1% - 100%), rgba(255, 255, 255, calc(.30 + var(--lift) * .2)), transparent 70%), linear-gradient(115deg, transparent calc(var(--mx) * 1% - 28%), rgba(255, 255, 255, .4) calc(var(--mx) * 1% - 6%), rgba(190, 220, 255, .22) calc(var(--mx) * 1%), transparent calc(var(--mx) * 1% + 26%)), linear-gradient(rgba(0, 0, 0, calc(var(--flex) * .012)), transparent 40%); mix-blend-mode: soft-light; }
/* Impression : le billet sort d'une fente, par à-coups, puis retombe. Rejouée au clic (motion.js). */
.ticket-printer { position: relative; max-width: 380px; margin: 12px auto 0; }
.ticket-printer.is-printing { clip-path: inset(-8px -80px -100vh -80px); }
.ticket-printer.is-printing .ticket-feed { animation: ticket-print 2.4s var(--ease) both; }
.ticket-printer.is-printing::before, .ticket-printer.is-printing::after { content: ""; position: absolute; z-index: 5; pointer-events: none; animation: ticket-slot 2.4s var(--ease) both; }
.ticket-printer.is-printing::before { left: -10px; right: -10px; top: -8px; height: 16px; border-radius: 8px; background: linear-gradient(var(--ink) 45%, #000 50% 60%, var(--ink) 65%); box-shadow: var(--sh-float); }
.ticket-printer.is-printing::after { left: 0; right: 0; top: 8px; height: 26px; background: linear-gradient(rgba(16, 24, 40, .22), transparent); }
@keyframes ticket-print {
  0%, 10% { transform: translateY(-100%); }
  22%, 27% { transform: translateY(-82%); }
  39%, 44% { transform: translateY(-62%); }
  56%, 61% { transform: translateY(-42%); }
  73%, 78% { transform: translateY(-20%); }
  90% { transform: translateY(0); }
  95% { transform: translateY(8px); }
  100% { transform: none; }
}
@keyframes ticket-slot { 0% { opacity: 0; translate: 0 -6px; } 8%, 88% { opacity: 1; translate: 0 0; } 100% { opacity: 0; translate: 0 -6px; } }

/* Talon découpé au scan : bords déchirés en dents de scie, le talon se détache et pend un peu */
.ticket.is-torn { margin-bottom: 30px; }
.ticket.is-torn .ticket-perf::before { display: none; }
.ticket.is-torn .ticket-main { -webkit-mask: conic-gradient(from -45deg at 50% 100%, #000 90deg, #0000 0) 0 100% / 10px 5px repeat-x, linear-gradient(#000 0 0) 0 0 / 100% calc(100% - 5px) no-repeat; mask: conic-gradient(from -45deg at 50% 100%, #000 90deg, #0000 0) 0 100% / 10px 5px repeat-x, linear-gradient(#000 0 0) 0 0 / 100% calc(100% - 5px) no-repeat; }
.ticket.is-torn .ticket-stub { translate: 0 22px; rotate: 3deg; transform-origin: 50% 0; -webkit-mask: conic-gradient(from 135deg at 50% 0, #000 90deg, #0000 0) 0 0 / 10px 5px repeat-x, linear-gradient(#000 0 0) 0 5px / 100% 100% no-repeat; mask: conic-gradient(from 135deg at 50% 0, #000 90deg, #0000 0) 0 0 / 10px 5px repeat-x, linear-gradient(#000 0 0) 0 5px / 100% 100% no-repeat; }
.ticket.is-tearing .ticket-stub { animation: ticket-tear 1.2s var(--ease) both; }
.ticket.is-tearing .ticket-main { animation: ticket-tug .5s var(--ease) both; }
.ticket.is-tearing .stamp { animation: stamp-in .5s var(--spring) .7s both; }
@keyframes ticket-tear {
  0% { translate: 0 0; rotate: 0deg; }
  15% { translate: 0 3px; rotate: -1.4deg; }
  28% { translate: 0 1px; rotate: 1deg; }
  55% { translate: 0 30px; rotate: 5.5deg; }
  76% { translate: 0 19px; rotate: 2.4deg; }
  100% { translate: 0 22px; rotate: 3deg; }
}
@keyframes ticket-tug { 30% { translate: 0 -3px; } }
@keyframes stamp-in { from { opacity: 0; scale: 1.8; } }

/* Grain de papier, très discret */
.ticket.is-live .ticket-main::before { content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none; opacity: .07; mix-blend-mode: multiply; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }

/* ---------- Connexion / inscription ---------- */

.is-bare .app { max-width: none; padding: 0; }
.auth { display: flex; flex-direction: column; min-height: 100dvh; background: var(--bg); }
.auth-hero { position: relative; isolation: isolate; display: flex; flex-direction: column; min-height: max(360px, 46dvh); padding: max(calc(var(--safe-t) + 10px), 18px) var(--gutter) 60px; overflow: hidden; color: #fff; background: var(--ink); }
.auth-bg { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
/* Voile franc : le texte reste lisible quelle que soit la photo */
.auth-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(10, 12, 14, .55) 0%, rgba(10, 12, 14, .25) 30%, rgba(10, 12, 14, .78) 68%, rgba(10, 12, 14, .94) 100%); }
.auth-hero-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 48px; }
.auth-brand { height: 48px; padding: 0 18px 0 14px; border-radius: 24px; background: #fff; box-shadow: 0 8px 24px -12px rgba(0, 0, 0, .5); }
.auth-brand .brand-mark { height: 27px; }
.auth-brand .brand-name { height: 18px; }
.auth-skip { display: inline-flex; align-items: center; gap: 2px; height: 40px; padding: 0 12px 0 18px; border-radius: 20px; background: #fff; color: var(--text); font-size: 15px; font-weight: 500; transition: background-color .2s; }
.auth-skip:hover { background: #ECEEF0; }
.auth-skip .ic { width: 16px; height: 16px; }
.auth-hero-copy { margin-top: auto; padding-top: 40px; max-width: 560px; }
.auth-headline { font: 700 34px/1.08 var(--font); letter-spacing: -.03em; color: #fff; text-shadow: 0 2px 18px rgba(0, 0, 0, .35); }
.auth-accent { display: block; color: #fff; }
.auth-lead { margin-top: 12px; max-width: 46ch; font-size: 16px; line-height: 1.5; color: #fff; text-shadow: 0 1px 12px rgba(0, 0, 0, .45); }
.auth-points { display: none; }

.auth-sheet { position: relative; flex: 1; margin-top: -32px; padding: 26px var(--gutter) calc(var(--safe-b) + 32px); border-radius: 32px 32px 0 0; background: var(--bg); }
.auth-sheet::before { content: none; }
.auth-switch { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; margin: 0 0 28px; padding: 4px; border-radius: 26px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.auth-switch a { display: grid; place-items: center; height: 44px; border-radius: 22px; color: var(--text-2); font-size: 15.5px; font-weight: 500; transition: background-color .25s, color .2s; }
.auth-switch a:not(.is-active):hover { color: var(--text); background: var(--bg); }
.auth-switch a.is-active { background: var(--ink); color: #fff; }
.auth-head { margin-bottom: 22px; }
.auth-head h2 { font: 700 26px/1.2 var(--font); letter-spacing: -.02em; color: var(--text); }
.auth-head p { margin-top: 8px; font-size: 15.5px; line-height: 1.5; color: var(--text-2); }
.auth-form { display: flex; flex-direction: column; gap: 18px; }
.auth-form .input label { margin: 0 0 8px 4px; font-size: 14.5px; font-weight: 500; color: var(--text); }
.auth-form .input-hint { margin-left: 4px; color: var(--text-2); }
.auth-form .input-error { margin-left: 4px; }
.auth-form > .btn-block, .step > .btn-block { height: 58px; margin-top: 6px; border-radius: 29px; font-size: 17px; }
.auth-foot { margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--line); text-align: center; font-size: 15px; color: var(--text-2); }
.auth-foot a, .auth-legal a { color: var(--text); font-weight: 500; text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 4px; }
.auth-legal { font-size: 14px; line-height: 1.5; color: var(--text-2); }
.alert { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 16px; padding: 14px 16px; border-radius: 22px; background: var(--danger-soft); color: #B4232A; font-size: 14.5px; animation: shake .45s var(--ease-out); }
.alert .ic { width: 19px; height: 19px; }

.input label { display: block; margin: 0 0 8px 8px; font-size: 14px; color: var(--text-2); }
.input-box { display: flex; align-items: center; gap: 10px; height: 56px; padding: 0 6px 0 16px; border-radius: var(--radius-field); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow .2s; }
.input-box:focus-within { box-shadow: 0 0 0 1.5px var(--ink); }
.input-ic { width: 21px; height: 21px; color: var(--text-3); transition: color .2s; }
.input-box:focus-within .input-ic { color: var(--text); }
.input-box input { flex: 1; width: 100%; min-width: 0; height: 100%; padding-right: 12px; border: 0; outline: 0; background: transparent; font-size: 17px; }
.input-box input::placeholder { color: var(--text-3); }
.input-reveal { display: grid; place-items: center; width: 46px; height: 46px; flex: none; border: 0; border-radius: 50%; background: transparent; color: var(--text-2); }
.input-reveal:hover { background: var(--bg); color: var(--text); }
.input-reveal .ic { width: 20px; height: 20px; }
.input.has-error .input-box { box-shadow: 0 0 0 1.5px var(--danger); animation: shake .45s var(--ease-out); }
.input-error { margin: 8px 0 0 10px; font-size: 13.5px; color: var(--danger); }
.input-hint { margin: 8px 0 0 10px; font-size: 13px; color: var(--text-3); }
.input-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.input-row > .input { min-width: 0; }

.step { display: flex; flex-direction: column; gap: 16px; min-width: 0; margin: 0; padding: 0; border: 0; }
.step + .step { margin-top: 32px; }
.steps, [data-next], [data-prev] { display: none; }
.is-stepped .steps { display: block; }
.is-stepped [data-next], .is-stepped [data-prev] { display: inline-flex; }
.is-stepped .step { display: none; margin: 0; }
.is-stepped .step.is-current { display: flex; animation: step-in .3s ease-out; }
.is-stepped .step.is-back { animation-name: step-back; }
@keyframes step-in { from { opacity: 0; transform: translateX(12px); } }
@keyframes step-back { from { opacity: 0; transform: translateX(-12px); } }
.steps-bar { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.steps-bar span { height: 4px; border-radius: 2px; background: var(--line); transition: background-color .5s var(--ease-out); }
.steps-bar span.is-done { background: var(--ink); }
.steps-label { margin-top: 8px; font-size: 13.5px; color: var(--text-2); }
.steps-label b { color: var(--text); }
.step-nav { display: flex; gap: 10px; margin-top: 8px; }
.step-nav .btn { height: 58px; border-radius: 29px; }
.step-nav .btn-primary { flex: 1; font-size: 17px; }
.strength { margin-top: -8px; }
.strength div { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.strength span { height: 4px; border-radius: 2px; background: var(--line); transition: background-color .3s; }
.strength p { min-height: 1em; margin-top: 8px; font-size: 13px; color: var(--text-2); }
.strength[data-level="1"] span:nth-child(-n+1) { background: var(--danger); }
.strength[data-level="2"] span:nth-child(-n+2) { background: #F2A516; }
.strength[data-level="3"] span { background: var(--ok); }
.accept-all { align-self: flex-start; display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 18px; border: 0; border-radius: 20px; background: var(--surface); font-size: 15px; }
.accept-all .ic { width: 16px; height: 16px; }
.consents { display: flex; flex-direction: column; gap: 10px; }
.consent { position: relative; display: flex; align-items: flex-start; gap: 12px; padding: 16px; border-radius: 22px; background: var(--surface); cursor: pointer; transition: box-shadow .25s; }
.consent input { position: absolute; opacity: 0; pointer-events: none; }
.consent-box { display: grid; place-items: center; width: 24px; height: 24px; flex: none; margin-top: 1px; border: 1.5px solid var(--control); border-radius: 8px; color: transparent; transition: background-color .2s, border-color .2s, color .2s, transform .4s var(--spring); }
.consent-box .ic { width: 15px; height: 15px; }
.consent:has(input:checked) { box-shadow: inset 0 0 0 1.5px var(--ink); }
.consent:has(input:focus-visible) { outline: 2px solid var(--ink); outline-offset: 2px; }
.consent input:checked + .consent-box { border-color: var(--ink); background: var(--ink); color: #fff; transform: scale(1.08); }
.consent-text b { display: block; font-size: 16px; }
.consent-text small { display: block; margin-top: 2px; font-size: 13.5px; line-height: 1.5; color: var(--text-3); }

/* ---------- Profil ---------- */

.me { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 16px; padding: 16px; border-radius: var(--radius-card); background: var(--bg); }
.me-id { flex: 1; min-width: 0; }
.me h2 { font: 600 20px/1.3 var(--font); }
.me .muted { margin-top: 2px; font-size: 14px; color: var(--text-3); }
.me-stats { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; width: 100%; }
.me-stats a { display: inline-flex; align-items: baseline; gap: 5px; height: 40px; padding: 0 16px; border-radius: 20px; background: var(--surface); font-size: 14px; color: var(--text-2); line-height: 40px; }
.me-stats b { font-size: 17px; color: var(--text); font-variant-numeric: tabular-nums; }
.role-pill { display: inline-flex; align-items: center; height: 40px; padding: 0 16px; border-radius: 20px; background: var(--ink); color: #fff; font-size: 14px; }
.logout { margin-top: 12px; }
.legal h2 { margin: 30px 0 8px; font: 600 19px/1.3 var(--font); color: var(--text); }
.legal p + p, .legal ul + p, .legal p + ul, .legal .table-wrap + p { margin-top: 10px; }
.legal ul { display: flex; flex-direction: column; gap: 8px; padding-left: 20px; list-style: disc; }

/* ---------- Bureau ---------- */

.kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 16px; }
.kpi { min-width: 0; container-type: inline-size; display: flex; flex-direction: column; gap: 12px; padding: 18px; background: var(--surface); border-radius: var(--radius-card); }
.kpi span, .kpi dt { font-size: 14px; color: var(--text-3); }
.kpi dt { color: var(--text-2); font-weight: 500; }
/* Le chiffre tient toujours en entier : sa taille suit la largeur de la tuile. */
.kpi b, .kpi dd { white-space: nowrap; font-size: clamp(15px, 13cqi, 26px); line-height: 1.15; font-variant-numeric: tabular-nums; }
.kpi b small { font-size: 14px; color: var(--text-3); }
.kpi-accent { background: var(--ink); color: #fff; }
.kpi-accent span { color: rgba(255, 255, 255, .6); }
.kpi-accent dt { color: rgba(255, 255, 255, .85); }
.kpi dd.kpi-note { margin-top: -6px; white-space: normal; font-size: 13.5px; line-height: 1.45; color: var(--text-2); }
.kpi-accent dd.kpi-note { color: rgba(255, 255, 255, .8); }
.group-links { margin-top: 20px; }
.admin-events { display: grid; gap: 10px; }
.admin-event { display: flex; flex-direction: column; gap: 14px; padding: 16px; background: var(--surface); border-radius: var(--radius-card); }
.admin-event-head { display: flex; align-items: center; gap: 14px; }
.admin-event-head > div:nth-child(2) { flex: 1; min-width: 0; }
.admin-event-head .status { flex: none; align-self: flex-start; }
.admin-event-media { width: 72px; height: 60px; flex: none; overflow: hidden; border-radius: 14px; }
.admin-event-media .cover-none span { font-size: 20px; }
.admin-event h3 { margin: 0 0 2px; font: 600 17px/1.3 var(--font); }
.admin-event .meta { color: var(--text-2); }
.admin-event-nums { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding-top: 14px; border-top: 1px solid var(--line); }
.admin-event-nums dt { font-size: 13.5px; color: var(--text-2); }
.admin-event-nums dd { margin-top: 2px; font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.admin-event-nums dd small { font-size: 14px; font-weight: 400; color: var(--text-2); }
.admin-event .meter-wrap { margin-top: 0; }
.admin-event .meter-label { margin-top: 6px; color: var(--text-2); }
/* Tableau de bord : des sections titrées, des listes sans puces, des lignes d'action explicites */
.dash-sub { margin-top: 4px; font-size: 15px; color: var(--text-2); }
.dash-section + .dash-section, .dash-section + .empty-card, .empty-card + .dash-section { margin-top: var(--section-gap); }
.dash-section > .section-title { margin-top: 0; }
.dash-section > .section-title small { color: var(--text-2); font-weight: 500; }
.dash-section > .section-title:has(.count-pill) { justify-content: flex-start; align-items: center; gap: 10px; }
.count-pill { min-width: 26px; padding: 2px 9px; border-radius: 13px; background: var(--line); color: var(--text); font-size: 14px; font-weight: 600; text-align: center; font-variant-numeric: tabular-nums; }
.dash-section ul { margin: 0; padding: 0; list-style: none; }
.group > li { position: relative; }
.group > li + li > .row::before { content: ""; position: absolute; top: 0; left: 20px; right: 20px; height: 1px; background: var(--line); }
.row-todo .row-ic { color: var(--warn); }
.row-todo > span small { color: var(--text-2); }
.dash-empty { padding: 20px; border-radius: var(--radius-card); background: var(--surface); color: var(--text-2); font-size: 15px; }
.status { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px 3px 8px; border-radius: 12px; font-size: 13.5px; line-height: 1.6; }
.status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.status-live { background: var(--ok-soft); color: var(--ok); }
.status-draft, .status-past { background: var(--bg); color: var(--text-2); }
.status-cancelled { background: var(--danger-soft); color: var(--danger); }
.actions { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 16px; }
.action { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 14px 4px 12px; background: var(--surface); border-radius: 22px; color: var(--text); }
.action .ic { width: 22px; height: 22px; transition: transform .5s var(--spring); }
.action span { font-size: 13px; }
.action:active { transform: scale(.95); }
.people { max-height: 480px; overflow-y: auto; }
.people .row > span { flex: 1; min-width: 0; }
.people .row > span b, .people .row > span small { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.dot { width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--text-3); }
.dot-on { background: var(--ok); box-shadow: 0 0 0 4px var(--ok-soft); }
.photo-block + .photo-block { margin-top: 10px; }
.photo-block-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.photo-block-head h3 { font: 600 16px/1.3 var(--font); }
.photo-block-head .muted { font-size: 13px; }
.photo-block .album { margin-top: 14px; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); border-radius: 20px; }
.album-admin form { position: absolute; top: 6px; right: 6px; }
.danger-zone { margin-top: 40px; }
.member select { font-size: 14px; }
.cover-picker { position: relative; display: grid; place-items: center; aspect-ratio: 16 / 9; overflow: hidden; border: 1.5px dashed var(--line-2); border-radius: var(--radius-card); background: var(--img, none) center / cover, var(--surface); cursor: pointer; transition: border-color .2s; }
.cover-picker:hover { border-color: var(--ink); }
.cover-picker[style*="--img"] { border: 0; }
.cover-picker-hint { display: flex; align-items: center; gap: 8px; height: 42px; padding: 0 18px; border-radius: 21px; background: var(--ink); color: #fff; font-size: 14.5px; }
.cover-picker-hint .ic { width: 17px; height: 17px; }

.scan-pick select { width: 100%; height: 52px; margin-bottom: 16px; background-color: var(--surface); border-radius: var(--radius-card); }
.scanner { position: relative; display: grid; place-items: center; aspect-ratio: 1; overflow: hidden; border-radius: 32px; background: #0E1012; }
.scanner video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.scanner-frame { position: absolute; inset: 18%; border-radius: 28px; box-shadow: 0 0 0 999px rgba(0, 0, 0, .5); pointer-events: none; background: linear-gradient(#fff, #fff) top left / 30px 3px no-repeat, linear-gradient(#fff, #fff) top left / 3px 30px no-repeat, linear-gradient(#fff, #fff) top right / 30px 3px no-repeat, linear-gradient(#fff, #fff) top right / 3px 30px no-repeat, linear-gradient(#fff, #fff) bottom left / 30px 3px no-repeat, linear-gradient(#fff, #fff) bottom left / 3px 30px no-repeat, linear-gradient(#fff, #fff) bottom right / 30px 3px no-repeat, linear-gradient(#fff, #fff) bottom right / 3px 30px no-repeat; }
.scanner.is-live .scanner-frame::after { content: ""; position: absolute; left: 8%; right: 8%; top: 0; height: 2px; border-radius: 2px; background: #fff; box-shadow: 0 0 14px 3px rgba(255, 255, 255, .55); animation: scanline 2.4s var(--ease) infinite alternate; }
@keyframes scanline { to { top: calc(100% - 2px); } }
.scanner-start { position: relative; z-index: 1; }
.scanner .btn { background: #fff; color: var(--text); }
.scanner.is-live .scanner-start { display: none; }
.scanner-msg { position: absolute; left: 16px; right: 16px; bottom: 16px; text-align: center; font-size: 14px; color: rgba(255, 255, 255, .8); }
.scan-count { margin: 24px 0; text-align: center; font-size: 15px; color: var(--text-2); }
.scan-count b { margin-right: 4px; font-size: 30px; color: var(--text); font-variant-numeric: tabular-nums; }
.manual { height: 56px; }
.verdict { position: fixed; inset: 0; z-index: 60; display: grid; align-items: end; padding: 16px; padding-bottom: max(calc(var(--safe-b) + 8px), 16px); background: rgba(10, 12, 14, .5); animation: fade .15s; }
.verdict-card { width: 100%; max-width: 460px; margin: 0 auto; padding: 34px 22px 22px; border-radius: 32px; text-align: center; color: #fff; box-shadow: var(--sh-float); animation: verdict-up .6s var(--spring); }
.verdict.is-ok .verdict-card { background: linear-gradient(180deg, #1BA466, #12804E); }
.verdict.is-ko .verdict-card { background: linear-gradient(180deg, #E2453F, #B52A24); }
.verdict-ic { display: grid; place-items: center; width: 64px; height: 64px; margin: 0 auto 16px; border-radius: 50%; background: #fff; animation: pop .5s .05s var(--spring) both; }
.verdict.is-ok .verdict-ic { color: #12804E; }
.verdict.is-ko .verdict-ic { color: #B52A24; }
.verdict-ic .ic { width: 30px; height: 30px; }
.verdict h2 { font: 600 24px/1.2 var(--font); }
.verdict-name { margin-top: 8px; font-size: 18px; }
.verdict p { margin-top: 4px; }
.verdict .muted { color: rgba(255, 255, 255, .85); }
.verdict .btn { margin-top: 20px; background: rgba(0, 0, 0, .2); color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18); }
@keyframes verdict-up { from { opacity: 0; transform: translateY(60px) scale(.9); } }

/* ---------- Assos ---------- */

.org-avatar { display: grid; place-items: center; flex: none; width: 46px; height: 46px; overflow: hidden; border-radius: 50%; object-fit: cover; background: var(--bg); }
.org-avatar-none { background: var(--ink); color: #fff; font-size: 14px; font-weight: 500; letter-spacing: .02em; }
.org-avatar-xs { width: 22px; height: 22px; font-size: 8px; }
.org-avatar-sm { width: 36px; height: 36px; font-size: 12px; }
.org-avatar-lg { width: 58px; height: 58px; font-size: 18px; }
.org-avatar-xl { width: 92px; height: 92px; font-size: 28px; }
.group .row > .org-avatar, .group .row > .avatar, .group .row > .uav { flex: 0 0 auto; }
.verified { display: inline-block; width: 17px; height: 17px; margin-left: 5px; vertical-align: -2px; color: var(--accent); }
.page-title .verified { width: 21px; height: 21px; }
.flyer-org { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 13px; }

/* Tes assos, façon stories */
.stories { display: flex; gap: 14px; margin: 0 calc(var(--gutter) * -1); padding: 2px var(--gutter) 4px; overflow-x: auto; scrollbar-width: none; }
.stories::-webkit-scrollbar { display: none; }
.story { display: flex; flex-direction: column; align-items: center; gap: 8px; width: 76px; flex: none; }
.story-ring { position: relative; display: grid; grid-template: minmax(0, 1fr) / minmax(0, 1fr); place-items: center; flex: none; aspect-ratio: 1; width: 72px; height: 72px; padding: 4px; border-radius: 50%; background: var(--surface); transition: transform .5s var(--spring); }
.story:active .story-ring { transform: scale(.9); }
.story-ring .org-avatar { width: 100%; height: 100%; min-width: 0; min-height: 0; aspect-ratio: 1; object-fit: cover; }
/* Anneau qui tourne : rotation (composée sur le GPU), pas de repeinte du dégradé à chaque image */
.story-ring.is-live { overflow: hidden; isolation: isolate; background: none; }
.story-ring.is-live::before { content: ""; position: absolute; inset: 0; z-index: -1; background: conic-gradient(var(--ink), #9AA0A6, var(--ink)); }
.story-ring.is-live .org-avatar { box-shadow: 0 0 0 2.5px var(--bg); }
.story-add { background: transparent; box-shadow: inset 0 0 0 1.5px var(--line-2); color: var(--text-2); }
.story-add .ic { width: 22px; height: 22px; }
.story-name { width: 100%; font-size: 12.5px; line-height: 1.3; text-align: center; color: var(--text-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.follow-card { margin-top: 30px; padding: 20px 0 18px; border-radius: var(--radius-card); background: var(--surface); }
.follow-card-head { padding: 0 20px 14px; }
.follow-card h2 { font: 600 21px/1.3 var(--font); }
.follow-card p { margin-top: 4px; font-size: 15px; color: var(--text-2); }
.rail-orgs { margin: 0; padding: 2px 20px 4px; scroll-padding: 20px; }
.org-tile { display: flex; flex-direction: column; align-items: center; gap: 12px; width: 152px; padding: 18px 12px 12px; border-radius: 22px; background: var(--bg); }
.org-tile-link { display: flex; flex-direction: column; align-items: center; gap: 4px; width: 100%; text-align: center; }
.org-tile-link .org-avatar { margin-bottom: 6px; }
.org-tile b { max-width: 100%; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 14.5px; }
.org-tile small { color: var(--text-3); }
.org-tile form, .org-tile .btn { width: 100%; }

/* Bouton S'abonner / Abonné */
.follow-btn .follow-on, .follow-btn.is-on .follow-off { display: none; }
.follow-btn.is-on .follow-on { display: inline-flex; }
.follow-btn span { align-items: center; gap: 6px; }
.follow-btn .follow-off { display: inline-flex; }
.follow-btn .ic { width: 16px; height: 16px; }
.cta-inner .follow-btn.is-on { background: var(--surface); color: var(--text); box-shadow: inset 0 0 0 1px var(--line-2), 0 18px 32px -18px rgba(16, 24, 40, .35); }

/* Annuaire */
.org-list { display: flex; flex-direction: column; gap: 10px; }
.org-row { display: flex; align-items: center; gap: 12px; padding: 12px 14px 12px 12px; background: var(--surface); border-radius: var(--radius-card); }
.org-row-main { flex: 1; min-width: 0; display: flex; align-items: center; gap: 14px; }
.org-row-thumb { position: relative; display: grid; place-items: center; width: 84px; height: 64px; flex: none; overflow: hidden; border-radius: 14px; background: var(--bg); }
.org-row-thumb .cover { position: absolute; inset: 0; }
.org-row-thumb .cover + .org-avatar { position: absolute; left: 6px; bottom: 6px; width: 26px; height: 26px; font-size: 9px; box-shadow: 0 0 0 2px #fff; }
.org-row-body { min-width: 0; display: flex; flex-direction: column; }
.org-row-body small { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 13.5px; color: var(--text-3); }
.org-row-body b { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 16px; line-height: 1.35; }
.org-row-meta { display: flex; align-items: center; margin-top: 1px; overflow: hidden; white-space: nowrap; font-size: 13.5px; color: var(--text-3); }
.org-row .btn-sm { padding: 0 14px; }

/* Bureau d'une asso */
.org-head { display: flex; align-items: center; gap: 16px; margin: 10px 0 24px; }
.notice b { font-weight: 500; }

/* Logo à choisir */
.logo-picker { display: flex; align-items: center; gap: 16px; margin-top: 16px; padding: 14px 18px 14px 14px; background: var(--surface); border-radius: var(--radius-card); cursor: pointer; }
.paper .logo-picker { background: var(--bg); }
.logo-picker > span:last-child { display: flex; flex-direction: column; }
.logo-picker-img { display: grid; place-items: center; width: 64px; height: 64px; flex: none; border-radius: 50%; border: 1.5px dashed var(--line-2); background: var(--img, none) center / cover, var(--surface); color: var(--text-3); }
.logo-picker-img .ic { width: 21px; height: 21px; }
.logo-picker-img.has-img { border: 0; }
.logo-picker-img.has-img .ic { display: none; }

/* ---------- Admin Tapage ---------- */

.stack { display: flex; flex-direction: column; gap: 12px; }
.mod-grid { display: grid; gap: 10px; }
.chips + .mod-grid, .chips + .empty, .chips + .group { margin-top: 16px; }

/* Équipe : recherche d'un profil avec suggestions */
.team-add { padding: 18px; border-radius: var(--radius-card); background: var(--surface); }
.people-search { position: relative; }
.people-input { display: flex; align-items: center; gap: 10px; height: 54px; padding: 0 16px; border-radius: 16px; background: var(--bg); box-shadow: inset 0 0 0 1px transparent; transition: box-shadow .2s, background-color .2s; cursor: text; }
.people-input:focus-within { background: var(--surface); box-shadow: inset 0 0 0 1.5px var(--ink); }
.people-input > .ic { width: 20px; height: 20px; flex: none; color: var(--text-2); }
.people-input input { flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent; font-size: 16px; }
.people-input input::placeholder { color: var(--text-3); }
.people-spinner { width: 18px; height: 18px; flex: none; border: 2px solid var(--line-2); border-top-color: var(--ink); border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.people-list { position: absolute; z-index: 20; top: calc(100% + 8px); left: 0; right: 0; max-height: 320px; margin: 0; padding: 6px; overflow-y: auto; list-style: none; border-radius: 20px; background: var(--surface); box-shadow: 0 0 0 1px var(--line), 0 24px 48px -20px rgba(16, 24, 40, .35); }
.people-opt { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 14px; cursor: pointer; }
.people-opt[aria-selected="true"] { background: var(--bg); }
.people-opt .uav { width: 40px; height: 40px; font-size: 14px; }
.people-opt-txt, .people-picked-txt { display: flex; flex-direction: column; min-width: 0; }
.people-opt-txt b, .people-picked-txt b { overflow: hidden; font-size: 15.5px; font-weight: 500; white-space: nowrap; text-overflow: ellipsis; }
.people-opt-txt mark { background: none; color: inherit; font-weight: 700; }
.people-opt-txt small, .people-picked-txt small { overflow: hidden; font-size: 13.5px; color: var(--text-2); white-space: nowrap; text-overflow: ellipsis; }
.people-empty { display: flex; flex-direction: column; gap: 2px; padding: 14px; font-size: 15px; font-weight: 500; }
.people-empty small { font-size: 13.5px; font-weight: 400; color: var(--text-2); }
.people-picked { display: flex; align-items: center; gap: 12px; min-height: 54px; padding: 8px 16px 8px 8px; border-radius: 16px; background: var(--bg); box-shadow: inset 0 0 0 1.5px var(--ink); }
.people-picked[hidden], .people-search[hidden] { display: none; }
.people-picked .uav { width: 40px; height: 40px; font-size: 14px; }
.people-picked-txt { flex: 1; }
.team-add-label { margin: 18px 4px 10px; font-size: 14.5px; font-weight: 500; }
.team-add .segmented { margin: 0; flex-wrap: wrap; }
.team-add .segmented span { background: var(--bg); }
.team-add .segmented input:checked + span { background: var(--ink); }
.team-add-btn { margin-top: 18px; }

/* Accueil filtré : résultats, filtres actifs retirables, tout effacer */
.filter-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 8px; margin-top: 14px; }
.filter-bar-count { order: -2; flex: 1 1 calc(100% - 150px); font-size: 15px; color: var(--text-2); }
.filter-bar-count b { font-weight: 600; color: var(--text); }
.filter-tokens { display: contents; margin: 0; padding: 0; list-style: none; }
.filter-tokens li { display: contents; }
.filter-token { display: inline-flex; align-items: center; gap: 8px; max-width: 100%; height: 36px; padding: 0 10px 0 14px; border-radius: 18px; background: var(--ink); color: #fff; font-size: 14px; font-weight: 500; transition: background-color .2s, transform .2s var(--ease-out); }
.filter-token span { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.filter-token .ic { flex: none; width: 13px; height: 13px; opacity: .8; }
.filter-token:hover { background: #000; }
.filter-token:active, .filter-clear:active { transform: scale(.95); }
.filter-clear { order: -1; display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px 0 12px; border-radius: 18px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line-2); color: var(--text); font-size: 14px; font-weight: 500; transition: box-shadow .2s, transform .2s var(--ease-out); }
.filter-clear .ic { width: 12px; height: 12px; }
.filter-clear:hover { box-shadow: inset 0 0 0 1px var(--ink); }
.empty-card { margin-top: 20px; padding: 40px 24px 28px; border-radius: var(--radius-card); background: var(--surface); }
.empty-card .empty-ic { background: var(--bg); }
.empty-card p { max-width: 340px; margin-bottom: 20px; }
.empty-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; width: 100%; }
.empty-actions .btn { flex: 1 1 200px; max-width: 260px; }
.mod-card .meta + .meta { margin-top: -8px; }
.mod-card { display: flex; flex-direction: column; gap: 12px; padding: 18px; background: var(--surface); border-radius: var(--radius-card); }
.mod-card-head { display: flex; align-items: center; gap: 12px; }
.mod-card-title { min-width: 0; }
.mod-card h3 { margin: 4px 0 1px; font: 600 16px/1.3 var(--font); }
.mod-card-desc { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; font-size: 14.5px; color: var(--text-2); }
.mod-actions { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 12px; border-top: 1px solid var(--line); }
.mod-actions form { display: contents; }
.user-list .status { flex: none; }
.audit-row small + small { color: var(--text-3); }
.split > * { min-width: 0; }

/* ---------- Survol (souris) ---------- */

@media (hover: hover) {
  .circle-btn:hover, .square-btn:hover { background: #fff; box-shadow: 0 8px 18px -10px rgba(16, 24, 40, .35); }
  .tour:hover { transform: translateY(-3px); box-shadow: 0 2px 4px rgba(16, 24, 40, .04), 0 24px 40px -24px rgba(16, 24, 40, .3); }
  .row-event, .org-row, .notif, .action { transition: transform .5s var(--spring); }
  .row-event:hover, .org-row:hover, .notif:hover, .action:hover { transform: translateY(-2px); }
  .row-event:hover .row-event-chev, .row-link:hover .chev { transform: translateX(3px); }
  .row-link:hover { background: #FAFBFC; }
  .action:hover .ic { transform: scale(1.15) rotate(-6deg); }
  .acc:not([open]):hover { border-color: var(--line-2); }
  .tab:not(.is-active):hover { color: rgba(255, 255, 255, .7); }
  .chip:not(.is-active):hover, .tab-pill:not(.is-active):hover { color: var(--text); }
}

/* ---------- Page d'asso personnalisée (couleurs du BDE) ----------
   --brand / --brand-ink : couleur principale et texte lisible dessus
   --brand-2 / --brand-2-ink : couleur secondaire (détails) */

.sheet-org .ic { width: 17px; height: 17px; color: var(--text-3); }

/* Page asso : en-tête façon profil, « À propos », soirées */
.org-head { display: grid; grid-template-columns: minmax(0, 1fr); }
.org-badge { position: relative; z-index: 3; width: max-content; margin: -78px 0 14px; padding: 4px; border-radius: 50%; background: var(--bg); }
.org-badge .org-avatar-xl { width: 88px; height: 88px; font-size: 26px; box-shadow: 0 10px 24px -14px rgba(16, 24, 40, .5); }
.org-id { min-width: 0; }
.org-tagline { margin-top: 6px; font-size: 17px; line-height: 1.45; color: var(--text-2); }
.org-meta { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0 0; padding: 0; list-style: none; }
.org-meta li { display: inline-flex; align-items: center; gap: 6px; height: 34px; max-width: 100%; padding: 0 14px 0 11px; border-radius: 17px; background: var(--surface); font-size: 14.5px; color: var(--text); white-space: nowrap; }
.org-meta li .ic { width: 16px; height: 16px; flex: none; color: var(--text-2); }
.org-meta li b { font-weight: 600; font-variant-numeric: tabular-nums; }
.org-meta .org-kind { background: var(--ink); color: #fff; }
.org-meta .org-kind .ic { color: inherit; }
.org-actions { display: none; }
.org-body { display: flex; flex-direction: column; }
.org-about { margin-top: 24px; padding: 20px; border-radius: var(--radius-card); background: var(--surface); }
.org-about-title { font: 600 18px/1.3 var(--font); }
.org-about .desc { margin-top: 8px; font-size: 15.5px; }
.org-stats { display: grid; grid-template-columns: repeat(3, 1fr); margin: 18px 0 0; padding-top: 16px; border-top: 1px solid var(--line); text-align: center; }
.org-stats div + div { border-left: 1px solid var(--line); }
.org-stats dd { margin: 0; font-size: 22px; font-weight: 600; line-height: 1.2; font-variant-numeric: tabular-nums; }
.org-stats dt { margin-top: 2px; font-size: 13px; color: var(--text-2); }
.org-link { display: flex; align-items: center; gap: 10px; height: 52px; margin-top: 16px; padding: 0 14px; border-radius: 16px; background: var(--bg); font-size: 15px; font-weight: 500; transition: background-color .2s; }
.org-link:hover { background: var(--line); }
.org-link .ic { width: 20px; height: 20px; flex: none; }
.org-link span { flex: 1; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.org-link-chev { color: var(--text-3); }

.is-themed .hero-plain { background: radial-gradient(90% 120% at 100% 0%, var(--brand-2), transparent 62%), var(--brand); }
.is-themed .btn-primary { background: var(--brand); color: var(--brand-ink); }
.is-themed .org-meta .org-kind { background: var(--brand-2); color: var(--brand-2-ink); }
.is-themed .sheet-org-page .section-head h2 { display: inline-flex; align-items: center; gap: 10px; }
.is-themed .sheet-org-page .section-head h2::before { content: ""; width: 4px; height: 20px; border-radius: 2px; background: var(--brand-2); }
.is-themed .org-link > .ic:first-child { color: var(--brand); }
@media (hover: hover) { .is-themed .btn-primary:not(:disabled):hover { background: var(--brand); filter: brightness(.9); } }

/* Réglages : identité visuelle */
.brand-label { margin: 22px 6px 10px; font-size: 14.5px; font-weight: 500; color: var(--text); }
.brand-preview { --brand: var(--ink); --brand-ink: #fff; --brand-2: #A820B0; --brand-2-ink: #fff; overflow: hidden; border-radius: var(--radius-card); background: var(--surface); box-shadow: var(--sh-card); }
.brand-preview-cover { height: 132px; background: var(--img, none) center var(--focus, center) / cover, radial-gradient(90% 120% at 100% 0%, var(--brand-2), transparent 62%), var(--brand); transition: background-position .3s var(--ease-out); }
.brand-preview-body { display: flex; flex-direction: column; align-items: flex-start; padding: 0 20px 20px; }
.brand-preview-logo { margin-top: -32px; padding: 3px; border-radius: 50%; background: var(--surface); }
.brand-preview-name { margin-top: 10px; font-size: 20px; font-weight: 600; letter-spacing: -.015em; }
.brand-preview-tagline { margin-top: 2px; font-size: 14.5px; color: var(--text-2); }
.brand-preview-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.brand-preview-btn { display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 18px 0 14px; border-radius: 20px; background: var(--brand); color: var(--brand-ink); font-size: 14.5px; font-weight: 500; transition: background-color .25s, color .25s; }
.brand-preview-btn .ic { width: 16px; height: 16px; }
.brand-preview-chip { display: inline-flex; align-items: center; height: 40px; padding: 0 16px; border-radius: 20px; background: var(--brand-2); color: var(--brand-2-ink); font-size: 14.5px; transition: background-color .25s, color .25s; }
.palettes { display: flex; flex-wrap: wrap; gap: 8px; }
.palette { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 14px 0 8px; border: 0; border-radius: 20px; background: var(--surface); color: var(--text); font-size: 14.5px; box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow .2s; }
.palette:hover { box-shadow: inset 0 0 0 1px var(--line-2); }
.palette.is-active { box-shadow: inset 0 0 0 2px var(--ink); }
.palette-dots { display: inline-flex; }
.palette-dots i { width: 22px; height: 22px; border-radius: 50%; box-shadow: 0 0 0 2px var(--surface); }
.palette-dots i + i { margin-left: -7px; }
.field-color input[type="color"] { flex: none; width: 34px; height: 34px; padding: 0; border: 0; border-radius: 50%; background: none; cursor: pointer; }
.field-color input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
.field-color input[type="color"]::-webkit-color-swatch { border: 1px solid var(--line-2); border-radius: 50%; }
.field-color input[type="color"]::-moz-color-swatch { border: 1px solid var(--line-2); border-radius: 50%; }
.field-color input[data-hex] { font-variant-numeric: tabular-nums; letter-spacing: .02em; text-transform: uppercase; }
.form .segmented { margin: 0 0 16px; }
/* Création / modification de soirée : l'essentiel en clair, les options repliées */
#event-form .section-title { margin: 36px 0 12px; }
#event-form .group + .group { margin-top: 12px; }
#event-form .footnote { margin: 10px 20px 0; }
#event-form .footnote + .group { margin-top: 10px; }
#event-form .subhead { margin: 20px 20px 8px; }
.field-unit { flex: none; font-style: normal; font-size: 15px; color: var(--text-3); }
/* Choix du statut : une ligne par option, un rond à droite */
.row-choice { cursor: pointer; }
.radio { appearance: none; -webkit-appearance: none; flex: none; width: 24px; height: 24px; margin: 0; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--control); cursor: pointer; transition: box-shadow .3s var(--spring); }
.radio:checked { box-shadow: inset 0 0 0 7px var(--ink); }
.radio:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
.row-choice.is-danger .radio:checked { box-shadow: inset 0 0 0 7px var(--danger); }
.row-choice.is-danger:has(:checked) b { color: var(--danger); }
/* Options facultatives : des cartes qui s'ouvrent */
.opts { display: flex; flex-direction: column; gap: 10px; }
.opt { scroll-margin-top: 80px; }
.opt-head { display: flex; align-items: center; gap: 14px; min-height: 72px; padding: 12px 18px 12px 14px; border-radius: var(--radius-card); background: var(--surface); cursor: pointer; list-style: none; transition: transform .2s var(--ease-out); }
.opt-head:active { transform: scale(.98); }
.opt-head::-webkit-details-marker { display: none; }
.opt-head::marker { content: ""; }
.opt-head:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.opt-ic { display: grid; place-items: center; width: 44px; height: 44px; flex: none; border-radius: 50%; background: var(--bg); color: var(--text); }
.opt-ic .ic { width: 20px; height: 20px; }
.opt-titles { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.opt-titles b { font-size: 16px; font-weight: 500; }
.opt-titles small { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 14px; color: var(--text-3); }
.opt-chev { width: 22px; height: 22px; flex: none; transition: transform .5s var(--spring); }
.opt[open] .opt-chev { transform: rotate(180deg); }
.opt-body { padding: 10px 0 14px; }
.opt-body > .bp > .subhead:first-of-type { margin-top: 8px; }
/* Prix par paliers : une ligne = un nombre de places et son prix */
.tier { gap: 10px; padding-right: 8px; }
.tier > .tier-name { display: flex; flex-direction: column; width: 96px; font-size: 15px; line-height: 1.3; }
.tier-name b { font-weight: 500; color: var(--text); }
.tier-name small { font-size: 12.5px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.tier.has-error .tier-name b { color: var(--danger); }
#event-form .tier-intro { margin: 0 20px 10px; }
/* Récapitulatif des paliers : une ligne par plage de places, le prix normal en dernier */
.tier-plan { margin: 12px 0 0; padding: 6px 16px; border-radius: var(--radius-card); box-shadow: inset 0 0 0 1px var(--line-2); list-style: none; }
.tier-plan li { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0 10px 18px; }
.tier-plan li + li { border-top: 1px solid var(--line); }
.tier-plan li::before { content: ""; position: absolute; left: 0; top: 50%; width: 8px; height: 8px; margin-top: -4px; border-radius: 50%; background: var(--ink); }
.tier-plan li.is-base::before { background: var(--control); }
.tier-plan li.is-over b { color: var(--danger); }
.tier-plan li > span { display: flex; flex-direction: column; min-width: 0; }
.tier-plan b { font-size: 15px; font-weight: 500; font-variant-numeric: tabular-nums; }
.tier-plan small { font-size: 13px; color: var(--text-3); }
.tier-plan-price { align-items: flex-end; text-align: right; white-space: nowrap; }
.tier-plan-price b { font-weight: 600; }
.tier-input { display: flex; flex: 1; align-items: baseline; gap: 6px; min-width: 0; }
.tier-input input { flex: 0 1 7ch; width: 0; }
.tier-input small { flex: none; font-size: 14px; color: var(--text-3); }
.tier .icon-btn { flex: none; }
#event-form .tier-add { margin: 12px 0 0; }
#event-form > .field-error { margin: 10px 20px 0; }
.check-line { display: flex; align-items: center; gap: 10px; margin: 16px 6px 0; font-size: 15px; color: var(--text-2); cursor: pointer; }
.check-line input { width: 18px; height: 18px; accent-color: var(--ink); }

/* ---------- Admin : gains par soirée ---------- */

.profit-search { margin-top: 20px; }
.profit-empty { margin-top: 16px; }
.profit-wrap { margin-top: 16px; overflow: hidden; background: var(--surface); border-radius: var(--radius-card); }
.profit-table { width: 100%; border-collapse: collapse; font-size: 15px; font-variant-numeric: tabular-nums; }
.profit-table th, .profit-table td { padding: 14px 18px; text-align: right; white-space: nowrap; }
.profit-table thead th { font-size: 13px; font-weight: 500; color: var(--text-3); }
.profit-table th[scope="row"], .profit-table thead th:first-child { text-align: left; white-space: normal; font-weight: 600; }
.profit-table th[scope="row"] small { display: block; margin-top: 2px; font-size: 13px; font-weight: 400; color: var(--text-3); }
.profit-table th[scope="row"] a:hover { text-decoration: underline; text-underline-offset: 3px; }
.profit-table tbody tr, .profit-table tfoot tr { border-top: 1px solid var(--line); }
.profit-table tfoot { background: var(--bg); }
.profit-table b { font-weight: 600; }
.profit-est { display: block; font-size: 12px; color: var(--text-3); }
.profit-sync { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; margin-top: 12px; padding: 14px 18px; background: var(--surface); border-radius: var(--radius-card); }
.profit-sync p { font-size: 14px; }
@media (max-width: 899px) {
  /* Chaque soirée devient une carte : nom en haut, montants en lignes libellées. */
  .profit-table thead { display: none; }
  .profit-table, .profit-table tbody, .profit-table tfoot, .profit-table tr, .profit-table th, .profit-table td { display: block; }
  .profit-table tr { padding: 14px 18px; }
  .profit-table th[scope="row"] { padding: 0 0 8px; }
  .profit-table td { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; }
  .profit-table td::before { content: attr(data-label); color: var(--text-3); }
  .profit-table td:last-child { margin-top: 4px; padding-top: 8px; border-top: 1px dashed var(--line); }
  .profit-est { display: inline; margin-left: 6px; }
}

/* ---------- Pages légales ---------- */

.legal-updated { margin-bottom: 14px; font-size: 14px; color: var(--text-3); }
.legal-toc { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.legal-toc a { display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border-radius: var(--radius-pill); background: var(--bg); color: var(--text); font-size: 14px; font-weight: 500; }
.legal a:not(.legal-toc a) { color: var(--text); text-decoration: underline; text-underline-offset: 3px; }
.legal li b, .legal p b { font-weight: 600; }
.legal code { padding: 1px 6px; border-radius: 6px; background: var(--bg); font-size: .92em; }
.prose.legal { max-width: 72ch; }
.table-wrap { margin: 12px 0; overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius-field); }
.legal-table { width: 100%; min-width: 520px; border-collapse: collapse; font-size: 14.5px; line-height: 1.5; }
.legal-table th, .legal-table td { padding: 12px 14px; text-align: left; vertical-align: top; }
.legal-table th { background: var(--bg); font-weight: 600; color: var(--text); }
.legal-table tr + tr td { border-top: 1px solid var(--line); }
.legal-table td:first-child { font-weight: 500; color: var(--text); }
.legal-pairs { display: grid; gap: 0; margin: 8px 0 0; border: 1px solid var(--line); border-radius: var(--radius-field); overflow: hidden; }
.legal-pairs > div { display: grid; grid-template-columns: minmax(140px, 220px) 1fr; gap: 12px; padding: 12px 16px; }
.legal-pairs > div + div { border-top: 1px solid var(--line); }
.legal-pairs dt { color: var(--text-2); }
.legal-pairs dd { color: var(--text); overflow-wrap: anywhere; }
@media (max-width: 520px) { .legal-pairs > div { grid-template-columns: 1fr; gap: 2px; } }
.legal-links { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13.5px; color: var(--text-2); }
.legal-links a { text-decoration: underline; text-underline-offset: 3px; }
.menu-foot { align-items: flex-start; }
.site-foot { display: none; }
.row-danger, .row-danger .row-ic, .row-danger .chev { color: var(--danger); }
.row-danger small { color: var(--text-3); }

/* ---------- Notes des soirées (étoiles à la couleur de l'asso, --star) ---------- */

.rating { margin-top: 22px; padding: 18px 20px; border-radius: var(--radius-card); background: var(--surface); }
.rating-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; }
.rating-title { font: 600 16px/1.35 var(--font); }
.rating-avg { display: inline-flex; align-items: center; gap: 10px; font-size: 14.5px; color: var(--text-2); font-variant-numeric: tabular-nums; }
.rating-avg b { font-size: 16px; color: var(--text); }
.rating-meter { position: relative; display: inline-block; flex: none; line-height: 0; color: var(--star); }
.rating-row { display: inline-flex; gap: 2px; }
.rating-row .ic { width: 20px; height: 20px; }
.rating-fill { position: absolute; inset: 0 auto 0 0; overflow: hidden; white-space: nowrap; --star-fill: currentColor; transition: width .6s var(--ease-out); }
.rating-note { margin-top: 10px; font-size: 14.5px; color: var(--text-2); }
.rating-note a { color: var(--text); text-decoration: underline; text-underline-offset: 3px; }
.rate { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.rate fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
.rate-legend { padding: 0; margin-bottom: 8px; font-size: 15px; font-weight: 500; color: var(--text); }
.rate-stars { display: inline-flex; gap: 4px; color: var(--star); }
.rate-star { position: relative; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; cursor: pointer; transition: transform .35s var(--spring), background-color .2s; }
.rate-star input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: pointer; }
.rate-star .ic { width: 34px; height: 34px; stroke-width: 1.6; }
/* Remplies : l'étoile cochée et toutes celles avant elle ; au survol, jusqu'à l'étoile pointée */
.rate-star:has(input:checked), .rate-star:has(~ .rate-star input:checked) { --star-fill: currentColor; }
@media (hover: hover) {
  .rate-stars:hover .rate-star { --star-fill: none; }
  .rate-stars:hover .rate-star:hover, .rate-stars:hover .rate-star:has(~ .rate-star:hover) { --star-fill: currentColor; }
  .rate-star:hover { background: var(--bg); }
}
.rate-star:active { transform: scale(.88); }
.rate-star:has(input:focus-visible) { outline: 2px solid var(--ink); outline-offset: 1px; }
.rate-submit { margin-top: 10px; }
.rate-status { margin-top: 4px; font-size: 14px; color: var(--text-2); }

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 639px) {
  .hide-sm { display: none; }
  .topbar .btn-sm:has(.hide-sm) { width: 50px; padding: 0; }
}

@media (max-width: 360px) {
  :root { --gutter: 16px; }
  .tour { width: 280px; }
  .menu-tiles { gap: 6px; }
  .menu-tile { font-size: 12.5px; }
}

/* Tablette */
@media (min-width: 640px) {
  :root { --gutter: 28px; --app-w: 680px; }
  .grid-cards { grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; }
  .list-rows, .org-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .admin-events, .mod-grid { grid-template-columns: repeat(2, 1fr); }
  .split { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: start; }
  .hero { height: 340px; margin: 16px 0 0; border-radius: 32px; }
  .hero-bar { top: 16px; left: 16px; right: 16px; }
  .sheet { margin: -40px 0 0; padding: 32px 28px 0; }
  .album { grid-template-columns: repeat(4, 1fr); }
  .auth-headline { font-size: 44px; }
  .auth-lead { font-size: 17px; }
  .paper { margin-left: 0; margin-right: 0; border-radius: 32px; min-height: 0; }
  .has-tabs .paper, .has-cta .paper { margin-bottom: calc(var(--tabbar-h) + 40px); padding-bottom: 36px; }
  .deck.is-stacked > .deck-card { left: 22%; right: 22%; }
}

/* ==========================================================================
   Ordinateur (≥ 1024)
   --------------------------------------------------------------------------
   Une vraie interface de bureau, même langage que le mobile :
   - Barre latérale fixe à gauche, contenu centré sur 1180 px
   - En-tête aligné à gauche : retour · grand titre + sous-titre · actions
   - Plus de « feuilles » à poignée : des panneaux blancs posés sur le fond
   - Soirée et asso : photo collée à gauche, infos et bouton d'action à droite
   - Bouton d'action collé en bas de la colonne de contenu, jamais par-dessus
   ========================================================================== */
@media (min-width: 1024px) {
  .dash-shortcuts { display: none; }
  :root { --side-w: 256px; --gutter: 32px; --app-w: 1180px; --section-gap: 40px; --section-inset: 18px; }
  body:not(.is-bare) { padding-left: var(--side-w); }
  .is-wide, body:has(.chips) { --app-w: 1180px; }

  /* Coque */
  .app { padding-top: 4px; }
  .has-tabs .app, .has-cta .app { padding-bottom: 56px; }
  .tabbar, .topbar-menu, .topbar-brand, .hello-bar { display: none; }

  .sidebar { position: fixed; z-index: 40; top: 12px; bottom: 12px; left: 12px; display: flex; flex-direction: column; gap: 26px; width: calc(var(--side-w) - 24px); padding: 24px 12px 12px; background: var(--surface); border-radius: 30px; overflow-y: auto; scrollbar-width: none; }
  .sidebar::-webkit-scrollbar { display: none; }
  .sidebar-brand { padding: 0 14px; align-self: flex-start; }
  .sidebar-foot { margin-top: auto; }
  .nav-group { margin: 20px 16px 6px; font-size: 12.5px; letter-spacing: .02em; }
  .nav-link { height: 44px; border-radius: 22px; font-size: 15px; }
  .nav-link .ic { width: 20px; height: 20px; }

  /* En-tête : aligné à gauche, pleine largeur pour le flou au défilement */
  .topbar {
    display: flex; align-items: center; gap: 16px;
    padding: 30px max(var(--gutter), calc((100% - var(--app-w)) / 2 + var(--gutter))) 18px;
  }
  .topbar:not(.is-pushed) > .topbar-side:first-child { display: none; }
  .topbar-center { flex: 1; text-align: left; }
  .topbar-title { font-size: 32px; line-height: 1.2; letter-spacing: -.025em; }
  .topbar-sub { margin-top: 4px; font-size: 15px; }
  .topbar-right { margin-left: auto; }
  .topbar .circle-btn { width: 46px; height: 46px; }
  /* Pages sans titre dans l'en-tête (bureau, admin) : les actions flottent en haut à droite, le contenu remonte */
  .topbar:has(.topbar-brand) { position: absolute; left: auto; right: max(0px, calc((100vw - var(--side-w) - var(--app-w)) / 2)); padding: 30px var(--gutter) 0; background: none !important; box-shadow: none !important; backdrop-filter: none !important; -webkit-backdrop-filter: none !important; }
  body:has(.topbar-brand) .app { padding-top: 30px; }
  body:has(.topbar-brand) .app > .notice-admin:first-child { margin-top: 0; margin-right: 200px; }

  .page-intro { margin: 8px 0 26px; }
  .page-title { font-size: 32px; line-height: 1.2; }
  .page-sub { margin-top: 6px; font-size: 16px; }

  /* Panneaux : la « feuille » mobile devient un panneau posé */
  .paper { margin: 12px 0 0; padding: 32px; border-radius: var(--radius-card); box-shadow: none; }
  .paper::before { display: none; }
  .has-tabs .paper, .has-cta .paper { margin-bottom: 0; padding-bottom: 40px; }

  /* Bouton d'action : collé en bas du contenu */
  .cta-bar { position: sticky; z-index: 25; left: auto; right: auto; bottom: 0; margin-top: 12px; padding: 28px 0 24px; background: linear-gradient(rgba(244, 246, 248, 0), var(--bg) 42%); pointer-events: none; }
  .cta-inner { max-width: none; justify-content: flex-end; }
  .cta-inner > .btn, .cta-inner > form { flex: 0 1 420px; }
  .cta-inner .btn { height: 58px; font-size: 17px; }

  /* Pages formulaire : une colonne lisible */
  :is(.page-checkout, .page-verify, .page-terms, .page-sales, .page-privacy, .page-legal_notice, .page-accessibility, .page-account_delete, .page-notifications, .page-org_create, .page-org-event_form, .page-org-settings, .page-org-team, .page-org-scan, .page-org-pick, .page-admin-user, .page-admin-schools) { --app-w: 920px; }
  .page-org-scan, .page-org-pick { --app-w: 720px; }

  /* Titres de section */
  .section-head { margin: var(--section-gap) 0 var(--section-inset); }
  .section-head h2 { font-size: 24px; }
  .title-md { font-size: 22px; }

  /* ---------- Accueil ----------
     Rythme : en-tête 32 · titre de section 56 au-dessus, 20 en dessous · gouttières 24 */
  .page-head { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; min-height: 100px; padding-top: 28px; }
  .page-head .hello { flex: 1 1 240px; min-width: 0; padding-top: 0; margin: 0; }
  .hello-title { font-size: 32px; line-height: 1.2; letter-spacing: -.025em; }
  .hello-sub { margin-top: 6px; font-size: 16px; }
  .page-head .searchbar { flex: 0 1 420px; height: 54px; margin-right: 4px; padding: 0 4px 0 20px; border-radius: 27px; }
  .page-head .searchbar > .ic { width: 21px; height: 21px; color: var(--text-2); }
  .page-head .searchbar input { font-size: 16px; }
  .page-head .filter-btn { width: 46px; height: 46px; }
  .page-head .filter-btn .ic { width: 21px; height: 21px; }
  .page-actions { display: flex; align-items: center; gap: 12px; }
  .page-actions .circle-btn { width: 54px; height: 54px; }
  .page-actions .circle-btn .ic { width: 23px; height: 23px; }
  .page-actions .circle-btn.has-dot::after { top: 14px; right: 15px; }
  .page-avatar { display: block; border-radius: 50%; transition: transform .45s var(--spring); }
  .page-avatar .uav { width: 54px; height: 54px; }
  .page-avatar:active { transform: scale(.92); }
  @media (hover: hover) { .page-actions .circle-btn:hover, .page-head .searchbar:hover:not(:focus-within) { box-shadow: 0 0 0 1px var(--line); } }

  .home-lead { margin-top: 32px; }
  .lead-title { margin: 0 0 16px; font-size: 24px; }
  .home-lead .chips { margin: 0; padding: 0; flex-wrap: wrap; overflow: visible; }
  .home-lead .chip { min-height: 44px; padding: 0 20px; font-size: 14px; }
  .filter-bar { margin-top: 18px; gap: 8px; }
  .filter-clear { order: 0; }
  .filter-bar-count { flex: none; margin-right: 8px; padding-right: 16px; border-right: 1px solid var(--line-2); line-height: 22px; }
  .empty-card { padding: 56px 24px 48px; }
  @media (hover: hover) { .home-lead .chip:not(.is-active):hover { color: var(--text); box-shadow: inset 0 0 0 1px var(--line-2); } }

  /* Une carte à la fois, sur toute la largeur de la colonne */
  .home-feature { --deck-h: clamp(400px, calc(100dvh - 310px), 520px); display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 24px; height: var(--deck-h); margin-top: 24px; }
  .deck-stage { position: relative; height: 100%; overflow: hidden; isolation: isolate; border-radius: 30px; background: var(--ink); box-shadow: 0 30px 50px -34px rgba(16, 24, 40, .55); }
  .home-feature .deck { height: 100%; margin: 0; }
  .deck.is-slider > .deck-card { left: 0; right: 0; border-radius: 30px; box-shadow: none; transition: transform .7s var(--glide), opacity .4s var(--ease-out); }
  .deck.is-slider > .deck-card::after { background: linear-gradient(180deg, rgba(8, 10, 12, 0) 34%, rgba(8, 10, 12, .38) 58%, rgba(8, 10, 12, .9) 100%), linear-gradient(90deg, rgba(8, 10, 12, .38), rgba(8, 10, 12, 0) 60%); }
  .deck.is-slider .fav-glass { top: 24px; right: 24px; }
  .deck.is-slider .deck-body { left: 28px; right: 28px; bottom: 28px; max-width: 640px; }
  .deck.is-slider .deck-kicker { font-size: 16px; }
  .deck.is-slider .deck-title { margin-top: 4px; font-size: clamp(28px, 2.6vw, 38px); line-height: 1.1; letter-spacing: -.015em; }
  .deck.is-slider .deck-meta { margin-top: 14px; font-size: 15px; }
  .deck.is-slider .deck-pill { height: 30px; font-size: 15px; }
  .deck.is-slider .deck-cta { display: inline-flex; gap: 18px; height: 54px; margin-top: 22px; padding: 0 4px 0 24px; border-radius: 27px; background: #fff; color: var(--text); box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; }
  .deck.is-slider .deck-cta > span:first-child { flex: none; padding: 0; font-size: 16px; }
  .deck.is-slider .deck-cta-go { width: 46px; height: 46px; background: var(--ink); color: #fff; }
  .deck.is-slider .deck-cta-go .ic { width: 20px; height: 20px; }
  /* « Voir plus » : simple bouton, toute la carte ouvre la soirée */
  /* Au survol, seule la flèche avance, à l'intérieur du rond : rien ne dépasse du bouton */
  .deck.is-slider .deck-card:hover .deck-cta-go { transform: none; }
  .deck.is-slider .deck-cta-go .ic { transition: transform .5s var(--spring); }
  .deck.is-slider .deck-card:hover .deck-cta-go .ic { transform: translateX(3px); }
  .deck-nav { position: absolute; z-index: 5; right: 24px; bottom: 32px; display: flex; align-items: center; gap: 10px; }
  .deck-dots { display: flex; align-items: center; gap: 6px; margin-right: 12px; }
  .deck-dots i { width: 7px; height: 7px; border-radius: 4px; background: rgba(255, 255, 255, .42); transition: width .4s var(--ease-out), background-color .3s; }
  .deck-dots i.is-on { width: 22px; background: #fff; }
  .deck-arrow { display: grid; place-items: center; width: 50px; height: 50px; padding: 0; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .16); color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .3); transition: background-color .2s, color .2s, transform .45s var(--spring); }
  .deck-arrow .ic { width: 22px; height: 22px; }
  .deck-arrow:hover { background: #fff; color: var(--text); }
  .deck-arrow:active { transform: scale(.9); }

  /* Prochainement : même hauteur que le carrousel */
  .home-next { display: flex; flex-direction: column; min-height: 0; padding: 22px 12px 12px; background: var(--surface); border-radius: 30px; box-shadow: var(--sh-card); }
  .home-next-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 0 12px 10px; }
  .home-next-title { font: 600 20px/1.3 var(--font); }
  .home-next-head .u-link { font-size: 15px; }
  .home-next .list-rows { display: flex; flex-direction: column; justify-content: space-between; flex: 1; min-height: 0; gap: 2px; overflow: hidden; }
  .home-next .row-event { gap: 14px; padding: 8px 12px 8px 8px; border-radius: 20px; background: transparent; transition: background-color .2s; }
  .home-next .row-event:hover { background: var(--bg); }
  .home-next .row-event:active { transform: none; }
  .home-next .row-event-media { width: 72px; height: 64px; border-radius: 14px; }
  .home-next .row-event-date { font-size: 13.5px; }
  .home-next .row-event-body h3 { font-size: 16px; }
  .home-next .row-event-chev .ic { width: 20px; height: 20px; color: var(--text-3); }
  /* Peu de dates : un encart remplit le bas du cadre */
  .home-next:has(.home-next-fill) .list-rows { flex: none; justify-content: flex-start; }
  .home-next-fill { display: flex; flex: 1; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 0; margin-top: 10px; padding: 20px 22px; overflow: hidden; border-radius: 22px; background: var(--bg); text-align: center; }
  .home-next-fill-ic { display: grid; place-items: center; width: 52px; height: 52px; margin-bottom: 8px; border-radius: 50%; background: var(--surface); color: var(--ink); }
  .home-next-fill-ic .ic { width: 22px; height: 22px; }
  .home-next-fill-title { font: 600 17px/1.3 var(--font); }
  .home-next-fill-text { max-width: 30ch; font-size: 14px; line-height: 1.45; color: var(--text-2); }
  .home-next-fill .btn { margin-top: 12px; }
  .home-next-fill.is-compact { padding: 14px 18px; }
  .home-next-fill.is-compact .home-next-fill-ic, .home-next-fill.is-compact .home-next-fill-text { display: none; }
  .home-next-fill.is-compact .btn { margin-top: 6px; }

  .section-head { margin: var(--section-gap) 0 var(--section-inset); }
  .section-head h2 { font-size: 24px; }
  .section-head .u-link { font-size: 14px; }

  .rail-tours { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 24px; margin: 0; padding: 0; overflow: visible; }
  .rail-tours > .tour { width: auto; }
  .rail-tours .tour-media { height: auto; aspect-ratio: 16 / 10; }
  /* Accueil : colonnes fixes pour que la tuile « D'autres soirées » finisse la rangée */
  .page-home .rail-tours { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .tour-fill { display: flex; grid-column: span var(--span3); flex-direction: column; align-items: center; justify-content: center; gap: 8px; min-height: 300px; padding: 32px 28px; border-radius: var(--radius-card); background: var(--surface); box-shadow: inset 0 0 0 1.5px var(--line-2); text-align: center; }
  .tour-fill[data-span3="0"] { display: none; }
  .tour-fill-ic { display: grid; place-items: center; width: 60px; height: 60px; margin-bottom: 8px; border-radius: 50%; background: var(--bg); color: var(--ink); }
  .tour-fill-ic .ic { width: 26px; height: 26px; }
  .tour-fill-title { font: 600 20px/1.3 var(--font); letter-spacing: -.015em; }
  .tour-fill-text { max-width: 38ch; font-size: 15px; line-height: 1.5; color: var(--text-2); }
  .tour-fill-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 14px; }
  .tour:hover { box-shadow: 0 2px 4px rgba(16, 24, 40, .04), 0 24px 40px -26px rgba(16, 24, 40, .3); }

  /* Tes assos : des tuiles, plus des ronds perdus dans le vide */
  .stories { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; margin: 0; padding: 0; overflow: visible; }
  .story { flex-direction: row; gap: 14px; width: auto; padding: 12px 18px 12px 12px; border-radius: var(--radius-card); background: var(--surface); transition: box-shadow .3s, transform .5s var(--spring); }
  .story:hover { box-shadow: var(--sh-card); }
  .story-ring { width: 60px; height: 60px; padding: 3px; }
  .story-add { box-shadow: none; background: var(--bg); }
  .story-name { display: block; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 16px; line-height: 1.35; text-align: left; color: var(--text); }
  .story-meta { display: block; margin-top: 2px; font-size: 14px; color: var(--text-3); }

  .list-rows { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
  .row-event { transition: box-shadow .3s; }
  .row-event:hover { box-shadow: var(--sh-card); }

  .rail-memories { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; margin: 0; padding: 0; overflow: visible; }
  .rail-memories > .memory { width: auto; }
  .page-home .list-rows:not(.home-next .list-rows) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hello-title { overflow-wrap: anywhere; }
  .hello-sub { max-width: 48ch; }
  .deck-arrow:focus-visible { outline-color: #fff; }
  .follow-card { padding: 26px 0 22px; }
  .follow-card-head, .rail-orgs { padding-left: 26px; padding-right: 26px; }

  /* ---------- Soirée et asso : photo à gauche, infos à droite ---------- */
  .page-event { --app-w: 1320px; }
  .page-event .app { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); column-gap: 32px; align-items: start; padding-top: 12px; }
  .page-event .app > .notice { grid-column: 1 / -1; }
  .page-event .hero { grid-column: 1; grid-row: 1 / span 3; position: sticky; top: 12px; height: min(720px, calc(100dvh - 48px)); margin: 0; border-radius: 32px; }
  .page-event .hero-bar { top: 18px; left: 18px; right: 18px; }
  .page-event .sheet { grid-column: 2; margin: 0; padding: 24px 0 0; background: none; border-radius: 0; }
  .page-event .sheet::before { display: none; }
  .page-event .sheet-title { font-size: 34px; line-height: 1.15; }
  .page-event .sheet-head { align-items: flex-start; }
  .page-event .sheet-head .pill-line { margin: 0; height: 34px; padding: 0 14px 0 11px; border-radius: 17px; font-size: 16px; }
  .page-event .sheet-line { margin-top: 14px; }
  .page-event .sheet-line .u-link { transform: none; }
  .page-event .desc { font-size: 17px; line-height: 1.6; }
  .page-event .rail-tours { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .page-event .rail-tours > :nth-child(n + 5) { display: none; }
  .page-event .album { grid-template-columns: repeat(3, 1fr); }
  .page-event .cta-bar { grid-column: 2; }
  .page-event .cta-inner > .btn, .page-event .cta-inner > form { flex: 1; }

  /* Fiche soirée */
  .page-event { --app-w: 1240px; }
  .page-event .app { grid-template-columns: minmax(0, 1fr) 360px; column-gap: 48px; padding-top: 16px; }
  .page-event .hero { grid-column: 1; grid-row: 1; position: relative; top: auto; height: clamp(320px, 50vh, 500px); }
  .page-event .sheet { grid-column: 1; grid-row: 2; padding-top: 32px; }
  .page-event .sheet-head .pill-line { display: none; }
  .page-event .sheet-title { font-size: 40px; line-height: 1.1; letter-spacing: -.03em; }
  .page-event .sheet-line { justify-content: flex-start; gap: 10px 20px; }
  .page-event .sheet-line .u-link { font-size: 15px; }
  .page-event .sheet-org { font-size: 16px; font-weight: 500; }
  .page-event .sheet-org .org-avatar-xs { width: 28px; height: 28px; font-size: 9px; }
  .page-event .event-facts { display: none; } /* déjà dans l'encart de réservation */
  .page-event .desc { margin-top: 28px; }
  .page-event .title-md { margin-top: 40px; }
  .page-event .tabs { margin: 0 0 14px; padding: 0; }
  .page-event .ev-book-wrap { grid-column: 2; grid-row: 1 / span 2; align-self: stretch; }
  .page-event .ev-book { position: sticky; top: 16px; display: flex; flex-direction: column; margin-top: 0; padding: 26px 24px 20px; border-radius: 28px; background: var(--surface); box-shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 24px 48px -28px rgba(16, 24, 40, .28); z-index: 3; }
  .ev-book-price { display: flex; flex-direction: column; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
  .ev-book-price small { font-size: 14px; color: var(--text-2); }
  .ev-book-price b { margin: 2px 0; font-size: 34px; font-weight: 600; line-height: 1.15; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
  .ev-book-facts { display: flex; flex-direction: column; gap: 14px; margin: 18px 0 0; padding: 0; list-style: none; }
  .ev-book-facts li { display: flex; align-items: flex-start; gap: 12px; font-size: 15px; font-weight: 500; line-height: 1.35; }
  .ev-book-facts .ic { width: 20px; height: 20px; flex: none; margin-top: 1px; color: var(--text-2); }
  .ev-book-facts span { display: flex; flex-direction: column; min-width: 0; }
  .ev-book-facts small { font-size: 13.5px; font-weight: 400; color: var(--text-2); }
  .ev-book .meter-wrap { margin-top: 20px; }
  .ev-book-cta { margin-top: 20px; }
  .ev-book-cta .btn { width: 100%; height: 56px; border-radius: 28px; font-size: 16.5px; }
  .ev-book-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; font-size: 13.5px; color: var(--text-2); }
  .ev-book-foot .u-link { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; }
  .ev-book-foot > span { display: inline-flex; align-items: center; gap: 6px; }
  .ev-book-foot .ic { width: 15px; height: 15px; margin-right: 0; }
  .page-event .cta-bar { display: none; }
  .page-event .ev-more { grid-column: 1 / -1; grid-row: 3; margin-top: 24px; }
  .page-event .ev-more .rail-tours { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .page-event .ev-more .rail-tours > :nth-child(n + 5) { display: none; }

  /* ---------- Billets ---------- */
  .page-tickets .accs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; align-items: start; }
  .page-tickets .tab-panel > .title-md { margin-top: 30px; }

  .page-ticket { --app-w: 1040px; }
  .page-ticket .paper { display: grid; grid-template-columns: 400px minmax(0, 1fr); gap: 0 56px; align-items: start; }
  .page-ticket .paper > .success { grid-column: 1 / -1; }
  .page-ticket .ticket-printer { margin: 8px 0 0; }
  .page-ticket .ticket-side { position: sticky; top: 120px; }
  .page-ticket .ticket-side > .footnote { margin: 8px 0 14px; padding: 22px 24px; border-radius: var(--radius-card); background: var(--bg); text-align: left; font-size: 15px; line-height: 1.55; }
  .page-ticket .ticket-side > .footnote br { display: none; }

  /* ---------- Réservation ---------- */
  .page-checkout #pay { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; align-items: start; }
  .page-checkout #pay > .accs, .page-checkout #pay > .rules { margin: 0; }
  .page-checkout #pay > .footnote, .page-checkout #pay > input { grid-column: 1 / -1; }
  .page-checkout #pay:not(:has(.rules)) { grid-template-columns: minmax(0, 1fr); }

  /* ---------- Profil : la carte d'identité reste à gauche ---------- */
  .page-profile { --app-w: 1080px; }
  .page-profile .paper { display: grid; grid-template-columns: 240px minmax(0, 1fr); column-gap: 32px; align-items: start; }
  .page-profile .paper > * { grid-column: 2; }
  .page-profile .paper > .me { grid-column: 1; grid-row: 1 / span 30; position: sticky; top: 110px; flex-direction: column; align-items: flex-start; gap: 16px; padding: 24px; }
  .page-profile .paper > .me .me-stats { flex-direction: column; align-items: stretch; }
  .page-profile .paper > .me .me-stats > * { justify-content: flex-start; }
  .page-profile .paper > .section-title:first-of-type, .page-profile .paper > .me + * { margin-top: 0; }

  /* ---------- Bureau et admin ---------- */
  .kpis { gap: 14px; }
  .kpi { padding: 22px; border-radius: var(--radius-card); }
  .kpi b { font-size: clamp(15px, 13cqi, 30px); }
  .admin-events, .mod-grid { gap: 14px; }
  .split { gap: 32px; }
  .org-head { margin-top: 4px; }
  .actions { gap: 12px; }
  .action { padding: 18px 8px 16px; }

  /* Pied de page : liens légaux */
  .site-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 24px; max-width: var(--app-w); margin: 0 auto; padding: 20px var(--gutter) 28px; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--text-2); }

  /* Menu : fenêtre centrée */
  .menu-sheet[open] { align-items: center; }
  .menu-panel { max-width: 460px; padding-top: 24px; border-radius: 32px; box-shadow: 0 30px 80px -30px rgba(16, 24, 40, .45); }
  .menu-handle { display: none; }

  /* Connexion / inscription */
  .auth { flex-direction: row; align-items: flex-start; gap: 16px; padding: 16px; background: var(--bg); }
  .auth-hero { position: sticky; top: 16px; flex: 1; height: calc(100dvh - 32px); min-height: 0; padding: 32px 44px 44px; border-radius: 32px; }
  .auth-headline { font-size: 60px; line-height: 1.02; }
  .auth-lead { margin-top: 18px; font-size: 18px; }
  .auth-points { display: flex; flex-wrap: wrap; gap: 8px; margin: 28px 0 0; padding: 0; list-style: none; }
  .auth-points li { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px 0 12px; border-radius: 20px; background: #fff; color: var(--text); font-size: 14.5px; font-weight: 500; }
  .auth-points .ic { width: 17px; height: 17px; color: var(--ink); }
  .auth-sheet { display: flex; flex-direction: column; justify-content: center; width: 520px; flex: none; min-height: calc(100dvh - 32px); margin: 0; padding: 48px 56px; border-radius: 32px; background: var(--surface); box-shadow: var(--sh-card); }
  .auth-sheet::before { display: none; }
  .auth-sheet > * { width: 100%; max-width: 400px; margin-left: auto; margin-right: auto; }
  .auth-sheet .auth-switch { background: var(--bg); box-shadow: none; }
  .auth-sheet .auth-switch a:not(.is-active):hover { background: var(--surface); }
  .auth-sheet .input-box { background: var(--bg); box-shadow: inset 0 0 0 1px transparent; }
  .auth-sheet .input-box:focus-within { background: var(--surface); box-shadow: 0 0 0 1.5px var(--ink); }
  .auth-sheet .input.has-error .input-box { background: var(--surface); }
  .auth-sheet :is(.consent, .accept-all) { background: var(--bg); }
  .auth-head h2 { font-size: 30px; }
}

/* ---------- Admin : rythme vertical ---------- */
:is(.page-admin-orgs, .page-admin-users) .searchbar + .chips { margin-top: 12px; }
:is(.page-admin-orgs, .page-admin-users) .chips + * { margin-top: 20px; }
.page-intro .page-sub { max-width: 70ch; margin-top: 8px; line-height: 1.55; color: var(--text-2); }
.page-admin-audit .app > .footnote:first-of-type { margin: 4px 6px 16px; }
.page-admin-schools .form + .section-title { margin-top: 40px; }
:is(.page-admin-schools, .page-admin-user) .form > .footnote { margin: 10px 6px 0; }
:is(.page-admin-schools, .page-admin-user) .form > .btn:not(.btn-block) { margin-top: 16px; }
.page-admin-user .card.me { padding: 22px 24px; background: var(--surface); }
.page-admin-user .card.me h2 { margin-bottom: 4px; }
.page-admin-user .mod-actions { padding-top: 0; border-top: 0; }
.page-admin-user .section-title + .muted { margin: -4px 0 12px; font-size: 15px; }
.page-admin-user .form > .btn-soft { background: var(--surface); box-shadow: inset 0 0 0 1px var(--line-2); }
.page-admin-user .split { margin-top: 12px; }
.page-admin-overview .kpis { margin-top: 0; }

/* Grand écran : un peu plus d'air */
/* Petit ordinateur : le carrousel prend toute la largeur, « Prochainement » s'efface (déjà dans « À venir ») */
@media (min-width: 1024px) and (max-width: 1279px) {
  .page-event .app { grid-template-columns: minmax(0, 1fr) 320px; column-gap: 32px; }
  .page-event .ev-more .rail-tours { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .page-event .ev-more .rail-tours > :nth-child(n + 4) { display: none; }
  .home-feature { grid-template-columns: minmax(0, 1fr); }
  .home-next { display: none; }
  .page-home .rail-tours { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tour-fill { display: flex; grid-column: span var(--span2); }
  .tour-fill[data-span2="0"] { display: none; }
  .page-head .searchbar { flex-basis: 340px; }
  .page-home .list-rows:not(.home-next .list-rows) { grid-template-columns: minmax(0, 1fr); }
}
/* Écran peu haut : 4 lignes dans « Prochainement » */
@media (min-width: 1024px) and (max-height: 820px) {
  .home-next .row-event:nth-child(n + 5) { display: none; }
}

@media (min-width: 1440px) {
  :root { --side-w: 272px; --gutter: 40px; }
}

/* Page asso : tablette */
@media (min-width: 640px) {
  .page-org .hero { height: clamp(220px, 34vw, 320px); margin: 16px 0 0; border-radius: 32px; }
  .page-org .sheet { margin: 0; padding: 0 4px; background: none; border-radius: 0; }
  .page-org .sheet::before { display: none; }
  .org-head { grid-template-columns: auto minmax(0, 1fr); column-gap: 22px; align-items: end; }
  .org-badge { grid-row: 1; align-self: start; margin: -60px 0 0 12px; padding: 5px; }
  .org-badge .org-avatar-xl { width: 116px; height: 116px; font-size: 34px; }
  .org-id { padding-top: 16px; }
  .page-org .sheet-title { font-size: 32px; line-height: 1.15; letter-spacing: -.025em; }
  .page-org .sheet-title .verified { width: 24px; height: 24px; }
  .org-meta { grid-column: 1 / -1; }
  .org-actions { grid-column: 1 / -1; display: flex; gap: 10px; margin-top: 18px; }
  .org-actions > .btn:not(.org-share), .org-actions > form { flex: 0 1 280px; }
  .org-actions .btn { height: 50px; min-height: 50px; font-size: 16px; }
  .org-actions form .btn { width: 100%; }
  .org-share { flex: none; width: 50px; min-width: 0; padding: 0; border-radius: 50%; }
  .page-org .cta-bar { display: none; }
  .page-org.has-cta .app { padding-bottom: 48px; }
  .org-about { margin-top: 28px; padding: 24px; }
  .page-org .org-events { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 0; padding: 0; overflow: visible; }
  .page-org .org-events > .tour { width: auto; }
  .page-org .org-events .tour-media { height: auto; aspect-ratio: 16 / 10; }
  .page-org .org-memories { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px; margin: 0; padding: 0; overflow: visible; }
  .page-org .org-memories > .memory { width: auto; }
}
@media (min-width: 900px) {
  .org-head { grid-template-columns: auto minmax(0, 1fr) auto; }
  .org-meta { grid-column: 2; }
  .org-actions { grid-column: 3; grid-row: 1 / span 2; align-self: end; margin: 0 4px 0 0; }
  .org-actions > .btn:not(.org-share), .org-actions > form { flex: none; width: 220px; }
}

/* Page asso : ordinateur */
@media (min-width: 1024px) {
  .page-org { --app-w: 1240px; }
  .page-org .app { padding-top: 16px; }
  .page-org .hero { height: clamp(240px, 30vh, 340px); margin: 0; }
  .page-org .hero-bar { top: 18px; left: 18px; right: 18px; }
  .org-head { padding: 0 8px; column-gap: 28px; }
  .org-badge { margin: -72px 0 0 16px; padding: 6px; }
  .org-badge .org-avatar-xl { width: 136px; height: 136px; font-size: 40px; }
  .org-id { padding-top: 20px; }
  .page-org .sheet-title { font-size: 38px; }
  .org-tagline { font-size: 18px; }
  .org-body { display: grid; grid-template-columns: minmax(0, 1fr) 340px; column-gap: 40px; align-items: start; margin-top: 12px; }
  .org-main { grid-column: 1; grid-row: 1; }
  .org-about { grid-column: 2; grid-row: 1; position: sticky; top: 24px; margin-top: var(--section-gap); }
  .org-main > .section-head:first-child { margin-top: var(--section-gap); }
  .page-org .org-events { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 20px; }
  .page-org .org-events > :nth-child(n) { display: flex; }
  .page-org .org-memories { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 16px; }
}
/* Petit ordinateur : une seule colonne, comme sur tablette, pour garder des cartes lisibles */
@media (min-width: 1024px) and (max-width: 1279px) {
  .org-head { grid-template-columns: auto minmax(0, 1fr); }
  .org-badge { margin-top: -64px; }
  .org-badge .org-avatar-xl { width: 120px; height: 120px; font-size: 36px; }
  .page-org .sheet-title { font-size: 34px; }
  .org-meta { grid-column: 1 / -1; }
  .org-actions { grid-column: 1 / -1; grid-row: auto; align-self: auto; margin: 18px 0 0; }
  .org-body { display: flex; flex-direction: column; }
  .org-about { position: static; margin-top: 28px; }
  .page-org .org-events { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  @view-transition { navigation: none; }
}

/* ---------- Budget prévisionnel (formulaire de soirée) ----------
   Calculateur : frais, réserves et dépenses, puis curseurs prix et participants,
   puis recettes, bénéfice ou perte et seuil de rentabilité. */

.bp-unit { flex: none; font-style: normal; font-size: 15px; color: var(--text-3); }
.bp .field input { text-align: left; }
.bp > .subhead:first-of-type { margin-top: 8px; }

/* Frais et réserves */
.bp-params .field > span { flex: 1; width: auto; padding: 12px 0; }
.bp-params .field > span small { display: block; margin-top: 2px; font-size: 13px; line-height: 1.4; color: var(--text-3); }
.bp-params .field input { flex: 0 0 96px; text-align: right; font-weight: 500; font-variant-numeric: tabular-nums; }

/* Récap des coûts et KPI */
.bp .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 12px; }
.bp-kpi-sub { margin-top: -8px; font-size: 13px; color: var(--text-3); font-variant-numeric: tabular-nums; }

/* Curseurs */
.bp-slider { position: relative; padding: 18px 20px 16px; }
.bp-slider + .bp-slider::before { content: ""; position: absolute; top: 0; left: 20px; right: 20px; height: 1px; background: var(--line); }
.bp-slider-top { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.bp-slider-top label { font-size: 15px; color: var(--text-3); }
.bp-slider-value { display: flex; align-items: baseline; gap: 6px; }
.bp-slider-value input { width: 110px; padding: 0; border: 0; outline: 0; background: transparent; font: 600 28px/1 var(--font); letter-spacing: -.02em; text-align: right; font-variant-numeric: tabular-nums; }
.bp-slider-value small { font-size: 15px; color: var(--text-3); }
.bp-range { --p: 50%; appearance: none; -webkit-appearance: none; display: block; width: 100%; height: 32px; margin: 0; background: transparent; cursor: pointer; }
.bp-range::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; background: linear-gradient(to right, var(--ink) var(--p), #E1E4E7 var(--p)); }
.bp-range::-moz-range-track { height: 6px; border-radius: 3px; background: #E1E4E7; }
.bp-range::-moz-range-progress { height: 6px; border-radius: 3px; background: var(--ink); }
.bp-range::-webkit-slider-thumb { -webkit-appearance: none; width: 28px; height: 28px; margin-top: -11px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 1px rgba(16, 24, 40, .06), 0 4px 12px rgba(16, 24, 40, .22); transition: transform .4s var(--spring); }
.bp-range::-moz-range-thumb { width: 28px; height: 28px; border: 0; border-radius: 50%; background: #fff; box-shadow: 0 0 0 1px rgba(16, 24, 40, .06), 0 4px 12px rgba(16, 24, 40, .22); }
.bp-range:active::-webkit-slider-thumb { transform: scale(1.12); }
.bp-range:focus-visible { outline: none; }
.bp-range:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 2px var(--ink), 0 4px 12px rgba(16, 24, 40, .22); }
.bp-scale { display: flex; justify-content: space-between; gap: 8px; margin-top: 2px; font-size: 13px; color: var(--text-3); }
.bp-scale .warn { color: var(--warn); }
.bp-apply { margin-top: 10px; }

/* Postes */
.subhead [data-bp-count] { margin-left: 4px; }
.bp-items { display: grid; gap: 10px; }
.bp-item { padding: 12px 12px 12px 20px; background: var(--surface); border-radius: var(--radius-card); animation: bp-in .45s var(--ease-out) both; }
.bp-item.is-leaving { animation: bp-out .22s var(--ease-out) both; }
@keyframes bp-in { from { opacity: 0; transform: translateY(10px) scale(.98); } }
@keyframes bp-out { to { opacity: 0; transform: scale(.96); } }
.bp-item-top { display: flex; align-items: center; gap: 10px; }
.bp-dot { flex: none; width: 10px; height: 10px; border-radius: 50%; }
.bp-name { flex: 1; min-width: 0; padding: 8px 0; border: 0; outline: 0; background: transparent; font-size: 16px; font-weight: 500; }
.bp-name::placeholder { color: var(--text-3); font-weight: 400; }
.bp-del:hover { background: var(--danger-soft); color: var(--danger); }
.bp-item-mid { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin: 6px 8px 0 0; }
.bp-amount { display: flex; align-items: center; gap: 6px; height: 46px; padding: 0 12px; border-radius: var(--radius-field); background: var(--bg); transition: box-shadow .2s; }
.bp-amount:focus-within { box-shadow: 0 0 0 1.5px var(--ink); }
.bp-amount input { width: 76px; border: 0; outline: 0; background: transparent; font-size: 17px; font-weight: 500; text-align: right; font-variant-numeric: tabular-nums; }
.bp-amount input::placeholder { color: var(--text-3); }
.bp-amount em { font-style: normal; font-size: 14px; color: var(--text-3); white-space: nowrap; }
.form .bp-item .segmented { gap: 4px; margin: 0; padding: 4px; border-radius: var(--radius-pill); background: var(--bg); }
.bp-item .segmented span { height: 34px; padding: 0 15px; background: transparent; font-size: 14px; }
.bp-item .segmented input:checked + span { background: var(--ink); color: #fff; }
.bp-add { margin-top: 10px; border-radius: var(--radius-card); background: transparent; box-shadow: inset 0 0 0 1.5px var(--line-2); }
.bp-add:hover { background: var(--surface); box-shadow: none; }

/* Résultat */
.bp-hero { margin-top: 12px; padding: 22px; border-radius: var(--radius-panel); background: var(--ink); color: #fff; box-shadow: var(--sh-float); }
.bp-hero-label { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 15px; color: rgba(255, 255, 255, .7); }
.bp-badge { display: inline-flex; align-items: center; height: 28px; padding: 0 12px; border-radius: var(--radius-pill); background: rgba(255, 255, 255, .12); font-size: 13px; font-weight: 500; color: #fff; white-space: nowrap; }
.bp-badge.is-ok { background: rgba(74, 222, 128, .16); color: #8EF0B4; }
.bp-badge.is-ko { background: rgba(248, 113, 113, .18); color: #FFB1B1; }
.bp-hero-value { display: block; margin-top: 6px; font: 600 40px/1.1 var(--font); letter-spacing: -.035em; font-variant-numeric: tabular-nums; transition: color .3s; }
.bp-hero-value.is-pos { color: #8EF0B4; }
.bp-hero-value.is-neg { color: #FF9A9E; }
.bp-hero-sub { margin-top: 8px; font-size: 14px; color: rgba(255, 255, 255, .65); font-variant-numeric: tabular-nums; }

/* Seuil de rentabilité */
.bp-ind { margin-top: 12px; padding: 20px; border-radius: var(--radius-card); background: var(--surface); box-shadow: inset 0 0 0 1.5px var(--accent); }
.bp-ind-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 14px; }
.bp-ind-head h4 { margin: 0; font-size: 17px; font-weight: 600; }
.form .bp-ind .segmented { gap: 4px; margin: 0; padding: 4px; border-radius: var(--radius-pill); background: var(--bg); }
.bp-ind .segmented span { height: 32px; padding: 0 14px; background: transparent; font-size: 14px; }
.bp-ind .segmented input:checked + span { background: var(--ink); color: #fff; }
.bp-ind-value { display: block; margin-top: 14px; font: 600 34px/1.1 var(--font); letter-spacing: -.03em; color: var(--accent); font-variant-numeric: tabular-nums; }
.bp-ind-value.is-text { font-size: 21px; line-height: 1.3; letter-spacing: -.01em; }
.bp-ind-text { margin-top: 6px; font-size: 15px; color: var(--text-2); }
.bp-ind-status { display: inline-flex; margin-top: 12px; padding: 6px 12px; border-radius: var(--radius-pill); font-size: 14px; font-weight: 500; }
.bp-ind-status.is-ok { background: var(--ok-soft); color: var(--ok); }
.bp-ind-status.is-ko { background: var(--danger-soft); color: var(--danger); }
.bp-ind-apply { display: flex; margin-top: 12px; }

.bp-budget { margin-top: 24px; }
.bp-budget input[readonly] { color: var(--text-2); }


/* ---------- Guide de première visite ---------- */

.guide { position: fixed; inset: 0; z-index: 90; pointer-events: none; }
.guide-block { position: absolute; inset: 0; pointer-events: auto; }
.guide.is-try .guide-block { pointer-events: none; }
.guide-spot { position: fixed; border-radius: 22px; box-shadow: 0 0 0 200vmax rgba(14, 16, 18, .58); opacity: 0; transition: opacity .3s, top .45s var(--ease-expo), left .45s var(--ease-expo), width .45s var(--ease-expo), height .45s var(--ease-expo); }
.guide.is-open .guide-spot { opacity: 1; }
.guide.is-try .guide-spot { box-shadow: 0 0 0 200vmax rgba(14, 16, 18, .58), 0 0 0 3px var(--accent); }
.guide-bubble { position: fixed; width: min(360px, calc(100vw - 32px)); padding: 18px 18px 16px; border-radius: var(--radius-card); background: var(--surface); box-shadow: var(--sh-float); pointer-events: auto; opacity: 0; transition: top .45s var(--ease-expo), left .45s var(--ease-expo); }
.guide-bubble.is-in { animation: guide-in .35s var(--ease-out) both; }
.guide-progress { display: flex; align-items: center; justify-content: space-between; font-size: 13px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.guide-progress .u-link { font-size: 13px; color: var(--text-3); }
.guide-bubble h3 { margin: 8px 0 6px; font: 600 18px/1.3 var(--font); letter-spacing: -.01em; }
.guide-bubble p { margin: 0; font-size: 15px; line-height: 1.5; color: var(--text-2); }
.guide-bubble .guide-try { margin-top: 10px; font-size: 14px; font-weight: 500; color: var(--accent); }
.guide-nav { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; }
.guide-nav .btn[hidden] { display: none; }
@keyframes guide-in { from { opacity: 0; transform: translateY(8px) scale(.98); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .guide-spot, .guide-bubble { transition: none; }
  .guide-bubble.is-in { animation: none; opacity: 1; }
}
.mini-event .u-link { margin-top: 6px; font-size: 13px; color: var(--text-2); }

/* ---------- Bureau : blocs du tableau de bord ----------
   Un bloc = un sujet (billetterie, argent, dépenses, participants, photos),
   titre avec icône, chiffres en gros, détails en petit. */

.panel { min-width: 0; padding: 20px; background: var(--surface); border-radius: var(--radius-card); }
.panel-title { display: flex; align-items: center; gap: 10px; margin: 0 0 16px; font: 600 18px/1.3 var(--font); letter-spacing: -.01em; }
.panel-title > .ic { width: 20px; height: 20px; color: var(--text-2); }
.panel-title small { margin-left: auto; font-size: 13.5px; font-weight: 400; color: var(--text-3); }
.panel .search { margin-bottom: 8px; background: var(--bg); }
.panel .footnote { margin: 12px 0 0; }

/* En-tête de la soirée */
.evd-head { display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: 14px 16px; margin: 8px 0 12px; padding: 14px; background: var(--surface); border-radius: var(--radius-card); }
.evd-head-media { width: 88px; height: 88px; overflow: hidden; border-radius: 16px; }
.evd-head-media .cover-none span { font-size: 26px; }
.evd-head-body { min-width: 0; align-self: center; }
.evd-head h1 { margin: 6px 0 2px; font: 600 20px/1.25 var(--font); letter-spacing: -.015em; }
.evd-head .meta { font-size: 14.5px; color: var(--text-2); }
.evd-head-note { margin-top: 2px; font-size: 13.5px; color: var(--text-3); }
.evd-actions { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.evd-actions .btn { width: 100%; }

.evd-grid { display: grid; gap: 12px; }

/* Billetterie */
.evd-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.evd-stat { display: flex; flex-direction: column; min-width: 0; padding: 14px; border-radius: 18px; background: var(--bg); }
.evd-stat small { font-size: 13px; color: var(--text-2); }
.evd-stat b { margin: 4px 0 10px; font-size: 28px; font-weight: 600; line-height: 1.1; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.evd-stat b span { font-size: 15px; font-weight: 400; color: var(--text-3); letter-spacing: 0; }
.evd-stat .meter { margin-bottom: 8px; }
.meter-ok span { background: var(--ok); }
.meter.is-over span { background: var(--danger); }
.evd-line { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 15px; color: var(--text-2); }
.evd-line b { font-size: 18px; color: var(--text); font-variant-numeric: tabular-nums; }

/* Argent : recettes − dépenses = résultat */
.evd-money > div { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.evd-money dt { font-size: 15px; color: var(--text-2); }
.evd-money dd { font-size: 18px; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.evd-money .is-total { padding-top: 14px; border-bottom: 0; }
.evd-money .is-total dt { font-weight: 600; color: var(--text); }
.evd-money .is-total dd { font-size: 28px; letter-spacing: -.02em; }
.evd-budget { margin-top: 6px; padding: 14px; border-radius: 18px; background: var(--bg); }
.evd-budget p { margin-top: 8px; font-size: 14px; color: var(--text-2); }
.evd-budget p b { font-weight: 600; color: var(--text); }
.evd-budget p b.neg { color: var(--danger); }

/* Listes (dépenses, participants) et ajout rapide */
.evd-add { display: flex; gap: 8px; margin-bottom: 8px; }
.evd-add input { flex: 1; min-width: 0; height: 44px; padding: 0 14px; border: 0; border-radius: 14px; outline: 0; background: var(--bg); font-size: 16px; }
.evd-add input:focus { box-shadow: 0 0 0 1.5px var(--ink); }
.evd-add .amount { flex: 0 0 104px; text-align: right; font-variant-numeric: tabular-nums; }
.evd-add .btn { flex: none; min-height: 44px; }
.evd-list li { display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 8px 0; }
.evd-list li + li { border-top: 1px solid var(--line); }
.evd-list li > span { flex: 1; min-width: 0; }
.evd-list li > b { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.evd-list li > span b, .evd-list li > span small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.evd-list li > span b { font-weight: 500; }
.evd-list li > span small { font-size: 13px; color: var(--text-3); }
.evd-list li > small { flex: none; font-size: 13px; }
.evd-list.people { max-height: 560px; overflow-y: auto; }
.evd-empty { padding: 16px; border-radius: 16px; background: var(--bg); font-size: 14.5px; color: var(--text-2); }

/* Photos */
.evd-photos { margin-top: 12px; }
.evd-photo-cols { display: grid; gap: 20px; }
.evd-photo-cols .photo-block + .photo-block { margin-top: 0; }
.photo-block-head h3 small { font-size: 14px; font-weight: 400; }

/* Bilan de l'asso */
.dash-totals { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.dash-totals > div { min-width: 0; padding: 14px 16px; border-radius: 18px; background: var(--bg); }
.dash-totals dt { font-size: 13.5px; color: var(--text-2); }
.dash-totals dd { margin-top: 2px; font-size: 22px; font-weight: 600; letter-spacing: -.015em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.dash-totals .is-total dt { font-weight: 600; color: var(--text); }

/* ---------- Paliers de prix : places restantes avant le prix suivant ---------- */

.tiers-live { margin-top: 16px; padding: 16px; border-radius: 20px; background: var(--surface); }
.ev-book .tiers-live, .paper .tiers-live, .panel .tiers-live { background: var(--bg); }
.paper .tiers-live { margin: 0 0 16px; }
.ev-tiers-inline { margin: 16px 0; }
.tiers-live-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.tiers-live-head > div { display: flex; flex-direction: column; min-width: 0; }
.tiers-live-head small { font-size: 13px; color: var(--text-2); }
.tiers-live-head > div b { font-size: 24px; font-weight: 600; line-height: 1.2; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.tiers-live-left { display: flex; align-items: center; gap: 8px; padding: 8px 12px 8px 14px; border-radius: 16px; background: var(--ink); color: #fff; }
.tiers-live-left b { font-size: 26px; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.tiers-live-left span { font-size: 12.5px; line-height: 1.25; color: rgba(255, 255, 255, .78); }
.tiers-live .meter { margin-top: 14px; }
.tiers-live-note { margin-top: 10px; font-size: 14px; color: var(--text-2); }
.tiers-live-note b { font-weight: 600; color: var(--text); }
/* Côté étudiant : une seule ligne, « le prix passe à … dans … places » */
.tier-hint { display: flex; align-items: center; gap: 10px; margin-top: 16px; padding: 12px 16px; border-radius: 18px; background: var(--surface); font-size: 15px; line-height: 1.4; color: var(--text-2); }
.tier-hint .ic { width: 20px; height: 20px; flex: none; color: var(--text); }
.tier-hint b { font-weight: 600; color: var(--text); font-variant-numeric: tabular-nums; white-space: nowrap; }
.ev-book .tier-hint, .paper .tier-hint, .panel .tier-hint { background: var(--bg); }
.paper .tier-hint { margin: 0 0 16px; }
.ev-tiers-inline .tier-hint { margin: 0; }
.tier-hint.is-hot { background: var(--warn-soft); color: var(--warn); }
.tier-hint.is-hot .ic, .tier-hint.is-hot b { color: var(--warn); }
.tier-steps { margin: 14px 0 0; padding: 6px 0 0; border-top: 1px solid var(--line-2); list-style: none; }
.tier-step { display: grid; grid-template-columns: 20px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 8px 0; }
.tier-step-dot { display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; box-shadow: inset 0 0 0 2px var(--line-2); color: #fff; }
.tier-step-dot .ic { width: 12px; height: 12px; stroke-width: 3; }
.tier-step-name { font-size: 14.5px; font-weight: 500; }
.tier-step-name small, .tier-step-price small { display: block; font-size: 12.5px; font-weight: 400; color: var(--text-3); }
.tier-step-price { font-size: 14.5px; font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tier-step.is-done .tier-step-dot { background: var(--ok); box-shadow: none; }
.tier-step.is-done .tier-step-name, .tier-step.is-done .tier-step-price { color: var(--text-3); }
.tier-step.is-done .tier-step-price { text-decoration: line-through; }
.tier-step.is-done .tier-step-price small { text-decoration: none; }
.tier-step.is-current .tier-step-dot { background: var(--ink); box-shadow: 0 0 0 4px rgba(33, 37, 40, .12); }
.tier-step.is-current .tier-step-price small { color: var(--ok); font-weight: 500; }

@media (min-width: 640px) {
  .evd-head { grid-template-columns: 120px minmax(0, 1fr); padding: 16px; }
  .evd-head-media { width: 120px; height: 120px; }
  .evd-head h1 { font-size: 24px; }
  .evd-actions { display: flex; flex-wrap: wrap; }
  .evd-actions .btn { width: auto; }
  .dash-totals { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .evd-photo-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
}

@media (min-width: 1024px) {
  .panel { padding: 24px; }
  .evd-head { grid-template-columns: 136px minmax(0, 1fr) auto; align-items: center; gap: 20px; }
  .evd-head-media { width: 136px; height: 136px; }
  .evd-head h1 { font-size: 28px; }
  .evd-actions { grid-column: auto; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .evd-actions .btn { width: 100%; }
  .evd-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: start; }
  .evd-grid > .panel { grid-column: 1; }
  .evd-grid > .evd-people { grid-column: 2; grid-row: 1 / span 3; }
  .evd-list.people { max-height: 900px; }
  .evd-photos { margin-top: 16px; }
  .page-event .ev-tiers-inline { display: none; }
}

/* ---------- Admin : calculateur de commission ---------- */

.calc { display: grid; gap: 12px; margin-top: 16px; }
.calc-inputs { padding-bottom: 12px; }
.calc-inputs .panel-title { margin-bottom: 4px; }
.calc-inputs .bp-slider { padding-left: 0; padding-right: 0; }
.calc-inputs .bp-slider + .bp-slider::before { left: 0; right: 0; }
.calc-inputs .field-error { margin: 4px 0 8px; }
.calc-submit { margin-top: 8px; }
.calc-results { display: grid; gap: 12px; min-width: 0; }
.calc-hero { padding: 22px 24px; border-radius: var(--radius-card); background: var(--ink); color: #fff; }
.calc-hero small { font-size: 14px; color: rgba(255, 255, 255, .7); }
.calc-hero b { display: block; margin: 4px 0; font-size: clamp(34px, 8vw, 48px); font-weight: 600; line-height: 1.1; letter-spacing: -.025em; font-variant-numeric: tabular-nums; }
.calc-hero b.neg { color: #FF8A8F; }
.calc-hero p { font-size: 14.5px; color: rgba(255, 255, 255, .78); }
.calc-hero p span { color: #fff; font-weight: 500; }
.calc-totals { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.calc-totals .is-total { background: var(--ok-soft); }
.calc-totals dd { font-size: clamp(16px, 4.6vw, 22px); }

@media (min-width: 640px) {
  .calc-totals { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
  .calc { grid-template-columns: minmax(0, 400px) minmax(0, 1fr); gap: 16px; align-items: start; }
  .calc-inputs { position: sticky; top: 16px; }
  .calc-results { gap: 16px; }
}
