/* ============================================================
   RESTAURANT CASINO AMÉLIE-LES-BAINS — Design System
   Aesthetic: Art Deco Luxe / Brasserie Chic
   Palette: Noir profond + Or champagne + Ivoire
   ============================================================ */


:root {
  /* ── Dark mode (défaut) ── */
  --noir:       #0d0d0d;
  --noir-soft:  #1a1a1a;
  --noir-card:  #141414;
  --or:         #c9a84c;
  --or-light:   #e8c96a;
  --or-dim:     #a07535;
  --ivoire:     #f5f0e8;
  --ivoire-dim: #d4cfc5;
  --rouge:      #8b2230;
  --vert:       #2d6a4f;
  --gris:       #3a3a3a;
  --gris-light: #7a7a7a;
  --white:      #ffffff;

  --radius:     6px;
  --radius-lg:  12px;
  --shadow:     0 4px 24px rgba(0,0,0,0.6);
  --shadow-gold:0 0 20px rgba(201,168,76,0.25);
  --transition: all 0.25s cubic-bezier(0.4,0,0.2,1);

  --font-display: 'Cinzel', 'Playfair Display', serif;
  --font-body:    'Cormorant Garamond', serif;
  --font-ui:      'Montserrat', sans-serif;

  /* Sidebar */
  --sidebar-w: 280px;
}

/* ── Light mode ── */
body.light-mode {
  --noir:       #f8f5ef;
  --noir-soft:  #eeebe3;
  --noir-card:  #f2efe8;
  --or:         #9a6e1a;
  --or-light:   #c9a84c;
  --or-dim:     #c9a84c;
  --ivoire:     #1a1208;
  --ivoire-dim: #3a2e18;
  --rouge:      #c0392b;
  --vert:       #1e5c36;
  --gris:       #d5d0c5;
  --gris-light: #b5ae9e;
  background: var(--noir);
  color: var(--ivoire);
}
body.light-mode .topbar       { background: #fffdf6; border-color: var(--or-dim); }
body.light-mode .salle-sidebar { background: #f0ece2; border-color: var(--gris); }
body.light-mode .sidebar-section { border-color: var(--gris); }
body.light-mode .form-control  { background: #fff; border-color: var(--gris); color: var(--ivoire); }
body.light-mode .modal         { background: #f8f5ef; }
body.light-mode .nav-btn       { color: var(--ivoire-dim); }
body.light-mode .nav-btn:hover { background: rgba(0,0,0,0.06); }
body.light-mode .nav-btn.active{ color: #1a1208; }
body.light-mode .tool-btn      { background: #fff; border-color: var(--gris); color: var(--ivoire); }
body.light-mode .tool-btn:hover{ background: #efe9d8; }
body.light-mode .tool-btn.active{ background: #c9a84c; color: #fff; border-color: #c9a84c; }
body.light-mode .card          { background: #fff; }
body.light-mode #page-salle    { background: #e8e2d4; }
body.light-mode .btn-ghost     { background: #e0dbd0; color: var(--ivoire); border-color: var(--gris); }
body.light-mode .preset-item   { background: #fff; }
body.light-mode .event-card    { background: #fff; }
body.light-mode .modal-overlay { background: rgba(0,0,0,0.4); }

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  height: 100%;
  background: var(--noir);
  color: var(--ivoire);
  font-family: var(--font-ui);
  font-size: 14px;
  overflow: hidden;
}

/* ── Scrollbars ── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--noir-soft); }
::-webkit-scrollbar-thumb { background: var(--or-dim); border-radius: 3px; }

/* ── App Shell ── */
#app {
  display: flex;
  flex-direction: column;
  height: 100vh;
}

/* ── Top Bar ── */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  height: 60px;
  background: var(--noir-soft);
  border-bottom: 1px solid var(--or-dim);
  flex-shrink: 0;
  position: relative;
  z-index: 100;
}

.topbar-logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.topbar-logo .logo-icon {
  width: 36px;
  height: 36px;
  border: 2px solid var(--or-dim);
  border-radius: 50%;
  display: block;
  object-fit: cover;
  flex-shrink: 0;
}

.topbar-logo h1 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--or);
  letter-spacing: 1px;
}

.topbar-logo span {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--ivoire-dim);
  font-style: italic;
  letter-spacing: 2px;
}

.topbar-nav {
  display: flex;
  gap: 4px;
}

.nav-btn {
  padding: 8px 16px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: transparent;
  color: var(--ivoire-dim);
  font-family: var(--font-ui);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-btn:hover {
  background: var(--gris);
  color: var(--ivoire);
  border-color: var(--gris-light);
}

.nav-btn.active {
  background: linear-gradient(135deg, var(--or-dim), var(--or));
  color: var(--noir);
  border-color: var(--or);
  font-weight: 600;
}

.topbar-date {
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--or);
  font-style: italic;
  letter-spacing: 0.5px;
}

/* ── Main Content ── */
.main {
  flex: 1;
  overflow: hidden;
  position: relative;
}

.page {
  display: none;
  width: 100%;
  height: 100%;
  overflow-y: auto;
  overflow-x: hidden;
}

.page.active { display: flex; flex-direction: column; }

/* ── Gold Divider ── */
.gold-divider {
  width: 60px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--or), transparent);
  margin: 8px auto;
}

/* ── Section Header ── */
.section-header {
  padding: 20px 24px 16px;
  border-bottom: 1px solid var(--gris);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}

.section-title {
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--or);
  font-weight: 600;
}

.section-subtitle {
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--ivoire-dim);
  font-style: italic;
  margin-top: 2px;
}

/* ── Buttons ── */
.btn {
  padding: 9px 18px;
  border-radius: var(--radius);
  font-family: var(--font-ui);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: var(--transition);
  border: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
}

.btn-gold {
  background: linear-gradient(135deg, var(--or-dim), var(--or));
  color: var(--noir);
}
.btn-gold:hover { filter: brightness(1.1); transform: translateY(-1px); box-shadow: var(--shadow-gold); }

.btn-outline {
  background: transparent;
  border: 1px solid var(--or-dim);
  color: var(--or);
}
.btn-outline:hover { background: rgba(201,168,76,0.1); }

.btn-ghost {
  background: var(--gris);
  color: var(--ivoire);
  border: 1px solid var(--gris-light);
}
.btn-ghost:hover { background: #4a4a4a; }

.btn-danger {
  background: rgba(139,34,48,0.3);
  color: #ff6b7a;
  border: 1px solid var(--rouge);
}
.btn-danger:hover { background: rgba(139,34,48,0.5); }

.btn-sm { padding: 6px 12px; font-size: 11px; }
.btn-lg { padding: 12px 24px; font-size: 13px; }

/* ── Cards ── */
.card {
  background: var(--noir-card);
  border: 1px solid var(--gris);
  border-radius: var(--radius-lg);
  padding: 16px;
  transition: var(--transition);
}

.card:hover { border-color: var(--or-dim); }

.card-gold {
  border-color: var(--or-dim);
  box-shadow: var(--shadow-gold);
}

/* ── Form Elements ── */
.form-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }

.form-label {
  font-family: var(--font-ui);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--or);
}

.form-control {
  background: var(--noir-soft);
  border: 1px solid var(--gris);
  border-radius: var(--radius);
  padding: 9px 12px;
  color: var(--ivoire);
  font-family: var(--font-ui);
  font-size: 13px;
  outline: none;
  transition: var(--transition);
  width: 100%;
}

.form-control:focus { border-color: var(--or); box-shadow: 0 0 0 2px rgba(201,168,76,0.15); }
.form-control::placeholder { color: var(--gris-light); }

select.form-control option { background: var(--noir-soft); }

/* ── Badge ── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.badge-bronze  { background: rgba(139,90,43,0.25); color: #cd7f32; border: 1px solid #cd7f32; }
.badge-silver  { background: rgba(150,150,150,0.2); color: #c0c0c0; border: 1px solid #c0c0c0; }
.badge-gold    { background: rgba(201,168,76,0.2);  color: var(--or); border: 1px solid var(--or); }
.badge-vip     { background: rgba(128,0,128,0.25);  color: #da70d6; border: 1px solid #9932cc; }
.badge-success { background: rgba(45,106,79,0.3);   color: #52b788; border: 1px solid var(--vert); }
.badge-danger  { background: rgba(139,34,48,0.3);   color: #ff6b7a; border: 1px solid var(--rouge); }
.badge-neutral { background: rgba(90,90,90,0.3);    color: var(--ivoire-dim); border: 1px solid var(--gris-light); }

/* ── Modal ── */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.8);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
}

.modal-overlay.open { display: flex; }

