/**
 * Les pages du site autour de l'application : accueil, présentation, aide, pages légales. Rien ici
 * ne sert à `app.html`.
 *
 * Toutes les tailles sont en `rem`, et la racine grandit avec l'écran : sur un grand
 * moniteur la page s'agrandit comme l'application (`--ui-scale`), au lieu de rester une
 * colonne minuscule au milieu. Le seul élément marquant est la frise de l'accueil,
 * dessinée avec les couleurs de marqueurs de l'application.
 */

/* 16 px sur un portable, jusqu'à 22 px sur un écran 4K. */
html:has(body.site) {
  font-size: clamp(16px, 0.45vw + 9px, 22px);
}

/* `theme.css` fige la page à la hauteur de la fenêtre et l'agrandit : c'est la coque de
   l'application. Une page de lecture défile, à la taille que fixe la racine. */
body.site {
  zoom: 1;
  height: auto;
  min-height: 100dvh;
  overflow: auto;
  display: block;
  font-size: 1.0625rem;
  line-height: 1.6;
}
/* `layout.css` fait de `main` la grille liste + détail de l'application. */
.site main {
  display: block;
}

.site a {
  color: var(--accent);
  text-underline-offset: 3px;
}
.site a:focus-visible,
.site button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
.site .btn {
  font-size: 0.9375rem;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
}
.site .btn.big {
  font-size: 1.0625rem;
  padding: 0.75rem 1.5rem;
  border-radius: 0.625rem;
}
.site code {
  font-family: var(--mono);
  font-size: 0.85em;
  color: var(--fg);
  background: var(--sunken);
  border: 1px solid var(--line);
  border-radius: 0.3rem;
  padding: 0.05em 0.35em;
  overflow-wrap: anywhere;
}

.page {
  max-width: 76rem;
  margin: 0 auto;
  padding: 0 2rem;
}

/* ---------- En-tête ---------- */
.site-head {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 1.5rem 0;
}
.site-head .brand {
  color: var(--fg);
  text-decoration: none;
  font-size: 1.125rem;
}
.site-head .brand .logo {
  width: 2.5rem;
  height: 2.5rem;
}
.site-head nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 1.75rem;
  font-size: 0.9375rem;
}
.site-head nav a:not(.btn) {
  color: var(--muted);
  text-decoration: none;
}
.site-head nav a:not(.btn):hover {
  color: var(--fg);
}

/* ---------- Accueil : l'accroche ---------- */
/* Le titre, la promesse et le bouton à gauche ; Poukey à droite, loupe en main. */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 24rem;
  align-items: center;
  gap: 3rem;
  padding: 3rem 0 2.5rem;
}
.hero h1 {
  margin: 0 0 1.5rem;
  max-width: 11em;
  font-size: 4.5rem;
  line-height: 1;
  font-weight: 700;
  letter-spacing: -0.045em;
  text-wrap: balance;
}
/* La devise du hibou, dans son regard sarcelle. */
.eyebrow {
  margin: 0 0 1.25rem;
  color: var(--owl-teal);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.hero .lead {
  max-width: 34rem;
  margin: 0 0 1.75rem;
  font-size: 1.1875rem;
  color: var(--muted);
}
.cta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
}
.cta small {
  color: var(--muted);
  font-size: 0.875rem;
}
/* L'action de la page : pleine, là où celle de l'application reste discrète. */
.site .btn.solid {
  font-size: 1.0625rem;
  font-weight: 600;
  padding: 0.8rem 1.6rem;
  border-radius: 0.625rem;
  border-color: var(--accent);
  background: var(--accent);
  color: var(--bg);
}
.site .btn.solid:hover {
  filter: brightness(1.1);
}

/* ---------- Accueil : la frise ---------- */
/* Posée à même la page, sans cadre : c'est l'élément fort, le reste reste sobre. */
.frise {
  margin: 0 0 2rem;
}
/* Sur téléphone la frise garde une taille lisible et défile dans son cadre. */
.frise-scroll {
  overflow-x: auto;
}
.frise svg {
  display: block;
  width: 100%;
  min-width: 46rem;
  height: auto;
}
.frise .lanes line {
  stroke: var(--line-strong);
}
.frise .who text {
  fill: var(--muted);
  font: 15px var(--sans);
}
.frise .ticks text {
  fill: var(--muted);
  font: 12px var(--mono);
  text-anchor: middle;
}
.frise .hp {
  fill: none;
  stroke: var(--c-hp);
  stroke-width: 2;
  stroke-linejoin: round;
}
.frise .kick {
  fill: var(--c-interrupt);
}
.frise .miss {
  stroke: var(--c-miss);
  stroke-width: 3;
  stroke-linecap: round;
}
.frise .def {
  fill: var(--d-major);
}
.frise .death {
  fill: var(--c-death);
}
.frise .death-line {
  stroke: var(--c-death);
  stroke-opacity: 0.6;
  stroke-dasharray: 4 4;
}
/* Les deux verdicts que la frise illustre, écrits là où ils tombent. */
.frise .note {
  font: 600 15px var(--sans);
}
.frise .note.bad {
  fill: var(--text-bad);
}
.frise .note.sub {
  fill: var(--fg);
  font-weight: 400;
}
.frise .note.warn {
  fill: var(--c-interrupt);
}
/* Le rideau et la tête de lecture : ils glissent une fois vers la droite et découvrent
   la clé à vitesse constante, comme on la relirait. */
