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

:root {
  --navy:      #1c3d5a;
  --navy-dk:   #112840;
  --coral:     #d97040;
  --yellow:    #f59e0b;
  --yellow-dk: #d97706;
  --yellow-lt: #fffbeb;
  --sand:      #f8f6f2;
  --white:     #ffffff;
  --text:      #1a1a2e;
  --muted:     #546475;    /* darkened from #6b7a8d — WCAG AA on white: ~6:1 */
  --border:    #e4e8ed;
  --ok:        #1a6e3c;
  --ok-bg:     #edfaf3;
  --warn:      #92400e;
  --warn-bg:   #fef3c7;
  --err:       #991b1b;
  --err-bg:    #fef2f2;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
  --shadow:    0 4px 16px rgba(0,0,0,0.08);
  --radius:    12px;
  --radius-sm: 8px;
}

body {
  font-family: system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
  background: var(--sand);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.6;
  font-size: 15px;
}

/* ── Focus visible (anneau jaune) ─────────────────────── */
:focus-visible {
  outline: 2px solid var(--yellow);
  outline-offset: 3px;
  border-radius: 3px;
}
textarea:focus-visible { outline: none; } /* géré par .panel:focus-within */

/* ── En-tête ──────────────────────────────────────────── */
header {
  background: linear-gradient(135deg, var(--navy-dk) 0%, var(--navy) 100%);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
nav {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 1.25rem;
  height: 54px;
  display: flex;
  align-items: center;
}
.brand { font-size: 1rem; font-weight: 700; color: #fff; text-decoration: none; letter-spacing: -0.01em; }
.brand-sub { font-size: 0.8rem; font-weight: 400; color: rgba(255,255,255,0.55); margin-left: 0.6rem; }
.nav-actions { margin-left: auto; display: flex; align-items: center; gap: 0.75rem; }
.nav-link {
  font-size: 0.82rem;
  font-weight: 600;
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-sm);
  transition: color 0.15s, background 0.15s;
}
.nav-link:hover { color: #fff; background: rgba(255,255,255,0.12); }
.alpha-badge {
  background: var(--coral);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  text-transform: uppercase;
}

/* ── Contenu ──────────────────────────────────────────── */
main {
  flex: 1;
  max-width: 900px;
  width: 100%;
  margin: 0 auto;
  padding: 1.5rem 1.25rem;
}

/* ── Intro SEO ────────────────────────────────────────── */
.seo-intro {
  text-align: center;
  margin-bottom: 1.5rem;
}
.seo-intro h1 {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 0.35rem;
  letter-spacing: -0.01em;
}
.seo-intro p {
  font-size: 0.9rem;
  color: var(--muted);
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.6;
}
.seo-intro a { color: var(--navy); text-decoration: underline; text-underline-offset: 2px; }

/* ── Direction toggle (pill container) ───────────────── */
.direction-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin: 0 auto 1.25rem;
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: 999px;
  padding: 0.3rem;
  box-shadow: var(--shadow-sm);
  width: fit-content;
  max-width: 100%;
}
.dir-btn {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 1.1rem;
  border-radius: 999px;
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
  font-family: inherit;
}
.dir-btn:hover:not(:disabled) { background: var(--yellow-lt); color: var(--yellow-dk); }
.dir-btn.active { background: var(--yellow); color: var(--navy); font-weight: 600; }
.dir-btn:disabled { opacity: 0.45; cursor: not-allowed; }
.dir-sep { color: var(--muted); font-size: 1rem; user-select: none; padding: 0 0.1rem; }

/* Badge "Bientôt" sur le bouton désactivé */
.badge-soon {
  display: inline-block;
  background: #e5e7eb;
  color: #6b7280;
  font-size: 0.6rem;
  font-weight: 700;
  padding: 0.1rem 0.4rem;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  vertical-align: middle;
}

/* ── Grille côte à côte ───────────────────────────────── */
.translation-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}
@media (max-width: 620px) {
  .translation-grid { grid-template-columns: 1fr; }
  .direction-bar { flex-wrap: wrap; }
}

.panel {
  background: var(--white);
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: border-color 0.15s, box-shadow 0.15s;
  min-height: 200px;
}
.panel:focus-within {
  border-color: var(--yellow);
  box-shadow: 0 0 0 3px rgba(245,158,11,0.15);
}

.panel-header {
  padding: 0.6rem 1rem;
  border-bottom: 1px solid var(--border);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: #fafbfc;
  min-height: 38px;
}
.panel-header-right {
  margin-left: auto;
  display: flex;
  gap: 0.3rem;
  align-items: center;
}

