/* ==========================================================================
   BlockBlock — Feuille de style
   DA : soirée voxel. Ciel bleu nuit et coucher de soleil de la bannière, blocs aux
   couleurs des lettres du logo (vert, rouge, jaune, bleu, orange), bois du
   ponton, lumière chaude des lanternes. Monnaie : les Bricks (rouge brique).
   Titres et boutons en Bungee (capitales massives, proches des lettres du logo),
   texte courant en Inter.
   ========================================================================== */

/* Polices auto-hébergées (assets/fonts, licence OFL) : aucune requête vers un
   tiers, donc aucune adresse IP transmise à Google à l'affichage du site. */
@font-face {
  font-family: "Inter"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url("assets/fonts/inter-latin-wght-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Inter"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url("assets/fonts/inter-latin-ext-wght-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Bungee"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("assets/fonts/bungee-latin-400-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Bungee"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("assets/fonts/bungee-latin-ext-400-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  /* ----- Nuit (fonds), reprise du ciel de la bannière ----- */
  --night-950: #070b24;
  --night-900: #0b1233;   /* fond de page : même teinte que le premier plan du décor */
  --night-800: #111a45;
  --night-700: #172257;
  --night-600: #1f2c6c;
  --night-500: #2a3a88;

  /* ----- Couleurs des lettres du logo ----- */
  --green-400: #a6e05a;  --green-500: #7cc62f;  --green-700: #4a8a16;
  --red-400:   #f27060;  --red-500:   #e0402f;  --red-700:   #a82618;
  --yellow-300:#ffe08a;  --yellow-400:#ffd04d;  --yellow-500:#f7b81c;  --yellow-700: #b97f05;
  --blue-400:  #5aa6f5;  --blue-500:  #2b86ea;  --blue-700:  #1556b0;
  --orange-400:#ffa057;  --orange-500:#f5801f;  --orange-700:#b8560a;
  --violet-400:#b48cf5;  --violet-500:#9466e6;  --violet-700:#5f3aa8;

  /* ----- Bois du ponton et pierre ----- */
  --wood-900: #2a180b;
  --wood-800: #3d2412;
  --wood-700: #5e3717;
  --wood-600: #7a4920;
  --wood-500: #a26a32;
  --wood-400: #c98d4c;
  --wood-ink: #fbecd2;   /* texte posé sur le bois */

  /* ----- Lanternes ----- */
  --lantern:      #ffc45e;
  --lantern-soft: #ffe2a3;

  /* ----- Bricks (monnaie) : rouge brique ----- */
  --brick-300: #ffb895;
  --brick-400: #ff8f5e;
  --brick-500: #ec6a3f;
  --brick-700: #8f2f1c;

  /* ----- Texte ----- */
  --ink:      #eef2ff;
  --ink-soft: #c5cdea;
  --ink-dim:  #a9b3d8;   /* reste ≥ 4,5:1 même sur le fond plus clair de la modale */

  --discord:      #5865f2;
  --discord-dark: #4653d6;

  /* ----- Tokens « bloc » ----- */
  --edge:      #050818;   /* contour sombre des blocs, comme les lettres du logo */
  --radius:    6px;
  --radius-sm: 4px;
  --line:      rgba(164, 178, 255, .2);
  --field-border: #7b88c4; /* bordure de champ : ≥ 3:1 avec le fond (WCAG 1.4.11) */
  --focus:     #ffd04d;    /* contour de focus clavier, visible sur tous les fonds */
  --bevel:     inset 0 3px 0 rgba(255, 255, 255, .08), inset 0 -4px 0 rgba(0, 0, 0, .28);
  --drop:      0 6px 0 var(--edge);
  --shadow:    0 6px 0 var(--edge), 0 18px 36px rgba(0, 0, 0, .45);
  --glow:      0 0 40px rgba(255, 196, 94, .28);

  --font-title: "Bungee", "Segoe UI Black", "Arial Black", system-ui, sans-serif;
  --font-body:  "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;

  --max-width: 1240px;
}

/* ----- Reset léger ----- */
*, *::before, *::after { box-sizing: border-box; }
/* Un `display` posé par une classe ne doit jamais annuler l'attribut hidden. */
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  /* Damier très discret, comme le grain des blocs du logo */
  background:
    repeating-conic-gradient(rgba(255, 255, 255, .018) 0 25%, transparent 0 50%) 0 0 / 48px 48px,
    radial-gradient(1200px 700px at 50% 112%, rgba(148, 102, 230, .16), transparent 64%),
    var(--night-900);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  /* Bungee n'existe qu'en une graisse : pas de faux gras calculé par le navigateur.
     Inter, variable de 400 à 700, n'est pas concerné. */
  font-synthesis-weight: none;
}
img { max-width: 100%; display: block; }
a { color: var(--yellow-300); text-decoration: none; }
a:hover { text-decoration: underline; }
/* Un lien dans du texte courant ne doit pas se distinguer par la seule couleur. */
.shop-note a, .footer a, .legal a, .thanks__note a, .thanks__legal a, .modal a, .join a { text-decoration: underline; text-underline-offset: 2px; }

/* Focus clavier unique et bien visible, sur tout élément interactif. */
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }

/* Masqué à l'écran, lu par les lecteurs d'écran. */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0; border: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Lien d'évitement : premier arrêt du clavier, visible seulement au focus. */
.skip-link {
  position: fixed;
  top: .6rem; left: .6rem;
  z-index: 2000;
  padding: .6rem 1rem;
  border: 3px solid var(--edge);
  border-radius: var(--radius-sm);
  background: var(--yellow-400);
  color: var(--edge);
  font-weight: 700;
  transform: translateY(-200%);
}
.skip-link:focus { transform: none; }
ul { list-style: none; margin: 0; padding: 0; }
code {
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  background: rgba(0, 0, 0, .35);
  color: var(--yellow-300);
  padding: .05em .4em;
  border-radius: var(--radius-sm);
  font-size: .92em;
}
h1, h2, h3, h4 { font-family: var(--font-title); font-weight: 400; margin: 0; line-height: 1.2; }

/* Icônes pixel (assets/ui) : agrandies sans flou */
.px { image-rendering: pixelated; flex: none; }

/* Mot « BlockBlock » aux couleurs des lettres du logo */
.wordmark {
  font-family: var(--font-title);
  letter-spacing: .02em;
  text-transform: uppercase;
  text-shadow: 0 3px 0 var(--edge);
}
.wordmark > span:nth-child(5n + 1) { color: var(--green-500); }
.wordmark > span:nth-child(5n + 2) { color: var(--red-500); }
.wordmark > span:nth-child(5n + 3) { color: var(--yellow-500); }
.wordmark > span:nth-child(5n + 4) { color: var(--blue-500); }
.wordmark > span:nth-child(5n + 5) { color: var(--orange-500); }

/* ==========================================================================
   HERO / BANNIÈRE
   ========================================================================== */
.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  /* Volontairement compact : le haut de la page doit dépasser dès l'arrivée. */
  padding: 0 0 8.5rem;
  text-align: center;
  color: var(--ink);
}

/* Bannière BlockBlock sans logo (le logo est posé par-dessus en HTML). Le
   dégradé derrière sert de repli tant que l'image n'est pas chargée. */
.hero__bg {
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    url("assets/banner-hero.webp") 50% 62% / cover no-repeat,
    linear-gradient(180deg, #0c1a5c 0%, #1a35a0 40%, #7c66d2 75%, #1a2a6e 100%);
}
/* Voile : assombrit le haut (nav) et le centre (textes, boutons), puis fond la
   bannière dans la couleur de la page. */
.hero__veil {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(62% 48% at 50% 58%, rgba(7, 11, 36, .5), transparent 78%),
    linear-gradient(180deg, rgba(7, 11, 36, .55) 0, rgba(7, 11, 36, 0) 18%, rgba(7, 11, 36, 0) 66%, var(--night-900) 100%);
  pointer-events: none;
}

/* ----- Barre de navigation ----- */
.nav {
  position: relative;
  z-index: 3;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.nav__brand {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  padding: .3rem .75rem .3rem .3rem;
  border: 3px solid var(--edge);
  border-radius: var(--radius-sm);
  background: rgba(11, 18, 51, .78);   /* la bannière est chargée derrière */
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, .1), 0 4px 0 var(--edge);
  font-size: 1.3rem;
  line-height: 1;
}
.nav__brand:hover { text-decoration: none; }
.nav__logo {
  width: 34px; height: 34px;
  filter: drop-shadow(0 3px 0 var(--edge));
}
.nav__links { display: flex; gap: .45rem; }
.nav__links a {
  display: inline-block;
  padding: .45rem .9rem;
  border: 3px solid var(--edge);
  border-radius: var(--radius-sm);
  color: var(--ink);
  font-family: var(--font-title);
  font-size: .88rem;
  background: rgba(11, 18, 51, .78);   /* fond sombre : le ciel est clair derrière */
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, .1), 0 4px 0 var(--edge);
  transition: transform .12s, box-shadow .12s, background .12s;
}
.nav__links a:hover {
  background: var(--night-600);
  transform: translateY(-2px);
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, .12), 0 6px 0 var(--edge);
  text-decoration: none;
}