.modal {
  background: var(--noir-card);
  border: 1px solid var(--or-dim);
  border-radius: var(--radius-lg);
  padding: 28px;
  width: min(520px, 95vw);
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow), var(--shadow-gold);
  position: relative;
  animation: modalIn 0.25s ease;
}

.modal-wide { width: min(720px, 95vw); }

/* ── Autocomplete client ── */
.ac-wrap { position: relative; }
.ac-dropdown {
  position: absolute;
  top: calc(100% + 2px);
  left: 0; right: 0;
  z-index: 20000;
  background: var(--noir-card);
  border: 1px solid var(--or-dim);
  border-top: none;
  border-radius: 0 0 var(--radius) var(--radius);
  box-shadow: 0 8px 28px rgba(0,0,0,0.75);
  overflow: hidden;
  display: none;
  max-height: 220px;
  overflow-y: auto;
}
.ac-dropdown.open { display: block; animation: acIn 0.12s ease; }
@keyframes acIn { from { opacity:0; transform:translateY(-4px); } to { opacity:1; transform:translateY(0); } }
.ac-item {
  padding: 9px 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  transition: background 0.1s;
}
.ac-item:last-child { border-bottom: none; }
.ac-item:hover, .ac-item.ac-active { background: rgba(201,168,76,0.13); }
.ac-name { color: var(--ivoire); font-size: 13px; font-weight: 600; }
.ac-name mark { background: none; color: var(--or); font-style: normal; }
.ac-meta { color: var(--ivoire-dim); font-size: 11px; white-space: nowrap; }
.ac-badge {
  font-size: 10px; font-weight: 700; padding: 1px 7px; border-radius: 10px;
  background: rgba(201,168,76,0.15); color: var(--or); letter-spacing: 0.5px;
}
.ac-hint {
  font-size: 10px; color: var(--ivoire-dim); padding: 5px 14px 6px;
  border-top: 1px solid var(--gris); background: rgba(0,0,0,0.3);
  text-align: center; pointer-events: none;
}
body.light-mode .ac-dropdown { background: #fff; box-shadow: 0 8px 24px rgba(0,0,0,0.18); border-color: #c9a84c; }
body.light-mode .ac-item:hover, body.light-mode .ac-item.ac-active { background: rgba(154,110,26,0.09); }
body.light-mode .ac-name { color: #1a1208; }
body.light-mode .ac-meta { color: #666; }

@keyframes modalIn {
  from { opacity: 0; transform: translateY(16px) scale(0.98); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--gris);
}

.modal-title {
  font-family: var(--font-display);
  font-size: 20px;
  color: var(--or);
}

.modal-close {
  background: none;
  border: none;
  color: var(--ivoire-dim);
  font-size: 20px;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: var(--radius);
  transition: var(--transition);
  line-height: 1;
}
.modal-close:hover { background: var(--gris); color: var(--ivoire); }

/* ── Toast ── */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  padding: 12px 18px;
  border-radius: var(--radius);
  font-size: 13px;
  font-family: var(--font-ui);
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: var(--shadow);
  animation: toastIn 0.3s ease;
  max-width: 340px;
}

.toast-success  { background: #1a3a2a; border: 1px solid var(--vert); color: #52b788; }
.toast-error    { background: #2a1a1e; border: 1px solid var(--rouge); color: #ff6b7a; }
.toast-info     { background: #1a1a2a; border: 1px solid var(--or-dim); color: var(--or); }
.toast-warning  { background: #2a1e0a; border: 1px solid #ff9800; color: #ffb74d; }

@keyframes toastIn {
  from { opacity: 0; transform: translateX(20px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* ── Loader ── */
.spinner {
  width: 18px; height: 18px;
  border: 2px solid var(--gris);
  border-top-color: var(--or);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Empty State ── */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 60px 20px;
  color: var(--gris-light);
}

.empty-state .icon { font-size: 48px; opacity: 0.4; }
.empty-state p { font-family: var(--font-body); font-size: 16px; font-style: italic; }

/* ============================================================
   PAGE 1 — PLAN DE SALLE
   ============================================================ */

#page-salle { flex-direction: row; overflow: hidden; }

/* Sidebar */
.salle-sidebar {
  width: var(--sidebar-w);
  min-width: var(--sidebar-w);
  background: var(--noir-soft);
  border-right: 1px solid var(--gris);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: width 0.28s cubic-bezier(0.4,0,0.2,1), min-width 0.28s cubic-bezier(0.4,0,0.2,1);
  position: relative;
  flex-shrink: 0;
}

.salle-sidebar.collapsed {
  width: 0 !important;
  min-width: 0 !important;
  border-right: none;
}

.sidebar-inner {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
}

/* Sidebar toggle tab */
.sidebar-toggle-btn {
  position: absolute;
  right: -18px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 50;
  width: 18px;
  height: 48px;
  background: var(--noir-soft);
  border: 1px solid var(--gris);
  border-left: none;
  border-radius: 0 6px 6px 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: var(--or);
  transition: var(--transition);
  padding: 0;
}
.sidebar-toggle-btn:hover { background: var(--gris); }
.salle-sidebar.collapsed .sidebar-toggle-btn { right: -18px; border-left: 1px solid var(--gris); border-radius: 6px; }

/* Sidebar category headers (collapsible) */
.sidebar-cat {
  padding: 0;
  border-bottom: 1px solid var(--gris);
}
.sidebar-cat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  cursor: pointer;
  user-select: none;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--or);
  background: transparent;
  transition: background 0.15s;
  border: none;
  width: 100%;
  text-align: left;
}
.sidebar-cat-header:hover { background: rgba(201,168,76,0.06); }
.sidebar-cat-arrow { font-size: 8px; transition: transform 0.2s; }
.sidebar-cat.open .sidebar-cat-arrow { transform: rotate(90deg); }
.sidebar-cat-body {
  display: none;
  padding: 8px 14px 12px;
}
.sidebar-cat.open .sidebar-cat-body { display: block; }

.sidebar-section-title {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--or-dim);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.tool-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.tool-btn {
  padding: 8px 10px;
  background: var(--noir-card);
  border: 1px solid var(--gris);
  border-radius: var(--radius);
  color: var(--ivoire-dim);
  font-family: var(--font-ui);
  font-size: 11px;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 6px;
  text-align: left;
}

.tool-btn:hover { border-color: var(--or-dim); color: var(--or); background: rgba(201,168,76,0.07); }
.tool-btn.active { border-color: var(--or); background: rgba(201,168,76,0.15); color: var(--or); }

/* Space tabs */
.space-tabs {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-height: 140px;
  overflow-y: auto;
}

.space-tab {
  padding: 8px 10px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12px;
  border: 1px solid transparent;
}

.space-tab:hover { background: var(--gris); }
.space-tab.active { background: rgba(201,168,76,0.15); border-color: var(--or-dim); color: var(--or); }

.space-tab-del {
  background: none; border: none; color: var(--gris-light); cursor: pointer;
  font-size: 14px; padding: 2px 4px; border-radius: 3px;
  transition: var(--transition);
}
.space-tab-del:hover { color: #ff6b7a; background: rgba(139,34,48,0.2); }

/* Layout presets */
.preset-list { display: flex; flex-direction: column; gap: 4px; overflow-y: auto; max-height: 180px; }

.preset-item {
  padding: 7px 10px;
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 12px;
  border: 1px solid var(--gris);
  background: var(--noir-card);
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: var(--transition);
  gap: 6px;
}

.preset-item:hover { border-color: var(--or-dim); }

.preset-actions { display: flex; gap: 4px; }
.preset-actions button {
  background: none; border: none; cursor: pointer;
  font-size: 13px; padding: 2px 4px; border-radius: 3px; color: var(--gris-light);
  transition: var(--transition);
}
.preset-actions button:hover { background: var(--gris); color: var(--ivoire); }

/* Canvas Area */
.salle-canvas-wrap {
  flex: 1;
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 20% 20%, rgba(201,168,76,0.04) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 80%, rgba(201,168,76,0.03) 0%, transparent 50%),
    var(--noir);
}

#salleCanvas {
  display: block;
  cursor: default;
}

/* Canvas toolbar */
.canvas-toolbar {
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  background: rgba(20,20,20,0.9);
  border: 1px solid var(--gris);
  border-radius: 30px;
  padding: 6px 12px;
  backdrop-filter: blur(8px);
  z-index: 10;
}

.canvas-info {
  position: absolute;
  bottom: 12px;
  left: 12px;
  background: rgba(20,20,20,0.85);
  border: 1px solid var(--gris);
  border-radius: var(--radius);
  padding: 6px 12px;
  font-size: 11px;
  color: var(--ivoire-dim);
  backdrop-filter: blur(6px);
}

/* ============================================================
   PAGE 2 — ÉVÉNEMENTS
   ============================================================ */

#page-events { padding: 0; }

.events-layout {
  display: flex;
  flex: 1;
  overflow: hidden;
}

.events-list-col {
  width: 380px;
  min-width: 380px;
  border-right: 1px solid var(--gris);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.events-list-scroll {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.event-card {
  background: var(--noir-card);
  border: 1px solid var(--gris);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.event-card::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--or-dim);
  opacity: 0;
  transition: var(--transition);
}

.event-card:hover { border-color: var(--or-dim); }
.event-card:hover::before { opacity: 1; }
.event-card.selected { border-color: var(--or); box-shadow: var(--shadow-gold); }
.event-card.selected::before { opacity: 1; background: var(--or); }

.event-card-title {
  font-family: var(--font-display);
  font-size: 16px;
  color: var(--ivoire);
  margin-bottom: 4px;
}

.event-card-meta {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
  font-size: 11px;
  color: var(--ivoire-dim);
}

.event-card-footer {
  margin-top: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.event-detail-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.event-detail-content {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
}

/* Reservation list */
.resa-table { width: 100%; border-collapse: collapse; margin-top: 12px; }
.resa-table th {
  background: var(--noir-soft);
  padding: 8px 12px;
  text-align: left;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--or);
  border-bottom: 1px solid var(--gris);
}
.resa-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--gris);
  font-size: 12px;
  color: var(--ivoire);
  vertical-align: middle;
}
.resa-table tr:last-child td { border-bottom: none; }
.resa-table tr:hover td { background: rgba(255,255,255,0.02); }

/* ============================================================
   PAGE 3 — SITE PUBLIC (réservation client)
   ============================================================ */

#page-public {
  background: var(--noir);
  overflow-y: auto;
}

.public-hero {
  background:
    linear-gradient(180deg, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0.9) 100%),
    repeating-linear-gradient(
      45deg,
      transparent,
      transparent 40px,
      rgba(201,168,76,0.03) 40px,
      rgba(201,168,76,0.03) 41px
    );
  padding: 48px 24px 36px;
  text-align: center;
  border-bottom: 1px solid var(--gris);
}

.public-hero-title {
  font-family: var(--font-display);
  font-size: 42px;
  font-weight: 900;
  color: var(--or);
  letter-spacing: 3px;
  margin-bottom: 4px;
}

.public-hero-sub {
  font-family: var(--font-body);
  font-size: 18px;
  color: var(--ivoire-dim);
  font-style: italic;
  letter-spacing: 3px;
}

.public-events-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
  padding: 28px 24px;
  max-width: 1200px;
  margin: 0 auto;
}

.public-event-card {
  background: var(--noir-card);
  border: 1px solid var(--gris);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: var(--transition);
}

.public-event-card:hover { border-color: var(--or-dim); transform: translateY(-2px); box-shadow: var(--shadow), var(--shadow-gold); }

.public-event-header {
  background: linear-gradient(135deg, #1a1200, #2a1f00);
  padding: 20px;
  border-bottom: 1px solid var(--or-dim);
  position: relative;
}

.public-event-header::after {
  content: '✦';
  position: absolute;
  top: 12px; right: 16px;
  color: var(--or-dim);
  font-size: 14px;
  opacity: 0.5;
}

.public-event-title {
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--or);
  margin-bottom: 6px;
}

.public-event-body { padding: 18px 20px; }

.public-event-detail {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 13px;
  color: var(--ivoire-dim);
}

.public-event-detail .ico { color: var(--or); width: 16px; text-align: center; }

.availability-bar {
  height: 6px;
  background: var(--gris);
  border-radius: 3px;
  overflow: hidden;
  margin: 10px 0 4px;
}

.availability-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--or-dim), var(--or));
  border-radius: 3px;
  transition: width 0.5s ease;
}

