/* ===============================
   Pop Ballons – styles spécifiques
   =============================== */

.pb-root {
  --pb-encre: #1d1840;
  --pb-doux: #6b6890;
  --pb-violet: #7c5cff;
  --pb-rose: #ff4f9a;
  /* Barre commune (css/games.css) aux couleurs du jeu */
  --mg-jeu-largeur: 1144px;
  --mgb-fond: radial-gradient(120% 160% at 0% 0%, rgba(255, 79, 154, 0.35), transparent 55%),
    linear-gradient(120deg, #3a2a8a, var(--pb-violet));
  --mgb-accent: #ffd166;
  --mgb-titre: linear-gradient(100deg, #ffd166, #ff8ac2 50%, #ffffff);
  --mg-fs-fond: #120f2a;
  --mg-bulle-fond: var(--pb-encre);
  align-items: center;
  font-family: "Outfit", system-ui, sans-serif;
}

/* La scène : le canevas et tout ce qui flotte au-dessus */
.pb-scene {
  position: relative;
  container-type: inline-size;
  border-radius: 22px;
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(29, 24, 64, 0.08),
    0 18px 50px -18px rgba(40, 20, 90, 0.55);
  background: #9fd8ff;
  user-select: none;
  -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent;
}

#pb-canvas {
  display: block;
  touch-action: none;
}

.pb-scene.pb-viseur #pb-canvas {
  cursor: none;
}

/* ---------- Puces translucides (bandeaux) ---------- */

.pb-puce {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(10px) saturate(1.4);
  -webkit-backdrop-filter: blur(10px) saturate(1.4);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 8px 22px -10px rgba(20, 10, 60, 0.45);
  color: var(--pb-encre);
  box-sizing: border-box;
}

.pb-puce small {
  display: block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--pb-doux);
  line-height: 1.1;
}

/* Barre commune : vies, couleur à éclater et score ; masqués sur l'accueil (choix du mode) */
.pb-infos {
  justify-content: space-between;
  gap: 10px;
}

.pb-root:has(.pb-sans-hud) .pb-infos,
.pb-root:has(.pb-sans-hud) .pb-outils-jeu,
.pb-root:has(.pb-sans-hud) .pb-outils-jeu + .mg-barre-sep {
  display: none;
}

.pb-root:has(.pb-sans-hud) .mg-barre-titre {
  border-right: none;
}

.pb-scene.pb-sans-hud .pb-bas {
  opacity: 0;
}

.pb-bas {
  transition: opacity 0.35s;
}

.pb-etat {
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  min-height: 52px;
  justify-content: center;
}

.pb-cible {
  padding: 5px 14px 5px 6px;
  border-radius: 40px;
}

/* Vies */
.pb-coeurs {
  display: flex;
  gap: 3px;
}

.pb-coeurs svg {
  width: 22px;
  height: 22px;
  display: block;
  transition: transform 0.3s;
}

.pb-coeurs svg path {
  fill: #ff4f7b;
  stroke: #d91f55;
  stroke-width: 1.4;
}

.pb-coeurs svg.vide path {
  fill: rgba(29, 24, 64, 0.1);
  stroke: rgba(29, 24, 64, 0.22);
}

.pb-coeurs svg.perdu {
  animation: pb-coeur-perdu 0.7s ease-out;
}

.pb-coeurs svg.gagne {
  animation: pb-coeur-gagne 0.6s cubic-bezier(0.34, 1.8, 0.64, 1);
}

@keyframes pb-coeur-perdu {
  0% {
    transform: scale(1.5) rotate(0);
  }
  30% {
    transform: scale(1.2) rotate(-18deg);
  }
  60% {
    transform: scale(1) rotate(12deg);
  }
  100% {
    transform: none;
  }
}

@keyframes pb-coeur-gagne {
  0% {
    transform: scale(0.2);
  }
  100% {
    transform: none;
  }
}

/* Jauge des ballons échappés */
.pb-fuites {
  display: flex;
  gap: 3px;
  padding-left: 2px;
}