/* ----- Contenu du hero ----- */
.hero__content {
  position: relative;
  z-index: 3;
  max-width: 860px;
  margin: 0 auto;
  padding: .4rem 1.5rem 0;
}
/* Le plafond en `vh` fait rétrécir le logo sur les écrans peu hauts, ce qui
   garantit que la suite de la page dépasse même sur un portable 768p. */
.hero__logo {
  width: min(400px, 76%);
  height: auto;
  max-height: min(36vh, 380px);
  object-fit: contain;
  margin: 0 auto .4rem;
  filter: drop-shadow(0 10px 0 rgba(5, 8, 24, .45)) drop-shadow(0 0 36px rgba(255, 196, 94, .35));
}
/* Le titre reste lu par Google et les lecteurs d'écran, masqué visuellement
   puisque le logo affiche déjà le nom. */
.hero__logo + .hero__title {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0; border: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.hero__title { font-size: clamp(2.2rem, 7vw, 4rem); }
.hero__tagline {
  margin: .4rem 0 0;
  font-family: var(--font-title);
  font-size: clamp(.85rem, 2vw, 1.05rem);
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #fff;
  text-shadow: 0 2px 0 var(--edge), 0 0 18px rgba(11, 18, 51, .9);
}
.hero__tagline .sep { color: var(--yellow-400); }
.hero__actions {
  margin-top: 1.4rem;
  display: flex;
  flex-wrap: wrap;
  gap: .9rem;
  justify-content: center;
}
.hero__version {
  margin: .9rem auto 0;
  width: fit-content;
  padding: .2rem .7rem;
  border-radius: var(--radius-sm);
  background: rgba(11, 18, 51, .72);
  font-size: .9rem;
  font-weight: 500;
  color: var(--ink);
}

/* ==========================================================================
   LAYOUT : jouer + boutique + sidebar
   ========================================================================== */
.layout {
  max-width: var(--max-width);
  margin: -2.5rem auto 0;
  padding: 0 1.5rem 4.5rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 2rem;
  align-items: start;
  position: relative;
  z-index: 4;
}

/* ----- Titres de section ----- */
.section-head { margin-bottom: 1.8rem; text-align: center; }
.eyebrow {
  display: inline-block;
  margin: 0 0 .6rem;
  padding: .15rem .6rem;
  border: 2px solid var(--edge);
  border-radius: var(--radius-sm);
  background: var(--yellow-500);
  color: #2b1c00;
  font-family: var(--font-title);
  font-size: .75rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  box-shadow: 0 3px 0 var(--edge);
}
.section-head h2 {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: .2em .45em;
  font-size: clamp(1.5rem, 3.2vw, 2.15rem);
  color: #fff;
  text-shadow: 0 3px 0 var(--edge);
}
.h-icon { width: 1.05em; height: 1.05em; filter: drop-shadow(0 3px 0 var(--edge)); }
.section-sub { margin: .7rem auto 0; max-width: 58ch; color: var(--ink-soft); }

.group-title {
  margin: 2.2rem 0 1.4rem;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  gap: .8rem;
  color: var(--ink);
}
/* Un seul enfant flex : le `gap` ne s'applique qu'entre le texte et le trait. */
.group-title__text { flex: none; text-shadow: 0 2px 0 var(--edge); }
.group-title::after {
  content: "";
  flex: 1;
  height: 6px;
  border: 2px solid var(--edge);
  border-radius: 2px;
  background: repeating-linear-gradient(90deg, var(--brick-500) 0 18px, var(--brick-700) 18px 20px);
  opacity: .75;
}

/* ==========================================================================
   REJOINDRE (Java / Bedrock)
   ========================================================================== */
.join { margin-bottom: 3rem; }
.join__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.2rem;
}
.join__card {
  position: relative;
  padding: 1.9rem 1.3rem 1.2rem;
  background: linear-gradient(180deg, var(--night-700), var(--night-800));
  border: 3px solid var(--edge);
  border-radius: var(--radius);
  box-shadow: var(--bevel), var(--drop);
}
.join__card h3 {
  display: flex;
  align-items: center;
  gap: .55rem;
  font-size: 1.2rem;
  color: #fff;
  text-shadow: 0 2px 0 var(--edge);
}
.join__card h3 .px { width: 30px; height: 30px; }
.join__card h3 small {
  font-family: var(--font-body);
  font-size: .8rem;
  font-weight: 600;
  color: var(--ink-dim);
  text-shadow: none;
}
.steps { counter-reset: step; display: grid; gap: .55rem; margin: .9rem 0 0; padding: 0; list-style: none; }
.steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 1.7rem 1fr;
  gap: .6rem;
  align-items: start;
  color: var(--ink-soft);
  font-size: .95rem;
}
.steps li::before {
  content: counter(step);
  display: grid;
  place-items: center;
  width: 1.7rem; height: 1.7rem;
  border: 2px solid var(--edge);
  border-radius: var(--radius-sm);
  background: var(--night-500);
  color: #fff;
  font-family: var(--font-title);
  font-size: .85rem;
  line-height: 1;
}
.steps strong { color: var(--ink); }
.join__note { margin: .9rem 0 0; font-size: .86rem; color: var(--ink-dim); }

