/**
 * SpocSpace EMS — Main Stylesheet
 * Theme Claude: warm, light, minimal
 */

/* ── Variables — Claude warm palette ── */
:root {
  --ss-navy: #1B2A4A;
  --ss-navy-light: #253755;
  --ss-navy-dark: #111D35;
  --ss-teal: #191918;
  --ss-teal-light: #3D3D3C;
  --ss-teal-dark: #000000;
  --ss-green: #16A34A;
  --ss-green-light: #6FCF97;
  --ss-orange: #EA8B2D;
  --ss-red: #DC2626;
  --ss-purple: #9B51E0;
  --ss-bg: #F7F5F2;
  --ss-bg-card: #FFFFFF;
  --ss-text: #1A1A1A;
  --ss-text-secondary: #6B6B6B;
  --ss-text-muted: #9B9B9B;
  --ss-border: #E8E5E0;
  --ss-border-light: #F0EDE8;
  --ss-shadow-sm: 0 1px 3px rgba(0,0,0,0.04), 0 1px 2px rgba(0,0,0,0.02);
  --ss-shadow-md: 0 4px 12px rgba(0,0,0,0.06);
  --ss-shadow-lg: 0 8px 24px rgba(0,0,0,0.08);
  --ss-radius-sm: 8px;
  --ss-radius-md: 12px;
  --ss-radius-lg: 16px;
  --ss-radius-xl: 20px;
  --ss-nav-h: 54px;
  --ss-sidebar-w: 250px;
  --ss-sidebar-mini: 64px;
  --ss-transition: 200ms cubic-bezier(0.4, 0, 0.2, 1);
  --ss-accent-bg: rgba(25,25,24,0.06);
}

/* Modals & table wrappers */
.modal-content { border-radius: 2rem; border: 1px solid #d1cfc5; overflow: hidden; }
.modal-header { position: relative; border-bottom: 1px solid #d1cfc5; background: #f3efe7; border-top-left-radius: 2rem; border-top-right-radius: 2rem; }
/* ══════════════════════════════════════
   STANDARD MODAL CLOSE BUTTON (Claude-style)
   Unifie tous les patterns existants : .btn-close, .confirm-close-btn,
   .ss-modal-close, et tout button[data-bs-dismiss="modal"] dans .modal-header
   (couvre aussi .chg-modal-close, .cuis-modal-close, .home-close-btn,
    .rep-modal-close-btn, .pv-modal-close, .abs-modal-close, etc.)
   ══════════════════════════════════════ */
.modal-header .btn-close,
.modal-header .confirm-close-btn,
.modal-header button[data-bs-dismiss="modal"],
.ss-modal-close {
  position: absolute;
  top: 0.6rem;
  right: 0.6rem;
  z-index: 2;
  width: 32px !important;
  height: 32px !important;
  min-width: 32px;
  border-radius: 8px !important;
  border: none !important;
  background: transparent !important;
  background-image: none !important;
  background-color: transparent !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0 !important;
  margin: 0;
  color: var(--cl-text-muted, #6b7280) !important;
  opacity: 1 !important;
  transition: background-color .15s ease, color .15s ease !important;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: none !important;
}
.modal-header .btn-close:hover,
.modal-header .confirm-close-btn:hover,
.modal-header button[data-bs-dismiss="modal"]:hover,
.ss-modal-close:hover {
  background-color: rgba(0, 0, 0, 0.06) !important;
  color: var(--cl-text, #1a1a1a) !important;
  border-color: transparent !important;
}
.modal-header .btn-close:focus,
.modal-header .confirm-close-btn:focus,
.modal-header button[data-bs-dismiss="modal"]:focus,
.ss-modal-close:focus,
.ss-modal-close:focus-visible {
  box-shadow: none !important;
  outline: none !important;
}
.modal-header .btn-close:active,
.modal-header button[data-bs-dismiss="modal"]:active,
.ss-modal-close:active {
  background-color: rgba(0, 0, 0, 0.10) !important;
}
/* Remplace le SVG natif Bootstrap par l'icône bi-x-lg (\f659) */
.modal-header .btn-close::before {
  content: "\f659";
  font-family: "bootstrap-icons" !important;
  font-size: 1.05rem;
  font-weight: 400;
  line-height: 1;
  display: inline-block;
  -webkit-font-smoothing: antialiased;
}
/* Normalise la taille de l'icône <i.bi> interne (bi-x-lg / bi-x) */
.modal-header .confirm-close-btn .bi,
.modal-header button[data-bs-dismiss="modal"] .bi,
.ss-modal-close .bi {
  font-size: 1.05rem !important;
  line-height: 1 !important;
}
/* Modal type: info (warm beige — default) */
.modal-info .modal-header { background: #F5F0E8; border-bottom: 2px solid #D4C9B5; }
/* Modal type: success (green) */
.modal-success .modal-header { background: #E8F5E9; border-bottom: 2px solid #4CAF50; }
/* Modal type: warning (warm amber/orange) */
.modal-warning .modal-header { background: #FFF8E1; border-bottom: 2px solid #FFC107; }
/* Modal type: danger (red) */
.modal-danger .modal-header { background: #FFEBEE; border-bottom: 2px solid #F44336; }
.modal-footer { border-top: 1px solid #d1cfc5; }
.table-wrap { overflow-x: auto; padding-bottom: 0.35rem; }
.table-wrap table { min-width: 700px; }

/* ── Custom scrollbar ── */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: var(--ss-border);
  border-radius: 99px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--ss-text-muted);
}

/* ── Reset & Base ── */
*, *::before, *::after { box-sizing: border-box; }
body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 14px;
  line-height: 1.6;
  color: var(--ss-text);
  background: var(--ss-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a { color: var(--ss-teal); text-decoration: none; transition: color var(--ss-transition); }
a:hover { color: var(--ss-teal-dark); }
img { max-width: 100%; }
button { cursor: pointer; font-family: inherit; }
input, select, textarea { font-family: inherit; font-size: 14px; }

/* ══════════════════════════════════════
   SIDEBAR (frontend)
   ══════════════════════════════════════ */
.fe-sidebar {
  position: fixed;
  top: 0; right: calc(-1 * var(--ss-sidebar-w)); bottom: 0;
  width: var(--ss-sidebar-w);
  background: var(--ss-bg-card);
  border-left: 1px solid var(--ss-border);
  z-index: 1040;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: right 0.3s ease;
  box-shadow: var(--ss-shadow-lg);
}
.fe-sidebar.open {
  right: 0;
}

/* Sidebar header */
.fe-sidebar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--ss-border);
  min-height: 54px;
  flex-shrink: 0;
  background: var(--ss-bg-card);
}
.fe-sidebar-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  color: var(--ss-text);
  font-weight: 700;
  font-size: 1.05rem;
  white-space: nowrap;
  overflow: hidden;
}
.fe-brand-icon { font-size: 1.2rem; flex-shrink: 0; }
.fe-brand-logo { width: 30px; height: 30px; object-fit: contain; border-radius: 6px; flex-shrink: 0; }
.fe-brand-avatar { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.fe-brand-avatar-circle {
  width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0;
  background: var(--ss-teal); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 600; font-size: 0.78rem;
}
.fe-brand-text { transition: opacity var(--ss-transition); }

.fe-sidebar-toggle {
  background: none;
  border: none;
  color: var(--ss-text-muted);
  cursor: pointer;
  padding: 5px 7px;
  border-radius: var(--ss-radius-sm);
  font-size: 1rem;
  flex-shrink: 0;
  transition: all var(--ss-transition);
}
.fe-sidebar-toggle:hover {
  color: var(--ss-text);
  background: var(--ss-accent-bg);
}

/* Category headers */
.fe-sidebar-cat {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.55rem 1rem 0.2rem;
  cursor: pointer;
  user-select: none;
}
.fe-sidebar-cat-label {
  font-size: 0.63rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--ss-text-muted);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
}
.fe-sidebar-cat-chevron {
  font-size: 0.55rem;
  color: var(--ss-text-muted);
  transition: transform 0.25s;
  flex-shrink: 0;
}
.fe-sidebar-cat.cat-collapsed .fe-sidebar-cat-chevron {
  transform: rotate(-90deg);
}

/* Category items */
.fe-sidebar-cat-items {
  overflow: hidden;
  max-height: 500px;
  transition: max-height 0.3s ease, opacity 0.25s ease;
  opacity: 1;
}
.fe-sidebar-cat-items.collapsed {
  max-height: 0;
  opacity: 0;
}

/* Sidebar nav links */
.fe-sidebar-nav {
  flex: 1;
  padding: 0.4rem 0;
  overflow-y: auto;
  overflow-x: hidden;
}
.fe-sidebar-link {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.45rem 1rem;
  margin: 1px 0.45rem;
  color: var(--ss-text-secondary);
  text-decoration: none;
  font-size: 0.84rem;
  font-weight: 500;
  transition: all var(--ss-transition);
  border-radius: var(--ss-radius-sm);
  white-space: nowrap;
  overflow: hidden;
}
.fe-sidebar-link:hover {
  color: var(--ss-text);
  background: var(--ss-accent-bg);
}
.fe-sidebar-link.active {
  color: var(--ss-teal);
  background: var(--ss-accent-bg);
  font-weight: 600;
}
.fe-sidebar-link--disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.fe-sidebar-link--disabled:hover {
  color: var(--ss-text-secondary);
  background: none;
}
.fe-sidebar-link i {
  font-size: 1.05rem;
  width: 1.25rem;
  text-align: center;
  flex-shrink: 0;
}
.fe-nav-label {
  transition: opacity var(--ss-transition);
  overflow: hidden;
  flex: 1;
}
.fe-sidebar-badge {
  width: 8px;
  height: 8px;
  background: var(--ss-red);
  border-radius: 50%;
  flex-shrink: 0;
  animation: fe-pulse 2s infinite;
}
@keyframes fe-pulse { 0%,100%{opacity:1} 50%{opacity:.5} }

/* Sidebar user header — link to profile */

/* Sidebar footer */
.fe-sidebar-footer {
  border-top: 1px solid var(--ss-border);
  padding: 0.4rem 0;
  flex-shrink: 0;
  background: var(--ss-bg-card);
}
.fe-sidebar-footer .fe-sidebar-link:hover,
.fe-sidebar-footer .fe-sidebar-link:active {
  background: transparent;
}
.fe-sidebar-logout-btn {
  color: var(--ss-red) !important;
  transition: background .15s;
}
.fe-sidebar-logout-btn:hover,
.fe-sidebar-logout-btn:active {
  background: rgba(220,38,38,0.08) !important;
}
.fe-sidebar-admin-link {
  color: var(--ss-teal) !important;
}

/* ══════════════════════════════════════
   SIDEBAR MINI STATE
   ══════════════════════════════════════ */
.fe-sidebar.mini {
  width: var(--ss-sidebar-mini);
}
.fe-sidebar.mini .fe-brand-text,
.fe-sidebar.mini .fe-nav-label,
.fe-sidebar.mini .fe-sidebar-cat-label,
.fe-sidebar.mini .fe-sidebar-cat-chevron,
.fe-sidebar.mini .fe-sidebar-badge {
  display: none;
}
.fe-sidebar.mini .fe-sidebar-header {
  justify-content: center;
  padding: 0.85rem 0.4rem;
}
.fe-sidebar.mini .fe-sidebar-brand { display: none; }
.fe-sidebar.mini .fe-sidebar-toggle {
  display: flex; margin: 0 auto;
}
.fe-sidebar.mini .fe-sidebar-cat {
  padding: 0.25rem 0;
  justify-content: center;
}
.fe-sidebar.mini .fe-sidebar-cat-items.collapsed {
  max-height: 500px !important;
  opacity: 1 !important;
}
.fe-sidebar.mini .fe-sidebar-link {
  justify-content: center;
  padding: 0.5rem 0.4rem;
  margin: 1px 0.3rem;
  gap: 0;
}
.fe-sidebar.mini .fe-sidebar-link i {
  font-size: 1.12rem;
  margin: 0;
}

/* ══════════════════════════════════════
   MAIN CONTENT
   ══════════════════════════════════════ */
.fe-main {
  margin-left: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: margin-left var(--ss-transition);
}

/* Topbar */
.fe-topbar {
  position: sticky;
  top: 0;
  z-index: 1020;
  background: var(--ss-bg-card);
  border-bottom: 1px solid var(--ss-border);
  padding: 0 1.25rem;
  height: var(--ss-nav-h);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.fe-topbar-left {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  min-width: 0;
}
.fe-topbar-brand { display: flex; align-items: center; text-decoration: none; flex-shrink: 0; position: relative; }
.fe-topbar-brand-logo { height: 30px; width: auto; object-fit: contain; border-radius: 8px; }
.fe-topbar-hamburger {
  display: none;
  background: none;
  border: none;
  font-size: 1.3rem;
  color: var(--ss-text-secondary);
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--ss-radius-sm);
  transition: all var(--ss-transition);
  flex-shrink: 0;
}
.fe-topbar-hamburger:hover { background: var(--ss-accent-bg); color: var(--ss-text); }
.fe-topbar-title {
  font-size: 0.92rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin: 0;
}

/* Topbar search — centered */
.fe-topbar-search {
  position: relative;
  width: 280px;
  flex-shrink: 0;
  transition: width 0.3s ease;
}
.fe-topbar-search.expanded {
  width: 450px;
}
.fe-topbar-search input {
  font-size: 0.84rem;
  padding: 0.4rem 2rem 0.4rem 2rem;
  border-radius: 20px;
  border: 1px solid var(--ss-border);
  background: var(--ss-bg);
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
  width: 100%;
  outline: none;
}
.fe-topbar-search input:focus {
  background: var(--ss-bg-card);
  border-color: var(--ss-teal);
  box-shadow: 0 0 0 3px rgba(25,25,24,0.1);
}
.fe-search-clear {
  position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  background: none; border: none; cursor: pointer; padding: 2px 6px;
  font-size: 0.78rem; color: var(--ss-text-muted); border-radius: 50%;
  transition: color 0.15s, background 0.15s;
}
.fe-search-clear:hover { color: var(--ss-text); background: rgba(0,0,0,0.05); }
.fe-search-icon {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--ss-text-muted);
  font-size: 0.82rem;
  pointer-events: none;
}
.fe-search-results {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--ss-bg-card);
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius-md);
  box-shadow: var(--ss-shadow-lg);
  z-index: 1050;
  max-height: 360px;
  overflow-y: auto;
  display: none;
  margin-top: 4px;
}
.fe-search-results.show { display: block; }
.fe-search-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 0.8rem;
  text-decoration: none;
  color: inherit;
  transition: background var(--ss-transition);
  cursor: pointer;
  border-bottom: 1px solid var(--ss-border-light);
  font-size: 0.85rem;
}
.fe-search-item:last-child { border-bottom: none; }
.fe-search-item:hover { background: var(--ss-accent-bg); }
.fe-search-item-icon {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--ss-accent-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
  color: var(--ss-teal);
}
.fe-search-item-icon.user-icon {
  background: var(--ss-teal);
  color: #fff;
}
.fe-search-item-name { font-weight: 500; }
.fe-search-item-meta { font-size: 0.75rem; color: var(--ss-text-muted); }
.fe-hist-del { background:none; border:none; color:#ccc; cursor:pointer; padding:2px; margin-left:auto; font-size:.75rem; transition:color .12s; flex-shrink:0; }
.fe-hist-del:hover { color:#dc3545; }

/* Topbar right */
.fe-topbar-right {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
}
.fe-topbar-icon-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  color: var(--ss-text-secondary);
  background: transparent;
  border: none;
  transition: all 0.2s ease;
  text-decoration: none;
  cursor: pointer;
}
.fe-topbar-icon-btn:hover {
  background: var(--ss-accent-bg);
  color: var(--ss-text);
}
.fe-topbar-icon-btn i { font-size: 1.1rem; }
.fe-topbar-notif {
  position: absolute;
  top: 3px; right: 3px;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--ss-red);
  border: 2px solid var(--ss-bg-card);
  animation: fe-pulse 2s infinite;
}
.fe-topbar-user {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0 6px;
}
.fe-topbar-user-avatar {
  width: 30px;
  height: 30px;
  background: var(--ss-teal);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.7rem;
  text-transform: uppercase;
  color: #fff;
  object-fit: cover;
  flex-shrink: 0;
}
.fe-topbar-user-name {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--ss-text);
}
.fe-topbar-logout:hover {
  background: rgba(220, 38, 38, 0.08);
  color: var(--ss-red);
}

/* Content area */
#app-content {
  min-height: calc(100vh - var(--ss-nav-h));
  padding: 1.5rem;
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
}

/* No sidebar for login */
body.no-nav .fe-sidebar,
body.no-nav .fe-sidebar-overlay { display: none; }
body.no-nav .fe-main { margin-left: 0; }
body.no-nav .fe-topbar { display: none; }
body.no-nav #app-content {
  min-height: 100vh;
  max-width: 100%;
  padding: 0;
}

/* ══════════════════════════════════════
   MOBILE — sidebar off-canvas
   ══════════════════════════════════════ */
.fe-sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.3);
  z-index: 1015;
  backdrop-filter: blur(2px);
}
.fe-sidebar-overlay.show { display: block; }

@media (max-width: 991.98px) {
  .fe-sidebar {
    right: calc(-1 * var(--ss-sidebar-w));
    transition: right 0.25s ease, width 0.25s ease;
    width: var(--ss-sidebar-w) !important;
    box-shadow: var(--ss-shadow-lg);
  }
  .fe-sidebar.open { right: 0; }
  .fe-sidebar .fe-sidebar-toggle { display: none; }
  .fe-sidebar .fe-brand-text,
  .fe-sidebar .fe-nav-label,
  .fe-sidebar .fe-sidebar-cat-label,
  .fe-sidebar .fe-sidebar-cat-chevron,
  .fe-sidebar .fe-sidebar-badge { display: revert !important; }
  .fe-sidebar .fe-sidebar-link {
    justify-content: flex-start !important;
    gap: 0.7rem !important;
    padding: 0.45rem 1rem !important;
    margin: 1px 0.45rem !important;
  }
  .fe-main { margin-left: 0 !important; }
  .fe-topbar-hamburger { display: block; }
  .fe-topbar-left { flex: unset; }
  .fe-topbar-search { width: 160px; }
  .fe-topbar-search.expanded { width: 260px; }
}

/* ── Cards ── */
.card {
  background: var(--ss-bg-card);
  border: 1px solid var(--ss-border-light);
  border-radius: var(--ss-radius-md);
  box-shadow: var(--ss-shadow-sm);
  transition: box-shadow var(--ss-transition), border-color var(--ss-transition);
}
.card:hover { box-shadow: var(--ss-shadow-md); }
.card-header {
  padding: 0.9rem 1.25rem;
  border-bottom: 1px solid var(--ss-border-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  background: transparent;
}
.card-header h3 {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
}
.card-body { padding: 1.25rem; }

/* ── Repartition toggle tabs (sliding pill) ── */
.rep-tabs {
  display: inline-flex;
  position: relative;
  background: var(--ss-bg, #F7F5F2);
  border-radius: 10px;
  padding: 3px;
  gap: 0;
}
.rep-tabs-slider {
  position: absolute;
  top: 3px;
  left: 3px;
  height: calc(100% - 6px);
  background: var(--ss-bg-card, #fff);
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.04);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 0;
  pointer-events: none;
}
.rep-tab {
  background: none;
  border: none;
  padding: 6px 14px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--ss-text-secondary);
  border-radius: 8px;
  cursor: pointer;
  transition: color 0.2s;
  position: relative;
  z-index: 1;
  text-align: center;
  white-space: nowrap;
}
.rep-tab:hover { color: var(--ss-text); }
.rep-tab-active {
  color: var(--ss-text);
  font-weight: 600;
}

/* ── Page header ── */
.page-header { margin-bottom: 1.5rem; }
.page-header h1 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 0.25rem;
  color: var(--ss-text);
}
.page-header p {
  margin: 0;
  color: var(--ss-text-secondary);
  font-size: 0.92rem;
}