.frise .sweep rect {
  fill: var(--bg);
}
.frise .sweep line {
  stroke: var(--accent);
  stroke-width: 2;
}
.frise .sweep {
  animation: sweep 3.2s linear 0.4s both;
}
@keyframes sweep {
  to {
    transform: translateX(1120px);
  }
}
@media (prefers-reduced-motion: reduce) {
  .frise .sweep {
    display: none;
  }
}
.frise figcaption {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  margin-top: 1rem;
  font-size: 0.875rem;
  color: var(--muted);
}
.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
/* Pastille d'un type de marqueur : la même couleur que sur la frise de l'application. */
.dot {
  display: inline-block;
  width: 0.6rem;
  height: 0.6rem;
  margin-right: 0.5rem;
  border-radius: 50%;
  vertical-align: 0.05em;
}
.dot.kick {
  background: var(--c-interrupt);
}
.dot.miss {
  background: var(--c-miss);
}
.dot.def {
  background: var(--d-major);
}
.dot.death {
  background: var(--c-death);
}
.dot.hp {
  background: var(--c-hp);
}

/* ---------- Accueil : les sections ---------- */
.block {
  padding: 5rem 0;
  border-top: 1px solid var(--line-soft);
}
.block h2,
.closing h2 {
  margin: 0 0 2.5rem;
  max-width: 20em;
  font-size: 2.25rem;
  line-height: 1.15;
  font-weight: 680;
  letter-spacing: -0.03em;
}
.block h3 {
  margin: 0 0 0.5rem;
  font-size: 1.1875rem;
  font-weight: 620;
}
.block p,
.block dd {
  margin: 0;
  color: var(--muted);
}
.block dl {
  margin: 0;
}
.block dt {
  margin-bottom: 0.35rem;
  font-size: 1.125rem;
  font-weight: 620;
}

/* Ce que le rapport montre : chaque entrée est une piste, de la couleur de son marqueur. */
.found dl {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2.5rem 4rem;
}
.found dl > div {
  padding-left: 1.25rem;
  border-left: 3px solid;
}
.found .death {
  border-color: var(--c-death);
}
.found .kick {
  border-color: var(--c-interrupt);
}
.found .def {
  border-color: var(--d-major);
}
.found .hp {
  border-color: var(--c-hp);
}

/* Le chemin du dossier Logs et son bouton : à coller dans la fenêtre de choix. */
.path {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin: 0.75rem 0;
}
.path code {
  font-size: 0.8rem;
}
.path .btn {
  font-size: 0.8125rem;
  padding: 0.3rem 0.7rem;
}

/* Confidentialité : la question qu'on se pose avant de cliquer, et ses trois réponses. */
.private {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 4rem;
}
.private h2 {
  margin-bottom: 1.25rem;
}
.private p + p {
  margin-top: 1rem;
}
.private dl > div {
  padding: 1rem 0;
  border-bottom: 1px solid var(--line-soft);
}
.private dl > div:first-child {
  padding-top: 0.5rem;
}
.private dl > div:last-child {
  border-bottom: 0;
}

/* Dernier appel, pour qui a tout lu. */
.closing {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem 3rem;
  padding: 4rem 0 2rem;
  border-top: 1px solid var(--line-soft);
}
.closing h2 {
  margin: 0;
}

/* Le lien qui prolonge une section de l'accueil vers sa page. */
.block .more-link {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 2rem;
  margin-top: 2.5rem;
}

/* Les deux terrains : Poukey à gauche, la promesse à droite ; toute la ligne mène à la page. */
.modes {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2rem 4rem;
}
.modes h2 {
  grid-column: 1 / -1;
  margin-bottom: 0.5rem;
}
.site .mode {
  display: grid;
  grid-template-columns: 9rem minmax(0, 1fr);
  align-items: start;
  gap: 1.5rem;
  color: inherit;
  text-decoration: none;
}
.mode img {
  width: 100%;
  height: auto;
  transition: transform 0.2s;
}
.mode:hover img {
  transform: translateY(-0.25rem);
}
.mode .more {
  display: inline-block;
  margin-top: 0.75rem;
  color: var(--accent);
  font-size: 0.9375rem;
}
.mode:hover .more {
  text-decoration: underline;
}

