:root {
    --club: #7b1e56;
    --club-light: #f9f0f5;
    --club-dark: #5a1640;
    --club-hover: #8e2564;
    --club-subtle: #a8507e;
    --gold: #c4952e;
    --gold-light: #faf3e0;
    --gold-hover: #d4a63e;
    --espace-entraineur: #1F6A7A;
    --espace-entraineur-dark: #175560;
    --espace-entraineur-light: #e8f4f6;
    --espace-admin: #7A5A1F;
    --espace-admin-dark: #614818;
    --espace-admin-light: #faf3e0;
    --espace-bureau: #7B1E56;
    --espace-bureau-dark: #5e1743;
    --espace-bureau-light: #f5e6ef;
    --espace-publicateur: #5B3A8C;
    --espace-publicateur-dark: #472D6E;
    --espace-publicateur-light: #f0eaf8;
    --bg: #f5f6f8;
    --surface: #ffffff;
    --surface-2: #ffffff;
    --text: #242832;
    --text-secondary: #636a7e;
    --text-muted: #969dae;
    --border: #e5e7ed;
    --border-strong: #cdd1da;
    --radius: 10px;
    --radius-sm: 6px;
    --radius-lg: 14px;
    --confirm-border: #C0392B;
    --interest-border: #E88A1A;
    --success: #2d7a3a;
    --success-bg: #edf7ee;
    --danger: #c0392b;
    --danger-bg: #fdecea;
    --shadow-sm: 0 1px 3px rgba(36, 40, 50, 0.04), 0 1px 2px rgba(36, 40, 50, 0.03);
    --shadow-md: 0 2px 8px rgba(36, 40, 50, 0.06), 0 1px 3px rgba(36, 40, 50, 0.04);
    --shadow-lg: 0 4px 20px rgba(36, 40, 50, 0.08);
    --font-display: 'Barlow', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-body: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ── DARK MODE ── */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #141620; --surface: #1E2030; --surface-2: #252838;
    --text: #E4E6EC; --text-secondary: #A0A5B8; --text-muted: #6B7190;
    --border: #2C2F42; --border-strong: #3A3E55;
    --club-light: #2A1525; --gold-light: #2A2518;
    --success-bg: #162218; --danger-bg: #261418;
    --confirm-border: #E05545; --interest-border: #F0A040;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.2);
    --shadow-md: 0 2px 8px rgba(0,0,0,0.25);
    --shadow-lg: 0 4px 20px rgba(0,0,0,0.3);
  }
}
:root[data-theme="dark"] {
  --bg: #141620; --surface: #1E2030; --surface-2: #252838;
  --text: #E4E6EC; --text-secondary: #A0A5B8; --text-muted: #6B7190;
  --border: #2C2F42; --border-strong: #3A3E55;
  --club-light: #2A1525; --gold-light: #2A2518;
  --success-bg: #162218; --danger-bg: #261418;
  --confirm-border: #E05545; --interest-border: #F0A040;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.2);
  --shadow-md: 0 2px 8px rgba(0,0,0,0.25);
  --shadow-lg: 0 4px 20px rgba(0,0,0,0.3);
}

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

body {
    font-family: var(--font-body);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    scroll-behavior: smooth;
}

a { color: var(--club); text-decoration: none; transition: color 0.2s; }
a:hover { text-decoration: underline; }

.app {
    max-width: 1200px;
    margin: 0 auto;
    min-height: 100vh;
}

/* ==============================
   TOPBAR
   ============================== */
.topbar {
    background: var(--club-dark);
    padding: 0 24px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
}
.topbar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}
.topbar-brand:hover { text-decoration: none; }
.topbar-logo { font-size: 22px; }
.topbar-title {
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    font-family: var(--font-display);
    letter-spacing: 0.01em;
}
.topbar-right {
    display: flex;
    align-items: center;
    gap: 12px;
}
.topbar-licence-icon {
    font-size: 22px;
    text-decoration: none;
    line-height: 1;
    filter: grayscale(0.2);
    transition: transform 0.15s;
}
.topbar-licence-icon:hover { transform: scale(1.15); }
.topbar-licence-btn {
    display: none;
    padding: 6px 16px;
    border-radius: 6px;
    background: rgba(255,255,255,0.12);
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    font-family: var(--font-display);
    text-decoration: none;
    transition: background 0.2s;
}
.topbar-licence-btn:hover { background: rgba(255,255,255,0.22); text-decoration: none; }
.topbar-avatar-wrap { position: relative; }
.topbar-avatar-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    border-radius: 6px;
    transition: background 0.15s;
}
.topbar-avatar-btn:hover { background: rgba(255,255,255,0.1); }
.topbar-avatar {
    width: 34px; height: 34px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--club), var(--club-hover));
    color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 12px;
    font-family: var(--font-display);
    flex-shrink: 0;
}
.topbar-avatar-name {
    color: rgba(255,255,255,0.85);
    font-size: 13px;
    font-weight: 500;
    display: none;
}
.topbar-avatar-caret {
    color: rgba(255,255,255,0.5);
    font-size: 10px;
    display: none;
}

/* Topbar dropdown */
.topbar-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 240px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    z-index: 200;
    overflow: hidden;
}
.topbar-avatar-wrap.open .topbar-dropdown { display: block; }
.topbar-dropdown-header {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
}
.topbar-dropdown-name {
    font-size: 14px; font-weight: 600; color: var(--text);
    font-family: var(--font-display);
}
.topbar-dropdown-licence {
    font-size: 12px; color: var(--text-muted); margin-top: 2px;
}
.topbar-dropdown-roles {
    display: flex; gap: 6px; margin-top: 8px;
}
.role-pill {
    font-size: 10px; padding: 2px 8px; border-radius: 4px;
    font-weight: 600; text-transform: uppercase; letter-spacing: 0.03em;
}
.role-entraineur { background: var(--espace-entraineur-light); color: var(--espace-entraineur); }
.role-admin { background: var(--espace-admin-light); color: var(--espace-admin); }
.role-publicateur { background: var(--espace-publicateur-light); color: var(--espace-publicateur); }
.topbar-dropdown-links {
    padding: 6px 0;
}
.topbar-dropdown-links a {
    display: block;
    padding: 8px 16px;
    font-size: 13px;
    color: var(--text);
    text-decoration: none;
    transition: background 0.15s;
}
.topbar-dropdown-links a:hover { background: var(--bg); text-decoration: none; }
.topbar-dropdown-logout { color: var(--danger) !important; }
.topbar-dropdown-theme {
    display: flex; align-items: center; gap: 8px; width: 100%;
    padding: 8px 16px; font-size: 13px; color: var(--text);
    background: none; border: none; cursor: pointer;
    font-family: var(--font-body); transition: background 0.15s;
}
.topbar-dropdown-theme:hover { background: var(--bg); }
.theme-icon { font-size: 16px; line-height: 1; }

/* ==============================
   ESPACE TOPBAR (entraîneur / admin)
   ============================== */
.topbar-espace {
    justify-content: flex-start;
    gap: 16px;
}
.topbar-entraineur { background: var(--espace-entraineur-dark); }
.topbar-admin { background: var(--espace-admin-dark); }
.topbar-bureau { background: var(--espace-bureau-dark); }
.topbar-espace-title {
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    font-family: var(--font-display);
}
.topbar-espace-sub {
    color: rgba(255,255,255,0.55);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}
.topbar-espace-user {
    color: rgba(255,255,255,0.7);
    font-size: 13px;
    display: none;
}
.topbar-retour-btn {
    margin-left: auto;
    padding: 6px 14px;
    border-radius: 6px;
    background: rgba(255,255,255,0.12);
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    font-family: var(--font-display);
    text-decoration: none;
    transition: background 0.2s;
    white-space: nowrap;
}
.topbar-retour-btn:hover { background: rgba(255,255,255,0.22); text-decoration: none; }

/* ==============================
   MAIN NAV (6 tabs + espace buttons)
   ============================== */
.main-nav {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 56px;
    z-index: 90;
    display: none;
}
.main-nav-inner {
    display: flex;
    align-items: stretch;
}
.main-nav-tab {
    padding: 12px 18px;
    color: var(--text-secondary);
    font-size: 13px;
    font-family: var(--font-display);
    font-weight: 500;
    letter-spacing: 0.01em;
    border-bottom: 3px solid transparent;
    white-space: nowrap;
    text-decoration: none;
    transition: color 0.2s, border-color 0.2s;
    display: flex;
    align-items: center;
}
.main-nav-tab:hover { color: var(--text); text-decoration: none; }
.main-nav-tab.active {
    color: var(--club);
    border-bottom-color: var(--club);
    font-weight: 600;
}
.main-nav-dropdown {
    position: relative;
    display: flex;
    align-items: stretch;
}
.main-nav-dropdown-trigger {
    background: none;
    border: none;
    cursor: pointer;
    gap: 4px;
}
.nav-caret {
    font-size: 10px;
    opacity: 0.6;
    transition: transform 0.2s;
}
.main-nav-dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 180px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    z-index: 200;
    padding: 6px 0;
}
.main-nav-dropdown:hover .main-nav-dropdown-menu,
.main-nav-dropdown.open .main-nav-dropdown-menu { display: block; }
.main-nav-dropdown:hover .nav-caret { transform: rotate(180deg); }
.main-nav-dropdown-menu a {
    display: block;
    padding: 10px 18px;
    font-size: 13px;
    font-family: var(--font-display);
    font-weight: 500;
    color: var(--text-secondary);
    text-decoration: none;
    transition: background 0.15s, color 0.15s;
}
.main-nav-dropdown-menu a:hover {
    background: var(--club-light);
    color: var(--club);
    text-decoration: none;
}
.main-nav-dropdown-menu a.active {
    color: var(--club);
    font-weight: 600;
    background: var(--club-light);
}

/* Popover mobile (bottom bar sub-menu) */
.bottom-tab-wrap {
    flex: 1;
    position: relative;
    display: flex;
    align-items: stretch;
}
.bottom-tab-wrap .bottom-tab { flex: 1; }
.bottom-popover {
    display: none;
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    min-width: 160px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    z-index: 300;
    padding: 6px 0;
}
.bottom-popover.open { display: block; }
.bottom-popover a {
    display: block;
    padding: 12px 18px;
    font-size: 14px;
    font-family: var(--font-display);
    font-weight: 500;
    color: var(--text-secondary);
    text-decoration: none;
    text-align: left;
    transition: background 0.15s, color 0.15s;
}
.bottom-popover a:hover {
    background: var(--club-light);
    color: var(--club);
    text-decoration: none;
}
.bottom-popover a.active {
    color: var(--club);
    font-weight: 600;
}

