/* Accueil du studio (methode Taste Skill) : bois, parchemin, laiton. Aplats seulement, ni degrade, ni ombre, ni filet. */
:root {
  --fond: #2e2116;
  --fond-2: #3a2a1c;
  --encre: #f1e2bf;
  --laiton: #e0ac45;
  --texte: 18px;
  --marge: clamp(16px, 4vw, 56px);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--fond); color: var(--encre); font: var(--texte)/1.55 system-ui, -apple-system, "Segoe UI", sans-serif; }
img { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3, .grand-nom, .marque, .action { font-family: "Lilita One", system-ui, sans-serif; font-weight: 400; }
h2 { font-size: clamp(2.4rem, 4.6vw, 4.6rem); line-height: .95; letter-spacing: -.02em; margin: 0 0 .3em; }

/* Barre : nom, liens, rien d'autre */
.barre { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 14px var(--marge); background: var(--fond); }
.marque { display: flex; align-items: center; gap: 10px; text-decoration: none; font-size: 1.35rem; }
.barre nav { display: flex; gap: 24px; flex-wrap: wrap; }
.barre nav a { text-decoration: none; font-weight: 600; }
.barre nav a:hover, .barre nav a:focus-visible { color: var(--laiton); }

/* Accroche : le logo en titre, le de a lancer, l'image du jeu a la une */
.heros { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(24px, 4vw, 64px); align-items: center; padding: 48px var(--marge) 120px; }
.heros h1 { margin: 0; }
.heros h1 img { width: 100%; height: auto; }
.chapeau { font-size: clamp(1.15rem, 1.6vw, 1.45rem); max-width: 34em; margin: 24px 0 36px; }
.heros-image img { width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; }
.lancer { display: flex; align-items: center; gap: 24px; }
.action { display: inline-block; background: var(--laiton); color: #2e2116; text-decoration: none; font-size: 1.35rem; padding: 14px 28px; border-radius: 999px; transition: transform .15s ease, background .15s ease; }
.action:hover, .action:focus-visible { background: #f3c463; transform: translateY(-2px); }
.action:active { transform: translateY(1px); }
.resultat { margin: 10px 0 0; font-size: 1rem; }

/* Le de : neuf cases, les points s'allument selon la face */
.de { width: 96px; height: 96px; flex: none; display: grid; grid-template: repeat(3, 1fr) / repeat(3, 1fr); padding: 14px; gap: 4px;
  background: var(--encre); border: 0; border-radius: 18px; cursor: pointer; transition: transform .15s ease; }
.de:hover, .de:focus-visible { transform: rotate(-6deg); outline: 3px solid var(--laiton); outline-offset: 4px; }
.de span { width: 100%; aspect-ratio: 1; border-radius: 50%; background: transparent; }
.de[data-face="1"] span:nth-child(5),
.de[data-face="2"] span:is(:nth-child(1), :nth-child(9)),
.de[data-face="3"] span:is(:nth-child(1), :nth-child(5), :nth-child(9)),
.de[data-face="4"] span:is(:nth-child(1), :nth-child(3), :nth-child(7), :nth-child(9)),
.de[data-face="5"] span:is(:nth-child(1), :nth-child(3), :nth-child(5), :nth-child(7), :nth-child(9)),
.de[data-face="6"] span:is(:nth-child(1), :nth-child(3), :nth-child(4), :nth-child(6), :nth-child(7), :nth-child(9)) { background: #2e2116; }
.de.roule { animation: roule .6s cubic-bezier(.3, .7, .4, 1); }
@keyframes roule { 0% { transform: rotate(0) scale(1); } 50% { transform: rotate(200deg) scale(.85); } 100% { transform: rotate(360deg) scale(1); } }

/* Un chapitre par jeu, chacun sur sa propre plage de couleur */
.chapitre { display: grid; grid-template-columns: 7fr 5fr; gap: clamp(24px, 4vw, 64px); align-items: center;
  padding: 120px var(--marge); background: var(--fond); color: var(--encre); }
.chapitre.inverse { grid-template-columns: 5fr 7fr; }
.chapitre.inverse .chapitre-image { order: 2; }
.chapitre-image img { width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; transition: transform .4s ease; }
.chapitre-image:hover img { transform: scale(1.02); }
.chapitre p { max-width: 32em; }
.accroche { font-size: clamp(1.3rem, 2vw, 1.75rem); line-height: 1.3; }
.etat { font-weight: 700; }
.chapitre .action { margin-top: 12px; }
.vignettes { grid-column: 1 / -1; order: 3; display: grid; grid-template-columns: repeat(var(--n, 3), 1fr); gap: 16px; }
.vignettes img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.chapitre.choisi { animation: choisi 1.2s ease; }
@keyframes choisi { 0%, 100% { filter: none; } 30% { filter: brightness(1.25); } }

/* Premiers pas : une liste, pas des cartes */
.premiers { padding: 120px var(--marge); background: var(--fond-2); }
.premiers ul { list-style: none; padding: 0; margin: 48px 0 0; display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 4vw, 64px); }
.premiers li a { display: grid; gap: 8px; text-decoration: none; }
.premiers li img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; object-position: top; filter: saturate(.7); transition: filter .3s ease; }
.premiers li a:hover img { filter: none; }
.premiers .nom { font-family: "Lilita One", sans-serif; font-size: 2.2rem; line-height: 1; margin-top: 8px; }
.premiers .date { font-weight: 700; color: var(--laiton); }

/* Le studio : la photo de Jisse en grand, ses plateformes en liste */
.studio { display: grid; grid-template-columns: 4fr 8fr; gap: clamp(24px, 4vw, 64px); align-items: start; padding: 120px var(--marge); background: #f1e2bf; color: #2e2116; }
.studio .portrait { width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; }
.studio h2 { font-size: clamp(2.2rem, 4.4vw, 4.2rem); }
.studio h3 { font-size: 1.8rem; margin: 40px 0 8px; }
.metiers { font-weight: 700; }
.plateformes { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.plateformes a { font-family: "Lilita One", sans-serif; font-size: 1.35rem; color: #7a3b12; margin-right: 8px; }

/* Pied : le nom revient en pleine largeur */
.pied { padding: 120px var(--marge) 48px; }
.grand-nom { font-size: clamp(3.5rem, 15vw, 14rem); line-height: .85; letter-spacing: -.03em; margin: 0 0 24px; color: var(--laiton); }
.pied a { margin-left: 16px; font-weight: 700; }

/* Entrees : titre, puis texte, puis image, une seule fois */
.entre { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.entre.vu { opacity: 1; transform: none; }

@media (max-width: 860px) {
  .heros, .chapitre, .chapitre.inverse, .studio { grid-template-columns: 1fr; }
  .chapitre.inverse .chapitre-image { order: 0; }
  .chapitre h2 { font-size: 2.4rem; }
  .heros { padding-top: 24px; }
  .chapitre, .premiers, .studio { padding: 72px var(--marge); }
  .premiers ul { grid-template-columns: 1fr; }
  .vignettes { grid-template-columns: 1fr 1fr; }
  .vignettes img:nth-child(3) { display: none; }
  .barre nav a:nth-child(n+2) { display: none; }
  .marque { white-space: nowrap; }
  .de { width: 80px; height: 80px; padding: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .entre { opacity: 1; transform: none; transition: none; }
  .de.roule, .chapitre.choisi { animation: none; }
  .action, .de, .chapitre-image img { transition: none; }
}

/* Etre prevenu : un aplat laiton, une seule ligne de saisie */
.lettre.aplat { background: var(--laiton); color: #2b1d10; padding: 96px var(--marge); }
.lettre.aplat p { max-width: 38ch; font-size: 1.15rem; }
.lettre-form { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; max-width: 640px; }
.lettre-form label { flex-basis: 100%; font-weight: 700; }
.lettre-form input { flex: 1 1 260px; font: inherit; padding: 14px 16px; border: 2px solid #2b1d10; border-radius: 10px; background: #f1e2bf; color: #2b1d10; }
.lettre-form button { font: 1.3rem "Lilita One", sans-serif; padding: 14px 24px; border: 0; border-radius: 10px; background: #2b1d10; color: #f1e2bf; cursor: pointer; }
.lettre-merci { font-weight: 700; font-size: 1.3rem; }
@media (min-width: 861px) {
  .lettre.aplat { display: grid; grid-template-columns: 1fr 1fr; column-gap: 64px; align-items: center; }
  .lettre.aplat h2, .lettre.aplat > p:not(.lettre-merci) { grid-column: 1; }
  .lettre.aplat .lettre-form, .lettre.aplat .lettre-merci { grid-column: 2; grid-row: 1 / span 2; margin-top: 0; }
}
.lettre-form button:active { transform: scale(.97); }
.lettre-form button:disabled { opacity: .6; cursor: wait; }
.lettre-erreur { font-weight: 700; color: #8a1f0c; }

/* Le jeu a la une : le lien pour y jouer, sous son image */
.jouer { display: inline-block; font: 1.2rem "Lilita One", sans-serif; color: inherit; text-underline-offset: 4px; margin: 16px 0 0 20px; transition: opacity .15s ease; }
.heros-une .jouer { margin-left: 0; }
.jouer:hover { opacity: .75; }
.jouer:active { opacity: .55; }
