:root {
  --fond: #0e1420;
  --fond-2: #141c2b;
  --carte: #1a2333;
  --bord: #2a3547;
  --texte: #e8e6e1;
  --texte-doux: #9aa5b6;
  --or: #c9a961;
  --or-clair: #e3c98a;
  --rouge: #d4756b;
  --serif: "Playfair Display", Georgia, serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  background:
    radial-gradient(120% 80% at 50% 0%, #1a2436 0%, var(--fond) 55%),
    var(--fond);
  background-attachment: fixed;
  color: var(--texte);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  min-height: 100dvh;
  -webkit-font-smoothing: antialiased;
}

/* Grain léger : évite l'aplat numérique */
.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: .035;
  z-index: 1;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)'/%3E%3C/svg%3E");
}

.wrap {
  position: relative;
  z-index: 2;
  max-width: 560px;
  margin: 0 auto;
  padding: max(24px, env(safe-area-inset-top)) 22px
           max(32px, env(safe-area-inset-bottom));
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

.ecran {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 26px;
  padding: 24px 0;
}

.ecran.centre { text-align: center; align-items: center; }

.apparait { animation: monte .55s cubic-bezier(.22,.68,.36,1) both; }
@keyframes monte {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: none; }
}

/* --- Typo ---------------------------------------------------------- */

.titre-display {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(30px, 8.5vw, 42px);
  line-height: 1.18;
  letter-spacing: -.01em;
}

.titre-question {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(23px, 6vw, 29px);
  line-height: 1.32;
}

.sous-titre { color: var(--texte-doux); font-size: 16px; }

.texte { color: var(--texte); white-space: pre-line; text-align: left; }
.ecran.centre .texte { text-align: center; }
.texte-final { color: var(--texte-doux); }

.legende { color: var(--texte-doux); font-size: 13px; margin-top: 8px; }

.erreur { color: var(--rouge); font-size: 15px; }

.indice {
  color: var(--or);
  font-size: 15px;
  font-style: italic;
  transition: opacity .4s ease;
}

.masque { opacity: 0; pointer-events: none; }

/* --- Boutons -------------------------------------------------------- */

.bouton {
  display: inline-block;
  background: linear-gradient(180deg, var(--or-clair), var(--or));
  color: #1a1305;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 16px;
  letter-spacing: .01em;
  border: none;
  border-radius: 100px;
  padding: 15px 40px;
  cursor: pointer;
  text-decoration: none;
  transition: transform .15s ease, filter .15s ease;
  -webkit-tap-highlight-color: transparent;
}
.bouton:active { transform: scale(.97); }
.bouton:disabled { opacity: .3; cursor: default; }
.bouton:not(:disabled):hover { filter: brightness(1.07); }

.bouton-secondaire {
  background: none;
  border: 1px solid var(--bord);
  color: var(--texte-doux);
  border-radius: 100px;
  padding: 14px 26px;
  font-family: var(--sans);
  font-size: 15px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.bouton-secondaire:active { transform: scale(.97); }

.actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* --- Écran code ----------------------------------------------------- */

.serrure { color: var(--or); width: 44px; opacity: .85; }
.serrure svg { width: 100%; height: auto; }

.form-code { display: flex; flex-direction: column; align-items: center; gap: 18px; width: 100%; }

.indice-code {
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--texte-doux);
}

.champ-code {
  width: min(240px, 80vw);
  background: var(--carte);
  border: 1px solid var(--bord);
  border-radius: 14px;
  color: var(--texte);
  font-family: var(--serif);
  font-size: 40px;
  letter-spacing: .34em;
  text-align: center;
  text-indent: .34em; /* recentre malgré le letter-spacing */
  padding: 14px 0;
  outline: none;
  transition: border-color .2s ease;
}
.champ-code:focus { border-color: var(--or); }

/* --- Barre de progression / lettres --------------------------------- */

