*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Apple Color Emoji', 'Segoe UI Emoji', sans-serif;
  background: #f0f4f8; height: 100dvh; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  touch-action: manipulation;
}

/* ── Login ── */
#login-screen {
  display: flex; flex-direction: column; justify-content: space-between;
  width: min(520px, 100%); height: 100dvh;
  padding: max(56px, calc(env(safe-area-inset-top, 0px) + 40px)) 28px max(40px, calc(env(safe-area-inset-bottom, 0px) + 24px));
  background: white;
}
#ooviz-screen, #reset-screen {
  background: white; border-radius: 16px; padding: 40px; width: 360px;
  box-shadow: 0 8px 32px rgba(0,0,0,.12);
}
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; font-weight: 600; color: #374151; margin-bottom: 6px; }
.field input {
  width: 100%; padding: 10px 14px; border: 1.5px solid #e2e8f0;
  border-radius: 8px; font-size: 14px; outline: none; transition: border .2s;
}
.field input:focus { border-color: #6366f1; }
.ls-inp {
  width: 100%; padding: 14px 16px; border: 1px solid #e5e7eb; border-radius: 12px;
  font-size: 15px; font-family: inherit; outline: none; transition: border .2s;
  -webkit-appearance: none;
}
.ls-inp:focus { border-color: #111; }
.ls-btn-social {
  width: 100%; padding: 13px 16px; background: white; color: #111;
  border: 1px solid #e5e7eb; border-radius: 12px; font-size: 14px; font-weight: 600;
  cursor: pointer; font-family: inherit; display: flex; align-items: center;
  justify-content: center; gap: 8px; transition: background .15s;
}
.ls-btn-social:active { background: #f9fafb; }
#login-btn {
  width: 100%; padding: 14px; background: #111; color: white;
  border: none; border-radius: 12px; font-size: 15px; font-weight: 600;
  cursor: pointer; transition: background .15s; font-family: inherit;
}
#login-btn:hover { background: #333; }
#login-btn:active { background: #000; }
#login-error { color: #dc2626; font-size: 13px; margin-top: 12px; text-align: center; }

/* ── App ── */
#app { display: none; width: min(520px, 100%); height: 100%; flex-direction: column; overflow: hidden; }
.card { background: white; border-radius: 16px; box-shadow: 0 4px 24px rgba(0,0,0,.08); overflow: hidden; display: flex; flex-direction: column; flex: 1; min-height: 0; }

/* ── Logo ── */
.logo { display:inline-flex; align-items:center; gap:8px; text-decoration:none; cursor:pointer; border:none; background:none; padding:0; flex-shrink:0; }
.logo-word { font:800 18px/1 -apple-system,system-ui,sans-serif; letter-spacing:-.02em; color:#111; }
.logo-dot { color:#22c55e; }

/* ── Top bar ── */
.topbar {
  display: flex; align-items: center;
  padding: max(8px, calc(8px + env(safe-area-inset-top, 0px))) 16px 8px;
  border-bottom: 1px solid #f1f5f9; flex-shrink: 0;
  position: relative; z-index: 201;
}
.topbar-row1 { display: flex; align-items: center; justify-content: space-between; width: 100%; gap: 8px; position: relative; }
.topbar-actions { display: flex; gap: 12px; align-items: center; flex-shrink: 0; }
.topbar-icon-btn { background:none; border:none; cursor:pointer; color:#6b7280; display:flex; align-items:center; justify-content:center; width:32px; height:32px; border-radius:8px; font-size:18px; transition:all .15s; flex-shrink:0; }
.topbar-icon-btn:hover { background:#f1f5f9; color:#111; }
.btn-sm {
  background: none; border: 1.5px solid #e2e8f0; border-radius: 7px;
  padding: 5px 11px; cursor: pointer; font-size: 12px; color: #64748b; transition: all .15s;
}
.btn-sm:hover { background: #f8fafc; color: #1e293b; }
.btn-sm.active { background: #eef2ff; border-color: #6366f1; color: #6366f1; }
#logout-btn { font-size: 12px; color: #94a3b8; border: none; background: none; cursor: pointer; padding: 5px; }
#logout-btn:hover { color: #dc2626; }

/* ── Tabs ── */
.tabs { display: flex; width: 100%; padding: 6px 12px 6px; align-items: center; gap: 6px; overflow-x: auto; scrollbar-width: none; background: #fafafa; border-bottom: 1px solid #f1f5f9; }
.tabs::-webkit-scrollbar { display: none; }
.tabs-middle { display: flex; flex: 1; gap: 6px; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.tabs-middle::-webkit-scrollbar { display: none; }
.tab {
  padding: 5px 12px; font-size: 12px; font-weight: 600; border-radius: 20px;
  cursor: pointer; border: 1.5px solid #e2e8f0; background: white; color: #64748b;
  white-space: nowrap; transition: all .15s; flex-shrink: 0;
  display: flex; align-items: center; gap: 5px;
}
.tab:hover { border-color: #cbd5e1; color: #374151; }
.tab.active { background: #111; border-color: #111; color: white; }
.tab.active .dot { background: rgba(255,255,255,.7) !important; }
.tab .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--tab-color, #94a3b8); flex-shrink: 0; }
.tab .tab-count { font-size: 10px; font-weight: 700; opacity: .7; }

/* ── Navigation ── */
.nav {
  display: inline-flex; align-items: center; gap: 1px; flex-shrink: 0;
  position: absolute; left: 50%; transform: translateX(-50%); z-index: 1;
}
.nav-month { font-size: 17px; font-weight: 700; color: #111; text-transform: capitalize; white-space: nowrap; }
.nav-btn {
  background: none; border: none; border-radius: 6px;
  width: 26px; height: 26px; cursor: pointer; font-size: 17px; color: #9ca3af; transition: all .15s;
  display: flex; align-items: center; justify-content: center; line-height: 1; padding: 0;
}
.nav-btn:hover { background: #f1f5f9; color: #374151; }

/* ── Export mode ── */
.exporting .nav-btn { opacity: 0; pointer-events: none; }
.exporting .view-toggle { display: none !important; }
.exporting .day { box-shadow: none !important; }
.exporting .ical-events-row { display: none !important; }

/* ── Calendar ── */
#calendar-wrap { padding: 0 0 4px; flex: 1; display: flex; flex-direction: column; overflow: visible; min-height: 350px; }
.day-headers { display: grid; grid-template-columns: repeat(7, 1fr); gap: 1px; margin-bottom: 0; flex-shrink: 0; background: #f1f5f9; border-bottom: 1px solid #f1f5f9; }
.day-header { text-align: center; font-size: 10px; font-weight: 600; color: #9ca3af; padding: 6px 0; text-transform: uppercase; letter-spacing: .05em; background: #fafafa; }
.calendar-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 1px; flex: 1; min-height: 0; grid-auto-rows: minmax(60px, 1fr); background: #f1f5f9; }

.day {
  border-radius: 0; overflow: hidden;
  display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-start;
  gap: 1px; padding: 4px 3px 2px;
  font-size: 13px; font-weight: 500; cursor: pointer;
  transition: none; position: relative; user-select: none;
  line-height: 1; min-height: 60px; background: #fff;
}
.day:active { opacity: .7; }
.day.other-month { opacity: .35; cursor: default; pointer-events: none; }
.day.today { box-shadow: none; }
.day.selected { box-shadow: inset 0 0 0 2px #6366f1; }
.day.selected::before {
  content: '✓'; position: absolute; top: 2px; right: 3px;
  font-size: 8px; color: #6366f1; font-weight: 800; line-height: 1;
}

.view-global .day { background:#fff; }
.view-global .day:hover { background:#f8fafc; }
.view-global .day.selected { box-shadow: 0 0 0 2px #6366f1 inset; }

.view-emp .day { background:#fff; padding:4px 4px 0; }
.view-emp .day:hover { background:#f8fafc; }
.view-emp .day.selected { box-shadow: 0 0 0 2px #6366f1 inset; }

.day-time { font-size: 9px; color: #64748b; line-height: 1; white-space: nowrap; overflow: hidden; max-width: 100%; }
.day.loading { opacity: .5; pointer-events: none; }
.event-chip.clip-src { outline: 1.5px solid rgba(255,255,255,.9); outline-offset: 1px; box-shadow: 0 1px 6px rgba(0,0,0,.35); filter: brightness(1.15); position: relative; z-index: 2; }

/* Mission / booking styles — global view uses chips, not bg color */
.day-mission { font-size: 8px; color: #374151; line-height: 1.2; width: 100%; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; font-weight: 600; word-break: break-word; }
.ical-events-row { display:flex; gap:2px; flex-wrap:wrap; padding:1px 0; width:100%; }
.ical-event-chip { display:flex; align-items:center; gap:2px; padding:1px 4px 1px 2px; border-radius:3px; font-size:8px; font-weight:700; line-height:1.4; max-width:100%; overflow:hidden; white-space:nowrap; text-overflow:ellipsis; }
.ical-event-chip-dot { width:5px; height:5px; border-radius:50%; flex-shrink:0; }
.ical-event-more { font-size:7px; color:#94a3b8; font-weight:700; line-height:1; align-self:center; padding:1px 3px; }
/* Emp view — white cells, color via day-num and bottom bar */
.view-emp .day.neutral .day-num { color:#9ca3af; }
.view-emp .day.indispo .day-num { color:#ef4444; }
.view-emp .day.dispo .day-num, .view-emp .day.booked-emp .day-num, .view-emp .day.booked-ooviz .day-num { color:var(--emp-color,#22c55e); }
.view-emp .day.dispo:not(.other-month) { background: rgba(34,197,94,0.75); }


/* ── Legend — hidden from main chrome ── */
.legend { display: none !important; }
.legend-item { display: flex; align-items: center; gap: 5px; font-size: 12px; color: #64748b; }
.ldot { width: 10px; height: 10px; border-radius: 3px; }

/* ── Status — compact sync indicator ── */
#status { font-size: 11px; text-align: center; padding: 1px 6px; color: #94a3b8; transition: color .3s; flex-shrink: 0; }
#status.ok { color: #16a34a; }
#status.error { color: #dc2626; }
#status.syncing { color: #f59e0b; }

/* ── Export bar — hidden from chrome (accessible via menu) ── */
.export-bar { padding: 10px 16px 18px; display: none !important; gap: 8px; flex-shrink: 0; }
.btn-export { flex: 1; padding: 10px; border: none; border-radius: 9px; font-size: 13px; font-weight: 600; cursor: pointer; transition: all .15s; }
.btn-export.main { background: #1e293b; color: white; }
.btn-export.main:hover { background: #0f172a; }
/* ── Copyright strip — hidden ── */
.copyright-strip { display: none !important; }

.action-bar { padding: 10px 16px 18px; display: flex; flex-direction: column; gap: 8px; flex-shrink: 0; }
.action-bar-info { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 6px; }
.sel-count { font-size: 13px; font-weight: 600; color: #6366f1; }
.action-time-row { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.action-btns { display: flex; gap: 6px; }
.btn-action {
  flex: 1; padding: 9px 8px; border: none; border-radius: 9px;
  font-size: 12px; font-weight: 700; cursor: pointer; transition: all .15s;
}
.btn-action.indispo  { background: var(--color-indispo,#dc2626); color: white; }
.btn-action.indispo:hover { background: color-mix(in srgb,var(--color-indispo,#dc2626) 85%,black); }
.btn-action.dispo    { background: var(--emp-color, #16a34a); color: white; }
.btn-action.delete   { background: #f1f5f9; color: #64748b; }
.btn-action.delete:hover { background: #fee2e2; color: #dc2626; }
.btn-action.cancel   { background: none; border: 1.5px solid #e2e8f0; color: #64748b; }
.btn-action.cancel:hover { background: #f8fafc; }

/* ── Modal overlay ── */
.modal-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 100; align-items: center; justify-content: center; }
.modal-overlay.open { display: flex; }
.modal { background: white; border-radius: 16px; padding: 28px; width: 380px; max-height: 90vh; overflow-y: auto; overflow-x: hidden; box-shadow: 0 20px 60px rgba(0,0,0,.2); }
.modal-handle { display: none; }
.modal h3 { font-size: 16px; color: #1e293b; margin-bottom: 20px; }
.modal-close { float: right; background: none; border: none; font-size: 20px; cursor: pointer; color: #94a3b8; margin-top: -4px; }
.modal-close:hover { color: #1e293b; }

/* Day modal */
.day-row { display: flex; align-items: center; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid #f1f5f9; }
.day-row-label { display: flex; align-items: center; gap: 8px; font-size: 14px; color: #374151; font-weight: 500; }
.emp-dot { width: 10px; height: 10px; border-radius: 50%; }
.toggle-group { display: flex; gap: 4px; }
.toggle-btn { padding: 5px 12px; border-radius: 6px; font-size: 12px; font-weight: 600; border: 1.5px solid #e2e8f0; background: #f8fafc; color: #64748b; cursor: pointer; transition: all .15s; }
.toggle-btn.active-dispo    { background: #dcfce7; border-color: #16a34a; color: #16a34a; }
.toggle-btn.active-indispo  { background: #fee2e2; border-color: #dc2626; color: #dc2626; }
.toggle-btn.active-neutral  { background: #f1f5f9; border-color: #94a3b8; color: #64748b; }

/* Time controls */
.time-row { padding: 6px 0 10px 26px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; border-bottom: 1px solid #f1f5f9; }
.time-tab { padding: 4px 10px; border-radius: 5px; font-size: 11px; font-weight: 600; border: 1.5px solid #e2e8f0; background: #f8fafc; color: #64748b; cursor: pointer; transition: all .15s; }
.time-tab.active { border-color: #dc2626; color: #dc2626; background: #fee2e2; }
.time-input { padding: 3px 7px; border: 1.5px solid #e2e8f0; border-radius: 6px; font-size: 12px; color: #374151; width: 80px; outline: none; }
.time-input:focus { border-color: #6366f1; }
.time-sep { font-size: 12px; color: #94a3b8; }

/* Valider button */
.btn-valider { width: 100%; padding: 11px; background: #6366f1; color: white; border: none; border-radius: 9px; font-size: 14px; font-weight: 600; cursor: pointer; transition: background .2s; }
.btn-valider:hover { background: #4f46e5; }
.btn-valider:disabled { background: #a5b4fc; cursor: not-allowed; }
.btn-reset { width: 100%; padding: 9px; background: none; color: #94a3b8; border: 1.5px solid #e2e8f0; border-radius: 9px; font-size: 13px; font-weight: 600; cursor: pointer; margin-top: 6px; transition: all .2s; }
.btn-reset:hover { background: #fee2e2; color: #dc2626; border-color: #fca5a5; }
.modal-footer { position: sticky; bottom: 0; background: white; padding-top: 10px; margin-top: 10px; box-shadow: 0 -8px 12px white; }
.preset-bar { display:flex; flex-wrap:wrap; gap:5px; padding-bottom:10px; margin-bottom:8px; border-bottom:1px solid #f1f5f9; align-items:center; }
.preset-save { padding:3px 10px; border-radius:20px; font-size:11px; font-weight:700; border:1.5px dashed #6366f1; background:#fff; color:#6366f1; cursor:pointer; letter-spacing:.3px; white-space:nowrap; }
.preset-save:hover { background:#eef2ff; }
.preset-pill { display:flex; align-items:center; gap:4px; padding:3px 6px 3px 10px; border-radius:20px; background:#f1f5f9; border:1.5px solid #e2e8f0; font-size:12px; color:#374151; cursor:pointer; transition:background .15s; white-space:nowrap; }
.preset-pill:hover { background:#e2e8f0; }
.preset-pill-del { color:#94a3b8; font-size:15px; line-height:1; cursor:pointer; padding:0 2px; border:none; background:none; }
.preset-pill-del:hover { color:#ef4444; }

/* Employer management modal */
.emp-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 20px; }
.emp-item { display: flex; align-items: flex-start; flex-wrap: wrap; padding: 10px 12px; border: 1.5px solid #e2e8f0; border-radius: 10px; gap: 0; }
.emp-item-row { display: flex; align-items: center; gap: 10px; width: 100%; }
.emp-color-dot { width: 14px; height: 14px; border-radius: 50%; flex-shrink: 0; }
.emp-item-name { flex: 1; font-size: 14px; color: #1e293b; font-weight: 500; }
.emp-item-channel { font-size: 11px; color: #94a3b8; background: #f1f5f9; padding: 2px 7px; border-radius: 4px; }
.emp-delete { background: none; border: none; color: #e2e8f0; cursor: pointer; font-size: 16px; transition: color .15s; }
.emp-delete:hover { color: #dc2626; }
.emp-drag-handle { width:20px; color:#d1d5db; cursor:grab; display:flex; align-items:center; justify-content:center; flex-shrink:0; touch-action:none; user-select:none; }
.emp-drag-handle:active { cursor:grabbing; color:#94a3b8; }
.emp-item.is-dragging { opacity:0.35; }
.emp-item.drop-above { border-top:2px solid #6366f1 !important; }
.emp-item.drop-below { border-bottom:2px solid #6366f1 !important; }
.emp-gmail-fields { width: 100%; display: flex; flex-direction: column; gap: 6px; margin-top: 8px; padding-top: 8px; border-top: 1px solid #f1f5f9; }
.emp-gmail-fields label { font-size: 10px; font-weight: 600; color: #94a3b8; text-transform: uppercase; letter-spacing: .5px; }
.add-emp-form { display: flex; flex-direction: column; gap: 10px; padding-top: 16px; border-top: 1px solid #f1f5f9; }
.add-emp-form h4 { font-size: 13px; font-weight: 700; color: #475569; }
/* Config sections */
.cfg-section { padding:16px 0 10px; border-top:1px solid #f1f5f9; }
.cfg-section:first-child { border-top:none; padding-top:0; }
.cfg-section-title { font-size:11px; font-weight:700; color:#94a3b8; text-transform:uppercase; letter-spacing:.6px; margin-bottom:12px; }
.cfg-avatar { width:48px; height:48px; border-radius:50%; background:#6366f1; color:white; font-size:18px; font-weight:800; display:flex; align-items:center; justify-content:center; flex-shrink:0; }
.cfg-row { display:flex; align-items:center; justify-content:space-between; gap:10px; padding:4px 0; }
.cfg-row-lbl { font-size:13px; color:#374151; flex:1; }
.cfg-row-sub { font-size:11px; color:#94a3b8; margin-top:1px; }
.cfg-radio-grp { display:flex; gap:6px; flex-wrap:wrap; }
.cfg-radio-btn { padding:4px 12px; border-radius:20px; font-size:12px; font-weight:600; cursor:pointer; border:1.5px solid; transition:all .12s; }
.cfg-radio-btn.on { border-color:#6366f1; background:#eef2ff; color:#4338ca; }
.cfg-radio-btn.off { border-color:#e2e8f0; background:white; color:#64748b; }
.cfg-inp { width:100%; border:1.5px solid #e2e8f0; border-radius:8px; padding:8px 10px; font-size:13px; background:white; box-sizing:border-box; }
.cfg-inp:focus { border-color:#6366f1; outline:none; }
.cfg-select { border:1.5px solid #e2e8f0; border-radius:8px; padding:7px 10px; font-size:12px; background:white; color:#374151; width:100%; }
.danger-zone-btn { width:100%; padding:10px; border:1.5px solid #fca5a5; border-radius:9px; background:white; color:#dc2626; font-size:12px; font-weight:600; cursor:pointer; text-align:left; }
input, textarea, select, [contenteditable] { -webkit-user-select: text !important; user-select: text !important; }
.inp { width: 100%; padding: 8px 12px; border: 1.5px solid #e2e8f0; border-radius: 8px; font-size: 13px; outline: none; }
.inp:focus { border-color: #6366f1; }
.inp-sm { width: 100%; padding: 5px 9px; border: 1.5px solid #e2e8f0; border-radius: 7px; font-size: 12px; outline: none; color: #374151; }
.inp-sm:focus { border-color: #6366f1; }
.inp-sm::placeholder { color: #94a3b8; }
.color-picker { display: flex; gap: 6px; flex-wrap: wrap; }
.color-swatch { width: 24px; height: 24px; border-radius: 50%; cursor: pointer; border: 2px solid transparent; transition: all .15s; }
.color-swatch.selected { border-color: #1e293b; transform: scale(1.15); }
.channel-select { display: flex; gap: 6px; }
.channel-btn { flex: 1; padding: 7px; border: 1.5px solid #e2e8f0; border-radius: 7px; font-size: 12px; font-weight: 600; color: #64748b; background: #f8fafc; cursor: pointer; transition: all .15s; text-align: center; }
.channel-btn.active { border-color: #6366f1; color: #6366f1; background: #eef2ff; }
#gmail-fields { display: none; flex-direction: column; gap: 6px; }
#gmail-fields label { font-size: 11px; font-weight: 600; color: #475569; }
.btn-add-emp { width: 100%; padding: 10px; background: #6366f1; color: white; border: none; border-radius: 8px; font-size: 14px; font-weight: 600; cursor: pointer; }
.btn-add-emp:hover { background: #4f46e5; }
.btn-fermer { width: 100%; padding: 10px; background: #f1f5f9; color: #475569; border: none; border-radius: 8px; font-size: 14px; font-weight: 600; cursor: pointer; margin-top: 4px; }
.btn-fermer:hover { background: #e2e8f0; }

/* ── Modèles view ── */
#modeles-view { display:none; padding:0 14px 20px; overflow-y:auto; flex: 1; min-height: 0; }
#modeles-view.active { display:block; }
#settings-view { display:none; padding:0 16px 24px; overflow-y:auto; flex: 1; min-height: 0; }
#settings-view.active { display:block; }
#config-view { display:none; padding:0 16px 24px; overflow-y:auto; overflow-x:hidden; flex: 1; min-height: 0; }
#config-view.active { display:block; }
.modeles-header { display:flex; align-items:center; justify-content:space-between; padding:12px 0 10px; }
.modeles-header h3 { font-size:15px; font-weight:700; color:#1e293b; }
/* Presets V2 cards */
.preset-help-banner { background:#eff6ff; border-left:3px solid #3b82f6; border-radius:6px; padding:10px 12px; margin-bottom:16px; font-size:12px; color:#1d4ed8; line-height:1.6; }
.preset-group-hdr { display:flex; align-items:center; gap:7px; padding:12px 4px 8px; }
.preset-group-dot { width:10px; height:10px; border-radius:50%; flex-shrink:0; }
.preset-group-name { font-size:13px; font-weight:700; color:#1e293b; }
.preset-group-badge { font-size:10px; background:#f1f5f9; color:#64748b; border-radius:10px; padding:1px 7px; }
.preset-add-link { margin-left:auto; font-size:12px; font-weight:600; color:#6366f1; cursor:pointer; background:none; border:none; padding:2px 0; }
.preset-add-link:hover { text-decoration:underline; }
.preset-card { background:white; border:1px solid #e2e8f0; border-radius:10px; padding:11px 13px; margin-bottom:8px; }
.preset-card-l1 { display:flex; align-items:center; gap:8px; margin-bottom:6px; }
.preset-card-name { flex:1; min-width:0; font-size:13px; font-weight:700; border:none; background:transparent; color:#1e293b; padding:0; outline:none; }
.preset-card-name:hover,.preset-card-name:focus { border-bottom:1.5px solid #6366f1; }
.preset-badge-contract { font-size:10px; font-weight:700; border-radius:8px; padding:2px 9px; cursor:pointer; border:none; white-space:nowrap; flex-shrink:0; }
.preset-badge-inter { background:#eff6ff; color:#2563eb; }
.preset-badge-soc { background:#f0fdf4; color:#16a34a; }
.preset-card-del { background:none; border:none; color:#cbd5e1; cursor:pointer; font-size:16px; line-height:1; padding:0 2px; flex-shrink:0; }
.preset-card-del:hover { color:#ef4444; }
.preset-card-l2 { display:flex; align-items:center; gap:5px; font-size:12px; color:#64748b; flex-wrap:wrap; margin-bottom:7px; min-height:20px; }
.preset-card-sep { color:#e2e8f0; }
.preset-card-tarif-h { color:#6366f1; font-weight:700; }
.preset-card-l3 { display:flex; align-items:center; gap:6px; font-size:11px; flex-wrap:wrap; }
.preset-indispo-lbl { color:#94a3b8; white-space:nowrap; }
.preset-indispo-btn { padding:2px 9px; border-radius:5px; font-size:11px; font-weight:600; cursor:pointer; border:1.5px solid; transition:all .12s; }
.preset-indispo-btn.active { border-color:#6366f1; background:#eef2ff; color:#4338ca; }
.preset-indispo-btn.inactive { border-color:#e2e8f0; background:white; color:#64748b; }
.preset-lunch-pill { display:inline-flex; align-items:center; gap:3px; padding:2px 8px; border-radius:10px; font-size:11px; cursor:pointer; border:1px solid; transition:all .12s; }
.preset-lunch-pill.on { background:#fef9c3; border-color:#fde047; color:#78350f; }
.preset-lunch-pill.off { background:#f8fafc; border-color:#e2e8f0; color:#94a3b8; text-decoration:line-through; }
.preset-time-edit { cursor:pointer; border-bottom:1px dashed #cbd5e1; padding-bottom:1px; }
.preset-time-edit:hover { border-bottom-color:#6366f1; color:#1e293b; }
.preset-inline-edit { display:flex; align-items:center; gap:4px; flex-wrap:wrap; margin-top:3px; }
.preset-inline-edit input[type=time] { border:1.5px solid #e2e8f0; border-radius:5px; padding:3px 4px; font-size:11px; width:74px; background:white; }
.preset-inline-edit input[type=number] { border:1.5px solid #e2e8f0; border-radius:5px; padding:3px 5px; font-size:11px; width:58px; background:white; }
.preset-inline-edit input:focus { border-color:#6366f1; outline:none; }
.preset-maj-hdr { display:flex; align-items:center; justify-content:space-between; margin-top:6px; padding-top:6px; border-top:1px solid #f1f5f9; }
.preset-maj-toggle { font-size:11px; color:#6366f1; cursor:pointer; font-weight:600; background:none; border:none; padding:0; font-family:inherit; text-align:left; }
.preset-maj-body { flex-direction:column; gap:5px; margin-top:5px; }
.preset-maj-row { display:flex; align-items:center; gap:5px; flex-wrap:wrap; }
.preset-maj-lbl { font-size:11px; color:#475569; font-weight:600; width:68px; flex-shrink:0; }
.preset-maj-inp { border:1.5px solid #e2e8f0; border-radius:5px; padding:2px 4px; font-size:11px; background:white; font-family:inherit; }
.preset-maj-inp:focus { border-color:#6366f1; outline:none; }
.preset-maj-inp:disabled { background:#f8fafc; color:#cbd5e1; }
.preset-maj-inp.time { width:66px; }
.preset-maj-inp.pct { width:44px; }
.recap-maj-badge { font-size:9px; background:#fef3c7; color:#92400e; border-radius:3px; padding:1px 5px; font-weight:700; margin-left:4px; vertical-align:middle; }
.preset-allday-toggle { padding:2px 8px; border-radius:5px; font-size:11px; font-weight:600; cursor:pointer; border:1.5px solid; transition:all .12s; }
/* Legacy preset-row kept for compat */
.preset-row { display:flex; flex-direction:column; gap:5px; padding:8px 10px; border-radius:9px; background:#f8fafc; border:1.5px solid #e2e8f0; margin-bottom:6px; }
.preset-row-top { display:flex; align-items:center; gap:6px; }
.preset-row-bottom { display:flex; align-items:center; gap:6px; flex-wrap:wrap; padding-left:20px; }
.preset-row-dot { width:8px; height:8px; border-radius:50%; flex-shrink:0; }
.preset-group-label { font-size:10px; font-weight:700; color:#94a3b8; text-transform:uppercase; letter-spacing:.8px; padding:10px 0 4px; }
.btn-add-preset { width:100%; padding:9px; border:1.5px dashed #6366f1; background:#fafafe; color:#6366f1; border-radius:9px; font-size:13px; font-weight:600; cursor:pointer; margin-top:4px; }
.btn-add-preset:hover { background:#eef2ff; }

/* Export popup */
#export-modal-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.7); z-index: 200; align-items: center; justify-content: center; flex-direction: column; gap: 16px; }
#export-modal-overlay.open { display: flex; }
#export-modal-img { max-width: 90vw; max-height: 75vh; border-radius: 12px; box-shadow: 0 20px 60px rgba(0,0,0,.4); }
.export-modal-actions { display: flex; gap: 12px; }
.btn-export-action { padding: 10px 22px; border-radius: 9px; font-size: 14px; font-weight: 600; cursor: pointer; border: none; transition: all .15s; }
.btn-export-action.dl { background: #1e293b; color: white; }
.btn-export-action.dl:hover { background: #0f172a; }
.btn-export-action.close { background: white; color: #475569; }
.btn-export-action.close:hover { background: #f1f5f9; }

/* Récap mensuel */
#recap-modal-overlay { display:none; position:fixed; inset:0; background:rgba(0,0,0,.6); z-index:200; align-items:flex-end; justify-content:center; }
#recap-modal-overlay.open { display:flex; }
#recap-modal { background:white; border-radius:20px 20px 0 0; width:100%; max-width:520px; padding:16px 18px 36px; max-height:90svh; overflow-y:auto; }
.recap-header { display:flex; align-items:center; justify-content:space-between; margin-bottom:14px; }
.recap-header h3 { font-size:15px; font-weight:700; color:#1e293b; }
.recap-close { background:none; border:none; font-size:20px; color:#94a3b8; cursor:pointer; line-height:1; }
.recap-emp-dot { display:inline-block; width:8px; height:8px; border-radius:50%; flex-shrink:0; }
.recap-item { padding:8px 0; border-bottom:1px solid #f1f5f9; }
.recap-item:last-child { border-bottom:none; }
.recap-item-top { display:flex; justify-content:space-between; align-items:center; margin-bottom:3px; }
.recap-item-emp { display:flex; align-items:center; gap:5px; font-size:13px; font-weight:600; color:#1e293b; flex:1; min-width:0; }
.recap-item-emp-name { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.recap-item-date { font-size:11px; color:#94a3b8; white-space:nowrap; flex-shrink:0; margin-left:8px; }
.recap-item-bot { display:flex; justify-content:space-between; align-items:center; }
.recap-item-time { font-size:11px; color:#94a3b8; }
.recap-item-nums { display:flex; gap:10px; align-items:center; flex-shrink:0; }
.recap-item-dur { font-size:12px; font-weight:600; color:#374151; }
.recap-item-tarif { font-size:11px; color:#6366f1; }
.recap-item-total { font-size:12px; font-weight:700; color:#059669; }
.recap-footer { margin-top:12px; padding:10px 12px; background:#f8fafc; border-radius:9px; display:flex; gap:16px; font-size:12px; }
.recap-footer strong { color:#1e293b; }
.recap-footer span { color:#64748b; }
.btn-recap-csv { margin-top:12px; width:100%; padding:10px; background:#1e293b; color:white; border:none; border-radius:9px; font-size:13px; font-weight:600; cursor:pointer; }
.btn-recap-csv:hover { background:#0f172a; }
.recap-empty { text-align:center; color:#94a3b8; font-size:13px; padding:24px 0; }
.recap-section-hdr { font-size:10px; font-weight:800; color:#7c3aed; text-transform:uppercase; letter-spacing:.06em; padding:14px 0 6px; border-top:1px solid #f1f5f9; margin-top:4px; }
.recap-section-hdr:first-child { border-top:none; padding-top:0; }

/* ── Analyse view ─────────────────────────────────────────────────────────── */
#analyse-view { display:none; padding:0 16px 24px; overflow-y:auto; flex:1; min-height:0; }
#analyse-view.active { display:block; }
#aide-view { display:none; flex-direction:column; flex:1; min-height:0; overflow:hidden; }
#aide-view.active { display:flex; }
.aide-chat { flex:1; overflow-y:auto; padding:16px 16px 8px; display:flex; flex-direction:column; gap:10px; }
.aide-msg { display:flex; flex-direction:column; }
.aide-msg-user { align-items:flex-end; }
.aide-msg-bot { align-items:flex-start; }
.aide-bubble { max-width:82%; padding:10px 14px; font-size:13px; line-height:1.55; }
.aide-bubble-user { background:#1e293b; color:white; border-radius:16px 16px 4px 16px; }
.aide-bubble-bot { background:#f1f5f9; color:#374151; border-radius:16px 16px 16px 4px; }
.aide-chips { padding:10px 14px 20px; display:flex; flex-direction:column; gap:7px; border-top:1px solid #f1f5f9; flex-shrink:0; }
.aide-chip { background:white; border:1.5px solid #e2e8f0; border-radius:10px; padding:10px 14px; font-size:13px; font-weight:500; color:#374151; cursor:pointer; text-align:left; font-family:inherit; transition:border-color .12s,background .12s; }
.aide-chip:hover { border-color:#1e293b; background:#f8fafc; }
.aide-chip-reset { font-size:12px; color:#94a3b8; background:none; border:none; padding:4px 0; cursor:pointer; font-family:inherit; text-decoration:underline; text-align:left; margin-top:2px; }
.analyse-year-nav { display:flex; align-items:center; justify-content:space-between; padding:14px 0 6px; }
.analyse-year-label { font-size:20px; font-weight:800; color:#1e293b; }
.analyse-year-btn { background:none; border:1.5px solid #e2e8f0; border-radius:8px; width:34px; height:34px; cursor:pointer; font-size:17px; color:#64748b; transition:all .15s; }
.analyse-year-btn:hover { background:#f8fafc; }
.analyse-summary { background:#f8fafc; border-radius:12px; padding:14px 16px; margin:8px 0 16px; display:flex; flex-wrap:wrap; gap:20px; }
.analyse-summary-item { display:flex; flex-direction:column; gap:3px; }
.analyse-summary-num { font-size:24px; font-weight:800; color:#1e293b; line-height:1; }
.analyse-summary-lbl { font-size:10px; font-weight:700; color:#94a3b8; text-transform:uppercase; letter-spacing:.5px; }
.analyse-section-label { font-size:10px; font-weight:800; color:#94a3b8; text-transform:uppercase; letter-spacing:.8px; padding:16px 0 8px; border-top:1px solid #f1f5f9; margin-top:4px; }
.analyse-section-label:first-of-type { border-top:none; }
.analyse-table { width:100%; border-collapse:collapse; font-size:13px; margin-bottom:4px; }
.analyse-table th { font-size:10px; font-weight:700; color:#94a3b8; text-transform:uppercase; letter-spacing:.5px; padding:5px 6px; border-bottom:2px solid #f1f5f9; text-align:left; }
.analyse-table td { padding:8px 6px; border-bottom:1px solid #f8fafc; vertical-align:middle; }
.analyse-table tr:last-child td { border-bottom:none; }
.analyse-bar-wrap { width:60px; }
.analyse-bar-bg { height:5px; background:#e2e8f0; border-radius:3px; overflow:hidden; }
.analyse-bar-fill { height:100%; border-radius:3px; background:#6366f1; }
.analyse-emp-row { display:flex; align-items:center; gap:8px; padding:8px 0; border-bottom:1px solid #f8fafc; }
.analyse-emp-bar { flex:1; height:7px; background:#e2e8f0; border-radius:4px; overflow:hidden; }
.analyse-emp-bar-fill { height:100%; border-radius:4px; }
/* Analyse V2 */
.an-seg-ctrl { display:flex; background:#f1f5f9; border-radius:10px; padding:3px; gap:2px; margin:8px 0; }
.an-seg-btn { flex:1; padding:5px; border:none; border-radius:7px; font-size:12px; font-weight:600; cursor:pointer; transition:all .12s; }
.an-seg-btn.active { background:white; color:#1e293b; box-shadow:0 1px 3px rgba(0,0,0,.1); }
.an-seg-btn.inactive { background:transparent; color:#64748b; }
.an-period-tabs { display:flex; gap:0; margin-bottom:12px; border:1.5px solid #e2e8f0; border-radius:8px; overflow:hidden; }
.an-period-tab { flex:1; padding:5px; border:none; background:white; font-size:11px; font-weight:600; cursor:pointer; color:#64748b; transition:all .12s; }
.an-period-tab.active { background:#eef2ff; color:#4338ca; }
.an-kpi-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:8px; margin:12px 0; }
.an-kpi-card { background:#f8fafc; border-radius:10px; padding:10px 12px; }
.an-kpi-num { font-size:20px; font-weight:800; color:#1e293b; line-height:1.1; }
.an-kpi-lbl { font-size:10px; font-weight:700; color:#94a3b8; text-transform:uppercase; letter-spacing:.4px; margin-top:3px; }
.an-threshold-bar-wrap { margin:12px 0 4px; }
.an-threshold-bar-bg { height:8px; background:#e2e8f0; border-radius:4px; overflow:visible; position:relative; }
.an-threshold-bar-fill { height:100%; border-radius:4px; position:relative; }
.an-threshold-marker { position:absolute; top:-3px; bottom:-3px; width:2px; background:#ef4444; border-radius:1px; }
.an-alert-banner { background:#fef2f2; border-left:3px solid #ef4444; border-radius:6px; padding:9px 11px; font-size:12px; color:#dc2626; margin:8px 0; }
.an-info-banner { background:#eff6ff; border-left:3px solid #3b82f6; border-radius:6px; padding:9px 11px; font-size:12px; color:#1d4ed8; margin:8px 0; }

/* ── Responsive mobile ────────────────────────────────────────────────────── */
@media (max-width: 560px) {
  body { align-items: flex-start; padding: 0; background: #fff; }
  #ooviz-screen { width: calc(100% - 32px); margin: 32px auto; padding: 28px 20px; }
  #app { width: 100%; }
  .card { border-radius: 0; min-height: 0; box-shadow: none; overflow: visible; }

  /* Topbar */
  .topbar { padding: 7px 10px; }
  .logo-word { font-size: 15px; }
  .topbar-actions { gap: 3px; }
  .btn-sm { padding: 4px 7px; font-size: 11px; }
  #logout-btn { font-size: 11px; padding: 4px; }
  .nav-month { font-size: 15px; }

  /* Calendar */
  #calendar-wrap { padding: 0 0 4px; }
  .day-header { font-size: 9px; padding: 4px 0; }
  .day { font-size: 11px; border-radius: 0; gap: 1px; padding: 3px 2px 1px; }
  .day-mission { font-size: 7px; }
  .day-time { font-size: 7px; }

  /* Legend */
  .legend { padding: 7px 12px; gap: 8px; }
  .legend-item { font-size: 11px; }

  /* Export / action bar */
  .export-bar { padding: 8px 12px 16px; }
  .btn-export { font-size: 12px; padding: 9px; }
  .action-bar { padding: 8px 12px 16px; }
  .btn-action { font-size: 11px; padding: 8px 6px; }

  /* Modal → bottom sheet */
  .modal-overlay { align-items: flex-end !important; padding: 0; }
  .modal-overlay.open { display: flex; }
  .modal {
    width: 100%;
    max-width: 100%;
    border-radius: 20px 20px 0 0;
    padding: 6px 18px 36px;
    max-height: 88svh;
  }
  .modal-handle { display: block; width: 40px; height: 4px; border-radius: 2px; background: #e2e8f0; margin: 6px auto 14px; }
  .modal h3 { font-size: 15px; margin-bottom: 16px; }
  .toggle-btn { padding: 5px 9px; font-size: 11px; }
  .day-row-label { font-size: 13px; gap: 6px; }
  .preset-pill { font-size: 11px; }
}

@media (max-width: 380px) {
  .logo-word { font-size: 15px; }
  #logout-btn { display: none; }
  .toggle-btn { padding: 4px 7px; font-size: 10px; }
}

/* ── Responsive global — tablette & PC ─────────────────────────────────── */
#sidebar {
  display:none; flex-direction:column; width:220px; flex-shrink:0;
  background:white; border-right:1px solid #f1f5f9;
  overflow-y:auto; overflow-x:hidden;
}
.sbar-section { padding:8px 12px 4px; font-size:10px; font-weight:700; color:#9ca3af; text-transform:uppercase; letter-spacing:.06em; }
.sbar-item {
  display:flex; align-items:center; gap:9px; width:100%; padding:8px 10px;
  border:none; background:none; cursor:pointer; font-family:inherit;
  font-size:13px; font-weight:600; color:#374151; border-radius:8px;
  text-align:left; transition:background .12s; border-left:3px solid transparent;
}
.sbar-item:hover { background:#f5f5f7; }
.sbar-item.active { background:#f5f5f7; border-left-color:#111; color:#111; }
.sbar-icon { width:28px; height:28px; border-radius:6px; display:flex; align-items:center; justify-content:center; flex-shrink:0; font-size:14px; }
.sbar-dot { width:9px; height:9px; border-radius:50%; flex-shrink:0; }

@media (min-width: 640px) {
  #app { width: min(760px, 100%); }
}

@media (min-width: 1024px) {
  #app { width: min(1200px, 100%); flex-direction:row; border-radius:16px; box-shadow:0 4px 24px rgba(0,0,0,.08); overflow:hidden; }
  .card { border-radius:0; box-shadow:none; }
  #sidebar { display:flex; }
  #bottom-nav { display:none !important; }
  .logo-menu-btn { pointer-events:none; }
  .logo-menu-btn .logo-bars { display:none; }
}

/* ── Simulateur — responsive tablette / PC ──────────────────────────────── */
#simulateur-view { display:none; overflow-y:auto; flex:1; min-height:0; }
.sim-card { background:white; border:1.5px solid #e2e8f0; border-radius:14px; padding:14px 16px; overflow:hidden; }
.sim-card-left {}
.sim-card-right {}
.sim-inputs-grid { display:grid; grid-template-columns:1fr; gap:8px; margin-bottom:10px; }
@media (min-width:480px) { .sim-inputs-grid { grid-template-columns:1fr 1fr; } }

@media (min-width: 640px) {
  body.sim-active #app { width: min(780px, 100%); }
  #simulateur-view { max-width: none !important; padding: 20px 24px 40px !important; }
  .sim-card { display:flex; padding:0; }
  .sim-card-left { width:300px; flex-shrink:0; padding:20px 20px 20px 24px; border-right:1px solid #f1f5f9; }
  .sim-card-right { flex:1; min-width:0; padding:20px 24px; }
  .sim-desc-tablet { display:block !important; }
}

@media (min-width: 1024px) {
  body.sim-active #app { width: min(1200px, 100%); }
  #simulateur-view { padding: 24px 32px 40px !important; }
  .sim-card-left { width:380px; padding:24px 24px 24px 28px; }
  .sim-card-right { padding:24px 28px; }
}

/* ── Side Menu ───────────────────────────────────────────────────────────── */
#side-overlay {
  display:none; position:fixed; inset:0; background:rgba(0,0,0,.4); z-index:400;
  opacity:0; transition:opacity .25s;
}
#side-overlay.open { display:block; opacity:1; }
/* ── Side menu (drawer) ─────────────────────────────────────────────────── */
#side-menu {
  position:fixed; top:0; left:-82vw; bottom:0; width:82%;
  background:white; z-index:401; overflow-y:auto; overflow-x:hidden;
  box-shadow:4px 0 30px rgba(0,0,0,.15); transition:left .22s ease-out;
  display:flex; flex-direction:column;
}
#side-menu.open { left:0; }
#smenu-head {
  display:flex; align-items:center; justify-content:space-between;
  padding:max(14px,calc(env(safe-area-inset-top,0px) + 14px)) 18px 16px;
  border-bottom:1px solid #f1f5f9; flex-shrink:0;
}
#side-menu-close {
  width:32px; height:32px; border-radius:16px; border:none;
  background:#f5f5f7; display:flex; align-items:center; justify-content:center;
  cursor:pointer; color:#6b7280; font-size:16px; flex-shrink:0; line-height:1;
}
#side-menu-close:hover { background:#e8e8ea; }
#smenu-user-card {
  display:flex; align-items:center; gap:12px; padding:12px 18px;
  border-bottom:1px solid #f1f5f9; flex-shrink:0;
}
#smenu-avatar {
  width:40px; height:40px; border-radius:20px;
  background:linear-gradient(135deg,#ef4444,#a855f7);
  color:#fff; font-size:14px; font-weight:700;
  display:flex; align-items:center; justify-content:center; flex-shrink:0;
}
#smenu-user-name { font-size:14px; font-weight:700; color:#111; }
#smenu-user-email { font-size:11px; color:#6b7280; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
#smenu-plan-pill {
  font-size:9px; font-weight:700; padding:2px 8px; border-radius:4px;
  background:#f3f4f6; color:#6b7280; text-transform:uppercase; letter-spacing:.04em; flex-shrink:0;
}
#smenu-plan-pill.pro { background:#eff6ff; color:#1e40af; }
#smenu-nav { flex:1; overflow-y:auto; padding:8px 0; }
.smenu-item {
  display:flex; align-items:center; gap:12px; padding:10px 18px; width:100%;
  background:transparent; border:none; border-left:3px solid transparent;
  cursor:pointer; font-family:inherit; text-align:left; transition:background .1s;
}
.smenu-item:hover { background:#fafafa; }
.smenu-item.active { background:#f5f5f7; border-left-color:#111; }
.smenu-ic {
  width:32px; height:32px; border-radius:8px;
  display:flex; align-items:center; justify-content:center; flex-shrink:0;
}
.smenu-label { flex:1; font-size:14px; font-weight:500; color:#111; }
.smenu-item.active .smenu-label { font-weight:700; }
.smenu-sublabel { font-size:10px; color:#9ca3af; margin-top:1px; }
.smenu-arrow { color:#d1d5db; font-size:16px; flex-shrink:0; }
#smenu-footer {
  display:flex; align-items:center; justify-content:space-between;
  padding:12px 18px max(12px,calc(env(safe-area-inset-bottom,0px) + 12px));
  border-top:1px solid #f1f5f9; flex-shrink:0;
}
#smenu-logout-btn {
  display:flex; align-items:center; gap:8px; color:#ef4444;
  background:none; border:none; cursor:pointer; font-size:13px; font-weight:700; font-family:inherit;
}
#smenu-version { font-size:9px; color:#d1d5db; font-family:ui-monospace,monospace; }
/* toggle pill réutilisé hors drawer (config) */
.smenu-cal-toggle {
  position:relative; width:38px; height:22px; background:#e2e8f0; border-radius:11px;
  border:none; cursor:pointer; transition:background .2s; flex-shrink:0;
}
.smenu-cal-toggle.on { background:#111; }
.smenu-cal-toggle::after {
  content:''; position:absolute; top:3px; left:3px; width:16px; height:16px;
  background:white; border-radius:50%; transition:left .2s; box-shadow:0 1px 3px rgba(0,0,0,.2);
}
.smenu-cal-toggle.on::after { left:19px; }

/* ── Bottom Nav — pills style ─────────────────────────────────────────────── */
.tabs { display:none; }
#bottom-nav { border-top:1px solid #f1f5f9; background:white; flex-shrink:0; }
#bottom-nav.hidden { display:none; }
#bottom-nav-scroll { display:flex; overflow-x:auto; scrollbar-width:none; gap:6px; padding:10px 12px max(14px,calc(14px + env(safe-area-inset-bottom,0px))); }
#bottom-nav-scroll::-webkit-scrollbar { display:none; }
.bnav-item { display:inline-flex; flex-direction:row; align-items:center; gap:5px; padding:7px 12px; border:none; background:#f4f4f5; color:#374151; cursor:pointer; border-radius:20px; flex-shrink:0; transition:all .15s; font-size:12px; font-weight:600; font-family:inherit; white-space:nowrap; }
.bnav-item:hover { background:#e8e8ea; }
.bnav-item:active { transform:scale(.95); }
.bnav-item.active { background:#111; color:#fff; }
.bnav-dot { width:7px; height:7px; border-radius:50%; flex-shrink:0; }
.bnav-icon { font-size:11px; display:flex; align-items:center; justify-content:center; }
.bnav-label { white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
@media (max-width:560px) {
  #bottom-nav-scroll { gap:4px; padding:8px 10px max(10px,calc(10px + env(safe-area-inset-bottom,0px))); }
  .bnav-item { padding:6px 9px; font-size:11px; }
}

/* ── Day numbers + chips ──────────────────────────────────────────────────── */
.view-global .day { align-items:flex-start; justify-content:flex-start; }
.view-global .day.today { box-shadow:none; }
.view-global .day.selected { box-shadow:inset 0 0 0 2px #6366f1; }
.day-num { display:block; text-align:left; font-size:13px; font-weight:600; color:#111; line-height:1; margin:0 0 2px; flex-shrink:0; padding-left:1px; }
.view-global .day.today .day-num { display:inline-flex; align-items:center; justify-content:center; background:#007aff; color:white; border-radius:50%; width:22px; height:22px; font-size:12px; font-weight:700; margin:0 0 2px; padding:0; }
.view-emp .day-num { font-size:13px; font-weight:600; color:#111; }
.view-emp .day.today .day-num { display:inline-flex; align-items:center; justify-content:center; background:#007aff !important; color:#fff !important; border-radius:50%; width:20px; height:20px; font-size:11px; font-weight:700; padding:0; }
/* Chips in global view */
.event-chips { display:flex; flex-direction:column; gap:2px; width:100%; margin-top:1px; min-width:0; }
.event-chip { border-radius:2px; font-size:8px; font-weight:700; color:white; padding:1px 3px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; line-height:1.3; display:block; width:100%; -webkit-touch-callout:none; user-select:none; }
.event-chip.pastel { color:#374151; font-weight:600; white-space:normal; }
.event-chip-more { font-size:7px; color:#94a3b8; padding:0 2px; font-weight:600; line-height:1.4; margin-top:1px; }

/* Vue semaine — time grid */
#week-view { display:none; flex-direction:column; flex:1; overflow:hidden; min-height:0; }
#week-view.active { display:flex; }
.wv-header { display:flex; flex-shrink:0; border-bottom:1px solid #e5e7eb; background:white; padding:0 8px 4px 0; }
.wv-header-gutter { width:36px; flex-shrink:0; }
.wv-day-hdr { flex:1; text-align:center; padding:5px 1px 4px; }
.wv-dayname { display:block; font-size:9px; font-weight:700; color:#9ca3af; text-transform:uppercase; letter-spacing:.3px; }
.wv-daynum { display:inline-flex; align-items:center; justify-content:center; width:24px; height:24px; font-size:14px; font-weight:700; color:#1e293b; border-radius:50%; }
.wv-daynum.is-today { background:#111; color:white; font-size:12px; }
.wv-scroll { flex:1; min-height:0; display:flex; padding:6px 0; }
.wv-grid { flex:1; display:flex; }
.wv-gutter { width:36px; flex-shrink:0; position:relative; }
.wv-hour-label { position:absolute; right:5px; font-size:9px; color:#9ca3af; font-weight:500; line-height:1; transform:translateY(-50%); white-space:nowrap; }
.wv-col { flex:1; position:relative; border-left:1px solid #f1f5f9; }
.wv-col.wv-today { background:#fafbff; }
.wv-col.selected { background:rgba(99,102,241,.06); }
.wv-col.selected::after { content:''; position:absolute; inset:0; box-shadow:inset 0 0 0 2px #6366f1; pointer-events:none; z-index:5; }
.wv-daynum.wv-selected { background:#6366f1 !important; color:white !important; }
.wv-h-line { position:absolute; left:0; right:0; height:1px; background:#f1f5f9; pointer-events:none; }
.wv-event { position:absolute; left:2px; right:2px; border-radius:4px; padding:2px 4px 2px 6px; overflow:hidden; cursor:pointer; box-sizing:border-box; border-left:3px solid transparent; font-size:9px; font-weight:700; line-height:1.3; white-space:nowrap; text-overflow:ellipsis; }
.wv-indispo { position:absolute; left:0; right:0; pointer-events:none; background:repeating-linear-gradient(45deg,#fee2e2 0 5px,#fecaca 5px 10px); opacity:.55; }
.wv-perso { position:absolute; left:2px; right:2px; border-radius:4px; padding:2px 5px; overflow:hidden; cursor:pointer; box-sizing:border-box; font-size:9px; font-weight:600; color:#6b7280; background:repeating-linear-gradient(45deg,#f3f4f6 0 4px,#e5e7eb 4px 8px); white-space:nowrap; text-overflow:ellipsis; }
.wv-now-line { position:absolute; left:0; right:0; height:2px; background:#ef4444; pointer-events:none; z-index:10; }
.wv-now-dot { position:absolute; left:-4px; top:50%; width:8px; height:8px; background:#ef4444; border-radius:50%; transform:translateY(-50%); }

/* Toggle Mois/Sem. */
.view-toggle { display:flex; gap:2px; }
.vtbtn { padding:3px 9px; border:1.5px solid #e2e8f0; border-radius:7px; font-size:11px; font-weight:600; color:#64748b; background:#f8fafc; cursor:pointer; transition:all .15s; }
.vtbtn.active { background:#eef2ff; border-color:#6366f1; color:#6366f1; }

/* ── Perso calendar hatch overlay — very subtle ── */
.day.has-perso > *:not(.perso-partial):not(.perso-info-dot) { position: relative; z-index: 1; }

/* ── Perso info band — neutral gray ── */
#perso-band {
  display: none; flex-shrink: 0;
  background: #fafafa; border-bottom: 1px solid #f1f5f9;
  padding: 6px 16px; font-size: 11px; color: #6b7280;
  align-items: center; gap: 8px;
}
#perso-band.visible { display: flex; }
#perso-band-close { display: none !important; }

/* ── Perso chip button ── */
#perso-btn { display:none; font-size:11px; font-weight:600; padding:5px 8px; background:#f4f4f5; border:none; border-radius:8px; color:#374151; cursor:pointer; flex-shrink:0; align-items:center; gap:4px; }
#perso-btn:hover { background:#e8e8ea; }

/* ── Perso tag in cells ── */
.perso-tag { font-size:8px; color:#6b7280; font-style:italic; display:flex; align-items:center; gap:2px; padding:0 2px 1px; overflow:hidden; margin-top:auto; flex-shrink:0; width:100%; }
.perso-tag-lbl { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.exporting .perso-tag, .exporting #perso-band { display:none !important; }

/* ── Legacy topbar buttons — hidden but kept for JS ── */
.view-toggle, #vt-month, #vt-week, #menu-btn, #select-btn, #help-btn, #logout-btn { display:none !important; }
/* ── Perso-band masqué : cal-toolbar couvre déjà l'info perso + actions ── */
#perso-band { display:none !important; }

/* ── iCal conflict bottom-sheet ── */
#ical-conflict-overlay {
  display: none; position: fixed; inset: 0; background: rgba(0,0,0,.5);
  z-index: 200; align-items: flex-end; justify-content: center;
}
#ical-conflict-overlay.open { display: flex; }
.ical-conflict-sheet {
  background: white; border-radius: 20px 20px 0 0; width: 100%; max-width: 520px;
  padding: 16px 20px 36px; box-shadow: 0 -8px 32px rgba(0,0,0,.15);
  animation: sheetUp .22s ease;
}
@keyframes sheetUp { from { transform: translateY(100%); } to { transform: translateY(0); } }
.ical-sheet-handle { width: 36px; height: 4px; background: #e2e8f0; border-radius: 2px; margin: 0 auto 14px; }
.ical-sheet-icon { font-size: 26px; text-align: center; margin-bottom: 6px; }
.ical-sheet-title { font-size: 16px; font-weight: 700; color: #111; text-align: center; margin-bottom: 3px; }
.ical-sheet-sub { font-size: 13px; color: #64748b; text-align: center; margin-bottom: 14px; }
.ical-sheet-events { background: #f8fafc; border-radius: 12px; padding: 10px 12px; margin-bottom: 18px; display: flex; flex-direction: column; gap: 5px; max-height: 160px; overflow-y: auto; }
.ical-sheet-ev { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #374151; }
.ical-sheet-ev-dot { width: 8px; height: 8px; border-radius: 50%; background: #a855f7; flex-shrink: 0; }
.ical-sheet-ev-name { font-weight: 600; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ical-sheet-ev-time { font-size: 12px; color: #94a3b8; flex-shrink: 0; }
.ical-sheet-btn-keep { width: 100%; padding: 13px; background: #1e293b; color: white; border: none; border-radius: 12px; font-size: 14px; font-weight: 700; cursor: pointer; margin-bottom: 8px; transition: background .15s; }
.ical-sheet-btn-keep:hover { background: #0f172a; }
.ical-sheet-btn-override { width: 100%; padding: 13px; background: #f1f5f9; color: #64748b; border: none; border-radius: 12px; font-size: 14px; font-weight: 600; cursor: pointer; transition: background .15s; }
.ical-sheet-btn-override:hover { background: #e2e8f0; color: #374151; }

/* ── Partial perso hatch zones (matin / aprem / soir) ── */
.perso-partial { position:absolute; left:0; right:0; pointer-events:none; z-index:0; background:repeating-linear-gradient(45deg,transparent 0 4px,rgba(156,163,175,.25) 4px 5px); }
.perso-partial.kind-full      { top:0; height:100%; }
.perso-partial.kind-morning   { top:0; height:33%; }
.perso-partial.kind-afternoon { top:33%; height:34%; }
.perso-partial.kind-evening   { top:67%; height:33%; }
.perso-info-dot { position:absolute; top:4px; right:4px; width:5px; height:5px; border-radius:50%; background:#9ca3af; z-index:1; pointer-events:none; }

/* ── FAB add event ── */
#fab-add-perso {
  display:none; position:fixed; bottom:max(84px, calc(84px + env(safe-area-inset-bottom))); right:16px;
  width:52px; height:52px; border-radius:50%; background:#111; color:white;
  border:none; font-size:24px; cursor:pointer;
  box-shadow:0 4px 24px rgba(0,0,0,.28); z-index:50;
  align-items:center; justify-content:center;
  transition:transform .15s, box-shadow .15s;
}
#fab-add-perso:hover { transform:scale(1.08); box-shadow:0 8px 28px rgba(0,0,0,.35); }
#fab-add-perso.visible { display:flex; }

/* ── Create perso event bottom sheet ── */
#create-perso-overlay {
  display:none; position:fixed; inset:0; background:rgba(0,0,0,.4);
  z-index:300; align-items:flex-end; justify-content:center;
}
#create-perso-overlay.open { display:flex; }
.create-perso-sheet {
  background:white; border-radius:20px 20px 0 0; width:100%; max-width:520px;
  padding:14px 20px calc(28px + env(safe-area-inset-bottom));
  animation:sheetUp .22s ease; max-height:90svh; overflow-y:auto;
}
.cps-handle  { width:36px; height:4px; background:#e2e8f0; border-radius:2px; margin:0 auto 14px; }
.cps-header  { display:flex; align-items:center; justify-content:space-between; margin-bottom:16px; }
.cps-cancel  { border:none; background:none; color:#6b7280; font-size:14px; cursor:pointer; font-family:inherit; }
.cps-title   { font-size:16px; font-weight:700; color:#111; }
.cps-ok      { border:none; background:none; color:#007aff; font-size:14px; font-weight:700; cursor:pointer; font-family:inherit; }
.cps-field   { background:#f5f5f7; border-radius:10px; margin-bottom:12px; overflow:hidden; }
.cps-row     { display:flex; align-items:center; justify-content:space-between; padding:10px 14px; border-bottom:1px solid #ececef; }
.cps-row:last-child { border-bottom:none; }
.cps-row-label { font-size:13px; color:#111; }
.cps-row-val   { font-size:13px; color:#007aff; font-variant-numeric:tabular-nums; }
.cps-inp  { background:transparent; border:none; outline:none; font-size:15px; font-weight:600; color:#111; width:100%; font-family:inherit; padding:10px 14px; display:block; }
.cps-sec-label { font-size:10px; font-weight:700; text-transform:uppercase; letter-spacing:.08em; color:#9ca3af; padding:14px 0 6px; }
.cps-radio-group { background:#f5f5f7; border-radius:10px; overflow:hidden; margin-bottom:12px; }
.cps-radio-row   { display:flex; align-items:center; gap:12px; padding:10px 12px; border-bottom:1px solid #ececef; cursor:pointer; }
.cps-radio-row:last-child { border-bottom:none; }
.cps-radio-circle { width:18px; height:18px; border-radius:50%; border:2px solid #d1d5db; background:white; display:flex; align-items:center; justify-content:center; flex-shrink:0; transition:all .15s; }
.cps-radio-circle.active { border-color:#111; background:#111; }
.cps-radio-circle.active::after { content:''; width:6px; height:6px; border-radius:50%; background:white; display:block; }
.cps-radio-text { flex:1; }
.cps-radio-main { font-size:13px; font-weight:600; color:#111; }
.cps-radio-sub  { font-size:11px; color:#6b7280; margin-top:1px; }
.cps-hint { margin-top:10px; padding:10px 12px; background:#eff6ff; border-radius:8px; font-size:11px; color:#1e40af; display:flex; gap:8px; align-items:flex-start; line-height:1.5; }
.cps-toggle { width:36px; height:22px; background:#e5e7eb; border-radius:11px; position:relative; cursor:pointer; border:none; flex-shrink:0; transition:background .2s; }
.cps-toggle.on { background:#22c55e; }
.cps-toggle::after { content:''; position:absolute; top:2px; left:2px; width:18px; height:18px; background:white; border-radius:50%; transition:left .2s; box-shadow:0 1px 3px rgba(0,0,0,.15); }
.cps-toggle.on::after { left:16px; }
.cps-del-btn { width:100%; padding:12px; background:#fef2f2; color:#ef4444; border:none; border-radius:10px; font-size:13px; font-weight:600; cursor:pointer; font-family:inherit; margin-top:8px; }
.cps-del-btn:hover { background:#fee2e2; }

/* ── Edit chip bottom sheet ── */
#edit-chip-overlay {
  display:none; position:fixed; inset:0; background:rgba(0,0,0,.4);
  z-index:300; align-items:flex-end; justify-content:center;
}
#edit-chip-overlay.open { display:flex; }
.edit-chip-sheet {
  background:white; border-radius:20px 20px 0 0; width:100%; max-width:520px;
  padding:14px 0 0;
  animation:sheetUp .22s ease; max-height:90svh;
  display:flex; flex-direction:column; overflow:hidden;
}
.ecs-scroll-body { flex:1; overflow-y:auto; padding:0 20px 8px; -webkit-overflow-scrolling:touch; }
.ecs-handle { width:36px; height:4px; background:#e2e8f0; border-radius:2px; margin:0 auto 14px; flex-shrink:0; }
.ecs-field  { background:#f5f5f7; border-radius:10px; overflow:hidden; margin-bottom:12px; }
.ecs-row    { display:flex; align-items:center; justify-content:space-between; padding:10px 14px; border-bottom:1px solid #ececef; }
.ecs-row:last-child { border-bottom:none; }
.ecs-label  { font-size:13px; color:#111; }
.ecs-val    { font-size:13px; color:#007aff; font-variant-numeric:tabular-nums; cursor:pointer; }
.ecs-status-seg { display:flex; gap:4px; background:#e5e7eb; border-radius:6px; padding:2px; }
.ecs-status-btn { padding:4px 12px; border:none; border-radius:4px; font-size:11px; font-weight:600; cursor:pointer; font-family:inherit; background:transparent; color:#374151; transition:all .15s; }
.ecs-status-btn.active { color:white; }
.ecs-actions { display:flex; gap:8px; padding:10px 20px calc(env(safe-area-inset-bottom) + 16px); background:white; border-top:1px solid #f1f5f9; flex-shrink:0; }
.ecs-save { flex:2; padding:13px; background:#111; color:white; border:none; border-radius:10px; font-size:13px; font-weight:600; cursor:pointer; font-family:inherit; }
.ecs-del  { flex:1; padding:13px; background:#fef2f2; color:#ef4444; border:none; border-radius:10px; font-size:13px; font-weight:600; cursor:pointer; font-family:inherit; }
.ecs-sec-label { font-size:10px; font-weight:700; text-transform:uppercase; letter-spacing:.08em; color:#9ca3af; padding:14px 0 6px; }
/* ── Booking sheet V3 ── */
.ecs-v3-close { width:32px; height:32px; border-radius:50%; background:#f1f5f9; border:none; font-size:20px; color:#64748b; cursor:pointer; flex-shrink:0; font-family:inherit; display:flex; align-items:center; justify-content:center; line-height:1; }
.ecs-v3-sec-lbl { font-size:10px; font-weight:700; color:#9ca3af; text-transform:uppercase; letter-spacing:.06em; margin-bottom:10px; }
.ecs-v3-statut-row { display:flex; gap:8px; margin-bottom:20px; }
.ecs-v3-pill { flex:1; padding:13px 6px; border-radius:12px; border:2px solid #e2e8f0; background:#f9fafb; color:#9ca3af; font-size:13px; font-weight:600; cursor:pointer; font-family:inherit; display:flex; align-items:center; justify-content:center; gap:6px; transition:all .15s; }
.ecs-v3-pill .sdot { width:8px; height:8px; border-radius:50%; background:#d1d5db; flex-shrink:0; transition:background .15s; }
.ecs-v3-pill[data-key="indispo"].sp-active { border-color:#ef4444; background:#fff5f5; color:#ef4444; }
.ecs-v3-pill[data-key="indispo"].sp-active .sdot { background:#ef4444; }
.ecs-v3-pill[data-key="booke"].sp-active { border-color:transparent; background:#7c3aed; color:#fff; }
.ecs-v3-pill[data-key="booke"].sp-active .sdot { background:rgba(255,255,255,.7); }
.ecs-v3-pill[data-key="option"].sp-active { border-color:#ddd6fe; background:#f5f3ff; color:#7c3aed; }
.ecs-v3-pill[data-key="option"].sp-active .sdot { background:#c4b5fd; }
.ecs-v3-jour-row { display:flex; align-items:center; justify-content:space-between; padding:13px 16px; background:#f8fafc; border-radius:12px; margin-bottom:16px; font-size:14px; font-weight:600; color:#111; }
.ecs-v3-hours-grid { display:grid; grid-template-columns:1fr 1fr 1fr; gap:10px; }
.ecs-v3-hours-2col { display:grid; grid-template-columns:1fr 1fr; gap:10px; margin-top:10px; }
.ecs-v3-hours-col { display:flex; flex-direction:column; gap:6px; }
.ecs-v3-col-lbl { font-size:10px; font-weight:700; color:#9ca3af; text-transform:uppercase; letter-spacing:.04em; }
.ecs-v3-time-inp { width:100%; padding:12px 4px; border:1.5px solid #e2e8f0; border-radius:10px; font-size:16px; font-weight:600; color:#111; text-align:center; font-family:inherit; outline:none; box-sizing:border-box; }
.ecs-v3-time-inp:focus { border-color:#7c3aed; }
.ecs-v3-dur-box { padding:12px 4px; background:#f5f3ff; border-radius:10px; font-size:16px; font-weight:700; color:#7c3aed; text-align:center; display:flex; align-items:center; justify-content:center; }
.ecs-v3-sep { margin:16px 0; border:none; border-top:1px solid #f1f5f9; }
.ecs-v3-card-row { display:flex; gap:8px; overflow-x:auto; scrollbar-width:none; padding-bottom:4px; }
.ecs-v3-tarif-wrap { display:flex; align-items:center; justify-content:space-between; padding:14px 16px; background:#f8fafc; border-radius:12px; margin-bottom:10px; }
.ecs-v3-tarif-lbl { font-size:14px; font-weight:600; color:#111; }
.ecs-v3-tarif-sub { font-size:11px; color:#94a3b8; margin-top:3px; min-height:14px; }
.ecs-v3-tarif-val { display:flex; align-items:baseline; gap:3px; flex-shrink:0; }
.ecs-v3-tarif-val input { border:none; outline:none; font-size:20px; font-weight:700; color:#111; font-family:inherit; background:transparent; width:72px; text-align:right; }
.ecs-v3-tarif-val span { font-size:16px; font-weight:600; color:#374151; }
.ecs-v3-block-wrap { display:flex; align-items:center; justify-content:space-between; padding:14px 16px; background:#f8fafc; border-radius:12px; margin-bottom:10px; gap:12px; }
.ecs-v3-more-wrap { display:flex; align-items:center; justify-content:space-between; padding:14px 16px; background:#f8fafc; border-radius:12px; margin-bottom:10px; cursor:pointer; }
.ecs-v3-more-inner { background:#f8fafc; border-radius:12px; margin-bottom:10px; overflow:hidden; }
.ecs-v3-section-hdr { font-size:11px; font-weight:700; color:#9ca3af; text-transform:uppercase; letter-spacing:.06em; margin:16px 0 10px; }

/* ── New pige sheet (remplace section inline booke/option) ── */
.nps-block-group { background:#f5f5f7; border-radius:10px; overflow:hidden; }
.nps-block-row   { display:flex; align-items:center; gap:12px; padding:10px 12px; border-bottom:1px solid #ececef; cursor:pointer; }
.nps-block-row:last-child { border-bottom:none; }
.nps-radio-circle { width:18px; height:18px; border-radius:50%; border:2px solid #d1d5db; background:white; display:flex; align-items:center; justify-content:center; flex-shrink:0; transition:all .15s; }
.nps-radio-circle.active { border-color:#111; background:#111; }
.nps-radio-circle.active::after { content:''; width:6px; height:6px; border-radius:50%; background:white; display:block; }
.nps-radio-text { flex:1; }
.nps-radio-main { font-size:13px; font-weight:600; color:#111; }
.nps-radio-sub  { font-size:11px; color:#6b7280; margin-top:1px; }
.nps-badge { font-size:9px; font-weight:700; color:#22c55e; text-transform:uppercase; letter-spacing:.06em; }

/* ── iCal outbound settings ── */
.ical-out-url-row { display:flex; align-items:center; gap:8px; margin:8px 0; }
.ical-out-url { flex:1; font-size:11px; background:#f5f5f7; padding:8px 10px; border-radius:6px; color:#374151; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-family:ui-monospace,monospace; border:none; outline:none; }
.ical-out-copy { padding:8px 12px; background:#111; color:#fff; border:none; border-radius:6px; font-size:12px; font-weight:600; cursor:pointer; font-family:inherit; white-space:nowrap; }
.ical-out-copy:hover { background:#374151; }
.ical-out-regen { margin-top:6px; padding:7px 12px; background:#f8fafc; color:#374151; border:1.5px solid #e2e8f0; border-radius:6px; font-size:11px; font-weight:600; cursor:pointer; font-family:inherit; }
.ical-out-instr-row { padding:10px 0; border-bottom:1px solid #f1f5f9; }
.ical-out-instr-row:last-child { border-bottom:none; }
.ical-out-app { font-size:13px; font-weight:600; color:#111; margin-bottom:2px; }
.ical-out-steps { font-size:11px; color:#6b7280; }

/* ── Export new bottom-sheet ── */
#export-new-overlay { display:none; position:fixed; inset:0; background:rgba(0,0,0,.5); z-index:210; align-items:flex-end; justify-content:center; }
#export-new-overlay.open { display:flex; }
#export-new-sheet { background:#fff; border-radius:20px 20px 0 0; padding:14px 20px calc(20px + env(safe-area-inset-bottom)); max-height:92svh; overflow-y:auto; width:100%; max-width:520px; }
.export-handle { width:40px; height:4px; background:#e5e7eb; border-radius:2px; margin:0 auto 14px; }
.export-sheet-hdr { display:flex; align-items:center; justify-content:space-between; margin-bottom:14px; }
.export-sheet-cancel { border:none; background:none; color:#6b7280; font-size:14px; cursor:pointer; font-family:inherit; }
.export-sheet-title { font-size:16px; font-weight:700; }
.export-params-blk { background:#f5f5f7; border-radius:10px; margin-bottom:12px; overflow:hidden; }
.export-param-row { display:flex; align-items:center; justify-content:space-between; padding:10px 14px; border-bottom:1px solid #ececef; }
.export-param-row:last-child { border-bottom:none; }
.export-param-lbl { font-size:13px; color:#111; }
.export-param-val { font-size:13px; color:#007aff; background:none; border:none; cursor:pointer; font-family:inherit; display:flex; align-items:center; gap:6px; padding:0; }
.export-conf-banner { background:#fff7ed; border-left:3px solid #f97316; border-radius:6px; padding:10px 12px; margin-bottom:12px; font-size:11px; color:#9a3412; line-height:1.5; display:none; }
.export-conf-banner.visible { display:block; }
.export-toggles-blk { background:#f5f5f7; border-radius:10px; margin-bottom:12px; overflow:hidden; display:none; }
.export-toggles-blk.visible { display:block; }
.export-toggle-row { display:flex; align-items:center; justify-content:space-between; padding:10px 14px; border-bottom:1px solid #ececef; }
.export-toggle-row:last-child { border-bottom:none; }
.export-toggle-info { flex:1; }
.export-toggle-lbl { font-size:13px; color:#111; }
.export-toggle-sub { font-size:10px; color:#6b7280; margin-top:1px; }
.export-itoggle { width:36px; height:22px; background:#e5e7eb; border-radius:11px; position:relative; border:none; cursor:pointer; flex-shrink:0; transition:background .15s; }
.export-itoggle.on { background:#22c55e; }
.export-itoggle::after { content:''; position:absolute; left:2px; top:2px; width:18px; height:18px; background:#fff; border-radius:50%; transition:left .15s; box-shadow:0 1px 3px #0002; }
.export-itoggle.on::after { left:16px; }
.export-perso-banner { background:#eff6ff; border-radius:8px; padding:8px 12px; margin-bottom:14px; font-size:11px; color:#1e40af; display:flex; gap:8px; align-items:flex-start; }
.export-sec-lbl { font-size:11px; font-weight:700; color:#6b7280; text-transform:uppercase; letter-spacing:.06em; margin:0 0 8px; }
.export-formats-grid { display:flex; flex-direction:column; gap:10px; margin-bottom:14px; }
.export-fmt-btn { display:none; } /* boutons anciens masqués */
.export-act-copy { width:100%; padding:14px; border:1.5px solid #e2e8f0; border-radius:12px; background:white; color:#111; font-size:15px; font-weight:600; cursor:pointer; font-family:inherit; display:flex; align-items:center; justify-content:center; gap:10px; transition:background .12s; }
.export-act-copy:active { background:#f5f5f7; }
.export-act-share { width:100%; padding:14px; border:none; border-radius:12px; background:#111; color:white; font-size:15px; font-weight:600; cursor:pointer; font-family:inherit; display:flex; align-items:center; justify-content:center; gap:10px; transition:background .12s; }
.export-act-share:active { background:#333; }
.export-preview-blk { background:#f5f5f7; border-radius:10px; padding:12px; font-size:11px; color:#374151; font-family:ui-monospace,monospace; line-height:1.6; max-height:160px; overflow-y:auto; white-space:pre-wrap; word-break:break-word; }
/* Bandeau confidentiel dans la vue calendrier (vu par l'utilisateur seulement) */
#emp-conf-banner { display:none; background:#fff7ed; border-bottom:1px solid #fed7aa; padding:5px 14px; font-size:10px; color:#9a3412; align-items:center; gap:6px; flex-shrink:0; }
#emp-conf-banner.visible { display:flex; }
.exporting #emp-conf-banner { display:none !important; }
/* En export confidentiel, masquer les horaires des cases Indispo "autres" */
.exporting-confidential .day.indispo .day-time { display:none !important; }
/* Dispo = fond couleur employeur (56%) dans l'export — appliqué en inline style par JS */

/* ── Logo-Menu button ── */
.logo-menu-btn { display:inline-flex; align-items:center; gap:8px; background:none; border:none; cursor:pointer; padding:4px; border-radius:8px; flex-shrink:0; }
.logo-menu-btn:hover { background:#f5f5f7; }
.logo-bars { display:flex; flex-direction:column; gap:3px; transition:transform .2s ease; }
.logo-bar-r { width:17px; height:3.5px; border-radius:1px; background:#ef4444; }
.logo-bar-g { width:14px; height:3.5px; border-radius:1px; background:#22c55e; margin-left:3px; }
.logo-bar-p { width:12px; height:3.5px; border-radius:1px; background:#a855f7; margin-left:1px; }
.menu-open .logo-bars { transform:rotate(90deg); }

/* ── Cal toolbar (remplace perso-band + export-bar) ── */
#cal-toolbar { display:none; align-items:center; justify-content:space-between; padding:0 12px; height:36px; background:#fafafa; border-bottom:1px solid #f1f5f9; flex-shrink:0; }
#cal-toolbar.visible { display:flex; }
#cal-toolbar.sel-active { background:#111; }
#cal-toolbar-perso { display:flex; align-items:center; gap:5px; font-size:12px; color:#16a34a; font-weight:600; }
#cal-toolbar-perso svg { flex-shrink:0; }
#cal-toolbar-sel-count { font-size:12px; font-weight:700; color:#fff; display:none; }
#cal-toolbar.sel-active #cal-toolbar-perso { display:none; }
#cal-toolbar.sel-active #cal-toolbar-sel-count { display:block; }
#cal-toolbar-btns { display:flex; gap:4px; }
#cal-toolbar.sel-active #cal-toolbar-btns { display:none; }
#cal-toolbar-sel-btns { display:none; gap:6px; }
#cal-toolbar.sel-active #cal-toolbar-sel-btns { display:flex; }
.cal-tb-btn { display:flex; align-items:center; gap:4px; padding:5px 10px; background:#fff; border:1.5px solid #e2e8f0; border-radius:20px; font-size:12px; color:#374151; cursor:pointer; font-family:inherit; font-weight:500; }
.cal-tb-btn:hover { background:#f5f5f7; }
.cal-tb-sel-btn { padding:5px 10px; border:none; border-radius:6px; font-size:11px; font-weight:600; cursor:pointer; font-family:inherit; }
.exporting #cal-toolbar { display:none !important; }
/* ── Month loader overlay ─────────────────────────────────────────────── */
#month-loader {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(255,255,255,0.6);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 16px;
  transition: opacity .22s ease;
}
#month-loader.hiding { opacity: 0; pointer-events: none; }
.ml-bars { display: flex; flex-direction: column; gap: 4px; }
.ml-bar-r { width: 28px; height: 5px; border-radius: 2px; background: #ef4444; animation: ml-pulse 1.1s ease-in-out infinite; }
.ml-bar-g { width: 22px; height: 5px; border-radius: 2px; background: #22c55e; margin-left: 5px; animation: ml-pulse 1.1s ease-in-out infinite .18s; }
.ml-bar-p { width: 18px; height: 5px; border-radius: 2px; background: #a855f7; margin-left: 2px; animation: ml-pulse 1.1s ease-in-out infinite .36s; }
.ml-word { font: 800 22px/1 -apple-system,system-ui,sans-serif; letter-spacing: -.02em; color: #111; }
.ml-dot { color: #22c55e; }
@keyframes ml-pulse {
  0%, 100% { opacity: 1; transform: scaleX(1); }
  50% { opacity: 0.28; transform: scaleX(0.58); }
}
@keyframes slideUp { from { opacity:0; transform:translateX(-50%) translateY(16px); } to { opacity:1; transform:translateX(-50%) translateY(0); } }