/* ==========================================================================
   CARTES DES PACKS
   ========================================================================== */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(258px, 1fr));
  gap: 1.6rem 1.4rem;
}

.card {
  --cap: var(--green-500);
  --cap-dark: var(--green-700);
  position: relative;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, var(--night-700), var(--night-800));
  border: 3px solid var(--edge);
  border-radius: var(--radius);
  padding: 2.3rem 1.3rem 1.3rem;
  box-shadow: var(--bevel), var(--drop);
  transition: transform .15s ease, box-shadow .15s ease;
}
/* Couvercle coloré qui « coule » comme la mousse sur le logo */
.card::before {
  content: "";
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 22px;
  border-radius: 3px 3px 0 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .35) 0 2px, transparent 2px),
    linear-gradient(180deg, var(--cap) 0 6px, var(--cap-dark) 6px);
  -webkit-mask: url("assets/ui/drip.svg") repeat-x 0 0 / 64px 20px;
          mask: url("assets/ui/drip.svg") repeat-x 0 0 / 64px 20px;
  pointer-events: none;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--bevel), 0 10px 0 var(--edge), 0 0 0 2px var(--cap);
}
.card--red    { --cap: var(--red-500);    --cap-dark: var(--red-700); }
.card--green  { --cap: var(--green-500);  --cap-dark: var(--green-700); }
.card--yellow { --cap: var(--yellow-500); --cap-dark: var(--yellow-700); }
.card--blue   { --cap: var(--blue-500);   --cap-dark: var(--blue-700); }
.card--orange { --cap: var(--orange-500); --cap-dark: var(--orange-700); }
.card--violet { --cap: var(--violet-500); --cap-dark: var(--violet-700); }

