/* RCFedg — charte Racing Club de France La Boulie (ciel & blanc) */

:root {
  --ciel: #7eb6e0;
  --ciel-soft: #b7d4ee;
  --ciel-deep: #4a90c8;
  --navy: #1a3a5c;
  --bg: #ffffff;
  --bg-2: #ffffff;
  --panel: #ffffff;
  --line: #c5daf0;
  --text: #1a3a5c;
  --muted: #5a7a9a;
  --accent: var(--ciel);
  --accent-2: var(--ciel-deep);
  --danger: #c94b4b;
  --ok: #2f8f5b;
  --radius: 14px;
  --font: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --shadow: 0 12px 40px rgba(26, 58, 92, 0.08);
  --stripe: 110px;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  color: var(--text);
  font-family: var(--sans);
  background-color: #fff;
  background-image:
    url("/img/rcf-la-boulie.png"),
    repeating-linear-gradient(
      180deg,
      rgba(126, 182, 224, 0.30) 0 var(--stripe),
      rgba(255, 255, 255, 0.96) var(--stripe) calc(var(--stripe) * 2)
    );
  background-repeat: no-repeat, repeat;
  background-position: center 42%, 0 0;
  background-size: min(440px, 72vw) auto, 100% calc(var(--stripe) * 2);
  background-attachment: fixed, fixed;
  min-height: 100vh;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: radial-gradient(circle at center, rgba(255,255,255,0.42) 0%, rgba(255,255,255,0.78) 52%, rgba(255,255,255,0.9) 100%);
}

#view-login,
#view-admin,
#view-parent,
#view-coach,
#view-player,
.login-wrap {
  position: relative;
  z-index: 1;
}

a { color: var(--ciel-deep); }
button, input, select, textarea { font: inherit; }

.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.5rem;
  border-bottom: 3px solid var(--ciel);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 10;
  box-shadow: var(--shadow);
}

.header-search {
  position: relative;
  flex: 1 1 14rem;
  min-width: 11rem;
  max-width: 22rem;
}

.header-search input[type="search"] {
  width: 100%;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: 999px;
  padding: 0.5rem 0.95rem;
  min-height: 2.4rem;
  box-shadow: 0 1px 2px rgba(26, 58, 92, 0.04);
}

.header-search input[type="search"]:focus {
  outline: 2px solid rgba(126, 182, 224, 0.45);
  border-color: var(--ciel);
}

.header-search-results {
  position: absolute;
  top: calc(100% + 0.35rem);
  left: 0;
  right: 0;
  margin: 0;
  padding: 0.35rem;
  list-style: none;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 16px 40px rgba(26, 58, 92, 0.14);
  max-height: min(22rem, 70vh);
  overflow: auto;
  z-index: 40;
}

.header-search-results li {
  margin: 0;
}

.header-search-results button {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.15rem;
  text-align: left;
  background: transparent;
  border: none;
  border-radius: 8px;
  padding: 0.55rem 0.65rem;
  cursor: pointer;
  color: var(--text);
  font: inherit;
}

.header-search-results button:hover,
.header-search-results button.is-active {
  background: #eaf3fb;
}