/* Première fois : la seule chose à savoir avant d'ouvrir l'analyseur, et le chemin à copier. */
.first {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 2rem 4rem;
}
.first h2 {
  margin-bottom: 1.25rem;
}
.first p {
  max-width: 38rem;
}
.first p + p {
  margin-top: 1rem;
}
.first .path {
  margin: 0;
}

/* ---------- Poukey ---------- */
/* Les illustrations sont détourées : un halo bleu nuit, la teinte de la capuche, les pose sur
   le fond sombre sans cadre ni carte. */
.pet {
  display: block;
  width: 100%;
  height: auto;
  background: radial-gradient(closest-side, var(--owl-navy), transparent);
}

/* ---------- Pages : l'en-tête ---------- */
/* Même geste que l'accueil, un cran plus bas : le sujet à gauche, Poukey qui l'illustre à droite. */
.page-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 19rem;
  align-items: center;
  gap: 3rem;
  padding: 2rem 0 3rem;
}
.page-hero h1 {
  margin: 0 0 1.25rem;
  max-width: 14em;
  font-size: 3.25rem;
  line-height: 1.05;
  font-weight: 700;
  letter-spacing: -0.04em;
  text-wrap: balance;
}
.page-hero .lead {
  max-width: 36rem;
  margin: 0;
  font-size: 1.1875rem;
  color: var(--muted);
}
/* La page introuvable : rien d'autre à lire, le bouton suit la phrase. */
.lost {
  min-height: 60vh;
}
.lost .cta {
  margin-top: 2rem;
}

/* ---------- Pages : le texte ---------- */
/* Le titre de chaque partie dans la marge, le texte à droite : on parcourt la marge, on lit la colonne. */
.article section {
  display: grid;
  grid-template-columns: 15rem minmax(0, 44rem);
  gap: 0.75rem 4rem;
  padding: 2.5rem 0;
  border-top: 1px solid var(--line-soft);
}
.article h2 {
  margin: 0;
  font-size: 1.1875rem;
  font-weight: 650;
  letter-spacing: -0.01em;
}
.article p {
  margin: 0;
  color: var(--muted);
}
.article section > div > * + * {
  margin-top: 1rem;
}
.article b {
  color: var(--fg);
  font-weight: 600;
}
/* Une précision qui éclaire la règle sans en faire partie. */
.aside {
  padding-left: 1rem;
  border-left: 2px solid var(--line-strong);
  font-size: 0.9375rem;
}
.site kbd {
  font-family: var(--mono);
  font-size: 0.8em;
  color: var(--fg);
  background: var(--sunken);
  border: 1px solid var(--line-strong);
  border-bottom-width: 2px;
  border-radius: 0.3rem;
  padding: 0.05em 0.4em;
}

/* Un tableau de référence : la colonne de gauche nomme, celle de droite explique. */
.facts {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
}
.facts th {
  padding: 0 1.5rem 0.5rem 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 600;
  text-align: left;
}
.facts td {
  padding: 0.6rem 1.5rem 0.6rem 0;
  border-bottom: 1px solid var(--line-soft);
  color: var(--muted);
  vertical-align: top;
}
.facts td:first-child {
  width: 15rem;
  color: var(--fg);
  font-weight: 560;
}

/* Une liste de termes courts, sur deux colonnes. */
.terms {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem 2.5rem;
  margin: 0;
}
.terms dt {
  margin-bottom: 0.2rem;
  font-weight: 600;
}
.terms dd {
  margin: 0;
  color: var(--muted);
  font-size: 0.9375rem;
}

/* La légende de la frise, avec les pastilles de l'application. */
.key {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem 2rem;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--muted);
  font-size: 0.9375rem;
}
.key b {
  font-weight: 560;
}
.dot.dmg {
  background: var(--o-major);
}
.dot.cc {
  background: var(--c-cc);
}
.dot.dispel {
  background: var(--c-dispel);
}
.dot.conso {
  background: var(--c-conso);
}

/* La suite de la lecture : là où celui qui arrive au bout se demande où aller. */
.next {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  padding-top: 2.5rem;
  border-top: 1px solid var(--line-soft);
}
.site .next a {
  flex: 1 1 16rem;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 1.1rem 1.25rem;
  border: 1px solid var(--line);
  border-radius: 0.625rem;
  color: var(--fg);
  font-size: 1.125rem;
  font-weight: 600;
  text-decoration: none;
}
.site .next a:hover {
  border-color: var(--line-hot);
  background: var(--panel);
}
.next small {
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 400;
}