/* ── Stat cards ── */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.stat-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem;
  background: var(--ss-bg-card);
  border-radius: var(--ss-radius-md);
  border: 1px solid var(--ss-border-light);
  box-shadow: var(--ss-shadow-sm);
  transition: box-shadow var(--ss-transition);
}
.stat-card:hover { box-shadow: var(--ss-shadow-md); transform: translateY(-1px); }
.stat-card-link {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}
.stat-card-link:hover {
  border-color: #bcd2cb;
  background: #faf7f0;
}
.stat-card-link:hover .stat-label {
  color: var(--ss-text);
}
.stat-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--ss-radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}
.stat-icon.teal   { background: #bcd2cb; color: #2d4a43; }
.stat-icon.green  { background: #B8C9D4; color: #3B4F6B; }
.stat-icon.orange { background: #D4C4A8; color: #6B5B3E; }
.stat-icon.purple { background: #D0C4D8; color: #5B4B6B; }
.stat-icon.red    { background: #E2B8AE; color: #7B3B2C; }
.stat-value {
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.2;
  color: var(--ss-text);
}
.stat-label {
  font-size: 0.78rem;
  color: var(--ss-text-muted);
  margin-top: 2px;
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.55rem 1.1rem;
  font-size: 0.88rem;
  font-weight: 500;
  border-radius: var(--ss-radius-sm);
  border: none;
  transition: all var(--ss-transition);
  cursor: pointer;
  text-decoration: none;
  line-height: 1.4;
}
.btn:focus-visible { box-shadow: 0 0 0 3px rgba(25,25,24,0.15); }
.btn-primary { background: var(--ss-teal); color: #fff; }
.btn-primary:hover { background: var(--ss-teal-dark); color: #fff; }
.btn-success { background: #bcd2cb; border: 1px solid #9db8b0; color: #2d4a43; }
.btn-success:hover { background: rgba(188,210,203,0.65); border-color: #9db8b0; color: #2d4a43; }
.btn-danger { background: #b25d7a; border: 1px solid #944d67; color: #fff; }
.btn-danger:hover { background: rgba(178,93,122,0.72); border-color: #944d67; color: #fff; }
.btn-outline-danger { background: rgba(178,93,122,0.12); border: 1px solid #944d67; color: #b25d7a; transition: background 0.25s ease, border-color 0.25s ease; }
.btn-outline-danger:hover { background: rgba(178,93,122,0.28); border-color: #944d67; color: #b25d7a; }
.btn-outline-danger:active { background: rgba(178,93,122,0.38); }
.btn-light {
  background: #EDEAE5;
  border: 1px solid #D8D4CD;
  color: #3D3B37;
  transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}
.btn-light:hover {
  background: #E3DFD8;
  border-color: #CCC8C0;
  color: #2A2926;
}
.btn-light:active, .btn-light:focus-visible {
  background: #DAD6CE;
  border-color: #C2BEB6;
}
.btn-outline {
  background: transparent;
  border: 1px solid var(--ss-border);
  color: var(--ss-text);
}
.btn-outline:hover {
  background: var(--ss-accent-bg);
  border-color: var(--ss-teal-light);
  color: var(--ss-teal);
}
.btn-sm { padding: 0.35rem 0.75rem; font-size: 0.82rem; }
.btn-lg { padding: 0.75rem 1.5rem; font-size: 1rem; }

/* Claude-style outline-secondary: warm tones, pill shape, soft hover */
.btn-outline-secondary {
  --bs-btn-color: var(--ss-text, #1A1A1A);
  --bs-btn-border-color: #D4D0CA;
  --bs-btn-hover-color: var(--ss-text, #1A1A1A);
  --bs-btn-hover-bg: #F0EDE8;
  --bs-btn-hover-border-color: #C4BDB0;
  --bs-btn-active-color: var(--ss-text, #1A1A1A);
  --bs-btn-active-bg: #EDE8E0;
  --bs-btn-active-border-color: #B8B0A2;
  --bs-btn-active-shadow: none;
  --bs-btn-focus-shadow-rgb: 25, 25, 24;
  --bs-btn-disabled-color: #9B9B9B;
  --bs-btn-disabled-border-color: #E8E5E0;
  --bs-btn-disabled-bg: transparent;
  border-radius: 9999px;
  font-weight: 500;
  transition: all 200ms cubic-bezier(0.4, 0, 0.2, 1);
}
.btn-outline-secondary:focus-visible {
  box-shadow: 0 0 0 3px rgba(25, 25, 24, 0.12);
}

/* ── Forms ── */
.form-group { margin-bottom: 1rem; }
.form-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 0.35rem;
  color: var(--ss-text);
}
.form-control {
  width: 100%;
  padding: 0.6rem 0.85rem;
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius-sm);
  background: var(--ss-bg-card);
  color: var(--ss-text);
  transition: border-color var(--ss-transition), box-shadow var(--ss-transition);
}
.form-control:focus {
  outline: none;
  border-color: var(--ss-teal);
  box-shadow: 0 0 0 3px rgba(25,25,24,0.1);
}
.form-control::placeholder { color: var(--ss-text-muted); }
select.form-control { appearance: auto; }
textarea.form-control { resize: vertical; min-height: 80px; }

/* ── Tables ── */
.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
table.table {
  width: 100%;
  border-collapse: collapse;
}
table.table th {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--ss-text-muted);
  padding: 0.65rem 0.85rem;
  border-bottom: 1px solid var(--ss-border);
  text-align: left;
  white-space: nowrap;
}
table.table td {
  padding: 0.65rem 0.85rem;
  border-bottom: 1px solid var(--ss-border-light);
  font-size: 0.88rem;
  vertical-align: middle;
}
table.table tr { transition: background var(--ss-transition); }
table.table tr:hover { background: var(--ss-accent-bg); }
table.table tr:last-child td { border-bottom: none; }

/* ── Badges ── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.6rem;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 50px;
  white-space: nowrap;
}
.badge-pending { background: #D4C4A8; color: #6B5B3E; }
.badge-success { background: #bcd2cb; color: #2d4a43; }
.badge-refused { background: #E2B8AE; color: #7B3B2C; }
.badge-info    { background: #B8C9D4; color: #3B4F6B; }
.badge-purple  { background: #D0C4D8; color: #5B4B6B; }
.badge.bg-success { background-color: #bcd2cb !important; color: #2d4a43 !important; }
.badge.bg-secondary { background-color: #EDEAE5 !important; color: #3D3B37 !important; }

/* ── Info notice (style image) ── */
.info-notice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1.25rem;
  background: var(--ss-bg);
  border: 1px solid var(--ss-border-light);
  border-radius: var(--ss-radius-lg);
  font-size: 0.88rem;
  color: var(--ss-text);
}

/* ── Bootstrap alert overrides ── */
.alert {
  border-radius: var(--ss-radius-lg) !important;
  border: 1px solid transparent;
  box-shadow: none !important;
  font-size: 0.88rem;
  padding: 0.85rem 1.25rem;
}
.alert-info    { background: #EBF5FB; border-color: #C8E6F8; color: #1A6DA3; }
.alert-success { background: #EAF7EF; border-color: #B8E6CB; color: #166535; }
.alert-warning { background: #FEF9EC; border-color: #F8E4B0; color: #92600A; }
.alert-danger  { background: #FEF0EF; border-color: #FACBC8; color: #9B1C1C; }
.alert-secondary { background: var(--ss-bg); border-color: var(--ss-border-light); color: var(--ss-text-secondary); }

/* ── Planning grid ── */
.planning-grid {
  display: grid;
  grid-template-columns: 180px repeat(7, 1fr);
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius-md);
  overflow: hidden;
  background: var(--ss-bg-card);
}
.planning-cell {
  padding: 0.5rem;
  border-right: 1px solid var(--ss-border-light);
  border-bottom: 1px solid var(--ss-border-light);
  min-height: 50px;
  font-size: 0.82rem;
}
.planning-cell:last-child { border-right: none; }
.planning-cell.header {
  background: var(--ss-bg);
  color: var(--ss-text);
  font-weight: 600;
  font-size: 0.78rem;
  text-align: center;
  padding: 0.6rem 0.5rem;
  border-bottom: 1px solid var(--ss-border);
}
.planning-cell.name-col {
  background: var(--ss-bg);
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.planning-cell .shift-badge {
  display: inline-block;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-size: 0.72rem;
  font-weight: 600;
  color: #fff;
}
.planning-cell .shift-time {
  font-size: 0.68rem;
  color: var(--ss-text-muted);
}
.planning-module-header {
  grid-column: 1 / -1;
  background: var(--ss-bg);
  padding: 0.5rem 0.75rem;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--ss-text);
  border-bottom: 1px solid var(--ss-border);
}

/* ── Login page ── */
/* ── Login (Claude-style) ── */
.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #EEECE7;
  padding: 1.5rem;
}
.login-card {
  width: 100%;
  max-width: 400px;
  background: #fff;
  border: none;
  border-radius: 2rem;
  box-shadow: 0 2px 8px rgba(0,0,0,.04), 0 0 0 1px rgba(0,0,0,.04);
  padding: 2.5rem 2.25rem 2rem;
}
.login-header {
  text-align: center;
  margin-bottom: 2rem;
}
.login-logo {
  width: 48px; height: 48px; margin: 0 auto 14px;
  background: linear-gradient(135deg, #D4A574, #C4956A);
  color: #fff; font-size: 1.4rem; font-weight: 700;
  border-radius: 12px; display: flex; align-items: center; justify-content: center;
  letter-spacing: -0.02em;
}
.login-logo-img {
  width: 64px; height: 64px; object-fit: contain; margin: 0 auto 14px; display: block;
  border-radius: 12px;
}
.login-header h1 {
  font-size: 1.35rem; font-weight: 600; color: #1a1a1a;
  margin: 0 0 4px; letter-spacing: -0.01em;
}
.login-header p {
  color: #8B8680; font-size: 0.88rem; margin: 0;
}
.login-error {
  background: #FEF2F2; color: #DC2626;
  padding: 0.6rem 0.85rem; border-radius: 10px;
  font-size: 0.84rem; margin-bottom: 1rem; display: none;
  border: 1px solid #FECACA;
}
.login-field {
  margin-bottom: 1.1rem;
}
.login-field label {
  display: block; font-size: 0.82rem; font-weight: 500;
  color: #6B6560; margin-bottom: 5px;
}
.login-field input {
  width: 100%; padding: 10px 14px; font-size: 0.92rem;
  border: 1px solid #E0DDD8; border-radius: 10px;
  background: #FAFAF8; color: #1a1a1a;
  outline: none; transition: border-color .2s, box-shadow .2s;
}
.login-field input::placeholder { color: #C4C0BA; }
.login-field input:focus {
  border-color: #C4956A; background: #fff;
  box-shadow: 0 0 0 3px rgba(196,149,106,.12);
}
.login-submit {
  width: 100%; padding: 11px 20px; margin-top: 6px;
  font-size: 0.92rem; font-weight: 500;
  background: #1a1a1a; color: #fff; border: none;
  border-radius: 10px; cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  transition: background .2s, transform .1s;
}
.login-submit:hover { background: #333; }
.login-submit:active { transform: scale(0.985); }
.login-footer { text-align: center; margin-top: 1.1rem; }
.login-footer a {
  font-size: 0.82rem; color: #8B8680; text-decoration: none;
  transition: color .2s;
}
.login-footer a:hover { color: #1a1a1a; }
.login-brand {
  text-align: center; margin-top: 1.5rem; padding-top: 1.1rem;
  border-top: 1px solid #F0EDE8; font-size: 0.72rem;
  color: #B5B0AA; letter-spacing: 0.02em;
}

/* ── Calendar mini ── */
.calendar-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}
.calendar-nav h3 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 600;
  text-transform: capitalize;
}
.calendar-nav .btn { padding: 0.4rem 0.8rem; }

/* ── Toast ── */
.toast-container {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  padding: 0.75rem 1.5rem;
  background: var(--ss-text);
  color: #fff;
  border-radius: var(--ss-radius-lg);
  font-size: 0.88rem;
  font-weight: 500;
  box-shadow: var(--ss-shadow-lg);
  z-index: 9999;
  opacity: 0;
  transition: all 0.3s ease;
  pointer-events: none;
}
.toast-container.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ── Alert toast (top-right, with progress bar) ── */
.ss-alert-toast-wrap {
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: .5rem;
  pointer-events: none;
  max-width: 400px;
  width: calc(100vw - 2rem);
}
.ss-alert-toast {
  pointer-events: auto;
  display: flex;
  align-items: flex-start;
  gap: .75rem;
  padding: .85rem 1rem;
  border-radius: 12px;
  box-shadow: 0 8px 30px rgba(0,0,0,.15);
  transform: translateX(110%);
  opacity: 0;
  transition: transform .35s cubic-bezier(.22,1,.36,1), opacity .35s ease;
  position: relative;
  overflow: hidden;
}
.ss-alert-toast.show {
  transform: translateX(0);
  opacity: 1;
}
.ss-alert-toast.removing {
  transform: translateX(110%);
  opacity: 0;
}
.ss-alert-toast--danger { background: #fef2f2; border: 1px solid #fecaca; color: #991b1b; }
.ss-alert-toast--info   { background: #f0fdf4; border: 1px solid #bbf7d0; color: #166534; }
.ss-alert-toast--warn   { background: #fffbeb; border: 1px solid #fde68a; color: #854d0e; }

.ss-alert-toast-icon {
  width: 36px; height: 36px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; flex-shrink: 0;
}
.ss-alert-toast--danger .ss-alert-toast-icon { background: #fee2e2; color: #dc2626; }
.ss-alert-toast--info   .ss-alert-toast-icon { background: #dcfce7; color: #16a34a; }
.ss-alert-toast--warn   .ss-alert-toast-icon { background: #fef3c7; color: #d97706; }

.ss-alert-toast-body { flex: 1; min-width: 0; }
.ss-alert-toast-title { font-weight: 700; font-size: .85rem; margin-bottom: .15rem; }
.ss-alert-toast-msg { font-size: .78rem; opacity: .85; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.ss-alert-toast-close {
  background: none; border: none; cursor: pointer;
  color: inherit; opacity: .5; font-size: .85rem;
  padding: 2px; transition: opacity .15s; flex-shrink: 0;
}
.ss-alert-toast-close:hover { opacity: 1; }

.ss-alert-toast-progress {
  position: absolute;
  bottom: 0; left: 0;
  height: 3px;
  border-radius: 0 0 12px 12px;
  transition: width linear;
}
.ss-alert-toast--danger .ss-alert-toast-progress { background: #dc2626; }
.ss-alert-toast--info   .ss-alert-toast-progress { background: #16a34a; }
.ss-alert-toast--warn   .ss-alert-toast-progress { background: #d97706; }

/* ── Empty states ── */
.empty-state {
  text-align: center;
  padding: 3rem 1.5rem;
  color: var(--ss-text-muted);
}
.empty-state i {
  font-size: 3rem;
  margin-bottom: 1rem;
  display: block;
  opacity: 0.4;
}
.empty-state p { margin: 0; font-size: 0.95rem; }

/* ── Loading ── */
.spinner {
  display: inline-block;
  width: 1.2rem;
  height: 1.2rem;
  border: 2px solid var(--ss-border);
  border-top-color: var(--ss-teal);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.page-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4rem;
}

/* ── Modal overrides (Bootstrap) ── */
.modal-content {
  border: none;
  border-radius: 2rem;
  box-shadow: var(--ss-shadow-lg);
}
.modal-header { border-bottom: 1px solid var(--ss-border); }
.modal-footer { border-top: 1px solid var(--ss-border); }

/* ── Toggle switch — only inside .form-switch ── */
.form-switch .form-check-input {
  width: 2rem;
  height: 1.1em;
  border-radius: 20px;
  border: 2px solid var(--ss-border);
  background-color: var(--ss-bg);
  background-image: none;
  transition: all var(--ss-transition);
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  position: relative;
}
.form-switch .form-check-input::before {
  content: '';
  position: absolute;
  width: 0.85em;
  height: 0.85em;
  border-radius: 50%;
  background: var(--ss-text-muted);
  top: 50%;
  left: 2px;
  transform: translateY(-50%);
  transition: all var(--ss-transition);
}
.form-switch .form-check-input:checked {
  background-color: var(--ss-teal);
  border-color: var(--ss-teal);
}
.form-switch .form-check-input:checked::before {
  background: #fff;
  left: calc(100% - 0.85em - 2px);
}
.form-switch .form-check-input:focus { box-shadow: 0 0 0 3px rgba(25,25,24,0.15); }

/* ── Normal checkbox — square with check mark (small) ── */
.form-check:not(.form-switch) .form-check-input[type="checkbox"],
input[type="checkbox"]:not(.form-check-input) {
  width: 15px;
  height: 15px;
  min-width: 15px;
  border-radius: 3px;
  border: 1.5px solid var(--ss-border);
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  position: relative;
  transition: all 0.2s;
  vertical-align: middle;
  background-color: var(--ss-bg, #fff);
  background-image: none;
  flex-shrink: 0;
  margin-top: 0;
}
.form-check:not(.form-switch) .form-check-input[type="checkbox"]:checked,
input[type="checkbox"]:not(.form-check-input):checked {
  background: var(--ss-teal);
  border-color: var(--ss-teal);
}
.form-check:not(.form-switch) .form-check-input[type="checkbox"]:checked::after,
input[type="checkbox"]:not(.form-check-input):checked::after {
  content: '✓';
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
.form-check:not(.form-switch) .form-check-input[type="checkbox"]:hover,
input[type="checkbox"]:not(.form-check-input):hover {
  border-color: var(--ss-teal);
}
.form-check:not(.form-switch) .form-check-input[type="checkbox"]:focus {
  box-shadow: 0 0 0 3px rgba(25,25,24,0.1);
  outline: none;
}
.form-check:not(.form-switch) .form-check-input[type="checkbox"]::before {
  display: none;
}

/* ── Normal radio — circle with dot (small) ── */
.form-check:not(.form-switch) .form-check-input[type="radio"] {
  width: 15px;
  height: 15px;
  min-width: 15px;
  border-radius: 50%;
  border: 1.5px solid var(--ss-border);
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  position: relative;
  transition: all 0.2s;
  vertical-align: middle;
  background-color: var(--ss-bg, #fff);
  background-image: none;
  flex-shrink: 0;
  margin-top: 0;
}
.form-check:not(.form-switch) .form-check-input[type="radio"]:checked {
  background: var(--ss-bg, #fff);
  border-color: var(--ss-teal);
}
.form-check:not(.form-switch) .form-check-input[type="radio"]:checked::after {
  content: '';
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ss-teal);
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
.form-check:not(.form-switch) .form-check-input[type="radio"]:hover {
  border-color: var(--ss-teal);
}
.form-check:not(.form-switch) .form-check-input[type="radio"]:focus {
  box-shadow: 0 0 0 3px rgba(25,25,24,0.1);
  outline: none;
}
.form-check:not(.form-switch) .form-check-input[type="radio"]::before {
  display: none;
}

/* ── Form check alignment ── */
.form-check:not(.form-switch) {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  padding-left: 0;
  margin-bottom: 0;
}
.form-check:not(.form-switch) .form-check-input {
  float: none;
  margin-left: 0;
  margin-top: 0;
  margin-right: 0;
}
.form-check:not(.form-switch) .form-check-label {
  line-height: 1.4;
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--ss-border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--ss-text-muted); }

/* ── Selection ── */
::selection { background: rgba(25,25,24,0.15); color: var(--ss-text); }

/* ── Responsive ── */
@media (max-width: 768px) {
  #app-content { padding: 1rem; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .planning-grid {
    grid-template-columns: 120px repeat(7, minmax(80px, 1fr));
    font-size: 0.78rem;
  }
  .planning-cell { padding: 0.35rem; }
}

@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr; }
  .stat-card { padding: 1rem; }
  .stat-value { font-size: 1.25rem; }
}

/* ── Utilities ── */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-muted { color: var(--ss-text-muted); }
.text-success { color: var(--ss-green); }
.text-danger { color: var(--ss-red); }
.text-warning { color: var(--ss-orange); }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.d-flex { display: flex; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.flex-wrap { flex-wrap: wrap; }
.hidden { display: none !important; }

/* ══════════════════════════════════════
   SPLIT VIEW — PV & Sondages
   ══════════════════════════════════════ */
.split-view {
  display: flex;
  height: calc(100vh - var(--ss-nav-h) - 3rem);
  gap: 0;
  background: var(--ss-bg);
}
.split-view-left {
  flex: 0 0 35%;
  display: flex;
  flex-direction: column;
  background: var(--ss-bg-card);
  border-right: 1px solid var(--ss-border);
  border-radius: var(--ss-radius-lg) 0 0 var(--ss-radius-lg);
  overflow: hidden;
}
.split-view-right {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: var(--ss-bg);
  overflow: hidden;
  border-top: 1px solid var(--ss-border);
  border-right: 1px solid var(--ss-border);
  border-bottom: 1px solid var(--ss-border);
  border-radius: 0 var(--ss-radius-lg) var(--ss-radius-lg) 0;
}
.split-view-header {
  padding: 15px;
  border-bottom: 1px solid var(--ss-border-light);
}
.split-view-header h4 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
}
.split-view-header small {
  color: var(--ss-text-muted);
}
.split-view-list {
  flex: 1;
  overflow-y: auto;
}
.split-view-detail {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}
.split-view-footer {
  padding: 10px;
  border-top: 1px solid var(--ss-border-light);
  text-align: center;
  font-size: 0.85rem;
  color: var(--ss-text-muted);
}
.split-view-empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--ss-text-muted);
}
.split-view-empty i {
  font-size: 3rem;
  opacity: 0.3;
  display: block;
  margin-bottom: 10px;
}
.split-view-loading {
  padding: 20px;
  text-align: center;
  color: var(--ss-text-muted);
}
.split-view-search {
  margin-bottom: 8px;
}
.split-view-search .input-group-text {
  background: white;
  border-right: none;
}
.split-view-search .form-control {
  border-left: none;
}

/* ── List items (shared) ── */
.split-list-item {
  padding: 12px 15px;
  border-bottom: 1px solid var(--ss-border-light);
  cursor: pointer;
  transition: background var(--ss-transition);
}
.split-list-item:hover {
  background: var(--ss-accent-bg);
}
.split-list-item.selected {
  background: var(--ss-accent-bg);
  border-left: 4px solid var(--ss-navy);
  padding-left: 11px;
}
.split-list-item-title {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--ss-text);
  margin-bottom: 2px;
}
.split-list-item-meta {
  font-size: 0.8rem;
  color: var(--ss-text-muted);
  display: flex;
  justify-content: space-between;
}

/* ── Sondage choice items (clickable lines) ── */
.sondage-choice-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border: 2px solid var(--ss-border);
  border-radius: var(--ss-radius-sm);
  margin-bottom: 6px;
  cursor: pointer;
  transition: all var(--ss-transition);
  background: var(--ss-bg-card);
  user-select: none;
}
.sondage-choice-item:hover {
  background: var(--ss-accent-bg);
}
.sondage-choice-item.chosen {
  border-color: var(--ss-text);
  background: var(--ss-accent-bg);
}
.sondage-choice-item .choice-label {
  font-size: 0.9rem;
  color: var(--ss-text);
}
.sondage-choice-item .choice-check {
  font-size: 1rem;
  color: var(--ss-text);
  opacity: 0;
  transition: opacity var(--ss-transition);
}
.sondage-choice-item.chosen .choice-check {
  opacity: 1;
}
.sondage-choice-item[aria-disabled="true"] {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Sondage detail container */
.sondage-detail-wrap {
  max-width: 700px;
  margin: 0 auto;
}
.sondage-detail-title {
  font-weight: 600;
  margin-bottom: 4px;
}
.sondage-detail-meta {
  color: var(--ss-text-muted);
  font-size: 0.85rem;
  margin-bottom: 15px;
}
.sondage-description-box {
  background: var(--ss-bg-card);
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius-sm);
  padding: 12px;
  margin-bottom: 15px;
  color: var(--ss-text-secondary);
}
.sondage-q-card {
  background: var(--ss-bg-card);
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius-sm);
  padding: 16px;
  margin-bottom: 12px;
}
.sondage-q-card .q-label {
  font-weight: 600;
  margin-bottom: 10px;
}
.sondage-q-type-badge {
  font-weight: normal;
  font-size: 0.7rem;
}
.sondage-submit-wrap {
  text-align: center;
  margin-top: 15px;
}
.sondage-status-badge {
  font-size: 0.7rem;
}

/* ── Email module ── */

/* Split-view layout */
.adm-email-split {
  display: flex;
  height: calc(100vh - var(--ss-nav-h) - 3rem);
  gap: 0;
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius-lg);
  overflow: hidden;
  background: var(--ss-bg-card);
  box-shadow: var(--ss-shadow-sm);
}
.adm-email-left {
  flex: 0 0 360px;
  max-width: 400px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: var(--ss-bg);
  border-right: 1px solid var(--ss-border);
  overflow: hidden;
}
.adm-email-right {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--ss-bg-card);
}
.adm-email-left-header {
  padding: 14px 16px;
  border-bottom: 1px solid var(--ss-border);
  overflow: hidden;
}
.adm-email-left-footer {
  padding: 14px;
  border-top: 1px solid var(--ss-border);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 18px;
  background: var(--ss-bg);
}
.email-pag-arrow {
  width: 38px;
  height: 38px;
  border-radius: var(--ss-radius-sm);
  border: 1.5px solid var(--ss-border);
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--ss-text);
  font-size: 1rem;
  transition: border-color .2s, background .2s, opacity .2s;
}
.email-pag-arrow:hover:not(:disabled) {
  border-color: var(--ss-text);
  background: var(--ss-bg-card);
}
.email-pag-arrow:disabled {
  opacity: .3;
  cursor: default;
}
.email-pag-dots {
  display: flex;
  align-items: center;
  gap: 10px;
}
.email-pag-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ss-border);
  transition: background .2s, transform .2s;
  cursor: pointer;
}
.email-pag-dot.active {
  background: var(--ss-text);
  transform: scale(1.25);
}
.email-pag-dot:hover:not(.active) {
  background: var(--ss-text-muted);
}
.adm-email-list {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
}
.adm-email-empty {
  text-align: center;
  padding: 30px 20px;
  color: var(--ss-text-muted);
}

/* Email list items */
.adm-email-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--ss-border-light);
  cursor: pointer;
  transition: background var(--ss-transition);
}
.adm-email-item:hover {
  background: var(--ss-accent-bg);
}
.adm-email-item.selected {
  background: var(--ss-accent-bg);
  border-left: 3px solid var(--ss-teal);
  padding-left: 11px;
}
.adm-email-item.unread .adm-email-item-sender,
.adm-email-item.unread .adm-email-item-subject {
  font-weight: 700;
}
.adm-email-item-avatar {
  width: 34px;
  height: 34px;
  min-width: 34px;
  border-radius: 50%;
  background: var(--ss-bg);
  color: var(--ss-text);
  border: 1px solid var(--ss-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  flex-shrink: 0;
  position: relative;
}
.adm-email-item.unread .adm-email-item-avatar::after {
  content: '';
  position: absolute;
  top: -1px;
  right: -1px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ss-teal);
  border: 2px solid var(--ss-bg);
}
}
.adm-email-item-content {
  flex: 1;
  min-width: 0;
}
.adm-email-item-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1px;
}
.adm-email-item-sender {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--ss-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
  min-width: 0;
}
.adm-email-item-date {
  font-size: 0.72rem;
  color: var(--ss-text-muted);
  white-space: nowrap;
  flex-shrink: 0;
  margin-left: 8px;
}
.adm-email-item-subject {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--ss-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 1px;
}
.adm-email-item-preview {
  font-size: 0.75rem;
  color: var(--ss-text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Email detail */
.adm-email-detail {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.adm-email-detail-header {
  padding: 14px 20px;
  border-bottom: 1px solid var(--ss-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 54px;
}
.adm-email-detail-subject {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ss-text);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
  min-width: 0;
  line-height: 1.3;
}
.adm-email-detail-actions {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}
.adm-email-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--ss-bg-card);
  color: var(--ss-text);
  border: 1px solid var(--ss-border);
  border-radius: 10px;
  padding: 6px 16px;
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}
.adm-email-btn:hover {
  background: var(--ss-border-light);
  border-color: var(--ss-border);
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.06);
}
.adm-email-btn:active {
  transform: scale(0.97);
}
.adm-email-btn i {
  font-size: 0.85rem;
}
.adm-email-detail-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px 24px;
}
.adm-email-detail-sender {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--ss-border-light);
}
.adm-email-detail-avatar {
  width: 40px;
  height: 40px;
  min-width: 40px;
  border-radius: 50%;
  background: var(--ss-bg);
  color: var(--ss-text);
  border: 1px solid var(--ss-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.5px;
}
.adm-email-detail-sender-info {
  flex: 1;
  min-width: 0;
}
.adm-email-detail-sender-name {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--ss-text);
  margin-bottom: 1px;
}
.adm-email-detail-sender-recipients {
  font-size: 0.8rem;
  color: var(--ss-text-muted);
  line-height: 1.45;
}
.adm-email-detail-date {
  font-size: 0.78rem;
  color: var(--ss-text-muted);
  white-space: nowrap;
  flex-shrink: 0;
  padding-top: 2px;
}
.adm-email-detail-content {
  background: var(--ss-bg);
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius-sm);
  padding: 20px 22px;
  margin-bottom: 16px;
}
.adm-email-detail-text {
  font-size: 0.9rem;
  line-height: 1.7;
  color: var(--ss-text);
  word-break: break-word;
}
.adm-email-detail-text p:last-child {
  margin-bottom: 0;
}

/* Email responsive */
@media (max-width: 991.98px) {
  .adm-email-left { flex: 0 0 280px; max-width: 300px; }
}
@media (max-width: 767.98px) {
  .adm-email-split {
    flex-direction: column;
    height: auto;
  }
  .adm-email-left {
    flex: none;
    max-width: none;
    max-height: 40vh;
    border-right: none;
    border-bottom: 1px solid var(--ss-border);
  }
  .adm-email-right {
    min-height: 50vh;
  }
}

/* Tab bar — pill toggle with sliding indicator */
.email-tabs {
  display: flex;
  position: relative;
  background: var(--ss-border-light);
  border-radius: 10px;
  padding: 3px;
  gap: 0;
}
.email-tabs-slider {
  position: absolute;
  top: 3px;
  left: 3px;
  width: calc(50% - 3px);
  height: calc(100% - 6px);
  background: var(--ss-bg-card);
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.04);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 0;
  pointer-events: none;
}
.email-tabs-slider.right {
  transform: translateX(100%);
}
.email-tab {
  flex: 1;
  background: none;
  border: none;
  padding: 8px 12px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--ss-text-muted);
  border-radius: 8px;
  cursor: pointer;
  transition: color 0.25s ease;
  position: relative;
  z-index: 1;
  text-align: center;
}
.email-tab:hover {
  color: var(--ss-text);
}
.email-tab.active {
  color: var(--ss-text);
  font-weight: 600;
}
.email-unread-badge {
  display: none;
  font-size: 0.7rem;
  background: var(--ss-red);
  color: #fff;
  border-radius: 50px;
  padding: 1px 6px;
  margin-left: 4px;
  vertical-align: middle;
  font-weight: 600;
}

/* Email list items (legacy — kept for backward compat) */

/* Attachments */
.email-detail-attachments {
  border-top: 1px solid var(--ss-border-light);
  padding-top: 14px;
  margin-top: 4px;
}
.email-detail-att-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ss-text-secondary);
  margin-bottom: 8px;
}
.email-att-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.email-att-grid .att-preview-card {
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}
.email-att-grid .att-preview-card:hover {
  text-decoration: none;
  color: inherit;
}
.email-att-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--ss-bg-card);
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius-sm);
  padding: 6px 10px;
  margin: 3px;
  font-size: 0.82rem;
  color: var(--ss-text);
  text-decoration: none;
  transition: all var(--ss-transition);
}
.email-att-item:hover {
  background: var(--ss-accent-bg);
  color: var(--ss-teal);
}

/* Thread */
.email-thread {
  margin-top: 20px;
  border-top: 1px solid var(--ss-border-light);
  padding-top: 14px;
}
.email-thread-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ss-text-muted);
  margin-bottom: 10px;
}
.email-thread-item {
  border: 1px solid var(--ss-border-light);
  border-radius: var(--ss-radius-sm);
  padding: 12px 14px;
  margin-bottom: 8px;
  background: var(--ss-bg-card);
}
.email-thread-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
  font-size: 0.82rem;
}
.email-thread-body {
  font-size: 0.85rem;
  color: var(--ss-text-secondary);
  line-height: 1.55;
  max-height: 120px;
  overflow-y: auto;
}

