

.reglages { text-align: left; max-width: 640px; margin: 0 auto; }
.reglages h2 { font-family: var(--font-display); font-size: 1.25rem; color: #f0f3f6; margin: 4px 0 12px; text-align: center; }

.reglage { margin-bottom: 16px; }
.reglage-titre { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--texte-doux); margin-bottom: 6px; }
.choix { display: flex; flex-wrap: wrap; gap: 8px; }
.choix-btn {
  flex: 1 1 150px; min-height: 52px; padding: 8px 12px;
  font: inherit; font-size: 0.95rem; font-weight: 700; text-align: left; color: var(--texte);
  background: var(--surface-2); border: 2px solid var(--line); border-radius: 8px; cursor: pointer;
}
.choix-court .choix-btn { flex: 1 1 60px; min-height: 46px; text-align: center; font-size: 1.05rem; }
.choix-btn small { display: block; margin-top: 2px; font-size: 0.74rem; font-weight: 500; color: var(--texte-doux); line-height: 1.3; }
.choix-btn:hover { border-color: var(--line-forte); }
.choix-btn[aria-pressed="true"] { border-color: var(--color-mid); background: color-mix(in srgb, var(--color-dark) 30%, var(--surface-2)); color: #fff; }
.choix-btn:focus-visible { outline: 3px solid #f2c14e; outline-offset: 2px; }

.coche { display: flex; align-items: center; gap: 10px; min-height: 44px; font-size: 0.92rem; color: var(--texte); cursor: pointer; }
.coche input { width: 20px; height: 20px; accent-color: var(--color-mid); flex-shrink: 0; }
.reglage-ligne { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; min-height: 44px; font-size: 0.92rem; color: var(--texte); }
.reglage-ligne label { min-width: 90px; font-weight: 600; }
.reglage-ligne select {
  min-height: 40px; padding: 6px 10px; font: inherit; color: var(--texte);
  background: var(--surface-2); border: 1px solid var(--line-forte); border-radius: 8px;
}

.reglages-actions { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 10px; margin: 18px 0 10px; }

#ecran-reglages .reglages-actions {
  position: sticky; bottom: 0; z-index: 4; margin: 10px -8px 8px; padding: 18px 8px 8px;
  background: linear-gradient(180deg, transparent, var(--surface-1) 22%);
}
.reglages-resume { flex-basis: 100%; margin: 0; text-align: center; font-size: 0.8rem; font-weight: 600; color: var(--texte-doux); }
.reglages-resume:empty { display: none; }
@media (max-width: 600px) and (max-height: 700px) {
  .reglages h2 { margin-bottom: 8px; }
  .reglage { margin-bottom: 10px; }
  .choix-btn { min-height: 44px; padding: 6px 10px; flex-basis: 90px; }
  .choix-btn small { display: none; }
}
.variantes-details { margin: -4px 0 14px; font-size: 0.88rem; color: var(--texte-doux); }
.variantes-details summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; font-weight: 700; color: var(--color-light); }
.variantes-note { font-size: 0.8rem; color: var(--texte-faible); margin: 2px 0 6px; }
.variantes-note:empty { display: none; }
.variantes-note a { color: var(--color-light); font-weight: 600; }
.reglages-info { color: #86efac; font-size: 0.88rem; font-weight: 600; text-align: center; }
.reglages-info:empty { display: none; }
.btn-large { min-height: 50px; padding: 12px 30px; font-size: 1.02rem; }
.reglages-erreur { color: #fca5a5; font-size: 0.88rem; font-weight: 600; text-align: center; }
.reglages-erreur:empty { display: none; }
.reglages-liens { text-align: center; font-size: 0.86rem; color: var(--texte-faible); line-height: 2; }
.reglages-liens a { color: var(--color-light); text-decoration: none; font-weight: 600; }
.reglages-liens a:hover { text-decoration: underline; }

.reprise {
  margin-bottom: 18px; padding: 12px 14px;
  background: rgba(242, 193, 78, 0.1); border: 1px solid rgba(242, 193, 78, 0.4); border-radius: 8px;
  text-align: center; font-size: 0.92rem; color: #fde9b0;
}
.reprise-boutons { margin-top: 10px; display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; }


.mes-stats { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.stats-chiffres { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 8px; margin-bottom: 10px; }
.stat { padding: 10px 8px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 8px; text-align: center; }
.stat b { display: block; font-size: 1.3rem; color: #f0f3f6; font-variant-numeric: tabular-nums; }
.stat span { font-size: 0.74rem; color: var(--texte-doux); }
.stat.stat-phare { border-color: rgba(242, 193, 78, 0.5); background: rgba(242, 193, 78, 0.08); }
.stat.stat-phare b { color: #fde9b0; }
.stats-objectif { font-size: 0.86rem; color: #fde9b0; text-align: center; margin: 0 0 10px; }

.ouv-jeu { display: flex; flex-direction: column; gap: 8px; margin-bottom: 14px; }
.ouv-chrono { font-weight: 800; font-size: 1.1rem; font-variant-numeric: tabular-nums; color: #86efac; }
.ouv-chrono.presse { color: #fca5a5; }
.ouv-zone-main { position: static; background: none; }
.ouv-resultat { text-align: center; margin: 10px auto 18px; max-width: 640px; }
.ouv-resultat h2 { font-family: var(--font-display); color: #86efac; margin-bottom: 6px; }
.ouv-solution { margin: 10px 0; padding: 10px; border-radius: 14px; background: var(--tapis, #0f3d26); }


.stats-sous-titre { font-size: 0.92rem; color: var(--color-light); margin: 6px 0 6px; text-align: center; }
.stats-badges { list-style: none; margin: 0 0 10px; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 6px; }
.badge-rami { display: flex; flex-direction: column; gap: 2px; padding: 6px 8px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface-2); opacity: 0.6; }
.badge-rami.obtenu { opacity: 1; border-color: rgba(242, 193, 78, 0.6); }
.badge-rami b { font-size: 0.84rem; color: #f1f5f9; }
.badge-rami span { font-size: 0.74rem; color: var(--texte-faible); }
.stats-tables { width: 100%; border-collapse: collapse; font-size: 0.84rem; }
.stats-tables th, .stats-tables td { padding: 6px 8px; border-bottom: 1px solid var(--line); text-align: right; }
.stats-tables th:first-child, .stats-tables td:first-child { text-align: left; }
.stats-tables th { color: var(--texte-doux); font-weight: 600; }
.stats-note { font-size: 0.8rem; color: var(--texte-faible); margin-top: 8px; text-align: center; }


.salon { max-width: 640px; margin: 0 auto; text-align: center; }
.salon h2 { font-family: var(--font-display); font-size: 1.25rem; color: #f0f3f6; margin: 4px 0 12px; }
.salon-texte { font-size: 0.9rem; color: var(--texte-doux); line-height: 1.5; margin-bottom: 12px; }
.champ { display: flex; flex-direction: column; gap: 4px; text-align: left; margin-bottom: 12px; }
.champ label { font-size: 0.8rem; font-weight: 700; color: var(--texte-doux); }
.champ input {
  min-height: 46px; padding: 8px 12px; font: inherit; font-size: 1rem; color: var(--texte);
  background: var(--surface-2); border: 1px solid var(--line-forte); border-radius: 8px;
}
.champ input:focus { outline: 2px solid var(--color-mid); outline-offset: 1px; }
.champ input[readonly] { color: var(--texte-doux); }
.champ-code input { text-transform: uppercase; letter-spacing: 0.4em; text-align: center; font-weight: 800; font-size: 1.3rem; }
.salon-onglets { display: flex; gap: 8px; margin-bottom: 16px; }
.salon-onglets .choix-btn { text-align: center; flex: 1; }
.salon-panneau { text-align: left; }
.code-salon {
  display: inline-block; margin: 6px 0 4px; padding: 8px 22px;
  font-family: ui-monospace, Consolas, monospace; font-size: 1.8rem; font-weight: 800; letter-spacing: 0.3em; color: #86efac;
  background: var(--surface-2); border: 1px solid var(--line-forte); border-radius: 10px;
}
.salon-partage { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin: 8px 0 16px; }
.salon-table {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 8px;
  max-width: 520px; margin: 0 auto 14px; padding: 14px; border-radius: 22px;
  background: radial-gradient(ellipse at center, #17573a 0%, #0f3d26 78%); border: 2px solid #1b5e3a;
}
.salon-siege {
  flex: 1 1 130px; min-height: 56px; padding: 6px 8px; border-radius: 10px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  font: inherit; font-size: 0.86rem; font-weight: 700; color: #ecfdf5;
  background: rgba(0, 0, 0, 0.3); border: 1px solid rgba(255, 255, 255, 0.16);
  overflow: hidden; text-overflow: ellipsis; max-width: 100%;
}
.salon-siege small { font-size: 0.68rem; font-weight: 600; color: #bbf7d0; }
.salon-siege.libre { border-style: dashed; color: #bbf7d0; cursor: pointer; }
.salon-siege.libre:hover { border-color: #f2c14e; color: #fde9b0; }
.salon-siege.moi { border-color: #f2c14e; }
.salon-actions { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.salon-note { font-size: 0.8rem; color: var(--texte-faible); }
.salon-note:empty { display: none; }
.salon-erreur { color: #fca5a5; font-size: 0.88rem; font-weight: 600; margin: 6px 0; }
.salon-erreur:empty { display: none; }

.publiques { margin-top: 14px; text-align: left; }
.publiques h3 { font-size: 0.9rem; color: #f0f3f6; margin-bottom: 6px; }
.publique { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 0.88rem; }
.publique-vide { font-size: 0.84rem; color: var(--texte-faible); }

.bandeau-absent {
  display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap;
  padding: 8px 12px; border-radius: 8px; font-size: 0.88rem; font-weight: 600;
  background: rgba(248, 113, 113, 0.1); border: 1px solid rgba(248, 113, 113, 0.4); color: #fecaca;
}
.fin-revanche { font-size: 0.86rem; color: var(--texte-doux); margin: 8px 0 0; }
.fin-revanche:empty { display: none; }
.fin-elo { font-size: 0.92rem; font-weight: 700; color: #fde9b0; margin: 6px 0; }
.fin-elo:empty { display: none; }
.fin-note { font-size: 0.84rem; color: var(--texte-doux); margin: 6px 0; }
.fin-note:empty { display: none; }


.defi-entete { text-align: center; margin-bottom: 14px; }
.defi-entete p { font-size: 0.92rem; color: var(--texte-doux); line-height: 1.5; margin-top: 6px; }
.defi-date { font-weight: 700; color: var(--color-light) !important; }
.defi-message { text-align: center; font-size: 0.9rem; color: #fca5a5; font-weight: 600; margin-bottom: 8px; }
.defi-message:empty { display: none; }
.defi-serie { text-align: center; font-size: 0.9rem; color: var(--texte); margin: 8px 0 14px; }
.defi-serie b { color: #fde9b0; }
.defi-compte { text-align: center; padding: 14px; margin-bottom: 14px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; }
.defi-compte p { font-size: 0.92rem; color: var(--texte); line-height: 1.5; margin-bottom: 10px; }
.encart-jour {
  margin-top: 16px; padding: 14px;
  background: rgba(148, 163, 184, 0.09); border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 18px;
}
.encart-jour h2 { font-family: var(--font-display); font-size: 1.1rem; color: #f0f3f6; margin-bottom: 10px; text-align: center; }
.lien-encart { display: inline-flex; align-items: center; min-height: 44px; color: var(--color-light); font-weight: 700; font-size: 0.88rem; text-decoration: none; }
.lien-encart:hover { text-decoration: underline; }
.u-centre { text-align: center; }
body.en-partie .encart-jour, body.en-partie .defi-entete, body.en-partie .defi-choix, body.en-partie .defi-intro, body.en-partie .titre-page-jeu { display: none; }
.defi-choix .reglages-actions { margin-top: 6px; }
.defi-intro { margin-top: 18px; }
.defi-intro h2 { font-size: 1.15rem; margin-bottom: 8px; }
.defi-intro h3 { font-size: 1rem; margin: 14px 0 6px; }
.defi-intro p { font-size: 0.9rem; color: var(--texte-doux); line-height: 1.6; margin-bottom: 8px; }
.defi-intro a { color: var(--color-light); }
