/* Sonic Online : site (accueil, regles, confidentialite) aux couleurs d'Emerald Hill */
/* polices hebergees ici (licence SIL OFL) : rien n'est demande a un autre site */
@font-face { font-family: "Bungee"; font-style: normal; font-weight: 400; font-display: swap; src: url(fonts/bungee-latin.woff2) format("woff2"); }
@font-face { font-family: "Nunito"; font-style: normal; font-weight: 200 1000; font-display: swap; src: url(fonts/nunito-latin.woff2) format("woff2"); }
:root {
  --sky-top: #0b2a9c;
  --sky: #2a62e0;
  --sky-low: #7fb2ff;
  --ink: #16203a;
  --muted: #5a6275;
  --card: #ffffff;
  --gold: #ffcc00;
  --gold-dark: #b38f00;
  --red: #e0261b;
  --grass: #3fbf2a;
  --grass-dark: #1f7a14;
  --dirt: #c86a10;
  --dirt-dark: #8a4206;
  --link: #1446c8;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--sky-top);
  font: 16px/1.6 "Nunito", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
img { max-width: 100%; display: block; }
a { color: var(--link); }
h1, h2, h3, .display { font-family: "Bungee", "Nunito", sans-serif; font-weight: 400; letter-spacing: .02em; }

/* ---------- barre de navigation ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 20px;
  background: rgba(8, 24, 90, .88);
  backdrop-filter: blur(6px);
  border-bottom: 3px solid var(--gold);
}
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; }
.brand .ring {
  width: 26px; height: 26px; border-radius: 50%;
  border: 5px solid var(--gold); box-shadow: inset 0 0 0 2px #fff6, 0 0 0 2px var(--gold-dark);
}
.brand span { font-family: "Bungee", sans-serif; font-size: 1.05rem; }
.brand span b { color: var(--gold); font-weight: 400; }
.topbar nav { display: flex; gap: 4px; flex-wrap: wrap; }
.topbar nav a {
  color: #fff; text-decoration: none; font-weight: 800; font-size: .95rem;
  padding: 6px 12px; border-radius: 999px;
}
.topbar nav a:hover, .topbar nav a[aria-current] { background: #ffffff22; color: var(--gold); }

/* ---------- ciel, nuages, sol en damier ---------- */
.sky {
  position: relative; overflow: hidden;
  background: linear-gradient(180deg, var(--sky-top) 0%, var(--sky) 55%, var(--sky-low) 100%);
}
.clouds::before, .clouds::after {
  content: ""; position: absolute; left: -10%; width: 120%; height: 90px; pointer-events: none;
  background:
    radial-gradient(60px 34px at 8% 60%, #fff 98%, transparent) ,
    radial-gradient(80px 44px at 16% 50%, #fff 98%, transparent),
    radial-gradient(54px 30px at 26% 62%, #fff 98%, transparent),
    radial-gradient(90px 46px at 56% 52%, #fff 98%, transparent),
    radial-gradient(60px 32px at 66% 62%, #fff 98%, transparent),
    radial-gradient(70px 38px at 86% 55%, #fff 98%, transparent);
  opacity: .9; animation: drift 60s linear infinite;
}
.clouds::before { top: 2%; }
.clouds::after { top: 64%; transform: scale(.7); opacity: .5; animation-duration: 90s; }
@keyframes drift { from { translate: 0 0; } to { translate: -8% 0; } }

.ground {
  height: 70px;
  background:
    linear-gradient(180deg, var(--grass) 0 18px, var(--grass-dark) 18px 24px, transparent 24px),
    repeating-conic-gradient(var(--dirt) 0 25%, var(--dirt-dark) 0 50%) 0 24px / 32px 32px;
  border-top: 4px solid #8ce46f;
}

/* ---------- accueil : haut de page ---------- */
.hero { padding: 48px 20px 0; text-align: center; color: #fff; }
.hero-inner { position: relative; z-index: 2; max-width: 1080px; margin: 0 auto; }
.logo-wrap { position: relative; display: inline-block; margin-top: 8px; }
.logo-wrap img { width: min(520px, 86vw); filter: drop-shadow(0 8px 0 #0004); }
.online-badge {
  position: absolute; right: -6px; bottom: -14px;
  font-family: "Bungee", sans-serif; font-size: clamp(1.1rem, 3.4vw, 2rem);
  color: #fff; background: var(--red); padding: 4px 16px; border-radius: 10px;
  border: 4px solid #fff; transform: rotate(-6deg); box-shadow: 0 6px 0 #0005;
}
.tagline { font-size: 1.2rem; font-weight: 800; max-width: 640px; margin: 34px auto 22px; text-shadow: 0 2px 0 #0b2a7a, 0 0 12px #0b2a7acc; }
.cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 26px; border-radius: 12px; text-decoration: none;
  font-family: "Bungee", sans-serif; font-size: 1.05rem;
  transition: transform .08s ease, box-shadow .08s ease;
}
.btn-gold { background: var(--gold); color: var(--ink); box-shadow: 0 5px 0 var(--gold-dark); }
.btn-ghost { background: #ffffff1f; color: #fff; box-shadow: inset 0 0 0 3px #ffffffaa; }
.btn:hover { transform: translateY(-2px); }
.btn-gold:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--gold-dark); }
.small-note { margin-top: 12px; font-size: .9rem; font-weight: 700; text-shadow: 0 1px 0 #0b2a7a, 0 0 8px #0b2a7a; }

.cast { display: flex; justify-content: center; align-items: flex-end; gap: clamp(8px, 4vw, 48px); margin-top: 26px; }
.cast img { height: clamp(110px, 20vw, 210px); width: auto; filter: drop-shadow(0 6px 0 #0005); }
.cast img:nth-child(2) { height: clamp(130px, 24vw, 250px); }

/* ---------- sections ---------- */
.band { background: #eef3ff; }
.band.alt { background: #ffffff; }
.section { max-width: 1080px; margin: 0 auto; padding: 56px 20px; }
.section h2 { font-size: clamp(1.5rem, 3.6vw, 2.1rem); margin: 0 0 8px; color: var(--sky-top); }
.section .lead { color: var(--muted); margin: 0 0 28px; max-width: 720px; }

.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 22px; }
.feature {
  background: var(--card); border-radius: 16px; overflow: hidden;
  box-shadow: 0 10px 28px #0b2a7a1f; border-top: 6px solid var(--gold);
  display: flex; flex-direction: column;
}
.feature img { aspect-ratio: 16 / 9; object-fit: cover; width: 100%; }
.feature.wide { grid-column: 1 / -1; flex-direction: row; }
.feature.wide img { width: 50%; flex: none; }
.feature.wide .txt { align-self: center; padding: 22px 26px; }
.feature .txt { padding: 16px 18px 20px; }
.feature h3 { margin: 0 0 6px; font-size: 1.15rem; color: var(--sky-top); }
.feature p { margin: 0; color: var(--muted); }
.tag {
  display: inline-block; font-size: .72rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
  color: #fff; background: var(--red); border-radius: 999px; padding: 2px 10px; margin-bottom: 8px;
}

.zones { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.zone { margin: 0; position: relative; border-radius: 12px; overflow: hidden; box-shadow: 0 6px 18px #0b2a7a26; border: 3px solid var(--gold); background: #000; }
.zone img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; transition: transform .25s ease; }
.zone:hover img { transform: scale(1.05); }
.zone figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 10px 7px;
  background: linear-gradient(transparent, #000c); color: #fff; font-family: "Bungee", sans-serif; font-size: .9rem;
  display: flex; align-items: center; gap: 8px;
}
.zone figcaption span {
  display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; flex: none;
  background: var(--gold); color: var(--ink); font-size: .75rem;
}

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 18px; counter-reset: step; }
.step {
  background: var(--card); border-radius: 14px; padding: 20px 18px 18px 18px; position: relative;
  box-shadow: 0 6px 18px #0b2a7a17;
}
.step::before {
  counter-increment: step; content: counter(step);
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  font-family: "Bungee", sans-serif; color: var(--ink); background: var(--gold);
  box-shadow: 0 3px 0 var(--gold-dark); margin-bottom: 10px;
}
.step h3 { margin: 0 0 4px; font-size: 1rem; }
.step p { margin: 0; color: var(--muted); font-size: .95rem; }

.gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.gallery img { border-radius: 12px; aspect-ratio: 16 / 9; object-fit: cover; width: 100%; box-shadow: 0 6px 16px #0b2a7a26; }

.credits { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.credit { background: var(--card); border-radius: 14px; padding: 16px 18px; box-shadow: 0 6px 18px #0b2a7a14; }
.credit h3 { margin: 0 0 6px; font-size: .95rem; color: var(--sky-top); }
.credit p { margin: 0; color: var(--muted); font-size: .92rem; }

.legal { font-size: .88rem; color: var(--muted); }

/* ---------- pages de texte (regles, confidentialite) ---------- */
.page-hero { padding: 40px 20px 0; text-align: center; color: #fff; }
.page-hero h1 { position: relative; z-index: 2; margin: 0; font-size: clamp(1.8rem, 5vw, 2.6rem); text-shadow: 0 4px 0 #0b2a7a, 0 0 14px #0b2a7a; }
.page-hero p { position: relative; z-index: 2; margin: 6px 0 0; font-weight: 800; text-shadow: 0 1px 0 #0b2a7a, 0 0 8px #0b2a7a; }
.doc {
  max-width: 820px; margin: -10px auto 40px; padding: 28px 30px 22px;
  background: var(--card); border-radius: 16px; border-top: 6px solid var(--gold);
  box-shadow: 0 12px 34px #0b2a7a2b; position: relative; z-index: 3;
}
.doc h2 { font-size: 1.15rem; margin: 1.6em 0 .4em; color: var(--sky-top); }
.doc h2:first-child { margin-top: 0; }
.muted { color: var(--muted); font-size: .92rem; }

footer.site {
  background: #08185a; color: #cfd8ff; text-align: center; font-size: .88rem; padding: 26px 16px 30px;
}
footer.site a { color: var(--gold); }

@media (max-width: 640px) {
  .feature.wide { flex-direction: column; }
  .feature.wide img { width: 100%; }
  .topbar { padding: 8px 12px; }
  .topbar nav a { padding: 5px 8px; font-size: .88rem; }
  .doc { padding: 20px 18px; margin: -10px 12px 32px; }
  .section { padding: 40px 16px; }
}
@media (prefers-reduced-motion: reduce) {
  .clouds::before, .clouds::after { animation: none; }
  html { scroll-behavior: auto; }
}