/* Carte mise en avant : cadre doré et lueur de lanterne */
.card--featured {
  background: linear-gradient(180deg, #232f72, #151e52);
  border-color: var(--edge);
  box-shadow: var(--bevel), 0 0 0 3px var(--yellow-500), var(--drop), 0 0 46px rgba(255, 196, 94, .32);
}
.card--featured:hover { box-shadow: var(--bevel), 0 0 0 3px var(--yellow-400), 0 10px 0 var(--edge), 0 0 56px rgba(255, 196, 94, .42); }

.card__ribbon {
  position: absolute;
  top: 1.7rem;
  right: 1rem;
  padding: .12rem .55rem;
  border: 2px solid var(--edge);
  border-radius: var(--radius-sm);
  background: var(--night-900);
  color: var(--ink);
  font-family: var(--font-title);
  font-size: .68rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.card__ribbon--hot {
  background: var(--yellow-500);
  color: #2b1c00;
  box-shadow: 0 3px 0 var(--edge), 0 0 18px rgba(255, 196, 94, .55);
}

/* Emplacement façon inventaire, pour l'icône pixel du Pack */
.card__icon {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  margin-bottom: .8rem;
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, .32);
  box-shadow: inset 3px 3px 0 rgba(0, 0, 0, .45), inset -3px -3px 0 rgba(255, 255, 255, .09), 0 0 0 2px var(--edge);
}
.card__icon img { width: 48px; height: 48px; }
.card__title { font-size: 1.3rem; color: #fff; text-shadow: 0 2px 0 var(--edge); }

.card__footer {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 2px dashed rgba(164, 178, 255, .22);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: .75rem;
  text-align: center;
}
.price {
  margin: 0;
  font-family: var(--font-title);
  font-size: 1.7rem;
  white-space: nowrap;
  color: #fff;
  line-height: 1;
  text-shadow: 0 3px 0 var(--edge);
}
.price span { font-size: 1.05rem; color: var(--ink-soft); }

.shop-note {
  margin-top: 2.2rem;
  padding: 1rem 1.2rem;
  background: rgba(0, 0, 0, .22);
  border: 2px solid var(--line);
  border-radius: var(--radius);
  font-size: .9rem;
  color: var(--ink-soft);
}

/* ----- Montant de Bricks ----- */
.pack__amount {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: .1rem .5rem;
  margin: .5rem 0 .45rem;
  padding: .85rem 1rem;
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, .3);
  box-shadow: inset 3px 3px 0 rgba(0, 0, 0, .4), inset -3px -3px 0 rgba(255, 255, 255, .07), 0 0 0 2px var(--edge);
}
.pack__coin-icon { width: 28px; height: 28px; }
.pack__coins {
  font-family: var(--font-title);
  font-size: 1.95rem;
  line-height: 1;
  white-space: nowrap;
  color: var(--brick-400);
  text-shadow: 0 3px 0 var(--edge);
}
.pack__currency {
  flex-basis: 100%;
  text-align: center;
  font-family: var(--font-title);
  font-size: .8rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--brick-300);
}

.pack__bonus {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  align-self: center;
  margin-bottom: 1rem;
  padding: .2rem .7rem;
  border: 2px solid var(--edge);
  border-radius: var(--radius-sm);
  font-family: var(--font-title);
  font-size: .78rem;
  color: #102406;
  background: var(--green-500);
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, .35), 0 3px 0 var(--edge);
}
.pack__bonus--none {
  background: var(--night-600);
  color: var(--ink-soft);
  box-shadow: 0 3px 0 var(--edge);
}