.main-nav-spacer {
    width: 1px;
    background: var(--border);
    margin: 8px 8px;
    flex-shrink: 0;
}
.main-nav-espaces {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 8px;
    margin-left: auto;
}
.espace-btn {
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    font-family: var(--font-display);
    text-decoration: none;
    transition: background 0.2s, transform 0.1s;
    white-space: nowrap;
}
.espace-btn:hover { text-decoration: none; transform: translateY(-1px); }
.espace-btn:active { transform: translateY(0); }
.espace-btn-entraineur {
    background: var(--espace-entraineur-light);
    color: var(--espace-entraineur);
}
.espace-btn-entraineur:hover { background: #d4ecf0; }
.espace-btn-admin {
    background: var(--espace-admin-light);
    color: var(--espace-admin);
}
.espace-btn-admin:hover { background: #f0e6cc; }
.espace-btn-bureau {
    background: var(--espace-bureau-light);
    color: var(--espace-bureau);
}
.espace-btn-bureau:hover { background: #ecd4e3; }

/* ==============================
   ESPACE NAV (contextual tabs)
   ============================== */
.espace-nav {
    display: none;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.espace-nav::-webkit-scrollbar { display: none; }
.espace-nav-entraineur { background: var(--espace-entraineur); }
.espace-nav-admin { background: var(--espace-admin); }
.espace-nav-bureau { background: var(--espace-bureau); }
.espace-nav-tab {
    padding: 10px 18px;
    color: rgba(255,255,255,0.7);
    font-size: 13px;
    font-family: var(--font-display);
    font-weight: 500;
    white-space: nowrap;
    text-decoration: none;
    border-bottom: 3px solid transparent;
    transition: color 0.2s, border-color 0.2s;
}
.espace-nav-tab:hover { color: #fff; text-decoration: none; }
.espace-nav-tab.active {
    color: #fff;
    border-bottom-color: #fff;
    font-weight: 600;
}

/* ==============================
   DASHBOARD
   ============================== */
.dashboard { max-width: 1140px; margin: 0 auto; padding: 10px 20px 16px; }

/* Identity strip */
.id-strip {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 10px; gap: 12px;
}
.id-left { display: flex; align-items: center; gap: 8px; }
.id-avatar {
  width: 36px; height: 36px; border-radius: 50%;
  background: linear-gradient(135deg, var(--club), var(--club-dark));
  color: #fff; display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 13px; font-family: var(--font-display); flex-shrink: 0;
}
.id-hello { font-size: 16px; font-weight: 700; font-family: var(--font-display); line-height: 1.15; }
.id-sub { font-size: 11px; color: var(--text-muted); margin-top: 1px; }
.id-season-pill {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 12px; border-radius: 20px;
  background: var(--surface); border: 1px solid var(--border);
  font-size: 11px; font-weight: 600; font-family: var(--font-display);
  color: var(--text); box-shadow: var(--shadow-sm);
}
.id-season-pill svg { flex-shrink: 0; }

/* 4 Summary cards */
.summary-row {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 10px; margin-bottom: 12px;
}
.summary-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 10px 12px;
  box-shadow: var(--shadow-sm); text-decoration: none; color: inherit;
  display: flex; gap: 10px; align-items: center;
  transition: box-shadow 0.2s, transform 0.15s;
}
.summary-card:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); text-decoration: none; }
.summary-icon {
  width: 36px; height: 36px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; flex-shrink: 0;
}
.icon-compet { background: #DBEAFE; }
.icon-entrain { background: #DCFCE7; }
.icon-classement { background: var(--club-light); }
.icon-fleches { background: #FEF3C7; }
.summary-body { flex: 1; min-width: 0; }
.summary-label {
  font-size: 9px; font-weight: 600; color: var(--text-muted);
  font-family: var(--font-display); text-transform: uppercase;
  letter-spacing: 0.05em; margin-bottom: 2px;
}
.summary-main {
  font-size: 13px; font-weight: 700; color: var(--club);
  font-family: var(--font-display); line-height: 1.2;
}
.summary-detail { font-size: 10px; color: var(--text-muted); line-height: 1.3; }
.summary-date {
  font-size: 24px; font-weight: 800; color: var(--club);
  font-family: var(--font-display); line-height: 1; text-align: center;
}
.summary-date-month {
  font-size: 9px; font-weight: 700; color: var(--club-subtle);
  text-transform: uppercase; letter-spacing: 0.06em;
}
.summary-date-col { display: flex; flex-direction: column; align-items: center; gap: 1px; flex-shrink: 0; min-width: 36px; }
.summary-rank {
  font-size: 24px; font-weight: 800; color: var(--club);
  font-family: var(--font-display); line-height: 1;
  font-variant-numeric: tabular-nums;
}
.summary-rank sup { font-size: 11px; }
.summary-trend {
  display: inline-flex; align-items: center; gap: 2px;
  font-size: 11px; font-weight: 700; color: var(--success);
  margin-left: 4px;
}

/* Main 2-col grid */
.main-grid {
  display: grid; grid-template-columns: 1fr 320px;
  gap: 10px; margin-bottom: 10px;
}
.card {
  background: var(--surface); border-radius: var(--radius);
  padding: 12px 14px; box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
}
.card-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 8px;
}
.card-title {
  font-size: 10px; font-weight: 600; color: var(--text-secondary);
  font-family: var(--font-display); text-transform: uppercase;
  letter-spacing: 0.05em;
}
.card-link {
  font-size: 10px; color: var(--club-subtle); text-decoration: none; font-weight: 500;
}
.card-link:hover { color: var(--club); }

/* Mes événements */
.my-events-grid { display: flex; gap: 8px; }
.my-evt {
  flex: 1; display: flex; flex-direction: column;
  padding: 8px 10px; background: var(--surface);
  border-radius: var(--radius); border: 2px solid var(--border);
  text-decoration: none; color: inherit;
  transition: box-shadow 0.2s, transform 0.15s; position: relative;
  min-height: 0;
}
.my-evt:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); text-decoration: none; }
.my-evt-confirmed { border-color: var(--confirm-border); }
.my-evt-interested { border-color: var(--interest-border); animation: pulse-border 1.8s ease-in-out infinite; }
@keyframes pulse-border {
  0%, 100% { border-color: var(--interest-border); box-shadow: 0 0 0 0 transparent; }
  50% { border-color: var(--interest-border); box-shadow: 0 0 0 3px rgba(232,138,26,0.18); }
}
.my-evt-none { border-color: var(--border); border-style: dashed; }
.my-evt-status {
  position: absolute; top: 5px; right: 6px;
  font-size: 8px; font-weight: 600; padding: 1px 5px; border-radius: 3px;
}
.status-confirmed { background: var(--danger-bg); color: var(--danger); }
.status-interested { background: #FEF3C7; color: #92400E; }
.status-none { background: var(--bg); color: var(--text-muted); }
.my-evt-date-row { display: flex; align-items: baseline; gap: 5px; margin-bottom: 3px; }
.my-evt-jour {
  font-size: 20px; font-weight: 800; color: var(--club);
  font-family: var(--font-display); line-height: 1;
}
.my-evt-mois-jsem { font-size: 9px; color: var(--text-muted); font-weight: 600; text-transform: uppercase; }
.my-evt-badge {
  font-size: 8px; padding: 1px 5px; border-radius: 3px; font-weight: 600;
  display: inline-block; margin-bottom: 2px; align-self: flex-start;
}
.my-evt-title {
  font-size: 11px; font-weight: 600; color: var(--text);
  font-family: var(--font-display); line-height: 1.2; margin-bottom: 1px;
}
.my-evt-lieu { font-size: 9px; color: var(--text-muted); }
.my-evt-footer {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: auto; padding-top: 5px; border-top: 1px solid var(--border);
}
.my-evt-participants { font-size: 9px; color: var(--text-muted); display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.my-evt-avatars { display: flex; align-items: center; }
.my-evt-avatar {
  width: 18px; height: 18px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 7px; font-weight: 700; font-family: var(--font-display);
  color: #fff; border: 1.5px solid var(--surface);
  margin-left: -4px; flex-shrink: 0;
}
.my-evt-avatar:first-child { margin-left: 0; }
.my-evt-avatar-more {
  width: 18px; height: 18px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 7px; font-weight: 700; font-family: var(--font-display);
  color: var(--text-muted); background: var(--bg); border: 1.5px solid var(--border);
  margin-left: -4px; flex-shrink: 0;
}
.my-evt-covoit { font-size: 9px; color: var(--text-secondary); font-weight: 600; }
.covoit-car { display: inline-block; animation: car-bounce 2s ease-in-out infinite; }
.my-evt:hover .covoit-car { animation: car-drive 1s ease-in-out forwards; }
@keyframes car-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-2px); }
}
@keyframes car-drive {
  0% { transform: translateX(0); }
  50% { transform: translateX(-80px); }
  100% { transform: translateX(0); }
}
.my-events-legend { display: flex; gap: 12px; margin-top: 6px; }
.legend-item { display: flex; align-items: center; gap: 4px; font-size: 8px; color: var(--text-muted); }
.legend-swatch {
  width: 12px; height: 8px; border-radius: 2px;
  border-width: 2px; border-style: solid; background: var(--surface);
}
.legend-confirmed { border-color: var(--confirm-border); }
.legend-interested { border-color: var(--interest-border); animation: pulse-border 1.8s ease-in-out infinite; }
.legend-none { border-color: var(--border); border-style: dashed; }

/* Calendar */
.cal-nav {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 8px;
}
.cal-month {
  font-size: 13px; font-weight: 700; font-family: var(--font-display);
  color: var(--text);
}
.cal-nav-btn {
  background: none; border: 1px solid var(--border); border-radius: 4px;
  width: 24px; height: 24px; display: flex; align-items: center; justify-content: center;
  cursor: pointer; color: var(--text-muted); font-size: 12px;
  transition: background 0.12s;
}
.cal-nav-btn:hover { background: var(--bg); color: var(--text); }
.cal-grid {
  display: grid; grid-template-columns: repeat(7, 1fr);
  gap: 2px; text-align: center;
}
.cal-dow {
  font-size: 9px; font-weight: 600; color: var(--text-muted);
  font-family: var(--font-display); text-transform: uppercase;
  letter-spacing: 0.04em; padding: 2px 0 4px;
}
.cal-day {
  font-size: 11px; padding: 4px 0; border-radius: 4px;
  cursor: default; position: relative; font-variant-numeric: tabular-nums;
  transition: background 0.12s;
}
.cal-day:hover { background: var(--bg); }
.cal-day.today {
  background: var(--club); color: #fff; font-weight: 700; border-radius: 50%;
}
.cal-day.other-month { color: var(--text-muted); opacity: 0.4; }
.cal-day .cal-dot {
  position: absolute; bottom: 1px; left: 50%; transform: translateX(-50%);
  width: 4px; height: 4px; border-radius: 50%;
}
.dot-compet { background: var(--danger); }
.dot-entrain { background: var(--success); }
.dot-club { background: var(--club); }
.cal-upcoming {
  margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--border);
}
.cal-evt-row {
  display: flex; align-items: center; gap: 6px;
  padding: 3px 0; font-size: 10px;
}
.cal-evt-dot {
  width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0;
}
.cal-evt-date { color: var(--text-muted); min-width: 28px; font-variant-numeric: tabular-nums; font-size: 9px; font-weight: 600; }
.cal-evt-label { color: var(--text); font-weight: 500; flex: 1; }
.cal-evt-type { font-size: 8px; padding: 1px 5px; border-radius: 3px; font-weight: 600; flex-shrink: 0; }

/* Bottom 3-col grid */
.bottom-grid {
  display: grid; grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
}

/* Chart */
.chart-filter {
  font-size: 10px; font-family: var(--font-display); font-weight: 600;
  padding: 2px 8px; border: 1px solid var(--border); border-radius: 4px;
  background: var(--surface); color: var(--text); cursor: pointer;
  -webkit-appearance: none;
}
.chart-area { position: relative; height: 100px; margin-top: 4px; }
.chart-area canvas { width: 100%; height: 100%; }
.chart-labels {
  display: flex; justify-content: space-between;
  font-size: 8px; color: var(--text-muted);
  margin-top: 2px; font-variant-numeric: tabular-nums;
}
.chart-legend { display: flex; gap: 10px; margin-top: 4px; }
.chart-legend-item { display: flex; align-items: center; gap: 3px; font-size: 9px; color: var(--text-muted); }
.chart-legend-dot { width: 6px; height: 6px; border-radius: 50%; }

/* Classement table */
.rank-tabs {
  display: flex; gap: 0; margin-bottom: 8px;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  overflow: hidden;
}
.rank-tab {
  flex: 1; padding: 4px 0; text-align: center;
  font-size: 9px; font-weight: 600; font-family: var(--font-display);
  background: var(--surface); color: var(--text-muted);
  border: none; cursor: pointer; transition: all 0.15s;
  border-right: 1px solid var(--border);
}
.rank-tab:last-child { border-right: none; }
.rank-tab.active { background: var(--club); color: #fff; }
.rank-table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.rank-table th {
  font-size: 8px; font-weight: 600; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 0.04em;
  padding: 3px 4px; text-align: left; border-bottom: 1px solid var(--border);
  font-family: var(--font-display);
}
.rank-table th:last-child, .rank-table td:last-child { text-align: right; }
.rank-table td {
  font-size: 10px; padding: 4px 4px;
  border-bottom: 1px solid var(--border);
}
.rank-table tr:last-child td { border-bottom: none; }
.rank-table .me { background: var(--club-light); font-weight: 600; }
.rank-table .me td { color: var(--club); }
.rank-num { font-weight: 700; font-family: var(--font-display); }
.rank-evolution { font-weight: 600; font-size: 9px; }
.rank-evolution.up { color: var(--success); }
.rank-evolution.down { color: var(--danger); }
.rank-evolution.same { color: var(--text-muted); }

/* List rows */
.list-row {
  display: flex; align-items: center; gap: 6px;
  padding: 3px 0; border-bottom: 1px solid var(--border);
  text-decoration: none; color: inherit; transition: background 0.12s;
}
.list-row:last-child { border-bottom: none; }
.list-row:hover { background: var(--bg); }
.list-date { font-size: 9px; color: var(--text-muted); min-width: 28px; font-variant-numeric: tabular-nums; }
.list-label {
  font-size: 10px; color: var(--text); flex: 1; min-width: 0;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.list-value {
  font-size: 11px; font-weight: 700; color: var(--text);
  font-family: var(--font-display); font-variant-numeric: tabular-nums; flex-shrink: 0;
}

/* Dashboard responsive */
@media (max-width: 960px) {
  .summary-row { grid-template-columns: repeat(2, 1fr); }
  .main-grid { grid-template-columns: 1fr; }
  .bottom-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 700px) {
  .summary-row { grid-template-columns: 1fr; }
  .bottom-grid { grid-template-columns: 1fr; }
  .my-events-grid { flex-direction: column; }
}
@media (max-width: 500px) {
  .dashboard { padding: 8px 10px 16px; }
}


/* Contenu */
.content {
    background: var(--surface);
    padding: 28px;
    min-height: 400px;
}

/* Welcome */
.welcome {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 28px;
}
.avatar {
    width: 52px; height: 52px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--club) 0%, var(--club-dark) 100%);
    color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 17px;
    font-family: var(--font-display);
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(123, 30, 86, 0.25);
}
.welcome-titre { font-size: 22px; font-weight: 700; font-family: var(--font-display); letter-spacing: -0.01em; }
.welcome-sous { font-size: 13px; color: var(--text-secondary); font-weight: 500; }
.mon-evt-badge {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--club-light);
    border: 1px solid var(--club);
    border-radius: var(--radius);
    padding: 8px 14px;
    text-decoration: none;
    color: var(--text);
    transition: background 0.15s;
}
.mon-evt-badge:hover { background: #f0dfe9; }
.mon-evt-date {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 36px;
}
.mon-evt-jour { font-size: 20px; font-weight: 700; color: var(--club); line-height: 1; }
.mon-evt-mois { font-size: 11px; text-transform: uppercase; color: var(--club); font-weight: 600; }
.mon-evt-info { display: flex; flex-direction: column; }
.mon-evt-titre { font-size: 13px; font-weight: 600; }
.mon-evt-meta { font-size: 11px; color: var(--text-secondary); }
.mon-evt-fleche { font-size: 20px; color: var(--club); font-weight: 300; }

/* Metrics */
.metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(155px, 1fr));
    gap: 12px;
    margin-bottom: 24px;
}
.metric {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-left: 3px solid var(--gold);
    border-radius: var(--radius);
    padding: 16px;
    transition: box-shadow 0.2s, transform 0.15s;
}
.metric:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.metric-label { font-size: 12px; color: var(--text-secondary); margin-bottom: 6px; font-weight: 500; }
.metric-valeur { font-size: 28px; font-weight: 800; color: var(--text); font-family: var(--font-display); letter-spacing: -0.02em; }
.metric-accent .metric-valeur { color: var(--club); }
.metric-detail { font-size: 11px; color: var(--text-muted); margin-top: 3px; }

.toggle-lieu {
    display: flex;
    gap: 4px;
    margin-bottom: 8px;
}
.toggle-btn {
    flex: 1;
    padding: 4px 8px;
    font-size: 11px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface-2);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s;
}
.toggle-btn.active {
    background: var(--club);
    color: white;
    border-color: var(--club);
}

/* Quick actions */
.quick-actions {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
    margin-bottom: 28px;
}
.quick-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 13px;
    font-weight: 600;
    font-family: var(--font-display);
    color: var(--text);
    text-decoration: none;
    transition: border-color 0.2s, color 0.2s, box-shadow 0.2s, transform 0.15s;
}
.quick-btn:hover { border-color: var(--club); color: var(--club); text-decoration: none; box-shadow: var(--shadow-sm); transform: translateY(-1px); }
.quick-btn:active { transform: translateY(0); }

/* Two columns */
.two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* Sections */
.section { margin-bottom: 24px; }
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}
.section-titre { font-size: 16px; font-weight: 700; font-family: var(--font-display); }
.section-lien { font-size: 12px; color: var(--club); font-weight: 600; transition: color 0.2s; }
.section-lien:hover { color: var(--club-hover); }

/* Page header */
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}
.page-header h1 { font-size: 22px; font-weight: 700; font-family: var(--font-display); letter-spacing: -0.01em; }
.page-header-actions { display: flex; align-items: center; gap: 8px; }

/* Result rows */
.result-row {
    display: flex;
    align-items: center;
    padding: 12px 14px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-left: 3px solid var(--club);
    border-radius: var(--radius);
    margin-bottom: 8px;
    gap: 14px;
    transition: box-shadow 0.2s, border-left-color 0.2s;
}
.result-date { min-width: 50px; text-align: center; flex-shrink: 0; }
.result-jour { font-size: 20px; font-weight: 800; line-height: 1; font-family: var(--font-display); }
.result-mois { font-size: 11px; color: var(--text-secondary); text-transform: uppercase; font-weight: 600; letter-spacing: 0.03em; }
.result-info { flex: 1; min-width: 0; }
.result-lieu { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.result-meta { font-size: 11px; color: var(--text-secondary); margin-top: 2px; }
.result-detail-scores { font-size: 11px; color: var(--text-muted); margin-top: 2px; }
.result-score { font-size: 22px; font-weight: 800; color: var(--club); min-width: 55px; text-align: right; flex-shrink: 0; font-family: var(--font-display); }
.result-score span { font-size: 11px; color: var(--text-muted); font-weight: 400; font-family: var(--font-body); }

/* Result cards grid */
.resultats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 10px;
}
.result-card {
    display: flex;
    flex-direction: column;
    padding: 14px 16px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    text-decoration: none;
    color: inherit;
    transition: border-color 0.2s, box-shadow 0.2s, transform 0.15s;
}
.result-card:hover {
    border-color: var(--club);
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
    text-decoration: none;
}
.result-card:active { transform: translateY(0); }
.result-card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}
.result-card-date {
    font-size: 12px;
    color: var(--text-secondary);
    font-weight: 500;
}
.result-card-type {
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 20px;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text-secondary);
}
.result-card-lieu {
    font-size: 14px;
    font-weight: 700;
    font-family: var(--font-display);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 8px;
}
.result-card-bottom {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
}
.result-card-score {
    font-size: 24px;
    font-weight: 800;
    color: var(--club);
    font-family: var(--font-display);
    line-height: 1;
}
.result-card-score span {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 400;
    font-family: var(--font-body);
}
.result-card-series {
    font-size: 12px;
    color: var(--text-secondary);
    font-weight: 500;
}
.result-card-meta {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 6px;
}

