:root {
  /* Palette de marque, extraite du logo JeloBox */
  --brand-blue: #4095ef;
  --brand-orange: #fe5208;
  --brand-yellow: #feba01;
  --brand-green: #83c527;

  /* Couleurs sémantiques (variantes assombries pour le contraste texte blanc) */
  --primary: #2969c7;
  --success: #5c9a1d;
  --warning: #c98a00;
  --danger: #e5484d;

  --bg: #ffffff;
  --border: #e2e8f0;
}

* { box-sizing: border-box; }

html { font-size: 112.5%; } /* base ~18px : tout le reste (rem) suit */

body {
  margin: 0;
  font-family: system-ui, Arial, sans-serif;
  background: var(--bg);
  color: #222;
}

/* Champs de formulaire : style unique pour toute l'application */
input[type="text"],
input[type="email"],
input[type="number"],
input[type="date"],
input[type="password"],
input[type="search"],
select,
textarea {
  font-family: inherit;
  font-size: 1rem;
  padding: 0.65rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
  color: #222;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="number"]:focus,
input[type="date"]:focus,
input[type="password"]:focus,
input[type="search"]:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(41, 105, 199, 0.18);
}

.field-hint {
  margin-top: -0.5rem;
  font-size: 0.85rem;
  color: #666;
}

.password-field {
  position: relative;
  display: flex;
}

.password-field input[type="password"],
.password-field input[type="text"] {
  width: 100%;
  padding-right: 2.75rem;
}

.password-toggle {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 2.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  padding: 0;
  color: #888;
  cursor: pointer;
}

.password-toggle:hover,
.password-toggle:focus-visible { color: var(--primary); }

.password-toggle:focus-visible { outline: 2px solid var(--primary); outline-offset: -2px; border-radius: 8px; }

.password-toggle .icon-eye-off { display: none; }
.password-toggle.is-visible .icon-eye { display: none; }
.password-toggle.is-visible .icon-eye-off { display: block; }

.checkbox-label {
  flex-direction: row !important;
  align-items: center;
  gap: 0.5rem !important;
}

.checkbox-label input[type="checkbox"] {
  width: 1.1rem;
  height: 1.1rem;
}

.navbar {
  background: #fff;
  border-bottom: 1px solid var(--border);
}

.navbar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0.85rem 1rem;
}

.navbar .brand { text-decoration: none; }

.navbar nav a {
  color: #444;
  margin-left: 1.5rem;
  text-decoration: none;
  font-weight: 500;
}

.navbar nav a:hover { color: var(--primary); }

/* Marque TMPlanning : icône + wordmark bicolore (écho au logo JeloBox) */
.brand-mark {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.navbar .brand-icon { height: 3.9rem; width: auto; }
.hero .brand-icon { height: 3.9rem; width: auto; }

.brand-word { font-weight: 800; letter-spacing: -0.01em; font-size: 2.9rem;}
.brand-tm { color: var(--brand-blue); }
.brand-planning { color: var(--brand-orange); }

/* Menu sandwich (mobile) */
.navbar-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 2.75rem;
  height: 2.75rem;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  flex-shrink: 0;
}

.navbar-toggle-bar {
  display: block;
  width: 1.6rem;
  height: 2px;
  background: #333;
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.navbar-toggle.is-open .navbar-toggle-bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.navbar-toggle.is-open .navbar-toggle-bar:nth-child(2) { opacity: 0; }
.navbar-toggle.is-open .navbar-toggle-bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }


.container {
  max-width: 1100px;
  margin: 2rem auto;
  padding: 0 1rem;
}

.hero {
  text-align: center;
  padding: 2.5rem 0;
}

.hero h1 { margin: 0.75rem 0 0; }

.eyebrow {
  display: inline-block;
  padding: 2.5rem;
  border-radius: 30px;
  background: #eaf3fd;
  color: var(--primary);
  font-size: 1.8rem;
  font-weight: 600;
  margin-bottom: 1.6rem;;
}