.pack__breakdown {
  margin: 0 0 .8rem;
  text-align: center;
  font-size: .9rem;
  font-weight: 600;
  color: var(--ink-soft);
}
.pack__breakdown strong { color: var(--yellow-400); font-weight: 800; }

/* ==========================================================================
   BOUTONS (blocs qui s'enfoncent au clic)
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  padding: .7rem 1.25rem;
  border: 3px solid var(--edge);
  border-radius: var(--radius-sm);
  font-family: var(--font-title);
  font-size: .92rem;
  font-weight: 400;
  letter-spacing: .02em;
  line-height: 1.25;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: inset 0 3px 0 rgba(255, 255, 255, .32), inset 0 -4px 0 rgba(0, 0, 0, .22), 0 5px 0 var(--edge);
  transition: transform .1s ease, box-shadow .1s ease, filter .1s ease;
}
.btn:hover {
  transform: translateY(-2px);
  text-decoration: none;
  filter: brightness(1.07);
  box-shadow: inset 0 3px 0 rgba(255, 255, 255, .32), inset 0 -4px 0 rgba(0, 0, 0, .22), 0 7px 0 var(--edge);
}
.btn:active {
  transform: translateY(4px);
  box-shadow: inset 0 3px 0 rgba(255, 255, 255, .22), inset 0 -2px 0 rgba(0, 0, 0, .22), 0 1px 0 var(--edge);
}
.btn:disabled { cursor: progress; filter: saturate(.6); transform: none; }
.btn svg { width: 18px; height: 18px; fill: currentColor; flex: none; }
.btn strong { font-weight: 400; }
/* L'adresse du serveur garde ses minuscules, en chasse fixe comme dans le jeu */
.btn [data-ip-text] { font-family: ui-monospace, "SFMono-Regular", Consolas, monospace; font-weight: 700; font-size: 1.02em; text-transform: none; letter-spacing: 0; }

/* Vert du « B » du logo */
.btn--primary { background: linear-gradient(180deg, var(--green-400), var(--green-500) 55%); color: #102406; }
.btn--discord { background: linear-gradient(180deg, var(--discord), var(--discord-dark) 60%); color: #fff; }
/* Bouton d'achat : jaune des engrenages */
.btn--buy { background: linear-gradient(180deg, var(--yellow-400), var(--yellow-500) 60%); color: #2b1c00; }
.btn--ghost { background: linear-gradient(180deg, var(--night-500), var(--night-600) 60%); color: var(--ink); }

.btn--block { width: 100%; margin-top: .7rem; }
.btn--sm { padding: .4rem .8rem; font-size: .8rem; }

/* ==========================================================================
   SIDEBAR (staff + infos)
   ========================================================================== */
.sidebar { display: grid; gap: 1.4rem; position: sticky; top: 1.5rem; }

.panel {
  background: linear-gradient(180deg, var(--night-700), var(--night-800));
  border: 3px solid var(--edge);
  border-radius: var(--radius);
  padding: 0 1.1rem 1.2rem;
  box-shadow: var(--bevel), var(--drop);
  overflow: hidden;
}
/* En-tête en planches de bois, comme le ponton */
.panel__title {
  display: flex;
  align-items: center;
  gap: .55rem;
  margin: 0 -1.1rem 1rem;
  padding: .6rem 1.1rem;
  font-size: 1rem;
  color: var(--wood-ink);
  text-shadow: 0 2px 0 var(--wood-900);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .14) 0 2px, transparent 2px),
    repeating-linear-gradient(90deg, var(--wood-600) 0 46px, var(--wood-700) 46px 49px);
  border-bottom: 3px solid var(--edge);
}
.panel__title .px { width: 24px; height: 24px; }
.panel--cta { text-align: center; }
.panel--cta .panel__title { justify-content: center; }
.panel__ip {
  margin: 0 0 .3rem;
  font-family: ui-monospace, Consolas, monospace;
  font-weight: 700;
  font-size: 1rem;
  color: var(--yellow-300);
  background: rgba(0, 0, 0, .35);
  border-radius: var(--radius-sm);
  box-shadow: inset 3px 3px 0 rgba(0, 0, 0, .4), 0 0 0 2px var(--edge);
  padding: .55rem;
}

.staff-rank {
  margin: 0 0 .55rem;
  font-family: var(--font-title);
  font-size: .75rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--yellow-400);
}

