/* ===== Page jeu de pinball spatial ===== */
.pb-hero { text-align: center; padding: 2.2rem 1rem 0.6rem; }
.pb-hero h1 { font-size: clamp(1.8rem, 5vw, 3rem); margin: 0 0 .4rem; line-height: 1.05; }
.pb-hero p.pb-sub { color: var(--muted, #7a7a8a); max-width: 46rem; margin: 0 auto; font-size: 1.05rem; }

/* Cadre du jeu : conteneur sombre spatial */
#pb-game {
  --pb-neon: #b48bff;
  position: relative;
  max-width: 760px;
  margin: 1.2rem auto 0;
  padding: 14px;
  border-radius: 22px;
  background:
    radial-gradient(120% 90% at 50% 0%, rgba(120,70,200,.28), transparent 60%),
    linear-gradient(180deg, #0d0826, #070414);
  box-shadow: 0 30px 80px -30px rgba(90,40,180,.6), inset 0 0 0 1px rgba(180,140,255,.18);
}

/* HUD haut */
.pb-hud {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}
.pb-hud .pb-cell {
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(180,140,255,.22);
  border-radius: 12px;
  padding: 8px 6px;
  text-align: center;
  min-width: 0;
}
.pb-hud .pb-k {
  font-size: .62rem; letter-spacing: .12em; text-transform: uppercase;
  color: #9a8fd0; display: block; margin-bottom: 3px;
}
.pb-hud .pb-v {
  font-family: 'Press Start 2P', monospace; font-size: .95rem; color: #fff;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block;
}
.pb-hud .pb-v.big { color: #ffd27a; }

/* Scène */
.pb-stage {
  position: relative;
  display: flex; justify-content: center;
  perspective: 1300px;
}
#pb-canvas {
  display: block;
  border-radius: 14px;
  transform: rotateX(6deg);
  transform-origin: center 65%;
  box-shadow: 0 40px 60px -24px rgba(0,0,0,.8);
  touch-action: none;
  -webkit-user-select: none; user-select: none;
  background: #070414;
  cursor: pointer;
}

/* Barre de contrôles */
.pb-controls {
  display: flex; align-items: center; justify-content: center;
  gap: 10px; margin-top: 12px; flex-wrap: wrap;
}
.pb-btn {
  appearance: none; border: 1px solid rgba(180,140,255,.35);
  background: rgba(255,255,255,.06); color: #eae4ff;
  border-radius: 12px; padding: 10px 16px; font-size: .95rem; font-weight: 600;
  cursor: pointer; transition: background .15s, transform .1s;
  -webkit-user-select: none; user-select: none;
}
.pb-btn:hover { background: rgba(180,140,255,.18); }
.pb-btn:active { transform: translateY(1px); }
.pb-btn.pb-primary {
  background: linear-gradient(135deg, #7a4bff, #b48bff);
  border-color: transparent; color: #fff;
  box-shadow: 0 8px 24px -8px rgba(150,90,255,.8);
}
#pb-launch { min-width: 130px; }

/* Aide contrôles */
.pb-help {
  margin-top: 10px; text-align: center; color: #8a80b5; font-size: .82rem;
}
.pb-help kbd {
  background: rgba(255,255,255,.08); border: 1px solid rgba(180,140,255,.25);
  border-radius: 5px; padding: 1px 6px; font-family: inherit; font-size: .78rem; color: #d8ceff;
}

/* Plein écran : la scène prend TOUT l'espace restant après le HUD et les
   boutons ; la table est mesurée dessus → toujours entièrement visible. */
#pb-game.pb-fs {
  position: fixed; inset: 0; z-index: 9999; max-width: none;
  margin: 0; border-radius: 0; padding: 8px;
  display: flex; flex-direction: column;
  background: #050310;
}
#pb-game.pb-fs .pb-stage { flex: 1; min-height: 0; align-items: center; }
#pb-game.pb-fs #pb-canvas { transform: none; }   /* pas d'inclinaison 3D : rien ne déborde */
#pb-game.pb-fs .pb-help { display: none; }
#pb-game.pb-fs .pb-hud { margin-bottom: 8px; }
#pb-game.pb-fs .pb-controls { margin-top: 8px; }

/* Contenu SEO sous le jeu */
.pb-content { max-width: 46rem; margin: 3rem auto 0; padding: 0 1rem; }
.pb-content h2 { font-size: 1.5rem; margin: 2.2rem 0 .8rem; }
.pb-content h3 { font-size: 1.15rem; margin: 1.4rem 0 .5rem; }
.pb-content p, .pb-content li { line-height: 1.7; }
.pb-content ul { padding-left: 1.2rem; }
.pb-faq details {
  border: 1px solid rgba(0,0,0,.1); border-radius: 10px; padding: .3rem 1rem; margin: .6rem 0;
  background: rgba(120,70,200,.04);
}
.pb-faq summary { cursor: pointer; font-weight: 600; padding: .6rem 0; }

@media (max-width: 640px) {
  #pb-game { border-radius: 16px; padding: 10px; margin-top: .8rem; }
  #pb-canvas { transform: rotateX(4deg); }
  .pb-hud .pb-v { font-size: .78rem; }
  .pb-hud .pb-k { font-size: .55rem; }
  .pb-controls .pb-btn { padding: 12px 14px; }
}

/* Figures (captures du jeu) dans le contenu SEO */
.pb-figure { margin: 1.8rem auto; max-width: 400px; text-align: center; }
.pb-figure img {
  width: 100%; height: auto; display: block;
  border-radius: 16px;
  border: 1px solid rgba(180,140,255,.25);
  box-shadow: 0 24px 50px -24px rgba(90,40,180,.6);
}
.pb-figure figcaption {
  margin-top: .6rem; font-size: .85rem; color: var(--muted, #7a7a8a);
}