/* Compose — Gmail-style bottom-right panel */
.compose-panel {
  position: fixed;
  bottom: 0;
  right: 24px;
  width: 580px;
  max-width: calc(100vw - 48px);
  background: var(--ss-bg-card);
  border: 1px solid var(--ss-border);
  border-bottom: none;
  border-radius: var(--ss-radius-md) var(--ss-radius-md) 0 0;
  box-shadow: 0 -4px 24px rgba(0,0,0,0.12), 0 -1px 6px rgba(0,0,0,0.06);
  display: none;
  flex-direction: column;
  z-index: 1050;
  transform: translateY(100%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.compose-panel.open {
  display: flex;
  transform: translateY(0);
}
.compose-panel.minimized .compose-panel-body,
.compose-panel.minimized .compose-panel-footer {
  display: none;
}
.compose-panel.fullscreen {
  width: 100%;
  max-width: 100vw;
  height: 100vh;
  right: 0;
  border-radius: 0;
}
.compose-panel.fullscreen .compose-panel-header {
  border-radius: 0;
}
.compose-panel.fullscreen .compose-panel-body {
  max-height: none;
  flex: 1;
}
.compose-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: var(--ss-teal);
  color: #fff;
  border-radius: var(--ss-radius-md) var(--ss-radius-md) 0 0;
  cursor: pointer;
  user-select: none;
}
.compose-panel-title {
  font-size: 0.88rem;
  font-weight: 600;
}
.compose-panel-header-actions {
  display: flex;
  gap: 4px;
}
.compose-panel-header-btn {
  background: none;
  border: none;
  color: rgba(255,255,255,0.7);
  padding: 2px 6px;
  cursor: pointer;
  border-radius: 4px;
  font-size: 0.85rem;
  line-height: 1;
  transition: all 0.15s;
}
.compose-panel-header-btn:hover {
  color: #fff;
  background: rgba(255,255,255,0.15);
}
.compose-panel-body {
  flex: 1;
  overflow-y: auto;
  padding: 10px 14px;
  max-height: 50vh;
}
.compose-field {
  margin-bottom: 8px;
}
.compose-field label {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--ss-text-secondary);
  margin-bottom: 2px;
  display: block;
}
.compose-panel-editor {
  min-height: 160px;
  padding: 10px 12px;
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius-sm);
  font-size: 0.88rem;
  line-height: 1.55;
  background: #fff;
  outline: none;
  transition: border-color var(--ss-transition);
  overflow-y: auto;
  max-height: 30vh;
}
.compose-panel-editor:focus {
  border-color: var(--ss-teal);
  box-shadow: 0 0 0 2px rgba(25, 25, 24, 0.06);
}
/* Tiptap editor inside compose panel */
.compose-editor-wrap {
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius-sm);
  overflow: hidden;
}
.compose-editor-wrap:focus-within {
  border-color: var(--ss-teal);
  box-shadow: 0 0 0 2px rgba(25,25,24,0.06);
}
.compose-editor-wrap .zs-ed-toolbar {
  padding: 3px 4px;
  gap: 1px;
  background: var(--ss-bg);
  border-bottom: 1px solid var(--ss-border-light);
}
.compose-editor-wrap .zs-ed-btn {
  width: 26px;
  height: 26px;
  font-size: .8rem;
}
.compose-editor-wrap .zs-ed-content {
  min-height: 120px;
  max-height: 30vh;
}
.compose-editor-wrap .zs-ed-content .ProseMirror {
  min-height: 120px;
  padding: 8px 10px;
  font-size: .88rem;
  line-height: 1.55;
}
.compose-panel-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  border-top: 1px solid var(--ss-border-light);
}
.compose-panel-footer-right {
  display: flex;
  align-items: center;
  gap: 4px;
}
.compose-panel-footer-btn {
  background: none;
  border: none;
  color: var(--ss-text-muted);
  padding: 6px 8px;
  cursor: pointer;
  border-radius: 6px;
  font-size: 1rem;
  line-height: 1;
  transition: all 0.15s;
}
.compose-panel-footer-btn:hover {
  color: var(--ss-text);
  background: var(--ss-accent-bg);
}
.compose-panel-delete:hover {
  color: var(--ss-red);
  background: rgba(220, 38, 38, 0.08);
}
@media (max-width: 575.98px) {
  .compose-panel {
    right: 0;
    width: 100vw;
    max-width: 100vw;
    border-radius: var(--ss-radius-md) var(--ss-radius-md) 0 0;
  }
  .compose-panel-header {
    border-radius: var(--ss-radius-md) var(--ss-radius-md) 0 0;
  }
}

