﻿/* ============================================================
   MonClubPro — Design System
   Brand: navy #1B4F72 / gold #F39C12 (conforme CLAUDE.md)
   Inspiration d'exécution : Linear · Vercel · Superhuman
   ============================================================ */

/* ---- Police : Inter, servie en local (offline-first, fallback système natif) ---- */
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400; font-display: swap; src: url("../vendor/inter/inter-latin-400-normal.73aaa95eab31.woff2") format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 500; font-display: swap; src: url("../vendor/inter/inter-latin-500-normal.96948ea7ac03.woff2") format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 600; font-display: swap; src: url("../vendor/inter/inter-latin-600-normal.0bf7eadca131.woff2") format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 700; font-display: swap; src: url("../vendor/inter/inter-latin-700-normal.2a4c97ec45ef.woff2") format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 800; font-display: swap; src: url("../vendor/inter/inter-latin-800-normal.9b96e5d17b9b.woff2") format('woff2'); }

:root {
  /* — Marque — */
  --primary: #1B4F72;
  --primary-dark: #143A56;
  --primary-darker: #0D2A40;
  --primary-light: #2E86C1;
  --accent: #F39C12;
  --accent-dark: #D68910;
  --accent-light: #F8C471;

  /* Teintes alpha (overlays, halos, focus) */
  --primary-a08: rgba(27, 79, 114, 0.08);
  --primary-a12: rgba(27, 79, 114, 0.12);
  --primary-a16: rgba(27, 79, 114, 0.16);
  --accent-a12: rgba(243, 156, 18, 0.12);
  --accent-a20: rgba(243, 156, 18, 0.20);

  /* — Sémantique — */
  --danger: #E5484D;
  --danger-bg: #FEF1F1;
  --success: #2BA471;
  --success-bg: #E7F7EF;
  --warning: #F39C12;
  --warning-bg: #FEF6E6;
  --info: #2E86C1;
  --info-bg: #EAF3FB;

  /* — Rampe de neutres (slate) — */
  --slate-50:  #F8FAFC;
  --slate-100: #F1F4F8;
  --slate-150: #E9EEF4;
  --slate-200: #E1E7EF;
  --slate-300: #CBD3DE;
  --slate-400: #94A3B4;
  --slate-500: #64748B;
  --slate-600: #475569;
  --slate-700: #334155;
  --slate-800: #1E293B;
  --slate-900: #0F172A;

  /* Alias historiques (compatibilité templates) */
  --text-dark: var(--slate-800);
  --text-muted: var(--slate-500);
  --bg-light: var(--slate-100);
  --bg-white: #FFFFFF;
  --border-color: var(--slate-200);

  /* — Layout — */
  --sidebar-width: 220px;
  --header-height: 62px;

  /* — Rayons — */
  --radius-sm: 7px;
  --radius: 10px;
  --radius-lg: 14px;
  --radius-pill: 999px;

  /* — Système d'élévation (ombres douces multi-couches) — */
  --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04), 0 1px 1px rgba(15, 23, 42, 0.03);
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04), 0 2px 6px rgba(15, 23, 42, 0.05);
  --shadow: 0 1px 3px rgba(15, 23, 42, 0.05), 0 4px 12px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 2px 6px rgba(15, 23, 42, 0.06), 0 10px 24px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 8px 24px rgba(15, 23, 42, 0.10), 0 20px 48px rgba(15, 23, 42, 0.12);
  --ring: 0 0 0 3px var(--primary-a16);

  /* — Transitions — */
  --t-fast: 120ms cubic-bezier(0.4, 0, 0.2, 1);
  --t: 180ms cubic-bezier(0.4, 0, 0.2, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

::selection { background: var(--accent-a20); color: var(--primary-darker); }

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Ubuntu', sans-serif;
  font-size: 14px;
  line-height: 1.55;
  color: var(--text-dark);
  background: var(--bg-light);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
}

/* Chiffres tabulaires partout où l'alignement compte */
table td, table th, .stat-value, .saison-badge,
.fcfa, [class*="montant"], .badge { font-variant-numeric: tabular-nums; }

a { color: var(--primary-light); text-decoration: none; transition: color var(--t-fast); }
a:hover { color: var(--primary); }

/* Accessibilité : anneau de focus clavier homogène */
:focus-visible {
  outline: none;
  box-shadow: var(--ring);
  border-radius: var(--radius-sm);
}

/* ===== Layout ===== */
.app-wrapper { display: flex; min-height: 100vh; }

/* ===== Sidebar ===== */
.sidebar {
  width: var(--sidebar-width);
  height: 100vh;
  height: 100dvh;
  background: linear-gradient(185deg, var(--primary) 0%, var(--primary-dark) 70%, var(--primary-darker) 100%);
  color: #fff;
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 100;
  transition: width var(--t);
  box-shadow: inset -1px 0 0 rgba(255, 255, 255, 0.04);
}

/* Logo et footer ne se compriment jamais ; seul le nav scrolle */
.sidebar-logo,
.sidebar-footer { flex-shrink: 0; }
.sidebar-nav { min-height: 0; }