.header-search-results .hs-name {
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.header-search-results .hs-meta {
  font-size: 0.78rem;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.header-search-results .hs-empty,
.header-search-results .hs-loading {
  padding: 0.7rem 0.75rem;
  color: var(--muted);
  font-size: 0.88rem;
}

@keyframes search-hit-flash {
  0%, 100% { background: transparent; }
  30%, 70% { background: #eaf3fb; }
}

.search-hit-flash {
  animation: search-hit-flash 1.4s ease;
  border-radius: 10px;
}

@media (max-width: 900px) {
  .app-header {
    flex-wrap: wrap;
  }
  .header-search {
    order: 3;
    flex: 1 1 100%;
    max-width: none;
  }
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-family: var(--font);
  font-size: 1.25rem;
  letter-spacing: 0.02em;
  color: var(--navy);
  text-decoration: none;
}
.brand img,
.brand-logo {
  width: 48px;
  height: 48px;
  object-fit: contain;
  flex-shrink: 0;
  display: block;
}
.brand span {
  color: var(--navy);
  font-weight: 600;
  font-size: 0.95rem;
  line-height: 1.25;
  max-width: 14rem;
}

.hero-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
}
.hero-brand img {
  width: 56px;
  height: 56px;
  object-fit: contain;
}

.nav { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.nav button {
  background: transparent;
  border: 1px solid transparent;
  color: var(--muted);
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  cursor: pointer;
}
.nav button.active, .nav button:hover {
  color: var(--navy);
  border-color: var(--line);
  background: #eaf3fb;
}

.user-chip {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--muted);
  font-size: 0.9rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.btn-space-switch {
  border-color: var(--ciel-deep) !important;
  color: var(--ciel-deep) !important;
  font-weight: 600;
}

.cgu-block {
  margin: 1rem 0;
}
.cgu-block-title {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
}
.cgu-scroll {
  max-height: 220px;
  overflow-y: auto;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.75rem 0.9rem;
  background: #f7fbff;
  margin: 0.5rem 0 0.75rem;
  font-size: 0.86rem;
  line-height: 1.45;
  color: var(--text);
}
.cgu-scroll h3 {
  font-size: 0.92rem;
  margin: 0.75rem 0 0.35rem;
}
.cgu-scroll h3:first-child { margin-top: 0; }
.cgu-check {
  align-items: flex-start;
  gap: 0.55rem;
}
.cgu-article {
  font-size: 0.95rem;
  line-height: 1.5;
}
.cgu-article h3 {
  margin: 1.25rem 0 0.4rem;
}

.image-rights-card {
  width: min(520px, 100%);
  max-height: min(90vh, 720px);
  overflow-y: auto;
}
.ir-recap {
  padding: 0.75rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #f7fbff;
}
.badge.danger {
  background: #fde8e8;
  color: #9b1c1c;
  border-color: #f5c2c2;
}
.badge.ok-soft {
  background: #e7f8ee;
  color: #0f6b38;
}
.medical-block {
  margin-top: 0.75rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(126, 182, 224, 0.08);
}
.medical-block-inner p { font-size: 0.95rem; }
.nested-panel {
  box-shadow: none;
  border: 1px solid var(--line);
}

.app-footer {
  text-align: center;
  padding: 1rem 1.5rem 1.5rem;
  color: var(--muted);
  font-size: 0.85rem;
}
.app-footer a { color: var(--ciel-deep); }

.layout-admin {
  max-width: 1180px;
  padding: 0;
}

.admin-zone {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
  min-height: calc(100vh - 5.5rem);
  align-items: start;
}

.admin-zone.hidden {
  display: none;
}

.admin-side-nav {
  position: sticky;
  top: 5.25rem;
  align-self: start;
  padding: 1.25rem 0.85rem 1.5rem 1.25rem;
  border-right: 1px solid var(--line);
  background: rgba(247, 251, 255, 0.92);
  min-height: calc(100vh - 5.5rem);
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.admin-side-title {
  margin: 0 0 0.55rem;
  padding: 0 0.65rem;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
}

.admin-side-title-spaced {
  margin-top: 1.15rem;
}

.admin-side-nav button {
  text-align: left;
  background: transparent;
  border: 1px solid transparent;
  color: var(--muted);
  padding: 0.55rem 0.75rem;
  border-radius: 10px;
  cursor: pointer;
  font: inherit;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  width: 100%;
}

.side-nav-count {
  flex-shrink: 0;
  min-width: 1.35rem;
  padding: 0.1rem 0.4rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  background: rgba(201, 75, 75, 0.14);
  color: var(--danger);
  border: 1px solid rgba(201, 75, 75, 0.35);
}

.side-nav-count.hidden {
  display: none !important;
}

.admin-alert {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  border: 1px solid rgba(212, 160, 23, 0.45);
  background: rgba(212, 160, 23, 0.12);
}

.admin-alert.hidden {
  display: none !important;
}

.admin-todo-list li {
  align-items: center;
}

.volunteer-section-title {
  margin: 1rem 0 0.4rem;
  font-size: 0.95rem;
}

.volunteer-section-title:first-of-type {
  margin-top: 0.35rem;
}

.volunteer-paths {
  gap: 1rem;
}

.admin-side-nav button.active,
.admin-side-nav button:hover {
  color: var(--navy);
  background: #fff;
  border-color: var(--line);
  box-shadow: var(--shadow);
}

.side-nav-group {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.side-nav-toggle .side-nav-chevron {
  flex-shrink: 0;
  font-size: 0.75rem;
  color: var(--muted);
  transition: transform 0.15s ease;
}

.side-nav-group.is-open > .side-nav-toggle .side-nav-chevron {
  transform: rotate(180deg);
}

.side-nav-group.is-open > .side-nav-toggle {
  color: var(--navy);
  background: #fff;
  border-color: var(--line);
}

.side-nav-sub {
  display: none;
  flex-direction: column;
  gap: 0.1rem;
  margin: 0.1rem 0 0.2rem 0.4rem;
  padding-left: 0.55rem;
  border-left: 2px solid rgba(30, 64, 100, 0.12);
}

.side-nav-group.is-open > .side-nav-sub {
  display: flex;
}

.side-nav-sub[hidden] {
  display: none !important;
}

.side-nav-sub button {
  font-size: 0.88rem;
  padding: 0.45rem 0.65rem;
}

@media (max-width: 960px) {
  .side-nav-group {
    flex: 1 1 100%;
  }
  .side-nav-sub {
    flex-direction: row;
    flex-wrap: wrap;
    margin-left: 0;
    padding-left: 0;
    border-left: none;
    gap: 0.25rem;
  }
}

.admin-side-content {
  padding: 1.5rem;
  min-width: 0;
}

.admin-detail-host {
  padding: 1.5rem;
  max-width: 1180px;
  margin: 0 auto;
}

.admin-detail-host.hidden {
  display: none;
}

.admin-zone.is-detail .admin-side-nav {
  opacity: 0.85;
}

.players-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.7rem 0.85rem;
  margin-top: 1rem;
  padding: 0.85rem 1rem;
  background: linear-gradient(180deg, #fafcfe 0%, #f2f7fc 100%);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.players-filters .field {
  margin-bottom: 0;
  flex: 0 0 auto;
  min-width: 0;
}

.players-filters .field--search {
  flex: 1 1 14rem;
  min-width: min(100%, 12rem);
}

.players-filters .field--actions {
  flex: 0 0 auto;
  padding-bottom: 1px;
}

.players-filters .field label {
  white-space: nowrap;
  margin-bottom: 0.3rem;
  letter-spacing: 0.03em;
}

.players-filters .field input,
.players-filters .field select {
  background: #fff;
  white-space: nowrap;
  min-height: 2.55rem;
  padding: 0.55rem 0.8rem;
  box-shadow: 0 1px 2px rgba(26, 58, 92, 0.04);
}

.players-filters .field--search input {
  width: 100%;
}

.players-filters .field select {
  width: max-content;
  min-width: 9.75rem;
  max-width: min(100%, 20rem);
  padding-right: 1.85rem;
}

.players-filters .field--actions .btn {
  min-height: 2.55rem;
  white-space: nowrap;
}

@media (max-width: 960px) {
  .admin-zone {
    grid-template-columns: 1fr;
  }
  .admin-side-nav {
    position: static;
    min-height: 0;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    border-right: none;
    border-bottom: 1px solid var(--line);
    padding: 0.85rem 1rem;
  }
  .admin-side-title {
    width: 100%;
    margin-bottom: 0.25rem;
  }
}

@media (max-width: 560px) {
  .players-filters .field,
  .players-filters .field--search,
  .players-filters .field--actions {
    flex: 1 1 100%;
  }
  .players-filters .field select {
    width: 100%;
    max-width: none;
  }
}

.panel {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid var(--line);
  border-top: 4px solid var(--ciel);
  border-radius: var(--radius);
  padding: 1.25rem 1.4rem;
  box-shadow: var(--shadow);
}

h1, h2, h3 { font-family: var(--font); font-weight: 600; margin: 0 0 0.75rem; color: var(--navy); }
h1 { font-size: 1.8rem; }
h2 { font-size: 1.35rem; }
p.lead { color: var(--muted); margin-top: 0; line-height: 1.45; }

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
@media (max-width: 760px) {
  .grid-2 { grid-template-columns: 1fr; }
  .app-header { flex-direction: column; align-items: flex-start; }
}

.field { margin-bottom: 0.9rem; }
.field label {
  display: block;
  font-size: 0.8rem;
  color: var(--muted);
  margin-bottom: 0.35rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.field input, .field select, .field textarea {
  width: 100%;
  background: #f7fbff;
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: 10px;
  padding: 0.7rem 0.85rem;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: 2px solid rgba(126, 182, 224, 0.4);
  border-color: var(--ciel);
}

.btn {
  appearance: none;
  border: none;
  border-radius: 999px;
  padding: 0.7rem 1.15rem;
  cursor: pointer;
  font-weight: 600;
}
.btn-primary { background: var(--ciel); color: #fff; }
.btn-primary:hover { background: var(--ciel-deep); }
.btn-ghost {
  background: transparent;
  color: var(--navy);
  border: 1px solid var(--line);
}
.btn-ghost:hover {
  border-color: var(--ciel);
  background: #eaf3fb;
}
.btn-danger { background: var(--danger); color: white; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.row-actions { display: flex; gap: 0.6rem; flex-wrap: wrap; margin-top: 0.5rem; }

.list { list-style: none; padding: 0; margin: 0; }
.list li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--line);
}
.list li:last-child { border-bottom: none; }
.meta { color: var(--muted); font-size: 0.85rem; }

.badge {
  display: inline-block;
  font-size: 0.75rem;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--ciel-deep);
  background: #eaf3fb;
}
.badge.warn {
  color: var(--navy);
  border-color: var(--ciel);
  background: #fff;
}

.toast {
  margin-top: 0.9rem;
  padding: 0.75rem 0.9rem;
  border-radius: 10px;
  font-size: 0.92rem;
}
.toast.ok { background: rgba(47, 143, 91, 0.12); color: var(--ok); }
.toast.err { background: rgba(201, 75, 75, 0.12); color: var(--danger); }

.hidden { display: none !important; }

.login-wrap {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 1.5rem;
}
.login-card { width: min(420px, 100%); }

.home-stack {
  width: min(720px, 100%);
  display: grid;
  gap: 1rem;
  justify-items: center;
}
.home-stack .login-card { width: min(420px, 100%); }

.signup-grid {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}
@media (max-width: 640px) {
  .signup-grid { grid-template-columns: 1fr; }
}

.signup-card {
  display: block;
  text-decoration: none;
  color: var(--text);
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid var(--line);
  border-top: 4px solid var(--ciel);
  border-radius: var(--radius);
  padding: 1.1rem 1.2rem;
  box-shadow: var(--shadow);
  transition: border-color 0.15s ease, transform 0.15s ease;
}
.signup-card:hover {
  border-color: var(--ciel-deep);
  transform: translateY(-1px);
}
.signup-card strong {
  display: block;
  font-family: var(--font);
  font-size: 1.15rem;
  color: var(--ciel-deep);
  margin-bottom: 0.35rem;
}
.signup-card span {
  display: block;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.4;
}

.hero-mark {
  font-family: var(--font);
  font-size: 2rem;
  margin-bottom: 0.25rem;
  color: var(--navy);
}
.hero-mark em { font-style: normal; color: var(--ciel-deep); }

.btn-edit {
  background: var(--ciel);
  color: #fff;
  white-space: nowrap;
  flex-shrink: 0;
}
.btn-edit:hover { background: var(--ciel-deep); }
.list li .btn-edit { min-width: 5.5rem; }

.detail-block { margin-top: 1.25rem; }
.divider { height: 1px; background: var(--line); margin: 1.1rem 0; }

.password-wrap {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
  background: #f7fbff;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}
.password-wrap:focus-within {
  outline: 2px solid rgba(126, 182, 224, 0.4);
  border-color: var(--ciel);
}
.field .password-wrap input,
.password-wrap input {
  flex: 1;
  min-width: 0;
  width: auto;
  margin: 0;
  border: none !important;
  background: transparent !important;
  box-shadow: none !important;
  outline: none !important;
  padding: 0.7rem 0.4rem 0.7rem 0.85rem !important;
  border-radius: 0 !important;
  color: var(--text);
}
.field .password-wrap input:focus,
.password-wrap input:focus {
  outline: none !important;
  border: none !important;
}
.password-toggle {
  position: static;
  transform: none;
  flex-shrink: 0;
  width: 2.4rem;
  height: 2.4rem;
  margin-right: 0.2rem;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  display: grid;
  place-items: center;
  padding: 0;
}
.password-toggle:hover { color: var(--ciel-deep); }
.password-toggle .hidden { display: none !important; }

.empty { color: var(--muted); }

/* Vue semaine calendrier */
.week-cal { margin-top: 1rem; }
.week-cal-scroll {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}
.week-cal-grid {
  min-width: 720px;
  --week-gutter: 3.25rem;
  --week-hour-h: 3rem;
}
.week-cal-head {
  display: grid;
  grid-template-columns: var(--week-gutter) repeat(7, minmax(0, 1fr));
  border-bottom: 1px solid var(--line);
  background: #f3f8fc;
  position: sticky;
  top: 0;
  z-index: 2;
}
.week-cal-corner { border-right: 1px solid var(--line); }
.week-cal-dayhead {
  padding: 0.55rem 0.35rem;
  text-align: center;
  border-right: 1px solid var(--line);
}
.week-cal-dayhead:last-child { border-right: none; }
.week-cal-dayhead.is-today {
  background: rgba(126, 182, 224, 0.22);
}
.week-cal-dow {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}
.week-cal-dom {
  display: block;
  font-weight: 700;
  color: var(--navy);
  margin-top: 0.1rem;
}
.week-cal-body {
  display: grid;
  grid-template-columns: var(--week-gutter) minmax(0, 1fr);
}
.week-cal-gutter {
  display: grid;
  grid-template-rows: repeat(12, var(--week-hour-h));
  border-right: 1px solid var(--line);
  background: #fafcfe;
}
.week-cal-hour {
  font-size: 0.7rem;
  color: var(--muted);
  padding: 0.15rem 0.35rem 0 0;
  text-align: right;
  border-bottom: 1px solid #e8f0f8;
  transform: translateY(-0.45rem);
}
.week-cal-days {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}
.week-cal-day {
  position: relative;
  height: calc(12 * var(--week-hour-h));
  border-right: 1px solid var(--line);
  background:
    repeating-linear-gradient(
      to bottom,
      transparent 0,
      transparent calc(var(--week-hour-h) - 1px),
      #e8f0f8 calc(var(--week-hour-h) - 1px),
      #e8f0f8 var(--week-hour-h)
    );
}
.week-cal-day:last-child { border-right: none; }
.week-cal-day.is-today { background-color: rgba(126, 182, 224, 0.08); }
.week-cal-day.is-createable { cursor: crosshair; }
.week-cal-day.is-createable:hover { background-color: rgba(126, 182, 224, 0.14); }
.week-cal-line { display: none; }
.week-cal-event {
  position: absolute;
  left: 3px;
  right: 3px;
  border-radius: 8px;
  padding: 0.25rem 0.35rem;
  overflow: hidden;
  font-size: 0.72rem;
  line-height: 1.2;
  box-shadow: 0 1px 4px rgba(26, 58, 92, 0.12);
  z-index: 1;
}
.week-cal-event.is-slot {
  background: var(--ciel);
  color: #fff;
}
.week-cal-event.is-event {
  background: var(--navy);
  color: #fff;
}
.cal-legend-host {
  margin: 0.65rem 0 0.35rem;
}
.cal-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem 1rem;
  font-size: 0.82rem;
  color: var(--ink-muted, #5a6a7a);
}
.cal-legend strong {
  color: var(--navy, #1a3a5c);
  font-weight: 600;
  margin-right: 0.15rem;
}
.cal-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}
.cal-legend-item i {
  display: inline-block;
  width: 0.85rem;
  height: 0.85rem;
  border-radius: 3px;
  flex-shrink: 0;
}
.week-cal-event-time {
  display: block;
  opacity: 0.9;
  font-size: 0.65rem;
}
.week-cal-event-title {
  display: block;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.week-cal-del {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 1.1rem;
  height: 1.1rem;
  border: none;
  border-radius: 999px;
  background: rgba(255,255,255,0.25);
  color: #fff;
  cursor: pointer;
  line-height: 1;
  padding: 0;
  font-size: 0.85rem;
}
.week-cal-event.is-clickable { cursor: pointer; }
.week-cal-event.is-clickable:hover { filter: brightness(1.05); }
.month-cal-pill.is-clickable { cursor: pointer; }
.list li.is-clickable {
  cursor: pointer;
  transition: background 0.12s ease;
}
.list li.is-clickable:hover,
.list li.is-clickable:focus-visible {
  background: #eaf3fb;
  outline: none;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 40;
  background: rgba(26, 58, 92, 0.35);
  display: grid;
  place-items: center;
  padding: 1rem;
}
.modal-backdrop.hidden { display: none !important; }
.modal-card {
  width: min(720px, 100%);
  max-height: min(85vh, 900px);
  overflow: auto;
  margin: 0;
}

@media (max-width: 700px) {
  .week-cal-grid { min-width: 640px; --week-hour-h: 2.6rem; }
}

.cal-mode {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 999px;
  overflow: hidden;
  background: #fff;
}
.cal-mode button {
  border: none;
  background: transparent;
  padding: 0.4rem 0.85rem;
  cursor: pointer;
  color: var(--muted);
  font: inherit;
  font-size: 0.88rem;
}
.cal-mode button.active {
  background: var(--ciel);
  color: #fff;
}
.cal-host { margin-top: 1rem; }

.time-hm {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.time-hm select {
  flex: 1;
  min-width: 0;
}
.time-hm span {
  color: var(--muted);
  font-weight: 600;
}

.month-cal {
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow-x: auto;
  background: #fff;
}
.month-cal-head {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  min-width: 640px;
  background: #f3f8fc;
  border-bottom: 1px solid var(--line);
}
.month-cal-dow {
  padding: 0.55rem 0.25rem;
  text-align: center;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  border-right: 1px solid var(--line);
}
.month-cal-dow:last-child { border-right: none; }
.month-cal-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  grid-auto-rows: minmax(96px, auto);
  min-width: 640px;
}
.month-cal-cell {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.25rem;
  width: 100%;
  min-width: 0;
  min-height: 96px;
  padding: 0.35rem;
  border: none;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #fff;
  text-align: left;
  cursor: pointer;
  font: inherit;
  color: inherit;
}
.month-cal-cell:nth-child(7n) { border-right: none; }
.month-cal-cell.is-out { background: #f7fafc; color: var(--muted); }
.month-cal-cell.is-today { background: rgba(126, 182, 224, 0.12); }
.month-cal-cell:hover { background: #eef6fc; }
.month-cal-add {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 1.35rem;
  height: 1.35rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ciel-deep);
  font-size: 1rem;
  line-height: 1;
  padding: 0;
  cursor: pointer;
  opacity: 0.55;
}
.month-cal-cell:hover .month-cal-add,
.month-cal-add:focus {
  opacity: 1;
  border-color: var(--ciel-deep);
  background: var(--badge-bg, #eef6fc);
}
.month-cal-num {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--navy);
}
.month-cal-cell.is-out .month-cal-num { color: var(--muted); font-weight: 500; }
.month-cal-pills {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-height: 0;
}
.month-cal-pill {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.25rem;
  border-radius: 6px;
  padding: 0.15rem 0.3rem;
  font-size: 0.68rem;
  line-height: 1.2;
  color: #fff;
}
.month-cal-pill > span {
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.month-cal-del {
  flex-shrink: 0;
  width: 1rem;
  height: 1rem;
  border: none;
  border-radius: 999px;
  background: rgba(255,255,255,0.28);
  color: #fff;
  cursor: pointer;
  line-height: 1;
  padding: 0;
  font-size: 0.75rem;
}
.month-cal-del:hover { background: rgba(255,255,255,0.5); }
.month-cal-pill.is-slot { background: var(--ciel); }
.month-cal-pill.is-event { background: var(--navy); }
.month-cal-more {
  font-size: 0.68rem;
  color: var(--muted);
  padding-left: 0.15rem;
}

.import-preview {
  overflow: auto;
  max-height: 320px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #f7fbff;
}
.import-preview table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
}
.import-preview th,
.import-preview td {
  padding: 0.4rem 0.55rem;
  border-bottom: 1px solid var(--line);
  text-align: left;
  white-space: nowrap;
}
.import-preview th {
  position: sticky;
  top: 0;
  background: #eaf3fb;
  color: var(--navy);
  font-weight: 600;
}
.import-preview tr.is-error td { background: rgba(201, 75, 75, 0.08); color: var(--danger); }
.import-preview tr.is-warn td { background: rgba(212, 160, 23, 0.12); }
.import-preview tr.is-ok td { color: var(--text); }
.import-preview .status-pill {
  display: inline-block;
  font-size: 0.72rem;
  padding: 0.1rem 0.4rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
}
.import-preview tr.is-error .status-pill { border-color: var(--danger); color: var(--danger); }
.import-preview tr.is-warn .status-pill { border-color: #d4a017; color: #8a6a00; }
.import-preview tr.is-ok .status-pill { border-color: var(--ok); color: var(--ok); }

@media (max-width: 700px) {
  .month-cal-grid { grid-auto-rows: minmax(72px, auto); }
  .month-cal-pill { font-size: 0.6rem; }
}

/* Présences */
.attendance-host h3 { margin-bottom: 0.35rem; }
.att-sheet {
  margin-top: 0.85rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.85rem 1rem;
  background: #f7fbff;
}
.att-sheet-head {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: flex-start;
  margin-bottom: 0.65rem;
}
.att-counters { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.att-stats-block {
  margin-top: 0.85rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.85rem 1rem;
  background: #fff;
}
.att-stats-group-head {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.att-stats-players { margin: 0; }
.att-stats-player {
  display: block !important;
  padding: 0.65rem 0;
}
.att-stats-player + .att-stats-player { border-top: 1px solid var(--line); }
.att-stats-player-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
}
.att-stats-player.is-warn { background: rgba(212, 160, 23, 0.06); margin: 0 -0.5rem; padding-left: 0.5rem; padding-right: 0.5rem; border-radius: 8px; }
.att-list { margin: 0; }
.att-row {
  display: grid !important;
  grid-template-columns: minmax(0, 1.2fr) auto minmax(5rem, 0.8fr);
  gap: 0.5rem 0.75rem;
  align-items: center;
}
.att-actions { display: flex; gap: 0.25rem; flex-wrap: wrap; }
.att-btn {
  width: 2rem;
  height: 2rem;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--navy);
  font-weight: 700;
  font-size: 0.75rem;
  cursor: pointer;
  padding: 0;
}
.att-btn:hover:not(:disabled) { border-color: var(--ciel); background: #eaf3fb; }
.att-btn.active { background: var(--ciel); color: #fff; border-color: var(--ciel-deep); }
.att-btn:disabled { opacity: 0.45; cursor: not-allowed; }
.att-note {
  width: 100%;
  min-width: 0;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0.35rem 0.5rem;
  font: inherit;
  font-size: 0.8rem;
}
.badge.att-present { background: rgba(47, 143, 91, 0.12); color: var(--ok); border-color: rgba(47, 143, 91, 0.35); }
.badge.att-late { background: rgba(212, 160, 23, 0.15); color: #8a6a00; border-color: rgba(212, 160, 23, 0.45); }
.badge.att-absent { background: rgba(201, 75, 75, 0.12); color: var(--danger); border-color: rgba(201, 75, 75, 0.35); }
.badge.att-excused { background: #eaf3fb; color: var(--ciel-deep); }
.badge.att-competition { background: rgba(126, 182, 224, 0.2); color: var(--navy); border-color: var(--ciel); }
.att-history-block .list li { padding: 0.45rem 0; }
.att-history-mini { margin: 0; }
@media (max-width: 700px) {
  .att-row {
    grid-template-columns: 1fr;
  }
}

.att-warn {
  padding: 0.65rem 0.8rem;
  border-radius: 10px;
  background: rgba(201, 75, 75, 0.1);
  color: var(--danger);
  border: 1px solid rgba(201, 75, 75, 0.28);
  font-size: 0.9rem;
}
.att-warn.hidden { display: none !important; }
.att-ok {
  padding: 0.65rem 0.8rem;
  border-radius: 10px;
  background: rgba(47, 143, 91, 0.1);
  color: var(--ok);
  border: 1px solid rgba(47, 143, 91, 0.28);
  font-size: 0.9rem;
}
.pres-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 0.75rem;
}
.pres-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.75rem 0.85rem;
  background: #f7fbff;
}
.pres-card-head {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  align-items: baseline;
  flex-wrap: wrap;
}
.pres-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}
.pres-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
.pres-table th,
.pres-table td {
  padding: 0.55rem 0.65rem;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
  white-space: nowrap;
}
.pres-table th {
  background: #f0f5fa;
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--muted, #5a6b7d);
}
.pres-table tbody tr:last-child td { border-bottom: none; }
.pres-table-nested {
  border: 1px solid var(--line);
  border-radius: 8px;
  margin: 0.25rem 0 0.5rem;
  background: #fafcfe;
}
.pres-table-nested th {
  background: #e8f0f7;
  font-size: 0.75rem;
}
.pres-row-detail > td {
  padding: 0.35rem 0.65rem 0.75rem;
  background: #f7fbff;
  white-space: normal;
}
.pres-row-warn td:first-child,
.pres-row-alarm td:first-child {
  box-shadow: inset 3px 0 0 var(--danger, #c94b4b);
}
.pres-row-alarm {
  background: rgba(201, 75, 75, 0.06);
}
.att-warn-list .list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.att-warn-list .list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  padding: 0.4rem 0;
  border-bottom: 1px solid rgba(201, 75, 75, 0.15);
}
.att-warn-list .list li:last-child { border-bottom: none; }

.check-label {
  display: grid !important;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 0.55rem;
  text-transform: none !important;
  letter-spacing: normal !important;
  font-size: 0.95rem !important;
  color: var(--text) !important;
  cursor: pointer;
  line-height: 1.35;
  max-width: 100%;
}
.check-label input {
  margin-top: 0.2rem;
}

.dir-share-line {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  word-break: break-word;
  max-width: 100%;
}


/* Droits admin — matrice domaine × actions */
.admin-caps-matrix {
  width: 100%;
  overflow-x: auto;
}
.admin-caps-table-wrap {
  width: 100%;
  overflow-x: auto;
}
.admin-caps-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  min-width: 32rem;
}
.admin-caps-table th,
.admin-caps-table td {
  border: 1px solid var(--line);
  padding: 0.45rem 0.5rem;
  text-align: center;
  vertical-align: middle;
}
.admin-caps-table thead th {
  background: #eaf3fb;
  color: var(--ciel-deep);
  font-weight: 600;
  white-space: nowrap;
}
.admin-caps-table tbody th {
  text-align: left;
  font-weight: 600;
  background: #fafbfc;
  min-width: 8.5rem;
}
.admin-caps-domain {
  display: block;
}
.admin-caps-hint {
  display: block;
  font-weight: 400;
  margin-top: 0.15rem;
}
.admin-cap-cell {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  cursor: pointer;
  min-width: 1.75rem;
  min-height: 1.75rem;
}
.admin-caps-na {
  color: var(--muted);
  background: #f7f8f9;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ─── Fil Infos (1A) ─────────────────────────────────────── */
.infos-feed {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 0.75rem;
  max-width: 40rem;
}
.subtabs,
.infos-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.75rem;
}
.subtab,
.infos-tab {
  appearance: none;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--navy);
  border-radius: 8px;
  padding: 0.45rem 0.75rem;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
}
.subtab.is-active,
.subtab.active,
.infos-tab.is-active,
.infos-tab.active {
  border-color: var(--ciel-deep);
  background: #eaf3fb;
  font-weight: 700;
}
.infos-tab-panels {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.infos-tab-panel {
  display: none;
  flex-direction: column;
  gap: 0.75rem;
}
.infos-tab-panel.is-active {
  display: flex;
}
.infos-section {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.infos-section-title {
  margin: 0;
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
}
.infos-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1rem 1.1rem;
  box-shadow: 0 6px 18px rgba(26, 58, 92, 0.05);
}
.infos-card--event {
  border-left: 4px solid var(--ciel-deep);
}
.infos-card--pedagogy {
  border-left: 4px solid var(--ciel);
  background: linear-gradient(180deg, #fafcfe 0%, #fff 55%);
}
.infos-card--assignment {
  border-left: 4px solid var(--ciel-deep);
  background: linear-gradient(180deg, rgba(126, 182, 224, 0.14) 0%, #fff 60%);
}
.infos-coach-todos {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin: 0 0 1rem;
}
.infos-coach-todos .infos-card--assignment .row-actions {
  margin-top: 0.75rem;
}
.infos-card-kicker {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ciel-deep);
  font-weight: 600;
}
.infos-card-title {
  margin: 0 0 0.4rem;
  font-family: var(--font);
  font-size: 1.15rem;
  color: var(--navy);
  line-height: 1.3;
}
.infos-card-meta,
.infos-card-when {
  margin: 0 0 0.45rem;
  font-size: 0.88rem;
  color: var(--muted);
  font-weight: 500;
}
.infos-card-body {
  margin-top: 0.45rem;
  font-size: 0.95rem;
  line-height: 1.45;
  color: var(--text);
  white-space: normal;
}
.infos-card-body.is-clamped {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
}
.infos-card-more {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ciel-deep);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.35rem 0 0;
  cursor: pointer;
  text-align: left;
}
.infos-card-media-wrap {
  margin-top: 0.45rem;
}
.infos-card-progress {
  margin-top: 0.85rem;
  padding-top: 0.75rem;
  border-top: 1px dashed var(--line);
}
.infos-card-progress > strong {
  display: block;
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.35rem;
}
.ped-progress-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.75rem;
  margin-bottom: 0.35rem;
}
.ped-progress-pct {
  font-weight: 800;
  color: var(--ciel-deep, #1a6fa8);
  font-size: 1.05rem;
}
.ped-progress-bar {
  height: 8px;
  border-radius: 6px;
  background: var(--line);
  overflow: hidden;
  margin-bottom: 0.65rem;
}
.ped-progress-bar > span {
  display: block;
  height: 100%;
  background: var(--ciel-deep, #1a6fa8);
  border-radius: 6px;
}
.ped-steps-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.4rem;
}
.ped-steps-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  font-size: 0.92rem;
  line-height: 1.35;
}
.ped-steps-list li.is-done {
  opacity: 0.75;
  text-decoration: line-through;
}
.ped-step-check {
  flex: 0 0 auto;
  width: 1.15rem;
  height: 1.15rem;
  border: 2px solid var(--line);
  border-radius: 4px;
  margin-top: 0.1rem;
}
.ped-steps-list li.is-done .ped-step-check {
  border-color: #2f8f5b;
  background: #2f8f5b;
}
.ped-steps-editor {
  display: grid;
  gap: 0.45rem;
  margin-bottom: 0.55rem;
}
.ped-step-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.55rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}
.ped-step-row input[type="checkbox"] {
  width: 1.1rem;
  height: 1.1rem;
  flex: 0 0 auto;
}
.ped-step-row .ped-step-title {
  flex: 1;
  font-size: 0.92rem;
}
.ped-step-row .ped-step-remove {
  border: 0;
  background: transparent;
  color: #c94b4b;
  cursor: pointer;
  font-size: 0.8rem;
  padding: 0.15rem 0.25rem;
}
.ped-step-add {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}
.ped-step-add input {
  flex: 1;
}
.nested-panel {
  background: #f7fbff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 1rem 1.1rem;
}
.field textarea {
  width: 100%;
  background: #f7fbff;
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: 10px;
  padding: 0.7rem 0.85rem;
  resize: vertical;
  min-height: 5rem;
  font: inherit;
}
.field textarea:focus {
  outline: 2px solid rgba(126, 182, 224, 0.4);
  border-color: var(--ciel);
}

.infos-card-photo,
.infos-card-media {
  margin: 0.55rem 0 0.35rem;
  border-radius: 10px;
  overflow: hidden;
  background: #eaf3fb;
  border: 1px solid var(--line);
}
.infos-card-photo img,
.infos-card-media img,
.infos-card-media video {
  display: block;
  width: 100%;
  max-height: 320px;
  object-fit: cover;
  background: #0f2438;
}
.infos-card-media video {
  object-fit: contain;
  max-height: 360px;
}
.infos-card--post {
  border-left: 4px solid var(--ok);
}


.infos-audience-checks {
  max-height: 12rem;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.45rem 0.55rem;
  background: #fff;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}
.infos-audience-item {
  margin: 0 !important;
  padding: 0.2rem 0;
}
.infos-audience-item.hidden { display: none !important; }


.infos-audience-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.55rem 0.7rem;
  margin: 0.35rem 0 0.45rem;
  padding: 0.65rem 0.75rem;
  background: linear-gradient(180deg, #fafcfe 0%, #f2f7fc 100%);
  border: 1px solid var(--line);
  border-radius: 10px;
}
.infos-audience-filters .field {
  margin-bottom: 0;
  flex: 0 0 auto;
  min-width: 0;
}
.infos-audience-filters .field--search {
  flex: 1 1 10rem;
  min-width: min(100%, 9rem);
}
.infos-audience-filters .field label {
  white-space: nowrap;
}
.infos-audience-filters .field input,
.infos-audience-filters .field select {
  background: #fff;
  min-height: 2.35rem;
  padding: 0.45rem 0.65rem;
}
.infos-audience-filters .field select {
  width: max-content;
  min-width: 8.5rem;
  max-width: min(100%, 16rem);
}
.btn-sm {
  min-height: 2.35rem !important;
  padding: 0.35rem 0.65rem !important;
  font-size: 0.85rem !important;
  white-space: nowrap;
}


/* Charte école */
.charter-block .charter-scroll { max-height: 280px; }
.charter-sign-label { margin: 0.75rem 0 0.25rem; }
.charter-header h2 { margin: 0.25rem 0; font-size: 1.25rem; }
.charter-kicker {
  margin: 0;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted, #5a6b7d);
}
.charter-quote {
  margin: 0.75rem 0;
  padding: 0.65rem 0.85rem;
  border-left: 3px solid var(--ciel-deep, #1a6bb5);
  background: #f0f7fc;
  font-style: italic;
  color: var(--text);
}
.charter-article h4 { margin: 0.85rem 0 0.3rem; font-size: 0.95rem; }
/* Overlay plein écran : ne doit PAS pousser le header / la nav vers le bas */
.charter-gate-host:not(.hidden) {
  position: fixed;
  inset: 0;
  z-index: 100;
  margin: 0;
  padding: 1rem 1rem 2rem;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  background: rgba(247, 251, 255, 0.97);
  backdrop-filter: blur(6px);
}
.charter-gate-host .charter-gate-panel {
  max-width: 40rem;
  margin: 1.25rem auto;
  box-shadow: var(--shadow, 0 8px 28px rgba(26, 58, 92, 0.12));
}
.badge.charter-ok { background: #e6f6ea; color: #1b6b35; }
.badge.charter-miss { background: #fff3cd; color: #7a5b00; }


/* Suivi tests / Trackman */
.player-stats-host { margin-top: 0.75rem; }
.stats-section-title { margin: 0.75rem 0 0.35rem; font-size: 1.05rem; }
.stats-overall-card {
  border: 1px solid var(--ciel-deep, #4a90c8);
  border-radius: 12px;
  padding: 0.85rem 1rem;
  margin: 0.45rem 0 0.85rem;
  background: #fff;
}
.stats-overall-pct {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--navy, #1a3a5c);
  line-height: 1.2;
  margin-top: 0.25rem;
}
.stats-compartments-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr));
  gap: 0.65rem;
  margin-bottom: 1rem;
}
.stats-compartment-card {
  border: 1px solid var(--line, #c5daf0);
  border-radius: 10px;
  padding: 0.7rem 0.85rem;
  background: #f7fbff;
}
.stats-compartment-ex {
  list-style: none;
  margin: 0.55rem 0 0;
  padding: 0;
}
.stats-compartment-ex li {
  padding: 0.4rem 0;
  border-top: 1px solid var(--line, #e2eef8);
}
.stats-pct {
  font-weight: 700;
  color: var(--ciel-deep, #4a90c8);
  white-space: nowrap;
}
.stats-pct-lg { font-size: 1.05rem; }
.stats-result-card {
  border: 1px solid var(--line, #c5daf0);
  border-radius: 10px;
  padding: 0.65rem 0.8rem;
  margin: 0.45rem 0;
  background: #f7fbff;
}
.stats-result-card .meta { margin: 0.2rem 0; }
.stats-metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(8.5rem, 1fr));
  gap: 0.35rem 0.75rem;
  margin-top: 0.35rem;
}
.stats-metric {
  font-size: 0.86rem;
}
.stats-metric strong { display: block; font-size: 0.78rem; color: var(--muted, #5a6b7d); font-weight: 600; }
.stats-evo {
  margin: 0.5rem 0 0;
  padding: 0;
  list-style: none;
  font-size: 0.84rem;
}
.stats-evo li {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.2rem 0;
  border-bottom: 1px solid var(--line, #e2eef8);
}
.stats-record-grid-scroll {
  overflow-x: auto;
  margin: 0.5rem 0 0.25rem;
  border: 1px solid var(--line, #c5daf0);
  border-radius: 10px;
  background: #fff;
}
.stats-record-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  min-width: 28rem;
}
.stats-record-table th,
.stats-record-table td {
  padding: 0.45rem 0.55rem;
  border-bottom: 1px solid var(--line, #e2eef8);
  text-align: left;
  vertical-align: middle;
}
.stats-record-table th {
  background: #eef5fc;
  font-weight: 600;
  white-space: nowrap;
  position: sticky;
  top: 0;
}
.stats-record-table .player-name {
  white-space: nowrap;
  font-weight: 600;
  min-width: 8rem;
}
.stats-record-table .metric-unit {
  font-weight: 400;
  color: var(--muted, #5a6b7d);
  font-size: 0.78rem;
}
.stats-record-table input[type="number"] {
  width: 5.25rem;
  max-width: 100%;
  min-width: 4rem;
}
.stats-record-table tr.stats-record-focus {
  background: #fff8e6;
}
.stats-record-table tr:last-child td {
  border-bottom: none;
}

/* Messagerie WhatsApp */
.messages-root { margin-top: 0.5rem; }
.chat-layout {
  display: grid;
  grid-template-columns: minmax(220px, 320px) 1fr;
  gap: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
  min-height: min(70vh, 640px);
}
@media (max-width: 800px) {
  .chat-layout { grid-template-columns: 1fr; min-height: auto; }
}
.chat-sidebar {
  border-right: 1px solid var(--line);
  padding: 0.85rem;
  background: #f7fbff;
  max-height: min(70vh, 640px);
  overflow: auto;
}
.chat-main {
  display: flex;
  flex-direction: column;
  min-height: min(70vh, 640px);
}
.chat-thread-header {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--line);
}
.chat-readonly-banner {
  padding: 0.55rem 1rem;
  background: #eaf3fb;
  border-bottom: 1px solid var(--line);
  font-size: 0.88rem;
  color: var(--navy);
}
.chat-thread {
  flex: 1;
  overflow: auto;
  padding: 1rem;
  background: #f0f6fc;
}
.chat-composer {
  display: flex;
  gap: 0.5rem;
  padding: 0.75rem;
  border-top: 1px solid var(--line);
  background: #fff;
}
.chat-composer .chat-input {
  flex: 1;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.65rem 0.85rem;
  font: inherit;
}
.chat-list-item {
  display: flex;
  gap: 0.65rem;
  width: 100%;
  text-align: left;
  border: 1px solid transparent;
  background: transparent;
  border-radius: 10px;
  padding: 0.55rem;
  cursor: pointer;
  margin-bottom: 0.25rem;
  font: inherit;
  color: inherit;
}
.chat-list-item:hover,
.chat-list-item.active {
  background: #fff;
  border-color: var(--line);
}
.chat-list-item.unread strong { font-weight: 800; }
.chat-unread-dot {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 999px;
  background: #e85d4c;
  flex-shrink: 0;
  align-self: center;
}
.chat-avatar {
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 999px;
  background: #eaf3fb;
  color: var(--navy);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  flex-shrink: 0;
}
.coaching-progress-track {
  height: 0.55rem;
  border-radius: 999px;
  background: var(--line);
  overflow: hidden;
}
.coaching-progress-fill {
  height: 100%;
  background: var(--ciel-deep);
  border-radius: 999px;
}
.coaching-goal-list li.coaching-goal-row {
  align-items: flex-start;
}
.coaching-check {
  display: flex;
  gap: 0.65rem;
  align-items: flex-start;
  flex: 1;
  min-width: 0;
  cursor: pointer;
}
.coaching-check input {
  margin-top: 0.25rem;
  width: 1.1rem;
  height: 1.1rem;
  accent-color: var(--ok);
  flex-shrink: 0;
}
.coaching-check .done {
  text-decoration: line-through;
  color: var(--muted);
}
.coaching-check .done strong {
  font-weight: 600;
}
.profile-photo-block {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 0.75rem 0 1rem;
}
.profile-avatar-lg {
  width: 5.5rem;
  height: 5.5rem;
  border-radius: 999px;
  background: #eaf3fb;
  color: var(--navy);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.6rem;
  flex-shrink: 0;
  overflow: hidden;
  background-size: cover;
  background-position: center;
}
.dir-avatar {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 999px;
  background: #eaf3fb;
  color: var(--navy);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  flex-shrink: 0;
  overflow: hidden;
  background-size: cover;
  background-position: center;
}
.dir-avatar-lg {
  width: 5rem;
  height: 5rem;
  border-radius: 999px;
  background: #eaf3fb;
  color: var(--navy);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.4rem;
  margin: 0 auto 0.75rem;
  overflow: hidden;
  background-size: cover;
  background-position: center;
}
.dir-row-with-avatar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  flex: 1;
}
.chat-list-main { flex: 1; min-width: 0; }
.chat-list-top {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
}
.chat-preview {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.chat-bubble-row { margin-bottom: 0.65rem; display: flex; flex-direction: column; }
.chat-bubble-row.mine { align-items: flex-end; }
.chat-bubble-row.theirs { align-items: flex-start; }
.chat-author { font-size: 0.75rem; color: var(--muted); margin: 0 0.35rem 0.15rem; }
.chat-bubble {
  max-width: min(85%, 28rem);
  padding: 0.55rem 0.8rem;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--line);
}
.chat-bubble-row.mine .chat-bubble {
  background: var(--ciel);
  border-color: transparent;
  color: var(--navy);
}
.chat-body { white-space: pre-wrap; word-break: break-word; line-height: 1.35; }
.chat-time { font-size: 0.7rem; color: var(--muted); margin-top: 0.25rem; text-align: right; }
.btn-sm { padding: 0.35rem 0.7rem; font-size: 0.85rem; }

/* Cloche messages non lus (header) */
.msg-bell {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border: 1px solid rgba(255,255,255,0.35);
  border-radius: 999px;
  background: rgba(255,255,255,0.12);
  cursor: pointer;
  padding: 0;
  color: inherit;
  font: inherit;
}
.msg-bell:hover { background: rgba(255,255,255,0.22); }
.msg-bell-icon { font-size: 1rem; line-height: 1; }
.msg-bell-badge {
  position: absolute;
  top: -0.2rem;
  right: -0.25rem;
  min-width: 1.15rem;
  height: 1.15rem;
  padding: 0 0.28rem;
  border-radius: 999px;
  background: #e85d4c;
  color: #fff;
  font-size: 0.65rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--navy);
}
.app-header .user-chip { gap: 0.55rem; }


/* Club Junior */
.club-junior-root { max-width: 720px; }
.club-junior-sections { display: flex; flex-direction: column; gap: 0.85rem; margin-top: 0.75rem; }
.club-junior-card .club-junior-p { margin: 0.45rem 0 0; color: var(--muted, #5a6b7d); font-size: 0.95rem; line-height: 1.45; }
.club-junior-card .club-junior-p:first-of-type { margin-top: 0.55rem; }
.club-junior-events { margin: 0.75rem 0 0; }

.club-junior-rsvp { margin-top: 0.35rem; }
.club-junior-rsvp-list { margin: 0.35rem 0 0; padding-left: 1.1rem; color: var(--muted, #5a6b7d); font-size: 0.9rem; }

/* Équipe école */
.school-team-root { max-width: 920px; }
.school-team-header { margin-bottom: 1rem; }
.school-team-title { margin: 0 0 0.35rem; font-size: 1.35rem; }
.school-team-org { display: flex; flex-direction: column; gap: 1.25rem; }
.school-team-level-title {
  margin: 0 0 0.65rem;
  font-size: 1.05rem;
  color: var(--ciel-deep, #0b3d5c);
}
.school-team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 0.85rem;
}
.school-team-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.55rem;
  padding: 0.85rem 0.75rem;
  border: 1px solid var(--line, #e2e8f0);
  border-radius: 14px;
  background: #fff;
}
.school-team-photo {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--line, #e2e8f0);
}
.school-team-photo--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--muted, #5a6b7d);
}
.school-team-card-body { width: 100%; }
.school-team-name { display: block; font-size: 0.98rem; }
.school-team-role {
  margin-top: 0.2rem;
  font-size: 0.88rem;
  color: var(--ciel-deep, #0b3d5c);
  font-weight: 600;
}
.school-team-bio {
  margin: 0.4rem 0 0;
  font-size: 0.85rem;
  line-height: 1.4;
  color: var(--muted, #5a6b7d);
}