/* ============================================================
   PAGE 4 — SCANNER QR
   ============================================================ */

#page-scanner {
  align-items: center;
  justify-content: center;
  gap: 24px;
  padding: 32px;
  overflow-y: auto;
}

/* ═══════════════════════════════════════
   PAGE CALENDRIER
═══════════════════════════════════════ */
#page-calendrier {
  flex-direction: row;
  overflow: hidden;
  padding: 0;
  gap: 0;
}
.cal-left {
  width: 380px;
  min-width: 320px;
  border-right: 1px solid var(--or-dim);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--noir-card);
}
.cal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px 12px;
  border-bottom: 1px solid var(--gris);
}
.cal-title {
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--or);
  font-weight: 600;
}
.cal-nav-btn {
  background: none;
  border: 1px solid var(--gris);
  color: var(--ivoire);
  width: 32px; height: 32px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 16px;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.15s;
}
.cal-nav-btn:hover { border-color: var(--or); color: var(--or); }
.cal-grid {
  padding: 10px 16px 16px;
  flex: 1;
}
.cal-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  margin-bottom: 6px;
}
.cal-weekday {
  text-align: center;
  font-size: 10px;
  font-weight: 700;
  color: var(--ivoire-dim);
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 4px 0;
}
.cal-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}
.cal-day {
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  color: var(--ivoire);
  position: relative;
  transition: all 0.15s;
  border: 1.5px solid transparent;
  gap: 2px;
  padding-top: 2px;
}
.cal-day:hover { background: rgba(201,168,76,0.10); border-color: var(--or-dim); }
.cal-day.today { border-color: var(--or); color: var(--or); font-weight: 700; }
.cal-day.selected { background: rgba(201,168,76,0.18); border-color: var(--or); }
.cal-day.other-month { color: var(--ivoire-dim); opacity: 0.4; }
.cal-day.empty { cursor: default; }
.cal-day-dots {
  display: flex; gap: 2px; align-items: center; justify-content: center;
}
.cal-dot {
  width: 5px; height: 5px;
  border-radius: 50%;
}
.cal-dot-midi  { background: #52b788; }
.cal-dot-soir  { background: #7ab8d4; }
.cal-dot-event { background: var(--or); }
/* Légende */
.cal-legend {
  padding: 10px 16px 12px;
  border-top: 1px solid var(--gris);
  display: flex; gap: 16px; flex-wrap: wrap;
}
.cal-legend-item {
  display: flex; align-items: center; gap: 5px;
  font-size: 11px; color: var(--ivoire-dim);
}
/* Panneau droit — réservations du jour */
.cal-right {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.cal-right-header {
  padding: 18px 24px 14px;
  border-bottom: 1px solid var(--gris);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}
.cal-right-title {
  font-family: var(--font-display);
  font-size: 20px;
  color: var(--or);
}
.cal-right-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px 24px;
}
.cal-service-block {
  margin-bottom: 28px;
}
.cal-service-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--or);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.cal-service-title::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--or-dim);
  opacity: 0.4;
}
/* ── Tableau réservations calendrier ── */
.cal-resa-wrap {
  border: 1px solid var(--gris);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 8px;
}
.cal-resa-header {
  display: flex;
  align-items: center;
  background: rgba(201,168,76,0.07);
  border-bottom: 1px solid var(--gris);
  padding: 0;
}
.cal-resa-header span {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.7px;
  color: var(--or);
  font-weight: 600;
  padding: 5px 8px;
}
.cal-resa-row {
  display: flex;
  align-items: center;
  gap: 0;
  background: var(--noir-card);
  border-bottom: 1px solid var(--gris);
  transition: background 0.12s;
  overflow: hidden;
  cursor: pointer;
}
.cal-resa-row:last-child { border-bottom: none; }
.cal-resa-row:hover { background: rgba(201,168,76,0.05); }
/* Séparateur vertical sur chaque cellule sauf la dernière */
.cal-resa-row span,
.cal-resa-header span {
  border-right: 1px solid var(--gris);
}
.cal-resa-row span:last-child,
.cal-resa-header span:last-child { border-right: none; }

.cal-resa-slot  { font-size: 12px; color: var(--or); font-weight: 700; white-space: nowrap; width: 52px; flex-shrink: 0; padding: 7px 8px; }
.cal-resa-qty   { font-size: 12px; color: var(--ivoire-dim); white-space: nowrap; width: 36px; flex-shrink: 0; text-align: center; padding: 7px 4px; }
.cal-resa-name  { font-weight: 600; color: var(--ivoire); font-size: 13px; width: 150px; flex-shrink: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 7px 8px; }
.cal-resa-tel   { font-size: 12px; color: var(--ivoire-dim); white-space: nowrap; width: 108px; flex-shrink: 0; padding: 7px 8px; }
.cal-resa-table { font-size: 12px; color: var(--or); font-weight: 700; white-space: nowrap; width: 44px; flex-shrink: 0; text-align: center; padding: 7px 4px; }
.cal-resa-note  { font-size: 11px; color: var(--ivoire-dim); font-style: italic; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 7px 8px; }
.cal-empty-day {
  text-align: center;
  padding: 60px 20px;
  color: var(--ivoire-dim);
  font-style: italic;
}
.cal-empty-day .icon { font-size: 40px; margin-bottom: 12px; }