.pitch {
  max-width: 800px;
  margin: 1rem auto 1.25rem;
  color: #444;
  line-height: 1.5;
  font-size: 1.2rem;
  margin-bottom: 3rem;;
}

.hero-actions {
  margin-top: 2rem;
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.hero-actions .btn,
.hero-actions .btn-secondary {
  min-width: 14rem;
}

/* Système de boutons unifié : même forme (pilule) et même famille pour tous,
   avec des tailles graduées selon le contexte (normal / small / icon). */
.btn, .btn-secondary, .btn-danger, .btn-icon, .btn-donate {
  display: inline-block;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 600;
  text-decoration: none;
  text-align: center;
  white-space: nowrap;
}

.btn, .btn-secondary, .btn-danger, .btn-donate {
  padding: 0.9rem 2rem;
  font-size: 1.05rem;
}

.btn { background: var(--primary); color: #fff; }

.btn-secondary {
  background: #fff;
  color: #444;
  border: 1px solid var(--border);
}

.btn-secondary:hover { border-color: var(--primary); color: var(--primary); }

.btn-danger { background: var(--danger); color: #fff; }

.btn-small { padding: 0.45rem 1rem; font-size: 0.9rem; }

.btn-icon {
  padding: 0.45rem 1rem;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--primary);
  font-size: 0.9rem;
}

.btn-icon:hover { background: #eaf3fd; }
.btn-icon-danger { color: var(--danger); border-color: var(--danger); }

/* Graphique de répartition des bandes (image SVG générée côté serveur) */
.band-chart-panel {
  background: #eaf3fd;
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 1rem 1rem 0.5rem;
  margin-top: 1.25rem;
  margin-bottom: 1.25rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.band-chart-panel h2 { margin: 0 0 0.5rem; font-size: 1.15rem; }

.band-chart { display: block; width: 100%; height: auto; }

.band-chart-open {
  display: block;
  width: 100%;
  padding: 0;
  border: none;
  background: none;
  cursor: zoom-in;
}

.band-chart-dialog {
  position: relative;
  border: none;
  border-radius: 18px;
  padding: 1rem;
  width: 96vw;
  max-width: none;
  max-height: 90vh;
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.2);
}

.band-chart-dialog::backdrop { background: rgba(20, 30, 45, 0.6); }

.band-chart-dialog-close {
  position: absolute;
  top: 0.6rem;
  right: 0.6rem;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: #fff;
  color: #444;
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
}

.band-chart-dialog-close:hover { color: var(--primary); border-color: var(--primary); }

.band-chart-large {
  display: block;
  width: 100%;
  height: auto;
  max-height: calc(90vh - 2rem);
  object-fit: contain;
}

.band-filter { position: relative; }

.band-filter summary {
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.band-filter summary::-webkit-details-marker { display: none; }

.band-filter-menu {
  position: absolute;
  right: 0;
  top: calc(100% + 0.4rem);
  z-index: 10;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.75rem;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
  display: grid;
  grid-template-columns: repeat(3, minmax(4.5rem, 1fr));
  gap: 0.4rem 0.75rem;
  min-width: 16rem;
}

.band-filter-actions {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.75rem;
  margin-bottom: 0.35rem;
  padding-bottom: 0.35rem;
  border-bottom: 1px solid var(--border);
}

.band-filter-actions button {
  background: none;
  border: none;
  color: var(--primary);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
}

.band-filter-option {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.88rem;
  white-space: nowrap;
  cursor: pointer;
}

/* Grille des bandes : élément central de la page */
.grid-panel {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 1rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.grid-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.2rem;
}

.grid-toolbar h2 { margin: 0; font-size: 1.15rem; }

.grid-toolbar-actions {
  display: flex;
  gap: 0.5rem;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th, td {
  border-bottom: 1px solid var(--border);
  padding: 0.6rem 0.6rem;
  text-align: left;
  font-size: 0.92rem;
}

th {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #666;
  border-bottom: 2px solid var(--border);
}

.chip {
  display: inline-block;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
}

.chip-free { background: #c8e9a5; color: var(--success); }
.chip-busy { background: #fdecec; color: var(--danger); }

/* Matrice bandes × modes */

.matrix-legend {
  display: flex;
  gap: 1.25rem;
  flex-wrap: wrap;
  font-size: 0.82rem;
  color: #666;
  margin-bottom: 1.85rem;
  justify-content: center;
}

.legend-item { display: inline-flex; align-items: center; gap: 0.4rem; }

.legend-swatch {
  width: 0.8rem;
  height: 0.8rem;
  border-radius: 4px;
  flex: none;
}

.legend-swatch.free { background: #fff; border: 1.5px solid var(--brand-green); }
.legend-swatch.busy { background: var(--primary); }

.matrix-scroll { overflow-x: auto; }

.bands-matrix {
  display: grid;
  grid-template-columns: minmax(3.4rem, auto) repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.matrix-head {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #666;
  text-align: center;
  padding-bottom: 0.3rem;
}

.matrix-row { display: contents; }

.matrix-band {
  display: flex;
  align-items: center;
  font-weight: 700;
  font-size: 0.9rem;
}

.cell {
  position: relative;
  min-height: 2.75rem;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font: inherit;
  font-size: 0.85rem;
}

.cell.free {
  background: #fff;
  border: 1.5px solid var(--brand-green);
  color: var(--success);
  cursor: pointer;
}

.cell.free:hover,
.cell.free:focus-visible {
  border-style: solid;
  border-color: var(--primary);
  background: #eaf3fd;
  color: var(--primary);
}

.cell-reserve { display: none; font-size: 0.72rem; font-weight: 700; }

.cell.free:hover .cell-dot,
.cell.free:focus-visible .cell-dot { display: none; }

.cell.free:hover .cell-reserve,
.cell.free:focus-visible .cell-reserve { display: inline-block; }

.cell.free.cell-disabled {
  cursor: default;
  opacity: 0.55;
}

.cell.free.cell-disabled:hover,
.cell.free.cell-disabled:focus-visible {
  border-color: var(--brand-green);
  background: #fff;
  color: var(--success);
}

.cell.busy {
  position: relative;
  background: var(--primary);
  color: #fff;
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  gap: 0.2rem;
  padding: 0.45rem 0.5rem;
  text-align: left;
  overflow: hidden;
  container-type: inline-size;
}

.cell-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.5rem;
  width: 100%;
  white-space: nowrap;
}

.cell-call { font-weight: 700; font-size: 0.85rem; }

.cell-info-left,
.cell-info-right {
  font-size: 0.7rem;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.85);
}

/* Cellule occupée trop étroite pour tout afficher : uniquement l'indicatif,
   les autres informations apparaissent dès que la cellule a la place (container query). */
.cell-row:nth-child(2) { display: none; }
.cell-row:nth-child(1) { justify-content: center; }
.cell-row:nth-child(1) .cell-info-right { display: none; }

@container (min-width: 15rem) {
  .cell-row:nth-child(1) { justify-content: space-between; }
  .cell-row:nth-child(1) .cell-info-right { display: inline; }
  .cell-row:nth-child(2) { display: flex; }
}

.cell-qrt {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(17, 24, 39, 0.72);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.12s ease;
}

.cell.busy:hover .cell-qrt,
.cell.busy:focus-within .cell-qrt { opacity: 1; pointer-events: auto; }

.cell-qrt button:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

.error {
  background: #fdecec;
  color: var(--danger);
  padding: 0.75rem;
  border-radius: 6px;
}

.session-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.session-filters .search-input {
  flex: 1 1 280px;
  width: auto;
}

.filter-toggle {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: #444;
  white-space: nowrap;
  cursor: pointer;
}

.filter-toggle input[type="checkbox"] {
  width: 1.1rem;
  height: 1.1rem;
}

.no-results {
  color: #666;
  font-style: italic;
}

mark {
  background: var(--brand-yellow);
  color: #222;
  border-radius: 3px;
  padding: 0 0.15em;
}

.session-card[hidden] { display: none; }

.session-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(345px, 1fr));
  gap: 1.25rem;
}

.session-card {
  position: relative;
  display: block;
  overflow: hidden;
  background: linear-gradient(135deg, var(--brand-blue) 0%, var(--primary) 55%, #1c4d90 100%);
  border: none;
  border-radius: 22px;
  padding: 1.75rem;
  text-decoration: none;
  color: #fff;
  transition: box-shadow 0.2s, transform 0.2s;
}

.session-card:hover {
  box-shadow: 0 14px 28px rgba(28, 77, 144, 0.35);
  transform: translateY(-3px);
}

/* Filigrane décoratif : reprend le losange de la marque, en fond */
.session-card-watermark {
  position: absolute;
  right: -2.2rem;
  bottom: -2.2rem;
  width: 9rem;
  height: 9rem;
  background: url('/img/tmplanning-mark.svg') no-repeat center / contain;
  opacity: 0.16;
  transform: rotate(-12deg);
  pointer-events: none;
  z-index: 0;
}

.session-card h3 {
  position: relative;
  z-index: 1;
  font-size: 1.4rem;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.session-card .session-dates, .session-card .date-info, .session-card .session-creator {
  position: relative;
  z-index: 1;
  white-space: nowrap;
  margin: 0.2rem 0 0;
}

.session-card .session-dates { color: rgba(255, 255, 255, 0.92); font-size: 1rem; }

.session-card .date-info { color: rgba(255, 255, 255, 0.78); font-size: 0.9rem; font-style: normal; }

.session-card .session-creator { color: rgba(255, 255, 255, 0.78); font-size: 0.9rem; }

.session-card-header, .session-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
}

.session-card-header {
  position: relative;
  z-index: 1;
  flex-wrap: nowrap;
}

.session-card-header .badge { flex-shrink: 0; }

.session-card-badges {
  display: flex;
  gap: 0.35rem;
  flex-shrink: 0;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.session-header {
  align-items: flex-start;
  flex-wrap: wrap;
  margin-bottom: 0.25rem;
}

.session-title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.session-title-row h1 { margin: 0; }

.session-dates {
  margin: 0.3rem 0 0;
  color: #666;
  font-size: 0.9rem;
}

.date-info {
  color: #888;
  font-size: 0.85rem;
  font-style: italic;
}

.session-creator {
  margin: 0.2rem 0 0;
  color: #888;
  font-size: 0.85rem;
}

.session-creator-empty { font-style: italic; }
.session-creator-empty a { color: var(--primary); font-style: normal; }

.session-card h3, .session-card p { margin: 0.25rem 0; }

.session-card-footer {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.9);
  flex-wrap: nowrap;
}

.session-card-footer > span:first-child { white-space: nowrap; }

.badge {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  color: #fff;
  white-space: nowrap;
}

.badge-ongoing { background: var(--success); }
.badge-upcoming { background: var(--warning); }
.badge-ended { background: #8a94a3; }

.badge-public { background: var(--primary); }
.badge-private { background: var(--brand-orange); }

.usage-readonly-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
  background: #fff6e5;
  border: 1px solid #f0d999;
  border-radius: 12px;
  padding: 0.75rem 1rem;
  margin-top: 1.25rem;
  margin-bottom: 1.25rem;
  font-size: 0.9rem;
  color: #7a5b00;
}

.session-notice-banner {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: #fff6e5;
  border: 1px solid #f0d999;
  border-radius: 12px;
  padding: 0.75rem 1rem;
  margin-top: 1.25rem;
  font-size: 0.9rem;
  color: #7a5b00;
}

.session-form {
  background: #fff;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 18px;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 1rem;
}

.session-form label {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  font-size: 0.9rem;
}

.date-row {
  display: flex;
  gap: 1rem;
}

.date-row label { flex: 1; }

.operator-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.operator-row input { flex: 1; }

.form-actions { margin-top: 0.5rem; }

.session-actions {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  flex-shrink: 0;
}

.inline-form { display: inline; }

.file-import {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  font-size: 0.85rem;
  background: #f5f8fb;
  border: 1px dashed var(--border);
  border-radius: 14px;
  padding: 0.75rem;
  margin-bottom: 1rem;
}

.operators-toolbar {
  display: flex;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.operators-toolbar .file-import {
  flex: 1;
  min-width: 16rem;
  margin-bottom: 0;
}

/* Champs fichier : bouton natif aligné sur la charte (même style que .btn-icon) */
input[type="file"] {
  font-family: inherit;
  font-size: 0.9rem;
  color: #555;
}

input[type="file"]::file-selector-button {
  display: inline-block;
  margin-right: 0.75rem;
  padding: 0.45rem 1rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: #fff;
  color: var(--primary);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

input[type="file"]::file-selector-button:hover {
  background: #eaf3fd;
  border-color: var(--primary);
}

input[type="file"]:focus-visible {
  outline: none;
  border-radius: 999px;
  box-shadow: 0 0 0 3px rgba(41, 105, 199, 0.18);
}

.password-dialog {
  border: none;
  border-radius: 18px;
  padding: 1.75rem;
  width: min(24rem, 90vw);
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.2);
}

.password-dialog::backdrop {
  background: rgba(20, 30, 45, 0.45);
}

.password-dialog h2 { margin-top: 0; }

.password-dialog form {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.password-dialog label {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  font-size: 0.9rem;
}

.password-dialog label.remember-me-toggle {
  flex-direction: row;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
}

.password-dialog .form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  margin-top: 0;
}

.reserve-dialog {
  border: none;
  border-radius: 18px;
  padding: 1.75rem;
  width: min(24rem, 90vw);
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.2);
}

.reserve-dialog::backdrop {
  background: rgba(20, 30, 45, 0.45);
}

.reserve-dialog h2 { margin-top: 0; }

.reserve-dialog form {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.reserve-dialog label {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  font-size: 0.9rem;
}

.reserve-dialog select,
.reserve-dialog input {
  padding: 0.5rem 0.7rem;
  font-size: 0.9rem;
}

.reserve-dialog select:invalid { color: #888; }

.reserve-dialog .form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  margin-top: 0;
}

.danger-zone {
  margin-top: 1.5rem;
  padding: 1rem;
  border: 1px solid var(--danger);
  border-radius: 18px;
}

.danger-zone h2 { margin-top: 0; color: var(--danger); }

.footer {
  margin-top: 5rem;
  text-align: center;
  padding: 3rem 1rem 2.5rem;
  color: #777;
  font-size: 0.95rem;
  border-top: 1px solid var(--border);
}

.footer p { margin: 0.4rem 0; }
.footer a { color: var(--primary); }

.footer-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  margin: 1.5rem auto 0.5rem;
  color: #777;
  text-decoration: none;
  font-size: 1rem;
}

.footer-brand:hover { color: var(--primary); }

.footer-logo {
  height: 5.5rem;
  width: auto;
  border-radius: 6px;
}

/* Page À propos : lecture aérée, technique et épurée */

.about h1 { font-size: 2.4rem; margin-bottom: 1.75rem; }

.about h2 {
  font-size: 1.5rem;
  margin-top: 3rem;
  margin-bottom: 1rem;
}

.about p {
  font-size: 1.1rem;
  line-height: 1.8;
  margin: 1.1rem 0;
  color: #333;
}

.donation-box {
  margin: 3rem auto 0;
  padding: 2.5rem 2rem;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 22px;
  text-align: center;
  max-width: 600px;
}

.donation-box p {
  font-size: 1.15rem;
  max-width: 520px;
  margin: 0 auto;
}

.btn-donate {
  margin-top: 1.5rem;
  padding: 1rem 2.25rem;
  background: var(--brand-yellow);
  color: #222;
  font-size: 1.15rem;
}

.btn-donate:hover { background: #e6a900; }

/* Partage : bouton d'ouverture, modale de configuration, page publique */

.share-active {
  border-color: var(--success);
  color: var(--success);
}

.share-dialog {
  border: none;
  border-radius: 18px;
  padding: 1.75rem;
  width: min(28rem, 90vw);
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.2);
}

.share-dialog::backdrop { background: rgba(20, 30, 45, 0.45); }

.share-dialog h2 { margin-top: 0; }

.share-dialog form {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.share-dialog-intro {
  margin: -0.4rem 0 0;
  font-size: 0.88rem;
  color: #666;
}

.share-dialog fieldset {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.75rem 0.9rem 0.9rem;
  margin: 0;
}

.share-dialog legend {
  padding: 0 0.4rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: #555;
}

.share-bands-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(4.5rem, 1fr));
  gap: 0.4rem 0.75rem;
}

.share-band-option,
.share-checkbox-option {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.9rem;
  cursor: pointer;
}

.share-checkbox-option[hidden] { display: none; }

.share-blocks-fieldset {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.share-enabled-option { font-weight: 600; }

.share-link-row {
  display: flex;
  gap: 0.5rem;
}

.share-link-row[hidden] { display: none; }

.share-link-row input {
  flex: 1;
  padding: 0.5rem 0.7rem;
  font-size: 0.85rem;
  color: #555;
  background: #f5f6f8;
}

.share-copied {
  margin: -0.4rem 0 0;
  font-size: 0.85rem;
  color: var(--success);
}

.share-dialog .form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  margin-top: 0;
}

/* Page de partage publique : minimaliste, sans entête ni menu */

.share-page .session-header { margin-bottom: 0; }

.share-toolbar {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.6rem;
}

.share-toolbar + .grid-panel { margin-top: 0.75rem; }

.share-refresh-countdown {
  font-variant-numeric: tabular-nums;
  opacity: 0.75;
}

.share-autorefresh-toggle {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  color: #666;
  cursor: pointer;
}

.share-unavailable {
  text-align: center;
  padding: 3rem 1rem;
}

.share-unavailable-brand {
  display: inline-block;
  margin-bottom: 1.5rem;
  text-decoration: none;
}

.share-unavailable-brand .brand-icon { height: 3.9rem; width: auto; }

.footer-share { margin-top: 1rem; padding: 1rem 1rem 1.25rem; }
.footer-share p { margin: 0.3rem 0; }
.footer-share .footer-logo {
  height: 3rem;
}
.footer-share .footer-brand {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  margin: 0.4rem 0 0;
  gap: 0.4rem;
}

.share-page .cell.free:hover,
.share-page .cell.free:focus-visible {
  border-color: var(--brand-green);
  background: #fff;
  color: var(--success);
}

.share-page .cell.free:hover .cell-dot,
.share-page .cell.free:focus-visible .cell-dot { display: inline; }

/* Responsive (mobile) - placé en fin de fichier pour primer sur les règles de base à spécificité égale */
@media (max-width: 800px) {
  .navbar-inner {
    flex-wrap: wrap;
    padding: 0.65rem 1rem;
  }

  .navbar .brand-icon { height: 2.6rem; }
  .navbar .brand-word { font-size: 1.6rem; }

  .navbar-toggle { display: flex; }

  .navbar nav {
    display: none;
    flex-basis: 100%;
    flex-direction: column;
    margin-top: 0.75rem;
  }

  .navbar nav.is-open { display: flex; }

  .navbar nav a {
    margin-left: 0;
    padding: 0.7rem 0;
    border-top: 1px solid var(--border);
  }
}

@media (max-width: 640px) {
  .date-row {
    flex-direction: column;
    gap: 0.75rem;
  }

  .session-actions {
    flex-wrap: wrap;
    flex-shrink: 1;
    min-width: 0;
  }

  .operator-row {
    flex-wrap: wrap;
  }

  .operator-row input {
    flex-basis: 100%;
  }

  .operator-row .remove-operator {
    margin-left: auto;
  }

  .operators-toolbar .file-import {
    flex-basis: 100%;
    min-width: 0;
  }

  .grid-toolbar {
    flex-wrap: wrap;
    gap: 0.5rem;
  }

  .band-filter-menu {
    right: auto;
    left: 0;
    min-width: 0;
    width: max(16rem, 80vw);
    max-width: calc(100vw - 2rem);
  }
}