.sidebar-logo {
  padding: 20px 18px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  text-align: center;
}

.sidebar-logo h1 {
  font-size: 19px;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: -0.3px;
}

.sidebar-logo span {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.55);
  display: block;
  margin-top: 3px;
  letter-spacing: 0.2px;
}

.sidebar-nav {
  flex: 1;
  padding: 10px 12px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.18) transparent;
}
.sidebar-nav::-webkit-scrollbar { width: 6px; }
.sidebar-nav::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.15); border-radius: 3px; }

.nav-section-label {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: rgba(255, 255, 255, 0.38);
  padding: 16px 10px 6px;
}

.nav-item {
  display: flex;
  align-items: center;
  padding: 9px 12px;
  margin: 1px 0;
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  border-radius: var(--radius-sm);
  transition: background var(--t-fast), color var(--t-fast), transform var(--t-fast);
  font-size: 13.5px;
  font-weight: 500;
  gap: 11px;
  position: relative;
}

.nav-item:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

/* État actif = pill rempli + accent latéral lumineux (style Linear) */
.nav-item.active {
  background: rgba(255, 255, 255, 0.13);
  color: #fff;
  font-weight: 600;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}
.nav-item.active::before {
  content: '';
  position: absolute;
  left: -12px;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 18px;
  background: var(--accent);
  border-radius: 0 3px 3px 0;
  box-shadow: 0 0 10px var(--accent-a20);
}

.nav-item .nav-icon {
  width: 18px;
  text-align: center;
  flex-shrink: 0;
  font-size: 14px;
  opacity: 0.9;
}
.nav-item.active .nav-icon { color: var(--accent-light); opacity: 1; }

.sidebar-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 12px;
}

.sidebar-user {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  padding: 4px;
}

.sidebar-user .avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(243, 156, 18, 0.35);
}

.sidebar-user .user-info { overflow: hidden; }

.sidebar-user .user-name {
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar-user .user-role {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
}

.btn-logout {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 9px 12px;
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: all var(--t-fast);
}

.btn-logout:hover {
  background: rgba(229, 72, 77, 0.22);
  border-color: rgba(229, 72, 77, 0.35);
  color: #fff;
}

/* ===== Main content ===== */
.main-content {
  margin-left: var(--sidebar-width);
  flex: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ===== Top header ===== */
.top-header {
  height: var(--header-height);
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--slate-200);
  display: flex;
  align-items: center;
  padding: 0 26px;
  gap: 16px;
  position: sticky;
  top: 0;
  z-index: 50;
}

.header-title {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.2px;
  color: var(--slate-900);
  flex: 1;
}

.header-subtitle {
  font-size: 12.5px;
  color: var(--text-muted);
  font-weight: 400;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.saison-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--primary-a08);
  color: var(--primary);
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 600;
  border: 1px solid var(--primary-a12);
}

/* ===== Page content ===== */
.page-content {
  padding: 26px;
  flex: 1;
  max-width: 1600px;
  width: 100%;
}

/* ===== Cards ===== */
.card {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--slate-150);
  overflow: hidden;
  transition: box-shadow var(--t), border-color var(--t);
}

.card-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--slate-150);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.card-header h2 {
  font-size: 14.5px;
  font-weight: 700;
  letter-spacing: -0.1px;
  color: var(--slate-800);
  display: flex;
  align-items: center;
  gap: 8px;
}

.card-body { padding: 20px; }

/* ===== Stat cards (dashboard) ===== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--slate-150);
  display: flex;
  align-items: center;
  gap: 16px;
  transition: transform var(--t), box-shadow var(--t), border-color var(--t);
  position: relative;
  overflow: hidden;
}

.stat-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(120deg, transparent 60%, var(--slate-50));
  opacity: 0;
  transition: opacity var(--t);
  pointer-events: none;
}

.stat-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--slate-200);
}
.stat-card:hover::after { opacity: 1; }

/* Carte statistique cliquable (navigable) */
a.stat-card-link {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}
a.stat-card-link:hover { border-color: var(--primary-light); }
/* Chevron d'affordance, masqué jusqu'au survol */
a.stat-card-link .stat-go {
  position: absolute;
  top: 14px; right: 14px;
  color: var(--slate-300);
  font-size: 12px;
  opacity: 0;
  transform: translateX(-4px);
  transition: opacity var(--t-fast), transform var(--t-fast), color var(--t-fast);
}
a.stat-card-link:hover .stat-go { opacity: 1; transform: translateX(0); color: var(--primary-light); }

.stat-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 21px;
  flex-shrink: 0;
}