/* ═══════════════════════════════════════
   PAGE MENU DU JOUR
═══════════════════════════════════════ */
#page-menu {
  flex-direction: row;
  overflow: hidden;
  padding: 0;
  gap: 0;
}
.menu-left {
  width: 420px;
  min-width: 360px;
  border-right: 1px solid var(--or-dim);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--noir-card);
}
.menu-right {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.menu-section-header {
  padding: 18px 20px 14px;
  border-bottom: 1px solid var(--gris);
  display: flex; align-items: center; justify-content: space-between;
}
.menu-section-title {
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--or);
}
.menu-form-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.menu-field-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--ivoire-dim);
  margin-bottom: 5px;
}
.menu-history-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px 20px;
}
.menu-history-item {
  padding: 12px 16px;
  background: var(--noir-card);
  border: 1px solid var(--gris);
  border-radius: var(--radius);
  margin-bottom: 8px;
  cursor: pointer;
  transition: all 0.15s;
  position: relative;
}
.menu-history-item:hover { border-color: var(--or-dim); background: rgba(201,168,76,0.04); }
.menu-history-item.same-menu { border-color: #52b788; background: rgba(82,183,136,0.06); }
.menu-history-date {
  font-size: 11px;
  color: var(--or);
  font-weight: 700;
  margin-bottom: 4px;
}
.menu-history-preview {
  font-size: 12px;
  color: var(--ivoire-dim);
  font-style: italic;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.menu-same-badge {
  position: absolute;
  top: 8px; right: 10px;
  font-size: 10px;
  background: rgba(82,183,136,0.2);
  color: #52b788;
  padding: 2px 7px;
  border-radius: 8px;
  font-weight: 700;
}
/* Carte menu public */
@keyframes cardSlideUp { from { opacity: 0; transform: translateY(60px); } to { opacity: 1; transform: translateY(0); } }

.menu-public-card {
  background: var(--noir-card);
  border: 1px solid var(--or-dim);
  border-radius: var(--radius-lg);
  padding: 28px 32px;
  max-width: 540px;
  width: 100%;
  box-sizing: border-box;
  margin: 0 auto;
  animation: cardSlideUp 2s cubic-bezier(0.16, 1, 0.3, 1) 1 both;
}
.menu-public-title {
  font-family: var(--font-display);
  font-size: 26px;
  color: var(--ivoire);
  text-align: center;
  margin-bottom: 4px;
}
.menu-public-price {
  text-align: center;
  font-size: 28px;
  font-family: var(--font-display);
  color: var(--or);
  font-weight: 700;
  margin: 8px 0 20px;
}
.menu-course {
  margin-bottom: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--gris);
}
.menu-course:last-of-type { border-bottom: none; }
.menu-course-label {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--or-dim);
  margin-bottom: 5px;
}
.menu-course-text {
  font-size: 18px;
  color: var(--ivoire);
  font-family: var(--font-body);
  line-height: 1.4;
}
.menu-horaires {
  text-align: center;
  margin-top: 20px;
  font-size: 13px;
  color: var(--ivoire-dim);
  font-style: italic;
}
.menu-resa-cta {
  text-align: center;
  margin-top: 16px;
  font-size: 14px;
  color: var(--ivoire);
}
.menu-resa-tel {
  color: var(--or);
  font-weight: 700;
  font-size: 16px;
}

@media (max-width: 768px) {
  #page-calendrier, #page-menu { flex-direction: column; }
  .cal-left, .menu-left { width: 100%; min-width: unset; border-right: none; border-bottom: 1px solid var(--or-dim); max-height: 55vh; }
  .cal-right, .menu-right { flex: 1; min-height: 0; }
}

/* ═══════════════════════════════════════
   PAGE CINÉMA ADMIN
═══════════════════════════════════════ */
#page-cinema {
  flex-direction: column;
  overflow-y: auto;
  padding: 0;
}
.cinema-drop-zone {
  border: 2px dashed var(--or-dim);
  border-radius: var(--radius-lg);
  padding: 48px 32px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  background: rgba(201,168,76,0.03);
}
.cinema-drop-zone:hover,
.cinema-drop-zone.drag-over {
  border-color: var(--or);
  background: rgba(201,168,76,0.08);
}
.cinema-drop-icon { font-size: 48px; margin-bottom: 12px; }
.cinema-drop-text { font-size: 15px; color: var(--ivoire-dim); }
.cinema-drop-sub  { font-size: 12px; color: var(--gris-light); margin-top:6px; }
.cinema-preview-wrap {
  position: relative;
  display: inline-block;
  margin-top: 16px;
}
.cinema-preview-img {
  max-width: 100%;
  max-height: 500px;
  border-radius: var(--radius);
  border: 1px solid var(--or-dim);
}
/* Pages publiques plein écran visiteur */
#page-public-menu,
#page-public-cinema {
  overflow-y: auto;
  padding: 0 0 40px;
  align-items: center;
}
/* ── Public tab bar ── */
.public-tab-bar {
  display: flex;
  gap: 6px;
  padding: 8px 16px;
  border-bottom: 1px solid var(--gris);
  background: var(--noir-soft);
  flex-shrink: 0;
  align-self: stretch;
  justify-content: center;
  align-items: center;
}
.public-tab-btn {
  padding: 7px 16px;
  border: 1px solid var(--gris);
  border-radius: 8px;
  background: var(--noir-card);
  color: var(--ivoire-dim);
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  letter-spacing: 0.3px;
}
.public-tab-btn:hover { background: var(--gris); color: var(--ivoire); }
.public-tab-btn.active {
  background: var(--noir-card);
  color: var(--or);
  border-color: var(--or);
  box-shadow: 0 0 0 1px var(--or-dim);
}

.pub-page-back {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--noir-card);
  border-bottom: 1px solid var(--or-dim);
  padding: 12px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
}
.pub-page-back-btn {
  background: none;
  border: 1px solid var(--gris);
  color: var(--ivoire-dim);
  padding: 6px 14px;
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 13px;
  transition: all 0.15s;
}
.pub-page-back-btn:hover { border-color: var(--or); color: var(--or); }
.pub-page-title {
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--or);
}
/* Modal calendrier service */
.cal-service-modal {
  position: fixed;
  inset: 0;
  z-index: 9500;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(4px);
}
.cal-service-modal-box {
  background: var(--noir-card);
  border: 1px solid var(--or-dim);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-gold);
  padding: 32px;
  width: min(480px, 95vw);
  max-height: 90vh;
  overflow-y: auto;
}
/* Modal choix service double-clic */
.cal-choice-modal {
  position: fixed;
  inset: 0;
  z-index: 9600;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.8);
  backdrop-filter: blur(6px);
}
.cal-choice-box {
  background: var(--noir-card);
  border: 1px solid var(--or-dim);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-gold);
  padding: 32px 28px;
  width: min(420px, 95vw);
  text-align: center;
}
.cal-choice-title {
  font-family: var(--font-display);
  font-size: 20px;
  color: var(--or);
  margin-bottom: 6px;
}
.cal-choice-sub {
  font-size: 13px;
  color: var(--ivoire-dim);
  margin-bottom: 24px;
  font-style: italic;
}
.cal-choice-btns {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.cal-choice-btn {
  padding: 14px 20px;
  border-radius: var(--radius);
  border: 1px solid var(--or-dim);
  background: rgba(201,168,76,0.06);
  color: var(--ivoire);
  font-size: 15px;
  cursor: pointer;
  transition: all 0.15s;
  font-family: var(--font-display);
  letter-spacing: 0.5px;
}
.cal-choice-btn:hover { background: rgba(201,168,76,0.15); border-color: var(--or); color: var(--or); }
.cal-choice-btn.danger { border-color: var(--gris); color: var(--ivoire-dim); background: none; font-family: var(--font-body); font-size: 13px; }
/* Modal plan de service depuis calendrier */
.cal-plan-modal {
  position: fixed;
  inset: 0;
  z-index: 9700;
  background: rgba(0,0,0,0.85);
  display: flex;
  flex-direction: column;
}
.cal-plan-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  border-bottom: 1px solid var(--or-dim);
  background: var(--noir-card);
  flex-shrink: 0;
}
.cal-plan-title {
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--or);
}
#cal-plan-canvas {
  flex: 1;
  display: block;
  cursor: crosshair;
}