/* ── Attachment preview cards in compose ── */
.email-attachments-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}
.att-preview-card {
  position: relative;
  width: 110px;
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius-sm);
  background: var(--ss-bg);
  overflow: hidden;
  transition: box-shadow .15s;
}
.att-preview-card:hover { box-shadow: 0 2px 8px rgba(0,0,0,.08); }
.att-preview-remove {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: none;
  background: rgba(0,0,0,.45);
  color: #fff;
  font-size: .75rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  transition: opacity .15s;
  z-index: 1;
}
.att-preview-card:hover .att-preview-remove { opacity: 1; }
.att-preview-thumb {
  width: 100%;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--ss-bg-card);
}
.att-preview-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.att-preview-icon {
  font-size: 2rem;
}
.att-icon-pdf  { color: #DC2626; }
.att-icon-word { color: #2B579A; }
.att-icon-excel { color: #217346; }
.att-icon-txt  { color: #6B7280; }
.att-icon-img  { color: #7C3AED; }
.att-preview-info {
  padding: 4px 6px;
  border-top: 1px solid var(--ss-border-light);
}
.att-preview-name {
  display: block;
  font-size: .7rem;
  font-weight: 500;
  color: var(--ss-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.att-preview-size {
  font-size: .65rem;
  color: var(--ss-text-muted);
}

/* Delete button — same style as adm-email-btn but red on hover */
.adm-email-btn-delete {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--ss-bg-card);
  color: var(--ss-text);
  border: 1px solid var(--ss-border);
  border-radius: 10px;
  padding: 6px 16px;
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}
.adm-email-btn-delete:hover {
  background: rgba(220, 38, 38, 0.08);
  border-color: rgba(220, 38, 38, 0.3);
  color: var(--ss-red);
}
.adm-email-btn-delete:active {
  transform: scale(0.97);
}
.adm-email-btn-delete i {
  font-size: 0.85rem;
}

/* Contact tags */
.email-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.email-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--ss-accent-bg);
  border: 1px solid var(--ss-border);
  border-radius: 50px;
  padding: 3px 10px;
  font-size: 0.8rem;
  color: var(--ss-text);
}
.email-tag-remove {
  border: none;
  background: none;
  padding: 0 2px;
  font-size: 0.9rem;
  line-height: 1;
  cursor: pointer;
  color: var(--ss-text-muted);
}
.email-tag-remove:hover {
  color: var(--ss-red);
}

/* Pending file previews */
.email-pending-file {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--ss-accent-bg);
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius-sm);
  padding: 4px 8px;
  margin: 3px;
  font-size: 0.82rem;
}
.email-remove-file {
  padding: 0 !important;
  font-size: 1rem;
}

/* Quote / Forward blocks */
.email-quote {
  border-left: 3px solid var(--ss-border);
  padding-left: 12px;
  margin-left: 4px;
  color: var(--ss-text-secondary);
  font-size: 0.88rem;
}
.email-quote-header {
  font-size: 0.8rem;
  color: var(--ss-text-muted);
  font-style: italic;
  margin-bottom: 6px;
}
.email-forward-header {
  border-top: 1px solid var(--ss-border);
  padding-top: 10px;
  margin-top: 10px;
  font-size: 0.85rem;
  color: var(--ss-text-secondary);
  line-height: 1.6;
}

/* ── Split-view panel cards (PV & Sondage) ── */
.split-panel-card {
  background: var(--ss-bg-card);
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius-md);
  box-shadow: var(--ss-shadow-sm);
}

@media (max-width: 768px) {
  .split-view {
    flex-direction: column;
    height: auto;
  }
  .split-view-left {
    flex: none;
    max-height: 40vh;
    border-right: none;
    border-bottom: 1px solid var(--ss-border);
    border-radius: var(--ss-radius-lg) var(--ss-radius-lg) 0 0;
  }
  .split-view-right {
    border: none;
    border-radius: 0 0 var(--ss-radius-lg) var(--ss-radius-lg);
  }
}

/* ── Changements — Layout ────────────────────────────────── */
.chg-hidden { display: none !important; }

/* Top row: calendar + list side by side */
.chg-top-row {
  display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem;
  margin-bottom: 1.25rem;
}
.chg-top-cal .card-body { padding-bottom: 0.5rem; }
.chg-top-list .card-body { padding: 0; }
.chg-top-list .chg-list-body { max-height: 420px; overflow-y: auto; }

.chg-cal-hint {
  font-size: 0.78rem; color: var(--ss-text-muted); text-align: center;
  padding: 0.5rem 0; display: flex; align-items: center; justify-content: center; gap: 0.3rem;
}

.chg-badge-inline {
  display: inline-block; padding: 2px 8px; border-radius: 4px;
  font-size: 0.74rem; font-weight: 700; color: #fff;
}

/* ── Slidedown ── */
.chg-slidedown {
  border: 1px solid var(--ss-border-light, #e5e7eb); border-radius: 12px;
  background: #fff; margin-bottom: 1.25rem; overflow: hidden;
  max-height: 2000px; opacity: 1;
  transition: max-height .4s ease, opacity .3s ease, margin .3s ease;
}
.chg-slide-closed {
  max-height: 0 !important; opacity: 0 !important;
  margin-bottom: 0 !important; border-color: transparent;
}
.chg-slide-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.75rem 1rem; border-bottom: 1px solid var(--ss-border-light, #e5e7eb);
  background: var(--ss-bg, #f5f3ee);
}
.chg-slide-title {
  font-size: 0.88rem; font-weight: 600;
  display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap;
}
.chg-slide-row {
  display: grid; grid-template-columns: 280px 1fr; gap: 0;
  min-height: 350px;
}
.chg-slide-left {
  border-right: 1px solid var(--ss-border-light, #e5e7eb);
  display: flex; flex-direction: column;
}
.chg-slide-search {
  position: relative; padding: 0.65rem 0.75rem;
  border-bottom: 1px solid var(--ss-border-light, #e5e7eb);
}
.chg-slide-search .chg-search-icon {
  position: absolute; left: 20px; top: 50%; transform: translateY(-50%);
  color: var(--ss-text-muted); font-size: 0.8rem;
}
.chg-slide-search .chg-search-input {
  padding-left: 2rem !important; font-size: 0.82rem;
}
.chg-slide-left .chg-colleague-list {
  flex: 1; max-height: none; overflow-y: auto; border: none; border-radius: 0;
}
.chg-slide-right { padding: 1rem; overflow-y: auto; }
.chg-slide-placeholder {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  height: 100%; gap: 0.75rem; color: var(--ss-text-muted); text-align: center;
}
.chg-slide-placeholder i { font-size: 2rem; opacity: 0.3; }
.chg-slide-placeholder span { font-size: 0.85rem; max-width: 240px; }

/* Colleague panel header in slide */
.chg-col-panel-header {
  display: flex; align-items: center; gap: 0.65rem;
  margin-bottom: 0.75rem; padding-bottom: 0.65rem;
  border-bottom: 1px solid var(--ss-border-light, #e5e7eb);
}
.chg-col-hint {
  font-size: 0.76rem; color: var(--ss-text-muted); text-align: center;
  margin-top: 0.5rem; display: flex; align-items: center; justify-content: center; gap: 0.3rem;
}
.chg-col-hint strong { color: var(--ss-teal); }
.chg-col-active { background: rgba(188,210,203,.2) !important; }

@media (max-width: 700px) {
  .chg-top-row { grid-template-columns: 1fr; }
  .chg-slide-row { grid-template-columns: 1fr; }
  .chg-slide-left { border-right: none; border-bottom: 1px solid var(--ss-border-light, #e5e7eb); max-height: 200px; }
}

/* ── Calendar ── */
.chg-cal-nav {
  display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.75rem;
}
.chg-cal-month {
  font-size: 0.95rem; font-weight: 700; min-width: 140px; text-align: center;
}
.chg-calendar { user-select: none; }
.chg-cal-header {
  display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px;
  margin-bottom: 2px;
}
.chg-cal-hcell {
  text-align: center; font-size: 0.7rem; font-weight: 700;
  color: var(--ss-text-muted); padding: 4px 0; text-transform: uppercase;
}
.chg-cal-body { display: flex; flex-direction: column; gap: 2px; }
.chg-cal-week { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }

.chg-cal-cell {
  position: relative; min-height: 58px; padding: 4px 5px;
  border: 1.5px solid transparent; border-radius: 8px;
  background: var(--ss-bg, #f9f8f5); transition: all .15s;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
}
.chg-cal-cell.chg-cal-empty { background: transparent; }
.chg-cal-cell.chg-cal-weekend { background: rgba(0,0,0,.02); }
.chg-cal-cell.chg-cal-today { background: rgba(0,0,0,.05); }
.chg-cal-cell.chg-cal-today .chg-cal-day {
  background: var(--ss-teal, #1a1a1a); color: #fff;
  border-radius: 50%; width: 18px; height: 18px;
  display: inline-flex; align-items: center; justify-content: center;
}
.chg-cal-cell.chg-cal-past { opacity: 0.4; pointer-events: none; }

.chg-cal-cell.chg-cal-has-shift,
.chg-cal-cell.chg-cal-clickable { cursor: pointer; }
.chg-cal-cell.chg-cal-has-shift:hover,
.chg-cal-cell.chg-cal-clickable:hover {
  border-color: var(--ss-teal, #1a1a1a); transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0,0,0,.08);
}
.chg-cal-cell.chg-cal-selected {
  border-color: var(--ss-teal, #1a1a1a);
  background: rgba(188,210,203,.25);
  box-shadow: 0 0 0 2px rgba(45,74,67,.15);
}

.chg-cal-day { font-size: 0.72rem; font-weight: 600; color: var(--ss-text-muted); }
.chg-cal-badge {
  display: inline-block; padding: 2px 7px; border-radius: 4px;
  font-size: 0.68rem; font-weight: 800; color: #fff; letter-spacing: .02em;
}
.chg-cal-module { font-size: 0.6rem; color: var(--ss-text-muted); font-weight: 500; }
.chg-cal-repos { font-size: 0.72rem; font-weight: 700; color: #999; }
.chg-cal-absence { font-size: 0.72rem; font-weight: 700; color: var(--ss-red, #c44); }

/* ── Colleague search ── */
.chg-search-wrap {
  position: relative; margin-bottom: 0.75rem;
}
.chg-search-icon {
  position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
  color: var(--ss-text-muted); font-size: 0.85rem;
}
.chg-search-input { padding-left: 2.2rem !important; }

.chg-colleague-list {
  max-height: 300px; overflow-y: auto;
  border: 1px solid var(--ss-border-light, #e5e7eb); border-radius: 8px;
}
.chg-col-item {
  display: flex; align-items: center; gap: 0.65rem;
  padding: 0.55rem 0.85rem; cursor: pointer;
  border-bottom: 1px solid var(--ss-border-light, #f0ede8);
  transition: background .15s;
}
.chg-col-item:last-child { border-bottom: none; }
.chg-col-item:hover { background: var(--ss-bg, #f5f3ee); }
.chg-col-avatar {
  width: 34px; height: 34px; border-radius: 50%; object-fit: cover; flex-shrink: 0;
}
.chg-col-avatar-initials {
  width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0;
  background: #B8C9D4; color: #3B4F6B;
  display: inline-flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 0.72rem;
}
.chg-col-info { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.chg-col-name { font-size: 0.86rem; font-weight: 600; }
.chg-col-meta { display: flex; align-items: center; gap: 0.35rem; flex-wrap: wrap; }
.chg-col-fonction {
  font-size: 0.66rem; font-weight: 600; padding: 1px 7px;
  border-radius: 4px; background: #B8C9D4; color: #3B4F6B;
}
.chg-col-module {
  font-size: 0.66rem; font-weight: 600; padding: 1px 7px;
  border-radius: 4px; background: #D4C4A8; color: #6B5B3E;
}
.chg-col-taux {
  font-size: 0.66rem; font-weight: 700; color: var(--ss-text-muted);
}
.chg-step-hint { font-size: 0.75rem; color: var(--ss-text-muted); font-weight: 400; }

/* ── Dual planning grid ── */
.chg-dual-section { margin-top: 1.5rem; }
.chg-dual-title {
  font-size: 0.9rem; font-weight: 700; margin-bottom: 0.5rem;
  display: flex; align-items: center; gap: 0.4rem;
}
.chg-dual-nav {
  display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.5rem;
}
.chg-dual-range { font-size: 0.82rem; font-weight: 600; flex: 1; text-align: center; }
/* Legend button & panel */
.chg-legend-btn {
  background: none; border: 1px solid var(--ss-border); border-radius: 6px;
  color: var(--ss-text-muted); padding: 4px 8px; font-size: .82rem;
  cursor: pointer; transition: all .15s;
}
.chg-legend-btn:hover { background: var(--ss-bg); color: var(--ss-text); }
.chg-legend-panel {
  max-height: 0; overflow: hidden; opacity: 0;
  transition: max-height .3s ease, opacity .2s ease, padding .2s ease;
  background: #FAFAF8; border: 1px solid var(--ss-border-light);
  border-radius: 8px; margin-bottom: 8px;
}
.chg-legend-panel.open {
  max-height: 200px; opacity: 1; padding: 10px 14px;
}
.chg-legend-item {
  display: flex; align-items: center; gap: 8px;
  font-size: .8rem; color: var(--ss-text-secondary); margin-bottom: 6px;
}
.chg-legend-item:last-child { margin-bottom: 0; }
.chg-legend-color {
  width: 18px; height: 18px; border-radius: 4px; flex-shrink: 0;
}
.chg-legend-off {
  font-size: .65rem; font-weight: 700; color: #999; letter-spacing: .5px;
  width: 18px; text-align: center; flex-shrink: 0;
}

.chg-dual-grid-wrap {
  overflow-x: auto; border: 1px solid var(--ss-border-light, #e5e7eb);
  border-radius: 8px; -webkit-overflow-scrolling: touch;
  cursor: grab; scrollbar-width: none;
}
.chg-dual-grid-wrap::-webkit-scrollbar { display: none; }
.chg-dual-grid-wrap.chg-grabbing { cursor: grabbing; }
.chg-dual-table {
  width: 100%; border-collapse: collapse; font-size: 0.8rem;
}
.chg-dual-table th, .chg-dual-table td {
  padding: 6px 4px; text-align: center; border: 1px solid var(--ss-border-light, #e5e7eb);
  white-space: nowrap; min-width: 52px;
}
.chg-dual-table thead th {
  background: var(--ss-bg, #f5f3ee); font-weight: 700; font-size: 0.72rem;
  position: sticky; top: 0; z-index: 2;
}
.chg-dual-user-col {
  position: sticky; left: 0; z-index: 3;
  background: #fff; font-weight: 600; font-size: 0.78rem;
  text-align: left !important; min-width: 120px; padding-left: 8px !important;
}
.chg-dual-table thead .chg-dual-user-col { z-index: 4; }

.chg-dual-swap-dem { background: rgba(188,210,203,.2) !important; }
.chg-dual-swap-dest { background: rgba(178,201,212,.2) !important; }

.chg-dual-cell-give { background: rgba(188,210,203,.3) !important; border-color: #bcd2cb !important; }
.chg-dual-cell-take { background: rgba(178,201,212,.3) !important; border-color: #B8C9D4 !important; }

/* ── Swap result cells ── */
.chg-swap-result {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 2px; border-radius: 6px;
}
.chg-swap-label {
  font-size: .6rem; line-height: 1; opacity: .6;
}
.chg-swap-lose {
  background: rgba(220,38,38,.08);
}
.chg-swap-lose .chg-swap-label { color: #c0392b; }
.chg-swap-gain {
  background: rgba(39,174,96,.1);
}
.chg-swap-gain .chg-swap-label { color: #27ae60; }
.chg-swap-off {
  font-size: .65rem; font-weight: 700; color: #999; letter-spacing: .5px;
}
.chg-swap-gain .chg-swap-off { color: #27ae60; }
.chg-swap-lose .chg-swap-off { color: #c0392b; }
.chg-dual-cell-give { background: rgba(220,38,38,.05) !important; }
.chg-dual-cell-take { background: rgba(39,174,96,.06) !important; }

.chg-dual-badge {
  display: inline-block; padding: 2px 7px; border-radius: 4px;
  font-size: 0.68rem; font-weight: 800; color: #fff;
}
.chg-dual-repos { font-size: 0.72rem; font-weight: 700; color: #999; }
.chg-dual-empty { color: #ccc; }

/* ── Confirmation step ── */
.chg-confirm-block {
  padding: 1.25rem; background: var(--ss-bg, #f5f3ee);
  border-radius: 10px; border: 1px solid var(--ss-border-light, #e5e7eb);
  margin-bottom: 1rem;
}
.chg-confirm-row {
  display: flex; align-items: stretch; gap: 0; flex-wrap: wrap;
}
.chg-confirm-side {
  flex: 1; min-width: 160px; padding: 0.75rem;
}
.chg-confirm-give { background: rgba(188,210,203,.15); border-radius: 8px 0 0 8px; }
.chg-confirm-take { background: rgba(178,201,212,.15); border-radius: 0 8px 8px 0; }
.chg-confirm-arrow {
  display: flex; align-items: center; padding: 0 0.75rem;
  font-size: 1.1rem; color: var(--ss-text-muted);
}
.chg-confirm-label { font-size: 0.74rem; font-weight: 600; color: var(--ss-text-muted); margin-bottom: 0.25rem; }
.chg-confirm-date { font-size: 0.9rem; font-weight: 700; margin-bottom: 0.35rem; }
.chg-confirm-with {
  margin-top: 0.75rem; font-size: 0.85rem; display: flex;
  align-items: center; gap: 0.35rem; color: var(--ss-text-muted);
}

/* ── Changements — liste des demandes ───────────────────── */
.chg-list-body { padding: 0; }
.chg-item {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--ss-border-light);
}
.chg-item:last-child { border-bottom: none; }

.chg-item-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 0.7rem;
}
.chg-item-date {
  font-size: 0.83rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  flex: 1;
  color: var(--ss-teal);
}
.chg-date-arrow { font-size: 0.7rem; opacity: 0.5; margin: 0 0.15rem; }
.chg-role-tag {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 2px 9px;
  border-radius: 20px;
  letter-spacing: 0.02em;
}
.chg-role-tag.demand { background: rgba(99,102,241,0.1); color: #5b5fc7; }
.chg-role-tag.invite { background: rgba(234,139,45,0.12); color: var(--ss-orange); }

.chg-exchange {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  flex-wrap: wrap;
  background: var(--ss-bg);
  border-radius: var(--ss-radius-sm);
  padding: 0.6rem 0.85rem;
}
.chg-person {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
  flex: 1;
}
.chg-person-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ss-teal);
}
.chg-person-you {
  font-weight: 400;
  color: var(--ss-text-muted);
  font-size: 0.78rem;
}
.chg-person-shift { font-size: 0.82rem; display: flex; align-items: center; gap: 0.35rem; }
.chg-person-shift-label { font-size: 0.72rem; color: var(--ss-text-muted); font-weight: 600; }
.chg-arrow {
  display: flex;
  align-items: center;
  align-self: stretch;
  padding: 0 0.5rem;
  color: var(--ss-text-muted);
  font-size: 0.85rem;
  flex-shrink: 0;
  border-left: 1px solid var(--ss-border-light);
  border-right: 1px solid var(--ss-border-light);
}
/* Details toggle button */
.chg-details-toggle {
  position: absolute; bottom: 6px; right: 6px;
  width: 24px; height: 24px; border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  background: transparent; border: 1px solid var(--ss-border);
  color: var(--ss-text-muted); font-size: .75rem;
  cursor: pointer; transition: all .2s; z-index: 1;
}
.chg-details-toggle:hover { background: var(--ss-border-light); color: var(--ss-text); }

/* Collapsible details */
.chg-details {
  max-height: 0; overflow: hidden; opacity: 0;
  transition: max-height .3s ease, opacity .2s ease, margin .2s ease;
  margin-top: 0;
}
.chg-details.open {
  max-height: 200px; opacity: 1; margin-top: 8px;
}

.chg-info {
  font-size: 0.84rem;
  color: var(--ss-text-secondary);
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  line-height: 1.5;
  padding: 8px 12px;
  border-left: 3px solid var(--ss-border);
  background: rgba(0,0,0,.02);
  border-radius: 0 6px 6px 0;
}
.chg-info + .chg-info { margin-top: 6px; }
.chg-info i { color: var(--ss-text-muted); margin-top: 2px; flex-shrink: 0; }
.chg-info-date { margin-left: auto; font-size: .72rem; color: var(--ss-text-muted); white-space: nowrap; flex-shrink: 0; }
.chg-info.refus {
  color: #991B1B;
  border-left-color: var(--ss-red);
  background: rgba(220,38,38,.04);
}
.chg-info.refus i { color: var(--ss-red); }

/* ── Changements — Modals (style admin absences) ── */
.chg-modal-dialog { max-width: 780px; }
.chg-modal-dialog-sm { max-width: 420px; }

/* Compensation panel (cas 3: jour OFF) */
.chg-compensation-panel {
  margin-top: 14px; padding: 12px 14px; border-radius: 8px;
  background: var(--ss-bg); border: 1px solid var(--ss-border-light);
}
.chg-comp-header {
  display: flex; gap: 10px; margin-bottom: 10px; align-items: flex-start;
}
.chg-comp-icon-inline {
  color: var(--ss-text-muted); font-size: 1rem; margin-top: 2px; flex-shrink: 0;
}
.chg-comp-title { font-size: .85rem; font-weight: 600; color: var(--ss-text); margin-bottom: 2px; }
.chg-comp-desc { font-size: .8rem; color: var(--ss-text-muted); line-height: 1.5; }
.chg-comp-cal {
  display: flex; flex-wrap: wrap; gap: 6px;
}
.chg-comp-day {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 12px; border-radius: 8px; cursor: pointer;
  background: #fff; border: 1.5px solid #E8E5E0;
  transition: all .15s; font-size: .84rem;
}
.chg-comp-day:hover { border-color: #16A34A; background: rgba(22,163,74,.04); }
.chg-comp-day-selected { border-color: #16A34A; background: rgba(22,163,74,.08); box-shadow: 0 0 0 2px rgba(22,163,74,.15); }
.chg-comp-day-name { font-weight: 600; min-width: 48px; }
.chg-comp-day-module { font-size: .75rem; color: var(--ss-text-muted); }

/* Step labels */
.chg-confirm-step-label {
  font-size: .85rem; font-weight: 600; color: var(--ss-text);
  display: flex; align-items: center; gap: 6px; margin-bottom: 8px;
}
.chg-confirm-step-label i { color: var(--ss-text-muted); }

/* Summary table */
.chg-summary-grid {
  border: 1px solid var(--ss-border-light); border-radius: 8px; overflow: hidden;
}
.chg-summary-row {
  display: grid; grid-template-columns: 1fr 1fr 1fr;
  border-bottom: 1px solid var(--ss-border-light); font-size: .84rem;
}
.chg-summary-row:last-child { border-bottom: none; }
.chg-summary-header {
  background: var(--ss-bg); font-weight: 600; font-size: .78rem;
  color: var(--ss-text-muted); text-transform: uppercase; letter-spacing: .3px;
}
.chg-summary-date { padding: 10px 12px; font-weight: 600; color: var(--ss-text); font-size: .82rem; }
.chg-summary-person { padding: 10px 12px; display: flex; align-items: center; gap: 6px; }
.chg-summary-person small { color: var(--ss-text-muted); font-size: .75rem; }
.chg-summary-gain { background: rgba(39,174,96,.06); }
.chg-summary-lose { background: rgba(220,38,38,.04); }

@media (max-width: 600px) {
  .chg-summary-row { grid-template-columns: 1fr; }
}
.chg-modal-close {
  width: 32px; height: 32px; border-radius: 50%;
  border: 1px solid var(--ss-border, #e5e7eb);
}
.chg-modal-close i { font-size: .85rem; }
.chg-btn-envoyer {
  background: var(--ss-bg, #f5f3ee); border: 1px solid var(--ss-border, #e5e7eb);
  color: var(--ss-text-muted); border-radius: var(--ss-radius-sm, 8px);
  transition: all .2s;
}
.chg-btn-envoyer:hover { background: #bcd2cb; color: #2d4a43; border-color: #bcd2cb; }
.chg-btn-refuser {
  background: var(--ss-bg, #f5f3ee); border: 1px solid var(--ss-border, #e5e7eb);
  color: var(--ss-text-muted); border-radius: var(--ss-radius-sm, 8px);
  transition: all .2s;
}
.chg-btn-refuser:hover { background: #E2B8AE; color: #7B3B2C; border-color: #E2B8AE; }

/* ── Changements responsive ── */
@media (max-width: 600px) {
  .chg-confirm-row { flex-direction: column; }
  .chg-confirm-give { border-radius: 8px 8px 0 0; }
  .chg-confirm-take { border-radius: 0 0 8px 8px; }
  .chg-confirm-arrow { justify-content: center; padding: 0.35rem 0; }
  .chg-cal-cell { min-height: 48px; }
}

/* ── Alert Modal (haute importance) ── */
/* ── Alert broadcast modal (employee-side) ── */
.ss-alert-overlay {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(0,0,0,.45); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity .3s ease; padding: 20px;
}
.ss-alert-overlay.show { opacity: 1; }
.ss-alert-modal {
  background: #fff; border-radius: 16px; max-width: 560px; width: 100%;
  box-shadow: 0 20px 60px rgba(0,0,0,.25); overflow: hidden;
  transform: scale(.9) translateY(20px); transition: transform .3s ease;
}
.ss-alert-overlay.show .ss-alert-modal { transform: scale(1) translateY(0); }
.ss-alert-haute { border-top: 4px solid #dc2626; }

/* Header */
.ss-alert-header {
  display: flex; align-items: center; gap: 14px;
  padding: 1.25rem 1.5rem; border-bottom: 1px solid #e5e5e5;
  background: #fafaf8;
}
.ss-alert-header-icon {
  width: 48px; height: 48px; border-radius: 12px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; background: rgba(42,157,143,.08); color: var(--ss-teal, #2a9d8f);
}
.ss-alert-header-icon--danger { background: rgba(220,38,38,.08); color: #dc2626; }
.ss-alert-title { font-size: 1.1rem; font-weight: 700; margin: 0; color: #191918; line-height: 1.3; }
.ss-alert-meta { font-size: 0.78rem; color: #999; }

/* Content */
.ss-alert-content { padding: 1.25rem 1.5rem; max-height: 55vh; overflow-y: auto; scroll-behavior: smooth; }
.ss-alert-btn:disabled { opacity: .5; cursor: not-allowed; filter: grayscale(.3); }
.ss-alert-message {
  display: flex; gap: 12px; align-items: flex-start;
  padding: 1rem 1.15rem; border-radius: 10px;
  background: rgba(42,157,143,.06); border: 1px solid rgba(42,157,143,.15);
}
.ss-alert-message--danger {
  background: rgba(220,38,38,.05); border-color: rgba(220,38,38,.15);
}
.ss-alert-message-icon {
  font-size: 1.15rem; flex-shrink: 0; margin-top: 2px;
  color: var(--ss-teal, #2a9d8f);
}
.ss-alert-message--danger .ss-alert-message-icon { color: #dc2626; }
.ss-alert-message--danger .ss-alert-message-text { color: #991b1b; }
.ss-alert-message-text {
  font-size: 0.92rem; line-height: 1.65; color: #374151;
  white-space: pre-wrap; max-height: 300px; overflow-y: auto;
}

/* Footer */
.ss-alert-footer {
  display: flex; justify-content: flex-end;
  padding: 0.85rem 1.5rem; border-top: 1px solid #e5e5e5; background: #fafaf8;
}
.ss-alert-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 10px 24px; border-radius: 8px; border: none; cursor: pointer;
  font-weight: 600; font-size: 0.9rem;
  background: var(--ss-teal, #2a9d8f); color: #fff;
  transition: background .2s;
}
.ss-alert-btn:hover { background: #238b7f; }
.ss-alert-btn-danger { background: #dc2626; }
.ss-alert-btn-danger:hover { background: #b91c1c; }

/* ── Offline / Sync bars ── */
.ss-offline-bar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 9990;
  background: #D4C4A8; color: #6B5B3E; padding: 10px 16px;
  font-size: 0.85rem; font-weight: 600; text-align: center;
  transform: translateY(100%); transition: transform .3s ease;
  display: flex; align-items: center; justify-content: center; gap: 8px;
}
.ss-offline-bar.show { transform: translateY(0); }
.ss-sync-bar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 9991;
  background: #1a1a1a; color: #fff; padding: 10px 16px;
  font-size: 0.85rem; text-align: center;
  transform: translateY(100%); transition: transform .3s ease;
}
.ss-sync-bar.show { transform: translateY(0); }
.ss-sync-text { margin-bottom: 6px; display: flex; align-items: center; justify-content: center; gap: 6px; }
.ss-sync-progress { height: 4px; background: rgba(255,255,255,.2); border-radius: 2px; overflow: hidden; }
.ss-sync-progress-fill { height: 100%; background: var(--ss-teal, #2a9d8f); border-radius: 2px; transition: width .3s ease; width: 0; }
.ss-sync-bar.ss-sync-success { background: #bcd2cb; color: #2d4a43; }
.ss-sync-bar.ss-sync-warning { background: #D4C4A8; color: #6B5B3E; }

/* ── Sync toast (floating) ── */
.ss-sync-toast {
  position: fixed; bottom: 20px; right: 20px; z-index: 9992;
  background: var(--ss-bg-card, #fff); border: 1px solid var(--ss-border, #E8E5E0);
  border-radius: 16px; width: 320px; max-width: calc(100vw - 32px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.12), 0 2px 8px rgba(0,0,0,0.06);
  transform: translateY(120%); opacity: 0;
  transition: transform .4s cubic-bezier(.4,0,.2,1), opacity .3s ease;
  overflow: hidden;
}
.ss-sync-toast.show { transform: translateY(0); opacity: 1; }
.ss-sync-toast-header {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 14px 8px; font-weight: 600; font-size: .88rem;
  color: var(--ss-text, #1A1A1A);
}
.ss-sync-toast-spinner {
  animation: ss-spin 1s linear infinite; font-size: 1.1rem; color: var(--ss-teal, #191918);
}
@keyframes ss-spin { to { transform: rotate(360deg); } }
.ss-sync-toast-title { flex: 1; }
.ss-sync-toast-close {
  background: none; border: none; cursor: pointer; padding: 2px 4px;
  color: var(--ss-text-muted, #9B9B9B); font-size: 1rem; line-height: 1;
}
.ss-sync-toast-close:hover { color: var(--ss-text, #1A1A1A); }
.ss-sync-toast-body { padding: 0 14px 10px; }
.ss-sync-toast-row {
  display: flex; align-items: center; gap: 10px; padding: 6px 0;
}
.ss-sync-icon-down { font-size: 1.2rem; color: #3B4F6B; }
.ss-sync-icon-up { font-size: 1.2rem; color: #2d4a43; }
.ss-sync-icon-done { font-size: 1.1rem; color: #2d4a43; }
.ss-sync-icon-warn { font-size: 1.1rem; color: #6B5B3E; }
.ss-sync-toast-info { flex: 1; min-width: 0; }
.ss-sync-toast-label { display: block; font-size: .78rem; font-weight: 600; color: var(--ss-text, #1A1A1A); }
.ss-sync-toast-detail { display: block; font-size: .72rem; color: var(--ss-text-muted, #9B9B9B); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ss-sync-toast-progress {
  height: 4px; background: var(--ss-border-light, #F0EDE8);
  border-radius: 2px; overflow: hidden; margin: 2px 0 6px;
}
.ss-sync-toast-progress-fill {
  height: 100%; border-radius: 2px; width: 0;
  transition: width .4s ease;
}
.ss-sync-down-fill { background: #B8C9D4; }
.ss-sync-up-fill { background: #bcd2cb; }
.ss-sync-toast-footer {
  padding: 0 14px 10px; font-size: .78rem;
  color: var(--ss-text-secondary, #6B6B6B); text-align: center;
}
.ss-sync-toast--success { border-color: #bcd2cb; }
.ss-sync-toast--success .ss-sync-toast-header { color: #2d4a43; }
.ss-sync-toast--warning { border-color: #D4C4A8; }
.ss-sync-toast--warning .ss-sync-toast-header { color: #6B5B3E; }

/* ═══════════════════════════════════════
   ANNUAIRE — Employee page
   ═══════════════════════════════════════ */
.an-emp-wrap { padding: 16px 20px; max-width: 1100px; margin: 0 auto; }
.an-emp-header { margin-bottom: 20px; }
.an-emp-title { font-size: 1.15rem; font-weight: 700; margin: 0 0 14px; display: flex; align-items: center; gap: 10px; color: var(--ss-text); }
.an-emp-title i { color: #2d4a43; }

.an-emp-tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.an-emp-tab { background: #fff; border: 1px solid var(--ss-border); border-radius: 10px; padding: 8px 14px; font-size: .85rem; font-weight: 600; color: var(--ss-text-muted); cursor: pointer; transition: all .15s; display: inline-flex; align-items: center; gap: 6px; }
.an-emp-tab:hover { background: var(--ss-bg); color: var(--ss-text); }
.an-emp-tab.active { background: #191918; color: #fff; border-color: #191918; }
.an-emp-tab i { font-size: .85rem; }

/* Urgence quick tiles — big red buttons */
.an-emp-urgence-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; margin-bottom: 24px; }
.an-emp-urgence-tile {
  background: #E2B8AE; color: #7B3B2C; border-radius: 14px; padding: 18px 14px;
  text-align: center; text-decoration: none; border: 2px solid transparent;
  transition: all .15s; display: flex; flex-direction: column; align-items: center; gap: 6px;
}
.an-emp-urgence-tile:hover { transform: translateY(-2px); border-color: #7B3B2C; color: #7B3B2C; }
.an-emp-urgence-tile i { font-size: 1.8rem; }
.an-emp-urgence-num { font-size: 1.4rem; font-weight: 800; font-family: monospace; }
.an-emp-urgence-label { font-size: .78rem; font-weight: 600; opacity: .85; }

/* Group labels */
.an-emp-group-label {
  font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .5px;
  color: var(--ss-text-muted); margin: 24px 0 10px 4px;
}

/* Contact cards */
.an-emp-list { display: flex; flex-direction: column; gap: 10px; }
.an-emp-card {
  background: #fff; border: 1px solid var(--ss-border); border-radius: 12px;
  padding: 14px; display: flex; align-items: center; gap: 14px; transition: all .15s;
}
.an-emp-card:hover { border-color: var(--ss-text-muted); box-shadow: var(--ss-shadow-sm); }

.an-emp-avatar {
  width: 44px; height: 44px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: .9rem; flex-shrink: 0;
}
.an-emp-avatar-interne { background: #bcd2cb; color: #2d4a43; }
.an-emp-avatar-externe { background: #B8C9D4; color: #3B4F6B; }
.an-emp-avatar-urgence { background: #E2B8AE; color: #7B3B2C; }

.an-emp-info { flex: 1; min-width: 0; }
.an-emp-name { font-weight: 600; color: var(--ss-text); font-size: .95rem; }
.an-emp-fav { color: #EA8B2D; font-size: .8rem; margin-left: 4px; }
.an-emp-meta { font-size: .78rem; color: var(--ss-text-muted); margin-top: 2px; }
.an-emp-tel { font-family: monospace; font-size: .88rem; font-weight: 600; color: var(--ss-text); margin-top: 4px; }
.an-emp-tel-sec { font-size: .78rem; color: var(--ss-text-muted); font-weight: 500; }
.an-emp-email { font-size: .78rem; color: var(--ss-text-muted); margin-top: 2px; }

.an-emp-actions { display: flex; gap: 6px; flex-shrink: 0; }
.an-emp-action {
  width: 40px; height: 40px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  background: var(--ss-bg); color: var(--ss-text-secondary);
  text-decoration: none; transition: all .15s; font-size: 1rem;
}
.an-emp-action:hover { background: var(--ss-border); color: var(--ss-text); }
.an-emp-action-call { background: #bcd2cb; color: #2d4a43; }
.an-emp-action-call:hover { background: #a3c0b6; color: #2d4a43; }

.an-emp-highlight {
  border-color: #EA8B2D !important;
  background: #FFF8E7 !important;
  box-shadow: 0 0 0 3px rgba(234, 139, 45, 0.2) !important;
  animation: an-emp-pulse 1.5s ease-in-out;
}
@keyframes an-emp-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(234, 139, 45, 0.6); }
  50%  { box-shadow: 0 0 0 10px rgba(234, 139, 45, 0.15); }
  100% { box-shadow: 0 0 0 3px rgba(234, 139, 45, 0.2); }
}

.an-emp-empty {
  text-align: center; padding: 60px 20px; color: var(--ss-text-muted);
  background: #fff; border: 1px dashed var(--ss-border); border-radius: 12px;
}

/* Online/offline presence on collegue cards */
.ss-avatar-with-presence { position: relative; flex-shrink: 0; }
.ss-presence-dot {
  position: absolute; bottom: 0; right: 0;
  width: 13px; height: 13px; border-radius: 50%;
  border: 2px solid #fff;
}
.ss-presence-online { background: #2d4a43; box-shadow: 0 0 0 3px rgba(45,74,67,.15); }
.ss-presence-offline { background: #9B9B9B; }
.ss-presence-label.is-online { color: #2d4a43; font-weight: 600; }

.an-emp-card-offline { opacity: .72; }
.an-emp-card-offline:hover { opacity: 1; }

/* Call buttons in global search results */
.fe-search-item-collegue {
  display: flex !important;
  align-items: center;
  gap: 10px;
  padding-right: 10px !important;
}
.fe-search-item-body { flex: 1; min-width: 0; }
.fe-search-call-actions {
  display: flex; gap: 4px; flex-shrink: 0;
}
.fe-search-call-btn {
  width: 34px; height: 34px; border-radius: 8px;
  border: none; cursor: pointer; font-size: .9rem;
  display: flex; align-items: center; justify-content: center;
  transition: all .15s;
}
.fe-search-call-audio { background: #bcd2cb; color: #2d4a43; }
.fe-search-call-audio:hover { background: #a3c0b6; }
.fe-search-call-video { background: #B8C9D4; color: #3B4F6B; }
.fe-search-call-video:hover { background: #9eb8c5; }

/* ═══════════════════════════════════════
   CALL — history items
   ═══════════════════════════════════════ */
.ss-callhist-item {
  background: #fff; border: 1px solid var(--ss-border); border-radius: 12px;
  padding: 12px 14px; display: flex; align-items: center; gap: 12px;
  margin-bottom: 8px; transition: all .15s;
}
.ss-callhist-item:hover { box-shadow: var(--ss-shadow-sm); }
.ss-callhist-missed .ss-callhist-name { color: #7B3B2C; }

.ss-callhist-arrow {
  width: 32px; height: 32px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; flex-shrink: 0;
}
.ss-call-arrow-out { background: #bcd2cb; color: #2d4a43; }
.ss-call-arrow-in { background: #B8C9D4; color: #3B4F6B; }
.ss-call-arrow-missed { background: #E2B8AE; color: #7B3B2C; }

.ss-callhist-info { flex: 1; min-width: 0; }
.ss-callhist-name {
  font-weight: 600; color: var(--ss-text); font-size: .92rem;
  display: flex; align-items: center; gap: 8px;
}
.ss-callhist-media { font-size: .78rem; color: var(--ss-text-muted); }
.ss-callhist-meta {
  display: flex; align-items: center; gap: 10px;
  font-size: .76rem; color: var(--ss-text-muted); margin-top: 2px;
}
.ss-callhist-duration { font-family: monospace; font-weight: 600; }

/* ═══════════════════════════════════════
   CALL — overlays & controls
   ═══════════════════════════════════════ */
.ss-call-overlay {
  position: fixed; inset: 0; z-index: 99990;
  background: rgba(25, 25, 24, 0.92); backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity .3s ease; pointer-events: none;
}
.ss-call-overlay.show { opacity: 1; pointer-events: all; }

.ss-call-card {
  background: #fff; border-radius: 28px; padding: 36px 28px;
  text-align: center; max-width: 340px; width: 90%;
  box-shadow: 0 20px 60px rgba(0,0,0,.4);
}
.ss-call-status-label {
  font-size: .82rem; color: #6B6B6B; margin-bottom: 18px;
  display: flex; align-items: center; justify-content: center; gap: 6px;
  font-weight: 600;
}
.ss-call-status-label.pulsing { animation: ss-call-pulse 1.5s ease-in-out infinite; }
@keyframes ss-call-pulse { 0%, 100% { opacity: .6; } 50% { opacity: 1; } }

.ss-call-avatar {
  width: 100px; height: 100px; border-radius: 50%;
  background: #bcd2cb; color: #2d4a43;
  margin: 0 auto 18px; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  font-size: 2rem; font-weight: 700;
  box-shadow: 0 4px 16px rgba(0,0,0,.1);
}
.ss-call-avatar-img { width: 100%; height: 100%; object-fit: cover; }
.ss-call-name { font-size: 1.3rem; font-weight: 700; color: #1A1A1A; margin-bottom: 4px; }
.ss-call-fonction { font-size: .82rem; color: #6B6B6B; margin-bottom: 28px; }

.ss-call-actions {
  display: flex; gap: 22px; justify-content: center;
  position: relative; z-index: 10;
}
.ss-call-btn {
  width: 72px; height: 72px; border-radius: 50%; border: none;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.6rem; color: #fff; cursor: pointer;
  transition: transform .15s, box-shadow .2s;
  box-shadow: 0 4px 12px rgba(0,0,0,.15);
  touch-action: manipulation;
  -webkit-tap-highlight-color: rgba(0,0,0,0.2);
  user-select: none;
  position: relative; z-index: 2;
}
.ss-call-btn:active { transform: scale(0.95); }
.ss-call-btn:hover { transform: scale(1.05); box-shadow: 0 6px 18px rgba(0,0,0,.25); }
.ss-call-btn-accept { background: #2d4a43; }
.ss-call-btn-accept:hover { background: #1f3631; }
.ss-call-btn-reject { background: #7B3B2C; }
.ss-call-btn-reject:hover { background: #5e2b1f; }
.ss-call-btn-reject:active { transform: scale(0.95); }

/* Incoming — ring animation */
.ss-call-overlay--incoming .ss-call-avatar {
  animation: ss-call-ring 1.5s ease-in-out infinite;
}
@keyframes ss-call-ring {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255,255,255,.4); }
  50%      { box-shadow: 0 0 0 16px rgba(255,255,255,0); }
}

/* Active call fullscreen */
.ss-call-overlay--active {
  background: #000;
  backdrop-filter: none;
  padding: 0;
}
.ss-call-overlay--active .ss-call-card { display: none; }

.ss-call-remote-video {
  width: 100%; height: 100%;
  object-fit: cover; background: #111;
}
.ss-call-local-video {
  position: absolute; top: 16px; right: 16px;
  width: 120px; height: 160px; object-fit: cover;
  border-radius: 14px; border: 2px solid #fff;
  box-shadow: 0 4px 16px rgba(0,0,0,.4); background: #111;
  z-index: 2;
}

.ss-call-active-top {
  position: absolute; top: 0; left: 0; right: 0;
  padding: 20px; z-index: 3;
  background: linear-gradient(to bottom, rgba(0,0,0,.6), transparent);
}
.ss-call-active-info { display: flex; align-items: center; gap: 12px; color: #fff; }
.ss-call-avatar-sm { width: 44px; height: 44px; font-size: .9rem; margin: 0; }
.ss-call-active-name { font-weight: 600; font-size: .95rem; }
.ss-call-active-duration { font-size: .78rem; opacity: .85; font-family: monospace; }

.ss-call-active-controls {
  position: absolute; bottom: 28px; left: 0; right: 0;
  display: flex; justify-content: center; gap: 16px; z-index: 10;
}
.ss-call-ctrl {
  touch-action: manipulation; user-select: none;
  -webkit-tap-highlight-color: rgba(255,255,255,.2);
}
.ss-call-ctrl {
  width: 58px; height: 58px; border-radius: 50%;
  background: rgba(255,255,255,.2); backdrop-filter: blur(10px);
  color: #fff; border: none; cursor: pointer;
  font-size: 1.3rem;
  display: flex; align-items: center; justify-content: center;
  transition: all .15s;
}
.ss-call-ctrl:hover { background: rgba(255,255,255,.35); }
.ss-call-ctrl.active { background: rgba(255,255,255,.6); color: #1A1A1A; }
.ss-call-ctrl-end { background: #7B3B2C; }
.ss-call-ctrl-end:hover { background: #5e2b1f; }

/* Audio-only active call: show a dark card instead of video */
.ss-call-overlay--active:has(#ssCallRemoteAudio) {
  background: #191918;
  padding: 0;
}
.ss-call-overlay--active:has(#ssCallRemoteAudio) .ss-call-active-top {
  position: static; padding: 60px 20px 20px;
  background: none; text-align: center;
  display: flex; flex-direction: column; align-items: center;
}
.ss-call-overlay--active:has(#ssCallRemoteAudio) .ss-call-active-info {
  flex-direction: column; gap: 16px;
}
.ss-call-overlay--active:has(#ssCallRemoteAudio) .ss-call-avatar-sm {
  width: 120px; height: 120px; font-size: 2.5rem;
}
.ss-call-overlay--active:has(#ssCallRemoteAudio) .ss-call-active-name { font-size: 1.3rem; }
.ss-call-overlay--active:has(#ssCallRemoteAudio) .ss-call-active-duration { font-size: .9rem; margin-top: 6px; }

@media (max-width: 600px) {
  .ss-call-local-video { width: 90px; height: 120px; top: 12px; right: 12px; }
  .ss-call-ctrl { width: 52px; height: 52px; font-size: 1.15rem; }
}
.an-emp-empty i { font-size: 2.5rem; opacity: .2; display: block; margin-bottom: 10px; }

@media (max-width: 600px) {
  .an-emp-wrap { padding: 12px 14px; }
  .an-emp-card { padding: 12px; gap: 10px; }
  .an-emp-avatar { width: 40px; height: 40px; font-size: .85rem; }
  .an-emp-action { width: 36px; height: 36px; font-size: .92rem; }
  .an-emp-urgence-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
  .ss-sync-toast { right: 8px; bottom: 8px; width: calc(100vw - 16px); }
}

/* ── Lock screen ── */
.ss-lockscreen {
  position: fixed; inset: 0; z-index: 99999;
  background: var(--ss-bg, #F7F5F2);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity .3s ease;
  pointer-events: none;
}
.ss-lockscreen.show { opacity: 1; pointer-events: all; }
.ss-lockscreen-card {
  background: var(--ss-bg-card, #fff);
  border: 1px solid var(--ss-border, #E8E5E0);
  border-radius: 24px; padding: 2.5rem 2rem; text-align: center;
  max-width: 360px; width: 90%;
  box-shadow: var(--ss-shadow-lg, 0 8px 24px rgba(0,0,0,.08));
}
.ss-lockscreen-avatar {
  width: 72px; height: 72px; border-radius: 50%;
  background: var(--ss-teal, #191918); color: #fff;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 1.5rem; font-weight: 700; margin-bottom: 1rem;
  object-fit: cover;
}
.ss-lockscreen-name {
  font-size: 1.1rem; font-weight: 600; color: var(--ss-text, #1A1A1A);
  margin-bottom: .25rem;
}
.ss-lockscreen-hint {
  font-size: .82rem; color: var(--ss-text-muted, #9B9B9B);
  margin-bottom: 1.5rem;
}
.ss-lockscreen-input {
  width: 100%; padding: 12px 16px; border: 1px solid var(--ss-border, #E8E5E0);
  border-radius: 12px; font-size: .95rem; background: var(--ss-bg, #F7F5F2);
  outline: none; transition: border-color .2s;
}
.ss-lockscreen-input:focus { border-color: var(--ss-teal, #191918); }
.ss-lockscreen-input.error { border-color: var(--ss-red, #DC2626); animation: ss-lock-shake .4s ease; }
@keyframes ss-lock-shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-6px); }
  40%, 80% { transform: translateX(6px); }
}
.ss-lockscreen-btn {
  width: 100%; padding: 12px; border: none; border-radius: 12px;
  background: var(--ss-teal, #191918); color: #fff;
  font-size: .95rem; font-weight: 600; cursor: pointer;
  margin-top: .75rem; transition: opacity .2s;
}
.ss-lockscreen-btn:hover { opacity: .9; }
.ss-lockscreen-btn:disabled { opacity: .5; cursor: not-allowed; }
.ss-lockscreen-error {
  font-size: .82rem; color: var(--ss-red, #DC2626);
  margin-top: .5rem; min-height: 1.2em;
}
.ss-lockscreen-status {
  font-size: .75rem; color: var(--ss-text-muted, #9B9B9B);
  margin-top: 1rem; display: flex; align-items: center; justify-content: center; gap: 6px;
}
.ss-lockscreen-logout {
  background: none; border: none; color: var(--ss-text-muted, #9B9B9B);
  font-size: .78rem; cursor: pointer; margin-top: .75rem; padding: 4px 8px;
  text-decoration: underline;
}
.ss-lockscreen-logout:hover { color: var(--ss-red, #DC2626); }

/* ═══════════════════════════════════════
   CUISINE PAGE
   ═══════════════════════════════════════ */
.cuis-tabs .nav-link { font-size: 0.88rem; padding: 0.5rem 1rem; }
.cuis-tabs .nav-link.active { font-weight: 600; }

/* Menu saisie - day cards (admin style) */
.cuis-day-card { border: 1px solid #E8E5E0; border-radius: 16px; margin-bottom: 0.75rem; overflow: hidden; box-shadow: 0 1px 3px rgba(0,0,0,0.04); transition: box-shadow 0.2s; }
.cuis-day-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.06); }
.cuis-day-header { background: transparent; padding: 0.85rem 1.25rem; font-weight: 700; font-size: 0.92rem; border-bottom: 1px solid #E8E5E0; color: #1A1A18; }
.cuis-menu-section { padding: 0.75rem 1.25rem; border-bottom: 1px solid #F0EDE8; }
.cuis-menu-section:last-child { border-bottom: none; }
.cuis-repas-label { font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 0.35rem; display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 6px; }
.cuis-repas-label.midi, .cuis-repas-label[data-repas="midi"] { background: #bcd2cb; color: #2d4a43; }
.cuis-repas-label.soir, .cuis-repas-label[data-repas="soir"] { background: #D0C4D8; color: #5B4B6B; }
.cuis-menu-form { display: flex; flex-wrap: wrap; gap: 0.35rem; align-items: center; }
.cuis-menu-input { flex: 1; min-width: 100px; font-size: 0.82rem; border-radius: 8px; }
.cuis-menu-btn-row { display: flex; gap: 0.25rem; margin-left: auto; }

/* Collab summary */
.cuis-collab-summary { display: flex; align-items: center; gap: 1rem; padding: 0.5rem 0; margin-bottom: 0.5rem; font-size: 0.9rem; }

/* Autocomplete (admin style) */
.cuis-autocomplete-list { max-height: 200px; overflow-y: auto; border: 1px solid #E8E5E0; border-radius: 8px; background: #fff; position: relative; z-index: 10; box-shadow: 0 4px 12px rgba(0,0,0,0.06); }
.cuis-autocomplete-list:empty { display: none; }
.cuis-autocomplete-item { padding: 0.5rem 0.75rem; cursor: pointer; font-size: 0.875rem; border-bottom: 1px solid #F0EDE8; transition: background 0.15s; }
.cuis-autocomplete-item:hover { background: rgba(0,0,0,0.02); }
.cuis-autocomplete-item:last-child { border-bottom: none; }

/* VIP cards (admin style) */
.cuis-vip-card { border: 1px solid #E8E5E0; border-radius: 16px; padding: 1rem 1.25rem; margin-bottom: 0.75rem; box-shadow: 0 1px 3px rgba(0,0,0,0.04); transition: box-shadow 0.2s; }
.cuis-vip-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.06); }
.cuis-vip-header { display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; }
.cuis-vip-header .btn { margin-left: auto; }

/* Table (admin style) */
.cuis-table { font-size: 0.875rem; background: #fff; }
.cuis-table thead { background: #f9f7f4; }
.cuis-table th {
  font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.5px;
  color: #6b7280; font-weight: 600; border-bottom-width: 1px;
  white-space: nowrap; height: 3.5em; padding-top: 1.1em; padding-bottom: 1.1em;
}
.cuis-table td { vertical-align: middle; font-size: 0.875rem; }
.cuis-table tbody tr { border-bottom: 1px solid #ece8e1; transition: background 0.2s; }
.cuis-table tbody tr:hover { background: rgba(0,0,0,0.02); }

/* ── zerdaSelect (shared with admin) ── */
.zs-select { position: relative; display: block; user-select: none; }
.zs-toggle {
  display: inline-flex; align-items: center; gap: 8px;
  height: 38px; padding: 0 .75rem; font-size: .88rem; font-weight: 500;
  background: #fff; color: #3a3a3a; border: 1.5px solid #E0DCD4;
  border-radius: 8px; cursor: pointer; transition: all .2s ease;
  white-space: nowrap; width: 100%;
}
.zs-toggle:hover { border-color: #C4BBA8; box-shadow: 0 2px 8px rgba(180,170,150,.15); background: #FDFCF9; }
.zs-toggle:focus { border-color: #2d4a43; box-shadow: 0 2px 12px rgba(45,74,67,.12); outline: none; }
.zs-toggle .zs-label { flex: 1; text-align: left; overflow: hidden; text-overflow: ellipsis; }
.zs-toggle:not(.zs-has-value) .zs-label { color: #999; }
.zs-arrow { font-size: .7rem; color: #8a8680; transition: transform .2s ease; flex-shrink: 0; }
.zs-select.open .zs-arrow { transform: rotate(180deg); }
.zs-list {
  display: none; position: fixed; z-index: 1060;
  min-width: 180px; background: #fff; border: 1.5px solid #E8E3D8; border-radius: 12px;
  box-shadow: 0 8px 28px rgba(160,148,120,.18); overflow: visible;
}
.zs-list::before {
  content: ''; position: absolute; top: -8px; left: 20px;
  width: 14px; height: 14px; background: #fff;
  border-top: 1.5px solid #E8E3D8; border-left: 1.5px solid #E8E3D8;
  transform: rotate(45deg); z-index: -1;
}
.zs-list.zs-align-right::before { left: auto; right: 20px; }
.zs-list-inner { max-height: 260px; overflow-y: auto; padding: 6px; }
.zs-select.open .zs-list { display: block; animation: zsFadeIn .15s ease; }
@keyframes zsFadeIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: translateY(0); } }
.zs-option {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 12px; border-radius: 8px; font-size: .85rem; font-weight: 500;
  color: #4A4840; cursor: pointer; transition: all .12s ease;
}
.zs-option:hover { background: #F5F0E8; color: #2d2d2d; }
.zs-option.active { background: #EDE8DE; font-weight: 600; color: #2d4a43; }
.zs-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.zs-empty { padding: 12px; text-align: center; font-size: .82rem; color: #999; }
.zs-search-wrap { position: relative; padding: 8px 8px 4px; border-bottom: 1px solid #F0EDE8; }
.zs-search-icon { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); font-size: .75rem; color: #999; }
.zs-search {
  width: 100%; border: 1.5px solid #E8E3D8; border-radius: 8px;
  padding: 6px 10px 6px 28px; font-size: .82rem; outline: none; transition: border-color .2s;
}
.zs-search:focus { border-color: #2d4a43; }

/* ── Connection indicator (on logo) ── */
.fe-conn-status {
  position: absolute; bottom: 1px; right: 1px;
  display: flex; align-items: center; cursor: default;
}
.fe-conn-dot { width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0; border: 2px solid var(--ss-bg, #fff); }
.fe-conn-online { background: #22c55e; box-shadow: 0 0 5px rgba(34,197,94,.5); }
.fe-conn-offline { background: #7B3B2C; box-shadow: 0 0 4px rgba(123,59,44,.4); animation: ss-pulse 2s infinite; }
@keyframes ss-pulse { 0%,100% { opacity: 1; } 50% { opacity: .5; } }
.fe-conn-count { font-size: .55rem; font-weight: 700; background: #f59e0b; color: #fff; border-radius: 10px; padding: 0 4px; min-width: 14px; text-align: center; position: absolute; top: -8px; right: -8px; }

/* ── Sync indicator (topbar) ── */
.fe-sync-indicator {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: .7rem; color: var(--ss-text-muted, #9B9B9B);
  margin-left: 8px; white-space: nowrap; cursor: pointer;
  padding: 2px 8px; border-radius: 6px;
  transition: background .2s, color .2s;
}
.fe-sync-indicator:hover { background: var(--ss-border-light, #F0EDE8); color: var(--ss-text-secondary, #6B6B6B); }
.fe-sync-indicator i { font-size: .72rem; }
.fe-sync-indicator.syncing i { animation: ss-spin 1s linear infinite; }
.fe-sync-indicator.synced { color: #2d4a43; }
.fe-sync-indicator.offline { color: #7B3B2C; }
@media (max-width: 768px) { .fe-sync-indicator { display: none; } }

/* Print-friendly collab */
@media print {
    .fe-sidebar, .fe-topbar, .cuis-tabs, .page-header, .card-header .btn { display: none !important; }
    .card { border: none !important; box-shadow: none !important; }
    .cuis-table { font-size: 11px; }
}

/* ══════════════════════════════════════════════════════════════════════════════
   MUR SOCIAL (Wall) — 3-column layout with hero
   ══════════════════════════════════════════════════════════════════════════════ */

/* ── Hero Banner (profile-cover style, full-bleed) ── */
.mur-hero { position: relative; overflow: hidden; border-radius: 0; margin-bottom: 20px; width: 100vw; margin-left: 50%; transform: translateX(-50%); margin-top: -1.5rem; }
@media (max-width: 768px) { .mur-hero { margin-top: -1rem; } }
.mur-hero-cover { position: absolute; inset: 0; background: linear-gradient(135deg, #2d4a43 0%, #4a7c6f 40%, #8bb5a5 70%, #bcd2cb 100%); background-size: cover; background-position: center; }
.mur-hero-overlay { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(45,74,67,.6) 100%); }
.mur-hero-inner { position: relative; z-index: 1; display: flex; align-items: flex-end; gap: 20px; padding: 80px 32px 24px; }
.mur-hero-avatar { width: 80px; height: 80px; border-radius: 50%; border: 4px solid #fff; background: #fff; box-shadow: 0 4px 16px rgba(0,0,0,.2); overflow: hidden; flex-shrink: 0; display: flex; align-items: center; justify-content: center; }
.mur-hero-avatar img { width: 100%; height: 100%; object-fit: contain; }
.mur-hero-info { flex: 1; min-width: 0; }
.mur-hero-info h1 { color: #fff; font-size: 1.4rem; font-weight: 700; margin: 0 0 2px; text-shadow: 0 1px 4px rgba(0,0,0,.3); }
.mur-hero-info p { color: rgba(255,255,255,.85); font-size: .85rem; margin: 0; text-shadow: 0 1px 3px rgba(0,0,0,.2); }
.mur-hero-stats { display: flex; gap: 24px; flex-shrink: 0; }
.mur-hero-stat { text-align: center; }
.mur-hero-stat strong { display: block; font-size: 1.3rem; font-weight: 700; color: #fff; line-height: 1.2; text-shadow: 0 1px 3px rgba(0,0,0,.3); }
.mur-hero-stat span { font-size: .68rem; color: rgba(255,255,255,.7); text-transform: uppercase; letter-spacing: .4px; }
@media (max-width: 700px) {
    .mur-hero-inner { flex-direction: column; align-items: center; text-align: center; padding: 60px 20px 20px; gap: 10px; }
    .mur-hero-avatar { width: 64px; height: 64px; margin-top: -10px; }
    .mur-hero-stats { justify-content: center; gap: 20px; }
}

/* ── 3-Column Layout ── */
.mur-3col { display: grid; grid-template-columns: 220px 1fr 260px; gap: 20px; }
@media (max-width: 1100px) { .mur-3col { grid-template-columns: 200px 1fr; } .mur-sidebar-right { display: none; } }
@media (max-width: 768px) { .mur-3col { grid-template-columns: 1fr; } .mur-sidebar-left { display: none; } }

/* ── Left Sidebar ── */
.mur-sidebar-left { display: flex; flex-direction: column; gap: 14px; }
.mur-sidebar-card { background: var(--ss-surface, #fff); border-radius: 14px; border: 1.5px solid var(--ss-border, #e5e7eb); padding: 16px; }
.mur-sidebar-title { font-weight: 700; font-size: .82rem; margin-bottom: 12px; display: flex; align-items: center; gap: 6px; color: var(--ss-muted, #888); text-transform: uppercase; letter-spacing: .3px; font-size: .7rem; }
.mur-sidebar-title i { font-size: .85rem; }

/* Category nav */
.mur-cat-nav { display: flex; flex-direction: column; gap: 2px; }
.mur-cat-item { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 10px; font-size: .85rem; font-weight: 500; color: var(--ss-text, #1a1a1a); cursor: pointer; transition: all .15s; border: none; background: none; width: 100%; text-align: left; }
.mur-cat-item:hover { background: var(--ss-bg, #F7F5F2); }
.mur-cat-item.active { background: var(--mur-accent, #bcd2cb); color: var(--mur-accent-text, #2d4a43); font-weight: 600; }
.mur-cat-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.mur-cat-icon { font-size: 1rem; width: 20px; text-align: center; }
.mur-cat-count { margin-left: auto; font-size: .72rem; color: var(--ss-muted, #888); font-weight: 600; }
.mur-cat-item.active .mur-cat-count { color: #2d4a43; }

/* Rules */
.mur-rule { font-size: .78rem; padding: 6px 0; display: flex; align-items: center; gap: 8px; color: var(--ss-text, #1a1a1a); border-bottom: 1px solid var(--ss-border, #e5e7eb); }
.mur-rule:last-child { border-bottom: none; }
.mur-rule i { font-size: .85rem; color: var(--ss-muted, #888); }

/* ── Center Column ── */
.mur-center { min-width: 0; }

/* ── Composer (TipTap editor — original pill layout + expandable toolbar) ── */
.mur-composer { background: var(--ss-surface, #fff); border-radius: 14px; border: 1.5px solid var(--ss-border, #e5e7eb); padding: 16px; margin-bottom: 14px; }
.mur-composer-row { display: flex; gap: 12px; }
.mur-composer-avatar { width: 40px; height: 40px; border-radius: 50%; background: #B8C9D4; color: #3B4F6B; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: .82rem; flex-shrink: 0; overflow: hidden; }
.mur-composer-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.mur-composer-wrap { flex: 1; position: relative; display: flex; align-items: center; border: 1.5px solid var(--ss-border, #e5e7eb); border-radius: 22px; background: var(--ss-bg, #F7F5F2); transition: border-color .25s ease, background .25s ease, border-radius .25s ease; overflow: hidden; }
.mur-composer-wrap:focus-within,
.mur-composer-wrap.mur-composer-expanded { border-color: #bcd2cb; background: #fff; flex-wrap: wrap; border-radius: 14px; }

/* Editor content area */
.mur-composer-editor { flex: 1; min-width: 0; }
.mur-composer-editor .ProseMirror { padding: 10px 0 10px 16px; font-size: .88rem; line-height: 1.55; outline: none; min-height: 42px; }
.mur-composer-editor .ProseMirror p { margin: 0 0 .3rem; }
.mur-composer-editor .ProseMirror p:last-child { margin-bottom: 0; }
.mur-composer-editor .ProseMirror p.is-editor-empty:first-child::before { content: attr(data-placeholder); color: var(--ss-muted, #999); pointer-events: none; float: left; height: 0; }
.mur-composer-editor .ProseMirror mark { background: #fef3cd; padding: .05em .15em; border-radius: 2px; }
.mur-composer-editor .ProseMirror ul, .mur-composer-editor .ProseMirror ol { padding-left: 1.4rem; margin: .2rem 0; font-size: .88rem; }
.mur-composer-wrap:focus-within .mur-composer-editor,
.mur-composer-wrap.mur-composer-expanded .mur-composer-editor { flex-basis: 100%; }
.mur-composer-wrap:focus-within .mur-composer-editor .ProseMirror,
.mur-composer-wrap.mur-composer-expanded .mur-composer-editor .ProseMirror { min-height: 100px; padding-right: 16px; }

/* Bottom bar: inline with editor (icons only), wraps below on focus (toolbar + icons) */
.mur-composer-bar { display: flex; align-items: center; flex-shrink: 0; padding-right: 8px; }
.mur-composer-wrap:focus-within .mur-composer-bar,
.mur-composer-wrap.mur-composer-expanded .mur-composer-bar { flex-basis: 100%; justify-content: space-between; padding: 4px 8px 6px; border-top: 1px solid var(--ss-border, #e5e7eb); }

/* Mini toolbar — smooth fade in/out */
.mur-composer-toolbar { display: flex; align-items: center; gap: 2px; max-width: 0; opacity: 0; overflow: hidden; transition: opacity .2s ease, max-width .25s ease .2s; }
.mur-composer-wrap:focus-within .mur-composer-toolbar,
.mur-composer-wrap.mur-composer-expanded .mur-composer-toolbar { max-width: 500px; opacity: 1; transition: max-width .25s ease, opacity .2s ease .1s; }
.mur-tb-btn { width: 30px; height: 30px; border-radius: 6px; display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--ss-muted, #888); border: none; background: none; font-size: .88rem; transition: all .15s; flex-shrink: 0; }
.mur-tb-btn:hover { background: rgba(188,210,203,.25); color: #2d4a43; }
.mur-tb-btn.active { background: rgba(188,210,203,.4); color: #2d4a43; }
.mur-tb-sep { width: 1px; height: 18px; background: var(--ss-border, #e5e7eb); margin: 0 3px; flex-shrink: 0; }
.mur-composer-cat { border: 1px solid var(--ss-border, #e5e7eb); border-radius: 6px; padding: 4px 10px; font-size: .85rem; background: var(--ss-surface, #fff); cursor: pointer; margin-left: 6px; color: var(--ss-text, #333); white-space: nowrap; }

/* Media icons (always visible, right side) */
.mur-composer-icons { display: flex; gap: 2px; }
.mur-composer-icon-btn { width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--ss-muted, #888); transition: all .15s; font-size: 1rem; }
.mur-composer-icon-btn:hover { background: rgba(188,210,203,.2); color: #2d4a43; }
.mur-composer-preview { display: flex; gap: 8px; flex-wrap: wrap; padding-top: 10px; margin-top: 10px; border-top: 1px solid var(--ss-border, #e5e7eb); }
.mur-preview-thumb { position: relative; width: 72px; height: 72px; border-radius: 10px; overflow: hidden; }
.mur-preview-thumb img { width: 100%; height: 100%; object-fit: cover; }
.mur-preview-remove { position: absolute; top: 2px; right: 2px; width: 20px; height: 20px; border-radius: 50%; background: rgba(0,0,0,.6); color: #fff; border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; font-size: .6rem; }
.mur-composer-bottom { display: flex; align-items: center; gap: 10px; margin-top: 10px; }
.mur-composer-bottom .mur-btn-post { margin-left: auto; }
.mur-select { border: 1.5px solid var(--ss-border, #e5e7eb); border-radius: 8px; padding: 5px 10px; font-size: .8rem; background: var(--ss-surface, #fff); cursor: pointer; }
.mur-composer-anon { font-size: .78rem; color: var(--ss-muted, #888); display: flex; align-items: center; gap: 4px; cursor: pointer; }
.mur-btn-post { background: var(--mur-accent, #bcd2cb); color: var(--mur-accent-text, #2d4a43); border: none; border-radius: 10px; padding: 8px 20px; font-size: .82rem; font-weight: 600; cursor: pointer; transition: all .2s; display: flex; align-items: center; gap: 6px; }
.mur-btn-post:hover { filter: brightness(.93); }
.mur-btn-post:disabled { opacity: .5; cursor: not-allowed; }

/* ── Posts (Zikzak style) ── */
.mur-post { background: var(--ss-surface, #fff); border-radius: 14px; border: 1.5px solid var(--ss-border, #e5e7eb); margin-bottom: 14px; transition: box-shadow .2s; }
.mur-post:hover { box-shadow: 0 4px 16px rgba(0,0,0,.04); }
.mur-post-header { display: flex; gap: 10px; align-items: center; padding: 16px 18px 0; }
.mur-post-avatar { width: 42px; height: 42px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.mur-post-avatar-initials { width: 42px; height: 42px; border-radius: 50%; background: #D0C4D8; color: #5B4B6B; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: .78rem; flex-shrink: 0; }
.mur-post-meta { flex: 1; min-width: 0; }
.mur-post-name { font-weight: 600; font-size: .92rem; }
.mur-post-fonction { font-weight: 400; font-size: .75rem; color: var(--ss-muted, #888); margin-left: 6px; }
.mur-post-time { font-size: .75rem; color: var(--ss-muted, #888); display: flex; align-items: center; gap: 6px; }
.mur-pin-icon { color: #f59e0b; font-size: .7rem; }
.mur-post-cat { background: var(--ss-bg, #F7F5F2); padding: 2px 8px; border-radius: 6px; font-size: .68rem; font-weight: 600; }
.mur-post-actions { display: flex; gap: 4px; margin-left: auto; }
.mur-post-body { padding: 10px 18px 0; font-size: .9rem; line-height: 1.65; color: var(--ss-text, #1a1a1a); word-break: break-word; }
.mur-post-body p { margin: 0 0 8px; }
.mur-post-body p:last-child { margin-bottom: 0; }
.mur-post-body ul, .mur-post-body ol { margin: 4px 0 8px 20px; padding: 0; }
.mur-post-body li { margin: 2px 0; }
.mur-post-body strong { font-weight: 700; }
.mur-post-body em { font-style: italic; }
.mur-post-body mark { background: #fff6b0; padding: 0 2px; border-radius: 3px; }
.mur-post-body a { color: var(--cl-green, #2E7D32); text-decoration: underline; }

/* Édition inline d'un post — réutilise les styles du composer avec quelques ajustements */
.mur-edit-composer { box-shadow: none; border: 1.5px solid var(--cl-green, #2E7D32); }
.mur-edit-composer .mur-composer-row { padding: 0; }
.mur-edit-composer .mur-composer-wrap { width: 100%; }
.mur-edit-composer .mur-composer-bottom { display: flex; justify-content: flex-end; gap: 8px; align-items: center; }
.mur-edit-composer .mur-edit-cancel {
    background: none;
    border: 1px solid var(--ss-border, #e5e7eb);
    color: var(--ss-muted, #6b7280);
    padding: 6px 16px;
    border-radius: 10px;
    font-size: .85rem;
    cursor: pointer;
    font-family: inherit;
}
.mur-edit-composer .mur-edit-cancel:hover { background: var(--ss-bg, #f9fafb); }
.mur-edit-composer .mur-edit-save { display: inline-flex; align-items: center; gap: 6px; }

/* Engagement stats — clickable */
.mur-post-engagement { display: flex; gap: 16px; padding: 10px 18px; font-size: .82rem; color: var(--ss-muted, #888); border-top: 1px solid var(--ss-border, #e5e7eb); }
.mur-post-engagement span { display: flex; align-items: center; gap: 5px; cursor: pointer; padding: 4px 8px; border-radius: 8px; transition: all .15s; user-select: none; }
.mur-post-engagement span:hover { background: var(--ss-bg, #F7F5F2); color: var(--ss-text, #333); }
.mur-post-engagement i { font-size: .92rem; }
.mur-post-engagement em { font-style: normal; font-weight: 600; }
.mur-eng-like { color: var(--ss-muted, #888); }
.mur-eng-like.mur-eng-liked { color: #e74c3c; }
.mur-eng-like.mur-eng-liked:hover { background: rgba(231,76,60,.06); }
.mur-eng-comment { color: var(--ss-muted, #888); }
.mur-eng-spacer { flex: 1; }

/* Keep action-btn for edit menu only */
.mur-action-btn { background: none; border: none; cursor: pointer; font-size: .82rem; color: var(--ss-muted, #888); display: flex; align-items: center; gap: 5px; padding: 6px; border-radius: 8px; transition: all .15s; }
.mur-action-btn:hover { background: var(--ss-bg, #F7F5F2); color: var(--ss-text, #1a1a1a); }

/* ── Comment section (always visible input) ── */
.mur-comments-section { padding: 0 18px 14px; }
.mur-comment-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 10px; }
.mur-comment { display: flex; gap: 8px; }
.mur-comment-avatar { width: 28px; height: 28px; border-radius: 50%; background: #B8C9D4; color: #3B4F6B; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: .62rem; flex-shrink: 0; overflow: hidden; }
.mur-comment-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.mur-comment-content { flex: 1; background: var(--ss-bg, #F7F5F2); border-radius: 12px; padding: 8px 12px; min-width: 0; }
.mur-comment-header { display: flex; align-items: center; gap: 6px; }
.mur-comment-name { font-weight: 600; font-size: .78rem; }
.mur-comment-time { font-size: .68rem; color: var(--ss-muted, #888); }
.mur-comment-del { background: none; border: none; cursor: pointer; color: var(--ss-muted, #888); font-size: .78rem; padding: 0; margin-left: auto; }
.mur-comment-del:hover { color: #e74c3c; }
.mur-comment-body { font-size: .82rem; line-height: 1.5; margin-top: 2px; }

/* Comment input (Zikzak: input + icons + send) */
.mur-comment-input { display: flex; gap: 6px; align-items: center; }
.mur-comment-input-wrap { flex: 1; display: flex; align-items: center; border: 1.5px solid var(--ss-border, #e5e7eb); border-radius: 22px; background: var(--ss-bg, #F7F5F2); overflow: hidden; }
.mur-comment-text { flex: 1; border: none; padding: 8px 0 8px 14px; font-size: .82rem; font-family: inherit; background: transparent; }
.mur-comment-text:focus { outline: none; }
.mur-comment-icons { display: flex; gap: 2px; padding-right: 6px; }
.mur-comment-icon-btn { width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--ss-muted, #999); font-size: .85rem; border: none; background: none; }
.mur-comment-icon-btn:hover { color: #2d4a43; }
.mur-comment-anon-label { font-size: .72rem; color: var(--ss-muted, #888); display: flex; align-items: center; gap: 3px; white-space: nowrap; cursor: pointer; }
.mur-comment-error { text-align: center; padding: 10px; font-size: .82rem; color: var(--ss-muted, #888); }

/* Emoji picker */
.mur-emoji-picker { display: flex; flex-wrap: wrap; gap: 2px; padding: 8px; background: var(--ss-surface, #fff); border: 1.5px solid var(--ss-border, #e5e7eb); border-radius: 12px; margin-top: 8px; max-width: 280px; }
.mur-emoji-item { width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; font-size: 1.2rem; cursor: pointer; border-radius: 6px; transition: background .1s; user-select: none; }
.mur-emoji-item:hover { background: var(--ss-bg, #F7F5F2); transform: scale(1.2); }

/* Comment image preview */
.mur-comment-img-preview { margin-top: 6px; }
.mur-comment-img-thumb { position: relative; display: inline-block; width: 60px; height: 60px; border-radius: 8px; overflow: hidden; }
.mur-comment-img-thumb img { width: 100%; height: 100%; object-fit: cover; }
.mur-comment-img-remove { position: absolute; top: 2px; right: 2px; width: 18px; height: 18px; border-radius: 50%; background: rgba(0,0,0,.6); color: #fff; border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; font-size: .55rem; }

/* Comment reactions (thumbs up/down) */
.mur-comment-reactions { display: flex; gap: 2px; margin-top: 4px; }
.mur-comment-react { background: none; border: none; cursor: pointer; font-size: .78rem; color: var(--ss-muted, #aaa); padding: 2px 6px; border-radius: 4px; transition: all .15s; }
.mur-comment-react:hover { color: var(--ss-text, #333); background: var(--ss-bg, #F7F5F2); }
.mur-comment-react.mur-react-active { color: #2d4a43; }

/* Comment 3-dots menu */
.mur-comment-menu-btn { background: none; border: none; cursor: pointer; color: var(--ss-muted, #aaa); padding: 0 4px; font-size: .75rem; margin-left: auto; opacity: 0; transition: opacity .15s; }
.mur-comment:hover .mur-comment-menu-btn { opacity: 1; }
.mur-comment-dropdown { position: absolute; right: 0; top: 100%; background: #fff; border: 1.5px solid var(--ss-border, #e5e7eb); border-radius: 10px; padding: 4px; z-index: 10; box-shadow: 0 4px 16px rgba(0,0,0,.1); min-width: 130px; }
.mur-comment-dropdown button { display: flex; align-items: center; gap: 8px; width: 100%; padding: 7px 12px; border: none; background: none; border-radius: 6px; font-size: .8rem; cursor: pointer; transition: background .15s; color: var(--ss-text, #333); }
.mur-comment-dropdown button:hover { background: var(--ss-bg, #F7F5F2); }
.mur-comment-dropdown .mur-menu-danger { color: #7B3B2C; }
.mur-comment-dropdown .mur-menu-danger:hover { background: #fdf0ed; }
.mur-comment-edit-input { width: 100%; border: 1.5px solid #bcd2cb; border-radius: 6px; padding: 4px 8px; font-size: .82rem; font-family: inherit; }

/* @Mention */
.mur-mention { background: rgba(188,210,203,.25); color: #2d4a43; padding: 1px 4px; border-radius: 4px; font-weight: 600; font-size: .82rem; }
.mur-mention-dropdown { position: absolute; left: 0; bottom: 100%; background: #fff; border: 1.5px solid var(--ss-border, #e5e7eb); border-radius: 12px; padding: 4px; z-index: 20; box-shadow: 0 -4px 20px rgba(0,0,0,.1); min-width: 220px; max-height: 240px; overflow-y: auto; margin-bottom: 4px; }
.mur-mention-item { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; cursor: pointer; transition: background .1s; }
.mur-mention-item:hover, .mur-mention-item.active { background: var(--ss-bg, #F7F5F2); }
.mur-mention-avatar { width: 28px; height: 28px; border-radius: 50%; background: #B8C9D4; color: #3B4F6B; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: .6rem; flex-shrink: 0; overflow: hidden; }
.mur-mention-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.mur-mention-name { font-size: .82rem; font-weight: 600; }
.mur-mention-fn { font-size: .7rem; color: var(--ss-muted, #888); }

/* Edit inline */
.mur-edit-area { width: 100%; border: 1.5px solid #bcd2cb; border-radius: 8px; padding: 8px; font-size: .85rem; font-family: inherit; resize: vertical; min-height: 60px; }
.mur-edit-actions { display: flex; gap: 8px; margin-top: 8px; }
.mur-btn-save { background: #bcd2cb; color: #2d4a43; border: none; border-radius: 8px; padding: 5px 14px; font-size: .8rem; font-weight: 600; cursor: pointer; }
.mur-btn-cancel { background: #f0f0f0; color: #666; border: none; border-radius: 8px; padding: 5px 14px; font-size: .8rem; cursor: pointer; }

/* ── Right Sidebar ── */
.mur-sidebar-right { display: flex; flex-direction: column; gap: 14px; }

/* Widget items (popular posts, contributors) */
.mur-widget-list { display: flex; flex-direction: column; gap: 2px; }
.mur-widget-item { display: flex; align-items: center; gap: 10px; padding: 8px 4px; border-radius: 8px; transition: background .15s; }
.mur-widget-item:hover { background: var(--ss-bg, #F7F5F2); }
.mur-widget-rank { width: 20px; height: 20px; border-radius: 6px; background: var(--ss-bg, #F7F5F2); font-size: .68rem; font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--ss-muted, #888); }
.mur-widget-avatar { width: 28px; height: 28px; border-radius: 50%; background: #D0C4D8; color: #5B4B6B; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: .6rem; flex-shrink: 0; overflow: hidden; }
.mur-widget-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.mur-widget-text { flex: 1; min-width: 0; font-size: .8rem; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mur-widget-meta { font-size: .7rem; color: var(--ss-muted, #888); display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.mur-widget-empty { font-size: .8rem; color: var(--ss-muted, #888); text-align: center; padding: 12px 0; }
.mur-ev-date { min-width: 36px; text-align: center; padding: 4px; border-radius: 8px; background: var(--ss-bg, #F7F5F2); flex-shrink: 0; }
.mur-ev-day { font-size: 1rem; font-weight: 700; line-height: 1; color: var(--ss-accent, #2d4a43); }
.mur-ev-month { font-size: .6rem; font-weight: 600; text-transform: uppercase; color: var(--ss-muted, #888); }
.mur-ev-vote-hint { font-size: .68rem; font-weight: 600; color: var(--ss-orange, #EA9D3D); margin-top: 2px; }
.mur-ev-list { display: flex; flex-direction: column; gap: 10px; }
.mur-ev-banner { display: block; border-radius: 10px; overflow: hidden; border: 1px solid var(--ss-border, #E8E5E0); transition: box-shadow .2s, transform .2s; }
.mur-ev-banner:hover { box-shadow: 0 2px 10px rgba(0,0,0,.08); transform: translateY(-1px); }
.mur-ev-banner-img { width: 100%; height: 90px; object-fit: cover; display: block; }
.mur-ev-banner-body { padding: 10px 12px; }
.mur-ev-banner-title { font-size: .85rem; font-weight: 700; margin-bottom: 2px; }
.mur-ev-banner-reminder { font-size: .75rem; font-weight: 600; color: var(--ss-orange, #EA9D3D); margin-bottom: 3px; }
.mur-ev-banner-inscrit { font-size: .72rem; font-weight: 600; color: #16A34A; margin-bottom: 3px; }
.mur-ev-banner-meta { font-size: .7rem; color: var(--ss-muted, #888); }

/* ── Empty + Loading ── */
.mur-loading { text-align: center; padding: 30px; }
.mur-empty-feed { text-align: center; padding: 50px 20px; color: var(--ss-muted, #888); }
.mur-empty-feed i { font-size: 2.5rem; opacity: .3; display: block; margin-bottom: 10px; }
.mur-empty-feed p { font-size: 1rem; font-weight: 600; margin: 0 0 4px; }
.mur-empty-feed span { font-size: .82rem; }
.mur-load-more { text-align: center; padding: 16px; }
.mur-btn-load-more { background: var(--ss-surface, #fff); border: 1.5px solid var(--ss-border, #e5e7eb); border-radius: 10px; padding: 8px 24px; font-size: .82rem; font-weight: 600; cursor: pointer; transition: all .2s; }
.mur-btn-load-more:hover { border-color: #bcd2cb; background: rgba(188,210,203,.08); }

/* ── Composer media preview ── */
.mur-composer-media-btn { cursor: pointer; display: flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 8px; color: var(--ss-muted, #888); transition: all .15s; }
.mur-composer-media-btn:hover { background: var(--ss-bg, #F7F5F2); color: #2d4a43; }
.mur-composer-preview { display: flex; gap: 8px; flex-wrap: wrap; padding-top: 10px; margin-top: 10px; border-top: 1px solid var(--ss-border, #e5e7eb); }
.mur-preview-thumb { position: relative; width: 72px; height: 72px; border-radius: 10px; overflow: hidden; }
.mur-preview-thumb img { width: 100%; height: 100%; object-fit: cover; }
.mur-preview-remove { position: absolute; top: 2px; right: 2px; width: 20px; height: 20px; border-radius: 50%; background: rgba(0,0,0,.6); color: #fff; border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; font-size: .6rem; }

/* ── Post images grid ── */
/* Post images — inside card with border-radius (like Zikzak) */
.mur-post-images { display: grid; gap: 4px; margin: 12px 18px 0; border-radius: 12px; overflow: hidden; }
.mur-post-images.count-1 { grid-template-columns: 1fr; }
.mur-post-images.count-2 { grid-template-columns: 1fr 1fr; }
.mur-post-images.count-3 { grid-template-columns: 1fr 1fr; grid-template-rows: auto auto; }
.mur-post-images.count-3 .mur-post-img:first-child { grid-column: 1 / -1; }
.mur-post-images.count-4 { grid-template-columns: 1fr 1fr; }
.mur-post-img { cursor: pointer; overflow: hidden; position: relative; }
.mur-post-img img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.mur-post-images.count-1 .mur-post-img { aspect-ratio: 16/9; }
.mur-post-images.count-2 .mur-post-img { aspect-ratio: 4/3; }
.mur-post-images.count-3 .mur-post-img:first-child { aspect-ratio: 16/9; }
.mur-post-images.count-3 .mur-post-img:not(:first-child) { aspect-ratio: 1; }
.mur-post-images.count-4 .mur-post-img { aspect-ratio: 1; }
.mur-post-img:hover img { transform: scale(1.04); }

/* ── Gallery grid (sidebar) ── */
.mur-gallery-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.mur-gallery-thumb { aspect-ratio: 1; border-radius: 6px; overflow: hidden; cursor: pointer; background: var(--ss-bg, #F7F5F2); }
.mur-gallery-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .2s; }
.mur-gallery-thumb:hover img { transform: scale(1.08); }
.mur-gallery-grid .mur-widget-empty { grid-column: 1 / -1; }

/* ── Lightbox ── */
.mur-lightbox { position: fixed; inset: 0; z-index: 99999; display: flex; align-items: center; justify-content: center; }
.mur-lightbox-overlay { position: absolute; inset: 0; background: rgba(0,0,0,.85); backdrop-filter: blur(6px); }
.mur-lightbox-img { position: relative; z-index: 1; max-width: 90vw; max-height: 90vh; object-fit: contain; border-radius: 8px; box-shadow: 0 8px 40px rgba(0,0,0,.5); }
.mur-lightbox-close, .mur-lightbox-prev, .mur-lightbox-next { position: absolute; z-index: 2; background: rgba(255,255,255,.15); border: none; color: #fff; width: 44px; height: 44px; border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; font-size: 1.2rem; backdrop-filter: blur(4px); transition: background .2s; }
.mur-lightbox-close:hover, .mur-lightbox-prev:hover, .mur-lightbox-next:hover { background: rgba(255,255,255,.25); }
.mur-lightbox-close { top: 20px; right: 20px; }
.mur-lightbox-prev { left: 20px; top: 50%; transform: translateY(-50%); }
.mur-lightbox-next { right: 20px; top: 50%; transform: translateY(-50%); }

/* ── Post context menu (3-dots) ── */
.mur-menu-item { display: flex; align-items: center; gap: 8px; width: 100%; padding: 8px 12px; border: none; background: none; border-radius: 8px; font-size: .82rem; cursor: pointer; transition: background .15s; color: var(--ss-text, #1a1a1a); }
.mur-menu-item:hover { background: var(--ss-bg, #F7F5F2); }
.mur-menu-danger { color: #7B3B2C; }
.mur-menu-danger:hover { background: #fdf0ed; }

/* ═══ Stagiaires / Mon stage ═══ */
.ms-wrap, .mst-wrap { max-width: 1100px; margin: 0 auto; padding: 1rem; }
.ms-header, .mst-header { margin-bottom: 1rem; }
.ms-title, .mst-title { display: flex; align-items: center; gap: 10px; font-size: 1.25rem; margin: 0; }
.ms-title i, .mst-title i { color: var(--ss-primary, #7B6B5B); }
.ms-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.ms-card { display: flex; gap: 12px; padding: 12px; border: 1px solid var(--ss-border, #e5e1db); border-radius: 12px; background: #fff; cursor: pointer; transition: all .15s; }
.ms-card:hover { border-color: var(--ss-primary, #7B6B5B); box-shadow: 0 4px 12px rgba(0,0,0,.06); transform: translateY(-1px); }
.ms-card-past { opacity: .7; }
.ms-card-avatar { width: 48px; height: 48px; border-radius: 50%; background: var(--ss-bg, #F7F5F2); display: flex; align-items: center; justify-content: center; font-weight: 700; color: var(--ss-text-muted, #6B6B6B); font-size: .85rem; flex-shrink: 0; overflow: hidden; }
.ms-card-avatar img { width: 100%; height: 100%; object-fit: cover; }
.ms-card-body { flex: 1; min-width: 0; }
.ms-card-name { font-weight: 600; font-size: .95rem; }
.ms-card-type { font-size: .78rem; color: var(--ss-text-muted, #6B6B6B); margin-top: 2px; }
.ms-card-period { font-size: .75rem; color: var(--ss-text-muted, #6B6B6B); margin-top: 4px; }
.ms-card-pending { margin-top: 8px; font-size: .75rem; color: var(--cl-orange-fg, #6B5B3E); font-weight: 600; }
.ms-card-pending i { margin-right: 4px; }
.ms-empty { text-align: center; padding: 40px 20px; color: var(--ss-text-muted, #6B6B6B); }
.mst-empty { text-align: center; padding: 40px 20px; color: var(--ss-text-muted); background: #fff; border: 1px dashed var(--ss-border); border-radius: 12px; }

.ms-tabs { display: flex; gap: 8px; border-bottom: 1px solid var(--ss-border); margin-bottom: 1rem; }
.ms-tab { background: none; border: none; padding: 8px 14px; font-size: .85rem; color: var(--ss-text-muted); cursor: pointer; border-bottom: 2px solid transparent; }
.ms-tab.active { color: var(--ss-primary, #7B6B5B); border-bottom-color: var(--ss-primary, #7B6B5B); font-weight: 600; }
.ms-tab-pane { display: none; }
.ms-tab-pane.active { display: block; }
.ms-info-row { padding: 6px 0; font-size: .88rem; }
.ms-lbl { font-weight: 600; color: var(--ss-text-muted); margin-right: 4px; }
.ms-alert { background: var(--cl-orange-bg, #D4C4A8); border-left: 3px solid var(--cl-orange-fg, #6B5B3E); color: var(--cl-orange-fg, #6B5B3E); padding: 8px 12px; border-radius: 6px; margin-top: 12px; font-size: .85rem; }

.ms-report { border: 1px solid var(--ss-border); border-radius: 10px; padding: 12px; margin-bottom: 10px; background: #fff; }
.ms-report-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; flex-wrap: wrap; }
.ms-report-type { background: var(--cl-purple-bg, #D0C4D8); color: var(--cl-purple-fg, #5B4B6B); font-size: .7rem; padding: 2px 8px; border-radius: 10px; font-weight: 600; }
.ms-report-status { font-size: .7rem; padding: 2px 8px; border-radius: 10px; font-weight: 600; text-transform: uppercase; }
.ms-report-title { font-weight: 600; font-size: .9rem; margin-bottom: 4px; }
.ms-report-content { white-space: pre-wrap; font-size: .85rem; color: var(--ss-text); }
.ms-report-comment { background: var(--cl-green-bg, #B8C9D4); border-left: 3px solid var(--cl-green-fg, #3B4F6B); color: var(--cl-green-fg, #3B4F6B); padding: 8px 10px; border-radius: 6px; margin-top: 8px; font-size: .82rem; }
.ms-report-actions { margin-top: 10px; display: flex; gap: 6px; }
.ms-btn-sm { padding: 4px 10px; font-size: .78rem; }

.ms-eval-card { border: 1px solid var(--ss-border); border-radius: 10px; padding: 12px; margin-bottom: 10px; background: #fff; }
.ms-eval-head { display: flex; gap: 10px; align-items: center; margin-bottom: 6px; }
.ms-eval-periode { background: #D0C4D8; color: #5B4B6B; font-size: .7rem; padding: 2px 8px; border-radius: 10px; font-weight: 600; }
.ms-eval-notes { font-size: .82rem; color: var(--ss-text); margin-bottom: 6px; }

.ms-obj { border: 1px solid var(--ss-border); border-radius: 10px; padding: 10px 12px; margin-bottom: 8px; background: #fff; }
.ms-obj-status { font-size: .7rem; padding: 2px 8px; border-radius: 10px; font-weight: 600; margin-left: 8px; }
.ms-obj-en_cours { background: #B8C9D4; color: #3B4F6B; }
.ms-obj-atteint { background: #bcd2cb; color: #2d4a43; }
.ms-obj-non_atteint { background: #E2B8AE; color: #7B3B2C; }
.ms-obj-abandonne { background: #eee; color: #666; }

.ms-eval-form .ms-lbl { display: block; margin-top: 10px; margin-bottom: 4px; font-size: .78rem; }
.ms-input { width: 100%; padding: 6px 10px; border: 1px solid var(--ss-border); border-radius: 6px; font-size: .88rem; font-family: inherit; }
.ms-notes-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin-top: 10px; }

.mst-info-card { background: #fff; border: 1px solid var(--cl-border, #E8E5E0); border-radius: 14px; }
.mst-info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px 20px; font-size: .88rem; }
.mst-info-grid .ms-lbl { display: block; margin-bottom: 2px; font-size: .68rem; text-transform: uppercase; letter-spacing: .4px; color: var(--cl-text-muted, #9B9B9B); font-weight: 600; }
.mst-progress { background: var(--cl-border-light, #F0EDE8); border-radius: 20px; height: 6px; overflow: hidden; }
.mst-progress-bar { background: var(--cl-accent, #191918); height: 100%; transition: width .3s ease; }
@media (max-width: 576px) {
  .mst-wrap .stat-card { padding: 10px 12px; }
  .mst-wrap .stat-icon { width: 34px; height: 34px; font-size: 1rem; }
  .mst-wrap .stat-value { font-size: 1.2rem; }
}
.mst-statut { font-size: .72rem; padding: 2px 8px; border-radius: 10px; font-weight: 600; }
.mst-statut-prevu { background: #B8C9D4; color: #3B4F6B; }
.mst-statut-actif { background: #bcd2cb; color: #2d4a43; }
.mst-statut-termine { background: #D4C4A8; color: #6B5B3E; }
.mst-statut-interrompu { background: #E2B8AE; color: #7B3B2C; }
.mst-section { margin-top: 1.5rem; }
.mst-section-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: .75rem; }
.mst-section h4 { font-size: 1rem; margin: 0; display: flex; align-items: center; gap: 8px; }

/* ═══ Stagiaires — Checklist tâches ═══ */
.mst-form-row { display: flex; gap: 12px; }
.mst-form-row .flex-1 { flex: 1; }
.mst-section-label { margin-top: 1rem; margin-bottom: .5rem; font-weight: 600; color: var(--ss-primary, #7B6B5B); display: flex; align-items: center; gap: 6px; }
.mst-section-label i { font-size: 1.1em; }
.mst-section-label .text-muted { font-weight: 400; font-size: .75rem; margin-left: 4px; }

.mst-taches-list { max-height: 40vh; overflow-y: auto; border: 1px solid var(--ss-border, #e5e1db); border-radius: 10px; padding: 8px; background: var(--ss-bg, #F7F5F2); }
.mst-tcat-section { margin-bottom: 12px; }
.mst-tcat-section:last-child { margin-bottom: 0; }
.mst-tcat-title { font-size: .72rem; text-transform: uppercase; letter-spacing: .5px; color: var(--ss-text-muted, #6B6B6B); font-weight: 600; margin-bottom: 4px; padding: 4px 6px; }
.mst-tcat-items { display: flex; flex-direction: column; gap: 4px; }
.mst-tache-item { display: flex; align-items: center; gap: 8px; padding: 6px 10px; background: #fff; border: 1px solid transparent; border-radius: 8px; cursor: pointer; font-size: .85rem; transition: all .12s; }
.mst-tache-item:hover { border-color: var(--ss-border, #e5e1db); }
.mst-tache-item.is-checked { background: var(--cl-teal-bg, #bcd2cb); border-color: transparent; }
.mst-tache-item input[type="checkbox"] { width: 18px; height: 18px; flex-shrink: 0; cursor: pointer; }
.mst-tache-name { flex: 1; }
.mst-tache-desc { color: var(--ss-text-muted, #6B6B6B); font-size: .85em; cursor: help; }
.mst-tache-nb { width: 50px; padding: 2px 6px; border: 1px solid var(--ss-border); border-radius: 4px; font-size: .8rem; text-align: center; }
.mst-tache-nb:disabled { background: #eee; opacity: .5; }

.mst-editor-wrap { border: 1px solid var(--ss-border, #e5e1db); border-radius: 10px; overflow: hidden; margin-top: 4px; }
.mst-editor-wrap .zs-ed-content { min-height: 180px; padding: 10px 14px; background: #fff; }

.mst-content-html { white-space: normal; }
.mst-content-html p { margin: 0 0 .5em 0; }
.mst-content-html ul, .mst-content-html ol { padding-left: 1.2em; margin: .3em 0; }
.mst-content-html h2, .mst-content-html h3 { margin: .6em 0 .3em 0; }

/* Synthèse tâches dans liste report (stagiaire) */
.mst-taches-summary { background: #f5f2ed; border-radius: 8px; padding: 8px 10px; margin: 6px 0 8px; font-size: .8rem; }
.mst-tcat { margin-bottom: 4px; }
.mst-tchip { display: inline-block; background: #fff; padding: 2px 8px; border-radius: 12px; margin: 2px 3px; border: 1px solid var(--ss-border); font-size: .78rem; }

/* Évaluation tâches côté formateur */
.mst-taches-eval { background: #f8f6f2; border-radius: 10px; padding: 10px 12px; margin: 8px 0; }
.mst-tcat-eval { margin-bottom: 10px; }
.mst-tcat-eval:last-child { margin-bottom: 0; }
.mst-tcat-title-eval { font-size: .72rem; text-transform: uppercase; letter-spacing: .5px; color: var(--ss-text-muted); font-weight: 600; margin-bottom: 4px; }
.mst-tache-eval-row { display: flex; justify-content: space-between; align-items: center; padding: 5px 8px; background: #fff; border-radius: 6px; margin-bottom: 3px; font-size: .82rem; }
.mst-tache-eval-name { flex: 1; display: flex; align-items: center; gap: 6px; }
.mst-tache-eval-name i { color: var(--cl-teal-fg, #2d4a43); }

.mst-niv-buttons { display: flex; gap: 3px; }
.mst-niv-btn { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--cl-border, #E8E5E0); background: #fff; cursor: pointer; transition: all .12s; padding: 0; }
.mst-niv-btn:hover { transform: scale(1.15); }
.mst-niv-btn-acquis { border-color: var(--cl-teal-fg); }
.mst-niv-btn-acquis.active { background: var(--cl-teal-bg); border-color: var(--cl-teal-fg); box-shadow: 0 0 0 2px rgba(45,74,67,.15); }
.mst-niv-btn-en_cours { border-color: var(--cl-orange-fg); }
.mst-niv-btn-en_cours.active { background: var(--cl-orange-bg); border-color: var(--cl-orange-fg); box-shadow: 0 0 0 2px rgba(107,91,62,.15); }
.mst-niv-btn-non_acquis { border-color: var(--cl-red-fg); }
.mst-niv-btn-non_acquis.active { background: var(--cl-red-bg); border-color: var(--cl-red-fg); box-shadow: 0 0 0 2px rgba(123,59,44,.15); }
.mst-niv-btn-non_evalue { border-color: var(--cl-text-muted, #9B9B9B); }
.mst-niv-btn-non_evalue.active { background: var(--cl-neutral-bg); border-color: var(--cl-text-muted); box-shadow: 0 0 0 2px rgba(107,107,107,.15); }

.mst-niv-badge { font-size: .7rem; padding: 2px 8px; border-radius: 10px; font-weight: 600; }
.mst-niv-acquis    { background: var(--cl-teal-bg);   color: var(--cl-teal-fg); }
.mst-niv-encours   { background: var(--cl-orange-bg); color: var(--cl-orange-fg); }
.mst-niv-nonacquis { background: var(--cl-red-bg);    color: var(--cl-red-fg); }
.mst-niv-pending   { background: var(--cl-neutral-bg);color: var(--cl-neutral-fg); }

.ss-modal-lg .ss-modal-dialog { max-width: 780px; }

/* ═══ Report edit — pleine page ═══ */
.re-wrap { padding: 1rem; max-width: 1400px; margin: 0 auto; }
.re-title, .sd-title { font-size: 1.5rem; font-weight: 700; display: flex; align-items: center; gap: 10px; margin: 0; color: var(--cl-text, #1A1A1A); }
.re-title i, .sd-title i { color: var(--cl-accent, #191918); font-size: 1.3rem; }
/* Back link (breadcrumb style) — standard SpocSpace */
.re-back-link { color: var(--cl-text-muted, #9B9B9B); text-decoration: none; font-weight: 500; font-size: .82rem; }
.re-back-link:hover { color: var(--cl-accent, #191918); text-decoration: none; }
.re-back-link i { margin-right: 4px; }

/* Les 2 colonnes partagent la même hauteur (flex-stretch) */
.re-columns { align-items: stretch; }
.re-card { display: flex; flex-direction: column; }

.re-editor-wrap {
  border: 1px solid var(--cl-border, #E8E5E0); border-radius: 10px;
  overflow: hidden; background: #fff;
}
/* TipTap limité à ~5 lignes visibles, scroll interne si plus */
.re-editor-wrap .zs-ed-content { overflow-y: auto; padding: 10px 14px; max-height: 9.5rem; }
.re-editor-wrap .zs-ed-content .ProseMirror { min-height: 7rem; font-size: .9rem; line-height: 1.55; }

/* Checklist tâches — hauteur bornée, scroll interne */
.re-taches-card {
  /* Viewport - (topbar admin + toolbar + paddings) */
  max-height: calc(100vh - 160px);
  /* Position sticky en haut de la colonne pour rester visible en scroll page */
  position: sticky;
  top: 80px;
  min-height: 0;
}
@media (max-width: 992px) {
  .re-taches-card { position: static; max-height: 60vh; }
}
.re-taches-body {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.re-taches-scroll {
  flex: 1 1 auto;
  overflow-y: auto;
  min-height: 0;
  padding: 8px 10px;
}

/* Footer avec rappel pédagogique */
.re-taches-footer {
  background: var(--cl-bg, #F7F5F2);
  border-top: 1px solid var(--cl-border-light, #F0EDE8);
  font-size: .75rem;
  color: var(--cl-text-secondary, #6B6B6B);
  padding: 8px 12px;
  line-height: 1.4;
  display: flex;
  gap: 6px;
  align-items: flex-start;
}
.re-taches-footer > i { color: var(--cl-orange-fg, #6B5B3E); flex-shrink: 0; padding-top: 1px; }
.re-niv-dot {
  display: inline-block; width: 8px; height: 8px; border-radius: 50%;
  margin: 0 2px 0 4px; vertical-align: middle;
}
.re-niv-dot.re-niv-acquis    { background: var(--cl-teal-fg); }
.re-niv-dot.re-niv-en_cours  { background: var(--cl-orange-fg); }
.re-niv-dot.re-niv-non_acquis{ background: var(--cl-red-fg); }
.re-tcat { margin-bottom: 6px; }
.re-tcat-title {
  font-size: .68rem; text-transform: uppercase; letter-spacing: .5px;
  color: var(--cl-text-muted, #9B9B9B); font-weight: 600;
  padding: 2px 4px; margin-bottom: 2px;
  border-bottom: 1px solid var(--cl-border-light, #F0EDE8);
}
.re-tache-wrap { margin-bottom: 3px; }
.re-tache-wrap:last-child { margin-bottom: 0; }
.re-tache {
  display: flex; align-items: center; gap: 6px;
  padding: 4px 6px; border: 1px solid transparent; border-radius: 6px;
  cursor: pointer; font-size: .82rem; line-height: 1.2;
  transition: background .1s;
  margin: 0;
}

/* Bouton info — empêche la sélection quand cliqué */
.re-tache-info {
  background: none; border: none; padding: 0 4px;
  color: var(--cl-text-muted, #9B9B9B);
  cursor: pointer; font-size: .88rem; line-height: 1;
  display: inline-flex; align-items: center;
  border-radius: 4px;
  transition: all .1s;
}
.re-tache-info:hover { color: var(--cl-accent, #191918); background: var(--cl-surface, #fff); }
.re-tache-info.is-open { color: var(--cl-accent, #191918); background: var(--cl-sidebar-active, #EDE8E0); }

/* Panneau description (collapse) */
.re-tache-desc {
  margin: 2px 6px 0 26px;
  padding: 6px 10px;
  background: var(--cl-bg, #F7F5F2);
  border-left: 2px solid var(--cl-accent, #191918);
  border-radius: 0 6px 6px 0;
  font-size: .76rem;
  line-height: 1.4;
  color: var(--cl-text-secondary, #6B6B6B);
}
.re-tache-desc[hidden] { display: none; }
.re-tache:hover { background: var(--cl-bg, #F7F5F2); }
.re-tache.is-checked { background: var(--cl-teal-bg, #bcd2cb); border-color: transparent; }
.re-tache input[type="checkbox"] {
  width: 15px; height: 15px; margin: 0; flex-shrink: 0; cursor: pointer;
}
.re-tache-name { flex: 1; }
.re-tache-name i.bi { font-size: .8em; }
.re-tache-nb {
  width: 44px; flex-shrink: 0; text-align: center;
  padding: 1px 2px !important; height: 24px; font-size: .78rem;
}
.re-tache-nb:disabled { background: #f0f0f0; opacity: .45; }
.re-taches-search input { font-size: .82rem; padding: 4px 10px; height: 30px; }
#reCountBadge { font-size: .72rem; }
@media (max-width: 992px) {
  .re-taches-body { max-height: none; }
}

/* ═══ Rich editor — styles globaux (TipTap) ═══ */
.zs-ed-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2px;
  padding: 6px 8px;
  background: var(--ss-bg, #F7F5F2);
  border-bottom: 1px solid var(--ss-border, #e5e1db);
}
.zs-ed-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  padding: 0;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  color: var(--ss-text, #1a1a1a);
  font-size: .9rem;
  cursor: pointer;
  transition: all .12s;
}
.zs-ed-btn:hover { background: #fff; border-color: var(--ss-border, #e5e1db); }
.zs-ed-btn.is-active { background: var(--ss-primary, #7B6B5B); color: #fff; border-color: var(--ss-primary, #7B6B5B); }
.zs-ed-btn i { pointer-events: none; }
.zs-ed-sep {
  width: 1px;
  height: 18px;
  background: var(--ss-border, #e5e1db);
  margin: 0 4px;
  display: inline-block;
}
.zs-ed-content { background: #fff; }
.zs-ed-content .ProseMirror {
  outline: none;
  padding: 12px 16px;
  min-height: 200px;
  font-size: .92rem;
  line-height: 1.6;
}
.zs-ed-content .ProseMirror p { margin: 0 0 .6em 0; }
.zs-ed-content .ProseMirror p:last-child { margin-bottom: 0; }
.zs-ed-content .ProseMirror h2 { font-size: 1.3rem; margin: .8em 0 .3em; }
.zs-ed-content .ProseMirror h3 { font-size: 1.1rem; margin: .7em 0 .3em; }
.zs-ed-content .ProseMirror ul, .zs-ed-content .ProseMirror ol { padding-left: 1.4em; margin: .4em 0; }
.zs-ed-content .ProseMirror a { color: var(--ss-primary, #7B6B5B); text-decoration: underline; }
.zs-ed-content .ProseMirror blockquote { border-left: 3px solid var(--ss-border, #e5e1db); padding-left: 12px; margin: .4em 0; color: var(--ss-text-muted, #6B6B6B); }
.zs-ed-content .ProseMirror code { background: var(--ss-bg, #F7F5F2); padding: 1px 5px; border-radius: 4px; font-size: .88em; }
.zs-ed-content .ProseMirror pre { background: var(--ss-bg, #F7F5F2); padding: 8px 12px; border-radius: 8px; overflow-x: auto; }
.zs-ed-content .ProseMirror img { max-width: 100%; border-radius: 6px; }
.zs-ed-content .ProseMirror table { border-collapse: collapse; margin: .4em 0; }
.zs-ed-content .ProseMirror th, .zs-ed-content .ProseMirror td { border: 1px solid var(--ss-border, #e5e1db); padding: 4px 8px; min-width: 60px; }
.zs-ed-content .ProseMirror th { background: var(--ss-bg, #F7F5F2); font-weight: 600; }
.zs-ed-content .ProseMirror p.is-editor-empty:first-child::before {
  content: attr(data-placeholder);
  color: var(--ss-text-muted, #9B9B9B);
  float: left;
  pointer-events: none;
  height: 0;
}

/* ═══ Stagiaire detail — page pleine ═══ */
.sd-wrap { padding: 1rem; max-width: 1400px; margin: 0 auto; }
.sd-title { font-size: 1.25rem; display: flex; align-items: center; gap: 10px; margin: 0; }
.sd-title i { color: var(--cl-accent, #191918); }

/* stat-card palette SpocSpace (miroir admin.css pour la SPA employé) */
.sd-wrap .stat-card {
  background: var(--cl-surface, #fff);
  border: 1px solid var(--cl-border, #E8E5E0);
  border-radius: 14px;
  padding: 14px 16px;
  display: flex; align-items: center; gap: 12px;
  transition: box-shadow .15s;
  height: 100%;
}
.sd-wrap .stat-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,.06); }
.sd-wrap .stat-icon {
  width: 40px; height: 40px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; flex-shrink: 0;
}
.sd-wrap .stat-icon.bg-teal   { background: var(--cl-teal-bg);   color: var(--cl-teal-fg); }
.sd-wrap .stat-icon.bg-green  { background: var(--cl-green-bg);  color: var(--cl-green-fg); }
.sd-wrap .stat-icon.bg-orange { background: var(--cl-orange-bg); color: var(--cl-orange-fg); }
.sd-wrap .stat-icon.bg-red    { background: var(--cl-red-bg);    color: var(--cl-red-fg); }
.sd-wrap .stat-icon.bg-purple { background: var(--cl-purple-bg); color: var(--cl-purple-fg); }
.sd-wrap .stat-value {
  font-size: 1.4rem; font-weight: 700; line-height: 1.1;
  color: var(--cl-text, #1A1A1A);
}
.sd-wrap .stat-label { font-size: .74rem; color: var(--cl-text-muted, #9B9B9B); margin-top: 2px; text-transform: uppercase; letter-spacing: .4px; }
.sd-stat-sub { font-size: .75rem; font-weight: 500; color: var(--cl-text-muted, #9B9B9B); margin-left: 6px; }

/* Profile head */
.sd-profile-head {
  display: flex; gap: 14px; align-items: center;
}
.sd-avatar {
  width: 64px; height: 64px; border-radius: 50%;
  background: var(--cl-bg, #F7F5F2);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 1.1rem;
  color: var(--cl-text-muted, #9B9B9B);
  overflow: hidden; flex-shrink: 0;
}
.sd-avatar img { width: 100%; height: 100%; object-fit: cover; }
.sd-profile-name { font-size: 1.1rem; font-weight: 700; }
.sd-lbl { font-size: .7rem; text-transform: uppercase; letter-spacing: .5px; color: var(--cl-text-muted, #9B9B9B); font-weight: 600; margin-bottom: 2px; }

.sd-report-content { font-size: .88rem; line-height: 1.55; color: var(--cl-text, #1A1A1A); }
.sd-report-content p { margin: 0 0 .4em 0; }
.sd-report-content p:last-child { margin-bottom: 0; }

/* Modal évaluation — pattern SpocCare (classes au lieu d'inline style) */
.sd-eval-modal-dialog { max-width: 640px; }
.sd-eval-modal-content { display: flex; flex-direction: column; max-height: 85vh; }
.sd-modal-header { flex-shrink: 0; }
.sd-modal-body { flex: 1; overflow-y: auto; }
.sd-close-btn {
    width: 32px; height: 32px; border-radius: 50%;
    border: 1px solid #dee2e6;
    display: flex; align-items: center; justify-content: center;
}
.sd-close-btn i { font-size: 0.85rem; }

/* Styles nav-tabs centralisés dans ss-colors.css (global) */

/* ═══ Fiches de salaire — cards mensuelles ═══ */
.fs-wrap { padding: 1rem; max-width: 1100px; margin: 0 auto; }
.fs-year-label { min-width: 50px; text-align: center; }
.fiche-card {
    border-radius: 12px; padding: 1rem;
    display: flex; align-items: center; gap: .75rem;
    cursor: pointer; transition: transform .15s, box-shadow .15s;
    border: 1px solid var(--cl-border-light, #F0EDE8);
    background: var(--cl-surface, #fff);
}
.fiche-card:hover { transform: translateY(-2px); box-shadow: var(--cl-shadow-md); }
.fiche-dl-icon {
    color: var(--cl-text-muted, #9B9B9B); font-size: 1.1rem;
    flex-shrink: 0; transition: color .15s;
}
.fiche-card:hover .fiche-dl-icon { color: var(--cl-accent, #333); }
.fiche-card .fiche-icon {
    width: 44px; height: 44px; border-radius: 10px;
    background: var(--cl-red-bg); color: var(--cl-red-fg);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.3rem; flex-shrink: 0;
}
.fiche-info { flex: 1; min-width: 0; }
.fiche-period { font-weight: 600; font-size: .95rem; }
.fiche-meta { font-size: .78rem; color: var(--cl-text-muted, #9B9B9B); }
.fiche-empty-month {
    border-radius: 12px; padding: 1rem;
    display: flex; align-items: center; gap: .75rem;
    border: 1px dashed var(--cl-border-light, #F0EDE8);
    opacity: .55;
}
.fiche-empty-month .fiche-icon {
    background: var(--cl-bg, #F7F5F2); color: var(--cl-text-muted, #9B9B9B);
}

/* ═══ Notifications ═══ */
.notif-wrap { padding: 1rem; max-width: 900px; margin: 0 auto; }
.notif-item {
    display: flex; gap: .75rem;
    padding: .85rem 1.2rem;
    border-bottom: 1px solid var(--cl-border-light, #F0EDE8);
    cursor: pointer;
    transition: background .15s;
}
.notif-item:last-child { border-bottom: none; }
.notif-item:hover { background: var(--cl-bg, #F7F5F2); }
.notif-item.unread { background: var(--cl-teal-bg); border-left: 3px solid var(--cl-teal-fg); }
.notif-item.unread .notif-title { font-weight: 700; }
.notif-icon {
    width: 36px; height: 36px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0; font-size: .9rem;
}
.notif-icon.bg-teal   { background: var(--cl-teal-bg);   color: var(--cl-teal-fg); }
.notif-icon.bg-green  { background: var(--cl-green-bg);  color: var(--cl-green-fg); }
.notif-icon.bg-orange { background: var(--cl-orange-bg); color: var(--cl-orange-fg); }
.notif-icon.bg-red    { background: var(--cl-red-bg);    color: var(--cl-red-fg); }
.notif-icon.bg-purple { background: var(--cl-purple-bg); color: var(--cl-purple-fg); }
.notif-icon.bg-neutral{ background: var(--cl-neutral-bg);color: var(--cl-neutral-fg); }
.notif-title { font-size: .9rem; margin-bottom: 2px; }
.notif-msg   { font-size: .8rem; color: var(--cl-text-muted, #9B9B9B); line-height: 1.3; }
.notif-time  { font-size: .72rem; color: var(--cl-text-muted, #9B9B9B); margin-top: 3px; }

/* ═══ Profile page ═══ */
.prof-wrap { padding: 1rem; max-width: 1100px; margin: 0 auto; }
.prof-hero-card { border-radius: 16px; }
.prof-hero-body { display: flex; align-items: center; gap: 1.5rem; flex-wrap: wrap; padding: 1.5rem 2rem; }
.prof-avatar-img, .prof-avatar-initials {
    width: 72px; height: 72px; border-radius: 50%; flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(0,0,0,.12); cursor: pointer;
}
.prof-avatar-img { object-fit: cover; }
.prof-avatar-initials {
    background: var(--cl-accent, #191918); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.5rem; font-weight: 700; position: relative;
}
.prof-avatar-camera {
    position: absolute; bottom: -2px; right: -2px;
    background: #fff; border-radius: 50%; padding: 4px;
    font-size: .7rem; color: var(--cl-accent);
    box-shadow: 0 1px 4px rgba(0,0,0,.15);
}
.prof-name { margin: 0 0 6px; font-size: 1.4rem; font-weight: 700; }
.prof-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.prof-meta-item { font-size: .85rem; color: var(--cl-text-secondary, #6B6B6B); }
.prof-meta-item i { margin-right: 4px; }
.prof-role-badge {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 3px 10px; border-radius: 20px;
    font-size: .78rem; font-weight: 600;
    background: var(--cl-teal-bg); color: var(--cl-teal-fg);
    border: 1px solid rgba(0,0,0,.05);
}
.prof-role-admin { background: var(--cl-red-bg); color: var(--cl-red-fg); }
.prof-role-direction { background: var(--cl-purple-bg); color: var(--cl-purple-fg); }
.prof-role-responsable { background: var(--cl-green-bg); color: var(--cl-green-fg); }
.prof-role-stagiaire { background: var(--cl-orange-bg); color: var(--cl-orange-fg); }

.prof-info-row {
    display: flex; align-items: flex-start; gap: 14px;
    padding: 12px 0; border-bottom: 1px solid var(--cl-border-light, #F0EDE8);
}
.prof-info-row:last-child { border-bottom: none; }
.prof-info-icon {
    width: 32px; height: 32px; border-radius: 8px;
    background: var(--cl-bg, #F7F5F2);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.prof-info-icon i { color: var(--cl-accent, #191918); font-size: .95rem; }
.prof-info-label {
    font-size: .7rem; font-weight: 600;
    text-transform: uppercase; letter-spacing: .5px;
    color: var(--cl-text-muted, #9B9B9B); margin-bottom: 2px;
}
.prof-taux { font-weight: 600; color: var(--cl-teal-fg); }
.prof-modules { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 2px; }
.prof-module-chip {
    display: inline-block;
    background: var(--cl-bg, #F7F5F2);
    color: var(--cl-text-secondary, #6B6B6B);
    padding: 2px 10px; border-radius: 12px;
    font-size: .8rem; font-weight: 500;
    border: 1px solid var(--cl-border, #E8E5E0);
}

/* Champs password avec œil */
.pwd-field-wrap { position: relative; }
.pwd-field-wrap input { padding-right: 40px; }
.pwd-eye {
    position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
    cursor: pointer; color: var(--cl-text-muted, #9B9B9B); font-size: 1rem;
    line-height: 1; padding: 4px; user-select: none; z-index: 5;
}
.pwd-eye:hover { color: var(--cl-text, #1A1A1A); }
.pwd-strength { margin-top: 6px; font-size: .72rem; }
.pwd-check { margin-right: 8px; }
.pwd-check.ok { color: var(--cl-teal-fg, #2d4a43); }
.pwd-check.ko { color: var(--cl-red-fg, #7B3B2C); }

/* ═══ Votes planning ═══ */
.votes-wrap { padding: 1rem; max-width: 900px; margin: 0 auto; }
.proposal-card {
    border-radius: 12px;
    border: 2px solid var(--cl-border, #E8E5E0);
    background: var(--cl-surface, #fff);
    overflow: hidden;
    transition: all .2s;
}
.proposal-card.voted-pour   { border-color: var(--cl-teal-fg); }
.proposal-card.voted-contre { border-color: var(--cl-red-fg); }
.proposal-header {
    padding: 12px 16px; font-weight: 700; font-size: 1rem;
    display: flex; justify-content: space-between; align-items: center;
}
.proposal-body { padding: 12px 16px; }
.vote-bar { height: 8px; border-radius: 4px; background: var(--cl-border-light, #F0EDE8); overflow: hidden; margin: 4px 0 8px; }
.vote-bar-fill { height: 100%; transition: width .3s; }
.vote-bar-pour { background: var(--cl-teal-fg); }
.vote-btn-group { display: flex; gap: 8px; margin-top: 12px; }
.vote-btn {
    flex: 1; padding: 10px; border-radius: 8px;
    border: 2px solid var(--cl-border, #E8E5E0);
    background: transparent; font-weight: 600; font-size: .9rem;
    cursor: pointer; transition: all .15s;
    display: flex; align-items: center; justify-content: center; gap: 6px;
}
.vote-btn.pour { color: var(--cl-teal-fg); }
.vote-btn.pour:hover, .vote-btn.pour.active {
    background: var(--cl-teal-bg); border-color: var(--cl-teal-fg);
}
.vote-btn.contre { color: var(--cl-red-fg); }
.vote-btn.contre:hover, .vote-btn.contre.active {
    background: var(--cl-red-bg); border-color: var(--cl-red-fg);
}

/* ═══ Home dashboard ═══ */
.home-wrap { padding: 1rem; max-width: 1400px; margin: 0 auto; }
.home-wrap .stat-card { cursor: pointer; color: var(--cl-text, #1A1A1A); }
.home-wrap .stat-card:hover { text-decoration: none; }
.home-week-label { font-size: .85rem; font-weight: 600; min-width: 160px; text-align: center; }
.home-loading { text-align: center; padding: 2rem; color: var(--cl-text-muted, #9B9B9B); }

/* Home modals */
.home-modal-dialog { max-width: 540px; }
.home-cancel-dialog { max-width: 420px; }
.home-close-btn {
    width: 32px; height: 32px; border-radius: 50%;
    border: 1px solid var(--cl-border, #E8E5E0);
    display: flex; align-items: center; justify-content: center;
}
.home-close-btn i { font-size: .85rem; }
.home-modal-body { max-height: 60vh; overflow-y: auto; }
.home-cancel-icon { color: var(--cl-red-fg); font-size: 1.1rem; }

/* ═══ Planning — classes pour remplacer inline styles ═══ */
.plan-btn-nav { height: 34px; padding: 0 8px; }
.plan-btn-left { border-radius: 6px 0 0 6px; border-right: 0; }
.plan-btn-right { border-radius: 0 6px 6px 0; border-left: 0; }
.plan-month-input { width: 155px; height: 34px; border-radius: 0; }
.plan-rows-sel { width: auto; height: 34px; }
.plan-btn-34 { height: 34px; }
.plan-btn-group-34 > .btn { height: 34px; }
.plan-filter-badge {
    background: var(--cl-border-light, #F0EDE8);
    color: var(--cl-text, #1A1A1A);
    margin-left: 4px;
}
.plan-filter-dialog { max-width: 520px; }
.plan-filter-body { padding: 1rem 1.25rem; }
.plan-filter-label {
    font-size: .72rem; text-transform: uppercase;
    letter-spacing: .5px; font-weight: 600;
    color: var(--cl-text-muted, #9B9B9B);
}
.plan-filter-mini-btn { font-size: .75rem; padding: 2px 10px; }
.plan-filter-mini-danger { color: var(--cl-red-fg); border-color: var(--cl-red-bg); }
.plan-filter-list {
    max-height: calc(100vh - 380px); min-height: 250px;
    overflow-y: auto;
    background: var(--cl-bg, #F7F5F2);
    border: 1px solid var(--cl-border, #E8E5E0);
    border-radius: 8px; padding: 4px 0;
}

/* ── Desirs SSR layout ── */
#desirFormCard { flex: 0 0 380px; }
.desir-right-panel { flex: 1; min-width: 300px; display: flex; flex-direction: column; gap: 0; }
.desir-detail-panel {
    padding: .85rem 1.1rem; font-size: .9rem; color: var(--ss-text, #2c2c2c);
    background: #faf7f0; border-bottom: 1px solid var(--ss-border-light, #e8e4da);
    border-left: 3px solid var(--ss-teal, #2a9d8f);
}
.desir-perm-header { border-top: 1px solid var(--border-color, #e1e5eb); }
.desir-banner-readonly {
    margin: 0.75rem 0 0; padding: 0.6rem 0.8rem; font-size: 0.8rem;
    border-radius: 8px; background: #fff8e1; border: 1px solid #f4d03f; color: #7d5d0e;
}
.desir-banner-info {
    margin: 0.75rem 0 0; padding: 0.6rem 0.8rem; font-size: 0.8rem;
    border-radius: 8px; background: rgba(26,26,26,0.04); border: 1px solid #d1cfc5; color: #1a1a1a;
}
.desir-banner-perm { font-size: 0.8rem; }
.desir-submit-btn { border-radius: 10px; padding: 10px 20px; }
.desir-badge-perm {
    background: rgba(255,193,7,0.15); color: #d4a017;
    font-size: 0.68rem; border: 1px solid rgba(255,193,7,0.3);
}
.desir-badge-modif {
    background: #fff3cd; color: #856404; border: 1px solid #ffc107;
}
.desir-badge-modif-small {
    background: #fff3cd; color: #856404; font-size: 0.68rem; border: 1px solid #ffc107;
}
.desir-badge-pending {
    background: #fff3cd; color: #856404; border: 1px solid #ffc107;
}

/* ── Vacances SSR helpers ── */
.vac-sw-valide { background: #a5d6a7; }
.vac-sw-attente { background: #ffe082; }
.vac-module-filter { width: 170px; }

/* ═══ Absences SSR layout ═══ */
.abs-layout { display: flex; gap: .75rem; flex-wrap: wrap; }
.abs-form-card { flex: 0 0 360px; }
.abs-list-card { flex: 1; min-width: 300px; }
.abs-empty-cell { padding: 2rem; }
.abs-icon-ok { color: #2d4a43; }
.abs-icon-no { color: #7B3B2C; }
.abs-toolbar-sep { width: 1px; height: 24px; background: rgba(255,255,255,.25); margin: 0 4px; }
.chg-exchange-has-details { position: relative; }
.abs-lb-download { text-align: center; color: #fff; }
.abs-lb-download-icon { font-size: 5rem; }
.abs-lb-download-link { color: #fff; text-decoration: underline; }
@media (max-width: 768px) {
  .abs-layout { flex-direction: column; }
  .abs-form-card { flex: 1 1 auto; }
}

/* ═══════════════════════════════════════════════
   Cuisine shared styles (modal, form, radio)
   ═══════════════════════════════════════════════ */

/* -- Modal layout -- */
.cuis-modal-dialog-md   { max-width: 540px; }
.cuis-modal-dialog-sm   { max-width: 520px; }
.cuis-modal-dialog-xs   { max-width: 420px; }
.cuis-modal-dialog-cf   { max-width: 480px; }
.cuis-modal-flex         { display: flex; flex-direction: column; max-height: 85vh; }
.cuis-modal-header-fix   { flex-shrink: 0; }
.cuis-modal-body-scroll  { flex: 1; overflow-y: auto; }
.cuis-modal-footer-fix   { flex-shrink: 0; }

/* -- Modal close button (round X) -- */
.cuis-modal-close {
  width: 32px; height: 32px; border-radius: 50%;
  border: 1px solid var(--cl-border, #E8E5E0);
}
.cuis-modal-close .bi-x-lg { font-size: 0.85rem; }

/* -- Card header title inline -- */
.cuis-h3-inline { margin: 0; }

/* -- Form label bold -- */
.cuis-label-bold { font-weight: 600; }

/* -- Form group spacing -- */
.cuis-field-group { margin-bottom: 1rem; }
.cuis-field-group-last { margin-bottom: 0; }
.cuis-field-group-rel { margin-bottom: 1rem; position: relative; }

/* -- Menu choice radio cards -- */
.cuis-choix-row { display: flex; gap: 0.5rem; }
.menu-choix-option {
  flex: 1; display: flex; align-items: center; gap: 0.5rem;
  padding: 0.7rem 1rem; border: 2px solid var(--cl-border, #E8E5E0);
  border-radius: 10px; cursor: pointer; transition: all 0.15s;
}
.menu-choix-option.active {
  border-color: var(--ss-teal);
  background: var(--ss-accent-bg);
}
.menu-choix-option input[type="radio"] { display: none; }
.cuis-choix-icon { font-size: 1.2rem; }
.cuis-choix-icon-menu { color: var(--ss-orange); }
.cuis-choix-icon-salade { color: var(--cl-teal-fg, #2d4a43); }
.cuis-choix-label { font-weight: 700; font-size: 0.9rem; }

/* -- Payment radio pills -- */
.cuis-pay-row { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.menu-pay-option {
  display: flex; align-items: center; gap: 0.4rem;
  padding: 0.45rem 0.9rem; border: 1.5px solid var(--cl-border, #E8E5E0);
  border-radius: 8px; cursor: pointer; transition: all 0.15s;
}
.menu-pay-option.active {
  border-color: var(--ss-teal);
  background: var(--ss-accent-bg);
}
.menu-pay-option input[type="radio"] { accent-color: var(--ss-teal); }

/* -- Autocomplete results scrollable -- */
.cuis-autocomplete-scroll { max-height: 200px; overflow-y: auto; }

/* -- Quick tags row -- */
.cuis-quick-tags { display: flex; gap: 0.3rem; flex-wrap: wrap; margin-top: 0.5rem; }

/* -- Width-auto for inline selects -- */
.cuis-w-auto { width: auto; }

/* -- Card body scroll -- */
.cuis-card-body-scroll { max-height: 400px; overflow-y: auto; }

/* ── cuisine-home.php ── */
.ch-week-label { font-weight: 600; min-width: 180px; text-align: center; }

/* ── cuisine.php ── */
.cu-week-label { font-size: 0.85rem; font-weight: 600; min-width: 160px; text-align: center; }

/* ── cuisine-reservations.php ── */
.cr-stat-icon-couverts { background: #bcd2cb; color: var(--cl-teal-fg, #2d4a43); }
.cr-stat-icon-menu     { background: #B8C9D4; color: #3B4F6B; }
.cr-stat-icon-salade   { background: #D0C4D8; color: #5B4B6B; }
.cr-date-input {
  max-width: 180px; border-radius: 8px;
  border: 1.5px solid var(--cl-border, #E0DCD4);
  height: 38px; font-size: 0.88rem;
}
.cr-print-btn { border-radius: 8px; height: 38px; padding: 0 16px; }

/* ── cuisine-vip.php ── */
.cv-page-header {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 0.75rem;
}
.cv-hint-pill {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.6rem 1.2rem; background: var(--cl-bg, #F0EDE8);
  border-radius: 50px; font-size: 0.82rem; color: var(--cl-text-muted, #4A4840);
}
.cv-kbd {
  background: var(--cl-border, #E8E5E0); padding: 1px 6px;
  border-radius: 4px; font-size: 0.78rem; font-weight: 600;
}
.cv-new-session-btn { border-radius: 8px; }
.cv-session-badge {
  background: #bcd2cb; color: var(--cl-teal-fg, #2d4a43);
  font-size: 0.8rem; padding: 6px 14px; border-radius: 8px;
}
#cvHistorySelect { width: 260px; }
#crRepasSelect { width: 130px; }

/* ── cuisine-menus.php ── */
.cm-spinner-full { grid-column: 1 / -1; }

/* ── cuisine-famille.php ── */
.cf-date-input { max-width: 180px; }
.cf-repas-select { max-width: 120px; }

/* ── Inline-style replacements ─────────────────────────────────────────────── */
.ss-loading-cell { padding: 2rem; }
.sd-filter-select { max-width: 200px; }
.doc-service-cards-row { display: flex; gap: .75rem; flex-wrap: wrap; margin-bottom: 1.5rem; }

/* ── Utility: JS-toggled hidden (no !important, overridable by inline style.display) ── */
.ss-hide { display: none; }

/* ── Covoiturage ── */
.cov-page-header { display: flex; justify-content: space-between; align-items: center; }
.cov-buddies-btn { background: var(--ss-accent-bg); color: var(--ss-text); font-weight: 500; }
.cov-search-icon { background: var(--ss-bg-card); border-right: none; }
.cov-search-input { border-left: none; }
.cov-week-label { min-width: 180px; text-align: center; }
.cov-alert-hint { background: var(--ss-bg); border: 1px solid var(--ss-border); border-left: 4px solid var(--ss-teal); }
.cov-alert-hint-icon { font-size: 1.5rem; color: var(--ss-teal); }

/* ── Desirs ── */
.des-horaire-badge { color: #fff; }

/* ── Wiki ── */
.wk-filters { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.wk-tag-filters { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; align-items: center; }
.wk-empty-icon { font-size: 2.5rem; display: block; margin-bottom: 8px; opacity: .3; }

/* ── Repartition ── */
.rep-page-header { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 0.5rem; }
.rep-modal-sm { max-width: 480px; }
.rep-modal-close-btn {
  width: 32px; height: 32px; border-radius: 50%;
  border: 1px solid var(--ss-border);
  display: flex; align-items: center; justify-content: center;
}
.rep-modal-close-icon { font-size: .85rem; }
.rep-modal-body { padding: 0; max-height: 60vh; overflow-y: auto; }

/* ── Emails ── */
.em-title { font-weight: 700; }
.em-empty-detail { padding: 60px 20px; }
.em-empty-icon { font-size: 2.5rem; opacity: .2; display: block; margin-bottom: 8px; }
.em-empty-text { font-size: .88rem; }
.em-search-wrap { position: relative; }

/* ── Annonces ── */
.ann-ack-alert {
  margin-bottom: 1rem; padding: .7rem 1rem;
  background: var(--ss-bg); border: 1px solid var(--ss-border);
  border-radius: 10px; font-size: .85rem; color: var(--ss-red);
}

/* ── Login ── */
.lgn-pwd-wrap { position: relative; }
.lgn-pwd-input { padding-right: 42px; }
.lgn-pwd-eye {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  cursor: pointer; color: var(--ss-text-muted); font-size: 1.1rem;
  line-height: 1; padding: 4px; user-select: none; z-index: 5;
}

/* ═══ Notifications — filtres + archivage ═══ */
.notif-filters {
    display: flex; gap: 6px; flex-wrap: wrap;
}
.notif-filter-btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 6px 14px; border-radius: 20px;
    font-size: .82rem; font-weight: 500; text-decoration: none;
    color: var(--cl-text-secondary, #6B6B6B);
    background: var(--cl-surface, #fff);
    border: 1px solid var(--cl-border, #E8E5E0);
    transition: all .15s; cursor: pointer;
}
.notif-filter-btn:hover {
    color: var(--cl-text, #1A1A1A);
    border-color: var(--cl-border-hover, #D4D0CA);
    background: var(--cl-sidebar-hover, #F0EDE8);
    text-decoration: none;
}
.notif-filter-btn.active {
    color: var(--cl-accent, #191918);
    background: var(--cl-sidebar-active, #EDE8E0);
    border-color: var(--cl-accent, #191918);
    font-weight: 600;
}
.notif-filter-count {
    background: var(--cl-border-light, #F0EDE8);
    color: var(--cl-text-secondary, #6B6B6B);
    font-size: .7rem; font-weight: 700;
    padding: 1px 7px; border-radius: 10px;
    min-width: 18px; text-align: center;
}
.notif-filter-count-unread {
    background: var(--cl-teal-bg); color: var(--cl-teal-fg);
}
.notif-archive-btn {
    background: none; border: none; cursor: pointer;
    color: var(--cl-text-muted, #9B9B9B);
    padding: 6px 8px; border-radius: 6px;
    font-size: .9rem; transition: all .12s;
    flex-shrink: 0; display: flex; align-items: center;
    opacity: 0; /* visible au hover de la ligne */
}
.notif-item:hover .notif-archive-btn { opacity: 1; }
.notif-archive-btn:hover {
    background: var(--cl-bg, #F7F5F2);
    color: var(--cl-accent, #191918);
}

/* ═══ Fiche highlight (depuis notification) ═══ */
.fiche-highlight {
    outline: 2px solid var(--cl-teal-fg, #2d4a43);
    outline-offset: 3px;
    animation: ficheHighlightPulse 1.5s ease-in-out 2;
}
@keyframes ficheHighlightPulse {
    0%, 100% { outline-color: var(--cl-teal-fg, #2d4a43); }
    50% { outline-color: transparent; }
}

/* ═══ PDF Lightbox (réutilisable) ═══ */
.ss-lightbox {
    position: fixed; inset: 0; z-index: 9999;
    background: rgba(0,0,0,.85);
    display: flex; align-items: center; justify-content: center;
    backdrop-filter: blur(4px);
    animation: ssLbFadeIn .2s ease-out;
}
@keyframes ssLbFadeIn { from { opacity: 0; } to { opacity: 1; } }
.ss-lightbox-wrap {
    display: flex; flex-direction: column;
    max-width: 90vw; max-height: 92vh;
    border-radius: 14px; overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,.3);
}
.ss-lightbox-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 10px 16px;
    background: #2c3e50;
}
.ss-lightbox-title {
    color: rgba(255,255,255,.85); font-size: .85rem;
    display: flex; align-items: center; gap: 6px;
}
.ss-lightbox-close {
    width: 32px; height: 32px; border-radius: 50%;
    background: rgba(255,255,255,.12); border: none;
    color: #fff; font-size: 1rem;
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    transition: background .15s;
    flex-shrink: 0;
}
.ss-lightbox-close:hover { background: rgba(255,255,255,.25); }
.ss-lightbox-content { flex: 1; min-height: 0; }
.ss-lightbox-content iframe {
    width: 80vw; height: 78vh;
    border: none; background: #fff; display: block;
}
.ss-lightbox-content img {
    max-width: 90vw; max-height: 78vh;
    object-fit: contain; display: block;
}
.ss-lightbox-footer {
    display: flex; gap: 8px; align-items: center; justify-content: center;
    padding: 12px 16px;
    background: #2c3e50;
}
.ss-lightbox-btn {
    padding: 7px 14px; border-radius: 8px;
    background: rgba(255,255,255,.1); border: none;
    color: rgba(255,255,255,.85); font-size: .82rem;
    cursor: pointer; text-decoration: none;
    display: flex; align-items: center; gap: 6px;
    transition: background .15s, color .15s;
}
.ss-lightbox-btn:hover { background: #d4c4a8; color: #2c3e50; }
/* Fullscreen */
.ss-lightbox-wrap:fullscreen { max-width: 100vw; max-height: 100vh; border-radius: 0; }
.ss-lightbox-wrap:fullscreen .ss-lightbox-content iframe { width: 100vw; height: calc(100vh - 96px); }
.ss-lightbox-wrap:fullscreen .ss-lightbox-header,
.ss-lightbox-wrap:fullscreen .ss-lightbox-footer { border-radius: 0; }

/* ═══ Global modal blur effect ═══ */
.modal-backdrop { backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); background: rgba(0,0,0,.3) !important; }
.modal-backdrop.show { opacity: 1 !important; }