/* Licence card */
.licence-card {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 14px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.licence-icon { font-size: 28px; }
.licence-info { flex: 1; }
.licence-titre { font-size: 13px; font-weight: 500; }
.licence-sous { font-size: 12px; color: var(--text-secondary); margin-top: 2px; }

/* Covoiturage */
.covoit-row {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 6px;
    gap: 12px;
}
.covoit-info { flex: 1; min-width: 0; }
.covoit-titre { font-size: 13px; font-weight: 500; }
.covoit-lieu { font-size: 11px; color: var(--text-secondary); margin-top: 2px; }
.covoit-badges { display: flex; gap: 6px; flex-shrink: 0; }

.covoit-card {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px;
    margin-bottom: 12px;
}
.covoit-card-header { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.covoit-card-header .covoit-titre { font-size: 16px; }
.covoit-statut { font-size: 13px; color: var(--text-secondary); padding: 8px 0; }
.covoit-form .form-row { margin-bottom: 8px; }

.badge {
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 20px;
    font-weight: 500;
    white-space: nowrap;
}
.badge-cond { background: var(--success-bg); color: var(--success); }
.badge-pass { background: var(--club-light); color: var(--club); }

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 20px;
    border: none;
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: 600;
    font-family: var(--font-display);
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--club); color: #fff; box-shadow: 0 2px 6px rgba(123, 30, 86, 0.2); }
.btn-primary:hover { background: var(--club-hover); box-shadow: 0 4px 12px rgba(123, 30, 86, 0.3); transform: translateY(-1px); }
.btn-secondary { background: var(--surface-2); color: var(--text); border: 1px solid var(--border); }
.btn-secondary:hover { border-color: var(--border-strong); transform: translateY(-1px); }
.btn-danger { background: var(--danger-bg); color: var(--danger); }
.btn-small { padding: 6px 14px; font-size: 12px; }
.btn-full { width: 100%; justify-content: center; }

/* Forms */
.form { }
.form-groupe { margin-bottom: 14px; }
.form-groupe label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 4px;
    color: var(--text-secondary);
}
.form-groupe input,
.form-groupe select,
.form-groupe textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 14px;
    font-family: var(--font-body);
    background: var(--surface);
    color: var(--text);
    transition: border-color 0.2s, box-shadow 0.2s;
}
.form-groupe input:focus,
.form-groupe select:focus,
.form-groupe textarea:focus {
    outline: none;
    border-color: var(--club);
    box-shadow: 0 0 0 3px rgba(123, 30, 86, 0.12);
}
.form-groupe input:disabled {
    background: var(--surface-2);
    color: var(--text-muted);
}
.form-groupe input[type="file"] {
    padding: 8px;
    border-style: dashed;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
}
.form-row .form-groupe { margin-bottom: 0; }

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 400;
    margin-bottom: 8px;
    cursor: pointer;
}
.checkbox-label input[type="checkbox"] { width: auto; }

/* Auth pages */
.auth-container {
    display: flex;
    justify-content: center;
    padding: 20px 0;
}
.auth-card {
    width: 100%;
    max-width: 400px;
}
.auth-titre { font-size: 24px; font-weight: 800; margin-bottom: 6px; font-family: var(--font-display); letter-spacing: -0.01em; }
.auth-sous-titre { font-size: 14px; color: var(--text-secondary); margin-bottom: 20px; }
.auth-lien {
    text-align: center;
    margin-top: 16px;
    font-size: 13px;
    color: var(--text-secondary);
}

/* Messages */
.message {
    padding: 12px 16px;
    border-radius: var(--radius);
    font-size: 13px;
    margin-bottom: 16px;
    font-weight: 500;
}
.message-ok { background: var(--success-bg); color: var(--success); border-left: 3px solid var(--success); }
.message-erreur { background: var(--danger-bg); color: var(--danger); border-left: 3px solid var(--danger); }

/* Empty state */
.vide { font-size: 13px; color: var(--text-muted); padding: 8px 0; }
.vide-large {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
}
.vide-large .btn { margin-top: 12px; }

/* Licence page */
.licence-section { }
.licence-info-bloc,
.licence-fichier-bloc {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    margin-bottom: 16px;
}
.licence-info-bloc h2,
.licence-fichier-bloc h2 { font-size: 16px; margin-bottom: 12px; font-family: var(--font-display); font-weight: 700; }
.licence-fichier-bloc h3 { font-size: 14px; margin: 16px 0 8px; font-family: var(--font-display); font-weight: 600; }
.info-grille { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.info-item { }
.info-label { display: block; font-size: 12px; color: var(--text-muted); }
.info-valeur { font-size: 14px; font-weight: 600; font-family: var(--font-display); }
.licence-image { max-width: 100%; border-radius: var(--radius); border: 1px solid var(--border); }
.licence-pdf-preview { padding: 16px; text-align: center; }
.licence-etapes {
    font-size: 13px;
    color: var(--text-secondary);
    margin: 0 0 12px 20px;
}
.licence-etapes li { margin-bottom: 4px; }

/* Grille volees entrainement */
.grille-volees-table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
    font-size: 13px;
}
.grille-volees-table th {
    background: var(--club-light);
    color: var(--club);
    padding: 8px 6px;
    text-align: center;
    font-weight: 600;
    font-size: 12px;
    font-family: var(--font-display);
}
.grille-volees-table td { padding: 4px; text-align: center; }
.grille-volees-table input[type="number"] {
    width: 44px;
    padding: 6px 2px;
    text-align: center;
    border: 1px solid var(--border);
    border-radius: 4px;
    font-size: 14px;
}
.grille-volees-table input:focus {
    outline: none;
    border-color: var(--club);
    box-shadow: 0 0 0 2px rgba(123, 30, 86, 0.12);
}
.grille-volees-table .volee-total {
    font-weight: 600;
    color: var(--club);
}
.score-total-label {
    font-size: 16px;
    text-align: right;
    padding: 12px 0;
}
.score-total-label strong {
    font-size: 26px;
    color: var(--club);
    font-family: var(--font-display);
    font-weight: 800;
}

/* Clickable rows */
.result-row-link {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s, border-left-color 0.2s, transform 0.15s;
}
.result-row-link:hover {
    border-color: var(--club);
    border-left-color: var(--gold);
    box-shadow: var(--shadow-md);
    text-decoration: none;
    transform: translateY(-1px);
}
.result-row-link:active { transform: translateY(0); }

/* Detail pages */
.detail-card {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px;
}
.detail-header {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 24px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--border);
}
.detail-score-big {
    font-size: 42px;
    font-weight: 800;
    color: var(--club);
    flex-shrink: 0;
    font-family: var(--font-display);
    letter-spacing: -0.02em;
}
.detail-score-big span {
    font-size: 16px;
    color: var(--text-muted);
    font-weight: 400;
    font-family: var(--font-body);
}
.detail-lieu-date { flex: 1; }
.detail-lieu { font-size: 18px; font-weight: 700; font-family: var(--font-display); }
.detail-date { font-size: 14px; color: var(--text-secondary); margin-top: 2px; }

.detail-infos {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    margin-bottom: 20px;
}
.detail-info-item {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 10px 12px;
}
.detail-label { display: block; font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; font-weight: 600; }
.detail-value { display: block; font-size: 15px; font-weight: 600; margin-top: 3px; font-family: var(--font-display); }

.detail-section {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
}
.detail-section-titre { font-size: 16px; font-weight: 700; margin-bottom: 12px; font-family: var(--font-display); }

.detail-series {
    display: flex;
    gap: 12px;
}
.detail-serie {
    flex: 1;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 14px;
    text-align: center;
}
.detail-serie-label { display: block; font-size: 12px; color: var(--text-secondary); margin-bottom: 4px; }
.detail-serie-score { display: block; font-size: 24px; font-weight: 800; font-family: var(--font-display); }
.detail-serie-total { border-color: var(--club); }
.detail-serie-total .detail-serie-score { color: var(--club); }

.detail-compteurs {
    display: flex;
    gap: 16px;
}
.detail-compteur {
    display: flex;
    align-items: baseline;
    gap: 6px;
}
.detail-compteur-val { font-size: 30px; font-weight: 800; color: var(--club); font-family: var(--font-display); }
.detail-compteur-label { font-size: 14px; color: var(--text-secondary); }

.table-scroll { overflow-x: auto; }
.volee-cumul { color: var(--text-secondary); font-size: 12px; }

.feuille-marque-img {
    max-width: 100%;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    margin-top: 8px;
}

/* ── DASHBOARD ENTRAÎNEUR ── */

.page { max-width: 1140px; margin: 0 auto; padding: 16px 20px 40px; }
.page-title { font-family: var(--font-display); font-size: 17px; font-weight: 700; }
.page-subtitle { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.header-badge {
    display: inline-flex; align-items: center; gap: 4px;
    background: var(--club-light); color: var(--club);
    font-size: 10px; font-weight: 600; font-family: var(--font-display);
    padding: 3px 10px; border-radius: 20px;
}

.stats-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 14px; }
.stat-card {
    background: var(--surface); border-radius: var(--radius);
    padding: 12px 14px; border: 1px solid var(--border); box-shadow: var(--shadow-sm);
}
.stat-label {
    font-size: 10px; font-weight: 600; text-transform: uppercase;
    letter-spacing: 0.05em; color: var(--text-muted);
    font-family: var(--font-display); margin-bottom: 4px;
}
.stat-value {
    font-family: var(--font-display); font-size: 22px; font-weight: 800;
    font-variant-numeric: tabular-nums; line-height: 1.1;
}
.stat-detail { font-size: 11px; color: var(--text-muted); margin-top: 3px; }
.stat-value .trend-up { color: var(--success); font-size: 13px; font-weight: 700; }
.stat-value .trend-down { color: var(--danger); font-size: 13px; font-weight: 700; }

/* Live competition */
:root {
    --live-bg: #1A1D2E; --live-surface: #232740; --live-border: #2E3350;
    --live-text: #E8EAEF; --live-muted: #8990A8;
    --live-row-from: #D4A028; --live-row-to: #B8891E; --live-row-text: #1A1400;
}
.live-card {
    background: var(--live-bg); border-radius: var(--radius);
    padding: 14px 16px; margin-bottom: 14px;
    border: 1px solid var(--live-border);
    box-shadow: 0 2px 12px rgba(26, 29, 46, 0.15);
}
.live-header {
    display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px;
}
.live-title-group { display: flex; align-items: center; gap: 8px; }
.live-title {
    font-family: var(--font-display); font-size: 13px; font-weight: 700; color: var(--live-text);
}
.live-badge {
    display: inline-flex; align-items: center; gap: 4px;
    background: rgba(229, 62, 62, 0.15); color: #F56565;
    font-size: 9px; font-weight: 700; font-family: var(--font-display);
    padding: 2px 8px; border-radius: 10px; text-transform: uppercase; letter-spacing: 0.05em;
}
.live-badge-dot {
    width: 5px; height: 5px; border-radius: 50%; background: #F56565;
    animation: pulse-dot 1.8s ease-in-out infinite;
}
.live-meta { font-size: 11px; color: var(--live-muted); font-family: var(--font-body); }
.live-refresh {
    display: inline-flex; align-items: center; gap: 4px;
    background: var(--live-surface); border: 1px solid var(--live-border);
    color: var(--live-muted); font-size: 10px; font-family: var(--font-display);
    font-weight: 600; padding: 4px 10px; border-radius: var(--radius-sm);
    cursor: pointer; transition: background 0.15s, color 0.15s; text-decoration: none;
}
.live-refresh:hover { background: var(--live-border); color: var(--live-text); }

.live-table-wrap { overflow-x: auto; margin: 0 -2px; }
.live-table { width: 100%; border-collapse: separate; border-spacing: 0 4px; font-variant-numeric: tabular-nums; }
.live-table th {
    font-size: 8px; font-weight: 600; color: var(--live-muted);
    text-transform: uppercase; letter-spacing: 0.06em;
    padding: 0 6px 4px; text-align: left; font-family: var(--font-display);
}
.live-table th:first-child { padding-left: 10px; }
.live-table th.al-r { text-align: right; }
.live-table th.al-c { text-align: center; }