textarea {
  flex: 1;
  width: 100%;
  min-height: 160px;
  padding: 1rem;
  border: none;
  resize: vertical;
  font-size: 1.1rem;
  font-family: inherit;
  background: transparent;
  outline: none;
  color: var(--text);
  line-height: 1.7;
}
textarea::placeholder { color: #c0c8d2; }

.result-area {
  flex: 1;
  min-height: 160px;
  padding: 1rem;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--navy);
  line-height: 1.7;
  white-space: pre-wrap;
  word-break: break-word;
}
.result-area.empty { color: #c0c8d2; font-weight: 400; font-size: 1rem; font-style: italic; }

/* Mots inconnus surlignés */
.inconnu {
  background: var(--warn-bg);
  color: var(--warn);
  border-radius: 4px;
  padding: 0 4px;
  font-size: 0.92em;
  font-weight: 600;
}

/* ── Panneau d'analyse ───────────────────────────────── */
.analyse-wrap {
  border-top: 1px solid var(--border);
  padding: 0.75rem 1rem;
  font-size: 0.82rem;
  background: #fafbfc;
}
.cov-bar-wrap { margin-bottom: 0.75rem; }
.cov-label { font-size: 0.78rem; color: var(--muted); margin-bottom: 0.3rem; }
.cov-bar { height: 6px; background: var(--border); border-radius: 999px; overflow: hidden; }
.cov-fill { height: 100%; border-radius: 999px; transition: width 0.4s; width: 0; }
.cov-ok   { background: var(--ok); }
.cov-warn { background: var(--coral); }
.cov-err  { background: var(--err); }
.clause-block + .clause-block { border-top: 1px solid var(--border); padding-top: 0.5rem; margin-top: 0.5rem; }
.clause-meta { display: flex; flex-wrap: wrap; gap: 0.3rem; margin-bottom: 0.5rem; }
.badge { font-size: 0.7rem; font-weight: 700; padding: 0.15rem 0.5rem; border-radius: 999px; }
.badge-temps { background: #dbeafe; color: #1d4ed8; }
.badge-mode  { background: #f3f4f6; color: #555; }
.badge-neg   { background: var(--err-bg); color: var(--err); }
.badge-quest { background: var(--warn-bg); color: var(--warn); }
.token-table { width: 100%; border-collapse: collapse; margin-top: 0.25rem; }
.token-table th { text-align: left; padding: 0.2rem 0.5rem; color: var(--muted); font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; border-bottom: 1px solid var(--border); }
.token-table td { padding: 0.25rem 0.5rem; border-bottom: 1px solid #f0f0f0; vertical-align: top; }
.token-ok  td:first-child { color: var(--ok); font-weight: 600; }
.token-unk td:first-child { color: var(--warn); font-weight: 600; }
.token-skip { opacity: 0.45; }
.tok-role { color: var(--muted); }

/* Bouton copier / analyse */
.copy-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.2rem 0.5rem;
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-size: 0.78rem;
  font-family: inherit;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  transition: color 0.15s, background 0.15s;
}
.copy-btn:hover { color: var(--navy); background: var(--border); }
.copy-btn.copied   { color: var(--ok); }
.copy-btn.playing  { color: var(--yellow-dk); animation: pulse 1s ease-in-out infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.5; } }

/* ── Bouton traduire ──────────────────────────────────── */
.form-actions {
  display: flex;
  justify-content: center;
  margin-bottom: 1.25rem;
}
.btn-primary {
  padding: 0.7rem 2.5rem;
  background: var(--navy);
  color: #fff;
  border: none;
  border-radius: 999px;
  font-size: 1rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.btn-primary:hover:not(:disabled) { background: var(--navy-dk); }
.btn-primary:active:not(:disabled) { transform: scale(0.98); }
.btn-primary:disabled { opacity: 0.55; cursor: not-allowed; }

/* ── Spinner ──────────────────────────────────────────── */
.spinner {
  display: none;
  width: 16px; height: 16px;
  border: 2px solid rgba(255,255,255,0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
.btn-primary.loading .spinner { display: block; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Alerte ───────────────────────────────────────────── */
.alert {
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
  font-size: 0.875rem;
  margin-bottom: 1rem;
  display: none;
}
.alert.visible { display: block; }
.alert-warn { background: var(--warn-bg); color: var(--warn); border: 1px solid #fde68a; }
.alert-err  { background: var(--err-bg);  color: var(--err);  border: 1px solid #fecaca; }

/* ── Info bas de page ─────────────────────────────────── */
.info-strip {
  font-size: 0.78rem;
  color: var(--muted);
  text-align: center;
  padding: 0.25rem 0 0;
}

/* ── Bloc SEO sous le traducteur ──────────────────────── */
.seo-content {
  border-top: 1px solid var(--border);
  margin-top: 1.5rem;
  padding-top: 1.25rem;
}
.seo-content h2 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 0.6rem;
}
.seo-content p {
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.75;
  margin-bottom: 0.5rem;
}
.seo-content strong { color: var(--text); }
.seo-content a { color: var(--navy); text-decoration: underline; text-underline-offset: 2px; font-size: 0.875rem; }

/* Utilitaire : état initial masqué */
.hidden { display: none !important; }

/* ── Footer ───────────────────────────────────────────── */
footer {
  border-top: 1px solid var(--border);
  padding: 1rem 1.25rem;
  text-align: center;
  font-size: 0.78rem;
  color: var(--muted);
}
footer a { color: var(--muted); text-decoration: none; }
footer a:hover { color: var(--navy); }

/* ── Page À propos ────────────────────────────────────── */
.about-main {
  flex: 1;
  max-width: 720px;
  width: 100%;
  margin: 0 auto;
  padding: 2rem 1.25rem;
}
.about-content h1 {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 2rem;
  letter-spacing: -0.02em;
}
.about-section {
  margin-bottom: 2rem;
}
.about-section h2 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 0.75rem;
  padding-bottom: 0.4rem;
  border-bottom: 2px solid var(--yellow);
  display: inline-block;
}
.about-section p {
  margin-bottom: 0.75rem;
  color: var(--text);
  font-size: 0.95rem;
  line-height: 1.8;
}
.about-section strong { color: var(--navy); }
.about-h3 {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 1.25rem 0 0.5rem;
}
.about-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.about-list li {
  font-size: 0.95rem;
  color: var(--text);
  line-height: 1.6;
  padding-left: 1.4rem;
  position: relative;
}
.about-list li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--yellow-dk);
  font-weight: 700;
}
.about-phases li { color: var(--muted); }
.about-phases li::before { content: '○'; color: var(--border); font-size: 0.8rem; top: 0.1rem; }
.phase-done { color: var(--muted) !important; text-decoration: line-through; }
.phase-done::before { content: '✓' !important; color: var(--ok) !important; text-decoration: none; }
.phase-active { color: var(--navy) !important; font-weight: 600; }
.phase-active::before { content: '◉' !important; color: var(--yellow-dk) !important; }
.btn-back {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.6rem 1.5rem;
  background: var(--navy);
  color: #fff;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  transition: background 0.15s;
  margin-top: 0.5rem;
}
.btn-back:hover { background: var(--navy-dk); }
.contact-link {
  display: inline-block;
  font-size: 1rem;
  font-weight: 600;
  color: var(--navy);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ── Grammaire étendue (panel debug) ─────────────────────────────────────── */
.gram-ext-block {
  margin-top: 1rem;
  border-top: 1px solid var(--border, #e2e8f0);
  padding-top: 0.75rem;
}
.gram-ext-title {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--navy, #1e3a5f);
  margin-bottom: 0.5rem;
}
.gram-ext-row {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.35rem;
  font-size: 0.82rem;
  padding: 0.25rem 0;
  border-bottom: 1px solid var(--border, #e2e8f0);
}
.gram-ext-row:last-child { border-bottom: none; }
.gram-ext-fr     { font-weight: 600; min-width: 3rem; }
.gram-ext-moteur { color: #e53e3e; text-decoration: line-through; font-family: monospace; }
.gram-ext-arrow  { color: #718096; }
.gram-ext-sugg   { color: #276749; font-weight: 700; font-family: monospace; }
.gram-ext-note   { color: #718096; font-style: italic; font-size: 0.75rem; }

/* ── Badge IA locale ─────────────────────────────────────────────────────── */
.badge-ia {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.2rem 0.6rem;
  background: #6b46c1;
  color: #fff;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.badge-ia.hidden { display: none; }

/* ── Debug IA locale (panel analyse) ────────────────────────────────────── */
.ia-debug-block {
  margin-top: 1rem;
  border: 1.5px solid #6b46c1;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  background: #faf5ff;
}
.ia-debug-title {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #6b46c1;
  margin-bottom: 0.6rem;
}
.ia-debug-row {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  font-size: 0.82rem;
  margin-bottom: 0.3rem;
}
.ia-debug-label {
  font-weight: 600;
  color: #553c9a;
  min-width: 7rem;
  flex-shrink: 0;
}
.ia-debug-section {
  margin-top: 0.6rem;
}
.ia-debug-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
  margin-top: 0.3rem;
}
.ia-debug-table th {
  background: #e9d8fd;
  padding: 0.2rem 0.5rem;
  text-align: left;
  font-size: 0.72rem;
}
.ia-debug-table td {
  padding: 0.15rem 0.5rem;
  border-bottom: 1px solid #e9d8fd;
  font-family: monospace;
}
.ia-debug-pre {
  background: #1a1a2e;
  color: #e2e8f0;
  border-radius: 6px;
  padding: 0.6rem 0.8rem;
  font-size: 0.75rem;
  white-space: pre-wrap;
  word-break: break-word;
  margin-top: 0.3rem;
  max-height: 200px;
  overflow-y: auto;
}

/* ── Page Dictionnaire ───────────────────────────────────────────────────── */
.dico-main {
  flex: 1;
  max-width: 900px;
  width: 100%;
  margin: 0 auto;
  padding: 1.5rem 1.25rem;
}
.dico-header { margin-bottom: 1.25rem; }
.dico-header h1 {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--navy);
  letter-spacing: -0.01em;
  margin-bottom: 0.3rem;
}
.dico-header p { font-size: 0.88rem; color: var(--muted); }

.dico-stat-row { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-bottom: 1.1rem; }
.dico-stat-pill {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.4rem 0.85rem;
  font-size: 0.82rem;
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
}
.dico-stat-pill strong { color: var(--navy); font-size: 1rem; font-weight: 800; }
.dico-stat-pill span   { color: var(--muted); font-size: 0.75rem; }

.dico-note-warn {
  background: var(--warn-bg);
  border: 1px solid #fde68a;
  border-radius: var(--radius-sm);
  padding: 0.7rem 1rem;
  font-size: 0.84rem;
  color: var(--warn);
  margin-bottom: 1.1rem;
  line-height: 1.6;
}

.dico-search-bar { position: relative; margin-bottom: 0.6rem; }
.dico-search-bar input {
  width: 100%;
  padding: 0.65rem 1rem 0.65rem 2.5rem;
  border: 1.5px solid var(--border);
  border-radius: 999px;
  font-size: 0.95rem;
  font-family: inherit;
  background: var(--white);
  color: var(--text);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.dico-search-bar input:focus {
  border-color: var(--yellow);
  box-shadow: 0 0 0 3px rgba(245,158,11,0.15);
}
.dico-search-icon {
  position: absolute;
  left: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  pointer-events: none;
}
.dico-search-count {
  font-size: 0.78rem;
  color: var(--muted);
  text-align: right;
  margin-bottom: 0.75rem;
  min-height: 1.2em;
}

.dico-wrap {
  background: var(--white);
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  overflow: hidden;
}
.dico-table { width: 100%; border-collapse: collapse; }
.dico-table thead th {
  padding: 0.6rem 1rem;
  text-align: left;
  background: #f1f5f9;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.dico-table tbody tr { border-bottom: 1px solid #f4f6f8; transition: background 0.1s; }
.dico-table tbody tr:last-child { border-bottom: none; }
.dico-table tbody tr:hover { background: #f8fafc; }
.dico-table td { padding: 0.6rem 1rem; font-size: 0.9rem; vertical-align: middle; }
.dico-td-fr  { font-weight: 600; color: var(--text); }
.dico-td-fut { font-weight: 700; color: var(--navy); font-family: "Courier New", monospace; }
.dico-td-type { color: var(--muted); font-size: 0.8rem; white-space: nowrap; }
.dico-td-sens { font-size: 0.78rem; color: var(--muted); font-style: italic; display: block; margin-top: 0.1rem; }

.badge-ok {
  display: inline-flex; align-items: center; gap: 0.2rem;
  background: var(--ok-bg); color: var(--ok); border: 1px solid #a7f3d0;
  border-radius: 999px; padding: 0.1rem 0.5rem;
  font-size: 0.7rem; font-weight: 700; white-space: nowrap;
}
.badge-warn-sm {
  display: inline-flex; align-items: center; gap: 0.2rem;
  background: var(--warn-bg); color: var(--warn); border: 1px solid #fde68a;
  border-radius: 999px; padding: 0.1rem 0.5rem;
  font-size: 0.7rem; font-weight: 700; white-space: nowrap;
}
.badge-auto {
  display: inline-flex; align-items: center; gap: 0.2rem;
  background: #eff6ff; color: #2563eb; border: 1px solid #bfdbfe;
  border-radius: 999px; padding: 0.1rem 0.5rem;
  font-size: 0.7rem; font-weight: 700; white-space: nowrap;
}

.dico-empty-msg {
  text-align: center; padding: 3rem 1rem;
  color: var(--muted); font-style: italic; font-size: 0.9rem;
}

/* ── Légende des types ── */
.legend-btn {
  background: none; border: 1px solid var(--muted); border-radius: 50%;
  width: 1.15rem; height: 1.15rem; font-size: 0.62rem; line-height: 1;
  cursor: pointer; color: var(--muted); padding: 0; vertical-align: middle;
  font-style: italic; font-weight: 700;
}
.legend-btn:hover { background: var(--border); color: var(--navy); }

.type-legend {
  background: #f8fafc; border: 1px solid var(--border);
  border-radius: 0.5rem; padding: 0.6rem 1rem; margin-bottom: 0.75rem;
  font-size: 0.8rem;
}
.type-legend.hidden { display: none; }
.legend-table { border-collapse: collapse; width: 100%; }
.legend-table th { text-align: left; padding: 0.2rem 0.6rem; color: var(--muted); font-size: 0.73rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; border-bottom: 1px solid var(--border); }
.legend-table td { padding: 0.2rem 0.6rem; border-bottom: 1px solid var(--border); }
.legend-table tr:last-child td { border-bottom: none; }
.legend-table code { font-size: 0.8rem; background: var(--border); border-radius: 3px; padding: 0.05rem 0.3rem; }

/* ── Sens alternatifs (futunien) ── */
.dico-td-sens-alt { font-size: 0.73rem; color: var(--muted); font-style: italic; display: block; margin-top: 0.15rem; }

.skel {
  height: 14px;
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.2s infinite;
  border-radius: 4px;
}
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.dico-skel-row td { padding: 0.75rem 1rem; }
.skel-w40 { width: 40%; } .skel-w50 { width: 50%; } .skel-w55 { width: 55%; }
.skel-w60 { width: 60%; } .skel-w65 { width: 65%; } .skel-w70 { width: 70%; }
.skel-w75 { width: 75%; } .skel-w80 { width: 80%; } .skel-w90 { width: 90%; }

@media (max-width: 580px) {
  .dico-table thead th:nth-child(3),
  .dico-table td:nth-child(3) { display: none; }
}

/* ── Tri des colonnes du dictionnaire ───────────────────────────────────── */
.dico-table th.sortable { cursor: pointer; user-select: none; white-space: nowrap; }
.dico-table th.sortable:hover { background: rgba(28, 61, 90, 0.07); }
.sort-arrow { font-size: 0.72rem; margin-left: 0.25rem; opacity: 0.35; vertical-align: middle; }
.sort-arrow.active { opacity: 1; color: var(--coral, #d97040); }

/* ── Cookie consent overlay ─────────────────────────────────────────────── */
#cookie-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  align-items: center;
  justify-content: center;
}
#cookie-overlay.visible { display: flex; }
#cookie-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 20, 35, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
#cookie-banner {
  position: relative;
  z-index: 1;
  background: var(--white, #fff);
  border-radius: var(--radius, 12px);
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.25);
  padding: 2rem;
  max-width: 500px;
  width: 92%;
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  max-height: 90vh;
  overflow-y: auto;
  font-family: system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
}
#cookie-banner h2 { font-size: 1.1rem; font-weight: 700; color: var(--navy, #1c3d5a); margin: 0; }
#cookie-banner > p { font-size: 0.9rem; color: var(--muted, #6b7a8d); margin: 0; line-height: 1.5; }
.cookie-actions { display: flex; flex-direction: column; gap: 0.6rem; margin-top: 0.4rem; }
.cookie-actions button {
  width: 100%;
  padding: 0.65rem 1rem;
  border-radius: var(--radius-sm, 8px);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.15s;
  border: none;
  font-family: inherit;
}
.cookie-actions button:hover { opacity: 0.85; }
#btn-accept-all     { background: var(--coral, #d97040); color: #fff; }
#btn-essential-only { background: transparent; color: var(--navy, #1c3d5a); border: 1px solid var(--navy, #1c3d5a) !important; }
#btn-refuse-all     { background: transparent; color: var(--muted, #6b7a8d); border: 1px solid var(--border, #e4e8ed) !important; }
.cookie-legal { font-size: 0.78rem; color: var(--muted, #6b7a8d); text-align: center; margin: 0; }
.cookie-legal a { color: var(--muted, #6b7a8d); text-decoration: underline; }