/* ---------- Questions fréquentes ---------- */
.faq {
  max-width: 50rem;
}
.faq h2 {
  margin: 3rem 0 0.5rem;
  color: var(--owl-teal);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.faq h2:first-child {
  margin-top: 0;
}
.faq details {
  border-bottom: 1px solid var(--line-soft);
}
.faq summary {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
  font-size: 1.0625rem;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary::after {
  content: '+';
  color: var(--muted);
  font-weight: 400;
}
.faq details[open] summary::after {
  content: '−';
}
.faq details p {
  max-width: 44rem;
  margin: 0 0 1.25rem;
  color: var(--muted);
}

/* ---------- Page de texte (confidentialité, mentions légales) ---------- */
.prose {
  max-width: 46rem;
  padding: 3rem 0 1rem;
}
/* Sous l'en-tête illustré, le texte commence tout de suite. */
.page-hero + .prose {
  padding-top: 0;
}
.prose h1 {
  margin: 0 0 0.5rem;
  font-size: 2.5rem;
  font-weight: 680;
  letter-spacing: -0.025em;
}
.prose h2 {
  margin: 2.75rem 0 0.6rem;
  font-size: 1.375rem;
  font-weight: 650;
}
.prose li + li {
  margin-top: 0.5rem;
}
.prose .updated {
  color: var(--muted);
  margin-top: 0;
}
.forget {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  margin-top: 1rem;
}
.forget output {
  color: var(--text-good);
}

/* ---------- Formulaire de contact ---------- */
.contact-form {
  display: grid;
  gap: 1.25rem;
}
.contact-form label {
  display: grid;
  gap: 0.4rem;
  font-weight: 550;
}
.contact-form input,
.contact-form textarea {
  padding: 0.65rem 0.8rem;
  background: var(--sunken);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--fg);
  font: inherit;
  font-weight: 400;
}
.contact-form textarea {
  resize: vertical;
}
.contact-form :is(input, textarea):focus {
  border-color: var(--line-hot);
  outline: none;
}
.contact-send {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
}
.contact-send output {
  color: var(--text-bad);
}
.contact-send output.ok {
  color: var(--text-good);
}

/* ---------- En-tête et pied, écrits par `js/site.js` ---------- */
/* Tant que l'en-tête est vide, il garde sa hauteur : la page ne saute pas à l'arrivée du menu. */
.site-head:empty {
  min-height: 5.5rem;
}
.site-head nav a[aria-current] {
  color: var(--fg);
}

.site-foot {
  margin-top: 6rem;
  padding: 3.5rem 0 2rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.875rem;
}
.foot-main {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr));
  gap: 2.5rem 3rem;
}
.foot-brand .brand {
  color: var(--fg);
  font-size: 1rem;
  text-decoration: none;
}
.foot-brand .brand .logo {
  width: 2rem;
  height: 2rem;
}
.foot-brand p {
  max-width: 20rem;
  margin: 1rem 0;
}
.site-foot nav {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.site-foot h2 {
  margin: 0 0 0.4rem;
  color: var(--fg);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.site .site-foot nav a {
  color: var(--muted);
  text-decoration: none;
}
.site .site-foot nav a:hover,
.site .site-foot nav a[aria-current] {
  color: var(--fg);
}
.foot-legal {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem 2rem;
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line-soft);
  font-size: 0.8125rem;
}
.foot-legal p {
  max-width: 44rem;
  margin: 0;
}

/* ---------- Écrans étroits ---------- */
@media (max-width: 1000px) {
  .hero,
  .page-hero,
  .first,
  .private {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .hero {
    padding: 2rem 0 2.5rem;
  }
  .hero h1 {
    font-size: 3.5rem;
  }
  /* Poukey passe au-dessus du titre, en plus petit : il annonce la page sans la repousser. */
  .hero .pet,
  .page-hero .pet {
    order: -1;
    width: 11rem;
  }
  .article section,
  .modes {
    grid-template-columns: 1fr;
  }
  .foot-main {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .foot-brand {
    grid-column: 1 / -1;
  }
}
@media (max-width: 600px) {
  .page {
    padding: 0 1rem;
  }
  .site-head nav a:not(.btn) {
    display: none;
  }
  .hero h1 {
    font-size: 2.5rem;
  }
  .page-hero h1 {
    font-size: 2.25rem;
  }
  .block {
    padding: 3.5rem 0;
  }
  .block h2,
  .closing h2 {
    font-size: 1.75rem;
  }
  .found dl,
  .terms,
  .key {
    grid-template-columns: 1fr;
  }
  .site .mode {
    grid-template-columns: 6rem minmax(0, 1fr);
  }
  .foot-main {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