.live-row td {
    padding: 8px 6px;
    background: linear-gradient(100deg, #D9AB2E 0%, #C89520 55%, #B88518 100%);
    color: var(--live-row-text); font-family: var(--font-display);
}
.live-row td:first-child { border-radius: 8px 0 0 8px; padding-left: 10px; }
.live-row td:last-child { border-radius: 0 8px 8px 0; padding-right: 10px; }
.live-row:nth-child(even) td {
    background: linear-gradient(100deg, #C99A22 0%, #B8891C 55%, #A87A15 100%);
}

.live-rank { font-size: 14px; font-weight: 800; opacity: 0.6; min-width: 18px; display: inline-block; }
.live-archer-cell { display: flex; align-items: center; gap: 8px; min-width: 160px; }
.live-avatar {
    width: 30px; height: 30px; border-radius: 50%;
    background: rgba(26, 20, 0, 0.15); color: rgba(26, 20, 0, 0.7);
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 11px; flex-shrink: 0;
    border: 2px solid rgba(26, 20, 0, 0.1);
}
.live-archer-name { font-size: 13px; font-weight: 700; line-height: 1.2; }
.live-archer-meta { font-size: 9px; font-weight: 500; opacity: 0.55; font-family: var(--font-body); }
.live-fleches { font-size: 13px; font-weight: 700; text-align: center; }
.live-fleches-label { font-size: 8px; font-weight: 500; opacity: 0.5; display: block; }
.live-volees { font-size: 10px; font-weight: 600; opacity: 0.75; font-family: var(--font-body); white-space: nowrap; }
.live-series { font-size: 12px; font-weight: 700; white-space: nowrap; }
.live-pct { font-size: 11px; font-weight: 600; text-align: center; }
.live-projection { text-align: right; }
.projection-pill {
    display: inline-block; padding: 3px 10px; border-radius: 12px;
    font-size: 13px; font-weight: 800;
    background: rgba(26, 20, 0, 0.12); min-width: 42px; text-align: center;
}
.projection-pill.high { background: rgba(45, 122, 58, 0.2); color: #145520; }
.projection-pill.mid { background: rgba(26, 20, 0, 0.12); }
.projection-pill.low { background: rgba(192, 57, 43, 0.15); color: #7A2018; }

.live-alert {
    display: flex; align-items: center; gap: 6px;
    background: rgba(229, 62, 62, 0.1); border: 1px solid rgba(229, 62, 62, 0.2);
    border-radius: var(--radius-sm); padding: 6px 10px; margin-top: 8px;
    font-size: 11px; color: #F9A8A8; font-family: var(--font-body);
}
.live-alert-icon { font-size: 14px; flex-shrink: 0; }

/* Archer list */
.archer-row {
    display: flex; align-items: center; gap: 8px;
    padding: 6px 0; border-bottom: 1px solid var(--border);
    text-decoration: none; color: inherit; transition: background 0.12s;
}
.archer-row:last-child { border-bottom: none; }
.archer-row:hover { background: var(--bg); margin: 0 -8px; padding: 6px 8px; border-radius: var(--radius-sm); }
.archer-avatar {
    width: 28px; height: 28px; border-radius: 50%;
    background: linear-gradient(135deg, var(--club), var(--club-hover));
    color: #fff; display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 10px; font-family: var(--font-display); flex-shrink: 0;
}
.archer-info { flex: 1; min-width: 0; }
.archer-name {
    font-family: var(--font-display); font-size: 12px; font-weight: 600;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.archer-detail { font-size: 10px; color: var(--text-muted); display: flex; gap: 6px; align-items: center; }
.archer-score { font-family: var(--font-display); font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; }
.archer-score-label { font-size: 9px; color: var(--text-muted); text-align: right; font-family: var(--font-body); }

.badge-cl { background: #DBEAFE; color: #1E40AF; }
.badge-co { background: #FED7AA; color: #9A3412; }
.badge-bb { background: #E9D5FF; color: #6B21A8; }

/* Activity feed */
.activity-item {
    display: flex; align-items: flex-start; gap: 8px;
    padding: 6px 0; border-bottom: 1px solid var(--border);
}
.activity-item:last-child { border-bottom: none; }
.activity-icon {
    width: 24px; height: 24px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 11px; flex-shrink: 0; margin-top: 1px;
}
.activity-icon.comp { background: var(--gold-light); }
.activity-icon.entr { background: #F1F5F9; }
.activity-content { flex: 1; min-width: 0; }
.activity-text { font-size: 11px; color: var(--text); line-height: 1.35; }
.activity-text strong { font-weight: 600; font-family: var(--font-display); }
.activity-date { font-size: 9px; color: var(--text-muted); margin-top: 1px; }

/* Nav live button */
.nav-live-btn {
    margin-left: 6px; align-self: center;
    padding: 4px 12px; border-radius: 20px;
    font-size: 11px; font-family: var(--font-display); font-weight: 600;
    text-decoration: none; cursor: pointer; border: none;
    background: linear-gradient(135deg, #D4A028, #E8B830);
    color: #1A1400; display: inline-flex; align-items: center; gap: 5px;
    transition: transform 0.15s, box-shadow 0.15s;
    box-shadow: 0 1px 4px rgba(212, 160, 40, 0.3);
}
.nav-live-btn:hover { transform: translateY(-1px); box-shadow: 0 2px 8px rgba(212, 160, 40, 0.4); }
.live-dot {
    width: 6px; height: 6px; border-radius: 50%; background: #E53E3E;
    animation: pulse-dot 1.8s ease-in-out infinite;
}

/* ── DASHBOARD ENTRAÎNEUR responsive ── */
@media (max-width: 960px) {
  .summary-row { grid-template-columns: repeat(2, 1fr); }
    .stats-strip { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 700px) {
    .stats-strip { grid-template-columns: 1fr; }
    .live-table { font-size: 11px; }
    .page { padding: 12px 12px 30px; }
}
@media (max-width: 500px) {
    .live-card { padding: 10px 10px; }
    .live-archer-cell { min-width: 120px; }
    .live-avatar { width: 26px; height: 26px; font-size: 10px; }
    .live-archer-name { font-size: 12px; }
}

/* ── COMPETITION LIVE PAGE ── */
.cl-tab-bar {
    display: flex; background: var(--live-bg); border-bottom: 1px solid var(--live-border);
    padding: 0;
}
.cl-tab-item {
    flex: 1; text-align: center; padding: 10px 0;
    font-family: var(--font-display); font-size: 12px; font-weight: 600;
    color: var(--live-muted); cursor: pointer; border: none; background: none;
    border-bottom: 2px solid transparent;
    transition: color 0.2s, border-color 0.2s;
}
.cl-tab-item:hover { color: var(--live-text); }
.cl-tab-item.active { color: #E8B830; border-bottom-color: #E8B830; }
.cl-tab-item:disabled { opacity: 0.4; cursor: not-allowed; }

/* Vue 1 : Formulaire */
.cl-form-page { max-width: 520px; margin: 0 auto; padding: 20px 16px 40px; }
.cl-form-header { margin-bottom: 20px; }
.cl-form-title { font-family: var(--font-display); font-size: 17px; font-weight: 700; }
.cl-form-subtitle { font-size: 12px; color: var(--text-muted); }
.cl-form-card {
    background: var(--surface); border-radius: var(--radius);
    padding: 16px; border: 1px solid var(--border); box-shadow: var(--shadow-sm);
}
.cl-form-group { margin-bottom: 14px; }
.cl-form-group:last-child { margin-bottom: 0; }
.cl-form-label {
    display: block; font-family: var(--font-display); font-size: 11px;
    font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em;
    color: var(--text-secondary); margin-bottom: 5px;
}
.cl-form-input, .cl-form-select {
    width: 100%; padding: 8px 10px; border: 1px solid var(--border);
    border-radius: var(--radius-sm); font-family: var(--font-body);
    font-size: 13px; color: var(--text); background: var(--surface);
    transition: border-color 0.15s; box-sizing: border-box;
}
.cl-form-input:focus, .cl-form-select:focus {
    outline: none; border-color: var(--club);
    box-shadow: 0 0 0 2px rgba(123, 30, 86, 0.12);
}
.cl-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.cl-type-toggle {
    display: flex; border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden;
}
.cl-type-btn {
    flex: 1; padding: 8px 0; text-align: center; border: none;
    font-family: var(--font-display); font-size: 12px; font-weight: 600;
    cursor: pointer; background: var(--surface); color: var(--text-muted);
    transition: background 0.15s, color 0.15s;
}
.cl-type-btn.active-salle { background: #1E40AF; color: #fff; }
.cl-type-btn.active-ext { background: #166534; color: #fff; }
.cl-type-hint { font-size: 10px; color: var(--text-muted); margin-top: 4px; font-style: italic; }

.cl-archer-check {
    display: flex; align-items: center; gap: 8px;
    padding: 6px 0; border-bottom: 1px solid var(--border); cursor: pointer;
}
.cl-archer-check:last-child { border-bottom: none; }
.cl-archer-check input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--club); flex-shrink: 0; }
.cl-archer-check-avatar {
    width: 26px; height: 26px; border-radius: 50%;
    background: linear-gradient(135deg, var(--club), var(--club-hover));
    color: #fff; display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 9px; font-family: var(--font-display); flex-shrink: 0;
}
.cl-archer-check-info { flex: 1; }
.cl-archer-check-name { font-family: var(--font-display); font-size: 12px; font-weight: 600; }
.cl-archer-check-detail { font-size: 10px; color: var(--text-muted); }

.cl-btn-primary {
    width: 100%; padding: 10px; border: none; border-radius: var(--radius-sm);
    background: linear-gradient(135deg, var(--live-row-from), #E8B830);
    color: #1A1400; font-family: var(--font-display); font-size: 13px;
    font-weight: 700; cursor: pointer; margin-top: 16px;
    transition: transform 0.12s, box-shadow 0.12s;
    box-shadow: 0 2px 8px rgba(212, 160, 40, 0.25);
}
.cl-btn-primary:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(212, 160, 40, 0.35); }

.cl-warning {
    background: var(--gold-light); border: 1px solid rgba(196, 149, 46, 0.3);
    border-radius: var(--radius-sm); padding: 10px 14px; margin-bottom: 16px;
    font-size: 12px; color: var(--text);
}
.cl-warning a { color: var(--club); font-weight: 600; }

/* Vue 2 : Live */
.cl-live-page { background: var(--live-bg); min-height: calc(100vh - 44px); padding: 0 0 40px; }
.cl-live-top-bar {
    display: flex; align-items: center; justify-content: space-between;
    padding: 12px 16px; border-bottom: 1px solid var(--live-border);
}
.cl-live-top-left { display: flex; align-items: center; gap: 8px; }
.cl-live-back {
    color: var(--live-muted); font-size: 18px; text-decoration: none;
    display: flex; align-items: center; padding: 2px;
}
.cl-live-page-title { font-family: var(--font-display); font-size: 15px; font-weight: 700; color: var(--live-text); }
.live-page-badge {
    display: inline-flex; align-items: center; gap: 4px;
    background: rgba(229, 62, 62, 0.15); color: #F56565;
    font-size: 9px; font-weight: 700; font-family: var(--font-display);
    padding: 2px 8px; border-radius: 10px; text-transform: uppercase; letter-spacing: 0.05em;
}
.live-page-badge-dot {
    width: 5px; height: 5px; border-radius: 50%; background: #F56565;
    animation: pulse-dot 1.8s ease-in-out infinite;
}
.cl-live-top-actions { display: flex; align-items: center; gap: 6px; }
.cl-live-refresh-btn {
    display: inline-flex; align-items: center; gap: 4px;
    background: var(--live-surface); border: 1px solid var(--live-border);
    color: var(--live-muted); font-size: 10px; font-family: var(--font-display);
    font-weight: 600; padding: 5px 10px; border-radius: var(--radius-sm);
    cursor: pointer; transition: background 0.15s, color 0.15s; text-decoration: none;
}
.cl-live-refresh-btn:hover { background: var(--live-border); color: var(--live-text); }
.cl-live-end-btn {
    display: inline-flex; align-items: center; gap: 4px;
    background: rgba(229, 62, 62, 0.15); border: 1px solid rgba(229, 62, 62, 0.3);
    color: #F56565; font-size: 10px; font-family: var(--font-display);
    font-weight: 600; padding: 5px 10px; border-radius: var(--radius-sm);
    cursor: pointer; transition: background 0.15s;
}
.cl-live-end-btn:hover { background: rgba(229, 62, 62, 0.25); }

.cl-comp-info {
    display: flex; align-items: center; gap: 12px;
    padding: 10px 16px; border-bottom: 1px solid var(--live-border); flex-wrap: wrap;
}
.cl-comp-info-item {
    font-size: 11px; color: var(--live-muted); font-family: var(--font-body);
    display: flex; align-items: center; gap: 4px;
}
.cl-comp-info-item strong { color: var(--live-text); font-family: var(--font-display); font-weight: 600; }
.cl-comp-type-badge {
    font-size: 9px; font-weight: 700; font-family: var(--font-display);
    padding: 2px 8px; border-radius: 10px; text-transform: uppercase; letter-spacing: 0.04em;
}
.cl-comp-type-badge.salle { background: rgba(30, 64, 175, 0.2); color: #60A5FA; }
.cl-comp-type-badge.ext { background: rgba(22, 101, 52, 0.2); color: #6EE7B7; }

/* Mobile cards */
.cl-live-cards { padding: 8px 12px; }
.alc-card {
    background: linear-gradient(135deg, #D9AB2E 0%, #C08A18 100%);
    border-radius: var(--radius); padding: 12px 14px; margin-bottom: 8px;
    color: var(--live-row-text);
}
.alc-card:nth-child(even) {
    background: linear-gradient(135deg, #C99A22 0%, #A87A15 100%);
}
.alc-header { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.alc-rank { font-family: var(--font-display); font-size: 20px; font-weight: 800; opacity: 0.4; min-width: 22px; }
.alc-avatar {
    width: 34px; height: 34px; border-radius: 50%;
    background: rgba(26, 20, 0, 0.15); color: rgba(26, 20, 0, 0.7);
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 12px; font-family: var(--font-display);
    border: 2px solid rgba(26, 20, 0, 0.1); flex-shrink: 0;
}
.alc-info { flex: 1; }
.alc-name { font-family: var(--font-display); font-size: 14px; font-weight: 700; line-height: 1.2; }
.alc-meta { font-size: 10px; font-weight: 500; opacity: 0.55; font-family: var(--font-body); }
.alc-projection {
    display: inline-block; padding: 4px 12px; border-radius: 14px;
    font-family: var(--font-display); font-size: 16px; font-weight: 800;
    background: rgba(26, 20, 0, 0.12); min-width: 48px; text-align: center;
}
.alc-projection.high { background: rgba(45, 122, 58, 0.2); color: #145520; }
.alc-projection.low { background: rgba(192, 57, 43, 0.15); color: #7A2018; }
.alc-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-bottom: 8px; }
.alc-stat { text-align: center; }
.alc-stat-label {
    font-size: 8px; font-weight: 600; text-transform: uppercase;
    letter-spacing: 0.04em; opacity: 0.5; font-family: var(--font-display); margin-bottom: 2px;
}
.alc-stat-value { font-family: var(--font-display); font-size: 14px; font-weight: 800; font-variant-numeric: tabular-nums; }
.alc-series { display: flex; gap: 6px; margin-bottom: 6px; }
.alc-serie {
    flex: 1; text-align: center; padding: 4px 0;
    background: rgba(26, 20, 0, 0.08); border-radius: var(--radius-sm);
}
.alc-serie-label {
    font-size: 8px; font-weight: 600; opacity: 0.5;
    font-family: var(--font-display); text-transform: uppercase;
}
.alc-serie-value { font-family: var(--font-display); font-size: 16px; font-weight: 800; font-variant-numeric: tabular-nums; }
.alc-serie-value.pending { opacity: 0.3; }
.alc-volees {
    font-size: 10px; font-weight: 500; opacity: 0.6;
    font-family: var(--font-body); line-height: 1.5; word-spacing: 1px;
}
.alc-volees-label {
    font-size: 8px; font-weight: 600; text-transform: uppercase;
    letter-spacing: 0.04em; opacity: 0.45; font-family: var(--font-display); margin-bottom: 2px;
}
.alc-alert {
    display: flex; align-items: center; gap: 6px;
    background: rgba(229, 62, 62, 0.12); border: 1px solid rgba(229, 62, 62, 0.25);
    border-radius: var(--radius-sm); padding: 6px 10px; margin-top: 6px;
    font-size: 10px; color: rgba(120, 30, 20, 0.85); font-family: var(--font-body);
}
.alc-alert-icon { font-size: 13px; flex-shrink: 0; }
.alc-status {
    display: inline-flex; align-items: center; gap: 4px;
    font-size: 9px; font-weight: 600; font-family: var(--font-display);
    padding: 2px 6px; border-radius: 8px; text-transform: uppercase; letter-spacing: 0.03em;
}
.alc-status.en-cours { background: rgba(229, 62, 62, 0.15); color: rgba(160, 40, 30, 0.8); }
.alc-status.termine { background: rgba(45, 122, 58, 0.15); color: rgba(20, 80, 30, 0.8); }
.alc-status.attente { background: rgba(100, 100, 120, 0.12); color: rgba(100, 100, 120, 0.8); }

/* Vue 3 : Historique */
.cl-history-page { max-width: 600px; margin: 0 auto; padding: 16px 16px 40px; }
.cl-history-title { font-family: var(--font-display); font-size: 15px; font-weight: 700; margin-bottom: 12px; }
.cl-history-card {
    background: var(--surface); border-radius: var(--radius);
    border: 1px solid var(--border); box-shadow: var(--shadow-sm);
    padding: 12px 14px; margin-bottom: 8px;
    text-decoration: none; color: inherit; display: block;
    transition: box-shadow 0.15s, transform 0.15s;
}
.cl-history-card:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.cl-history-card-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.cl-history-card-name { font-family: var(--font-display); font-size: 13px; font-weight: 700; }
.cl-history-card-date { font-size: 10px; color: var(--text-muted); }
.cl-history-card-detail { font-size: 11px; color: var(--text-secondary); }
.cl-history-card-archers { display: flex; margin-top: 6px; }
.cl-history-avatar-sm {
    width: 22px; height: 22px; border-radius: 50%;
    background: linear-gradient(135deg, var(--club), var(--club-hover));
    color: #fff; display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 8px; font-family: var(--font-display);
    border: 2px solid var(--surface); margin-left: -6px;
}
.cl-history-avatar-sm:first-child { margin-left: 0; }

/* Competition Live responsive */
@media (max-width: 500px) {
    .alc-stats { grid-template-columns: repeat(4, 1fr); gap: 4px; }
    .cl-comp-info { gap: 8px; }
    .cl-form-row { grid-template-columns: 1fr; }
    .cl-live-top-bar { flex-direction: column; gap: 8px; align-items: flex-start; }
    .cl-live-top-actions { width: 100%; justify-content: flex-end; }
}

/* Admin */

.badge-lieu-int, .badge-lieu-ext { display:inline-block; padding:2px 8px; border-radius:4px; font-size:12px; font-weight:500; }
.badge-lieu-int { background:#eff6ff; color:#1e40af; }
.badge-lieu-ext { background:#dcfce7; color:#166534; }

.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
    margin-bottom: 20px;
}
.admin-stat {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 16px;
    transition: border-color 0.2s, box-shadow 0.15s;
}
.admin-stat:hover { border-color: var(--border-strong); box-shadow: var(--shadow-sm); }

.admin-quick-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
    gap: 8px;
    margin-bottom: 20px;
}
.admin-quick {
    display: flex; align-items: center; gap: 10px;
    padding: 14px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 13px; font-weight: 600;
    font-family: var(--font-display);
    color: var(--text);
    text-decoration: none;
    transition: border-color 0.2s, box-shadow 0.2s, transform 0.15s;
}
.admin-quick:hover { border-color: var(--club); color: var(--club); text-decoration: none; box-shadow: var(--shadow-sm); transform: translateY(-1px); }
.admin-quick-icon {
    width: 32px; height: 32px;
    border-radius: var(--radius);
    display: flex; align-items: center; justify-content: center;
    font-size: 16px; flex-shrink: 0;
}
.qa-licences .admin-quick-icon { background: var(--club-light); }
.qa-roles .admin-quick-icon { background: var(--gold-light); }
.qa-abonnes .admin-quick-icon { background: #e8f0fe; }
.qa-entraineurs .admin-quick-icon { background: var(--success-bg); }

.admin-panel {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    margin-bottom: 16px;
    overflow: hidden;
}
.admin-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
}
.admin-panel-header h2 { font-size: 15px; font-weight: 700; font-family: var(--font-display); }

.admin-feed-item {
    display: flex; gap: 10px; align-items: center;
    padding: 10px 16px;
    border-bottom: 1px solid var(--border);
    font-size: 13px;
}
.admin-feed-item:last-child { border-bottom: none; }
.admin-feed-dot {
    width: 6px; height: 6px;
    border-radius: 50%;
    flex-shrink: 0;
}
.dot-prune { background: var(--club); }
.dot-gold { background: var(--gold); }
.dot-warn { background: #b87a00; }
.admin-feed-text { flex: 1; }
.admin-feed-text strong { font-weight: 600; }
.admin-feed-time { font-size: 11px; color: var(--text-muted); white-space: nowrap; }
.admin-feed-sub { font-size: 11px; color: var(--text-muted); }

.admin-badge-warn {
    display: inline-block;
    font-size: 10px; font-weight: 600;
    padding: 2px 7px;
    border-radius: 10px;
    background: #fef6e0; color: #b87a00;
}

.admin-search-bar {
    display: flex; gap: 8px;
    padding: 10px 16px;
    border-bottom: 1px solid var(--border);
}
.admin-search-input {
    padding: 7px 10px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 13px;
    background: var(--surface);
    color: var(--text);
}
.admin-search-input:focus {
    outline: none;
    border-color: var(--club);
    box-shadow: 0 0 0 2px rgba(123, 30, 86, 0.1);
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}
.admin-table th {
    text-align: left;
    padding: 8px 16px;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    font-weight: 600;
    font-family: var(--font-display);
    border-bottom: 1px solid var(--border);
    background: var(--surface-2);
}
.admin-table td {
    padding: 10px 16px;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}
.admin-table tr:last-child td { border-bottom: none; }
.admin-table tr:hover td { background: var(--surface-2); transition: background 0.15s; }
.row-inactive { opacity: 0.5; }

.admin-user-cell { display: flex; align-items: center; gap: 8px; }
.admin-avatar-sm {
    width: 28px; height: 28px; border-radius: 50%;
    background: var(--club-light);
    color: var(--club);
    display: flex; align-items: center; justify-content: center;
    font-size: 10px; font-weight: 600; flex-shrink: 0;
}
.admin-user-name { font-weight: 500; }
.mono { font-variant-numeric: tabular-nums; }

.status-dot {
    display: inline-block;
    width: 7px; height: 7px;
    border-radius: 50%;
    margin-right: 5px;
}
.dot-active { background: var(--success); }
.dot-inactive { background: var(--text-muted); }

.role-badge {
    display: inline-block;
    font-size: 10px; font-weight: 700;
    padding: 3px 8px;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    margin-right: 2px;
    font-family: var(--font-display);
}
.rb-admin { background: var(--club-light); color: var(--club); }
.rb-bureau { background: var(--gold-light); color: var(--gold); }
.rb-entraineur { background: var(--success-bg); color: var(--success); }
.rb-licencie { background: var(--surface-2); color: var(--text-muted); }

.btn-danger-sm { background: var(--danger-bg); color: var(--danger); border-color: var(--danger-bg); }

.admin-role-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 6px;
}
.admin-role-info { display: flex; align-items: center; gap: 10px; }
.admin-role-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.admin-role-name { font-size: 13px; font-weight: 500; }
.admin-role-desc { font-size: 11px; color: var(--text-secondary); }
.admin-role-count { font-size: 12px; color: var(--text-muted); }

.admin-edit-member {
    display: flex; align-items: center; gap: 10px;
    padding: 12px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 12px;
}
.admin-toggle-label {
    display: flex; align-items: center; gap: 8px;
    font-size: 13px; cursor: pointer;
}

.admin-chip {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 3px 8px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: 12px;
    font-size: 11px; color: var(--text-secondary);
}
.admin-chip-remove {
    background: none; border: none;
    cursor: pointer; color: var(--text-muted);
    font-size: 14px; line-height: 1;
    padding: 0 2px;
}
.admin-chip-remove:hover { color: var(--danger); }

/* ==============================
   MOBILE RESPONSIVE
   ============================== */
@media (max-width: 767px) {
    .app { margin: 0; border-radius: 0; box-shadow: none; }
    .content { padding: 16px; padding-bottom: 100px; }
    .two-col { grid-template-columns: 1fr; }
    .metrics { grid-template-columns: repeat(2, 1fr); }
    .quick-actions { grid-template-columns: repeat(2, 1fr); }
    .welcome { flex-wrap: wrap; }
    .mon-evt-badge { margin-left: 0; width: 100%; }
    .welcome-titre { font-size: 18px; }
    .page-header { flex-direction: column; gap: 10px; align-items: flex-start; }
    .form-row { grid-template-columns: 1fr; }
    .info-grille { grid-template-columns: 1fr; }
    .covoit-card-header { flex-wrap: wrap; }
    .covoit-badges { width: 100%; }
    .detail-header { flex-direction: column; gap: 12px; }
    .detail-score-big { font-size: 36px; }
    .metric-valeur { font-size: 24px; }
    .famille-banner { margin: -16px -16px 16px; }
    .topbar { height: 48px; padding: 0 14px; }
    .topbar-title { font-size: 13px; }
    .topbar-retour-btn { font-size: 11px; padding: 5px 10px; }
    .espace-nav { display: flex; }
    .espace-nav-tab { padding: 8px 14px; font-size: 12px; }
}

@media (max-width: 480px) {
    .metrics { grid-template-columns: 1fr 1fr; }
    .quick-actions { grid-template-columns: 1fr; }
    .detail-score-big { font-size: 30px; }
    .classement-rang-card { min-width: 60px; }
}

.metric-classement { cursor: pointer; transition: box-shadow 0.2s, transform 0.15s; }
.metric-classement:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.metric-classement .metric-valeur { color: var(--club); }
.metric-classement .metric-valeur sup { font-size: 12px; }
.classement-rangs { display: flex; gap: 12px; margin: 6px 0; }
.classement-rang-item { display: flex; flex-direction: column; align-items: center; }
.classement-niv { font-size: 10px; font-weight: 600; text-transform: uppercase; color: var(--text-secondary); }

.select-saison { padding: 6px 10px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface-2); color: var(--text); font-size: 13px; font-family: var(--font-body); transition: border-color 0.2s; }
.select-saison:focus { outline: none; border-color: var(--club); box-shadow: 0 0 0 3px rgba(123, 30, 86, 0.12); }
.classement-hist-titre { font-size: 15px; font-weight: 700; color: var(--text-secondary); margin: 0.75rem 0 0.4rem; font-family: var(--font-display); }

/* Grille classements : côte à côte sur desktop */
.classements-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
}
.classement-bloc {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.75rem 1rem;
}
.classement-scores {
    display: flex;
    gap: 1rem;
    align-items: baseline;
    flex-wrap: wrap;
    margin-bottom: 0.5rem;
}
.classement-scores-nums {
    display: flex;
    gap: 0.5rem;
    align-items: baseline;
}
.classement-scores-label { font-size: 0.8rem; color: var(--text-muted); }
.classement-score { font-size: 1rem; font-weight: 600; font-family: var(--font-display); }
.classement-moyenne { font-size: 1.1rem; font-weight: 800; font-family: var(--font-display); color: var(--club); }
.classement-meta { font-size: 0.8rem; color: var(--text-muted); }
.classement-rangs {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 0.25rem;
}
.classement-rang-card {
    text-align: center;
    padding: 0.4rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    min-width: 70px;
    transition: border-color 0.2s, box-shadow 0.15s;
}
.classement-rang-card:hover { border-color: var(--club); box-shadow: var(--shadow-sm); }
.classement-rang-val { font-size: 1.2rem; font-weight: 800; font-family: var(--font-display); color: var(--club); }
.classement-rang-val sup { font-size: 0.6rem; }
.classement-rang-total { font-size: 0.8rem; color: var(--text-muted); }
.classement-rang-niv { font-size: 0.75rem; font-weight: 500; margin-top: 0.1rem; }
.classement-trend { font-size: 0.7rem; font-weight: 600; margin-top: 0.15rem; border-radius: 4px; padding: 1px 5px; }
.trend-up { color: #fff; background: var(--success); }
.trend-down { color: #fff; background: var(--danger, #c0392b); }
.trend-stable { color: var(--text-muted); background: var(--surface-alt, #eee); }
.classement-maj { font-size: 0.7rem; color: var(--text-muted); margin-top: 0.2rem; }

/* Voisins classement */
.voisins-table { width: 100%; font-size: 0.8rem; border-collapse: collapse; margin-top: 0.5rem; }
.voisins-table td { padding: 3px 6px; border-bottom: 1px solid var(--border, #eee); }
.voisins-table tr.voisin-moi { background: var(--surface-alt, #f5f5f5); font-weight: 600; }
.voisins-table .voisin-rang { color: var(--text-muted); width: 2rem; text-align: right; }
.voisins-table .voisin-score { text-align: right; font-variant-numeric: tabular-nums; }

/* Layout classements + progression côte à côte sur desktop */
@media (min-width: 900px) {
    .classements-layout {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 1rem;
        align-items: start;
    }
}
.prog-controls {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}
.prog-controls .select-saison { min-width: 0; }
.prog-disc-section { display: none; }
.prog-disc-section.active { display: block; }
.table-classements { width: 100%; border-collapse: collapse; font-size: 13px; }
.table-classements th { text-align: left; padding: 8px 10px; border-bottom: 2px solid var(--border); font-size: 11px; text-transform: uppercase; color: var(--text-secondary); font-family: var(--font-display); font-weight: 600; letter-spacing: 0.3px; }
.table-classements td { padding: 8px 10px; border-bottom: 1px solid var(--border); transition: background 0.15s; }
.table-classements td strong { color: var(--club); font-family: var(--font-display); font-weight: 700; }
.table-classements tr:last-child td { border-bottom: none; }
.table-classements tr:hover td { background: var(--surface-2); }

/* Evenements - badges */
.evt-badge { display: inline-flex; align-items: center; gap: 3px; font-size: 11px; padding: 3px 9px; border-radius: var(--radius); font-weight: 600; white-space: nowrap; font-family: var(--font-display); letter-spacing: 0.02em; }
.badge-salle { background: #dbeafe; color: #1e40af; }
.badge-ext { background: #dcfce7; color: #166534; }
.badge-3d { background: #fed7aa; color: #9a3412; }
.badge-jeunes { background: #fef3c7; color: #92400e; }
.badge-ag { background: #f3f4f6; color: #374151; }
.badge-club { background: var(--club-light); color: var(--club); }
.badge-entr { background: #f1f5f9; color: #64748b; }
.badge-autre { background: #f3f4f6; color: #6b7280; }

/* Evenements - cartes */
.evt-card { display: flex; align-items: flex-start; gap: 12px; padding: 0.875rem 1rem; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 0.5rem; transition: border-color 0.2s, box-shadow 0.2s; }
.evt-card:hover { border-color: var(--border-strong); box-shadow: var(--shadow-sm); }
.evt-date { min-width: 48px; text-align: center; }
.evt-date-mois { font-size: 11px; font-weight: 600; text-transform: uppercase; color: var(--club); letter-spacing: 0.5px; font-family: var(--font-display); }
.evt-date-jour { font-size: 24px; font-weight: 800; color: var(--text); line-height: 1.2; font-family: var(--font-display); }
.evt-date-sem { font-size: 11px; color: var(--text-secondary); }
.evt-body { flex: 1; min-width: 0; }
.evt-titre-row { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; flex-wrap: wrap; }
.evt-titre { font-size: 14px; font-weight: 600; color: var(--text); text-decoration: none; font-family: var(--font-display); }
.evt-titre:hover { text-decoration: underline; color: var(--club); }
.evt-meta { font-size: 12px; color: var(--text-secondary); display: flex; align-items: center; gap: 10px; margin-bottom: 6px; flex-wrap: wrap; }
.evt-lien-mandat { color: var(--club); text-decoration: none; font-weight: 500; }
.evt-lien-mandat:hover { text-decoration: underline; }
.evt-footer { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.evt-personnes { display: flex; align-items: center; gap: 4px; }
.evt-avatar { width: 24px; height: 24px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 600; }
.evt-avatar-more { font-size: 11px; color: var(--text-secondary); }
.evt-compte { font-size: 11px; color: var(--text-secondary); margin-left: 4px; }
.evt-vide { font-size: 11px; color: var(--text-secondary); font-style: italic; }
.evt-covoit { font-size: 11px; color: var(--text-secondary); }
.evt-actions { display: flex; flex-direction: column; gap: 4px; min-width: 90px; align-items: flex-end; }
.evt-btn { font-size: 12px; padding: 5px 12px; border-radius: var(--radius); cursor: pointer; text-decoration: none; text-align: center; display: inline-block; font-family: var(--font-display); font-weight: 600; transition: background 0.2s, transform 0.15s, box-shadow 0.15s; }
.evt-btn:active { transform: scale(0.96); }
.evt-btn-confirme { background: var(--club); color: #fff; }
.evt-btn-confirme:hover { background: var(--club-hover); box-shadow: var(--shadow-sm); }
.evt-btn-interesse { background: transparent; color: var(--text-secondary); border: 1px solid var(--border); }
.evt-btn-interesse:hover { border-color: var(--border-strong); }
.evt-btn-confirme-actif { background: #dbeafe; color: #1e40af; font-weight: 600; }
.evt-btn-interesse-actif { background: #f3f4f6; color: #6b7280; font-weight: 600; }

/* Evenements - dashboard */
.evt-dash-row { display: flex; align-items: flex-start; gap: 12px; padding: 0.75rem 0; border-bottom: 1px solid var(--border); text-decoration: none; color: inherit; transition: background 0.15s; }
.evt-dash-row:last-child { border-bottom: none; }
.evt-dash-row:hover { background: var(--bg-hover); }
.evt-dash-row .evt-date-jour { font-family: var(--font-display); font-weight: 800; }
.evt-dash-row .evt-date-mois { font-family: var(--font-display); color: var(--club); }
.evt-dash-date { min-width: 42px; text-align: center; }
.evt-dash-info { flex: 1; min-width: 0; }

/* Evenements - detail */
.evt-detail-infos { margin-bottom: 1rem; }
.evt-detail-row { display: flex; gap: 12px; padding: 6px 0; border-bottom: 1px solid var(--border); }
.evt-detail-row:last-child { border-bottom: none; }
.evt-detail-label { font-size: 13px; color: var(--text-secondary); min-width: 80px; }
.evt-description { font-size: 14px; color: var(--text-secondary); margin: 1rem 0; line-height: 1.5; }
.evt-detail-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.agenda-dropdown { position: relative; }
.agenda-dropdown-menu {
    display: none;
    position: absolute;
    bottom: 100%;
    left: 0;
    margin-bottom: 4px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    min-width: 240px;
    z-index: 10;
}
.agenda-dropdown.open .agenda-dropdown-menu { display: block; }
.agenda-dropdown-menu a {
    display: block;
    padding: 10px 14px;
    font-size: 14px;
    color: var(--text);
    text-decoration: none;
    border-bottom: 1px solid var(--border);
}
.agenda-dropdown-menu a:last-child { border-bottom: none; }
.agenda-dropdown-menu a:hover { background: var(--bg); }
.evt-choix-interet { display: flex; gap: 0.5rem; }
.evt-mon-statut { display: flex; align-items: center; gap: 0.5rem; }
.evt-participant { display: flex; align-items: center; gap: 8px; padding: 4px 0; }

/* Covoiturage - detail evenement */
.covoit-vehicule { background: var(--bg-alt); border: 1px solid var(--border); border-radius: var(--radius); padding: 0.75rem; margin-bottom: 0.5rem; transition: border-color 0.2s; }
.covoit-vehicule:hover { border-color: var(--border-strong); }
.covoit-vehicule-header { display: flex; justify-content: space-between; align-items: center; font-weight: 700; font-size: 14px; font-family: var(--font-display); }
.covoit-places { font-size: 12px; font-weight: 400; color: var(--text-secondary); }
.covoit-commentaire { font-size: 12px; color: var(--text-secondary); font-style: italic; margin-top: 4px; }
.covoit-passagers { margin-top: 8px; }
.covoit-passager { display: flex; align-items: center; justify-content: space-between; padding: 4px 0; font-size: 13px; border-top: 1px solid var(--border); }
.covoit-attente { margin-top: 1rem; }
.covoit-attente h4 { font-size: 13px; color: var(--text-secondary); margin: 0 0 0.5rem; }
.covoit-passager-attente { display: inline-block; font-size: 12px; background: #fef3c7; color: #92400e; padding: 2px 8px; border-radius: var(--radius); margin: 0 4px 4px 0; }

/* Calendrier grille */
.cal-nav { display: flex; align-items: center; gap: 8px; }
.cal-nav-btn { font-size: 14px; padding: 4px 8px; border: 1px solid var(--border); border-radius: var(--radius); text-decoration: none; color: var(--text); background: var(--surface-2); transition: border-color 0.2s, background 0.15s; }
.cal-nav-btn:hover { background: var(--bg-hover); border-color: var(--border-strong); }
.cal-nav-mois { font-size: 15px; font-weight: 700; min-width: 140px; text-align: center; font-family: var(--font-display); }
.cal-legende { display: flex; gap: 12px; margin-bottom: 10px; flex-wrap: wrap; }
.cal-leg-item { font-size: 11px; color: var(--text-secondary); display: flex; align-items: center; }
.cal-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 4px; }
.cal-dot-salle { background: #3b82f6; }
.cal-dot-ext { background: #22c55e; }
.cal-dot-3d { background: #f97316; }
.cal-dot-club { background: #8b5cf6; }
.cal-dot-entr { background: #94a3b8; }
.cal-grille-wrap { overflow-x: auto; }
.cal-grille { width: 100%; border-collapse: collapse; table-layout: fixed; }
.cal-grille th { font-size: 11px; font-weight: 600; color: var(--text-secondary); padding: 6px 4px; text-align: center; border: 1px solid var(--border); text-transform: uppercase; }
.cal-cell { border: 1px solid var(--border); padding: 4px; min-height: 70px; vertical-align: top; font-size: 12px; }
.cal-cell-vide { background: var(--bg-alt); }
.cal-cell-today { background: var(--club-light); }
.cal-jour { font-size: 12px; font-weight: 700; color: var(--text); margin-bottom: 2px; font-family: var(--font-display); }
.cal-evt { display: block; font-size: 10px; padding: 1px 4px; border-radius: 3px; margin-bottom: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-decoration: none; cursor: pointer; }

/* Admin evenements */
.badge-evt { font-size: 11px; padding: 2px 6px; border-radius: 4px; }
.badge-comp-salle { background: #dbeafe; color: #1e40af; }
.badge-comp-exterieur { background: #dcfce7; color: #166534; }
.badge-comp-3d { background: #fed7aa; color: #9a3412; }
.badge-comp-jeunes { background: #fef3c7; color: #92400e; }

/* Famille - bannière switcher */
.famille-banner {
    background: var(--gold-light);
    border-bottom: 1px solid #e8d5a0;
    padding: 8px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    gap: 10px;
    flex-wrap: wrap;
    margin: -20px -20px 16px;
}
.famille-banner-parent { background: var(--club-light); border-bottom-color: #dbc6d4; }
.famille-banner-actions { display: flex; gap: 8px; align-items: center; }
.famille-switch-link {
    background: var(--club);
    color: #fff;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
}
.famille-switch-link:hover { background: var(--club-hover); text-decoration: none; }
.famille-retour {
    background: var(--surface);
    border: 1px solid var(--border);
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text);
    text-decoration: none;
}
.famille-retour:hover { background: var(--bg); text-decoration: none; }

/* Famille - tags admin */
.famille-tag {
    font-size: 11px;
    color: var(--text-secondary);
    margin-top: 2px;
}
.famille-tag-parent { color: var(--club); font-weight: 600; }

/* Modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(30, 21, 32, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    backdrop-filter: blur(4px);
}
.modal-box {
    background: var(--surface);
    border-radius: var(--radius-lg);
    padding: 28px;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 12px 40px rgba(90, 22, 64, 0.18);
}
.modal-box h3 { margin-bottom: 8px; font-size: 17px; font-family: var(--font-display); font-weight: 700; }
.modal-box p { font-size: 14px; color: var(--text-secondary); }

/* Toggle switch simplifié/détaillé */
.view-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: var(--text-secondary);
}
.view-toggle-label { white-space: nowrap; }
.view-toggle-label.active { color: var(--text); font-weight: 600; }
.toggle-switch {
    position: relative;
    width: 44px;
    height: 24px;
    background: var(--border-strong);
    border-radius: 12px;
    cursor: pointer;
    transition: background 0.2s;
    flex-shrink: 0;
}
.toggle-switch.on { background: var(--club); }
.toggle-switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background: white;
    border-radius: 50%;
    transition: transform 0.2s;
    box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}
.toggle-switch.on::after { transform: translateX(20px); }

/* Progression : stats cards */
.prog-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 8px;
    margin-bottom: 16px;
}
.prog-stat {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 6px 10px;
    text-align: center;
}
.prog-stat-value { font-size: 20px; font-weight: 800; color: var(--club); line-height: 1.2; font-family: var(--font-display); }
.prog-stat-label { font-size: 10px; color: var(--text-secondary); margin-top: 1px; font-family: var(--font-display); font-weight: 500; }
.prog-stat-sub { font-size: 9px; color: var(--text-muted); }
.prog-trend-up { color: var(--success); }
.prog-trend-down { color: var(--danger); }

/* Progression : graphe SVG */
.prog-chart-wrap {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px;
    margin-bottom: 16px;
    overflow-x: auto;
}
.prog-chart-wrap svg { display: block; width: 100%; height: auto; }

/* Progression : vue simplifiée barres */
.prog-bar-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
    font-size: 13px;
}
.prog-bar-row:last-child { border-bottom: none; }
.prog-bar-date { min-width: 70px; color: var(--text-secondary); font-size: 12px; flex-shrink: 0; }
.prog-bar-track {
    flex: 1;
    height: 22px;
    background: var(--bg);
    border-radius: 4px;
    position: relative;
    overflow: hidden;
    min-width: 80px;
}
.prog-bar-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.3s;
}
.prog-bar-score {
    min-width: 60px;
    text-align: right;
    font-weight: 700;
    flex-shrink: 0;
    font-family: var(--font-display);
}
.prog-bar-place {
    min-width: 32px;
    text-align: right;
    font-size: 12px;
    color: var(--text-secondary);
    flex-shrink: 0;
}
.prog-bar-best .prog-bar-score { color: var(--club); }
.prog-bar-name {
    position: absolute;
    left: 6px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 11px;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: calc(100% - 12px);
    pointer-events: none;
}

/* Tooltip pour le graphe */
.prog-tooltip {
    position: absolute;
    background: var(--text);
    color: white;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 12px;
    pointer-events: none;
    white-space: nowrap;
    z-index: 10;
    transform: translate(-50%, -100%);
    margin-top: -8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}
.prog-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: var(--text);
}

/* Import feuille de marque */
.import-zone {
    text-align: center;
    padding: 2rem;
    border: 2px dashed var(--border-strong);
    border-radius: var(--radius-lg);
    background: var(--surface-2);
    transition: border-color 0.2s, background 0.15s;
}
.import-zone:hover { border-color: var(--club); background: var(--club-light); }
.import-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    color: var(--text-secondary);
    font-size: 14px;
}
.spinner {
    width: 24px;
    height: 24px;
    border: 3px solid var(--border);
    border-top-color: var(--club);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

@media (max-width: 600px) {
    .evt-card { flex-wrap: wrap; }
    .evt-actions { flex-direction: row; width: 100%; justify-content: flex-end; }
    .cal-cell { min-height: 50px; padding: 2px; }
    .cal-evt { font-size: 9px; }
    .famille-banner { flex-direction: column; align-items: flex-start; margin: -16px -16px 16px; }
    .prog-bar-name { display: none; }
    .prog-stats { grid-template-columns: repeat(2, 1fr); }
}

/* ==============================
   DESKTOP LAYOUT (≥768px)
   ============================== */
@media (min-width: 768px) {
    .app {
        max-width: 1200px;
        margin: 0 auto;
        border-radius: 0;
        min-height: 100vh;
    }
    .topbar-licence-icon { display: none; }
    .topbar-licence-btn { display: inline-flex; }
    .topbar-avatar-name { display: inline; }
    .topbar-avatar-caret { display: inline; }
    .topbar-espace-user { display: inline; }
    .main-nav { display: block; }
    .espace-nav { display: flex; }
    .bottom-bar { display: none; }
    .bottom-sheet-overlay { display: none !important; }
    .fab-saisir { display: none; }
    .content { padding: 28px 36px; }
    .famille-banner { margin: -28px -36px 24px; }
}

/* ==============================
   BOTTOM BAR (mobile)
   ============================== */
.bottom-bar {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--surface);
    border-top: 1px solid var(--border);
    z-index: 100;
    padding: 4px 0;
    padding-bottom: env(safe-area-inset-bottom, 0);
}
.bottom-tab {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 6px 4px;
    font-size: 10px;
    font-weight: 500;
    color: var(--text-muted);
    text-decoration: none;
    border: none;
    background: none;
    cursor: pointer;
    font-family: var(--font-body);
    min-height: 52px;
    justify-content: center;
    transition: color 0.2s;
    -webkit-tap-highlight-color: transparent;
}
.bottom-tab:hover { text-decoration: none; }
.bottom-tab.active { color: var(--club); font-weight: 600; }
.bottom-icon {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
}
.bottom-bar-espace .bottom-tab.active { font-weight: 600; }
.bottom-bar-entraineur { border-top-color: var(--espace-entraineur); }
.bottom-bar-entraineur .bottom-tab.active { color: var(--espace-entraineur); }
.bottom-bar-admin { border-top-color: var(--espace-admin); }
.bottom-bar-admin .bottom-tab.active { color: var(--espace-admin); }
.bottom-bar-bureau { border-top-color: var(--espace-bureau); }
.bottom-bar-bureau .bottom-tab.active { color: var(--espace-bureau); }

/* ==============================
   BOTTOM SHEET (mobile "Plus")
   ============================== */
.bottom-sheet-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 150;
}
.bottom-sheet-overlay.open { display: block; }
.bottom-sheet-bg {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.3);
    backdrop-filter: blur(2px);
}
.bottom-sheet-panel {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--surface);
    border-radius: 16px 16px 0 0;
    padding: 12px 20px 24px;
    padding-bottom: calc(24px + env(safe-area-inset-bottom, 0));
    max-height: 60vh;
    overflow-y: auto;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.1);
}
.bottom-sheet-handle {
    width: 36px; height: 4px;
    background: var(--border-strong);
    border-radius: 2px;
    margin: 0 auto 16px;
}
.bottom-sheet-section-label {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin: 16px 0 8px;
}
.bottom-sheet-section-label:first-of-type { margin-top: 0; }
.bottom-sheet-links {
    display: flex;
    flex-direction: column;
}
.bottom-sheet-links a {
    display: block;
    padding: 12px 0;
    font-size: 15px;
    font-weight: 500;
    color: var(--text);
    text-decoration: none;
    border-bottom: 1px solid var(--border);
}
.bottom-sheet-links a:last-child { border-bottom: none; }
.bottom-sheet-links a:hover { text-decoration: none; }
.bottom-sheet-espace-entraineur { color: var(--espace-entraineur) !important; font-weight: 600 !important; }
.bottom-sheet-espace-admin { color: var(--espace-admin) !important; font-weight: 600 !important; }
.bottom-sheet-espace-bureau { color: var(--espace-bureau) !important; font-weight: 600 !important; }
.bottom-sheet-logout {
    display: block;
    padding: 12px 0;
    font-size: 14px;
    color: var(--danger);
    text-decoration: none;
    margin-top: 8px;
    border-top: 1px solid var(--border);
}

/* ==============================
   FAB (mobile saisir)
   ============================== */
.fab-saisir {
    display: flex;
    align-items: center;
    justify-content: center;
    position: fixed;
    bottom: calc(70px + env(safe-area-inset-bottom, 0));
    right: 16px;
    padding: 12px 20px;
    background: var(--club);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    font-family: var(--font-display);
    border-radius: 28px;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(123, 30, 86, 0.3);
    z-index: 110;
    transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
}
.fab-saisir:hover { background: var(--club-hover); text-decoration: none; transform: translateY(-2px); box-shadow: 0 6px 16px rgba(123, 30, 86, 0.35); }
.fab-saisir:active { transform: translateY(0); }

@media (min-width: 768px) {
    .bottom-bar, .bottom-sheet-overlay, .fab-saisir { display: none !important; }
}

/* Coach split layout */
.coach-split {
    display: flex;
    gap: 20px;
    overflow: hidden;
}
.coach-sidebar {
    width: 240px;
    flex-shrink: 0;
    align-self: flex-start;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
}
.coach-sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}
.coach-archers-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    padding: 10px;
    overflow-y: auto;
    flex: 1;
}
.coach-archer-card {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 10px 6px 8px;
    border-radius: var(--radius);
    border: 2px solid transparent;
    background: var(--surface);
    text-decoration: none;
    color: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
    cursor: pointer;
}
.coach-archer-check {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 16px;
    height: 16px;
    accent-color: var(--club);
    cursor: pointer;
    z-index: 2;
    margin: 0;
}
.coach-archer-card:hover {
    border-color: var(--club-light);
    box-shadow: var(--shadow-sm);
    text-decoration: none;
}
.coach-archer-card.active {
    border-color: var(--club);
    background: var(--club-light);
    box-shadow: 0 0 0 1px var(--club);
}
.coach-archer-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--club-light);
    color: var(--club);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    font-family: var(--font-display);
    margin-bottom: 6px;
    flex-shrink: 0;
}
.coach-archer-card.active .coach-archer-avatar {
    background: var(--club);
    color: #fff;
}
.coach-archer-name {
    font-size: 12px;
    line-height: 1.3;
    margin-bottom: 4px;
}
.coach-archer-name strong {
    font-weight: 700;
    font-family: var(--font-display);
}
.coach-archer-score {
    font-size: 18px;
    font-weight: 800;
    color: var(--club);
    font-family: var(--font-display);
    line-height: 1;
    margin-bottom: 2px;
}
.coach-archer-meta {
    font-size: 10px;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}
.coach-detail {
    flex: 1;
    min-width: 0;
    min-height: 0;
    overflow-y: auto;
    padding-right: 4px;
}

@media (min-width: 900px) {
    body.coach-view {
        overflow: hidden;
    }
    body.coach-view .app {
        height: 100vh;
        min-height: 0;
        margin: 0 auto;
        border-radius: 0;
        display: flex;
        flex-direction: column;
    }
    body.coach-view .content {
        flex: 1;
        min-height: 0;
        display: flex;
        flex-direction: column;
        overflow: hidden;
    }
    body.coach-view .coach-split {
        flex: 1;
        min-height: 0;
        height: auto;
    }
}

@media (max-width: 899px) {
    body.coach-view { overflow: auto; }
    .coach-view .app { height: auto; overflow: visible; }
    .coach-view .content { overflow: visible; }
    .coach-split {
        flex-direction: column;
        height: auto !important;
        overflow: visible;
    }
    .coach-sidebar {
        width: 100%;
    }
    .coach-archers-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    }
    .coach-detail {
        overflow-y: visible;
        padding-right: 0;
    }
}

/* Performances (page combinée) */
.perf-section {
    background: var(--surface);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-sm);
}
.perf-section .section-header { margin-bottom: 1rem; }
.perf-section .section-titre { font-size: 1.15rem; }
.perf-section .section { margin-bottom: 1.5rem; }
.form-inline { display: flex; gap: 8px; align-items: center; }
@media (max-width: 767px) {
    .perf-section { padding: 1rem; margin-bottom: 1rem; border-radius: var(--radius); }
}

/* ==============================
   SAISIE IMPACTS (blason)
   ============================== */
.impacts-setup {
    background: var(--surface);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
}
.impacts-field { margin-bottom: 1rem; }
.impacts-field label {
    display: block;
    font-weight: 600;
    font-size: .9rem;
    margin-bottom: 6px;
    color: var(--text);
}
.impacts-toggle {
    display: flex;
    gap: 0;
    border-radius: var(--radius);
    overflow: hidden;
    border: 1.5px solid var(--border-strong);
}
.impacts-toggle button {
    flex: 1;
    padding: 10px 16px;
    border: none;
    background: var(--surface);
    color: var(--text-secondary);
    font-family: var(--font-body);
    font-size: .9rem;
    font-weight: 500;
    cursor: pointer;
    transition: background .2s, color .2s;
}
.impacts-toggle button.on {
    background: var(--club);
    color: #fff;
    font-weight: 600;
}
.impacts-toggle button:not(.on):hover {
    background: var(--club-light);
    color: var(--club);
}
.impacts-info-box {
    background: var(--club-light);
    color: var(--club-dark);
    border-radius: var(--radius);
    padding: 10px 14px;
    font-size: .88rem;
    line-height: 1.5;
}
.impacts-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--club);
    color: #fff;
    padding: 12px 16px;
    border-radius: var(--radius-lg);
    margin-bottom: 12px;
}
.impacts-bar-title { font-weight: 700; font-size: 1.05rem; }
.impacts-bar-sub { font-size: .82rem; opacity: .85; }
.impacts-bar-score { font-size: 1.6rem; font-weight: 800; font-variant-numeric: tabular-nums; }

.impacts-target-wrap {
    position: relative;
    background: var(--surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: 8px;
    margin-bottom: 12px;
}
.impacts-svg {
    display: block;
    width: 100%;
    max-width: 420px;
    margin: 0 auto;
    cursor: crosshair;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
}
.impacts-hint {
    text-align: center;
    font-size: .82rem;
    color: var(--text-muted);
    padding: 6px 0 2px;
}
.impacts-hint-text {
    color: var(--text-muted);
    font-size: .85rem;
    font-style: italic;
}

.impacts-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 8px 0 12px;
    min-height: 38px;
    align-items: center;
}
.impacts-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: .82rem;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    line-height: 1;
}
.impacts-pill-num {
    font-size: .7rem;
    opacity: .7;
    font-weight: 400;
}
.impacts-pill-gold { background: #FFC90E; color: #5a3e00; }
.impacts-pill-red { background: #ED1C24; color: #fff; }
.impacts-pill-blue { background: #00A2E8; color: #fff; }
.impacts-pill-dark { background: #2a2a2a; color: #fff; }
.impacts-pill-light { background: #e8e8e8; color: #333; }

.impacts-actions {
    display: flex;
    gap: 10px;
    padding: 4px 0;
}
.impacts-actions .btn { flex: 1; text-align: center; }

.impacts-icon-undo {
    display: inline-block;
    width: 14px;
    height: 14px;
    vertical-align: -2px;
    margin-right: 2px;
    background: currentColor;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 7v6h6'/%3E%3Cpath d='M21 17a9 9 0 00-9-9 9 9 0 00-6 2.3L3 13'/%3E%3C/svg%3E") no-repeat center;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 7v6h6'/%3E%3Cpath d='M21 17a9 9 0 00-9-9 9 9 0 00-6 2.3L3 13'/%3E%3C/svg%3E") no-repeat center;
}

.impacts-summary-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    padding: 1.5rem;
    text-align: center;
    margin-bottom: 12px;
}
.impacts-summary-title {
    font-size: .9rem;
    color: var(--text-secondary);
    margin-bottom: 6px;
}
.impacts-summary-score {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--club);
    font-variant-numeric: tabular-nums;
}
.impacts-summary-detail {
    font-size: .85rem;
    color: var(--text-muted);
    margin: 6px 0 12px;
}

.impacts-session-line {
    text-align: center;
    font-size: .85rem;
    color: var(--text-secondary);
    padding: 8px 0 12px;
    font-variant-numeric: tabular-nums;
}

.impacts-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    padding: 8px 0;
}
.impacts-legend-item {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: .82rem;
    color: var(--text-secondary);
    font-variant-numeric: tabular-nums;
}
.impacts-legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
}

.impacts-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 10px;
    margin: 12px 0 16px;
}
.impacts-stat {
    background: var(--surface);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    padding: 14px 10px;
    text-align: center;
}
.impacts-stat-val {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--club);
    font-variant-numeric: tabular-nums;
}
.impacts-stat-lbl {
    font-size: .75rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.impacts-spot-tabs {
    display: flex;
    gap: 6px;
    margin-bottom: 10px;
}
.impacts-spot-tab {
    flex: 1;
    padding: 10px 8px;
    border: 1.5px solid var(--border-strong);
    border-radius: var(--radius);
    background: var(--surface);
    color: var(--text-secondary);
    font-family: var(--font-body);
    font-size: .88rem;
    font-weight: 500;
    cursor: pointer;
    text-align: center;
    transition: background .2s, color .2s, border-color .2s;
}
.impacts-spot-tab.on {
    background: var(--club);
    color: #fff;
    border-color: var(--club);
    font-weight: 600;
}
.impacts-spot-tab:not(.on):hover {
    background: var(--club-light);
    border-color: var(--club-subtle);
    color: var(--club);
}
.impacts-spot-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    border-radius: 9px;
    background: rgba(255,255,255,.25);
    font-size: .72rem;
    font-weight: 700;
    margin-left: 4px;
    padding: 0 4px;
}
.impacts-spot-tab:not(.on) .impacts-spot-count {
    background: var(--club-light);
    color: var(--club);
}

@media (max-width: 767px) {
    .impacts-setup { padding: 1rem; }
    .impacts-bar { padding: 10px 12px; border-radius: var(--radius); }
    .impacts-target-wrap { padding: 4px; border-radius: var(--radius); }
    .impacts-summary-card { padding: 1rem; }
    .impacts-stats { grid-template-columns: repeat(2, 1fr); }
}

/* ===== Phase 3 : Suivi coach côté archer ===== */

/* Badge cloche coach dans la topbar */
.coach-bell {
    position: relative;
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
    margin-right: 10px;
}
.coach-bell { font-size: 1.15rem; line-height: 1; }
.coach-bell.has-unread {
    animation: coach-wobble 2s ease-in-out infinite;
}
@keyframes coach-wobble {
    0%, 100% { transform: rotate(0deg) scale(1); }
    10% { transform: rotate(-12deg) scale(1.1); }
    20% { transform: rotate(10deg) scale(1.1); }
    30% { transform: rotate(-8deg) scale(1.05); }
    40% { transform: rotate(6deg) scale(1.05); }
    50% { transform: rotate(0deg) scale(1); }
}
.coach-bell:hover svg { opacity: 1; }
.coach-bell-badge {
    position: absolute;
    top: -6px;
    right: -10px;
    background: #E53935;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    min-width: 18px;
    height: 18px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 5px;
    box-shadow: 0 0 0 2px var(--surface);
    animation: coach-pulse 2s ease-in-out infinite;
}
@keyframes coach-pulse {
    0%, 100% { box-shadow: 0 0 0 2px var(--surface); }
    50% { box-shadow: 0 0 0 2px var(--surface), 0 0 0 6px rgba(229, 57, 53, 0.3); }
}

/* Point rouge sur l'icône bottom-bar */
.bottom-tab-icon-wrap {
    position: relative;
    display: inline-flex;
}
.bottom-tab-dot {
    position: absolute;
    top: -2px;
    right: -4px;
    width: 8px;
    height: 8px;
    background: #c0392b;
    border-radius: 50%;
    border: 2px solid var(--surface);
}

/* Badge compteur dans le popover */
.popover-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    background: #E53935;
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    border-radius: 10px;
    margin-left: 8px;
}

/* Layout split entraînements (desktop) */
.entrainements-layout {
    display: block;
}
.entrainements-layout.has-suivi {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 24px;
    align-items: start;
}

/* Panneau suivi coach (sidebar desktop) */
.entrainements-suivi-panel {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px;
    position: sticky;
    top: 16px;
}
.suivi-coach-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}
.suivi-coach-panel-header h2 {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}
.suivi-coach-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    background: var(--club);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    border-radius: 10px;
}
.suivi-coach-voir-tout {
    font-size: 0.8rem;
    color: var(--club);
    text-decoration: none;
    font-weight: 500;
    white-space: nowrap;
}
.suivi-coach-voir-tout:hover { text-decoration: underline; }
.suivi-coach-vide {
    color: var(--text-muted);
    font-size: 0.9rem;
    text-align: center;
    padding: 16px 0;
}

/* Fil de messages coach */
.suivi-coach-fil {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.suivi-coach-fil-compact .suivi-coach-msg {
    padding: 10px;
}
.suivi-coach-msg {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 14px;
    transition: border-color 0.2s;
}
.suivi-coach-msg.non-lu {
    border-left: 3px solid var(--club);
    background: #fdf6f9;
}
.suivi-coach-msg-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}
.suivi-coach-badge {
    font-family: var(--font-display);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    padding: 2px 8px;
    border-radius: 4px;
    text-transform: uppercase;
}
.suivi-coach-badge-consigne {
    background: var(--club);
    color: #fff;
}
.suivi-coach-badge-objectif {
    background: var(--gold);
    color: #fff;
}
.suivi-coach-date {
    font-size: 0.8rem;
    color: var(--text-muted);
}
.suivi-coach-dot-new {
    width: 8px;
    height: 8px;
    background: var(--club);
    border-radius: 50%;
    flex-shrink: 0;
}
.suivi-coach-coach {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 500;
    margin-bottom: 4px;
}
.suivi-coach-contenu {
    font-size: 0.9rem;
    line-height: 1.5;
    color: var(--text-primary);
}
.suivi-coach-plus {
    display: block;
    text-align: center;
    font-size: 0.85rem;
    color: var(--club);
    text-decoration: none;
    font-weight: 500;
    margin-top: 8px;
    padding: 8px;
}
.suivi-coach-plus:hover { text-decoration: underline; }

/* Mobile : suivi panel passe sous les séances */
@media (max-width: 899px) {
    .entrainements-layout.has-suivi {
        grid-template-columns: 1fr;
    }
    .entrainements-suivi-panel {
        display: none;
    }
}

/* --- Widget objectif score --- */
.objectif-widget { margin-top: 8px; padding: 6px 10px; background: var(--surface-alt, #f8f5f0); border-radius: 8px; border: 1px dashed var(--gold); }
.objectif-display, .objectif-form { display: flex; align-items: center; gap: 6px; }
.objectif-icon { font-size: 14px; }
.objectif-label { font-size: 12px; color: var(--text-secondary); white-space: nowrap; }
.objectif-value { font-size: 13px; font-weight: 600; color: var(--gold); font-family: 'Barlow', sans-serif; }
.objectif-edit-btn { background: none; border: none; cursor: pointer; font-size: 12px; padding: 2px 4px; opacity: 0.5; transition: opacity 0.2s; }
.objectif-edit-btn:hover { opacity: 1; }
.objectif-input { width: 70px; padding: 3px 6px; border: 1px solid var(--border); border-radius: 6px; font-size: 13px; font-family: 'Barlow', sans-serif; text-align: center; background: var(--surface); color: var(--text); }
.objectif-input:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 2px rgba(196,149,46,0.15); }
.objectif-save-btn { background: var(--gold); color: #fff; border: none; border-radius: 6px; padding: 3px 10px; font-size: 12px; font-weight: 600; cursor: pointer; transition: background 0.2s; }
.objectif-save-btn:hover { background: #b08528; }
.objectif-cancel-btn { background: none; border: none; cursor: pointer; font-size: 14px; color: var(--text-muted); padding: 2px 4px; }
.objectif-cancel-btn:hover { color: var(--text); }

/* ══════════════════════════════════════
   DARK MODE — Component overrides
   ══════════════════════════════════════ */

/* Mixin: we use a helper that targets both auto-dark and manual-dark */

/* --- Badges disciplines --- */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .badge-salle,
  :root:not([data-theme="light"]) .badge-comp-salle,
  :root:not([data-theme="light"]) .badge-lieu-int,
  :root:not([data-theme="light"]) .badge-cl { background: rgba(59,130,246,0.2); color: #93B5FF; }

  :root:not([data-theme="light"]) .badge-ext,
  :root:not([data-theme="light"]) .badge-comp-exterieur,
  :root:not([data-theme="light"]) .badge-lieu-ext { background: rgba(34,197,94,0.2); color: #86EFAC; }

  :root:not([data-theme="light"]) .badge-3d,
  :root:not([data-theme="light"]) .badge-comp-3d,
  :root:not([data-theme="light"]) .badge-co { background: rgba(251,146,60,0.2); color: #FDBA74; }

  :root:not([data-theme="light"]) .badge-bb { background: rgba(168,85,247,0.2); color: #C4B5FD; }

  :root:not([data-theme="light"]) .badge-comp-jeunes { background: rgba(234,179,8,0.15); color: #FDE047; }

  /* Icon backgrounds */
  :root:not([data-theme="light"]) .icon-compet { background: rgba(59,130,246,0.15); }
  :root:not([data-theme="light"]) .icon-entrain { background: rgba(34,197,94,0.12); }
  :root:not([data-theme="light"]) .activity-icon.entr { background: var(--surface-2); }

  /* Status badges */
  :root:not([data-theme="light"]) .status-interested { background: rgba(234,179,8,0.15); color: #FDE047; }

  /* Projection pills */
  :root:not([data-theme="light"]) .projection-pill.high,
  :root:not([data-theme="light"]) .alc-projection.high { background: rgba(34,197,94,0.15); color: #86EFAC; }
  :root:not([data-theme="light"]) .projection-pill.low,
  :root:not([data-theme="light"]) .alc-projection.low { background: rgba(239,68,68,0.15); color: #FCA5A5; }
  :root:not([data-theme="light"]) .projection-pill.mid { background: rgba(255,255,255,0.06); }

  /* Classement type buttons */
  :root:not([data-theme="light"]) .cl-type-btn.active-salle { background: #1E40AF; color: #fff; }
  :root:not([data-theme="light"]) .cl-type-btn.active-ext { background: #166534; color: #fff; }
  :root:not([data-theme="light"]) .cl-comp-type-badge.salle { background: rgba(30,64,175,0.3); color: #93B5FF; }
  :root:not([data-theme="light"]) .cl-comp-type-badge.ext { background: rgba(22,101,52,0.3); color: #86EFAC; }

  /* Mon-evt badge hover */
  :root:not([data-theme="light"]) .mon-evt-badge:hover { background: var(--surface-2); }

  /* Espace buttons hover */
  :root:not([data-theme="light"]) .espace-btn-entraineur:hover { background: var(--espace-entraineur-light, #142a2e); }
  :root:not([data-theme="light"]) .espace-btn-admin:hover { background: var(--espace-admin-light, #2a2518); }
  :root:not([data-theme="light"]) .espace-btn-bureau:hover { background: var(--espace-bureau-light, #2a1522); }

  /* Form inputs */
  :root:not([data-theme="light"]) input,
  :root:not([data-theme="light"]) select,
  :root:not([data-theme="light"]) textarea {
    background: var(--surface-2); color: var(--text);
    border-color: var(--border);
  }
  :root:not([data-theme="light"]) input::placeholder { color: var(--text-muted); }

  /* Links in dark mode */
  :root:not([data-theme="light"]) a { color: var(--club-subtle, #c070a0); }

  /* Table striping */
  :root:not([data-theme="light"]) .grille-volees-table th { background: var(--club-light); color: #d090b8; }
}

/* Manual toggle: same overrides */
:root[data-theme="dark"] .badge-salle,
:root[data-theme="dark"] .badge-comp-salle,
:root[data-theme="dark"] .badge-lieu-int,
:root[data-theme="dark"] .badge-cl { background: rgba(59,130,246,0.2); color: #93B5FF; }

:root[data-theme="dark"] .badge-ext,
:root[data-theme="dark"] .badge-comp-exterieur,
:root[data-theme="dark"] .badge-lieu-ext { background: rgba(34,197,94,0.2); color: #86EFAC; }

:root[data-theme="dark"] .badge-3d,
:root[data-theme="dark"] .badge-comp-3d,
:root[data-theme="dark"] .badge-co { background: rgba(251,146,60,0.2); color: #FDBA74; }

:root[data-theme="dark"] .badge-bb { background: rgba(168,85,247,0.2); color: #C4B5FD; }

:root[data-theme="dark"] .badge-comp-jeunes { background: rgba(234,179,8,0.15); color: #FDE047; }

:root[data-theme="dark"] .icon-compet { background: rgba(59,130,246,0.15); }
:root[data-theme="dark"] .icon-entrain { background: rgba(34,197,94,0.12); }
:root[data-theme="dark"] .icon-fleches { background: rgba(196,149,46,0.15); }
:root[data-theme="dark"] .activity-icon.entr { background: var(--surface-2); }

:root[data-theme="dark"] .status-interested { background: rgba(234,179,8,0.15); color: #FDE047; }

:root[data-theme="dark"] .projection-pill.high,
:root[data-theme="dark"] .alc-projection.high { background: rgba(34,197,94,0.15); color: #86EFAC; }
:root[data-theme="dark"] .projection-pill.low,
:root[data-theme="dark"] .alc-projection.low { background: rgba(239,68,68,0.15); color: #FCA5A5; }
:root[data-theme="dark"] .projection-pill.mid { background: rgba(255,255,255,0.06); }

:root[data-theme="dark"] .cl-type-btn.active-salle { background: #1E40AF; color: #fff; }
:root[data-theme="dark"] .cl-type-btn.active-ext { background: #166534; color: #fff; }
:root[data-theme="dark"] .cl-comp-type-badge.salle { background: rgba(30,64,175,0.3); color: #93B5FF; }
:root[data-theme="dark"] .cl-comp-type-badge.ext { background: rgba(22,101,52,0.3); color: #86EFAC; }

:root[data-theme="dark"] .mon-evt-badge:hover { background: var(--surface-2); }

:root[data-theme="dark"] .espace-btn-entraineur:hover { background: #142a2e; }
:root[data-theme="dark"] .espace-btn-admin:hover { background: #2a2518; }

:root[data-theme="dark"] input,
:root[data-theme="dark"] select,
:root[data-theme="dark"] textarea {
  background: var(--surface-2); color: var(--text);
  border-color: var(--border);
}
:root[data-theme="dark"] input::placeholder { color: var(--text-muted); }

:root[data-theme="dark"] a { color: #c070a0; }

:root[data-theme="dark"] .grille-volees-table th { background: var(--club-light); color: #d090b8; }

/* ══════════════════════════════════════
   SAISIE ENTRAINEMENT — Pavé numérique
   ══════════════════════════════════════ */

/* Position indicator */
.saisie-position {
    display: flex; justify-content: center; gap: 24px;
    padding: 16px; margin-bottom: 12px;
    background: var(--surface); border-radius: var(--radius);
    border: 1px solid var(--border);
}
.saisie-pos-volee, .saisie-pos-fleche {
    font-family: var(--font-display); font-size: 18px; font-weight: 700;
    color: var(--text);
}
.saisie-pos-volee span:first-child, .saisie-pos-fleche span:first-child {
    color: var(--club); font-size: 22px;
}
.saisie-pos-sep { color: var(--text-muted); margin: 0 2px; font-weight: 400; }

.saisie-finished-msg {
    text-align: center; font-family: var(--font-display);
    font-size: 18px; color: var(--success);
}
.saisie-finished-msg strong { font-size: 24px; }

/* Score bar */
.saisie-scores-bar {
    display: flex; justify-content: space-around;
    padding: 10px 16px; margin-bottom: 12px;
    background: var(--club-light); border-radius: var(--radius-sm);
}
.saisie-score-volee, .saisie-score-total {
    text-align: center;
}
.saisie-score-label {
    display: block; font-size: 11px; text-transform: uppercase;
    color: var(--text-muted); font-family: var(--font-display);
    letter-spacing: 0.5px;
}
.saisie-score-val {
    font-family: var(--font-display); font-size: 28px;
    font-weight: 800; color: var(--club);
}
.saisie-score-total .saisie-score-val { color: var(--gold); }

/* Arrow pills */
.saisie-fleches-pills {
    display: flex; justify-content: center; gap: 8px;
    margin-bottom: 16px;
}
.saisie-pill {
    width: 42px; height: 42px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-family: var(--font-display); font-weight: 700; font-size: 15px;
    background: var(--surface-2); color: var(--text-muted);
    border: 2px solid var(--border);
    transition: all 0.15s;
}
.saisie-pill.current {
    border-color: var(--club); box-shadow: 0 0 0 3px rgba(123,30,86,0.15);
    color: var(--club); font-size: 16px;
    animation: pill-pulse 1.2s ease-in-out infinite;
}
@keyframes pill-pulse {
    0%, 100% { box-shadow: 0 0 0 3px rgba(123,30,86,0.15); }
    50% { box-shadow: 0 0 0 5px rgba(123,30,86,0.1); }
}
.saisie-pill.filled { border-color: transparent; color: #fff; }
.saisie-pill.pill-gold { background: #D4A028; }
.saisie-pill.pill-red { background: #C0392B; }
.saisie-pill.pill-blue { background: #2980B9; }
.saisie-pill.pill-black { background: #2C3E50; }
.saisie-pill.pill-miss { background: var(--text-muted); }

/* Keypad */
.saisie-keypad {
    display: grid; grid-template-columns: repeat(4, 1fr);
    gap: 8px; margin-bottom: 16px;
    max-width: 400px; margin-left: auto; margin-right: auto;
}
.kp-btn {
    padding: 16px 0; border-radius: var(--radius);
    font-family: var(--font-display); font-weight: 700; font-size: 20px;
    border: 1.5px solid var(--border); background: var(--surface);
    color: var(--text); cursor: pointer;
    transition: all 0.1s; -webkit-tap-highlight-color: transparent;
    user-select: none;
}
.kp-btn:active { transform: scale(0.93); }
.kp-10 { background: #FFF3CD; color: #856404; border-color: #F0D060; }
.kp-9 { background: #FFF8E1; color: #856404; border-color: #F0D060; }
.kp-m { background: var(--danger-bg); color: var(--danger); border-color: var(--danger); }

/* Dark overrides for keypad */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .kp-10 { background: rgba(212,160,40,0.2); color: #F0D060; border-color: rgba(212,160,40,0.4); }
  :root:not([data-theme="light"]) .kp-9 { background: rgba(212,160,40,0.12); color: #E8C840; border-color: rgba(212,160,40,0.3); }
  :root:not([data-theme="light"]) .kp-btn { background: var(--surface-2); color: var(--text); border-color: var(--border-strong); }
}
:root[data-theme="dark"] .kp-10 { background: rgba(212,160,40,0.2); color: #F0D060; border-color: rgba(212,160,40,0.4); }
:root[data-theme="dark"] .kp-9 { background: rgba(212,160,40,0.12); color: #E8C840; border-color: rgba(212,160,40,0.3); }
:root[data-theme="dark"] .kp-btn { background: var(--surface-2); color: var(--text); border-color: var(--border-strong); }

/* Quick actions */
.saisie-actions {
    display: flex; gap: 8px; margin-bottom: 16px;
    max-width: 400px; margin-left: auto; margin-right: auto;
}
.saisie-actions .btn { flex: 1; }

/* Recap details */
.saisie-recap-details {
    margin-bottom: 16px;
}
.saisie-recap-details summary {
    cursor: pointer; padding: 10px 14px;
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 13px; color: var(--text-secondary);
    font-family: var(--font-display); font-weight: 500;
}
.saisie-recap-details[open] summary { border-radius: var(--radius-sm) var(--radius-sm) 0 0; }

/* Recap cells coloring */
.recap-cell.pill-gold { color: #D4A028; font-weight: 600; }
.recap-cell.pill-red { color: #C0392B; font-weight: 600; }
.recap-cell.pill-blue { color: #2980B9; }
.recap-cell.pill-black { color: #555; }
.recap-cell.pill-miss { color: var(--text-muted); }
.recap-row-active { background: var(--club-light); }

/* Cumul column */
.volee-cumul { color: var(--text-secondary); font-size: 12px; }

/* Submit zone */
.saisie-submit-zone { margin-top: 8px; }

/* Mobile optimizations */
@media (max-width: 480px) {
    .saisie-position { padding: 12px; gap: 16px; }
    .saisie-pos-volee, .saisie-pos-fleche { font-size: 16px; }
    .saisie-pos-volee span:first-child, .saisie-pos-fleche span:first-child { font-size: 20px; }
    .kp-btn { padding: 14px 0; font-size: 18px; }
    .saisie-pill { width: 38px; height: 38px; font-size: 14px; }
    .saisie-keypad { gap: 6px; }
    .saisie-scores-bar { padding: 8px 12px; }
    .saisie-score-val { font-size: 24px; }
}

/* --- Bouton masquer consigne --- */
.btn-masquer-consigne {
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    margin-left: auto;
    color: var(--text-muted);
    opacity: 0.15;
    transition: opacity 0.2s, color 0.2s;
    border-radius: 4px;
    display: flex;
    align-items: center;
    flex-shrink: 0;
    position: relative;
    z-index: 2;
}
.btn-masquer-consigne svg {
    pointer-events: none;
}
.suivi-coach-msg:hover .btn-masquer-consigne {
    opacity: 0.6;
}
.btn-masquer-consigne:hover {
    opacity: 1 !important;
    color: var(--club);
    background: rgba(123, 30, 86, 0.08);
}
.suivi-coach-msg.masquee {
    opacity: 0.5;
}
.suivi-coach-msg.masquee .suivi-coach-contenu {
    font-style: italic;
    color: var(--text-muted);
}

/* Mobile: always show the button */
@media (max-width: 700px) {
    .btn-masquer-consigne {
        opacity: 0.6;
    }
}

/* --- Dashboard Suivi Coach strip --- */
.dash-coach-strip { margin-bottom: 10px; }
.dash-coach-strip .card { padding: 12px 16px; }
.dash-coach-badge {
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--club); color: #fff; font-size: 0.7rem; font-weight: 700;
  min-width: 18px; height: 18px; border-radius: 9px; padding: 0 5px;
  margin-left: 6px; vertical-align: middle;
}
.dash-coach-list { display: flex; flex-direction: column; gap: 0; }
.dash-coach-item {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 4px; border-bottom: 1px solid var(--border);
  text-decoration: none; color: var(--text); transition: background 0.15s;
  font-size: 0.85rem;
}
.dash-coach-item:last-child { border-bottom: none; }
.dash-coach-item:hover { background: rgba(123,30,86,0.04); }
.dash-coach-item.non-lu { font-weight: 600; }
.dash-coach-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--club); flex-shrink: 0;
}
.dash-coach-type {
  font-size: 0.7rem; font-weight: 600; padding: 2px 6px;
  border-radius: 4px; flex-shrink: 0; text-transform: uppercase; letter-spacing: 0.02em;
}
.dash-coach-type-consigne { background: rgba(123,30,86,0.12); color: var(--club); }
.dash-coach-type-feedback { background: rgba(46,125,50,0.12); color: #2E7D32; }
.dash-coach-type-objectif { background: rgba(196,149,46,0.15); color: #8B6914; }
.dash-coach-type-info { background: rgba(30,64,175,0.1); color: #1E40AF; }
.dash-coach-text {
  flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--text-secondary, var(--text));
}
.dash-coach-date {
  font-size: 0.75rem; color: var(--text-muted); flex-shrink: 0; font-variant-numeric: tabular-nums;
}
@media (max-width: 700px) {
  .dash-coach-item { font-size: 0.8rem; gap: 6px; padding: 7px 2px; }
}

/* --- Competition Live : améliorations mobile --- */
@media (max-width: 500px) {
    .cl-live-top-left { flex-wrap: wrap; gap: 6px; }
    .cl-live-page-title { font-size: 14px; max-width: 180px; }
    .cl-live-refresh-btn, .cl-live-end-btn { font-size: 9px; padding: 4px 8px; }
    .alc-header { gap: 6px; }
    .alc-rank { font-size: 16px; min-width: 18px; }
    .alc-avatar { width: 28px; height: 28px; font-size: 10px; }
    .alc-name { font-size: 13px; }
    .alc-projection { font-size: 14px; padding: 3px 8px; min-width: 40px; }
    .alc-stat-value { font-size: 13px; }
    .alc-serie-value { font-size: 14px; }
    .alc-volees { font-size: 9px; overflow-x: auto; white-space: nowrap; -webkit-overflow-scrolling: touch; }
    .alc-alert { font-size: 9px; padding: 5px 8px; }
    .cl-comp-info { flex-direction: column; gap: 4px; padding: 8px 12px; }
}

/* Auto-refresh spinner */
.cl-live-refresh-btn.refreshing {
    pointer-events: none; opacity: 0.6;
}
.cl-live-refresh-btn.refreshing::before {
    content: ''; display: inline-block; width: 10px; height: 10px;
    border: 2px solid var(--live-muted); border-top-color: transparent;
    border-radius: 50%; animation: spin-refresh 0.6s linear infinite;
    margin-right: 4px; vertical-align: middle;
}
@keyframes spin-refresh {
    to { transform: rotate(360deg); }
}

/* Sticky header en mode live mobile */
@media (max-width: 700px) {
    .cl-live-top-bar {
        position: sticky; top: 0; z-index: 50;
        background: var(--live-bg, #1a1625);
        border-bottom: 1px solid var(--live-border);
    }
}

/* --- Bannière compétition live en cours (tableau de bord) --- */
.live-banner {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    margin-bottom: 16px;
    background: linear-gradient(135deg, #7B1E56 0%, #5a1640 100%);
    border-radius: 12px;
    color: #fff;
    text-decoration: none;
    box-shadow: 0 4px 16px rgba(123,30,86,0.3);
    transition: transform 0.15s, box-shadow 0.15s;
    position: relative;
    overflow: hidden;
}
.live-banner:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 24px rgba(123,30,86,0.45);
}
.live-banner-pulse {
    width: 10px; height: 10px;
    background: #ef4444;
    border-radius: 50%;
    flex-shrink: 0;
    animation: banner-pulse 2s ease-in-out infinite;
}
@keyframes banner-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(239,68,68,0.6); }
    50% { box-shadow: 0 0 0 6px rgba(239,68,68,0); }
}
.live-banner-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
    min-width: 0;
}
.live-banner-content strong {
    font-family: 'Barlow', sans-serif;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0.02em;
}
.live-banner-detail {
    font-size: 13px;
    opacity: 0.85;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.live-banner-cta {
    flex-shrink: 0;
    font-size: 13px;
    font-weight: 600;
    background: rgba(255,255,255,0.15);
    padding: 6px 14px;
    border-radius: 8px;
    white-space: nowrap;
    transition: background 0.15s;
}
.live-banner:hover .live-banner-cta {
    background: rgba(255,255,255,0.25);
}
@media (max-width: 500px) {
    .live-banner {
        flex-wrap: wrap;
        padding: 12px 14px;
        gap: 8px;
    }
    .live-banner-cta {
        width: 100%;
        text-align: center;
        padding: 8px;
    }
}

/* ===== Mode coéquipier ===== */
.coequipier-toggle-section {
    margin-bottom: 0;
    padding: 12px 16px;
}
.coequipier-toggle {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    user-select: none;
}
.coequipier-toggle input[type="checkbox"] {
    display: none;
}
.coequipier-toggle-slider {
    position: relative;
    width: 44px;
    height: 24px;
    background: #ccc;
    border-radius: 12px;
    transition: background 0.2s;
    flex-shrink: 0;
}
.coequipier-toggle-slider::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.2s;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
.coequipier-toggle input:checked + .coequipier-toggle-slider {
    background: var(--bordeaux, #7B1E56);
}
.coequipier-toggle input:checked + .coequipier-toggle-slider::after {
    transform: translateX(20px);
}
.coequipier-toggle-label {
    font-family: 'Barlow', sans-serif;
    font-size: 15px;
    font-weight: 600;
    color: #e8e8f0;
}
.coequipier-match-section {
    padding: 0 16px 16px;
}
.coequipier-found {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #f0fdf4;
    border: 1px solid #86efac;
    border-radius: 10px;
    padding: 12px 16px;
}
.coequipier-found-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #22c55e;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 700;
    flex-shrink: 0;
}
.coequipier-found-info {
    flex: 1;
    min-width: 0;
}
.coequipier-found-name {
    font-family: 'Barlow', sans-serif;
    font-size: 16px;
    font-weight: 700;
    color: #15803d;
}
.coequipier-found-detail {
    font-size: 13px;
    color: #4b5563;
    margin-top: 2px;
}
.coequipier-notfound {
    background: #fffbeb;
    border: 1px solid #fcd34d;
    border-radius: 10px;
    padding: 14px 16px;
}
.coequipier-notfound-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #f59e0b;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    margin-right: 8px;
    vertical-align: middle;
}
.coequipier-notfound-label {
    font-size: 14px;
    color: #92400e;
    line-height: 28px;
}
@media (max-width: 500px) {
    .coequipier-found {
        flex-wrap: wrap;
        gap: 8px;
    }
    .coequipier-found .btn {
        width: 100%;
        text-align: center;
    }
}