.stat-icon.blue { background: linear-gradient(135deg, var(--primary-a12), var(--primary-a08)); color: var(--primary); }
.stat-icon.orange { background: linear-gradient(135deg, var(--accent-a20), var(--accent-a12)); color: var(--accent-dark); }
.stat-icon.green { background: linear-gradient(135deg, rgba(43,164,113,0.16), rgba(43,164,113,0.08)); color: var(--success); }
.stat-icon.red { background: linear-gradient(135deg, rgba(229,72,77,0.16), rgba(229,72,77,0.08)); color: var(--danger); }
.stat-icon.purple { background: linear-gradient(135deg, rgba(142,68,173,0.16), rgba(142,68,173,0.08)); color: #8E44AD; }

.stat-info { flex: 1; min-width: 0; }
.stat-value {
  font-size: 27px;
  font-weight: 800;
  letter-spacing: -0.6px;
  color: var(--slate-900);
  line-height: 1.15;
}
.stat-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 3px;
  font-weight: 500;
}

/* ===== Tables ===== */
.table-container { overflow-x: auto; }

table { width: 100%; border-collapse: collapse; }

table th {
  background: var(--slate-50);
  padding: 11px 14px;
  text-align: left;
  font-size: 11px;
  font-weight: 700;
  color: var(--slate-500);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  border-bottom: 1px solid var(--slate-200);
  white-space: nowrap;
}

table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--slate-150);
  vertical-align: middle;
  color: var(--slate-700);
}

table tr:last-child td { border-bottom: none; }
table tbody tr { transition: background var(--t-fast); }
table tbody tr:hover td { background: var(--primary-a08); }

/* ===== Badges / Statuts ===== */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
  letter-spacing: 0.1px;
  border: 1px solid transparent;
}