.staff-list { display: grid; gap: .55rem; }
.staff {
  display: flex;
  align-items: center;
  gap: .7rem;
  padding: .45rem .6rem;
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, .22);
  box-shadow: 0 0 0 2px var(--edge);
  transition: transform .15s, background .15s;
}
.staff:hover { transform: translateX(3px); background: rgba(255, 255, 255, .06); }
.staff__avatar {
  width: 38px; height: 38px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  image-rendering: pixelated; /* rendu net pour les têtes Minecraft */
  box-shadow: 0 0 0 2px var(--edge);
  flex: none;
}
.staff__name { font-weight: 700; flex: 1; color: var(--ink); }
.staff__tag {
  font-family: var(--font-title);
  font-size: .65rem;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: .1rem .45rem;
  border: 2px solid var(--edge);
  border-radius: var(--radius-sm);
}
.staff__tag--owner { background: var(--yellow-500); color: #2b1c00; }

.info-list { display: grid; gap: .45rem; font-size: .92rem; }
.info-list li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: .45rem;
  border-bottom: 2px dashed rgba(164, 178, 255, .16);
}
.info-list li:last-child { border-bottom: 0; padding-bottom: 0; }
.info-list span { color: var(--ink-dim); }
.info-list strong { color: var(--ink); text-align: right; }

/* Pastille « joueurs connectés » (live) */
.server-status {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  margin: 1.2rem auto 0;
  padding: .35rem .9rem;
  border: 3px solid var(--edge);
  border-radius: var(--radius-sm);
  font-family: var(--font-title);
  font-size: .85rem;
  color: var(--ink);
  background: rgba(11, 18, 51, .85);
  box-shadow: 0 4px 0 var(--edge);
}
.server-status__dot {
  width: 10px; height: 10px;
  background: var(--ink-dim);
  box-shadow: 0 0 0 2px var(--edge);
  flex: none;
}
.server-status.is-online .server-status__dot {
  background: var(--green-500);
  animation: pulse-online 1.6s steps(2) infinite;
}
.server-status.is-offline .server-status__dot { background: var(--red-500); }
@keyframes pulse-online {
  0%, 100% { box-shadow: 0 0 0 2px var(--edge), 0 0 0 0 rgba(124, 198, 47, .6); }
  50%      { box-shadow: 0 0 0 2px var(--edge), 0 0 0 6px rgba(124, 198, 47, 0); }
}

/* ==========================================================================
   FOOTER : le ponton en bois, bordé d'herbe
   ========================================================================== */
.footer {
  position: relative;
  text-align: center;
  padding: 3rem 1.5rem 2.6rem;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, .25), transparent 40px),
    repeating-linear-gradient(180deg, var(--wood-700) 0 30px, var(--wood-800) 30px 33px);
  border-top: 3px solid var(--edge);
  color: var(--wood-ink);
  font-size: .92rem;
}
.footer::before {
  content: "";
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 20px;
  background: linear-gradient(180deg, var(--green-400) 0 2px, var(--green-500) 2px 6px, var(--green-700) 6px);
  -webkit-mask: url("assets/ui/drip.svg") repeat-x 0 0 / 64px 20px;
          mask: url("assets/ui/drip.svg") repeat-x 0 0 / 64px 20px;
}
.footer a { color: var(--yellow-300); }
.footer__brand { margin: 0 0 .35rem; font-size: 1.6rem; line-height: 1.3; }
.footer__links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .35rem 1.1rem;
  margin-top: 1rem;
}
/* La fonction de rétractation doit rester visible et directement accessible (art. D. 221-5). */
.footer__withdraw { font-weight: 700; color: var(--yellow-400) !important; }
.footer__legal { margin-top: .9rem; font-size: .82rem; color: var(--wood-ink); opacity: .92; }

/* ==========================================================================
   MODALE D'ACHAT
   ========================================================================== */
