/* ============================================================
   FIN DE SAISON — l'annonce plein écran au retour du joueur.
   Reprend la grammaire de l'app (traits noirs, ombres portées, capitales
   Anton) sans redéfinir une seule classe de proto.css : tout est préfixé .fsz-.
   La couleur de la saison qui se termine est injectée par app.js dans
   --fsz-color, pour que l'écran change de peau à chaque saison sans CSS neuf.
   ============================================================ */
.fsz-screen {
  position: fixed;
  inset: 0;
  z-index: 9000;
  background: var(--paper);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  --fsz-color: var(--yellow);
}

.fsz-screen[hidden] { display: none; }

.fsz-inner {
  min-height: 100%;
  box-sizing: border-box;
  padding: 22px 16px calc(22px + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: 13px;
  max-width: 520px;
  margin-inline: auto;
  width: 100%;                                   /* sinon margin auto réduit le bloc à son contenu */
}

.fsz-kick {
  font-family: var(--fd);
  font-size: 12px;
  letter-spacing: 3px;
  opacity: .65;
  text-align: center;
}

/* ---- la bannière de la saison qui se termine ---- */
.fsz-banner {
  position: relative;
  overflow: hidden;
  border: 4px solid var(--ink);
  box-shadow: 7px 7px 0 var(--ink);
  background: var(--fsz-color);
  padding: 20px 16px 18px;
  text-align: center;
}

.fsz-b-rays {
  position: absolute;
  top: -55%;
  left: 50%;
  width: 165%;
  aspect-ratio: 1;
  transform: translateX(-50%);
  background: repeating-conic-gradient(from 0deg at 50% 42%, rgba(0, 0, 0, .10) 0 11deg, transparent 11deg 22deg);
  animation: fsz-spin 22s linear infinite;
}

@keyframes fsz-spin { to { transform: translateX(-50%) rotate(360deg); } }

@media (prefers-reduced-motion: reduce) { .fsz-b-rays { animation: none; } }

.fsz-banner > *:not(.fsz-b-rays) { position: relative; }

.fsz-b-lbl { font-family: var(--fb); font-weight: 800; font-size: 11px; letter-spacing: 2px; opacity: .75; }
.fsz-b-nm { font-family: var(--fd); font-size: 44px; line-height: 1.2; letter-spacing: .5px; margin: 2px 0 8px; }
.fsz-b-tag {
  display: inline-block;
  font-family: var(--fd);
  font-size: 12px;
  letter-spacing: 2px;
  border: 3px solid var(--ink);
  background: var(--paper);
  padding: 4px 11px;
}

/* ---- blocs ---- */
.fsz-card {
  border: 3px solid var(--ink);
  background: var(--paper);
  box-shadow: 5px 5px 0 var(--ink);
  padding: 13px;
}

.fsz-h {
  font-family: var(--fd);
  font-size: 13.5px;
  letter-spacing: 1.1px;
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-top: 4px;
}

.fsz-h i {
  font-style: normal;
  font-family: var(--fb);
  font-size: 10px;
  font-weight: 700;
  opacity: .55;
  letter-spacing: .4px;
}

.fsz-lbl { font-family: var(--fb); font-size: 10px; font-weight: 800; letter-spacing: 1.2px; opacity: .6; }
.fsz-sub { font-family: var(--fb); font-size: 12px; font-weight: 700; margin-top: 2px; }

.fsz-place { display: flex; align-items: center; gap: 13px; }
.fsz-place-rk { font-family: var(--fd); font-size: 40px; line-height: 1.2; letter-spacing: .5px; }
.fsz-place-tx { flex: 1; min-width: 0; }

/* ---- les lots ---- */
.fsz-won { display: flex; flex-direction: column; gap: 9px; }

.fsz-lot {
  display: flex;
  align-items: center;
  gap: 11px;
  border: 3px solid var(--ink);
  background: var(--paper);
  box-shadow: 4px 4px 0 var(--ink);
  padding: 11px;
}

.fsz-lot.djai { background: var(--fsz-color); }

.fsz-lot-em {
  width: 42px;
  height: 42px;
  flex: none;
  border: 3px solid var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  background: var(--paper);
  display: grid;
  place-items: center;
  font-size: 19px;
}

.fsz-lot-tx { flex: 1; min-width: 0; }
.fsz-lot-nm { font-family: var(--fd); font-size: 15px; letter-spacing: .4px; line-height: 1.2; }
.fsz-lot-d { font-family: var(--fb); font-size: 10.5px; font-weight: 600; opacity: .65; line-height: 1.45; margin-top: 2px; }

/* rien gagné : on le dit franchement, sans faux lot */
.fsz-none {
  border: 3px dashed var(--ink);
  background: var(--paper);
  padding: 13px;
  font-family: var(--fb);
  font-size: 11.5px;
  font-weight: 600;
  line-height: 1.55;
  opacity: .8;
}

/* ---- ce que tu gardes ---- */
.fsz-keeps { display: flex; gap: 9px; }

.fsz-keep-i {
  flex: 1;
  min-width: 0;
  border: 3px solid var(--ink);
  background: var(--paper);
  box-shadow: 3px 3px 0 var(--ink);
  padding: 9px 7px;
  text-align: center;
}

.fsz-keep-v { font-family: var(--fd); font-size: 17px; line-height: 1.2; letter-spacing: .3px; }
.fsz-keep-l { font-family: var(--fb); font-size: 9px; font-weight: 700; letter-spacing: .5px; opacity: .6; margin-top: 3px; }

.fsz-note {
  font-family: var(--fb);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.55;
  opacity: .75;
  margin-top: 11px;
}

.fsz-note b { opacity: 1; }

/* ---- le bouton ---- */
.fsz-cta {
  display: block;
  width: 100%;
  margin-top: 6px;
  border: 4px solid var(--ink);
  background: var(--magenta);
  box-shadow: 6px 6px 0 var(--ink);
  padding: 14px;
  font-family: var(--fd);
  font-size: 18px;
  letter-spacing: .8px;
  color: var(--ink);
  cursor: pointer;
}

.fsz-cta:active { transform: translate(3px, 3px); box-shadow: 3px 3px 0 var(--ink); }
.fsz-cta small { display: block; font-family: var(--fb); font-size: 10px; font-weight: 700; opacity: .7; margin-top: 3px; letter-spacing: .3px; }

/* ============================================================
   L'ARRIVÉE DE LA NOUVELLE SAISON — l'écran qui suit le récap.
   C'est le moment « la saison 2 commence » : plein écran, la couleur de la
   nouvelle saison, son numéro en énorme, et une seule porte d'entrée.
   Préfixe .nsz- — rien de proto.css n'est redéfini.
   ============================================================ */
.nsz-screen {
  position: fixed;
  inset: 0;
  z-index: 9200;
  background: var(--nsz-color, var(--magenta));
  /* ⚠ PAS overflow:hidden. Avec un contenu plus haut que l'écran, le numéro
     mangeait toute la place, le nom de la saison se tassait en bas et le bouton
     ENTRER passait hors champ — sans aucun moyen de faire défiler. */
  overflow-y: auto;
  overscroll-behavior: contain;
  display: flex;
  flex-direction: column;
  justify-content: safe center;
  gap: 14px;
  padding: 26px 20px calc(26px + env(safe-area-inset-bottom));
}

.nsz-screen[hidden] { display: none; }

/* les couches de fond, même grammaire que le récap : des trames, jamais de dégradé */
.nsz-bg { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.nsz-bg > * { position: absolute; }
.nsz-bg .dots { inset: -20px; background-image: radial-gradient(rgba(10, 10, 10, .16) 2.5px, transparent 2.6px); background-size: 15px 15px; }
.nsz-bg .rays {
  width: 900px; height: 900px; top: 50%; left: 50%; margin: -450px 0 0 -450px;
  background: repeating-conic-gradient(from 0deg, rgba(10, 10, 10, .09) 0 6deg, transparent 6deg 12deg);
  animation: nsz-spin 30s linear infinite;
}
.nsz-bg .grain { inset: 0; background-image: radial-gradient(rgba(10, 10, 10, .1) .5px, transparent .6px); background-size: 4px 4px; }

@keyframes nsz-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .nsz-bg .rays { animation: none; } }

.nsz-screen > *:not(.nsz-bg) { position: relative; z-index: 1; max-width: 520px; width: 100%; margin-inline: auto; }

.nsz-kick { font-family: var(--fd); font-size: 13px; letter-spacing: 3px; opacity: .75; }

.nsz-num {
  font-family: var(--fd);
  /* proportionnel à l'écran : à 150 px fixes, sur un téléphone court, il
     poussait le nom de la saison et le bouton hors de vue. */
  font-size: clamp(88px, 34vw, 150px);
  line-height: 1.05;
  letter-spacing: -6px;
  position: relative;
  flex-shrink: 0;
}

.nsz-num .off { position: absolute; left: 7px; top: 7px; color: var(--paper); z-index: -1; }

.nsz-nm {
  font-family: var(--fd);
  font-size: clamp(40px, 15vw, 58px);
  line-height: 1.2;
  letter-spacing: 1px;
  -webkit-text-stroke: 2px var(--ink);
  color: var(--paper);
  text-shadow: 5px 5px 0 var(--ink);
}

.nsz-dates {
  display: inline-block;
  font-family: var(--fb);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1px;
  border: 3px solid var(--ink);
  background: var(--paper);
  padding: 5px 11px;
}

.nsz-say { font-family: var(--fb); font-size: 13px; font-weight: 600; line-height: 1.6; }

.nsz-list { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }
.nsz-li {
  display: flex; align-items: center; gap: 10px;
  border: 3px solid var(--ink); background: var(--paper);
  box-shadow: 4px 4px 0 var(--ink); padding: 10px 12px;
  font-family: var(--fb); font-size: 12px; font-weight: 700;
}
.nsz-li b { font-family: var(--fd); font-size: 14px; letter-spacing: .3px; }

.nsz-cta {
  display: block; width: 100%; margin-top: 10px;
  border: 4px solid var(--ink); background: var(--ink);
  box-shadow: 6px 6px 0 var(--paper);
  padding: 15px; font-family: var(--fd); font-size: 19px; letter-spacing: 1px;
  color: var(--paper); cursor: pointer;
}

.nsz-cta:active { transform: translate(3px, 3px); box-shadow: 3px 3px 0 var(--paper); }

/* L'ENTRÉE EN SCÈNE — le numéro tombe, le reste suit.
   ⚠ Aucune animation ne porte `both` / `backwards` : avec un remplissage arrière,
   un élément à délai reste bloqué sur son image de départ (opacity:0) tant que
   l'animation n'a pas démarré — et si elle ne démarre jamais (moteur qui gèle les
   animations, onglet en arrière-plan, capture), le contenu est INVISIBLE pour de bon.
   Ici le pire cas est un élément qui s'affiche sans son entrée, jamais un écran vide. */
.nsz-screen[data-anim="1"] .nsz-num { animation: nsz-drop .55s cubic-bezier(.2, .9, .3, 1.4); }
.nsz-screen[data-anim="1"] .nsz-nm { animation: nsz-drop .55s .12s cubic-bezier(.2, .9, .3, 1.4); }
.nsz-screen[data-anim="1"] .nsz-dates,
.nsz-screen[data-anim="1"] .nsz-say,
.nsz-screen[data-anim="1"] .nsz-list,
.nsz-screen[data-anim="1"] .nsz-cta { animation: nsz-rise .45s .3s ease-out; }

@keyframes nsz-drop { from { transform: translateY(-26px) scale(.86); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes nsz-rise { from { transform: translateY(14px); opacity: 0; } to { transform: none; opacity: 1; } }

@media (prefers-reduced-motion: reduce) {
  .nsz-screen[data-anim="1"] * { animation: none !important; }
}