.scanner-card {
  background: var(--noir-card);
  border: 1px solid var(--or-dim);
  border-radius: var(--radius-lg);
  padding: 28px;
  width: min(480px, 100%);
  box-shadow: var(--shadow-gold);
}

.scanner-video-wrap {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: #000;
  aspect-ratio: 4/3;
}

#scannerVideo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.scanner-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.scanner-frame {
  width: 200px;
  height: 200px;
  border: 2px solid var(--or);
  border-radius: 8px;
  box-shadow: 0 0 0 9999px rgba(0,0,0,0.5);
  position: relative;
}

.scanner-frame::before,
.scanner-frame::after {
  content: '';
  position: absolute;
  width: 24px; height: 24px;
}

.scanner-frame::before {
  top: -3px; left: -3px;
  border-top: 3px solid var(--or-light);
  border-left: 3px solid var(--or-light);
  border-radius: 4px 0 0 0;
}

.scanner-frame::after {
  bottom: -3px; right: -3px;
  border-bottom: 3px solid var(--or-light);
  border-right: 3px solid var(--or-light);
  border-radius: 0 0 4px 0;
}

.scanner-line {
  position: absolute;
  left: 4px; right: 4px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--or), transparent);
  animation: scanLine 2s ease-in-out infinite;
}

@keyframes scanLine {
  0%   { top: 10%; }
  50%  { top: 85%; }
  100% { top: 10%; }
}

.scan-result {
  margin-top: 16px;
  padding: 16px;
  border-radius: var(--radius);
  display: none;
}

.scan-result.valid   { background: rgba(45,106,79,0.2); border: 1px solid var(--vert); }
.scan-result.invalid { background: rgba(139,34,48,0.2); border: 1px solid var(--rouge); }
.scan-result.show    { display: block; animation: modalIn 0.3s ease; }

/* ============================================================
   TICKET PDF PREVIEW
   ============================================================ */

#ticket-preview {
  font-family: var(--font-ui);
  background: #fff;
  color: #111;
  width: 400px;
  border-radius: 12px;
  overflow: hidden;
  position: fixed;
  left: -9999px;
  top: 0;
}

.ticket-header {
  background: linear-gradient(135deg, #0d0d0d, #1a1000);
  padding: 24px;
  text-align: center;
  border-bottom: 4px solid #c9a84c;
}

.ticket-header h2 {
  font-family: 'Playfair Display', serif;
  color: #c9a84c;
  font-size: 22px;
  letter-spacing: 2px;
}

.ticket-header p {
  color: #d4cfc5;
  font-size: 12px;
  letter-spacing: 3px;
  margin-top: 4px;
  font-style: italic;
}

.ticket-body {
  padding: 20px 24px;
  background: #fafafa;
}

.ticket-row {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  border-bottom: 1px dashed #ddd;
  font-size: 13px;
}

.ticket-row:last-child { border-bottom: none; }
.ticket-row .label { color: #666; font-weight: 600; }
.ticket-row .value { color: #111; font-weight: 500; }

.ticket-qr {
  padding: 20px;
  display: flex;
  justify-content: center;
  background: #fff;
  border-top: 1px dashed #ccc;
}

.ticket-footer {
  background: #0d0d0d;
  padding: 12px 24px;
  text-align: center;
  font-size: 11px;
  color: #666;
  letter-spacing: 1px;
}

/* ═══════════════════════════════════════
   PAGE CALENDRIER
═══════════════════════════════════════ */
#page-calendrier {
  flex-direction: row;
  overflow: hidden;
  padding: 0;
  gap: 0;
}
.cal-left {
  width: 380px;
  min-width: 320px;
  border-right: 1px solid var(--or-dim);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--noir-card);
}
.cal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px 12px;
  border-bottom: 1px solid var(--gris);
}
.cal-title {
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--or);
  font-weight: 600;
}
.cal-nav-btn {
  background: none;
  border: 1px solid var(--gris);
  color: var(--ivoire);
  width: 32px; height: 32px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 16px;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.15s;
}
.cal-nav-btn:hover { border-color: var(--or); color: var(--or); }
.cal-grid {
  padding: 10px 16px 16px;
  flex: 1;
}
.cal-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  margin-bottom: 6px;
}
.cal-weekday {
  text-align: center;
  font-size: 10px;
  font-weight: 700;
  color: var(--ivoire-dim);
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 4px 0;
}
.cal-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}
.cal-day {
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  color: var(--ivoire);
  position: relative;
  transition: all 0.15s;
  border: 1.5px solid transparent;
  gap: 2px;
  padding-top: 2px;
}
.cal-day:hover { background: rgba(201,168,76,0.10); border-color: var(--or-dim); }
.cal-day.today { border-color: var(--or); color: var(--or); font-weight: 700; }
.cal-day.selected { background: rgba(201,168,76,0.18); border-color: var(--or); }
.cal-day.other-month { color: var(--ivoire-dim); opacity: 0.4; }
.cal-day.empty { cursor: default; }
.cal-day-dots {
  display: flex; gap: 2px; align-items: center; justify-content: center;
}
.cal-dot {
  width: 5px; height: 5px;
  border-radius: 50%;
}
.cal-dot-midi  { background: #52b788; }
.cal-dot-soir  { background: #7ab8d4; }
.cal-dot-event { background: var(--or); }
/* Légende */
.cal-legend {
  padding: 10px 16px 12px;
  border-top: 1px solid var(--gris);
  display: flex; gap: 16px; flex-wrap: wrap;
}
.cal-legend-item {
  display: flex; align-items: center; gap: 5px;
  font-size: 11px; color: var(--ivoire-dim);
}
/* Panneau droit — réservations du jour */
.cal-right {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.cal-right-header {
  padding: 18px 24px 14px;
  border-bottom: 1px solid var(--gris);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}
.cal-right-title {
  font-family: var(--font-display);
  font-size: 20px;
  color: var(--or);
}
.cal-right-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px 24px;
}
.cal-service-block {
  margin-bottom: 28px;
}
.cal-service-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--or);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.cal-service-title::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--or-dim);
  opacity: 0.4;
}
/* ── Tableau réservations calendrier ── */
.cal-resa-wrap {
  border: 1px solid var(--gris);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 8px;
}
.cal-resa-header {
  display: flex;
  align-items: center;
  background: rgba(201,168,76,0.07);
  border-bottom: 1px solid var(--gris);
  padding: 0;
}
.cal-resa-header span {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.7px;
  color: var(--or);
  font-weight: 600;
  padding: 5px 8px;
}
.cal-resa-row {
  display: flex;
  align-items: center;
  gap: 0;
  background: var(--noir-card);
  border-bottom: 1px solid var(--gris);
  transition: background 0.12s;
  overflow: hidden;
  cursor: pointer;
}
.cal-resa-row:last-child { border-bottom: none; }
.cal-resa-row:hover { background: rgba(201,168,76,0.05); }
/* Séparateur vertical sur chaque cellule sauf la dernière */
.cal-resa-row span,
.cal-resa-header span {
  border-right: 1px solid var(--gris);
}
.cal-resa-row span:last-child,
.cal-resa-header span:last-child { border-right: none; }

.cal-resa-slot  { font-size: 12px; color: var(--or); font-weight: 700; white-space: nowrap; width: 52px; flex-shrink: 0; padding: 7px 8px; }
.cal-resa-qty   { font-size: 12px; color: var(--ivoire-dim); white-space: nowrap; width: 36px; flex-shrink: 0; text-align: center; padding: 7px 4px; }
.cal-resa-name  { font-weight: 600; color: var(--ivoire); font-size: 13px; width: 150px; flex-shrink: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 7px 8px; }
.cal-resa-tel   { font-size: 12px; color: var(--ivoire-dim); white-space: nowrap; width: 108px; flex-shrink: 0; padding: 7px 8px; }
.cal-resa-table { font-size: 12px; color: var(--or); font-weight: 700; white-space: nowrap; width: 44px; flex-shrink: 0; text-align: center; padding: 7px 4px; }
.cal-resa-note  { font-size: 11px; color: var(--ivoire-dim); font-style: italic; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 7px 8px; }
.cal-empty-day {
  text-align: center;
  padding: 60px 20px;
  color: var(--ivoire-dim);
  font-style: italic;
}
.cal-empty-day .icon { font-size: 40px; margin-bottom: 12px; }