.barre {
  display: flex;
  flex-direction: column;      /* numéro au-dessus, lettres en dessous */
  align-items: center;
  gap: 10px;
  padding: 6px 0 16px;
  border-bottom: 1px solid var(--bord);
}

.compteur {
  font-family: var(--serif);
  font-size: 19px;
  color: var(--or);
  white-space: nowrap;
}
.compteur span { color: var(--texte-doux); font-size: 14px; }

.lettres-gagnees {
  display: flex;
  gap: 3px;
  flex-wrap: wrap;
  justify-content: center;
  max-width: 100%;
}

.case-lettre {
  width: 19px;
  height: 25px;
  border: 1px solid var(--bord);
  border-radius: 4px;
  display: grid;
  place-items: center;
  font-family: var(--serif);
  font-size: 13px;
  color: transparent;
  transition: all .45s cubic-bezier(.22,.68,.36,1);
}
.case-lettre.pleine {
  color: #1a1305;
  background: linear-gradient(180deg, var(--or-clair), var(--or));
  border-color: var(--or);
}
.case-lettre.neuve { animation: pop .5s cubic-bezier(.22,1.3,.36,1) both; }
@keyframes pop {
  0%   { transform: scale(.4) rotate(-8deg); opacity: 0; }
  100% { transform: none; opacity: 1; }
}

/* --- QCM ------------------------------------------------------------ */

.choix { list-style: none; display: flex; flex-direction: column; gap: 11px; }

.option {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--carte);
  border: 1px solid var(--bord);
  border-radius: 14px;
  padding: 16px 18px;
  color: var(--texte);
  font-family: var(--sans);
  font-size: 16px;
  text-align: left;
  cursor: pointer;
  transition: border-color .2s ease, background .2s ease, transform .12s ease;
  -webkit-tap-highlight-color: transparent;
}
.option:active { transform: scale(.985); }
.option:hover:not(:disabled) { border-color: var(--or); background: var(--fond-2); }
.option:disabled { cursor: default; }

.puce {
  flex: 0 0 auto;
  width: 27px; height: 27px;
  border-radius: 50%;
  border: 1px solid var(--bord);
  display: grid; place-items: center;
  font-size: 13px;
  color: var(--texte-doux);
  transition: all .2s ease;
}

.option.faux { border-color: var(--rouge); animation: secoue .4s ease; }
.option.faux .puce { border-color: var(--rouge); color: var(--rouge); }
.option.juste { border-color: var(--or); background: rgba(201,169,97,.12); }
.option.juste .puce {
  background: var(--or); border-color: var(--or); color: #1a1305; font-weight: 600;
}

@keyframes secoue {
  0%,100% { transform: translateX(0); }
  25%     { transform: translateX(-6px); }
  75%     { transform: translateX(6px); }
}

.form-texte { display: flex; flex-direction: column; gap: 14px; }
.champ-texte {
  background: var(--carte);
  border: 1px solid var(--bord);
  border-radius: 14px;
  padding: 16px 18px;
  color: var(--texte);
  font-family: var(--sans);
  font-size: 16px;
  outline: none;
}
.champ-texte:focus { border-color: var(--or); }

/* --- Révélation du souvenir ----------------------------------------- */

/* [hidden] doit gagner contre les display: flex/block ci-dessous */
[hidden] { display: none !important; }