.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 1.2rem;
  background: rgba(5, 8, 24, .78);
  backdrop-filter: blur(4px);
}
.modal[hidden] { display: none; }
.modal__box {
  width: min(470px, 100%);
  max-height: calc(100vh - 2.4rem);
  overflow-y: auto;
  background: linear-gradient(180deg, var(--night-600), var(--night-700));
  border: 3px solid var(--edge);
  border-radius: var(--radius);
  box-shadow: var(--bevel), 0 0 0 3px var(--yellow-500), 0 8px 0 var(--edge), 0 30px 60px rgba(0, 0, 0, .6);
  padding: 1.5rem 1.4rem 1.2rem;
  animation: modal-in .2s steps(4);
}
@keyframes modal-in {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}
.modal__title { display: flex; align-items: center; gap: .5rem; font-size: 1.25rem; color: #fff; text-shadow: 0 2px 0 var(--edge); }
.modal__title .px { width: 26px; height: 26px; }
.modal__pack {
  margin: .5rem 0 1.1rem;
  font-weight: 700;
  color: var(--yellow-400);
}
.modal__label {
  display: block;
  font-family: var(--font-title);
  font-size: .78rem;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: .35rem;
}
.modal__input {
  width: 100%;
  padding: .7rem .9rem;
  font: inherit;
  color: #fff;
  background: rgba(5, 8, 24, .6);
  border: 3px solid var(--field-border);
  border-radius: var(--radius-sm);
  box-shadow: inset 3px 3px 0 rgba(0, 0, 0, .35);
  transition: border-color .15s;
}
.modal__input::placeholder { color: var(--ink-dim); }
.modal__input:focus-visible { border-color: var(--yellow-400); outline-offset: 3px; }
.modal__hint { margin: .5rem 0 0; font-size: .84rem; color: var(--ink-dim); }
/* Rappel du préfixe Floodgate : sans le point, le pseudo Bedrock est introuvable
   côté serveur et la livraison échoue alors que le paiement est encaissé. */
.modal__hint--bedrock {
  margin-top: .55rem;
  padding: .5rem .65rem;
  border: 2px solid var(--edge);
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, .25);
  line-height: 1.45;
}
.modal__hint--bedrock code { color: var(--ink); }
.modal__error {
  margin: .6rem 0 0;
  min-height: 1.1em;
  font-size: .87rem;
  font-weight: 600;
  color: #ffb4a8;
}
.modal__actions { display: flex; gap: .7rem; margin-top: 1.1rem; }
.modal__actions .btn { flex: 1; white-space: normal; }
.modal__legal {
  margin: 1rem 0 0;
  text-align: center;
  font-size: .8rem;
  color: var(--ink-dim);
}
/* Cases à cocher de la commande : jamais pré-cochées (consentement exprès). */
.consent { margin: 1rem 0 0; padding: 0; border: 0; display: grid; gap: .7rem; }
.consent__item {
  display: grid;
  grid-template-columns: 1.15rem 1fr;
  gap: .6rem;
  align-items: start;
  font-size: .86rem;
  line-height: 1.45;
  color: var(--ink);
  cursor: pointer;
}
.consent__item input { width: 1.15rem; height: 1.15rem; margin: .12rem 0 0; accent-color: var(--green-500); cursor: pointer; }

/* ==========================================================================
   PAGE MERCI (récapitulatif de commande)
   ========================================================================== */
/* Bannière allégée : juste la nav, sans le gros contenu du hero. */
.hero--slim { padding-bottom: 5.5rem; }
.hero--slim .hero__bg { background-position: 50% 46%, 0 0; }

.thanks {
  max-width: 640px;
  margin: -1.5rem auto 0;
  padding: 0 1.5rem 4.5rem;
  position: relative;
  z-index: 4;
}
.thanks__card {
  background: linear-gradient(180deg, var(--night-700), var(--night-800));
  border: 3px solid var(--edge);
  border-radius: var(--radius);
  padding: 2.2rem 1.8rem;
  box-shadow: var(--bevel), var(--shadow);
  text-align: center;
}
.thanks__badge {
  font-size: 3rem;
  line-height: 1;
  margin-bottom: .5rem;
}
.thanks__title { font-size: clamp(1.4rem, 3.4vw, 1.9rem); color: #fff; text-shadow: 0 3px 0 var(--edge); }
.thanks__sub { margin: .6rem auto 1.6rem; max-width: 46ch; color: var(--ink-soft); }

/* Numéro de commande : mis en avant, avec bouton copier. */
.order-id {
  margin: 0 auto 1.6rem;
  padding: 1rem 1.2rem;
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, .3);
  box-shadow: inset 3px 3px 0 rgba(0, 0, 0, .4), 0 0 0 2px var(--edge);
}
.order-id__label {
  display: block;
  font-family: var(--font-title);
  font-size: .75rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--yellow-400);
  margin-bottom: .5rem;
}
.order-id__row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .8rem;
  flex-wrap: wrap;
}
.order-id__value {
  font-family: var(--font-title);
  font-size: 1.4rem;
  letter-spacing: .06em;
  color: #fff;
  text-shadow: 0 3px 0 var(--edge);
}

.recap {
  display: grid;
  text-align: left;
  margin: 0 0 1.4rem;
}
.recap li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding: .7rem .2rem;
  border-bottom: 2px dashed rgba(164, 178, 255, .16);
}
.recap li:last-child { border-bottom: 0; }
.recap span { color: var(--ink-soft); font-size: .92rem; }
.recap strong { color: var(--ink); font-weight: 700; text-align: right; }
.recap__amount { color: var(--brick-400) !important; font-family: var(--font-title); font-weight: 400 !important; font-size: 1.05rem; }

.thanks__note { margin: 0 0 1.6rem; font-size: .9rem; color: var(--ink-soft); }
.thanks__actions { display: flex; gap: .8rem; justify-content: center; flex-wrap: wrap; }
.thanks__legal { margin: 1.4rem 0 0; font-size: .85rem; color: var(--ink-soft); }

/* ==========================================================================
   PAGES LÉGALES
   ========================================================================== */
