@import url('https://fonts.googleapis.com/css2?family=Dancing+Script:wght@600;700&family=Open+Sans:wght@400;600;700&display=swap');

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

:root {
  --cyan:        #29b6d5;
  --cyan-dark:   #1a96b3;
  --cyan-pale:   #e0f7fc;
  --orange:      #f5821f;
  --green:       #8bc43a;
  --white:       #ffffff;
  --bg:          #f0f5f8;
  --gray:        #6b7280;
  --radius:      10px;
  --shadow:      0 2px 10px rgba(0,0,0,0.08);
}

body {
  font-family: 'Open Sans', sans-serif;
  background: var(--bg);
  color: #1a1a1a;
  min-height: 100vh;
}

/* ── LOGIN ───────────────────────────────────────────── */
.admin-login {
  max-width: 380px;
  margin: 80px auto;
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 40px 32px;
  text-align: center;
  border-top: 4px solid var(--cyan);
}
.admin-login h1 {
  font-family: 'Dancing Script', cursive;
  color: var(--cyan-dark);
  font-size: 1.8rem;
  margin-bottom: 6px;
}
.admin-login p { color: var(--gray); margin-bottom: 24px; font-size: 0.9rem; }
.admin-login input {
  width: 100%; margin-bottom: 14px;
  padding: 10px 14px;
  border: 1.5px solid #d0e8f0;
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: 'Open Sans', sans-serif;
}
.admin-login input:focus { outline: none; border-color: var(--cyan); }
.btn-login {
  width: 100%; padding: 12px;
  background: var(--orange); color: white;
  border: none; border-radius: 8px;
  font-size: 1rem; font-weight: 700;
  font-family: 'Open Sans', sans-serif;
  cursor: pointer; text-transform: uppercase; letter-spacing: 0.4px;
}
.btn-login:hover { background: #d96a0a; }
.error-msg { color: #dc2626; font-size: 0.85rem; margin-top: 10px; }

/* ── TOPBAR ──────────────────────────────────────────── */
.dash-topbar {
  background: var(--cyan-dark);
  color: white;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.dash-topbar h1 {
  font-family: 'Dancing Script', cursive;
  font-size: 1.5rem;
  font-weight: 700;
}
.dash-topbar .sub { font-size: 0.78rem; opacity: 0.75; margin-top: 1px; }
.dash-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

.btn-action {
  padding: 6px 12px;
  border-radius: 7px;
  border: 1.5px solid rgba(255,255,255,0.35);
  background: rgba(255,255,255,0.1);
  color: white;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  font-family: 'Open Sans', sans-serif;
  transition: background 0.15s;
  white-space: nowrap;
}
.btn-action:hover { background: rgba(255,255,255,0.22); }
.btn-action:disabled { opacity: 0.45; cursor: not-allowed; }
.btn-action.danger { border-color: rgba(255,100,100,0.45); }
.cache-info { font-size: 0.72rem; opacity: 0.6; white-space: nowrap; }

/* ── NAV SECONDAIRE ──────────────────────────────────── */
.dash-nav {
  background: white;
  border-bottom: 1px solid #e0edf2;
  display: flex;
  gap: 0;
  padding: 0 16px;
  overflow-x: auto;
}
.nav-tab {
  padding: 12px 18px;
  border: none;
  background: none;
  font-family: 'Open Sans', sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gray);
  cursor: pointer;
  border-bottom: 3px solid transparent;
  white-space: nowrap;
  transition: color 0.15s, border-color 0.15s;
  position: relative;
}
.nav-tab:hover { color: var(--cyan-dark); }
.nav-tab.active { color: var(--cyan-dark); border-bottom-color: var(--cyan); }

.alert-badge {
  display: inline-block;
  background: #ef4444;
  color: white;
  font-size: 0.65rem;
  font-weight: 700;
  border-radius: 10px;
  padding: 1px 5px;
  margin-left: 4px;
  vertical-align: middle;
}

/* ── SECTIONS ────────────────────────────────────────── */
.section { display: none; }
.section.active { display: block; }
.section-inner { padding: 24px 28px 56px; max-width: 1600px; }

/* ── HÉRO ACCUEIL ────────────────────────────────────── */
.hero-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 28px;
}
@media (max-width: 720px) { .hero-metrics { grid-template-columns: 1fr; } }

.hero-card {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 28px 20px 22px;
  text-align: center;
  border-top: 5px solid #e5e7eb;
  transition: border-color 0.4s;
}
.hero-icon { font-size: 1.8rem; margin-bottom: 8px; }
.hero-val {
  font-size: 3.2rem;
  font-weight: 700;
  line-height: 1;
  transition: color 0.4s;
  color: #9ca3af;
}
.hero-lbl {
  font-size: 0.85rem;
  font-weight: 700;
  color: #374151;
  margin-top: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.hero-sub { font-size: 0.75rem; color: var(--gray); margin-top: 4px; }

/* ── CARDS NAVIGATION ────────────────────────────────── */
.nav-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px;
}
.nav-card {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  border-left: 4px solid var(--cyan);
  transition: box-shadow 0.15s, transform 0.1s;
}
.nav-card:hover { box-shadow: 0 4px 18px rgba(0,0,0,0.12); transform: translateY(-1px); }
.nav-card-alert { border-left-color: #f59e0b; }
.nav-card-icon { font-size: 1.8rem; flex-shrink: 0; }
.nav-card-body { flex: 1; }
.nav-card-title { font-weight: 700; font-size: 0.92rem; color: #1a1a1a; }
.nav-card-desc  { font-size: 0.78rem; color: var(--gray); margin-top: 3px; }
.nav-card-count {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--cyan-dark);
  white-space: nowrap;
}
.nav-card-count-alert { color: #ef4444; }

/* ── FILTRES ─────────────────────────────────────────── */
.filters-bar {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 14px 18px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: flex-end;
  margin-bottom: 16px;
}
.filters-bar label { font-size: 0.8rem; font-weight: 700; color: #555; white-space: nowrap; }
.filters-bar select,
.filters-bar input[type="text"],
.filters-bar input[type="date"] {
  padding: 7px 11px;
  border-radius: 7px;
  border: 1.5px solid #d0e8f0;
  font-size: 0.86rem;
  font-family: 'Open Sans', sans-serif;
  background: #f9fdff;
  color: #222;
}
.filters-bar select:focus,
.filters-bar input:focus { outline: none; border-color: var(--cyan); }
.filter-group { display: flex; flex-direction: column; gap: 3px; }
.filter-search { flex: 1; min-width: 200px; }

/* ── TABLE ───────────────────────────────────────────── */
.table-wrap {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow-x: auto;
  max-height: calc(100vh - 260px);
  overflow-y: auto;
  scrollbar-gutter: stable;
}
.reviews-table { width: 100%; border-collapse: collapse; font-size: 0.83rem; table-layout: fixed; }

thead th {
  background: #1a3a4a;
  color: white;
  padding: 11px 12px;
  text-align: left;
  font-weight: 600;
  white-space: nowrap;
  font-size: 0.76rem;
  letter-spacing: 0.3px;
  position: sticky;
  top: 0;
  z-index: 2;
}
thead th:first-child { border-radius: 10px 0 0 0; }
thead th:last-child  { border-radius: 0 10px 0 0; }

tbody td {
  padding: 11px 12px;
  border-bottom: 1px solid #f0f4f6;
  vertical-align: middle;
  overflow: hidden;
}
tbody td:last-child {
  overflow: visible;
  padding: 6px 4px;
  width: 38px;
  min-width: 38px;
}
tbody tr.review-main-row:nth-child(4n+1) td { background: #fafcfd; }
tbody tr.review-main-row:nth-child(4n+3) td { background: #ffffff; }
tbody tr.review-main-row:hover td {
  background: #edf7fb !important;
  border-bottom-color: #c8e8f2;
}
tbody tr.review-main-row:hover td:first-child {
  box-shadow: inset 3px 0 0 var(--cyan);
}
tbody tr:last-child td { border-bottom: none; }

/* Largeurs fixes des colonnes */
.col-w-date    { width: 88px; }
.col-w-nom     { width: 140px; }
.col-w-badge   { width: 110px; }
.col-w-score   { width: 60px; text-align: center; }
.col-w-comment { width: 320px; min-width: 160px; }

.col-date { white-space: nowrap; font-size: 0.74rem; color: var(--gray); }
.col-nom  { font-weight: 700; font-size: 0.84rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Commentaire : 2 lignes max */
.col-comment {
  color: #444;
  font-size: 0.79rem;
  line-height: 1.5;
  font-style: italic;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  white-space: normal;
}

.col-reponse {
  margin-top: 7px;
  padding: 6px 10px;
  background: #f0fdf4;
  border-left: 3px solid #22c55e;
  border-radius: 0 6px 6px 0;
  color: #166534;
  font-size: 0.75rem;
  line-height: 1.45;
  font-style: normal;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.col-comment.expanded,
.col-reponse.expanded {
  -webkit-line-clamp: unset;
  overflow: visible;
  white-space: pre-wrap;
  user-select: text;
}
.reponse-wrap { margin-top: 7px; }
.reponse-wrap .col-reponse { margin-top: 0; }
.btn-reponse-expand {
  margin-top: 4px;
  padding: 2px 8px;
  font-size: 0.68rem;
  font-weight: 600;
  color: #15803d;
  background: #ecfdf5;
  border: 1px solid #bbf7d0;
  border-radius: 5px;
  cursor: pointer;
}
.btn-reponse-expand:hover { background: #d1fae5; }
.reponse-label {
  font-weight: 700;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-right: 5px;
  color: #15803d;
}

.count-label { font-size: 0.8rem; color: var(--gray); margin-top: 10px; padding-left: 2px; }

/* ── TRI COLONNES ────────────────────────────────────── */
th.sortable {
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
  transition: background 0.15s;
}
th.sortable:hover { background: #244d61; }
th.sortable::after { content: ' ⇅'; opacity: 0.25; font-size: 0.65rem; }
th.sort-asc::after  { content: ' ▲'; opacity: 1; color: #7ee8f8; }
th.sort-desc::after { content: ' ▼'; opacity: 1; color: #7ee8f8; }

/* ── BOUTON EXPAND ───────────────────────────────────── */
.btn-expand {
  background: none;
  border: 1.5px solid #d1d5db;
  border-radius: 6px;
  width: 26px; height: 26px;
  font-size: 0.55rem;
  cursor: pointer;
  color: #b0bec5;
  transition: all 0.15s;
  line-height: 1;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto;
}
.btn-expand:hover { border-color: var(--cyan); color: var(--cyan); background: var(--cyan-pale); }
.btn-expand.open  { border-color: var(--cyan); color: var(--cyan); background: var(--cyan-pale); }

/* ── LIGNE DÉTAIL ────────────────────────────────────── */
.review-detail-row > td {
  background: #f0f7fa !important;
  padding: 14px 16px 14px 24px;
  border-bottom: 2px solid #d0e8f0;
}
.detail-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
}
.detail-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: white;
  border: 1px solid #ddeef4;
  border-radius: 8px;
  padding: 8px 14px;
  min-width: 80px;
  gap: 4px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}
.detail-item.detail-wide {
  flex-direction: row;
  min-width: 160px;
  justify-content: space-between;
}
.detail-label {
  color: var(--gray);
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

/* ── BOUTON AFFICHER ─────────────────────────────────── */
.btn-afficher {
  background: none;
  border: 1.5px solid #d1d5db;
  border-radius: 20px;
  padding: 3px 8px;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  color: #9ca3af;
  transition: all 0.15s;
  white-space: nowrap;
  font-family: 'Open Sans', sans-serif;
  display: flex; align-items: center; gap: 3px;
}
.btn-afficher:hover { border-color: var(--cyan); color: var(--cyan); background: var(--cyan-pale); }
.btn-afficher.active {
  background: var(--cyan-pale);
  border-color: var(--cyan);
  color: var(--cyan-dark);
  font-weight: 700;
}

/* ── BADGES ──────────────────────────────────────────── */
.badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 20px;
  font-size: 0.7rem;
  font-weight: 700;
  white-space: nowrap;
}
.badge-google      { background: #e8f0fe; color: #1a73e8; }
.badge-formulaire  { background: #e6f9f0; color: #1e8a5e; }
.badge-guestsuite  { background: #fff3e0; color: #e65100; }
.badge-pagesjaunes { background: #fffde7; color: #f57f17; }
.badge-tripadvisor { background: #e8faf3; color: #00aa6c; }
.badge-autre       { background: #f3f4f6; color: #6b7280; }

.sejour-badge {
  display: inline-block; padding: 2px 8px; border-radius: 20px;
  font-size: 0.7rem; font-weight: 600; white-space: nowrap;
}
.sejour-famille { background: #dbeafe; color: #1d4ed8; }
.sejour-couple  { background: #fce7f3; color: #9d174d; }
.sejour-amis    { background: #dcfce7; color: #15803d; }
.sejour-seul    { background: #f3f4f6; color: #374151; }
.sejour-autre   { background: #fef9c3; color: #854d0e; }

.sc {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 24px; border-radius: 6px;
  font-weight: 700; font-size: 0.79rem; color: white;
}
.sc-na  { background: #e5e7eb; color: #9ca3af; }
.sc-low { background: #ef4444; }
.sc-mid { background: var(--orange); }
.sc-ok  { background: #84cc16; }
.sc-hi  { background: #22c55e; }

/* ── STATISTIQUES ────────────────────────────────────── */
.stats-section-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
@media (max-width: 900px) { .stats-section-grid { grid-template-columns: 1fr; } }

.stats-block {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px 20px;
}
.block-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #1a1a1a;
  margin-bottom: 18px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--cyan-pale);
}

/* Critères */
.criteria-list { display: flex; flex-direction: column; gap: 12px; }
.criteria-row  { display: flex; align-items: center; gap: 10px; }
.criteria-label { font-size: 0.83rem; font-weight: 600; width: 120px; flex-shrink: 0; }
.criteria-bar-wrap {
  flex: 1; height: 10px; background: #f0f5f7;
  border-radius: 5px; overflow: hidden;
}
.criteria-bar-fill { height: 100%; border-radius: 5px; transition: width 0.5s ease; }
.criteria-val { font-size: 0.88rem; font-weight: 700; width: 30px; text-align: right; flex-shrink: 0; }

/* Distribution */
.dist-chart { display: flex; flex-direction: column; gap: 8px; }
.dist-row   { display: flex; align-items: center; gap: 10px; }
.dist-label { font-size: 0.82rem; font-weight: 700; width: 18px; text-align: right; flex-shrink: 0; color: #374151; }
.dist-bar-wrap {
  flex: 1; height: 18px; background: #f0f5f7;
  border-radius: 4px; overflow: hidden;
}
.dist-bar-fill { height: 100%; border-radius: 4px; transition: width 0.5s ease; }
.dist-count { font-size: 0.78rem; font-weight: 600; color: var(--gray); width: 36px; flex-shrink: 0; }

/* Top / Flop */
.top-flop-list { display: flex; flex-direction: column; gap: 10px; }
.top-flop-item { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: #f8fafb; border-radius: 8px; }
.rank       { font-size: 1.1rem; }
.rank-flop  { color: #ef4444; font-weight: 700; font-size: 0.9rem; }
.tf-label   { flex: 1; font-size: 0.85rem; font-weight: 600; }
.tf-val     { font-size: 1rem; font-weight: 700; }

/* ── PAR PLATEFORME ──────────────────────────────────── */
.platform-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 18px;
}
.platform-card {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.platform-card-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  font-weight: 700;
}
.badge-google.platform-card-header      { background: #e8f0fe; color: #1a73e8; }
.badge-formulaire.platform-card-header  { background: #e6f9f0; color: #1e8a5e; }
.badge-guestsuite.platform-card-header  { background: #fff3e0; color: #e65100; }
.badge-pagesjaunes.platform-card-header { background: #fffde7; color: #f57f17; }
.badge-tripadvisor.platform-card-header { background: #e8faf3; color: #00aa6c; }
.badge-autre.platform-card-header       { background: #f3f4f6; color: #6b7280; }

.platform-card-icon  { font-size: 1.3rem; }
.platform-card-name  { flex: 1; font-size: 0.95rem; }
.platform-card-count { font-size: 0.8rem; opacity: 0.75; }

.platform-card-body { padding: 16px; }
.platform-note {
  font-size: 2.8rem; font-weight: 700; text-align: center;
  margin-bottom: 14px; line-height: 1;
}
.platform-note-lbl { font-size: 1rem; color: var(--gray); font-weight: 400; }

.platform-criteria { display: flex; flex-direction: column; gap: 8px; }
.pcrit-row   { display: flex; align-items: center; gap: 8px; }
.pcrit-icon  { font-size: 0.85rem; flex-shrink: 0; }
.pcrit-bar-wrap { flex: 1; height: 7px; background: #f0f5f7; border-radius: 4px; overflow: hidden; }
.pcrit-bar-fill { height: 100%; border-radius: 4px; transition: width 0.5s; }
.pcrit-val   { font-size: 0.78rem; font-weight: 700; width: 28px; text-align: right; color: #374151; }

/* ── TENDANCES ───────────────────────────────────────── */
.tendances-wrap {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px 20px;
}

.month-chart {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  height: 180px;
  padding-bottom: 0;
  overflow-x: auto;
}
.month-col {
  display: flex; flex-direction: column; align-items: center;
  min-width: 42px; flex-shrink: 0;
}
.month-bar-wrap {
  flex: 1; width: 100%; display: flex; flex-direction: column;
  align-items: center; justify-content: flex-end; height: 140px;
  position: relative;
}
.month-bar-val {
  font-size: 0.6rem; font-weight: 700; color: var(--gray);
  margin-bottom: 2px;
}
.month-bar {
  width: 28px; border-radius: 4px 4px 0 0;
  min-height: 4px;
  transition: height 0.5s ease;
}
.month-lbl   { font-size: 0.62rem; color: #9ca3af; margin-top: 4px; white-space: nowrap; }
.month-count { font-size: 0.58rem; color: #c4d0d8; }

/* ── SUIVI 30 JOURS ──────────────────────────────────── */
.last30-chart {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 140px;
  overflow-x: auto;
  padding-bottom: 0;
}
.l30-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  min-width: 26px;
  cursor: default;
}
.l30-col.l30-today .l30-label {
  color: var(--cyan-dark);
  font-weight: 700;
}
.l30-count {
  font-size: 0.6rem;
  font-weight: 700;
  color: #374151;
  height: 14px;
  line-height: 14px;
}
.l30-bar-wrap {
  width: 100%;
  height: 100px;
  display: flex;
  align-items: flex-end;
  padding: 0 1px;
}
.l30-bar {
  width: 100%;
  border-radius: 3px 3px 0 0;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column-reverse;
  transition: height 0.4s ease;
}
.l30-label {
  font-size: 0.58rem;
  color: #9ca3af;
  margin-top: 4px;
  white-space: nowrap;
}
.l30-stats {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 0.82rem;
  margin-top: 14px;
  flex-wrap: wrap;
}
.l30-stat   { color: #374151; }
.l30-sep    { color: #d1d5db; }
.l30-legend {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 10px;
}
.l30-legend-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.78rem;
  color: #555;
}
.l30-legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 3px;
  flex-shrink: 0;
}

/* ── CARDS ANNUELLES ─────────────────────────────────── */
.year-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
@media (max-width: 900px) { .year-cards { grid-template-columns: 1fr 1fr; } }

.year-card {
  background: #f8fafb;
  border-radius: 10px;
  border: 1.5px solid #e0edf2;
  padding: 18px 16px;
}
.year-card-current {
  background: white;
  border-color: var(--cyan);
  box-shadow: 0 2px 12px rgba(41,182,213,0.15);
}
.year-card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}
.year-label {
  font-size: 1.1rem;
  font-weight: 700;
  color: #374151;
}
.year-badge {
  font-size: 0.65rem;
  font-weight: 700;
  background: var(--cyan-pale);
  color: var(--cyan-dark);
  padding: 2px 7px;
  border-radius: 10px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
.year-note {
  font-size: 2.4rem;
  font-weight: 700;
  line-height: 1;
  margin-bottom: 2px;
}
.year-count {
  font-size: 0.75rem;
  color: var(--gray);
  margin-bottom: 14px;
}
.year-criteria { display: flex; flex-direction: column; gap: 7px; }
.ycrit-row     { display: flex; align-items: center; gap: 7px; }
.ycrit-label   { font-size: 0.75rem; width: 100px; flex-shrink: 0; color: #555; }
.ycrit-bar-wrap { flex: 1; height: 7px; background: #e5e7eb; border-radius: 4px; overflow: hidden; }
.ycrit-bar-fill { height: 100%; border-radius: 4px; transition: width 0.5s; }
.ycrit-val     { font-size: 0.75rem; font-weight: 700; width: 26px; text-align: right; color: #374151; }

.season-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
@media (max-width: 700px) { .season-cards { grid-template-columns: 1fr 1fr; } }

.season-card {
  background: #f8fafb;
  border-radius: 10px;
  padding: 20px;
  text-align: center;
  border: 1.5px solid #e0edf2;
}
.season-icon  { font-size: 2rem; margin-bottom: 6px; }
.season-name  { font-size: 0.82rem; font-weight: 700; color: #374151; margin-bottom: 6px; }
.season-note  { font-size: 2rem; font-weight: 700; }
.season-count { font-size: 0.75rem; color: var(--gray); margin-top: 4px; }

/* ── ALERTES ─────────────────────────────────────────── */
.alertes-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
@media (max-width: 900px) { .alertes-grid { grid-template-columns: 1fr; } }

.alertes-block {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px;
}

.alerte-card {
  border: 1.5px solid #e5e7eb;
  border-radius: 8px;
  padding: 12px 14px;
  margin-bottom: 10px;
  transition: border-color 0.15s;
}
.alerte-card:last-child { margin-bottom: 0; }
.alerte-card-bad { border-left: 4px solid #ef4444; }

.alerte-card-top {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}
.alerte-nom   { font-weight: 700; font-size: 0.88rem; }
.alerte-date  { font-size: 0.75rem; color: var(--gray); }
.alerte-comment {
  font-size: 0.8rem; color: #555; font-style: italic;
  line-height: 1.45; margin-top: 4px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.alerte-empty { color: var(--gray); font-size: 0.85rem; padding: 16px 0; text-align: center; }

/* Boutons sur fond CLAIR (cartes, modales).
   ⚠ Ne pas réutiliser `.btn-action` ici : elle est faite pour la barre d'en-tête
   turquoise — texte blanc sur fond blanc translucide. Sur une carte blanche le
   bouton existe, fonctionne, et reste parfaitement invisible. C'est exactement
   ce qui est arrivé au bouton « Créer la clé ». */
.btn-clair {
  padding: 7px 14px;
  border-radius: 7px;
  border: 1.5px solid var(--cyan);
  background: var(--cyan);
  color: var(--white);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  font-family: 'Open Sans', sans-serif;
  transition: background 0.15s, border-color 0.15s;
  white-space: nowrap;
}
.btn-clair:hover { background: var(--cyan-dark); border-color: var(--cyan-dark); }
.btn-clair:disabled { opacity: 0.45; cursor: not-allowed; }
.btn-clair.secondaire {
  background: var(--white);
  color: var(--cyan-dark);
}
.btn-clair.secondaire:hover { background: var(--cyan-pale); }
.btn-clair.danger {
  background: var(--white);
  color: #b91c1c;
  border-color: #fca5a5;
}
.btn-clair.danger:hover { background: #fee2e2; }