.badge-actif, .badge-paye, .badge-present { background: var(--success-bg); color: #1B7A53; border-color: rgba(43,164,113,0.2); }
.badge-inactif { background: var(--slate-100); color: var(--slate-500); border-color: var(--slate-200); }
.badge-suspendu, .badge-impaye, .badge-absent { background: var(--danger-bg); color: #C13438; border-color: rgba(229,72,77,0.2); }
.badge-planifie { background: var(--info-bg); color: #1F6391; border-color: rgba(46,134,193,0.2); }
.badge-termine { background: var(--success-bg); color: #1B7A53; border-color: rgba(43,164,113,0.2); }
.badge-annule { background: var(--slate-100); color: var(--slate-500); border-color: var(--slate-200); }
.badge-en_cours { background: var(--warning-bg); color: #9A6C0A; border-color: rgba(243,156,18,0.22); }
.badge-partiel { background: var(--warning-bg); color: #9A6C0A; border-color: rgba(243,156,18,0.22); }
.badge-retard { background: var(--warning-bg); color: #9A6C0A; border-color: rgba(243,156,18,0.22); }
.badge-excuse { background: var(--info-bg); color: #1F6391; border-color: rgba(46,134,193,0.2); }
.badge-legere { background: var(--success-bg); color: #1B7A53; }
.badge-moderee { background: var(--warning-bg); color: #9A6C0A; }
.badge-grave { background: var(--danger-bg); color: #C13438; }
.badge-critique { background: #922B21; color: #fff; }
.badge-admin { background: var(--primary); color: #fff; }
.badge-coach { background: var(--accent); color: #fff; }
.badge-medecin { background: #16A085; color: #fff; }
.badge-secretaire { background: var(--slate-500); color: #fff; }

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 9px 16px;
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  border: 1px solid transparent;
  text-decoration: none;
  transition: background var(--t-fast), border-color var(--t-fast), box-shadow var(--t-fast), transform var(--t-fast);
  white-space: nowrap;
  letter-spacing: -0.1px;
  user-select: none;
}

.btn:active { transform: translateY(0.5px) scale(0.99); }

.btn-primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 1px 2px rgba(27, 79, 114, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}
.btn-primary:hover { background: var(--primary-dark); box-shadow: 0 4px 12px rgba(27, 79, 114, 0.28); color: #fff; }

.btn-accent {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 1px 2px rgba(243, 156, 18, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}
.btn-accent:hover { background: var(--accent-dark); box-shadow: 0 4px 12px rgba(243, 156, 18, 0.32); color: #fff; }

.btn-success { background: var(--success); color: #fff; }
.btn-success:hover { background: #228A5F; color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #CF3A3F; color: #fff; }
.btn-warning { background: var(--warning); color: #fff; }
.btn-info { background: var(--info); color: #fff; }

.btn-outline {
  background: var(--bg-white);
  border: 1px solid var(--slate-200);
  color: var(--slate-700);
  box-shadow: var(--shadow-xs);
}
.btn-outline:hover { background: var(--slate-50); border-color: var(--slate-300); color: var(--slate-900); }

.btn-sm { padding: 6px 11px; font-size: 12px; border-radius: var(--radius-sm); }
.btn-lg { padding: 12px 24px; font-size: 14.5px; }
.btn-icon { padding: 7px 9px; }
.btn:disabled, .btn[disabled] { opacity: 0.5; cursor: not-allowed; pointer-events: none; }

/* ===== Forms ===== */
.form-group { margin-bottom: 16px; }

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--slate-700);
  margin-bottom: 6px;
}

.form-label .required { color: var(--danger); }

.form-control {
  width: 100%;
  padding: 10px 13px;
  border: 1px solid var(--slate-200);
  border-radius: var(--radius);
  font-size: 14px;
  font-family: inherit;
  color: var(--slate-800);
  background: var(--bg-white);
  transition: border-color var(--t-fast), box-shadow var(--t-fast);
  outline: none;
}

.form-control:hover { border-color: var(--slate-300); }
.form-control:focus {
  border-color: var(--primary);
  box-shadow: var(--ring);
}

.form-control::placeholder { color: var(--slate-400); }

select.form-control {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}
textarea.form-control { resize: vertical; min-height: 92px; line-height: 1.6; }

.form-hint {
  font-size: 11.5px;
  color: var(--text-muted);
  margin-top: 5px;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.form-actions {
  display: flex;
  gap: 10px;
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid var(--slate-150);
}

/* ===== Filters bar ===== */
.filters-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
  background: var(--bg-white);
  padding: 12px 14px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--slate-150);
  box-shadow: var(--shadow-xs);
}

.filters-bar .search-input { flex: 1; min-width: 200px; }

/* ===== Alerts / Messages ===== */
.messages-container { margin-bottom: 18px; display: flex; flex-direction: column; gap: 8px; }

.alert {
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: 13.5px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid transparent;
  animation: alert-in 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes alert-in {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}

.alert-success { background: var(--success-bg); color: #1B7A53; border-color: rgba(43,164,113,0.25); }
.alert-error, .alert-danger { background: var(--danger-bg); color: #C13438; border-color: rgba(229,72,77,0.25); }
.alert-warning { background: var(--warning-bg); color: #9A6C0A; border-color: rgba(243,156,18,0.25); }
.alert-info { background: var(--info-bg); color: #1F6391; border-color: rgba(46,134,193,0.25); }

/* ===== Toasts (notifications éphémères, coin haut-droit) ===== */
.toast-container {
  position: fixed;
  top: 18px;
  right: 18px;
  z-index: 1200;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: min(380px, calc(100vw - 36px));
  pointer-events: none;
}
.toast {
  pointer-events: auto;
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 13px 14px 13px 15px;
  border-radius: var(--radius);
  background: var(--bg-white, #fff);
  border: 1px solid var(--slate-200);
  box-shadow: var(--shadow-lg);
  font-size: 13.5px;
  line-height: 1.4;
  position: relative;
  overflow: hidden;
  animation: toast-in 0.32s cubic-bezier(0.16, 1, 0.3, 1);
}
.toast.toast-out { animation: toast-out 0.3s cubic-bezier(0.4, 0, 1, 1) forwards; }
@keyframes toast-in { from { opacity: 0; transform: translateX(24px); } to { opacity: 1; transform: translateX(0); } }
@keyframes toast-out { to { opacity: 0; transform: translateX(24px); } }
.toast-icon { font-size: 17px; line-height: 1.3; flex-shrink: 0; }
.toast-body { flex: 1; color: var(--text); padding-top: 1px; }
.toast-close {
  background: none; border: none; cursor: pointer; padding: 0 2px;
  color: var(--slate-400); font-size: 14px; line-height: 1; flex-shrink: 0;
  transition: color var(--t-fast);
}
.toast-close:hover { color: var(--slate-600); }
/* Liseré coloré gauche + couleur d'icône par type */
.toast::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; }
.toast-success::before { background: var(--success); }
.toast-success .toast-icon { color: var(--success); }
.toast-error::before, .toast-danger::before { background: var(--danger); }
.toast-error .toast-icon, .toast-danger .toast-icon { color: var(--danger); }
.toast-warning::before { background: var(--warning); }
.toast-warning .toast-icon { color: var(--warning); }
.toast-info::before { background: var(--info); }
.toast-info .toast-icon { color: var(--info); }
/* Barre de progression d'auto-fermeture */
.toast-progress { position: absolute; left: 0; bottom: 0; height: 2px; width: 100%; opacity: 0.35; transform-origin: left; animation: toast-progress linear forwards; }
.toast-success .toast-progress { background: var(--success); }
.toast-error .toast-progress, .toast-danger .toast-progress { background: var(--danger); }
.toast-warning .toast-progress { background: var(--warning); }
.toast-info .toast-progress { background: var(--info); }
@keyframes toast-progress { from { transform: scaleX(1); } to { transform: scaleX(0); } }

/* ===== Barre de progression de navigation (haut de page) ===== */
.nav-progress {
  position: fixed; top: 0; left: 0; height: 3px; width: 0;
  background: linear-gradient(90deg, var(--accent), var(--accent-light));
  box-shadow: 0 0 8px var(--accent-a20);
  z-index: 2000; opacity: 0;
  transition: width 0.2s ease, opacity 0.3s ease;
}
.nav-progress.active { opacity: 1; }

.hidden { display: none !important; }

/* ===== États de chargement (boutons & overlays) ===== */
.btn.is-loading { position: relative; color: transparent !important; pointer-events: none; }
.btn.is-loading > * { visibility: hidden; }
.btn.is-loading::after {
  content: ''; position: absolute; top: 50%; left: 50%;
  width: 15px; height: 15px; margin: -7.5px 0 0 -7.5px;
  border: 2px solid currentColor; border-right-color: transparent;
  border-radius: 50%; color: #fff;
  animation: spin 0.6s linear infinite; visibility: visible;
}
.btn-outline.is-loading::after, .btn-sm.is-loading::after { color: var(--primary); }
@keyframes spin { to { transform: rotate(360deg); } }

/* Spinner réutilisable + état vide de chargement */
.spinner {
  display: inline-block; width: 18px; height: 18px;
  border: 2.5px solid var(--slate-200); border-top-color: var(--primary);
  border-radius: 50%; animation: spin 0.7s linear infinite;
  vertical-align: middle;
}
.loading-block { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 48px 20px; color: var(--text-muted); }
.loading-block .spinner { width: 30px; height: 30px; border-width: 3px; }

/* Skeletons pour chargement de contenu */
.skeleton {
  background: linear-gradient(90deg, var(--slate-100) 25%, var(--slate-150) 37%, var(--slate-100) 63%);
  background-size: 400% 100%; border-radius: var(--radius-sm);
  animation: skeleton-wave 1.4s ease infinite;
}
.skeleton-line { height: 12px; margin: 8px 0; }
@keyframes skeleton-wave { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }
@media (prefers-reduced-motion: reduce) {
  .toast, .nav-progress, .skeleton, .btn.is-loading::after, .spinner { animation: none !important; transition: none !important; }
}

/* ===== Avatar ===== */
.avatar-circle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-light), var(--primary));
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  flex-shrink: 0;
}

.avatar-photo {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--bg-white);
  box-shadow: var(--shadow-xs);
}

/* ===== Page header (titre + boutons) ===== */
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
  flex-wrap: wrap;
  gap: 12px;
}

.page-header h1 {
  font-size: 23px;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: var(--slate-900);
}

.page-header p {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 3px;
}

/* ===== Grid layout ===== */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 20px; }
.gap-16 { gap: 16px; }

/* ===== Calendar (planning) ===== */
.calendar-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }

.cal-day-header {
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--slate-500);
  padding: 8px 4px;
}

.cal-day {
  min-height: 94px;
  background: var(--bg-white);
  border: 1px solid var(--slate-150);
  padding: 7px;
  border-radius: var(--radius-sm);
  transition: background var(--t-fast), box-shadow var(--t-fast);
}
.cal-day:hover { box-shadow: var(--shadow-sm); }
.cal-day.empty { background: var(--slate-50); border-style: dashed; }
.cal-day.today { border-color: var(--accent); background: #FFFBF2; box-shadow: 0 0 0 1px var(--accent-a20); }

.cal-day-num { font-size: 13px; font-weight: 700; color: var(--slate-700); margin-bottom: 5px; }
.cal-day.today .cal-day-num { color: var(--accent-dark); }

.cal-event {
  font-size: 11px;
  font-weight: 500;
  padding: 3px 7px;
  border-radius: 5px;
  margin-bottom: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  cursor: pointer;
  transition: filter var(--t-fast);
}
.cal-event:hover { filter: brightness(0.96); }

.cal-event.entrainement { background: var(--info-bg); color: #1F6391; }
.cal-event.match { background: var(--success-bg); color: #1B7A53; }
.cal-event.tournoi { background: #FDEBD0; color: #8A4B00; }
.cal-event.stage { background: #EFE3F7; color: #6C3483; }
.cal-event.autre { background: var(--slate-100); color: var(--slate-500); }

/* ===== Presence table ===== */
.presence-radio-group { display: flex; gap: 6px; flex-wrap: wrap; }

.presence-radio-group label {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--slate-200);
  transition: all var(--t-fast);
}
.presence-radio-group label:hover { border-color: var(--slate-300); background: var(--slate-50); }

.presence-radio-group input[type=radio]:checked + span { font-weight: 600; }
.presence-radio-group label:has(input[value=present]:checked) { background: var(--success-bg); border-color: var(--success); color: #1B7A53; }
.presence-radio-group label:has(input[value=absent]:checked) { background: var(--danger-bg); border-color: var(--danger); color: #C13438; }
.presence-radio-group label:has(input[value=retard]:checked) { background: var(--warning-bg); border-color: var(--warning); color: #9A6C0A; }
.presence-radio-group label:has(input[value=excuse]:checked) { background: var(--info-bg); border-color: var(--info); color: #1F6391; }

/* ===== Chart container ===== */
.chart-container { position: relative; height: 280px; }

/* ===== Progress bars ===== */
.progress-bar {
  width: 100%;
  height: 8px;
  background: var(--slate-150);
  border-radius: var(--radius-pill);
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  border-radius: var(--radius-pill);
  background: linear-gradient(90deg, var(--primary-light), var(--primary));
  transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.progress-bar-fill.accent { background: linear-gradient(90deg, var(--accent-light), var(--accent)); }
.progress-bar-fill.success { background: linear-gradient(90deg, #3DBE85, var(--success)); }
.progress-bar-fill.danger { background: linear-gradient(90deg, #F0696D, var(--danger)); }

/* ===== Tabs ===== */
.tabs {
  display: flex;
  gap: 4px;
  border-bottom: 1px solid var(--slate-200);
  margin-bottom: 22px;
}

.tab-link {
  padding: 10px 16px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color var(--t-fast), border-color var(--t-fast);
}

.tab-link:hover { color: var(--primary); }
.tab-link.active { color: var(--primary); border-bottom-color: var(--accent); font-weight: 600; }

/* ===== Modals ===== */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  animation: overlay-in 0.18s ease;
}
@keyframes overlay-in { from { opacity: 0; } to { opacity: 1; } }

.modal-overlay.open { display: flex; }

.modal {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  min-width: 320px;
  max-width: 560px;
  width: 90vw;
  max-height: 90vh;
  overflow-y: auto;
  animation: modal-in 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modal-in {
  from { transform: scale(0.96) translateY(8px); opacity: 0; }
  to { transform: scale(1) translateY(0); opacity: 1; }
}

.modal-header {
  padding: 18px 20px;
  border-bottom: 1px solid var(--slate-150);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-header h3 { font-size: 16px; font-weight: 700; letter-spacing: -0.2px; }
.modal-close {
  background: none; border: none; font-size: 20px;
  cursor: pointer; color: var(--slate-400); padding: 2px;
  transition: color var(--t-fast);
}
.modal-close:hover { color: var(--slate-700); }
.modal-body { padding: 20px; }
.modal-footer {
  padding: 14px 20px;
  border-top: 1px solid var(--slate-150);
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

/* ===== Danger zone ===== */
.danger-zone {
  border: 1px solid rgba(229, 72, 77, 0.35);
  background: var(--danger-bg);
  border-radius: var(--radius-lg);
  padding: 16px 18px;
  margin-top: 20px;
}

.danger-zone h3 { color: #C13438; font-size: 14px; margin-bottom: 8px; }

/* ===== Login page ===== */
.login-wrapper {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  position: relative;
  background:
    radial-gradient(1200px 600px at 15% 10%, rgba(46, 134, 193, 0.25), transparent 55%),
    radial-gradient(900px 500px at 85% 90%, rgba(243, 156, 18, 0.16), transparent 50%),
    linear-gradient(150deg, var(--primary) 0%, var(--primary-dark) 55%, var(--primary-darker) 100%);
  overflow: hidden;
}
.login-wrapper::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 28px 28px;
  pointer-events: none;
}

.login-card {
  position: relative;
  background: rgba(255, 255, 255, 0.98);
  border-radius: 20px;
  padding: 40px 36px;
  width: 380px;
  max-width: 100%;
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(255, 255, 255, 0.6);
  animation: modal-in 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.login-logo { text-align: center; margin-bottom: 28px; }

.login-logo h1 {
  color: var(--primary);
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.login-logo span { color: var(--accent); font-weight: 800; }

.login-logo p { color: var(--text-muted); font-size: 12.5px; margin-top: 5px; }

/* ===== Empty state ===== */
.empty-state {
  text-align: center;
  padding: 52px 20px;
  color: var(--text-muted);
}

.empty-state .empty-icon {
  font-size: 44px;
  margin-bottom: 16px;
  color: var(--slate-300);
}

.empty-state h3 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--slate-700);
}

/* ── Sidebar-logo inner wrap ── */
.sidebar-logo { position: relative; display: flex; align-items: center; justify-content: center; }
.sidebar-logo-inner { text-align: center; }
.sidebar-centre-name { font-size: 11px; color: rgba(255,255,255,.55); display: block; margin-top: 3px; letter-spacing: .2px; }
.sidebar-close-btn {
  display: none;
  position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
  background: rgba(255,255,255,.12); border: none; border-radius: var(--radius-sm);
  color: rgba(255,255,255,.8); width: 30px; height: 30px;
  align-items: center; justify-content: center; cursor: pointer; font-size: 14px;
  transition: background var(--t-fast);
}
.sidebar-close-btn:hover { background: rgba(255,255,255,.22); color: #fff; }
.sidebar-toggle {
  display: none;
  align-items: center; justify-content: center;
  width: 38px; height: 38px; flex-shrink: 0;
  background: none; border: 1.5px solid var(--slate-200); border-radius: var(--radius-sm);
  color: var(--slate-600); cursor: pointer; font-size: 15px;
  transition: background var(--t-fast), border-color var(--t-fast);
}
.sidebar-toggle:hover { background: var(--slate-100); border-color: var(--slate-300); color: var(--slate-800); }
.header-title-group { flex: 1; min-width: 0; }
.sidebar-overlay {
  display: none; position: fixed; inset: 0;
  background: rgba(15,23,42,.48); backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px);
  z-index: 199; opacity: 0; pointer-events: none; transition: opacity var(--t);
}

/* ===== Responsive — Tablette (641px – 900px) ===== */
@media (max-width: 900px) {
  .sidebar-toggle { display: none; }
  .sidebar { width: 64px; overflow: visible; }
  .sidebar-logo h1, .nav-item span, .sidebar-user .user-info,
  .nav-section-label, .sidebar-footer .btn-logout span { display: none; }
  .sidebar-logo { justify-content: center; padding: 14px 8px; }
  .sidebar-logo-inner { display: none; }
  .main-content { margin-left: 64px; }
  .nav-item { justify-content: center; padding: 12px; }
  .nav-item.active::before { left: -8px; }
  .nav-item .nav-icon { width: auto; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ===== Responsive — Mobile (≤ 640px) ===== */
@media (max-width: 640px) {

  /* ── Sidebar overlay ── */
  .sidebar-overlay { display: block; }
  .sidebar-overlay.active { opacity: 1; pointer-events: auto; }

  /* ── Hamburger ── */
  .sidebar-toggle { display: flex; }

  /* ── Sidebar drawer depuis la gauche ── */
  .sidebar {
    width: 270px !important;
    transform: translateX(-100%);
    transition: transform var(--t), box-shadow var(--t);
    z-index: 200; box-shadow: none;
  }
  .sidebar.sidebar-open {
    transform: translateX(0);
    box-shadow: 6px 0 32px rgba(15,23,42,.2);
  }

  /* Réafficher tout le texte de la sidebar (surchargé par ≤900px) */
  .sidebar-logo { justify-content: space-between; padding: 18px 16px 14px; }
  .sidebar-logo-inner { display: block; text-align: left; }
  .sidebar-logo h1 { display: block !important; font-size: 18px; }
  .sidebar-centre-name { display: block !important; }
  .sidebar-close-btn { display: flex; }
  .nav-item span { display: inline !important; }
  .sidebar-user .user-info { display: block !important; }
  .nav-section-label { display: block !important; }
  .sidebar-footer .btn-logout span { display: inline !important; }
  .nav-item { justify-content: flex-start !important; padding: 9px 12px !important; }
  .nav-item .nav-icon { width: 18px !important; }
  .nav-item.active::before { left: -12px !important; }

  /* ── Main content pleine largeur ── */
  .main-content { margin-left: 0 !important; }

  /* ── Header ── */
  .top-header { padding: 0 12px; gap: 10px; height: 54px; }
  .header-title { font-size: 15px; }
  .header-subtitle { display: none; }
  .saison-badge { display: none; }
  .header-actions { gap: 6px; flex-shrink: 0; }
  /* Boutons dans le header : icône seule, texte masqué */
  .header-actions .btn { padding: 7px 10px; }
  .header-actions .btn > span { display: none; }
  .header-actions .btn > i { margin: 0; }

  /* ── Page content ── */
  .page-content {
    padding: 12px;
    padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px));
  }

  /* ── Stats grid : 2 colonnes compactes ── */
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 14px; }
  .stat-card { padding: 13px 11px; gap: 10px; }
  .stat-card:hover { transform: none; }
  .stat-icon { width: 40px; height: 40px; font-size: 16px; border-radius: 10px; flex-shrink: 0; }
  .stat-value { font-size: 19px; }
  .stat-label { font-size: 11px; margin-top: 2px; }
  .stat-go { display: none; }

  /* ── Grilles de contenu ── */
  .grid-2, .grid-3 { grid-template-columns: 1fr !important; gap: 12px; }

  /* ── Cards ── */
  .card-header { padding: 11px 13px; flex-wrap: wrap; gap: 8px; }
  .card-header h2 { font-size: 13px; }
  .card-body { padding: 13px; }

  /* ── Tables : scroll horizontal tactile ── */
  .table-container { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  table { min-width: 500px; }
  table th, table td { padding: 9px 10px; font-size: 12.5px; }

  /* ── Page header ── */
  .page-header { margin-bottom: 14px; gap: 8px; }
  .page-header h1 { font-size: 18px; }

  /* ── Filters bar : colonne ── */
  .filters-bar { flex-direction: column; align-items: stretch; gap: 8px; padding: 10px 12px; }
  .filters-bar .search-input { min-width: 0; width: 100%; }
  .filters-bar .btn > span { display: inline; }

  /* ── Tabs : scroll horizontal ── */
  .tabs { overflow-x: auto; -webkit-overflow-scrolling: touch; flex-wrap: nowrap; padding-bottom: 2px; }
  .tab-link { white-space: nowrap; padding: 9px 13px; font-size: 12.5px; }

  /* ── Calendrier ── */
  .calendar-grid { grid-template-columns: repeat(7, minmax(38px, 1fr)); gap: 2px; overflow-x: auto; }
  .cal-day { min-height: 60px; padding: 4px; }
  .cal-day-num { font-size: 11px; }
  .cal-event { font-size: 9px; padding: 2px 4px; }
  .cal-day-header { font-size: 9px; padding: 5px 2px; }

  /* ── Forms ── */
  .form-row { grid-template-columns: 1fr; }
  .form-actions { flex-wrap: wrap; gap: 8px; padding-top: 14px; margin-top: 14px; }
  .form-actions .btn { flex: 1; min-width: 0; justify-content: center; }
  .form-group { margin-bottom: 13px; }
  .form-control { padding: 10px 12px; font-size: 15px; }
  select.form-control { font-size: 15px; }

  /* ── Modales : bottom sheet ── */
  dialog.quick-modal {
    width: 100% !important; max-width: 100% !important;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    position: fixed; bottom: 0; left: 0; right: 0; top: auto; margin: 0;
    max-height: 92vh;
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }
  @keyframes qm-in {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
  }
  .qm-body { padding: 16px; }
  .qm-header { padding: 14px 16px; }

  /* ── Pagination ── */
  .pagination-bar { flex-direction: column; align-items: center; gap: 8px; padding: 12px; }

  /* ── Présences : radio boutons plus grands (touch) ── */
  .presence-radio-group label { padding: 6px 12px; font-size: 12.5px; }

  /* ── Charts ── */
  .chart-container { height: 220px; }

  /* ── Toasts : pleine largeur en bas sur mobile ── */
  .toast-container {
    top: auto; bottom: calc(12px + env(safe-area-inset-bottom, 0px));
    right: 10px; left: 10px; max-width: none;
  }
  @keyframes toast-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }

  /* ── Danger zone ── */
  .danger-zone { padding: 13px; }
}

/* ===== Pagination ===== */
.pagination-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  padding: 14px 16px;
  border-top: 1px solid var(--slate-150);
  background: var(--slate-50);
}

.pagination-info {
  font-size: 13px;
  color: var(--slate-600);
  font-weight: 500;
}

.pagination-links {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ===== Tabs (hash-based, no-JS fallback shows all) ===== */
.tab-content { display: none; }
.tab-content.tab-active { display: block; }

/* ===== View toggle (Calendrier / Liste) ===== */
.view-toggle {
  display: flex;
  gap: 0;
  border: 1.5px solid var(--slate-200);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
}
.view-toggle-btn {
  padding: 6px 14px;
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  transition: background var(--t-fast), color var(--t-fast);
  line-height: 1.4;
}
.view-toggle-btn:hover { background: var(--slate-100); color: var(--text); }
.view-toggle-btn.active { background: var(--primary); color: #fff; }

/* ===== Quick-action dialog (HTMX modals) ===== */
.quick-modal {
  padding: 0;
  border: none;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  width: min(480px, 96vw);
  max-height: 90vh;
  overflow-y: auto;
  background: var(--bg-white);
  /* Center via margin auto (dialog default positioning is centered) */
}
.quick-modal::backdrop {
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}
@keyframes qm-in { from { opacity: 0; transform: translateY(-12px) scale(0.97); } to { opacity: 1; transform: none; } }
.quick-modal[open] { animation: qm-in 0.22s cubic-bezier(0.16, 1, 0.3, 1); }

.qm-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--slate-150);
  gap: 12px;
}
.qm-title { margin: 0; font-size: 15px; font-weight: 700; color: var(--text); display: flex; align-items: center; gap: 8px; }
.qm-title i { color: var(--primary-light); }
.qm-close {
  background: none; border: none; cursor: pointer;
  font-size: 22px; line-height: 1; color: var(--slate-400);
  width: 32px; height: 32px; display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm); transition: background var(--t-fast), color var(--t-fast);
  flex-shrink: 0;
}
.qm-close:hover { background: var(--slate-100); color: var(--text); }
.qm-body { padding: 20px; }

.qm-summary {
  display: flex; flex-direction: column; gap: 3px;
  background: var(--slate-50); border-radius: var(--radius);
  padding: 12px 14px; margin-bottom: 18px;
  border-left: 3px solid var(--accent);
}
.qm-amount { font-size: 20px; font-weight: 800; color: var(--accent-dark); margin-top: 2px; }

.confirm-modal { width: min(420px, 94vw); }
.confirm-modal .qm-title i { color: var(--danger); }

/* Indicateur de chargement HTMX sur les résultats filtrés en direct */
.htmx-results { transition: opacity 0.15s ease; }
.htmx-results.htmx-request { opacity: 0.45; pointer-events: none; }
.results-counter { margin-bottom: 12px; }

/* ===== Utilities ===== */
.text-muted { color: var(--text-muted) !important; }
.text-danger { color: var(--danger) !important; }
.text-success { color: var(--success) !important; }
.text-accent { color: var(--accent-dark) !important; }
.text-primary { color: var(--primary) !important; }
.fw-bold { font-weight: 700 !important; }
.fs-sm { font-size: 12px !important; }
.mt-8 { margin-top: 8px !important; }
.mt-16 { margin-top: 16px !important; }
.mt-24 { margin-top: 24px !important; }
.mb-8 { margin-bottom: 8px !important; }
.mb-16 { margin-bottom: 16px !important; }
.d-flex { display: flex !important; }
.align-center { align-items: center !important; }
.justify-between { justify-content: space-between !important; }
.gap-8 { gap: 8px !important; }
.w-100 { width: 100% !important; }
.nowrap { white-space: nowrap; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ===== Préférence : mouvement réduit (accessibilité) ===== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ===== Print ===== */
@media print {
  .sidebar, .top-header { display: none; }
  .main-content { margin-left: 0; }
  .card { box-shadow: none; border: 1px solid #ccc; }
}