/* ═══════════════════════════════════════
   PAGE MENU DU JOUR
═══════════════════════════════════════ */
#page-menu {
  flex-direction: row;
  overflow: hidden;
  padding: 0;
  gap: 0;
}
.menu-left {
  width: 420px;
  min-width: 360px;
  border-right: 1px solid var(--or-dim);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--noir-card);
}
.menu-right {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.menu-section-header {
  padding: 18px 20px 14px;
  border-bottom: 1px solid var(--gris);
  display: flex; align-items: center; justify-content: space-between;
}
.menu-section-title {
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--or);
}
.menu-form-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.menu-field-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--ivoire-dim);
  margin-bottom: 5px;
}
.menu-history-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px 20px;
}
.menu-history-item {
  padding: 12px 16px;
  background: var(--noir-card);
  border: 1px solid var(--gris);
  border-radius: var(--radius);
  margin-bottom: 8px;
  cursor: pointer;
  transition: all 0.15s;
  position: relative;
}
.menu-history-item:hover { border-color: var(--or-dim); background: rgba(201,168,76,0.04); }
.menu-history-item.same-menu { border-color: #52b788; background: rgba(82,183,136,0.06); }
.menu-history-date {
  font-size: 11px;
  color: var(--or);
  font-weight: 700;
  margin-bottom: 4px;
}
.menu-history-preview {
  font-size: 12px;
  color: var(--ivoire-dim);
  font-style: italic;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.menu-same-badge {
  position: absolute;
  top: 8px; right: 10px;
  font-size: 10px;
  background: rgba(82,183,136,0.2);
  color: #52b788;
  padding: 2px 7px;
  border-radius: 8px;
  font-weight: 700;
}
/* Carte menu public */
@keyframes cardSlideUp { from { opacity: 0; transform: translateY(60px); } to { opacity: 1; transform: translateY(0); } }

.menu-public-card {
  background: var(--noir-card);
  border: 1px solid var(--or-dim);
  border-radius: var(--radius-lg);
  padding: 28px 32px;
  max-width: 540px;
  width: 100%;
  box-sizing: border-box;
  margin: 0 auto;
  animation: cardSlideUp 2s cubic-bezier(0.16, 1, 0.3, 1) 1 both;
}
.menu-public-title {
  font-family: var(--font-display);
  font-size: 26px;
  color: var(--ivoire);
  text-align: center;
  margin-bottom: 4px;
}
.menu-public-price {
  text-align: center;
  font-size: 28px;
  font-family: var(--font-display);
  color: var(--or);
  font-weight: 700;
  margin: 8px 0 20px;
}
.menu-course {
  margin-bottom: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--gris);
}
.menu-course:last-of-type { border-bottom: none; }
.menu-course-label {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--or-dim);
  margin-bottom: 5px;
}
.menu-course-text {
  font-size: 18px;
  color: var(--ivoire);
  font-family: var(--font-body);
  line-height: 1.4;
}
.menu-horaires {
  text-align: center;
  margin-top: 20px;
  font-size: 13px;
  color: var(--ivoire-dim);
  font-style: italic;
}
.menu-resa-cta {
  text-align: center;
  margin-top: 16px;
  font-size: 14px;
  color: var(--ivoire);
}
.menu-resa-tel {
  color: var(--or);
  font-weight: 700;
  font-size: 16px;
}

@media (max-width: 768px) {
  #page-calendrier, #page-menu { flex-direction: column; }
  .cal-left, .menu-left { width: 100%; min-width: unset; border-right: none; border-bottom: 1px solid var(--or-dim); max-height: 55vh; }
  .cal-right, .menu-right { flex: 1; min-height: 0; }
}

/* ═══════════════════════════════════════
   PAGE CINÉMA ADMIN
═══════════════════════════════════════ */
#page-cinema {
  flex-direction: column;
  overflow-y: auto;
  padding: 0;
}
.cinema-drop-zone {
  border: 2px dashed var(--or-dim);
  border-radius: var(--radius-lg);
  padding: 48px 32px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  background: rgba(201,168,76,0.03);
}
.cinema-drop-zone:hover,
.cinema-drop-zone.drag-over {
  border-color: var(--or);
  background: rgba(201,168,76,0.08);
}
.cinema-drop-icon { font-size: 48px; margin-bottom: 12px; }
.cinema-drop-text { font-size: 15px; color: var(--ivoire-dim); }
.cinema-drop-sub  { font-size: 12px; color: var(--gris-light); margin-top:6px; }
.cinema-preview-wrap {
  position: relative;
  display: inline-block;
  margin-top: 16px;
}
.cinema-preview-img {
  max-width: 100%;
  max-height: 500px;
  border-radius: var(--radius);
  border: 1px solid var(--or-dim);
}
/* Pages publiques plein écran visiteur */
#page-public-menu,
#page-public-cinema {
  overflow-y: auto;
  padding: 0 0 40px;
  align-items: center;
}
/* ── Public tab bar ── */
.public-tab-bar {
  display: flex;
  gap: 6px;
  padding: 8px 16px;
  border-bottom: 1px solid var(--gris);
  background: var(--noir-soft);
  flex-shrink: 0;
  align-self: stretch;
  justify-content: center;
  align-items: center;
}
.public-tab-btn {
  padding: 7px 16px;
  border: 1px solid var(--gris);
  border-radius: 8px;
  background: var(--noir-card);
  color: var(--ivoire-dim);
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  letter-spacing: 0.3px;
}
.public-tab-btn:hover { background: var(--gris); color: var(--ivoire); }
.public-tab-btn.active {
  background: var(--noir-card);
  color: var(--or);
  border-color: var(--or);
  box-shadow: 0 0 0 1px var(--or-dim);
}

.pub-page-back {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--noir-card);
  border-bottom: 1px solid var(--or-dim);
  padding: 12px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
}
.pub-page-back-btn {
  background: none;
  border: 1px solid var(--gris);
  color: var(--ivoire-dim);
  padding: 6px 14px;
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 13px;
  transition: all 0.15s;
}
.pub-page-back-btn:hover { border-color: var(--or); color: var(--or); }
.pub-page-title {
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--or);
}
/* Modal calendrier service */
.cal-service-modal {
  position: fixed;
  inset: 0;
  z-index: 9500;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(4px);
}
.cal-service-modal-box {
  background: var(--noir-card);
  border: 1px solid var(--or-dim);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-gold);
  padding: 32px;
  width: min(480px, 95vw);
  max-height: 90vh;
  overflow-y: auto;
}
/* Modal choix service double-clic */
.cal-choice-modal {
  position: fixed;
  inset: 0;
  z-index: 9600;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.8);
  backdrop-filter: blur(6px);
}
.cal-choice-box {
  background: var(--noir-card);
  border: 1px solid var(--or-dim);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-gold);
  padding: 32px 28px;
  width: min(420px, 95vw);
  text-align: center;
}
.cal-choice-title {
  font-family: var(--font-display);
  font-size: 20px;
  color: var(--or);
  margin-bottom: 6px;
}
.cal-choice-sub {
  font-size: 13px;
  color: var(--ivoire-dim);
  margin-bottom: 24px;
  font-style: italic;
}
.cal-choice-btns {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.cal-choice-btn {
  padding: 14px 20px;
  border-radius: var(--radius);
  border: 1px solid var(--or-dim);
  background: rgba(201,168,76,0.06);
  color: var(--ivoire);
  font-size: 15px;
  cursor: pointer;
  transition: all 0.15s;
  font-family: var(--font-display);
  letter-spacing: 0.5px;
}
.cal-choice-btn:hover { background: rgba(201,168,76,0.15); border-color: var(--or); color: var(--or); }
.cal-choice-btn.danger { border-color: var(--gris); color: var(--ivoire-dim); background: none; font-family: var(--font-body); font-size: 13px; }
/* Modal plan de service depuis calendrier */
.cal-plan-modal {
  position: fixed;
  inset: 0;
  z-index: 9700;
  background: rgba(0,0,0,0.85);
  display: flex;
  flex-direction: column;
}
.cal-plan-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  border-bottom: 1px solid var(--or-dim);
  background: var(--noir-card);
  flex-shrink: 0;
}
.cal-plan-title {
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--or);
}
#cal-plan-canvas {
  flex: 1;
  display: block;
  cursor: crosshair;
}


/* ============================================================
   STATS BAR
   ============================================================ */

.stats-bar {
  display: flex;
  gap: 1px;
  background: var(--gris);
  border-top: 1px solid var(--gris);
  flex-shrink: 0;
}