.voile {
  position: fixed;
  inset: 0;
  z-index: 10;
  background: rgba(8, 12, 20, .82);
  backdrop-filter: blur(7px);
  -webkit-backdrop-filter: blur(7px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px;
  overflow-y: auto;
  animation: fondu .35s ease both;
}
@keyframes fondu { from { opacity: 0; } to { opacity: 1; } }

.carte-reveal {
  background: var(--carte);
  max-height: calc(100dvh - 44px);
  overflow-y: auto;
  border: 1px solid var(--bord);
  border-radius: 22px;
  padding: 30px 24px 26px;
  max-width: 460px;
  width: 100%;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  animation: monte .45s cubic-bezier(.22,.68,.36,1) both .1s;
  margin: auto;
}

.lettre-obtenue {
  width: 62px; height: 74px;
  border-radius: 10px;
  background: linear-gradient(180deg, var(--or-clair), var(--or));
  color: #1a1305;
  font-family: var(--serif);
  font-size: 38px;
  display: grid; place-items: center;
  box-shadow: 0 8px 28px rgba(201,169,97,.28);
  animation: pop .55s cubic-bezier(.22,1.3,.36,1) both .25s;
}

.reveal-image { width: 100%; border-radius: 14px; overflow: hidden; background: var(--fond-2); }
.reveal-image img {
  width: 100%;
  height: auto;
  display: block;
  max-height: 40vh;      /* la carte entière doit tenir dans un écran de téléphone */
  object-fit: cover;
}

.reveal-texte { color: var(--texte-doux); font-size: 16px; white-space: pre-line; }

/* --- Anagramme ------------------------------------------------------- */

.slots, .tuiles {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  width: 100%;
}

.slot {
  width: 40px; height: 50px;
  border: 1px dashed var(--bord);
  border-radius: 8px;
  background: rgba(255,255,255,.02);
  color: var(--texte);
  font-family: var(--serif);
  font-size: 24px;
  cursor: pointer;
  transition: all .2s ease;
  -webkit-tap-highlight-color: transparent;
}
.slot.rempli {
  border-style: solid;
  border-color: var(--or);
  background: rgba(201,169,97,.14);
  color: var(--or-clair);
}
.slot.faux { border-color: var(--rouge); animation: secoue .4s ease; }

.tuiles { min-height: 50px; }

.tuile {
  width: 40px; height: 50px;
  border: 1px solid var(--bord);
  border-radius: 8px;
  background: var(--carte);
  color: var(--texte);
  font-family: var(--serif);
  font-size: 24px;
  cursor: pointer;
  transition: all .18s ease;
  -webkit-tap-highlight-color: transparent;
}
.tuile:active { transform: scale(.9); }
.tuile.utilisee { opacity: 0; pointer-events: none; transform: scale(.6); }

/* --- Final ----------------------------------------------------------- */

.final { gap: 24px; }
.couronne { color: var(--or); width: 58px; }
.couronne svg { width: 100%; height: auto; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* --- Plateau d'échecs -------------------------------------------------- */

.plateau-zone { display: flex; flex-direction: column; align-items: center; gap: 14px; }

.plateau {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  grid-template-rows: repeat(8, 1fr);
  width: min(100%, 400px);
  aspect-ratio: 1;
  border: 1px solid rgba(201,169,97,.55);
  outline: 6px solid var(--carte);
  outline-offset: 0;
  border-radius: 12px;
  overflow: hidden;
  box-shadow:
    0 0 0 7px rgba(201,169,97,.25),
    0 18px 50px rgba(0,0,0,.55),
    0 0 60px rgba(201,169,97,.07);
}

.plateau.refuse { animation: secoue .4s ease; }

.case {
  border: none;
  padding: 0;
  display: grid;
  place-items: center;
  cursor: pointer;
  position: relative;
  transition: box-shadow .15s ease;
  -webkit-tap-highlight-color: transparent;
}
.case.claire { background: linear-gradient(160deg, #e9dfc6, #ddd0b1); }
.case.sombre { background: linear-gradient(160deg, #66573c, #57492f); }

.case.selectionnee { box-shadow: inset 0 0 0 3px var(--or); }
.case.cible        { box-shadow: inset 0 0 0 3px var(--or-clair); }

/* Aide après 2 erreurs : la pièce à jouer pulse doucement */
.case.a-jouer::after {
  content: '';
  position: absolute;
  inset: 12%;
  border: 2px solid var(--or);
  border-radius: 50%;
  animation: pulse 1.5s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: .35; transform: scale(.9); }
  50%      { opacity: 1;   transform: scale(1.05); }
}

/* Pièces SVG : taille strictement identique pour toutes */
.piece {
  pointer-events: none;
  user-select: none;
}
.piece-svg {
  width: 88%;
  height: 88%;
  object-fit: contain;
  display: block;
}

.legende-plateau { color: var(--texte-doux); font-size: 14px; text-align: center; }

/* --- Question 8 : note + repli ---------------------------------------- */

.note-question {
  color: var(--texte-doux);
  font-size: 15px;
  font-style: italic;
  margin-top: -12px;
}

.repli-intro { margin-bottom: 4px; }

/* Le roi et la dame blancs : vos deux visages, en médaillon doré */
.piece-photo {
  width: 82%;
  aspect-ratio: 1;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--or);
  box-shadow: 0 2px 10px rgba(0,0,0,.45), 0 0 0 1px rgba(255,255,255,.25) inset;
  background: var(--carte);
}
.case.selectionnee .piece-photo {
  box-shadow: 0 0 0 3px var(--or-clair), 0 2px 12px rgba(0,0,0,.5);
}

/* --- Mots croisés ------------------------------------------------------ */

.croises-zone { display: flex; flex-direction: column; gap: 24px; }

/* La grille : du papier crème dans un cadre doré, comme l'échiquier */
.grille-cadre {
  align-self: center;
  background: linear-gradient(160deg, #1c2536, #151d2c);
  padding: 14px;
  border: 1px solid rgba(201,169,97,.55);
  border-radius: 14px;
  box-shadow:
    0 0 0 7px rgba(201,169,97,.22),
    0 18px 50px rgba(0,0,0,.5),
    0 0 60px rgba(201,169,97,.06);
}

.grille {
  display: grid;
  grid-template-columns: repeat(var(--gcols), minmax(30px, 44px));
  grid-auto-rows: minmax(30px, 44px);
}

.cellule {
  background: linear-gradient(160deg, #f8f1e0, #ece1c6);
  border: 1px solid #9c8c66;
  margin: -0.5px;                    /* les bordures se partagent, façon papier */
  box-shadow: 0 1px 3px rgba(0,0,0,.25);
  position: relative;
  display: grid;
  place-items: center;
}

.cellule .num {
  position: absolute;
  top: 1px; left: 3px;
  font-size: 10px;
  font-weight: 600;
  color: #8a774f;
}

.lettre-cellule {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(15px, 4.6vw, 24px);
  color: #2a2216;
}

.cellule.trouvee { background: #f6efdd; }
.cellule.neuve-cellule .lettre-cellule {
  animation: pop .4s cubic-bezier(.22,1.3,.36,1) both;
}
.cellule.neuve-cellule { animation: flash-or 1s ease both; }
@keyframes flash-or {
  0%   { background: var(--or-clair); }
  100% { background: linear-gradient(160deg, #f8f1e0, #ece1c6); }
}

/* Les définitions */
.definitions {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.def {
  background: var(--carte);
  border: 1px solid var(--bord);
  border-radius: 16px;
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: border-color .3s ease, opacity .3s ease;
}
.def.resolue { border-color: rgba(201,169,97,.55); opacity: .82; }

.def-tete { display: flex; align-items: baseline; gap: 12px; }

.def-num {
  flex: 0 0 auto;
  width: 26px; height: 26px;
  border-radius: 50%;
  border: 1px solid var(--bord);
  display: grid; place-items: center;
  font-size: 13px;
  color: var(--texte-doux);
  align-self: flex-start;
}
.def.resolue .def-num {
  background: linear-gradient(180deg, var(--or-clair), var(--or));
  border-color: var(--or);
  color: #1a1305;
  font-weight: 600;
}

.def-texte { font-size: 15.5px; line-height: 1.5; color: var(--texte); }
.def-sens {
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--texte-doux);
  display: block;
  margin-bottom: 2px;
}

.def-form { display: flex; gap: 8px; }

.champ-mot {
  flex: 1;
  min-width: 0;
  background: var(--fond-2);
  border: 1px solid var(--bord);
  border-radius: 12px;
  padding: 12px 14px;
  color: var(--texte);
  font-family: var(--serif);
  font-size: 17px;
  text-transform: uppercase;
  letter-spacing: .14em;
  outline: none;
}
.champ-mot:focus { border-color: var(--or); }
.champ-mot.secoue { animation: secoue .4s ease; border-color: var(--rouge); }

.bouton-mini {
  background: linear-gradient(180deg, var(--or-clair), var(--or));
  color: #1a1305;
  border: none;
  border-radius: 12px;
  padding: 0 20px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.bouton-mini:active { transform: scale(.95); }

.def-mot-trouve {
  font-family: var(--serif);
  font-size: 19px;
  color: var(--or-clair);
  letter-spacing: .18em;
}

.aide-mot { color: var(--or); font-size: 14px; font-style: italic; }

/* --- Combo Mario Kart --------------------------------------------------- */

.combo-zone { display: flex; flex-direction: column; gap: 20px; }

.combo-titre {
  font-size: 12px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--texte-doux);
  margin-bottom: 8px;
}

.combo-choix {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 4px 2px 10px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  scroll-snap-type: x proximity;
}
.combo-choix::-webkit-scrollbar { display: none; }

.vignette {
  flex: 0 0 86px;
  width: 86px;
  height: 86px;
  scroll-snap-align: start;
  padding: 6px;
  background: var(--carte);
  border: 1.5px solid var(--bord);
  border-radius: 14px;
  cursor: pointer;
  transition: border-color .18s ease, transform .12s ease, box-shadow .18s ease;
  -webkit-tap-highlight-color: transparent;
}
.vignette img { width: 100%; height: 100%; object-fit: contain; display: block; }
.vignette:active { transform: scale(.93); }

.vignette.choisie {
  border-color: var(--or);
  background: rgba(201,169,97,.12);
  box-shadow: 0 0 0 1px var(--or), 0 4px 16px rgba(201,169,97,.18);
}
.vignette.verrouillee {
  border-color: var(--or);
  background: linear-gradient(180deg, rgba(227,201,138,.22), rgba(201,169,97,.16));
}
.vignette.fausse { animation: secoue .4s ease; border-color: var(--rouge); }

#valider-combo { align-self: center; }

/* --- L'étoile mystère --------------------------------------------------- */

.etoile-zone { display: flex; flex-direction: column; gap: 20px; }

.etoile-photo {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(201,169,97,.5);
  box-shadow: 0 0 0 6px rgba(201,169,97,.2), 0 16px 44px rgba(0,0,0,.5);
  max-height: 52vh;
  align-self: center;
}
.etoile-photo > img {
  display: block;
  max-width: 100%;
  max-height: 52vh;
}

.etoile-cases {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(var(--ecols, 6), 1fr);
  grid-template-rows: repeat(var(--erows, 6), 1fr);
}

.case-etoile {
  background: linear-gradient(160deg, #1d2739, #141c2b);
  border: 1px solid rgba(201,169,97,.28);
  display: grid;
  place-items: center;
  transition: opacity .5s ease, transform .5s ease;
}
.case-etoile .petite-etoile {
  color: rgba(201,169,97,.45);
  font-size: 11px;
}
.case-etoile.partie {
  opacity: 0;
  transform: scale(1.12);
  pointer-events: none;
}

/* --- Question audio ----------------------------------------------------- */

.audio-zone { display: flex; flex-direction: column; gap: 22px; }

.bloc-audio {
  background: var(--carte);
  border: 1px solid rgba(201,169,97,.5);
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 0 0 6px rgba(201,169,97,.16), 0 14px 40px rgba(0,0,0,.45);
}
.bloc-audio audio, .reveal-audio audio { width: 100%; display: block; }

.reveal-audio { width: 100%; }

/* --- Question calendrier ------------------------------------------------ */

.date-zone { display: flex; flex-direction: column; gap: 16px; }

.champ-date {
  font-family: var(--serif);
  font-size: 20px;
  letter-spacing: .06em;
  text-align: center;
  color-scheme: dark;              /* le sélecteur natif passe en sombre */
}
.champ-date::-webkit-calendar-picker-indicator {
  filter: invert(.75) sepia(.4) saturate(3) hue-rotate(10deg);  /* icône dorée */
  transform: scale(1.3);
  cursor: pointer;
}

.direction {
  color: var(--or);
  font-size: 16px;
  text-align: center;
  transition: opacity .3s ease;
}

.vignette.cachee { display: none; }

.reveal-video { width: 100%; }
.reveal-video video {
  width: 100%;
  max-height: 46vh;
  display: block;
  border-radius: 14px;
  background: #000;
}

/* --- Révélation à plusieurs images + lightbox --------------------------- */

.reveal-images {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  width: 100%;
}
.reveal-images img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid var(--bord);
  cursor: zoom-in;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: rgba(5, 8, 14, .96);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: auto;
  animation: fondu .25s ease both;
}
.lightbox img {
  max-width: 96vw;
  max-height: 92vh;
  border-radius: 8px;
}
.lightbox-fermer {
  position: fixed;
  top: max(14px, env(safe-area-inset-top));
  right: 16px;
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1px solid var(--bord);
  background: var(--carte);
  color: var(--texte);
  font-size: 17px;
  cursor: pointer;
}

.photo-question {
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(201,169,97,.5);
  box-shadow: 0 0 0 6px rgba(201,169,97,.16), 0 14px 40px rgba(0,0,0,.45);
  align-self: center;
  max-width: 340px;
}
.photo-question img { width: 100%; display: block; }

.legende-zoom {
  color: var(--texte-doux);
  font-size: 12.5px;
  font-style: italic;
  margin-top: -10px;
}

/* --- Paroles traduites -------------------------------------------------- */

.paroles {
  border-left: 2px solid var(--or);
  padding: 4px 0 4px 16px;
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.paroles span {
  font-family: var(--serif);
  font-style: italic;
  font-size: 15.5px;
  line-height: 1.45;
  color: var(--texte-doux);
}

.slot.verrouille {
  border-style: solid;
  border-color: var(--or);
  background: linear-gradient(180deg, rgba(227,201,138,.30), rgba(201,169,97,.22));
  color: var(--or-clair);
  cursor: default;
}

.photo-intro { max-width: 380px; }

/* --- Mots croisés v2 : numéros cliquables + bulle de définition --------- */

.cellule.depart { cursor: pointer; }
.cellule.depart .num {
  background: linear-gradient(180deg, #e3c98a, #c9a961);
  color: #1a1305;
  border-radius: 3px;
  padding: 0 2px;
  font-weight: 700;
}
.cellule.depart:active { filter: brightness(1.08); }

.voile-def {
  position: fixed;
  inset: 0;
  z-index: 40;
  background: rgba(8, 12, 20, .78);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 14vh 22px 22px;
  animation: fondu .25s ease both;
}

.carte-def {
  position: relative;
  background: var(--carte);
  border: 1px solid rgba(201,169,97,.5);
  border-radius: 20px;
  padding: 26px 22px 22px;
  width: 100%;
  max-width: 420px;
  display: flex;
  flex-direction: column;
  gap: 13px;
  animation: monte .35s cubic-bezier(.22,.68,.36,1) both;
  box-shadow: 0 18px 50px rgba(0,0,0,.5);
}

.fermer-def {
  position: absolute;
  top: 10px; right: 12px;
  width: 32px; height: 32px;
  border-radius: 50%;
  border: 1px solid var(--bord);
  background: var(--fond-2);
  color: var(--texte-doux);
  font-size: 13px;
  cursor: pointer;
}

.def-entete {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--or);
}

.def-texte-modal {
  font-size: 16.5px;
  line-height: 1.55;
  color: var(--texte);
}