.legal {
  max-width: 860px;
  margin: -1.5rem auto 0;
  padding: 0 1.5rem 4.5rem;
  position: relative;
  z-index: 4;
}
.legal__card {
  background: var(--night-800);
  border: 3px solid var(--edge);
  border-radius: var(--radius);
  padding: clamp(1.4rem, 4vw, 2.6rem);
  box-shadow: var(--bevel), var(--shadow);
  overflow-wrap: break-word;
}
.legal h1 { font-size: clamp(1.5rem, 4.4vw, 2.2rem); color: #fff; text-shadow: 0 3px 0 var(--edge); }
.legal h2 { margin: 2.2rem 0 .7rem; font-size: 1.25rem; color: var(--yellow-300); text-shadow: 0 2px 0 var(--edge); }
.legal h3 { margin: 1.4rem 0 .5rem; font-size: 1rem; color: #fff; }
.legal p, .legal li { color: var(--ink); }
.legal p { margin: .7rem 0; }
.legal ul, .legal ol { margin: .7rem 0; padding-left: 1.4rem; }
.legal ul { list-style: square; }
.legal li { margin: .35rem 0; }
.legal__meta { margin-top: .5rem; font-size: .88rem; color: var(--ink-soft) !important; }
.legal__lead {
  margin: 1.2rem 0;
  padding: 1rem 1.2rem;
  background: rgba(0, 0, 0, .25);
  border: 2px solid var(--edge);
  border-left: 6px solid var(--green-500);
  border-radius: var(--radius-sm);
}
/* Encadré imposé par l'annexe à l'article D. 211-3 du code de la consommation. */
.legal__box {
  margin: 1.2rem 0;
  padding: 1.1rem 1.3rem;
  border: 3px solid var(--yellow-500);
  border-radius: var(--radius-sm);
}
.legal__box ol { list-style: none; padding-left: 0; }
/* Donnée à fournir par l'éditeur avant la mise en ligne : voyant exprès. */
.todo { padding: .05em .35em; border-radius: 4px; background: var(--yellow-400); color: #2b1d00; font-weight: 700; }
.table-wrap { overflow-x: auto; margin: 1rem 0; }
.legal table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: .9rem; }
.legal caption { text-align: left; padding-bottom: .5rem; color: var(--ink-soft); font-size: .88rem; }
.legal th, .legal td { padding: .6rem .7rem; border: 2px solid rgba(164, 178, 255, .2); text-align: left; vertical-align: top; color: var(--ink); }
.legal th { background: rgba(0, 0, 0, .3); color: #fff; font-weight: 700; }

/* Formulaire de rétractation en ligne */
.form { display: grid; gap: 1rem; margin-top: 1.2rem; }
.form__field { display: grid; gap: .3rem; }
.form__field label { font-weight: 700; color: #fff; }
.form__hint { margin: 0 !important; font-size: .85rem; color: var(--ink-soft) !important; }
.form__actions { display: flex; flex-wrap: wrap; gap: .7rem; }
.form__actions .btn { white-space: normal; }
.form__error { margin: 0 !important; min-height: 1.2em; font-weight: 600; color: #ffb4a8 !important; }
.receipt { margin: 1.2rem 0; }
.legal .receipt__title { margin-top: 0; }
.receipt dl { display: grid; grid-template-columns: minmax(120px, auto) 1fr; gap: .4rem 1rem; margin: 1rem 0; }
.receipt dt { color: var(--ink-soft); }
.receipt dd { margin: 0; color: var(--ink); font-weight: 600; overflow-wrap: anywhere; }

/* ==========================================================================
   TOAST
   ========================================================================== */
.toast {
  position: fixed;
  left: 50%;
  bottom: 2rem;
  transform: translate(-50%, 160%);
  background: var(--night-600);
  border: 3px solid var(--edge);
  border-left: 8px solid var(--green-500);
  color: #fff;
  font-family: var(--font-title);
  font-size: .9rem;
  padding: .7rem 1.3rem;
  border-radius: var(--radius-sm);
  box-shadow: 0 5px 0 var(--edge), 0 18px 40px rgba(0, 0, 0, .5);
  opacity: 0;
  pointer-events: none;
  transition: transform .25s steps(5), opacity .25s;
  z-index: 1100;
}
.toast.is-visible { transform: translate(-50%, 0); opacity: 1; }

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 980px) {
  .layout { grid-template-columns: 1fr; }
  .sidebar { position: static; }
}

@media (max-width: 640px) {
  .nav { padding: .9rem 1rem; flex-wrap: wrap; justify-content: center; }
  .nav__links { flex-wrap: wrap; justify-content: center; }
  .nav__links a { padding: .4rem .75rem; font-size: .95rem; }
  .hero { padding-bottom: 7rem; }
  .hero__bg { background-image: url("assets/banner-hero-960.webp"), linear-gradient(180deg, #0c1a5c 0%, #1a35a0 40%, #7c66d2 75%, #1a2a6e 100%); }
  .hero__actions .btn { width: 100%; }
  .layout { padding: 0 1rem 3rem; margin-top: -2rem; }
  .legal, .thanks { padding: 0 1rem 3rem; }
}

/* Accessibilité : coupe les animations si l'utilisateur le demande */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  html { scroll-behavior: auto; }
}