.stat-block {
  flex: 1;
  background: var(--noir-card);
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.stat-icon { font-size: 18px; }

.stat-value {
  font-family: var(--font-display);
  font-size: 20px;
  color: var(--or);
  font-weight: 700;
  line-height: 1;
}

.stat-label {
  font-size: 10px;
  color: var(--ivoire-dim);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ============================================================
   UTILITIES
   ============================================================ */

.flex { display: flex; }
.flex-col { flex-direction: column; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.gap-4 { gap: 16px; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 12px; }
.mt-4 { margin-top: 16px; }
.mb-2 { margin-bottom: 8px; }
.mb-3 { margin-bottom: 12px; }
.w-full { width: 100%; }
.text-or { color: var(--or); }
.text-dim { color: var(--ivoire-dim); }
.text-sm { font-size: 12px; }
.italic { font-style: italic; }
.font-body { font-family: var(--font-body); }
.font-display { font-family: var(--font-display); }
.hidden { display: none !important; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }

.progress-wrap { background: var(--gris); border-radius: 4px; height: 8px; overflow: hidden; }
.progress-fill { height: 100%; background: linear-gradient(90deg, var(--or-dim), var(--or)); border-radius: 4px; transition: width 0.4s; }

/* ============================================================
   AUTH — Écran de connexion Admin
   ============================================================ */

#auth-screen {
  position: fixed;
  inset: 0;
  z-index: 9000;
  background: var(--noir);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.auth-facade-mobile {
  display: none;
}
@media (max-width: 600px) {
  #auth-screen {
    flex-direction: column;
    justify-content: flex-start;
    align-items: stretch;
    overflow-y: auto;
  }
  .auth-facade-mobile {
    display: block;
    width: 100%;
    height: 220px;
    object-fit: cover;
    object-position: right center;
    flex-shrink: 0;
  }
  .auth-card {
    margin: -20px 16px 24px;
    border-radius: 16px;
    width: auto;
  }
}

#auth-screen::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 30% 40%, rgba(201,168,76,0.07) 0%, transparent 60%),
    radial-gradient(ellipse 50% 60% at 70% 60%, rgba(139,34,48,0.06) 0%, transparent 60%),
    repeating-linear-gradient(
      45deg,
      transparent, transparent 60px,
      rgba(201,168,76,0.018) 60px, rgba(201,168,76,0.018) 61px
    );
  pointer-events: none;
}

.auth-card {
  position: relative;
  z-index: 1;
  width: min(420px, 92vw);
  background: var(--noir-card);
  border: 1px solid var(--or-dim);
  border-radius: 16px;
  padding: 44px 40px 36px;
  box-shadow: 0 8px 60px rgba(0,0,0,0.8), 0 0 40px rgba(201,168,76,0.12);
  animation: authIn 0.5s cubic-bezier(0.2,0,0.1,1);
}

@keyframes authIn {
  from { opacity:0; transform: translateY(28px) scale(0.96); }
  to   { opacity:1; transform: translateY(0) scale(1); }
}

.auth-logo {
  text-align: center;
  margin-bottom: 32px;
}

/* ── Flip logo auth ── */
@keyframes logoFlip {
  0%      { transform: rotateY(0deg); }
  17%     { transform: rotateY(180deg); }
  55%     { transform: rotateY(180deg); }
  72%     { transform: rotateY(360deg); }
  100%    { transform: rotateY(360deg); }
}
.auth-logo-flip {
  width: 80px; height: 80px;
  perspective: 500px;
  margin: 0 auto 14px;
}
.auth-flip-inner {
  width: 100%; height: 100%;
  transform-style: preserve-3d;
  animation: logoFlip 2s ease-in-out 1 forwards;
  animation-delay: 2.3s;
}
.auth-flip-front,
.auth-flip-back {
  position: absolute; width: 100%; height: 100%;
  border-radius: 50%;
  backface-visibility: hidden;
}
.auth-flip-front img {
  width: 100%; height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--or-dim);
  box-shadow: 0 0 24px rgba(201,168,76,0.2);
  display: block;
}
/* Face arrière : jeton doré */
.auth-flip-back {
  transform: rotateY(180deg);
  background: conic-gradient(
    #fff 0deg 10deg,   #c9a84c 10deg 30deg,
    #fff 30deg 40deg,  #c9a84c 40deg 60deg,
    #fff 60deg 70deg,  #c9a84c 70deg 90deg,
    #fff 90deg 100deg, #c9a84c 100deg 120deg,
    #fff 120deg 130deg,#c9a84c 130deg 150deg,
    #fff 150deg 160deg,#c9a84c 160deg 180deg,
    #fff 180deg 190deg,#c9a84c 190deg 210deg,
    #fff 210deg 220deg,#c9a84c 220deg 240deg,
    #fff 240deg 250deg,#c9a84c 250deg 270deg,
    #fff 270deg 280deg,#c9a84c 280deg 300deg,
    #fff 300deg 310deg,#c9a84c 310deg 330deg,
    #fff 330deg 340deg,#c9a84c 340deg 360deg
  );
  box-shadow: 0 0 20px rgba(201,168,76,0.5);
}
.auth-flip-back::before {
  content: '';
  position: absolute; top: 10px; left: 10px; right: 10px; bottom: 10px;
  border-radius: 50%;
  background: #1a1000;
  border: 2px solid var(--or);
}
.auth-flip-back::after {
  content: '50';
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  color: var(--or);
  font-family: var(--font-display);
  font-size: 18px; font-weight: 700;
  text-shadow: 0 1px 4px rgba(0,0,0,0.7);
}

@keyframes slideFromLeft {
  from { opacity: 0; transform: translateX(-80px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes slideFromRight {
  from { opacity: 0; transform: translateX(80px); }
  to   { opacity: 1; transform: translateX(0); }
}

.auth-title-line1 {
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--or);
  letter-spacing: 2px;
  margin-bottom: 4px;
  overflow: hidden;
  animation: slideFromLeft 2s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.auth-title-line2 {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 400;
  color: var(--ivoire-dim);
  letter-spacing: 4px;
  text-transform: uppercase;
  margin-bottom: 0;
  animation: slideFromRight 2s cubic-bezier(0.16, 1, 0.3, 1) both;
  animation-delay: 0.1s;
}

.auth-logo p {
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--ivoire-dim);
  font-style: italic;
  letter-spacing: 2px;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--gris-light);
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
}
.auth-divider::before, .auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--or-dim), transparent);
}

.auth-role-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 20px;
}

.role-card {
  padding: 14px 12px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--gris);
  background: var(--noir-soft);
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
}

.role-card:hover { border-color: var(--or-dim); background: rgba(201,168,76,0.05); }
.role-card.selected { border-color: var(--or); background: rgba(201,168,76,0.1); box-shadow: 0 0 12px rgba(201,168,76,0.15); }

.role-card .role-icon { font-size: 24px; margin-bottom: 6px; }
.role-card .role-name { font-size: 12px; font-weight: 600; color: var(--ivoire); letter-spacing: 0.5px; }
.role-card .role-desc { font-size: 10px; color: var(--ivoire-dim); margin-top: 2px; font-style: italic; font-family: var(--font-body); }

.auth-error {
  background: rgba(139,34,48,0.2);
  border: 1px solid var(--rouge);
  border-radius: var(--radius);
  padding: 9px 14px;
  font-size: 12px;
  color: #ff6b7a;
  margin-top: 10px;
  display: none;
  animation: toastIn 0.2s ease;
}

/* Admin badge in topbar */
.admin-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: linear-gradient(135deg, rgba(201,168,76,0.15), rgba(201,168,76,0.08));
  border: 1px solid var(--or-dim);
  border-radius: 20px;
  font-size: 11px;
  color: var(--or);
  font-weight: 600;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: var(--transition);
}
.admin-badge:hover { background: rgba(201,168,76,0.2); }

/* ── Modal plan admin événement ── */
.modal-event-plan {
  width: min(98vw, 1400px);
  height: 92vh;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 0;
}
.modal-event-plan .modal-header {
  padding: 14px 20px 12px;
  margin-bottom: 0;
  flex-shrink: 0;
}
#event-plan-canvas-container {
  flex: 1;
  position: relative;
  overflow: hidden;
  min-height: 0;
  background: var(--noir);
}
#event-plan-canvas {
  display: block;
  width: 100%;
  height: 100%;
  cursor: crosshair;
}
.event-plan-toolbar {
  flex-shrink: 0;
  padding: 8px 16px;
  border-top: 1px solid var(--gris);
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  background: var(--noir-soft);
  font-size: 12px;
  color: var(--ivoire-dim);
}

/* Table cliquable surbrillée sur plan bg */
.resa-table-tooltip {
  position: absolute;
  background: rgba(13,13,13,0.9);
  border: 1px solid var(--or-dim);
  border-radius: var(--radius);
  padding: 6px 12px;
  font-size: 12px;
  color: var(--or);
  pointer-events: none;
  white-space: nowrap;
  transform: translate(-50%, -110%);
  z-index: 9100;
}
.prop-selected-info {
  background: rgba(201,168,76,0.07);
  border: 1px solid var(--or-dim);
  border-radius: var(--radius);
  padding: 8px 12px;
  margin-top: 8px;
  font-size: 11px;
  color: var(--or);
  display: none;
}