.pb-fuites i {
  width: 9px;
  height: 11px;
  border-radius: 50% 50% 50% 50% / 45% 45% 55% 55%;
  border: 1.5px solid rgba(29, 24, 64, 0.25);
  box-sizing: border-box;
  transition:
    background 0.2s,
    border-color 0.2s;
}

.pb-fuites i.on {
  background: var(--c, #ff4f7b);
  border-color: rgba(0, 0, 0, 0.25);
}

.pb-fuites.alerte i.on {
  animation: pb-clignote 0.5s 3;
}

@keyframes pb-clignote {
  50% {
    opacity: 0.2;
  }
}

/* Chrono */
.pb-temps {
  font-family: "Madimi One", cursive;
  font-size: 1.7rem;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.pb-temps.urgent {
  color: #e8204f;
  animation: pb-battement 1s infinite;
}

@keyframes pb-battement {
  0%,
  100% {
    transform: none;
  }
  12% {
    transform: scale(1.14);
  }
}

.pb-zen {
  font-family: "Madimi One", cursive;
  font-size: 1.35rem;
  line-height: 1;
}

/* Couleur à éclater */
.pb-cible-ico {
  position: relative;
  width: 46px;
  height: 46px;
  flex: none;
}

.pb-cible-ico img {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 26px;
  height: 34px;
  margin: -18px 0 0 -13px;
  object-fit: contain;
  filter: drop-shadow(0 3px 3px rgba(0, 0, 0, 0.2));
  animation: pb-flotte 2.4s ease-in-out infinite;
}

@keyframes pb-flotte {
  0%,
  100% {
    transform: translateY(0) rotate(-4deg);
  }
  50% {
    transform: translateY(-3px) rotate(4deg);
  }
}

.pb-anneau {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.pb-anneau circle {
  fill: none;
  stroke-width: 3.5;
}

.pb-anneau .fond {
  stroke: rgba(29, 24, 64, 0.1);
}

.pb-anneau .jauge {
  stroke: var(--c, #7c5cff);
  stroke-linecap: round;
  stroke-dasharray: 132;
  stroke-dashoffset: 0;
}

.pb-cible-txt b {
  display: inline-block;
  margin-top: 2px;
  padding: 1px 10px;
  border-radius: 9px;
  background: var(--c, #7c5cff);
  color: var(--t, #fff);
  font-family: "Madimi One", cursive;
  font-weight: normal;
  font-size: 1.3rem;
  letter-spacing: 0.04em;
  line-height: 1.25;
  box-shadow: 0 4px 12px -4px var(--c, #7c5cff);
  white-space: nowrap;
}

.pb-cible.change {
  animation: pb-cible-change 1.1s cubic-bezier(0.34, 1.7, 0.64, 1);
}

.pb-cible.change .pb-cible-txt b {
  animation: pb-cible-mot 1.1s ease-out;
}

@keyframes pb-cible-change {
  0% {
    transform: scale(1.7);
    box-shadow:
      0 0 0 0 var(--c),
      0 0 40px 12px var(--c);
  }
  35% {
    transform: scale(0.92);
  }
  100% {
    transform: none;
    box-shadow:
      0 0 0 14px transparent,
      0 8px 22px -10px rgba(20, 10, 60, 0.45);
  }
}

@keyframes pb-cible-mot {
  0%,
  30%,
  60% {
    filter: brightness(1.6);
  }
  15%,
  45%,
  100% {
    filter: none;
  }
}

.pb-cible.alerte {
  animation: pb-tremble 0.45s ease-in-out infinite;
}

@keyframes pb-tremble {
  0%,
  100% {
    transform: rotate(0);
  }
  25% {
    transform: rotate(-2.5deg);
  }
  75% {
    transform: rotate(2.5deg);
  }
}

.pb-ensuite {
  display: none;
  flex-direction: column;
  align-items: center;
  margin-left: 2px;
  padding-left: 10px;
  border-left: 1px dashed rgba(29, 24, 64, 0.22);
}

.pb-cible.alerte .pb-ensuite {
  display: flex;
}

.pb-ensuite img {
  width: 18px;
  height: 24px;
  object-fit: contain;
  margin-top: 2px;
}

/* Score */
.pb-score {
  flex-direction: column;
  align-items: flex-end;
  gap: 0;
  min-width: 92px;
  min-height: 52px;
  justify-content: center;
}

.pb-score b {
  font-family: "Madimi One", cursive;
  font-weight: normal;
  font-size: 1.6rem;
  line-height: 1.05;
  font-variant-numeric: tabular-nums;
}

.pb-score b.bump {
  animation: pb-bump 0.25s ease-out;
}

@keyframes pb-bump {
  40% {
    transform: scale(1.15);
  }
}

.pb-record {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--pb-doux);
}

/* Boutons ronds */

/* ---------- Bandeau du bas ---------- */

.pb-bas {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 10px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 8px;
  pointer-events: none;
}

.pb-vague {
  padding: 6px 12px 8px;
  flex-direction: column;
  align-items: stretch;
  gap: 4px;
  min-width: 120px;
  transition: opacity 0.35s;
}

.pb-vague b {
  font-family: "Madimi One", cursive;
  font-weight: normal;
  font-size: 1rem;
  line-height: 1;
}

.pb-barre {
  display: block;
  height: 6px;
  border-radius: 4px;
  background: rgba(29, 24, 64, 0.1);
  overflow: hidden;
}

.pb-barre i {
  display: block;
  height: 100%;
  width: 0;
  border-radius: 4px;
  background: linear-gradient(90deg, #ffb547, #ff4f9a, #7c5cff);
  transition: width 0.25s;
}

.pb-combo {
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%) scale(0.6);
  opacity: 0;
  padding: 5px 14px 5px 10px;
  border-radius: 40px;
  transition:
    opacity 0.25s,
    transform 0.3s cubic-bezier(0.34, 1.6, 0.64, 1);
}

.pb-combo.visible {
  opacity: 1;
  transform: translateX(-50%) scale(1);
}

.pb-combo b {
  font-family: "Madimi One", cursive;
  font-weight: normal;
  font-size: 1.7rem;
  line-height: 1;
  background: linear-gradient(135deg, #ffb547, #ff4f9a 55%, #7c5cff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.pb-combo > span {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 78px;
}

.pb-combo .pb-barre i {
  transition: none;
}

.pb-combo.monte {
  animation: pb-combo-monte 0.45s cubic-bezier(0.34, 1.8, 0.64, 1);
}

@keyframes pb-combo-monte {
  0% {
    transform: translateX(-50%) scale(1.45) rotate(-6deg);
  }
  100% {
    transform: translateX(-50%) scale(1);
  }
}

/* ---------- Écrans superposés (accueil, pause, fin, aide) ---------- */

.pb-ecran {
  position: absolute;
  inset: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px;
  box-sizing: border-box;
  background: radial-gradient(
    ellipse at center,
    rgba(29, 24, 64, 0.32),
    rgba(29, 24, 64, 0.12) 70%
  );
  animation: pb-fondu 0.3s ease-out;
}

.pb-ecran-menu {
  background: none;
}

.pb-ecran-modal {
  z-index: 20;
  background: rgba(29, 24, 64, 0.45);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}

.pb-ecran[hidden] {
  display: none;
}

@keyframes pb-fondu {
  from {
    opacity: 0;
  }
}

.pb-carte {
  position: relative;
  width: min(540px, 100%);
  max-height: 100%;
  overflow-y: auto;
  box-sizing: border-box;
  padding: 20px 24px 18px;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow:
    0 1px 0 #fff inset,
    0 30px 70px -20px rgba(20, 10, 60, 0.6);
  color: #3d3a5c;
  text-align: center;
  line-height: 1.45;
  animation: pb-carte-entre 0.5s cubic-bezier(0.34, 1.45, 0.64, 1);
  scrollbar-width: thin;
}

@keyframes pb-carte-entre {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.92);
  }
}

.pb-carte-titre {
  font-family: "Madimi One", cursive;
  font-size: 1.9rem;
  line-height: 1.15;
  color: var(--pb-encre);
}

.pb-carte-sous {
  margin: 6px 0 4px;
  color: var(--pb-doux);
}

.pb-carte-btns {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px;
  margin-top: 14px;
}

.pb-gros {
  min-width: 150px;
  font-size: 17px !important;
  padding: 10px 26px !important;
}

/* Logo : « Pop ! » dans une étoile, « Ballons » en lettres-ballons */
.pb-logo {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin: 4px 0 2px;
}

.pb-logo-pop {
  position: relative;
  flex: none;
  margin-top: -18px;
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  font-family: "Madimi One", cursive;
  font-size: 1.1rem;
  color: #fff;
  transform: rotate(-14deg);
  background: #ff4f9a;
  clip-path: polygon(
    50% 0%,
    61% 18%,
    82% 10%,
    79% 32%,
    100% 39%,
    84% 54%,
    96% 74%,
    74% 76%,
    70% 98%,
    52% 84%,
    33% 100%,
    27% 78%,
    5% 79%,
    15% 58%,
    0% 42%,
    19% 32%,
    14% 10%,
    36% 17%
  );
  animation: pb-pop 2.6s ease-in-out infinite;
  z-index: 1;
}

@keyframes pb-pop {
  0%,
  70%,
  100% {
    transform: rotate(-14deg) scale(1);
  }
  76% {
    transform: rotate(-8deg) scale(1.22);
  }
  84% {
    transform: rotate(-18deg) scale(0.94);
  }
}

.pb-logo-mot {
  display: inline-flex;
  font-family: "Madimi One", cursive;
  font-size: clamp(2.4rem, 9cqi, 3.4rem);
  line-height: 1.1;
}

.pb-logo-mot i {
  font-style: normal;
  display: inline-block;
  color: var(--c);
  text-shadow:
    0 2px 0 rgba(0, 0, 0, 0.12),
    0 8px 16px rgba(0, 0, 0, 0.12);
  animation: pb-lettre 2.8s ease-in-out infinite;
}

.pb-logo-mot i:nth-child(1) {
  --c: #ff4757;
  animation-delay: 0s;
}
.pb-logo-mot i:nth-child(2) {
  --c: #ff9f1a;
  animation-delay: -0.4s;
}
.pb-logo-mot i:nth-child(3) {
  --c: #f5c400;
  animation-delay: -0.8s;
}
.pb-logo-mot i:nth-child(4) {
  --c: #2ed573;
  animation-delay: -1.2s;
}
.pb-logo-mot i:nth-child(5) {
  --c: #1e90ff;
  animation-delay: -1.6s;
}
.pb-logo-mot i:nth-child(6) {
  --c: #a55eea;
  animation-delay: -2s;
}
.pb-logo-mot i:nth-child(7) {
  --c: #ff4f9a;
  animation-delay: -2.4s;
}

@keyframes pb-lettre {
  0%,
  100% {
    transform: translateY(0) rotate(-3deg);
  }
  50% {
    transform: translateY(-7px) rotate(3deg);
  }
}

.pb-accroche {
  margin: 4px 0 14px;
  color: var(--pb-doux);
}

.pb-accroche b {
  color: var(--pb-encre);
}

/* Choix du mode */
.pb-modes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.pb-mode {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 12px 8px 10px;
  margin: 0;
  border: 2px solid rgba(29, 24, 64, 0.08);
  border-radius: 18px;
  background: #fff;
  font-family: inherit;
  color: var(--pb-encre);
  cursor: pointer;
  transition:
    border-color 0.2s,
    transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1),
    box-shadow 0.2s;
}

.pb-mode:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 22px -14px rgba(60, 30, 140, 0.55);
}

.pb-mode:focus-visible {
  outline: 2px solid var(--pb-violet);
  outline-offset: 2px;
}

.pb-mode.sel {
  border-color: var(--pb-violet);
  background: linear-gradient(180deg, #f6f2ff, #fff);
  box-shadow: 0 12px 26px -14px rgba(124, 92, 255, 0.8);
}

.pb-mode-ico {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: var(--mc);
  box-shadow: 0 8px 16px -8px var(--mc);
}

.pb-mode[data-mode="classique"] {
  --mc: #ff4f7b;
}
.pb-mode[data-mode="chrono"] {
  --mc: #ffa52e;
}
.pb-mode[data-mode="zen"] {
  --mc: #2ec98e;
}

.pb-mode-ico svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: #fff;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pb-mode[data-mode="classique"] .pb-mode-ico svg {
  fill: #fff;
  stroke: none;
}

.pb-mode-txt b {
  display: block;
  font-family: "Madimi One", cursive;
  font-weight: normal;
  font-size: 1.15rem;
}

.pb-mode-txt small {
  display: block;
  font-size: 0.8rem;
  line-height: 1.25;
  color: var(--pb-doux);
}

.pb-mode-rec {
  margin-top: auto;
  padding: 2px 9px;
  border-radius: 10px;
  background: #f2f0f8;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--pb-doux);
}

.pb-mode-rec:empty {
  display: none;
}

.pb-option {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
  text-align: left;
  font-weight: 600;
  color: var(--pb-encre);
  cursor: pointer;
}

.pb-option small {
  font-weight: 400;
  color: var(--pb-doux);
}

/* Fin de partie */
.pb-fin-ico {
  font-size: 2.6rem;
  line-height: 1;
  margin-bottom: 2px;
}

.pb-fin-ico img {
  width: 46px;
  height: 58px;
  object-fit: contain;
  animation: pb-flotte 2.4s ease-in-out infinite;
}

.pb-fin-score {
  font-family: "Madimi One", cursive;
  font-size: 3.4rem;
  line-height: 1.05;
  font-variant-numeric: tabular-nums;
  background: linear-gradient(135deg, #ffb547, #ff4f9a 50%, #7c5cff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.pb-fin-record {
  min-height: 1.4em;
  font-weight: 600;
  color: var(--pb-doux);
}

.pb-fin-record.nouveau {
  display: inline-block;
  padding: 3px 14px;
  border-radius: 20px;
  color: #fff;
  background: linear-gradient(
    90deg,
    #ffb547,
    #ff4f9a,
    #7c5cff,
    #ff4f9a,
    #ffb547
  );
  background-size: 200% 100%;
  animation: pb-brille 2s linear infinite;
}

@keyframes pb-brille {
  to {
    background-position: -200% 0;
  }
}

.pb-fin-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: 12px;
}

.pb-fin-stats div {
  padding: 8px 4px;
  border-radius: 14px;
  background: #f4f2fa;
}

.pb-fin-stats b {
  display: block;
  font-family: "Madimi One", cursive;
  font-weight: normal;
  font-size: 1.35rem;
  line-height: 1.1;
  color: var(--pb-encre);
}

.pb-fin-stats small {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--pb-doux);
}

/* Aide : deux colonnes quand la scène est large ; la taille du texte
   est ajustée par game.js (ajusterAide) pour éviter tout défilement */
.pb-carte-aide {
  text-align: left;
  width: min(880px, 100%);
  font-size: var(--aide-taille, 16px);
  overflow: hidden;
}

.pb-carte-aide .pb-carte-titre {
  text-align: center;
  font-size: 1.8em;
  margin-bottom: 0.3em;
}

.pb-aide-cols {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0 1.6em;
}

@container (min-width: 700px) {
  .pb-aide-cols {
    grid-template-columns: 1.15fr 1fr;
  }
  .pb-aide-col + .pb-aide-col .pb-aide-sous:first-child {
    margin-top: 0;
  }
}

.pb-carte-aide p {
  margin: 0 0 0.5em;
}

.pb-aide-liste {
  margin: 0;
  padding-left: 1.2em;
}

.pb-aide-liste li {
  margin-bottom: 0.25em;
}

.pb-aide-sous {
  margin: 0.6em 0 0.35em;
  font-family: "Madimi One", cursive;
  font-size: 1.1em;
  color: var(--pb-encre);
}

.pb-legende {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.35em 0.9em;
}

.pb-legende div {
  display: flex;
  align-items: center;
  gap: 0.6em;
  font-size: 0.92em;
  line-height: 1.3;
}

.pb-legende img {
  flex: none;
  width: 1.9em;
  height: 2.5em;
  object-fit: contain;
}

.pb-aide-cmd {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35em 1.1em;
  font-size: 0.92em;
}

.pb-aide-cmd kbd {
  display: inline-block;
  padding: 0 0.45em;
  border-radius: 6px;
  border: 1px solid #d9d6e8;
  border-bottom-width: 2px;
  background: #faf9ff;
  font-family: inherit;
  font-size: 0.9em;
  color: var(--pb-encre);
}

.pb-carte-aide .pb-carte-btns {
  justify-content: center;
  margin-top: 0.7em;
}

/* Raccourcis clavier inutiles sur téléphone et tablette */
@media (pointer: coarse) {
  .pb-aide-clavier {
    display: none !important;
  }
}

@container (max-width: 620px) {
  .pb-aide-clavier {
    display: none !important;
  }
  .pb-carte-aide {
    padding: 12px 14px;
  }
}

/* ---------- Infobulle (attribut data-bulle) ---------- */

/* ---------- Plein écran ---------- */

.pb-root.mg-fs .pb-scene {
  box-shadow: none;
}

/* ---------- Scènes étroites (téléphone) ---------- */

@container (max-width: 620px) {
  .pb-modes {
    grid-template-columns: 1fr;
    gap: 6px;
  }
  .pb-mode {
    flex-direction: row;
    text-align: left;
    padding: 8px 10px;
  }
  .pb-mode-txt {
    flex: 1;
  }
  .pb-mode-rec {
    margin: 0;
  }
  .pb-fin-stats {
    grid-template-columns: repeat(2, 1fr);
  }
  .pb-logo-mot {
    font-size: 2.5rem;
  }
  .pb-logo-pop {
    width: 54px;
    height: 54px;
    font-size: 0.95rem;
  }
  .pb-accroche {
    margin-bottom: 10px;
    font-size: 0.92rem;
  }
  .pb-mode-ico {
    width: 34px;
    height: 34px;
    border-radius: 11px;
  }
  .pb-mode-ico svg {
    width: 20px;
    height: 20px;
  }
  .pb-mode-txt small {
    font-size: 0.75rem;
  }
  .pb-option {
    margin-top: 10px;
  }
  .pb-option small {
    display: none;
  }
  .pb-carte {
    padding: 16px 16px 14px;
  }
}

@container (max-width: 400px) {
  .pb-puce {
    padding: 5px 9px;
  }
  .pb-cible-txt b {
    font-size: 1.1rem;
  }
  .pb-score b {
    font-size: 1.35rem;
  }
  .pb-score {
    min-width: 76px;
  }
  .pb-logo-mot {
    font-size: 2.3rem;
  }
}

/* ---------- Scènes basses (petite fenêtre) ---------- */

.pb-compacte .pb-carte {
  padding: 12px 18px 12px;
}

.pb-compacte .pb-logo-mot {
  font-size: 2.2rem;
}

.pb-compacte .pb-logo-pop {
  width: 48px;
  height: 48px;
  margin-top: -10px;
  font-size: 0.85rem;
}

.pb-compacte .pb-accroche {
  margin: 0 0 8px;
  font-size: 0.9rem;
}

.pb-compacte .pb-mode {
  padding: 8px 8px 6px;
  gap: 3px;
}

.pb-compacte .pb-mode-ico {
  width: 32px;
  height: 32px;
  border-radius: 10px;
}

.pb-compacte .pb-mode-ico svg {
  width: 19px;
  height: 19px;
}

.pb-compacte .pb-mode-txt small,
.pb-compacte .pb-option small {
  display: none;
}

.pb-compacte .pb-option {
  margin-top: 8px;
}

.pb-compacte .pb-carte-btns {
  margin-top: 8px;
}

.pb-compacte .pb-fin-score {
  font-size: 2.6rem;
}

.pb-compacte .pb-fin-stats {
  margin-top: 8px;
}

.pb-compacte .pb-fin-stats div {
  padding: 5px 4px;
}

@media (prefers-reduced-motion: reduce) {
  .pb-logo-mot i,
  .pb-logo-pop,
  .pb-cible-ico img,
  .pb-fin-ico img {
    animation: none;
  }
}