/* Rotation arc visual hint on canvas */

/* ============================================================
   RESPONSIVE MOBILE — 375px+
   ============================================================ */

/* ── Bouton Accueil mobile (admin) ── */
#mobile-accueil-btn {
  display: none;
  background: none;
  border: 1px solid var(--gris);
  border-radius: var(--radius);
  color: var(--or);
  font-size: 13px;
  padding: 4px 10px;
  cursor: pointer;
  transition: var(--transition);
}
#mobile-accueil-btn:hover { border-color: var(--or); }

@media (max-width: 768px) {
  /* Topbar : masquer nav normale, afficher hamburger si admin */
  .topbar { padding: 0 16px; height: 52px; }
  .topbar-logo h1 { font-size: 16px; }
  .topbar-logo span { display: none; }
  .topbar-nav { display: none !important; }
  #mobile-accueil-btn { display: flex; align-items: center; justify-content: center; }
  .topbar-date { display: none; }

  /* Page publique hero */
  .public-hero { padding: 28px 16px 22px; }
  .public-hero-title { font-size: 26px; letter-spacing: 1px; }
  .public-hero-sub { font-size: 14px; letter-spacing: 1px; }
  .public-events-grid { grid-template-columns: 1fr; padding: 16px 12px; gap: 14px; }

}

body.light-mode #mobile-nav-drawer { background: #f8f5ef; border-color: #c9a84c; }
body.light-mode .mobile-nav-item { color: #1a1208; }
body.light-mode .mobile-nav-item:hover { background: rgba(154,110,26,0.08); }

/* ── Jeux & Machines à Sous ── */
.jeux-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.5px;
}
.jeux-status-badge.jeux-open {
  background: rgba(82, 183, 136, 0.15);
  border: 1px solid rgba(82, 183, 136, 0.5);
  color: #52b788;
}
.jeux-status-badge.jeux-closed {
  background: rgba(200, 70, 70, 0.12);
  border: 1px solid rgba(200, 70, 70, 0.4);
  color: #e07070;
}
.jeux-legal-banner {
  background: #f5c800;
  border: none;
  border-radius: 0;
  padding: 14px 20px;
  margin-top: 8px;
  margin-left: -16px;
  margin-right: -16px;
  margin-bottom: -24px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.jeux-legal-banner-text {
  flex: 1;
  text-align: center;
}
.jeux-legal-banner-line1 {
  font-size: 11px;
  font-weight: 800;
  color: #1a1a1a;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  line-height: 1.5;
}
.jeux-legal-banner-line2 {
  font-size: 10px;
  font-weight: 700;
  color: #1a1a1a;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  line-height: 1.5;
  margin-top: 4px;
}
.jeux-legal-banner-line2 a {
  color: #1a1a1a;
  text-decoration: underline;
}
.jeux-legal-18 {
  flex-shrink: 0;
  width: 62px;
  height: 62px;
  background: #fff;
  border: 3px solid #e00;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  font-weight: 900;
  color: #1a1a1a;
  letter-spacing: -0.5px;
  line-height: 1;
  position: relative;
  overflow: hidden;
}
.jeux-legal-18::after {
  content: '';
  position: absolute;
  top: 50%;
  left: -4px;
  right: -4px;
  height: 3px;
  background: #e00;
  transform: translateY(-50%) rotate(-35deg);
}


@media (max-width: 768px) {
  #admin-login-toggle { display: none !important; }
}

@media (max-width: 600px) {
  .public-tab-bar {
    overflow-x: auto;
    justify-content: flex-start;
    padding: 8px 10px;
    gap: 5px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .public-tab-bar::-webkit-scrollbar { display: none; }
  .public-tab-btn {
    flex-shrink: 0;
    padding: 6px 12px;
    font-size: 11.5px;
    white-space: nowrap;
    letter-spacing: 0;
    border-radius: 6px;
  }
}

/* ── Tab bar mobile dark mode : fond plus clair pour la distinguer ── */
@media (max-width: 600px) {
  body:not(.light-mode) .public-tab-bar {
    background: #383838;
    box-shadow: 0 2px 8px rgba(0,0,0,0.4);
    border-bottom-color: #484848;
  }
  body:not(.light-mode) .public-tab-dots {
    background: var(--noir);
  }
}


/* ── Animation titre événements ── */
@keyframes revealLTR   { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0% 0 0); } }
@keyframes starWink    { 0% { opacity:0; transform:scale(0) rotate(-20deg); } 70% { transform:scale(1.4) rotate(10deg); opacity:1; } 100% { transform:scale(1) rotate(0deg); opacity:1; } }

.hero-reveal-sub { clip-path: inset(0 100% 0 0); animation: revealLTR 1.4s ease-out 0.3s 1 forwards; }
.star-wink       { display:inline-block; opacity:0; animation: starWink 0.5s ease-out 1.5s 1 forwards; }

/* ── Animation titre cinéma ── */
@keyframes cinemaTitle { from { transform: perspective(400px) rotateY(0deg); } to { transform: perspective(400px) rotateY(360deg); } }
@keyframes cinemaSub   { from { opacity: 0; letter-spacing: 6px; } to { opacity: 1; letter-spacing: 1px; } }

.cinema-title-anim { animation: cinemaTitle 2s cubic-bezier(0.4,0,0.2,1) 1 forwards; }
.cinema-sub-anim   { opacity: 0; animation: cinemaSub 1.6s ease-out 0.4s 1 forwards; }

/* ── Gains du mois (page Jeux) ── */
.jeux-gains-block {
  text-align: center;
  padding: 24px 16px 8px;
}
.jeux-gains-label {
  font-family: var(--font-ui);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--ivoire-dim);
  margin-bottom: 8px;
}
.jeux-gains-amount {
  font-family: var(--font-display);
  font-size: 48px;
  font-weight: 700;
  color: var(--or);
  text-shadow: 0 0 20px rgba(201,168,76,0.4);
  line-height: 1;
}
.jeux-gains-euro {
  font-size: 32px;
  vertical-align: super;
}

/* ── 777 slot machine ── */
@keyframes reelSpin { from { transform: translateY(0); } to { transform: translateY(-468px); } }

.slot-777 {
  display: flex; gap: 10px; justify-content: center;
  padding: 24px 0 16px; position: relative; z-index: 1;
}
.slot-reel {
  width: 52px; height: 52px; overflow: hidden;
  border: 2px solid var(--or-dim); border-radius: 8px;
  background: #0d0d0d; position: relative;
}
.slot-reel::before, .slot-reel::after {
  content: ''; position: absolute; left: 0; right: 0; height: 14px; z-index: 2; pointer-events: none;
}
.slot-reel::before { top: 0;    background: linear-gradient(to bottom, #0d0d0d, transparent); }
.slot-reel::after  { bottom: 0; background: linear-gradient(to top,   #0d0d0d, transparent); }
.slot-strip { display: flex; flex-direction: column; }
.slot-strip span {
  height: 52px; line-height: 52px; text-align: center; display: block;
  font-family: var(--font-display); font-size: 26px; font-weight: 700; color: var(--or);
}
.s1 { animation: reelSpin 1.3s cubic-bezier(0.15,0.9,0.4,1) 0.3s 1 forwards; }
.s2 { animation: reelSpin 1.6s cubic-bezier(0.15,0.9,0.4,1) 0.6s 1 forwards; }
.s3 { animation: reelSpin 1.9s cubic-bezier(0.15,0.9,0.4,1) 0.9s 1 forwards; }


/* ── Transition page publique ── */
@keyframes pageSlideIn {
  from { opacity: 0; transform: translateX(20px); }
  to   { opacity: 1; transform: translateX(0); }
}
.page.page-slide-in {
  animation: pageSlideIn 0.2s ease-out;
}

/* ── Indicateur points + flèches tab bar mobile ── */
.public-tab-dots {
  display: none;
}
@media (max-width: 600px) {
  .public-tab-dots {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 5px 12px 4px;
    background: var(--noir-soft);
    border-bottom: 1px solid var(--gris);
  }
  .public-tab-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--gris-light);
    transition: all 0.25s ease;
  }
  .public-tab-dot.active {
    background: var(--or);
    width: 18px;
    border-radius: 3px;
  }
  .tab-nav-arrow {
    font-size: 18px;
    font-weight: 700;
    color: var(--or);
    line-height: 1;
    transition: visibility 0.15s;
    user-select: none;
  }
}
