/* ============ Téléphone (manette) ============ */
body.phone {
  min-height: 100dvh;
  overscroll-behavior: none;
  touch-action: manipulation;
  font-size: 18px;
}
/* Sur téléphone, on peut se permettre le vrai flou */
.phone .glass {
  -webkit-backdrop-filter: blur(22px) saturate(160%);
  backdrop-filter: blur(22px) saturate(160%);
  background: linear-gradient(155deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.05) 60%);
}
.phone.reduced .glass { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(40, 28, 100, 0.75); }

#app { min-height: 100dvh; }
.view {
  min-height: 100dvh;
  padding: calc(env(safe-area-inset-top) + 16px) 16px calc(env(safe-area-inset-bottom) + 24px);
  max-width: 560px;
  margin: 0 auto;
  animation: fade-up 0.35s var(--ease) both;
}
.view.center { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; text-align: center; }

h1, h2, h3 { margin: 0; line-height: 1.1; }
h2 { font-size: 26px; font-weight: 800; }
h3 { font-size: 15px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-2); margin: 22px 4px 10px; }
p { margin: 0; }
.muted { color: var(--text-2); }
.huge { font-size: 64px; line-height: 1; }

.card { padding: 20px; border-radius: var(--r-lg); }
.card + .card { margin-top: 14px; }
.center-card { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; padding: 30px 24px; width: 100%; }

.spinner {
  width: 54px; height: 54px; border-radius: 50%;
  border: 5px solid rgba(255, 255, 255, 0.15); border-top-color: var(--cyan);
  animation: spin 0.9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Boutons ---------- */
.btn {
  appearance: none;
  border: 1.5px solid rgba(255, 255, 255, 0.22);
  color: var(--text);
  font: 700 19px/1.1 'Inter', system-ui, sans-serif;
  min-height: 58px;
  padding: 14px 22px;
  border-radius: var(--r-md);
  background: linear-gradient(155deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.06));
  box-shadow: inset 0 1.5px 0 rgba(255, 255, 255, 0.3), 0 10px 24px -14px rgba(0, 0, 0, 0.6);
  width: 100%;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  transition: transform 0.18s var(--spring), opacity 0.2s;
  cursor: pointer;
}
.btn:active { transform: scale(0.96); }
.btn:disabled { opacity: 0.45; }
.btn.primary {
  background: linear-gradient(135deg, #a07bff 0%, #6d5cff 45%, #3fa7ff 100%);
  border-color: rgba(255, 255, 255, 0.4);
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.45), 0 14px 34px -12px rgba(110, 90, 255, 0.85);
  font-size: 21px;
  min-height: 64px;
}
.btn.danger { background: linear-gradient(155deg, rgba(255, 90, 110, 0.45), rgba(255, 90, 110, 0.15)); }
.btn.small { min-height: 40px; padding: 8px 14px; font-size: 16px; width: auto; border-radius: 14px; }
.btn-row { display: flex; gap: 10px; }
.btn-col { display: flex; flex-direction: column; gap: 10px; }
.link-btn { background: none; border: 0; color: var(--text-2); font: 600 16px 'Inter', sans-serif; text-decoration: underline; padding: 12px; cursor: pointer; }
.icon-btn {
  appearance: none; border: 0; background: rgba(255, 255, 255, 0.12); color: #fff;
  width: 46px; height: 46px; border-radius: 50%; font-size: 22px; cursor: pointer; flex: none;
}

/* ---------- Champs ---------- */
.field { display: block; }
.field span { display: block; font-size: 15px; font-weight: 600; color: var(--text-2); margin: 0 4px 8px; }
.input {
  width: 100%;
  font: 600 20px 'Inter', system-ui, sans-serif; /* ≥ 16px : évite le zoom auto d'iPhone */
  color: #fff;
  padding: 16px 18px;
  border-radius: var(--r-md);
  border: 1.5px solid rgba(255, 255, 255, 0.22);
  background: rgba(10, 6, 40, 0.45);
  outline: none;
}
.input:focus { border-color: var(--cyan); box-shadow: 0 0 0 4px rgba(94, 231, 255, 0.2); }
.input::placeholder { color: var(--text-3); }
.error { color: #ff9aa8; font-weight: 600; min-height: 1.3em; text-align: center; margin-top: 8px; }

/* segmented control */
.seg { display: flex; padding: 5px; gap: 5px; border-radius: 18px; background: rgba(10, 6, 40, 0.4); border: 1px solid rgba(255, 255, 255, 0.14); }
.seg button {
  flex: 1; appearance: none; border: 0; background: transparent; color: var(--text-2);
  font: 700 17px 'Inter', sans-serif; padding: 12px 6px; border-radius: 14px; cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.seg button.on { background: linear-gradient(135deg, rgba(160, 123, 255, 0.85), rgba(63, 167, 255, 0.75)); color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4); }

/* ---------- Rejoindre ---------- */
.join-head { display: flex; align-items: center; gap: 10px; justify-content: center; margin: 6px 0 18px; }
.join-head .logo-word { font-size: 40px; }
.join-preview { display: flex; align-items: center; gap: 16px; margin-bottom: 14px; }
.join-preview .avatar { --size: 96px; }
.join-preview .btn { flex: 1; }
.selfie-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(62px, 1fr)); gap: 10px; }
.gallery button { appearance: none; border: 0; background: none; padding: 0; border-radius: 50%; cursor: pointer; transition: transform 0.2s var(--spring); }
.gallery button .avatar { --size: 100%; aspect-ratio: 1; width: 100%; height: auto; }
.gallery button.on { transform: scale(1.08); }
.gallery button.on .avatar { box-shadow: 0 0 0 3px var(--cyan), 0 0 18px rgba(94, 231, 255, 0.6); }

/* ---------- Principal ---------- */
.topbar {
  position: sticky; top: calc(env(safe-area-inset-top) + 8px); z-index: 10;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 8px 8px 8px 10px; border-radius: 26px; margin-bottom: 14px;
}
.me-mini { display: flex; align-items: center; gap: 10px; min-width: 0; font-weight: 700; font-size: 18px; }
.me-mini .avatar { --size: 44px; }
.me-mini .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tabs { padding-bottom: 96px; }

.hero { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; padding: 26px 20px; }
.hero .avatar { --size: 130px; animation: bob 3.4s ease-in-out infinite; }
.hero .nm { font-size: 30px; font-weight: 800; }
.stats { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.status-msg { font-size: 19px; color: var(--text-2); font-weight: 500; line-height: 1.35; }

.tabbar {
  position: fixed; left: 50%; transform: translateX(-50%);
  bottom: calc(env(safe-area-inset-bottom) + 10px);
  width: min(540px, calc(100% - 20px));
  display: grid; grid-template-columns: repeat(4, 1fr); padding: 6px; border-radius: 26px; z-index: 20;
}
.tabbar button {
  appearance: none; border: 0; background: none; color: var(--text-2); cursor: pointer;
  font: 600 13px 'Inter', sans-serif; padding: 8px 0 6px; border-radius: 20px;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
}
.tabbar button span { font-size: 22px; }
.tabbar button.on { color: #fff; background: rgba(255, 255, 255, 0.14); }

.banner {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 10px 14px; margin-bottom: 14px; border-radius: 18px; font-weight: 700;
  background: rgba(255, 209, 102, 0.2); border: 1px solid rgba(255, 209, 102, 0.45);
}

/* listes (jeux, joueurs) */
.list { display: flex; flex-direction: column; gap: 10px; }
.row {
  display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: var(--r-md);
  appearance: none; color: inherit; font: inherit; text-align: left; width: 100%; cursor: pointer;
}
.row .avatar { --size: 48px; }
.row .emoji { font-size: 30px; width: 44px; text-align: center; flex: none; }
.row .main { flex: 1; min-width: 0; }
.row .t { font-weight: 700; font-size: 18px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row .s { font-size: 14px; color: var(--text-2); }
.row.off { opacity: 0.45; }
.row.on { box-shadow: 0 0 0 2px var(--cyan); }
.row .acts { display: flex; gap: 6px; flex: none; }
.row .acts .icon-btn { width: 40px; height: 40px; font-size: 18px; }

/* réglages */
.set { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 14px 4px; border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
.set:last-child { border-bottom: 0; }
.set .lbl { font-weight: 600; }
.set .lbl small { display: block; font-weight: 400; color: var(--text-2); font-size: 14px; margin-top: 2px; }
.switch { position: relative; width: 58px; height: 34px; flex: none; }
.switch input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; z-index: 1; }
.switch span {
  position: absolute; inset: 0; border-radius: 99px; background: rgba(255, 255, 255, 0.18);
  transition: background 0.25s; box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.3);
}
.switch span::after {
  content: ''; position: absolute; top: 3px; left: 3px; width: 28px; height: 28px; border-radius: 50%;
  background: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35); transition: transform 0.3s var(--spring);
}
.switch input:checked + span { background: linear-gradient(135deg, #8b5cf6, #3fa7ff); }
.switch input:checked + span::after { transform: translateX(24px); }
input[type='range'] { width: 100%; accent-color: var(--violet-2); height: 34px; }
.stepper { display: flex; align-items: center; gap: 8px; flex: none; }
.stepper b { min-width: 58px; text-align: center; font-size: 18px; }
.stepper .icon-btn { width: 40px; height: 40px; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip { position: relative; }
.chip input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.chip span {
  display: inline-block; padding: 10px 14px; border-radius: 99px; font-weight: 700;
  background: rgba(255, 255, 255, 0.1); border: 1.5px solid rgba(255, 255, 255, 0.18); color: var(--text-2);
}
.chip input:checked + span { background: linear-gradient(135deg, rgba(160, 123, 255, 0.8), rgba(63, 167, 255, 0.7)); color: #fff; border-color: rgba(255, 255, 255, 0.4); }

/* ---------- Feuille du bas, toast, pause ---------- */
.sheet { position: fixed; inset: 0; z-index: 40; }
.sheet-scrim { position: absolute; inset: 0; background: rgba(5, 3, 20, 0.6); animation: fade-up 0.2s both; }
.sheet-panel {
  position: absolute; left: 0; right: 0; bottom: 0; max-width: 560px; margin: 0 auto;
  padding: 22px 18px calc(env(safe-area-inset-bottom) + 22px);
  border-radius: 30px 30px 0 0; max-height: 88dvh; overflow: auto;
  animation: sheet-up 0.4s var(--spring) both;
  background: linear-gradient(155deg, rgba(60, 40, 140, 0.85), rgba(20, 12, 60, 0.9)) !important;
}
@keyframes sheet-up { from { transform: translateY(100%); } }

.toast {
  position: fixed; left: 50%; bottom: calc(env(safe-area-inset-bottom) + 100px); transform: translateX(-50%);
  z-index: 60; padding: 14px 22px; border-radius: 18px; font-weight: 700; max-width: 90vw; text-align: center;
  background: rgba(30, 20, 80, 0.92); border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 16px 40px -10px rgba(0, 0, 0, 0.6);
  animation: pop-in 0.4s var(--spring) both;
}
.toast.bad { background: rgba(150, 30, 60, 0.95); }
.toast.ok { background: rgba(30, 120, 80, 0.95); }

.conn-pill {
  position: fixed; top: calc(env(safe-area-inset-top) + 8px); left: 50%; transform: translateX(-50%);
  z-index: 70; padding: 8px 18px; border-radius: 99px; font-weight: 700; font-size: 15px;
  background: rgba(255, 90, 110, 0.92);
}

.pause-overlay {
  position: fixed; inset: 0; z-index: 30; display: grid; place-items: center; padding: 24px;
  background: rgba(5, 3, 20, 0.7);
}

/* ---------- Veille (écran noir + chat) ---------- */
.sleep-view {
  position: fixed; top: 0; left: 0; right: 0; height: 100dvh; z-index: 25; max-width: none; background: #000;
  display: flex; flex-direction: column; gap: 12px;
  padding: calc(env(safe-area-inset-top) + 18px) 16px calc(env(safe-area-inset-bottom) + 12px);
}
.sleep-view > * { width: 100%; max-width: 560px; margin: 0 auto; }
.sl-head { text-align: center; padding: 6px 0 4px; }
.sl-moon { font-size: 40px; }
.sl-title { font-size: 24px; font-weight: 800; color: rgba(255, 255, 255, 0.85); }
.sl-sub { font-size: 15px; color: rgba(255, 255, 255, 0.4); margin-top: 2px; }
.sl-admin { display: flex; flex-direction: column; gap: 10px; }
.sl-admin .btn { min-height: 50px; font-size: 16px; }
.sl-mutes { display: flex; flex-direction: column; gap: 6px; max-height: 34dvh; overflow: auto; padding: 4px; }
.sl-mutes .mrow { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 16px; background: rgba(255, 255, 255, 0.06); }
.sl-mutes .mrow .avatar { --size: 36px; }
.sl-mutes .mrow .nm { flex: 1; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sl-feed { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; padding: 6px 2px; }
.sl-empty { margin: auto; color: rgba(255, 255, 255, 0.3); text-align: center; }
.msg { display: flex; gap: 10px; align-items: flex-end; animation: fade-up 0.3s var(--ease) both; }
.msg .avatar { --size: 34px; }
.msg .b { padding: 10px 14px; border-radius: 18px 18px 18px 6px; background: rgba(255, 255, 255, 0.1); max-width: 80%; }
.msg .b .who { font-size: 13px; font-weight: 700; color: var(--cyan); }
.msg .b .t { font-size: 17px; overflow-wrap: anywhere; }
.msg.mine { flex-direction: row-reverse; }
.msg.mine .b { border-radius: 18px 18px 6px 18px; background: linear-gradient(135deg, rgba(139, 92, 246, 0.6), rgba(63, 167, 255, 0.5)); }
.msg.system { justify-content: center; color: rgba(255, 255, 255, 0.4); font-size: 14px; }
.sl-input { display: flex; gap: 8px; }
.sl-input .input { flex: 1; background: rgba(255, 255, 255, 0.08); }
.sl-input .btn { width: 60px; min-height: 0; padding: 0; font-size: 22px; }
.sl-input .input:disabled { opacity: 0.5; }

/* ---------- Jeux ---------- */
#game-area:empty { display: none; }
#game-area { display: flex; flex-direction: column; gap: 14px; }
.admin-quick { margin: 12px 0; }
.admin-quick .btn { flex: 1; }
.g-info { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; padding: 34px 20px; }
.big-sub { font-size: 20px; font-weight: 700; color: var(--text); }
.g-title { text-align: center; }
.g-title h2 { font-size: 23px; line-height: 1.25; }
.g-title p { margin-top: 6px; }
.g-quote { font-size: 21px; font-weight: 600; margin-top: 12px !important; }
.g-vote-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 12px; }
.g-cand {
  appearance: none; border: 1.5px solid rgba(255, 255, 255, 0.15); background: rgba(255, 255, 255, 0.07); color: #fff;
  border-radius: 20px; padding: 12px 6px; display: flex; flex-direction: column; align-items: center; gap: 8px;
  font: 700 15px 'Inter', sans-serif; cursor: pointer; transition: transform 0.2s var(--spring);
}
.g-cand .avatar { --size: 64px; }
.g-cand span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.g-cand:active { transform: scale(0.94); }
.g-cand.on { background: linear-gradient(135deg, rgba(160, 123, 255, 0.7), rgba(63, 167, 255, 0.6)); border-color: #fff; transform: scale(1.04); }
.row .t.wrap { white-space: normal; font-size: 18px; line-height: 1.3; }
.g-stars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.g-star { appearance: none; border: 1.5px solid rgba(255, 255, 255, 0.15); background: rgba(255, 255, 255, 0.07); color: #fff; border-radius: 20px; padding: 16px 4px; font-size: 40px; cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.g-star small { font: 600 13px 'Inter', sans-serif; }
.g-star.on { background: linear-gradient(135deg, rgba(255, 209, 102, 0.6), rgba(255, 159, 90, 0.4)); border-color: #fff; }
.g-text { display: flex; flex-direction: column; gap: 10px; }
.g-text textarea { resize: none; }
.g-sent { text-align: center; }
.g-hint { font-size: 30px; font-weight: 800; letter-spacing: 0.08em; margin-top: 8px; word-break: break-word; }
.g-guess { display: flex; gap: 8px; }
.g-guess .input { flex: 1; }
.g-guess .btn { width: 64px; padding: 0; }
.g-close { text-align: center; font-weight: 800; color: var(--gold); font-size: 20px; }

.d-word { padding: 12px 16px; border-radius: 18px; font-size: 18px; text-align: center; }
.d-word b { font-size: 22px; color: var(--gold); }
.d-found { color: var(--text-2); font-size: 15px; }
.d-canvas { border-radius: 18px; overflow: hidden; background: #fbf9ff; box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.2); }
.d-canvas canvas { display: block; width: 100%; touch-action: none; }
.d-tools { padding: 10px; border-radius: 20px; display: flex; flex-direction: column; gap: 10px; }
.d-colors { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.d-color { width: 36px; height: 36px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, 0.4); cursor: pointer; font-size: 18px; padding: 0; background: #fff; }
.d-color.on { box-shadow: 0 0 0 3px var(--cyan); transform: scale(1.12); }
.d-row { display: flex; gap: 8px; justify-content: center; align-items: center; }
.d-size, .d-btn { width: 48px; height: 44px; border-radius: 14px; border: 1.5px solid rgba(255, 255, 255, 0.2); background: rgba(255, 255, 255, 0.08); color: #fff; display: grid; place-items: center; cursor: pointer; font-size: 20px; }
.d-size i { display: block; border-radius: 50%; background: #fff; }
.d-size.on { background: rgba(94, 231, 255, 0.3); border-color: var(--cyan); }

.drink-phone { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 24px; background: rgba(40, 20, 0, 0.6); animation: fade-up 0.3s both; }
.drink-phone .card { text-align: center; padding: 36px 26px; background: linear-gradient(155deg, rgba(255, 209, 102, 0.55), rgba(255, 159, 90, 0.3)) !important; animation: pop-in 0.5s var(--spring) both; }

/* bouton « C'est parti » toujours visible, centré en bas */
#v-join { padding-bottom: calc(env(safe-area-inset-bottom) + 110px); }
.join-cta {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 15;
  padding: 18px 16px calc(env(safe-area-inset-bottom) + 16px);
  display: flex; flex-direction: column; gap: 10px; align-items: center;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.75) 45%);
}
.join-cta .btn { width: min(100%, 528px); }

/* thème nuit d'encre (téléphone) */
.phone .glass { background: rgba(24, 24, 28, 0.78); }
.btn { background: rgba(255, 255, 255, 0.06); border-color: rgba(255, 255, 255, 0.1); box-shadow: none; }
.btn.primary { background: var(--accent); border-color: transparent; box-shadow: 0 10px 30px -12px rgba(139, 92, 246, 0.8); }
.btn.danger { background: rgba(255, 90, 110, 0.18); border-color: rgba(255, 90, 110, 0.35); }
.seg { background: rgba(255, 255, 255, 0.05); border-color: rgba(255, 255, 255, 0.08); }
.seg button.on { background: var(--accent); box-shadow: none; }
.switch input:checked + span { background: var(--accent); }
.chip input:checked + span { background: var(--accent); border-color: transparent; }
.input { background: rgba(255, 255, 255, 0.05); border-color: rgba(255, 255, 255, 0.1); }
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.25); }
.tabbar button.on { color: #fff; background: var(--accent-soft); }
.gallery button.on .avatar, .g-cand.on .avatar { box-shadow: 0 0 0 3px var(--accent); }
.g-cand, .g-star { background: rgba(255, 255, 255, 0.05); border-color: rgba(255, 255, 255, 0.08); }
.g-cand.on, .g-star.on, .row.on { background: var(--accent-soft); border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.msg.mine .b { background: var(--accent); }
.d-word b { color: #fff; }
.d-color.on { box-shadow: 0 0 0 3px var(--accent); }
.d-size.on { background: var(--accent-soft); border-color: var(--accent); }
.g-close { color: var(--violet-2); }
.drink-phone .card { background: rgba(24, 24, 28, 0.95) !important; border-color: var(--accent); }
.banner { background: var(--accent-soft); border-color: rgba(139, 92, 246, 0.45); }
.d-done { margin-top: 4px; }
.btn-row .input { min-width: 0; }
.btn.icon-ok { flex: none; width: 56px; padding: 0; font-size: 20px; }
.d-btn { font-size: 20px; }

/* Plus ou moins / Imposteur / Fais deviner */
.g-num { display: flex; flex-direction: column; gap: 10px; }
.g-num-row { display: flex; align-items: center; gap: 10px; }
.g-num-row .input { flex: 1; font-size: 26px; text-align: center; }
.g-unit { font-weight: 700; color: var(--text-2); max-width: 40%; }
.g-secret { text-align: center; padding: 26px 18px; }
.g-word { font-size: 38px; font-weight: 800; margin-top: 6px; overflow-wrap: anywhere; }
.g-turn { text-align: center; display: flex; flex-direction: column; gap: 8px; }
.g-turn b { color: #fff; }
.g-taboo { text-align: center; padding: 24px 18px; }
.g-forbid { list-style: none; padding: 0; margin: 8px 0 0; display: flex; flex-direction: column; gap: 6px; }
.g-forbid li { font-size: 20px; font-weight: 600; color: #ff9aa8; }
.g-tb-row { display: grid; grid-template-columns: 1fr 1.6fr 1fr; gap: 10px; }
.g-tb { font-size: 30px; min-height: 76px; }
.g-count { text-align: center; }

/* Le Mème */
.meme-card, .g-meme { position: relative; overflow: hidden; background: #000; }
.meme-card img, .g-meme img { display: block; width: 100%; height: 100%; object-fit: contain; }
.mm-top, .mm-bot { position: absolute; left: 4%; right: 4%; text-align: center; font-family: 'Anton', Impact, sans-serif; font-weight: 400; text-transform: uppercase; color: #fff; line-height: 1.05; letter-spacing: 0.01em;
  -webkit-text-stroke: 0.06em #000; paint-order: stroke fill; text-shadow: 0 0.04em 0.12em rgba(0,0,0,0.6); overflow-wrap: break-word; }
.mm-top { top: 3%; } .mm-bot { bottom: 3%; }
.g-meme { border-radius: 18px; aspect-ratio: 4 / 3; font-size: 26px; margin-bottom: 12px; }

/* outils de dessin v2 */
.d-canvas { position: relative; }
.d-palette { position: absolute; left: 8px; right: 8px; bottom: 8px; display: grid; grid-template-columns: repeat(8, 1fr); gap: 8px; padding: 12px; border-radius: 18px; background: rgba(18, 18, 24, 0.92); }
.d-palette[hidden] { display: none; }
.d-sw { aspect-ratio: 1; border-radius: 50%; border: 2px solid rgba(255, 255, 255, 0.25); padding: 0; cursor: pointer; }
.d-tools { flex-direction: row !important; align-items: center; gap: 8px !important; }
.d-tool { flex: none; width: 46px; height: 46px; border-radius: 14px; border: 1.5px solid rgba(255, 255, 255, 0.18); background: rgba(255, 255, 255, 0.07); color: #fff; display: grid; place-items: center; font-size: 20px; cursor: pointer; padding: 0; }
.d-tool.on { border-color: var(--accent); background: var(--accent-soft); }
.d-cur i { width: 26px; height: 26px; border-radius: 50%; box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.5); }
.d-slider { flex: 1; position: relative; height: 46px; touch-action: none; cursor: pointer; }
.d-track { position: absolute; left: 0; right: 0; top: 50%; height: 0; border-top: 10px solid transparent; border-bottom: 0; transform: translateY(-50%);
  background: linear-gradient(90deg, rgba(255,255,255,0.25), rgba(255,255,255,0.5)); clip-path: polygon(0 45%, 100% 0, 100% 100%, 0 55%); height: 18px; border: 0; }
.d-knob { position: absolute; top: 50%; width: 0; height: 0; }
.d-knob i { position: absolute; left: 0; top: 0; transform: translate(-50%, -50%); border-radius: 50%; box-shadow: 0 0 0 2px #fff, 0 2px 8px rgba(0,0,0,0.5); transition: transform 0.12s; }
.d-slider.drag .d-knob i { transform: translate(-50%, -50%) scale(1.25); }

/* accueil joueur v2 */
.hm { display: flex; flex-direction: column; gap: 18px; padding-top: 6px; }
.hm-id { display: flex; align-items: center; gap: 16px; }
.hm-id .avatar { --size: 76px; }
.hm-name { font-size: 26px; font-weight: 800; letter-spacing: -0.01em; }
.hm-crown { font-size: 20px; }
.hm-role { font-size: 14px; color: var(--text-2); text-transform: uppercase; letter-spacing: 0.1em; margin-top: 2px; }
.hm-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: 10px; }
.hm-stat { border-radius: 18px; padding: 16px 8px 12px; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.hm-stat b { font-size: 34px; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; }
.hm-stat b sup { font-size: 0.45em; margin-left: 1px; }
.hm-stat span { font-size: 13px; color: var(--text-2); text-transform: uppercase; letter-spacing: 0.08em; }
.hm-msg { font-size: 17px; color: var(--text-2); line-height: 1.4; text-align: center; margin: 4px 0; }
.hm-actions { display: flex; flex-direction: column; gap: 8px; }
.btn.ghost { background: transparent; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.14); font-weight: 600; }
/* chat muet */
.sl-input.locked { opacity: 0.55; pointer-events: none; }
.sl-input.locked .input { background: rgba(255, 60, 90, 0.12); box-shadow: inset 0 0 0 1px rgba(255, 60, 90, 0.5); }
/* pas de zoom auto d'iOS sur les champs (cause d'affichages trop petits/grands) */
input, textarea, select { font-size: max(16px, 1em); }

/* barre admin (tous les onglets) */
.admin-bar { position: sticky; top: 8px; z-index: 15; margin: 8px 0 12px; padding: 10px 12px; border-radius: 18px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.admin-bar[hidden] { display: none; }
.ab-info { display: flex; align-items: center; gap: 8px; min-width: 0; font-size: 15px; }
.ab-info b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ab-dot { flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); }
.ab-dot.live { background: #22c55e; box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.25); animation: pulse-dot 1.6s ease-in-out infinite; }
@keyframes pulse-dot { 50% { box-shadow: 0 0 0 8px rgba(34, 197, 94, 0); } }
.ab-btns { display: flex; gap: 6px; flex: none; }
.ab-btns .btn { min-height: 36px; padding: 0 12px; }
.tabs { padding-bottom: 110px; }
.seg-hint { font-size: 14px; margin-top: 8px; text-align: center; }
/* validation avant un jeu */
.rd { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; padding: 30px 20px; }
.rd-emoji { font-size: 64px; line-height: 1; }
.rd-btn { width: 100%; min-height: 64px; font-size: 22px; }
.rd-ok { font-size: 22px; font-weight: 800; color: #22c55e; }
/* roue de sélection (admin) */
.pk { position: relative; height: 240px; border-radius: 22px; overflow: hidden; perspective: 600px; }
.pk-band { position: absolute; left: 10px; right: 10px; top: 50%; height: 48px; margin-top: -24px; border-radius: 14px; background: rgba(255, 255, 255, 0.09); pointer-events: none; }
.pk-scroll { position: absolute; inset: 0; overflow-y: auto; scroll-snap-type: y mandatory; scrollbar-width: none; transform-style: preserve-3d;
  -webkit-mask-image: linear-gradient(transparent, #000 30%, #000 70%, transparent); mask-image: linear-gradient(transparent, #000 30%, #000 70%, transparent); }
.pk-scroll::-webkit-scrollbar { display: none; }
.pk-pad { height: 96px; }
.pk-item { height: 48px; scroll-snap-align: center; display: flex; align-items: center; justify-content: center; gap: 10px; font-size: 21px; font-weight: 700; cursor: pointer; }
.pk-why { text-align: center; font-size: 14px; margin: 8px 0 10px; min-height: 18px; }
.pk-btns .pk-go { flex: 2; }
.pk-btns .btn:disabled { opacity: 0.45; }

/* chat partout */
.chat-fab { position: fixed; right: 16px; bottom: calc(env(safe-area-inset-bottom) + 96px); width: 56px; height: 56px; border-radius: 50%; border: 0; font-size: 24px; z-index: 25; cursor: pointer; color: #fff; }
.chat-fab[hidden] { display: none; }
.chat-fab i { position: absolute; top: -2px; right: -2px; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: #ff3b5c; font: 700 12px/22px 'Inter', sans-serif; font-style: normal; }
.chat-fab i[hidden] { display: none; }
.chat-panel { display: flex; flex-direction: column; gap: 10px; height: min(78vh, 640px); }
.cp-head { display: flex; align-items: center; justify-content: space-between; font-size: 20px; }
.cp-feed { flex: 1; overflow-y: auto; min-height: 0; }

/* accueil joueur v3 */
.hm-id { position: relative; }
.hm-who { flex: 1; min-width: 0; }
.hm-av { position: relative; border-radius: 50%; padding: 4px; background: linear-gradient(160deg, rgba(255,255,255,0.22), rgba(255,255,255,0.02)); box-shadow: inset 0 0 0 1px rgba(255,255,255,0.18), 0 10px 30px rgba(0,0,0,0.45); }
.hm-av::after { content: ''; position: absolute; inset: 4px; border-radius: 50%; background: linear-gradient(170deg, rgba(255,255,255,0.28) 0%, rgba(255,255,255,0) 42%); pointer-events: none; }
.hm-av .avatar { --size: 96px; }
.hm-more { position: relative; }
.hm-more .icon-btn { font-size: 22px; }
.hm-menu { position: absolute; right: 0; top: 46px; z-index: 30; min-width: 230px; padding: 6px; border-radius: 16px; display: flex; flex-direction: column; background: rgba(20, 20, 26, 0.96); }
.hm-menu[hidden] { display: none; }
.hm-menu button { appearance: none; border: 0; background: none; color: #fff; font: 600 16px 'Inter', sans-serif; text-align: left; padding: 12px 14px; border-radius: 12px; cursor: pointer; }
.hm-menu button:active { background: rgba(255,255,255,0.08); }
.hm-rank { display: flex; align-items: center; gap: 18px; padding: 16px 20px; border-radius: 20px; }
.hr-big { font-size: 64px; font-weight: 800; line-height: 1; letter-spacing: -0.03em; }
.hr-big sup { font-size: 0.38em; margin-left: 2px; }
.hr-side { flex: 1; min-width: 0; }
.hr-gap { font-size: 16px; font-weight: 600; margin-bottom: 6px; }
.hr-stats { display: flex; gap: 14px; flex-wrap: wrap; font-size: 14px; color: var(--text-2); }
.hr-stats b { color: #fff; font-size: 17px; }
.hm-curve { padding: 12px 14px 8px; border-radius: 18px; }
.hc-label { font-size: 12px; color: var(--text-2); text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 6px; }
.spark { display: block; width: 100%; height: 70px; }
.sp-line { fill: none; stroke: var(--accent); stroke-width: 2.5; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.sp-fill { fill: var(--accent-soft); opacity: 0.6; }
.sp-dot { fill: #fff; }
.hm-next { padding: 14px 18px; border-radius: 18px; text-align: center; }
.hn-label { font-size: 12px; color: var(--text-2); text-transform: uppercase; letter-spacing: 0.08em; }
.hn-name { font-size: 22px; font-weight: 800; margin-top: 4px; }
.hn-desc { font-size: 14px; color: var(--text-2); margin-top: 4px; }
.hm-people { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.hm-people .avatar { --size: 34px; }
.rd-rules { font-size: 16px; line-height: 1.45; color: var(--text-2); }

.online-card.on { box-shadow: inset 0 0 0 1.5px rgba(34, 197, 94, 0.6); }
.oc-url { margin-top: 8px; font-size: 13px; color: #22c55e; overflow-wrap: anywhere; }

/* choix du vaisseau */
.ship-pick { display: flex; align-items: center; gap: 6px; }
.ship-pick .icon-btn { font-size: 30px; flex: none; }
.ship-view { flex: 1; height: 180px; touch-action: pan-y; }
.ship-view canvas { display: block; width: 100% !important; height: 100% !important; }
.ship-name { text-align: center; font-size: 20px; font-weight: 800; margin-top: 4px; }
.ship-hint { text-align: center; font-size: 13px; margin-top: 2px; }

.colors { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 14px; }
.colors button { width: 38px; height: 38px; border-radius: 50%; border: 0; background: var(--c); cursor: pointer; box-shadow: 0 0 0 2px rgba(0,0,0,0.4) inset; transition: transform 0.15s; }
.colors button.on { box-shadow: 0 0 0 3px #0b0b10, 0 0 0 5px #fff; transform: scale(1.08); }
.colors button.taken { opacity: 0.18; cursor: default; background: linear-gradient(135deg, transparent 45%, #fff 45%, #fff 55%, transparent 55%), var(--c); }

/* bouton Boost de l'accueil */
.boost-btn { position: relative; overflow: hidden; width: 100%; height: 64px; border: 0; border-radius: 20px; cursor: pointer;
  background: color-mix(in srgb, var(--c) 30%, #15151d); color: #fff; font: 800 22px 'Inter', sans-serif; box-shadow: inset 0 0 0 2px var(--c); }
.boost-btn:active { transform: scale(0.97); }
.boost-btn .bb-txt { position: relative; }
.boost-btn .bb-fill { position: absolute; inset: 0; transform-origin: 0 50%; background: var(--c); opacity: 0.35; transform: scaleX(0); }
.boost-btn.cooling { background: #15151d; color: var(--text-2); box-shadow: inset 0 0 0 2px rgba(255,255,255,0.12); }
.boost-btn.cooling .bb-fill { animation: bb-fill linear forwards; }
@keyframes bb-fill { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* télécommande de la télé (barre admin) : emojis seulement */
.tv-remote { display: flex; gap: 6px; width: 100%; }
.tv-remote button { flex: 1; height: 42px; border: 0; border-radius: 12px; background: rgba(255, 255, 255, 0.06); font-size: 21px; cursor: pointer; }
.tv-remote button.on { background: var(--accent-soft, rgba(139, 92, 246, 0.35)); box-shadow: inset 0 0 0 1.5px var(--accent, #8b5cf6); }
.tv-remote button:active { transform: scale(0.95); }
#admin-bar { flex-wrap: wrap; row-gap: 8px; }

/* écran d'attente : mon vaisseau */
.g-ship { height: 200px; margin-top: 10px; }
.g-ship canvas { display: block; width: 100% !important; height: 100% !important; }
/* retour visuel quand on touche une réponse */
.g-opt { transition: box-shadow 0.15s, background 0.15s; }
.g-opt:active, .g-opt.lit, .g-opt.on { box-shadow: inset 0 0 0 2px var(--me, #8b5cf6), 0 0 22px color-mix(in srgb, var(--me, #8b5cf6) 45%, transparent); background: color-mix(in srgb, var(--me, #8b5cf6) 22%, rgba(20, 20, 28, 0.8)); }
/* rejoindre en un tap, installer */
.quick-join { width: 100%; min-height: 58px; font-size: 18px; margin-bottom: 4px; }
.install-card .s { margin-top: 4px; }
/* état du Pi */
.ps-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; }
.ps-grid span { display: block; font-size: 12px; color: var(--text-2); text-transform: uppercase; letter-spacing: 0.06em; }
.ps-grid b { font-size: 18px; }
.ps-grid b.good { color: #22c55e; } .ps-grid b.warn { color: #f59e0b; } .ps-grid b.bad { color: #ef4444; }
/* mode léger : pas de flou ni d'animations de fond, pas de 3D */
body.lite * { backdrop-filter: none !important; -webkit-backdrop-filter: none !important; }
body.lite .glass { background: rgba(22, 22, 30, 0.96) !important; }
body.lite .backdrop * { animation: none !important; }
body.lite .ship-card .ship-view, body.lite .g-ship { display: none; }

/* notifications : pastille en haut, centrée */
.toast { left: 16px !important; right: 16px !important; top: calc(env(safe-area-inset-top) + 14px) !important; bottom: auto !important; transform: none !important;
  margin: 0 auto; width: fit-content; max-width: calc(100vw - 32px); padding: 12px 18px !important; border-radius: 16px !important;
  font-size: 15px; font-weight: 600; line-height: 1.35; text-align: center; color: #fff;
  background: rgba(24, 24, 32, 0.92) !important; border: 1px solid rgba(255, 255, 255, 0.12) !important;
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); box-shadow: 0 12px 34px rgba(0, 0, 0, 0.5) !important;
  animation: toast-in 0.35s cubic-bezier(.2, .9, .3, 1.2) both !important; }
.toast.ok { box-shadow: inset 0 0 0 1.5px rgba(34, 197, 94, 0.7), 0 12px 34px rgba(0, 0, 0, 0.5) !important; }
.toast.bad { box-shadow: inset 0 0 0 1.5px rgba(239, 68, 68, 0.8), 0 12px 34px rgba(0, 0, 0, 0.5) !important; }
@keyframes toast-in { from { opacity: 0; transform: translateY(-16px) scale(0.96); } }
/* Prêt ? */
.rd-btn { display: flex; align-items: center; justify-content: center; gap: 12px; }
.rd-count { font-size: 15px; font-weight: 700; padding: 4px 10px; border-radius: 99px; background: rgba(0, 0, 0, 0.25); }
.rd-spec { width: 100%; margin-top: 10px; }
.rd-ok.spec { color: var(--text-2); }

.g-btns { display: flex; flex-direction: column; gap: 10px; margin-top: 14px; }
.g-btns .btn { min-height: 56px; font-size: 18px; }
.g-big { font-size: 64px; line-height: 1; margin-bottom: 8px; }
.g-secret { margin-top: 14px; padding: 16px; border-radius: 16px; background: rgba(0,0,0,0.35); font-size: 20px; font-weight: 700; line-height: 1.35; }

.lg-roles .row { gap: 10px; }
.lg-emo { font-size: 28px; width: 36px; text-align: center; }
.lg-n { min-width: 26px; text-align: center; font-size: 20px; }

/* Uno */
.uno-top { display: flex; align-items: center; gap: 16px; }
.ut-pile { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.ucard.small { --cw: 54px; }
.ut-color { font-size: 12px; font-weight: 800; padding: 2px 8px; border-radius: 99px; color: #fff; }
.ut-color.c-r { background: #e5293a; } .ut-color.c-y { background: #f5c518; color: #222; } .ut-color.c-g { background: #2fa84f; } .ut-color.c-b { background: #1f6fd1; }
.ut-info { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.ut-info b { font-size: 18px; }
.ut-info span { font-size: 13px; }
.uno-acts { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0; }
.uno-acts .btn { flex: 1; min-height: 50px; }
.uno-btn { font-weight: 900; letter-spacing: 0.05em; }
.uno-hand { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; padding-bottom: 20px; }
.uno-hand .ucard { --cw: 64px; cursor: pointer; transition: transform 0.15s; }
.uno-hand .ucard.ok { transform: translateY(-6px); box-shadow: inset 0 0 0 4px #fff, 0 0 0 3px var(--me, #8b5cf6), 0 8px 20px rgba(0,0,0,0.5); }
.uno-hand .ucard.no { filter: brightness(0.45); }
.uno-pick { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; background: rgba(0,0,0,0.6); padding: 20px; }
.uno-pick[hidden] { display: none; }
.up-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
.up-c { height: 70px; border: 0; border-radius: 16px; font: 800 18px 'Inter', sans-serif; color: #fff; }
.up-c.c-r { background: #e5293a; } .up-c.c-y { background: #f5c518; color: #222; } .up-c.c-g { background: #2fa84f; } .up-c.c-b { background: #1f6fd1; }
/* Skyjo */
.sk-top { display: flex; justify-content: center; gap: 18px; }
.sk-pile { appearance: none; border: 0; background: none; color: #fff; display: flex; flex-direction: column; align-items: center; gap: 6px; font: 600 13px 'Inter', sans-serif; padding: 0; }
.sk-pile:disabled { opacity: 0.45; }
.sk-pile.held .sky { box-shadow: 0 0 0 3px #fff, 0 0 20px rgba(255,255,255,0.4); }
.sk-hint { text-align: center; display: flex; flex-direction: column; gap: 4px; margin-top: 10px; }
.sk-last { color: #fca5a5; font-weight: 800; }
.sk-grid { display: flex; justify-content: center; gap: 8px; margin: 14px 0 20px; }
.sk-col { display: flex; flex-direction: column; gap: 8px; }
.sk-cell { appearance: none; border: 0; background: none; padding: 0; }
.sk-cell .sky { --cw: 68px; }
.sk-grid:not(.active) .sk-cell { pointer-events: none; }

.uno-hand .ucard.played { animation: card-out 0.25s ease-in forwards; }
@keyframes card-out { to { transform: translateY(-120px) scale(0.6) rotate(-12deg); opacity: 0; } }
.uno-hand .ucard { animation: card-in 0.3s var(--ease, ease) both; }
@keyframes card-in { from { transform: translateY(30px) scale(0.85); opacity: 0; } }

.sk-mode { margin-top: 12px; }
.sk-grid.flipmode .sk-cell .sky:not(.hid) { opacity: 0.35; }
.sk-grid.flipmode .sk-cell .sky.hid { box-shadow: 0 0 0 3px var(--me, #8b5cf6), 0 0 16px color-mix(in srgb, var(--me, #8b5cf6) 50%, transparent); }

/* fin de jeu */
.fin-card { text-align: center; animation: pop-in 0.6s var(--spring, ease) both; }
.fin-emoji { font-size: 76px; line-height: 1; animation: fin-bounce 1.2s ease-in-out infinite alternate; }
@keyframes fin-bounce { to { transform: translateY(-8px) rotate(-6deg); } }
.fin-pts { font-size: 40px; font-weight: 900; color: var(--me, #8b5cf6); margin: 6px 0; }
.fin-card.rank1 { box-shadow: inset 0 0 0 2px #fbbf24, 0 0 40px rgba(251, 191, 36, 0.25); }
/* chrono */
#game-timer { position: relative; height: 6px; margin: 0 0 10px; }
#game-timer:empty { display: none; }
.gt-bar { height: 6px; border-radius: 99px; background: rgba(255, 255, 255, 0.1); overflow: hidden; }
.gt-bar i { display: block; height: 100%; background: var(--me, #8b5cf6); transform-origin: 0 50%; transition: transform 0.2s linear; }
#game-timer.urgent .gt-bar i { background: #ef4444; }
.gt-sec { position: absolute; right: 0; top: 10px; font-size: 26px; font-weight: 900; color: #ef4444; }
#game-timer.urgent { animation: gt-pulse 0.5s ease-in-out infinite alternate; }
@keyframes gt-pulse { to { opacity: 0.55; } }
/* réactions */
.react-bar { display: flex; justify-content: center; gap: 8px; margin-top: 14px; }
.react-bar button { width: 56px; height: 56px; border: 0; border-radius: 18px; background: rgba(255, 255, 255, 0.08); font-size: 28px; cursor: pointer; }
.react-bar button.pop { animation: react-pop 0.35s ease; }
@keyframes react-pop { 50% { transform: scale(1.35); } }
/* Uno : groupes de couleur */
.uno-hand { flex-direction: column; align-items: center; gap: 10px; }
.uno-group { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; padding: 6px; border-radius: 16px; background: rgba(255, 255, 255, 0.03); }

/* vaisseau 2D (profil, attente) */
.ship-2d { width: min(260px, 80%); height: 100%; margin: 0 auto; display: grid; place-items: center; animation: ship-float 3.2s ease-in-out infinite; }
.ship-2d svg { width: 100%; height: auto; }
@keyframes ship-float { 50% { transform: translateY(-8px) rotate(-2deg); } }

.g-word { flex-direction: column; gap: 2px; min-height: 64px; }
.g-lvl { font-size: 13px; font-weight: 600; opacity: 0.85; }

.react-fly { position: fixed; z-index: 90; font-size: 40px; pointer-events: none; transform: translate(-50%, 0); animation: react-fly 1.1s ease-out forwards; }
@keyframes react-fly { to { transform: translate(-50%, -260px) scale(1.6); opacity: 0; } }

/* Uno : la main sur une seule ligne, qu'on fait défiler */
.uno-hand { flex-direction: row !important; flex-wrap: nowrap !important; justify-content: flex-start !important; align-items: flex-end; gap: 0 !important;
  overflow-x: auto; overflow-y: visible; padding: 16px 12px 22px !important; scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch; }
.uno-hand .ucard { --cw: 76px; margin-right: -14px; scroll-snap-align: start; }
.uno-hand .ucard:last-child { margin-right: 0; }
.uno-hand .ucard.ok { transform: translateY(-12px); z-index: 2; }

.sk-cell.sel .sky { transform: translateY(-6px) scale(1.06); box-shadow: 0 0 0 3px #fff, 0 0 0 6px var(--me, #8b5cf6), 0 10px 24px rgba(0,0,0,0.5); }
.sk-confirm:empty { display: none; }
.sk-confirm { position: sticky; bottom: 90px; }

.pk-end { width: 100%; margin-top: 12px; }
.pk-btns .pk-go { flex: 1; }

.pk-end { margin-top: 28px !important; }

/* bouton d'envoi validé */
.btn.sent { background: #16a34a !important; border-color: #16a34a !important; color: #fff !important; animation: sent-pop 0.35s ease; }
@keyframes sent-pop { 40% { transform: scale(1.06); } }
.d-fill.on { box-shadow: inset 0 0 0 2px #fff; background: rgba(255, 255, 255, 0.18); }
.g-opt.mine { opacity: 0.4; pointer-events: none; }

/* Uno : toute la main visible, sans défilement */
.uno-hand { overflow: visible !important; justify-content: center !important; scroll-snap-type: none !important; padding: 18px 12px 22px !important; }
.uno-hand .ucard { --cw: var(--cw2, 76px) !important; margin-right: var(--ov, -14px) !important; }
.uno-hand .ucard:last-child { margin-right: 0 !important; }
.uno-turn { text-align: center; font-size: 26px; font-weight: 900; letter-spacing: 0.06em; padding: 14px; margin-bottom: 10px; border-radius: 18px;
  background: var(--me, #8b5cf6); color: #fff; animation: uno-turn 1.2s ease-in-out infinite; }
@keyframes uno-turn { 50% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--me, #8b5cf6) 40%, transparent), 0 0 40px var(--me, #8b5cf6); } }
.uno-wait { text-align: center; font-size: 18px; color: var(--text-2); padding: 10px; margin-bottom: 10px; }
.uno-top.mine { box-shadow: inset 0 0 0 2px var(--me, #8b5cf6); }
/* Uno : effets sur le téléphone */
.ufx-p { position: fixed; inset: 0; z-index: 95; display: grid; place-content: center; justify-items: center; gap: 8px; pointer-events: none; background: rgba(0, 0, 0, 0.45); animation: ufxp 1.8s ease both; }
.ufx-p b { font-size: 140px; font-weight: 900; line-height: 1; }
.ufx-p span { font-size: 26px; font-weight: 800; text-align: center; padding: 0 20px; }
.ufx-p.skip b { color: #ef4444; } .ufx-p.plus b { color: #f97316; } .ufx-p.rev b { color: #f5c518; }
.ufx-p.me { background: rgba(120, 0, 0, 0.55); }
@keyframes ufxp { from { opacity: 0; transform: scale(0.6); } 15% { opacity: 1; transform: scale(1.05); } 25% { transform: scale(1); } 80% { opacity: 1; } to { opacity: 0; } }
.win-p { position: fixed; inset: 0; z-index: 95; pointer-events: none; overflow: hidden; }
.win-p i { position: absolute; top: -30px; left: var(--x); width: 10px; height: 18px; background: var(--c); border-radius: 2px; animation: un-fall-p 2.6s linear var(--d) both; }
@keyframes un-fall-p { to { transform: translateY(110vh) rotate(720deg); } }
.win-p b { position: absolute; inset: 0; display: grid; place-items: center; font-size: 110px; animation: ufxp 2.6s ease both; }

/* Skyjo : la main un peu à l'écart, poubelle */
.sk-sep { width: 1px; align-self: stretch; margin: 0 8px; background: rgba(255, 255, 255, 0.18); }
.sk-pile.held { margin-left: 4px; }
.sk-pile span { font-size: 14px; }
.sk-empty { width: 58px; height: 80px; border-radius: 10px; border: 2px dashed rgba(255, 255, 255, 0.25); }
.sk-fly { animation: sk-fly 0.5s cubic-bezier(.5, 0, .7, 1) forwards; }
@keyframes sk-fly { 30% { transform: translateY(-20px) scale(1.1) rotate(-6deg); } to { transform: translate(var(--tx), var(--ty)) scale(0.85) rotate(12deg); opacity: 0.9; } }

.react-bar { padding-right: 76px; }
.react-bar button { width: 50px !important; height: 50px !important; font-size: 25px !important; transition: opacity 0.2s, filter 0.2s; }
.react-bar.cool button { opacity: 0.35; filter: grayscale(1); pointer-events: none; }

/* ============ Lot 1 (nov. 2026) ============ */
/* rejoindre : lien admin discret */
.admin-link { text-align: center; margin: 4px 0 8px; }
.admin-link .link-btn { font-size: 13px; opacity: 0.7; }
.admin-link .field { margin-top: 10px; text-align: left; }

/* ⚙️ : trois boutons */
.sheet-menu { gap: 10px; }
.sheet-menu .btn { width: 100%; justify-content: flex-start; }
.sheet-menu .btn.on { box-shadow: inset 0 0 0 2px var(--accent, #8b5cf6); }
.set-pause { width: 100%; margin: 4px 0 6px; }

/* réactions : tout en bas, sur toute la largeur ; le chat juste au-dessus */
#react-dock { position: fixed; left: 0; right: 0; bottom: 0; z-index: 24; padding: 8px 10px calc(8px + env(safe-area-inset-bottom)); background: linear-gradient(to top, rgba(0, 0, 0, 0.85), rgba(0, 0, 0, 0)); }
#react-dock:empty { display: none; }
#react-dock .react-bar { display: flex; gap: 8px; margin: 0; padding: 0 !important; }
#react-dock .react-bar button { flex: 1; width: auto !important; height: 56px !important; font-size: 28px !important; border-radius: 16px; }
.chat-fab { bottom: calc(env(safe-area-inset-bottom) + 16px) !important; right: 16px !important; }
body.has-react .chat-fab { bottom: calc(env(safe-area-inset-bottom) + 84px) !important; }
body.has-react #app { padding-bottom: 150px; }

/* dernières secondes sans avoir répondu : le tour de l'écran clignote en rouge */
body::after { content: ''; position: fixed; inset: 0; z-index: 200; pointer-events: none; opacity: 0; box-shadow: inset 0 0 0 6px #ff2b3d, inset 0 0 40px 10px rgba(255, 43, 61, 0.55); transition: opacity 0.2s; }
body.hurry::after { animation: hurry 0.5s ease-in-out infinite alternate; }
@keyframes hurry { from { opacity: 0.25; } to { opacity: 1; } }
.gt-sec { display: none !important; }

/* « On t'attend ! » au milieu, au-dessus des boutons */
.rd-nudge { margin: 6px 0 14px; padding: 18px 16px; border-radius: 20px; text-align: center; font-size: 30px; font-weight: 900; letter-spacing: 0.01em;
  background: var(--me, #8b5cf6); color: #fff; animation: nudge-in 0.4s var(--spring) both, nudge-pulse 0.9s 0.4s ease-in-out infinite alternate; }
.rd-nudge small { display: block; font-size: 15px; font-weight: 600; opacity: 0.9; margin-top: 4px; }
@keyframes nudge-in { from { transform: scale(0.6); opacity: 0; } }
@keyframes nudge-pulse { to { transform: scale(1.04); box-shadow: 0 0 40px color-mix(in srgb, var(--me, #8b5cf6) 70%, transparent); } }

/* gorgées : petit bandeau net en haut de l'écran */
.drink-phone { position: fixed; left: 0; right: 0; top: calc(env(safe-area-inset-top) + 14px); z-index: 80; display: flex; justify-content: center; padding: 0 16px; pointer-events: auto;
  bottom: auto; background: none !important; animation: dp-in 0.45s var(--spring) both; }
.drink-phone.out { animation: dp-out 0.35s ease forwards; }
.dp-card { display: flex; align-items: center; gap: 14px; padding: 10px 22px 10px 12px; border-radius: 18px; background: #111116; border: 1.5px solid #f5b83d; box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6); }
.dp-n { min-width: 52px; height: 52px; padding: 0 8px; border-radius: 14px; display: grid; place-items: center; background: #f5b83d; color: #111; font-size: 30px; font-weight: 900; }
.dp-txt { display: flex; flex-direction: column; line-height: 1.15; }
.dp-txt b { font-size: 20px; font-weight: 800; letter-spacing: 0.02em; text-transform: uppercase; }
.dp-txt small { font-size: 13px; color: var(--text-2); }
@keyframes dp-in { from { transform: translateY(-120%); opacity: 0; } }
@keyframes dp-out { to { transform: translateY(-120%); opacity: 0; } }

/* vote à confirmer */
.g-cand { position: relative; }
.g-cand.arm { border-color: #fff !important; box-shadow: 0 0 0 3px var(--me, #8b5cf6) !important; transform: scale(1.04); }
.g-cand em { font-style: normal; font-size: 11px; font-weight: 700; color: #fff; background: var(--me, #8b5cf6); padding: 3px 7px; border-radius: 8px; white-space: nowrap; animation: nudge-pulse 0.7s ease-in-out infinite alternate; }
.g-strong { color: var(--me, #fff); font-weight: 900; }
.g-big { font-size: 64px; line-height: 1; margin-bottom: 8px; }

/* Loup Garou : la carte */
.lgc-stage { display: grid; justify-items: center; gap: 12px; padding: 10px 0 4px; }
.lgc { width: min(72vw, 280px); aspect-ratio: 5 / 7; perspective: 1200px; cursor: pointer; }
.lgc.arrive { animation: lgc-arrive 0.9s cubic-bezier(.2, .9, .3, 1.1) both; }
@keyframes lgc-arrive { from { transform: translate(60vw, -40vh) rotate(40deg) scale(0.5); opacity: 0; } 70% { transform: translate(0, 0) rotate(-4deg) scale(1.02); opacity: 1; } }
.lgc-inner { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform 0.7s cubic-bezier(.3, .7, .3, 1.2); }
.lgc.flip .lgc-inner { transform: rotateY(180deg); }
.lgc-face { position: absolute; inset: 0; border-radius: 20px; backface-visibility: hidden; -webkit-backface-visibility: hidden; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 18px; border: 3px solid #000; box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6); }
.lgc-back { background: repeating-linear-gradient(45deg, #2a1650 0 12px, #1e0f3b 12px 24px); }
.lgc-back span { font-size: 80px; filter: drop-shadow(0 4px 0 #000); }
.lgc-back b { margin-top: 10px; font-size: 18px; letter-spacing: 0.2em; text-transform: uppercase; color: #f5b83d; }
.lgc-front { transform: rotateY(180deg); background: linear-gradient(170deg, #fdf6e3, #e9dcbc); color: #1a1426; }
.lgc-emo { font-size: 72px; line-height: 1; }
.lgc-name { font-size: 26px; font-weight: 900; margin: 8px 0 6px; }
.lgc-front p { font-size: 14px; line-height: 1.35; margin: 0; }
.lgc-extra { margin-top: 8px; font-size: 13px; font-weight: 800; padding: 4px 10px; border-radius: 10px; background: #1a1426; color: #f5b83d; }
.lgc-tip { margin: 0; font-size: 14px; color: var(--text-2); }
.lgc-overlay { position: fixed; inset: 0; z-index: 90; display: grid; place-content: center; justify-items: center; gap: 14px; background: rgba(0, 0, 0, 0.82); }
.lg-see { display: block; width: 100%; margin-top: 14px; opacity: 0.85; }

/* ============ Lot 2 (nov. 2026) ============ */
/* admin : barre tout en haut, au-dessus de tout */
.tabbar, .tv-remote { display: none !important; }
.admnav { position: sticky; top: 0; z-index: 40; display: flex; gap: 6px; margin: 0 -16px 10px; padding: calc(env(safe-area-inset-top) + 8px) 12px 8px;
  background: #0d1019; border-bottom: 3px solid #000; box-shadow: 0 2px 0 #263250; }
.admnav[hidden], .admsub[hidden] { display: none !important; }
.admnav button, .admsub button { flex: 1; height: 46px; border: 3px solid #000; border-radius: 12px; background: #1b2235; font-size: 22px; cursor: pointer; box-shadow: 3px 3px 0 #000; }
.admnav button.on, .admsub button.on { background: var(--me, #8b5cf6); }
.admnav button:active, .admsub button:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 #000; }
.admsub { position: sticky; top: calc(env(safe-area-inset-top) + 66px); z-index: 39; display: flex; gap: 6px; margin: -4px 0 12px; padding: 8px; border-radius: 14px;
  background: #151b2c; border: 3px solid #000; box-shadow: 4px 4px 0 #000; animation: sub-in 0.2s ease both; }
@keyframes sub-in { from { transform: translateY(-10px); opacity: 0; } }

/* liste des jeux (la télé fait défiler les jeux) */
.gl-h { display: flex; align-items: center; justify-content: space-between; margin: 4px 2px 10px; }
.gl-h span { font-size: 14px; font-weight: 600; color: var(--text-2); }
.gl { display: flex; flex-direction: column; gap: 10px; }
.gl-row { padding: 12px 14px; border-radius: 14px; background: #151b2c; border: 3px solid #000; box-shadow: 4px 4px 0 #000; }
.gl-row.focus { box-shadow: 0 0 0 3px var(--me, #8b5cf6), 4px 4px 0 #000; }
.gl-top { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.gl-top b { font-size: 18px; }
.gl-min { flex: none; font-size: 12px; font-weight: 800; padding: 2px 8px; border-radius: 8px; background: #000; color: #f5b83d; }
.gl-row p { margin: 4px 0 0; font-size: 14px; color: var(--text-2); line-height: 1.35; }
.gl-row.off { opacity: 0.38; filter: grayscale(1); }

/* Loup Garou : cartes illustrées */
.lgc-front { padding: 0 0 14px !important; justify-content: flex-start !important; overflow: hidden; }
.lgc-art { width: 100%; height: 56%; object-fit: cover; border-bottom: 3px solid #000; }
.lgc-front .lgc-name { margin-top: 8px !important; }
.lgc-front p { padding: 0 12px; }
.lgc-back { padding: 0 !important; overflow: hidden; }
.lgc-dos { width: 100%; height: 100%; object-fit: cover; }

/* Uno : juste à qui le tour + la carte du dessus */
.uno-top.solo { justify-content: center; margin: 6px 0 14px; }
.uno-top.solo .ucard { --cw: 110px; width: 110px; }

/* écran des jeux : grille de planètes, on touche pour voter */
.gv-h { text-align: center; font: 800 20px 'Orbitron', 'Inter', sans-serif; margin: 2px 0 12px; }
.gv { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.gv-t { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 4px 8px; border-radius: 14px; background: #151b2c; border: 3px solid #000; box-shadow: 3px 3px 0 #000; color: #fff; font: inherit; }
.gv-t b { font-size: 12.5px; line-height: 1.15; text-align: center; min-height: 2.3em; display: grid; place-items: center; }
.gv-p { width: 54px; height: 54px; display: grid; place-items: center; }
.gv-p .p2 { --size: 54px; }
.gv-t small { font-size: 10px; color: #f5b83d; font-weight: 800; }
.gv-t.off { opacity: 0.35; filter: grayscale(1); }
.gv-t.focus { box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.5), 3px 3px 0 #000; }
.gv-t.mine { background: color-mix(in srgb, var(--me, #8b5cf6) 30%, #151b2c); box-shadow: 0 0 0 3px var(--me, #8b5cf6), 3px 3px 0 #000; }
.gv-t:active:not([disabled]) { transform: translate(2px, 2px); box-shadow: 1px 1px 0 #000; }
.gv-who { display: flex; gap: 3px; align-items: center; }
.gv-who i { width: 10px; height: 10px; border-radius: 50%; border: 2px solid #000; }
.gv-who em { font-style: normal; font-size: 10px; font-weight: 800; }

/* Skyjo : une carte qui se retourne (face cachée → valeur) */
.sky.sk-flipin { animation: sk-flipin 0.6s cubic-bezier(.3, .7, .3, 1) both; }
@keyframes sk-flipin {
  0% { transform: perspective(500px) rotateY(180deg) scale(1.1); filter: brightness(0.4); }
  50% { transform: perspective(500px) rotateY(90deg) scale(1.15); filter: brightness(0.6); }
  100% { transform: perspective(500px) rotateY(0) scale(1); filter: none; }
}
.sk-hint { margin-top: 12px; }

.gv-t { cursor: pointer; user-select: none; }
.gv-t[data-off] { opacity: 0.35; filter: grayscale(1); }
.gv-t:active:not([data-off]) { transform: translate(2px, 2px); box-shadow: 1px 1px 0 #000; }
.gv-i { position: absolute; right: 5px; top: 5px; width: 22px; height: 22px; border-radius: 50%; border: 2px solid #000; background: #f5b83d; color: #000; font: italic 900 13px/1 Georgia, serif; display: grid; place-items: center; padding: 0; z-index: 2; }
.gv-sheet { position: fixed; inset: 0; z-index: 90; background: rgba(0, 0, 0, 0.7); display: grid; place-items: center; padding: 20px; animation: fade-in 0.2s ease both; }
.gv-card { width: 100%; max-width: 360px; background: #151b2c; border: 3px solid #000; box-shadow: 6px 6px 0 #000; border-radius: 18px; padding: 20px; display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; }
.gv-cp .p2 { --size: 90px; }
.gv-card h2 { margin: 0; font: 900 24px 'Orbitron', 'Inter', sans-serif; }
.gv-min { font-size: 13px; font-weight: 800; padding: 3px 10px; border-radius: 8px; background: #000; color: #f5b83d; }
.gv-card p { margin: 4px 0 8px; font-size: 16px; line-height: 1.45; color: var(--text-2); }
.gv-card .btn { width: 100%; }
@keyframes fade-in { from { opacity: 0; } }

.teams-set { display: none; }
body.teams-on .teams-set { display: flex; }

.lg-deal[disabled] { opacity: 1; background: #2a2f45; color: #f5b83d; filter: none; box-shadow: 3px 3px 0 #000; font-size: 15px; }

/* ===== nouveaux jeux (téléphone) ===== */
/* Réflexes */
.rx-pad { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 62vh; border-radius: 26px; border: 4px solid #000; box-shadow: 6px 6px 0 #000; color: #fff; font: inherit; touch-action: none; user-select: none; transition: background 0.08s; }
.rx-pad b { font: 900 40px 'Orbitron', 'Inter', sans-serif; letter-spacing: 0.03em; }
.rx-pad span { font-size: 16px; opacity: 0.85; }
.rx-pad.wait { background: #b4232f; }
.rx-pad.trap { background: #e0a400; color: #000; }
.rx-pad.go { background: #18a84a; animation: rx-go 0.25s ease-out; }
@keyframes rx-go { from { transform: scale(0.96); } }
.rx-pad.done { background: #1f2a44; }
.rx-pad.false { background: #3a0d12; }
/* Astéroïdes : manette */
.pad { display: flex; align-items: center; justify-content: space-between; gap: 18px; min-height: 60vh; padding: 10px 4px; touch-action: none; user-select: none; }
.pad-stick { position: relative; width: 170px; height: 170px; border-radius: 50%; background: radial-gradient(circle, #1d2440, #0d1124); border: 4px solid #000; box-shadow: 5px 5px 0 #000, inset 0 0 0 3px color-mix(in srgb, var(--pc) 60%, transparent); touch-action: none; }
.pad-stick i { position: absolute; left: 50%; top: 50%; width: 74px; height: 74px; margin: -37px 0 0 -37px; border-radius: 50%; background: var(--pc); border: 4px solid #000; box-shadow: 3px 3px 0 #000; }
.pad-fire { width: 140px; height: 140px; border-radius: 50%; background: #e5293a; color: #fff; border: 4px solid #000; box-shadow: 5px 5px 0 #000; font: 900 26px 'Orbitron', 'Inter', sans-serif; touch-action: none; }
.pad-fire:active { transform: translate(3px, 3px); box-shadow: 2px 2px 0 #000; background: #ff4d5c; }
/* Priorities */
.po-list { display: flex; flex-direction: column; gap: 10px; margin: 6px 0 14px; }
.po-it { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 16px; background: #151b2c; border: 3px solid #000; box-shadow: 4px 4px 0 #000; color: #fff; font: 700 18px 'Inter', sans-serif; text-align: left; }
.po-it b { flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: #0b0f1d; border: 2px dashed rgba(255,255,255,0.3); font: 900 18px 'Orbitron', sans-serif; }
.po-it.on { background: color-mix(in srgb, var(--me, #8b5cf6) 25%, #151b2c); }
.po-it.on b { background: var(--me, #8b5cf6); border: 2px solid #000; color: #fff; animation: un-pop 0.3s ease; }
/* Longueur d'onde */
.on-clue { text-align: center; font: 900 26px 'Inter', sans-serif; margin: 8px 0 22px; }
.on-gauge { margin: 10px 0 18px; }
.on-bar { position: relative; height: 70px; border-radius: 18px; border: 4px solid #000; box-shadow: 4px 4px 0 #000; background: linear-gradient(90deg, #4f9bff, #8b5cf6 50%, #ff5a6e); touch-action: none; }
.on-needle { position: absolute; top: -12px; bottom: -12px; width: 8px; margin-left: -4px; background: #fff; border: 3px solid #000; border-radius: 6px; transition: left 0.05s; }
.on-target { position: absolute; top: 0; bottom: 0; width: 18%; margin-left: -9%; background: repeating-linear-gradient(90deg, rgba(255,255,255,0.15) 0 3%, rgba(255,255,255,0.45) 3% 6%); border-left: 3px solid #fff; border-right: 3px solid #fff; }
.on-ends { display: flex; justify-content: space-between; margin-top: 10px; font-weight: 800; font-size: 16px; }
/* champs multiples */
.mu-letter { text-align: center; font: 900 84px/1 'Inter', sans-serif; color: #f5b83d; text-shadow: 4px 4px 0 #000; margin: 4px 0 8px; }
.mu-stop { text-align: center; font: 900 32px 'Orbitron', sans-serif; color: #fff; background: #e5293a; border: 3px solid #000; border-radius: 12px; padding: 6px; margin-bottom: 10px; animation: rx-go 0.3s ease, mu-blink 0.5s steps(2) infinite; }
@keyframes mu-blink { 50% { background: #8c1520; } }
.mu-f { display: flex; flex-direction: column; gap: 4px; }
.mu-f span { font-size: 13px; font-weight: 800; color: var(--text-2); text-transform: uppercase; letter-spacing: 0.04em; }
/* Petit Bac : vérification */
.fl-rows { display: flex; flex-direction: column; gap: 14px; margin-bottom: 14px; }
.fl-cat h3 { margin: 0 0 6px; font-size: 14px; text-transform: uppercase; color: var(--text-2); }
.fl-a { display: inline-flex; flex-direction: column; align-items: flex-start; margin: 0 6px 6px 0; padding: 8px 12px; border-radius: 12px; background: #151b2c; border: 2px solid #000; box-shadow: 3px 3px 0 #000; color: #fff; font: inherit; }
.fl-a b { font-size: 16px; }
.fl-a small { font-size: 11px; color: var(--text-2); }
.fl-a.no { background: #3a0d12; }
.fl-a.no b { text-decoration: line-through; color: #ff8a8a; }
.fl-a[disabled] { opacity: 0.4; }
/* Codenames */
.cn-head { text-align: center; font-weight: 900; padding: 10px; border-radius: 12px; background: var(--tc); color: #000; border: 3px solid #000; margin-bottom: 10px; }
.cn-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 5px; margin-bottom: 12px; }
.cn-c { min-height: 54px; padding: 4px 2px; border-radius: 8px; background: #f3ead6; color: #1b1640; border: 2px solid #000; font: 800 11px/1.1 'Inter', sans-serif; word-break: break-word; }
.cn-c.arm { outline: 3px solid #fff; transform: scale(1.06); }
.cn-c.k-0 { background: #f5b83d; } .cn-c.k-1 { background: #4f9bff; color: #fff; } .cn-c.k-n { background: #c9b99a; } .cn-c.k-x { background: #111; color: #fff; }
.cn-grid.chief .cn-c:not(.up) { opacity: 1; }
.cn-c.up { opacity: 0.35; text-decoration: line-through; }
.cn-c[disabled]:not(.up) { opacity: 0.9; }
/* La Bombe */
.bm-top { display: flex; align-items: center; justify-content: space-between; margin: 6px 0 16px; }
.bm-ico { font-size: 54px; animation: bm-shake 0.4s ease-in-out infinite; }
@keyframes bm-shake { 50% { transform: rotate(-8deg) scale(1.05); } }
.bm-s { font: 900 54px 'Orbitron', sans-serif; color: #f5b83d; text-shadow: 3px 3px 0 #000; padding: 4px 18px; border: 3px solid #000; border-radius: 14px; background: #151b2c; }
.bm-l { font-size: 22px; }
.bm-no { text-align: center; color: #ff8a8a; font-weight: 800; margin-top: 10px; }
.bm-no.shake { animation: bm-no 0.35s ease; }
@keyframes bm-no { 25% { transform: translateX(-8px); } 75% { transform: translateX(8px); } }
/* Bataille navale */
.nv-head { text-align: center; font-weight: 900; padding: 10px; border-radius: 12px; background: #151b2c; border: 3px solid var(--tc); margin-bottom: 12px; }
.nv-grid { display: grid; grid-template-columns: repeat(var(--n), 1fr); gap: 3px; padding: 6px; border-radius: 12px; background: #0b1530; border: 3px solid #000; box-shadow: 4px 4px 0 #000; }
.nv-c { aspect-ratio: 1; border-radius: 4px; background: #16244a; border: 1px solid #22356a; padding: 0; }
.nv-c.arm { background: #f5b83d; transform: scale(1.12); }
.nv-c.s-M { background: #0b1530; } .nv-c.s-M::after { content: '•'; color: #6f86c4; }
.nv-c.s-H { background: #e5293a; } .nv-c.s-S { background: #5a0c14; } .nv-c.s-F { background: #6b7380; }
/* Juste Prix, Cadavre exquis */
.g-num-img { display: block; max-width: 70%; max-height: 32vh; margin: 0 auto 12px; border-radius: 14px; border: 3px solid #000; background: #fff; object-fit: contain; }
.d-guide { position: absolute; inset: 0; pointer-events: none; }
.d-guide::before, .d-guide::after { content: ''; position: absolute; left: 38%; right: 38%; height: 0; border-top: 3px dashed rgba(139, 92, 246, 0.6); }
.d-guide.g0::after { bottom: 3%; } .d-guide.g0::before { display: none; }
.d-guide.g1::before { top: 3%; } .d-guide.g1::after { bottom: 3%; left: 30%; right: 30%; }
.d-guide.g2::before { top: 3%; left: 30%; right: 30%; } .d-guide.g2::after { display: none; }
/* Tu préfères */
.btn.tp-a { background: #e5293a !important; color: #fff !important; min-height: 90px; font-size: 18px; }
.btn.tp-b { background: #1f6fd1 !important; color: #fff !important; min-height: 90px; font-size: 18px; }

/* réponse envoyée : le bouton reste vert, la saisie est figée (retoucher le bouton pour modifier) */
form.locked .input { opacity: 0.75; }
form .btn.sent { background: #18a84a !important; color: #fff !important; }

/* Priorities : emplacements numérotés (chaud → froid) */
.po-slots { display: flex; flex-direction: column; gap: 10px; margin-bottom: 18px; }
.po-slot { display: flex; align-items: center; gap: 14px; min-height: 66px; padding: 8px 14px 8px 8px; border-radius: 18px; background: #0b0f1d; border: 3px dashed rgba(255, 255, 255, 0.25); color: #fff; font: 800 20px 'Inter', sans-serif; text-align: left; }
.po-slot b { flex: none; width: 50px; height: 50px; border-radius: 14px; display: grid; place-items: center; background: var(--hc); border: 3px solid #000; font: 900 26px 'Orbitron', sans-serif; color: #fff; text-shadow: 2px 2px 0 #000; }
.po-slot.on { background: #151b2c; border: 3px solid #000; box-shadow: 4px 4px 0 #000, inset 6px 0 0 var(--hc); animation: un-pop 0.25s ease; }
.po-pool { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; min-height: 54px; margin-bottom: 18px; }
.po-it { padding: 14px 18px; border-radius: 16px; background: #f3ead6; color: #1b1640; border: 3px solid #000; box-shadow: 4px 4px 0 #000; font: 900 19px 'Inter', sans-serif; }
.po-it:active { transform: translate(2px, 2px); box-shadow: 2px 2px 0 #000; }
.po-ok { width: 100%; }

/* Space Invaders : manette */
.pad-ud { display: flex; flex-direction: column; gap: 18px; }
.pad-b { width: 130px; height: 130px; border-radius: 28px; background: #1d2440; color: #fff; border: 4px solid #000; box-shadow: 5px 5px 0 #000, inset 0 0 0 3px color-mix(in srgb, var(--pc) 60%, transparent); font-size: 56px; touch-action: none; user-select: none; }
.pad-b.on, .pad-fire.on { transform: translate(3px, 3px); box-shadow: 2px 2px 0 #000; filter: brightness(1.3); }
.pad-fire { width: 170px; height: 170px; }

/* Codenames : cartes lisibles, couleurs du capitaine */
.cn-head { font-size: 17px; }
.cn-grid { gap: 6px; }
.cn-c { position: relative; min-height: 76px; padding: 6px 3px; border-radius: 10px; border: 3px solid #000; box-shadow: 3px 3px 0 #000; font: 900 12.5px/1.1 'Inter', sans-serif; text-transform: uppercase; letter-spacing: -0.01em; overflow-wrap: anywhere; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; }
.cn-c i { font-style: normal; font-size: 18px; }
.cn-c.k-x { background: #111 !important; color: #ff5a6e !important; }
.cn-c.up { opacity: 0.3; }
.cn-c.up span { text-decoration: line-through; }
.cn-grid.chief .cn-c.k-0, .cn-grid.chief .cn-c.k-1, .cn-grid.chief .cn-c.k-n { opacity: 1; }
.cn-grid.chief .cn-c.up { opacity: 0.3; }
.cn-c[disabled]:not(.up) { opacity: 1; }
.cn-legend { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-bottom: 10px; }
.cn-legend span { padding: 4px 10px; border-radius: 8px; border: 2px solid #000; font-size: 12px; font-weight: 900; }
.cn-legend .k-0 { background: #f5b83d; color: #111; } .cn-legend .k-1 { background: #4f9bff; color: #fff; } .cn-legend .k-n { background: #c9b99a; color: #111; } .cn-legend .k-x { background: #111; color: #ff5a6e; }
.g-title h2 { white-space: pre-line; }

/* Petit Bac */
.pbs-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.pbs-c { padding: 10px 14px; border-radius: 12px; background: #151b2c; color: #fff; border: 2px solid #000; box-shadow: 3px 3px 0 #000; font: 700 14px 'Inter', sans-serif; }
.pbs-c.on { background: #f5b83d; color: #111; }
.pb-stop { width: 100%; margin-top: 12px; min-height: 64px; font: 900 28px 'Orbitron', sans-serif; background: #e5293a !important; color: #fff !important; }
.pb-stop[disabled] { background: #3a3f52 !important; color: #8b90a8 !important; }
.pb-stopped { position: fixed; inset: 0; z-index: 60; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; background: rgba(120, 10, 20, 0.82); pointer-events: none; animation: un-pop 0.35s ease both; }
.pb-stopped b { font: 900 96px 'Orbitron', sans-serif; color: #fff; text-shadow: 6px 6px 0 #000; }
.pb-stopped span { font: 800 22px 'Inter', sans-serif; color: #fff; }

/* Tu préfères ? */
.tp-title { text-align: center; font: 900 26px 'Orbitron', sans-serif; margin: 4px 0 14px; }
.tp-duel { display: flex; flex-direction: column; gap: 12px; position: relative; }
.tp-opt { min-height: 26vh; padding: 20px; border-radius: 24px; border: 4px solid #000; box-shadow: 6px 6px 0 #000; color: #fff; font: 900 24px/1.2 'Inter', sans-serif; text-shadow: 2px 2px 0 rgba(0,0,0,0.5); transition: transform 0.15s, opacity 0.2s; }
.tp-opt.a { background: #e5293a; } .tp-opt.b { background: #1f6fd1; }
.tp-opt.on { box-shadow: 0 0 0 5px #fff, 6px 6px 0 #000; transform: scale(1.02); }
.tp-opt.on::after { content: ' ✓'; }
.tp-opt.off { opacity: 0.45; }
.tp-or2 { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 2; width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: #0b0f1d; border: 4px solid #000; font: 900 20px 'Orbitron', sans-serif; }

/* Bataille spatiale : placement */
.nvp-ships { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-bottom: 8px; }
.nvp-s { display: flex; flex-direction: column; align-items: center; padding: 6px 10px; border-radius: 10px; background: #151b2c; color: #fff; border: 2px solid #000; box-shadow: 3px 3px 0 #000; font: inherit; }
.nvp-s b { font-size: 12px; } .nvp-s span { font-size: 11px; letter-spacing: 1px; color: #5fd4ff; }
.nvp-s.on { background: #f5b83d; color: #111; } .nvp-s.on span { color: #111; }
.nvp-s.done:not(.on) { opacity: 0.6; } .nvp-s.done b::after { content: ' ✓'; }
.nvp-tools { display: flex; gap: 8px; justify-content: center; margin-bottom: 10px; }
.nv-grid.place .nv-c.ship { background: #5fd4ff; border-color: #000; }
.nv-grid.place .nv-c.ship.sel { background: #f5b83d; }
.nvp-ok { width: 100%; margin-top: 12px; }

/* Draw my mutant : bas du morceau d'avant */
.d-prev { border-radius: 14px 14px 0 0; overflow: hidden; border: 3px dashed rgba(139, 92, 246, 0.7); border-bottom: none; margin-bottom: -3px; opacity: 0.85; }
.d-prev canvas { display: block; width: 100%; }
.cn-c { overflow-wrap: normal; word-break: keep-all; }
.cn-c.l { font-size: 10.5px; letter-spacing: -0.03em; }
.cn-c.xl { font-size: 9px; letter-spacing: -0.04em; }

/* jamais de débordement horizontal : sinon le navigateur dézoome toute la page (tout devient minuscule jusqu'à l'actualisation) */
html, body { max-width: 100%; overflow-x: clip; }
#app, #home, .view { max-width: 100vw; overflow-x: clip; }
img, canvas, svg { max-width: 100%; }

.fin-sips { margin: 6px auto 4px; padding: 8px 16px; border-radius: 14px; background: #2a2210; border: 3px solid #f5b83d; color: #f5b83d; font-weight: 900; font-size: 20px; display: inline-block; }

/* Space Invaders : joystick */
.pad .pad-stick { width: 190px; height: 190px; }
.pad .pad-stick i { width: 80px; height: 80px; margin: -40px 0 0 -40px; transition: transform 0.05s; }

/* Priorities : glisser-déposer */
.po-slot { position: relative; min-height: 70px; }
.po-slot em { font-style: normal; font-size: 14px; color: rgba(255, 255, 255, 0.35); font-weight: 600; }
.po-slot.hover { border-color: #fff; background: #1d2440; }
.po-pool { position: sticky; bottom: 0; padding: 12px 6px; border-radius: 18px; background: rgba(8, 10, 24, 0.9); border: 2px dashed rgba(255, 255, 255, 0.2); }
.po-chip { display: inline-flex; align-items: center; padding: 12px 16px; border-radius: 14px; background: #f3ead6; color: #1b1640; border: 3px solid #000; box-shadow: 4px 4px 0 #000; font: 900 18px 'Inter', sans-serif; touch-action: none; user-select: none; cursor: grab; }
.po-chip.in { box-shadow: 3px 3px 0 #000; padding: 8px 12px; font-size: 17px; }
.po-chip.lifted { opacity: 0.25; }
.po-ghost { position: fixed; left: 0; top: 0; z-index: 99; pointer-events: none; box-shadow: 8px 8px 0 #000; }

.on-ok { width: 100%; margin-top: 18px; }
.on-bar.locked { filter: saturate(0.6); }

/* Petit Bac : liste des catégories à cocher, règle */
.pbs-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.pbs-list .pbs-c { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 14px; text-align: left; font-size: 17px; }
.pbs-list .pbs-c i { flex: none; width: 26px; height: 26px; border-radius: 7px; border: 3px solid #000; background: #0b0f1d; display: grid; place-items: center; font-style: normal; }
.pbs-list .pbs-c.on { background: #2a2210; color: #fff; box-shadow: inset 0 0 0 2px #f5b83d, 3px 3px 0 #000; }
.pbs-list .pbs-c.on i { background: #f5b83d; }
.pbs-list .pbs-c.on i::after { content: '✓'; color: #000; font-weight: 900; font-size: 17px; }
.pbs-go { position: sticky; bottom: 10px; width: 100%; }
.pb-rule { text-align: center; font-size: 14px; font-weight: 800; color: #f5b83d; margin: -2px 0 10px; }

/* Bataille spatiale : les vaisseaux dessinés sur la grille */
.nv-grid { position: relative; }
.fl-layer { position: absolute; inset: 6px; pointer-events: none; }
.fl-ship { position: absolute; display: grid; place-items: center; padding: 1px; }
.fl-ship img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(2px 2px 0 #000); }
.fl-ship.v { container-type: size; }
.fl-ship.v img { position: absolute; left: 50%; top: 50%; width: 100cqh; height: 100cqw; max-width: none; transform: translate(-50%, -50%) rotate(90deg); }
.nv-grid.place .nv-c.ship { background: rgba(95, 212, 255, 0.25); }
.nv-grid.place .nv-c.ship.sel { background: rgba(245, 184, 61, 0.55); }

/* Priorities : tout tient sur l'écran, sans défiler */
.po-slots { gap: 7px; margin-bottom: 10px; }
.po-slot { min-height: 54px; padding: 5px 10px 5px 6px; gap: 10px; font-size: 16px; }
.po-slot b { width: 40px; height: 40px; font-size: 21px; border-radius: 11px; }
.po-slot em { font-size: 12px; }
.po-pool { position: static; gap: 7px; padding: 8px 4px; margin-bottom: 10px; min-height: 0; }
.po-chip { padding: 8px 11px; font-size: 15px; border-radius: 11px; box-shadow: 3px 3px 0 #000; }
.po-chip.in { padding: 6px 10px; font-size: 15px; }
.po-ok { margin-top: 0; }

/* Bataille spatiale : tirs et vaisseaux détruits */
.nvp-tip { font-size: 13px; color: var(--text-2); align-self: center; }
.nv-c.just-hit { animation: nv-pboom 0.7s ease; }
@keyframes nv-pboom { 0% { transform: scale(1.8); background: #fff; box-shadow: 0 0 30px #ffd23a; } 40% { background: #ff8a1e; } }
.nv-c.just-miss { animation: nv-pmiss 0.6s ease; }
@keyframes nv-pmiss { 0% { box-shadow: 0 0 0 0 rgba(160, 190, 255, 0.9); } 100% { box-shadow: 0 0 0 14px rgba(160, 190, 255, 0); } }
.fl-ship { overflow: visible; }
.nv-grid:not(.place) .fl-ship img { filter: grayscale(0.6) brightness(0.55) drop-shadow(2px 2px 0 #000); }
.nv-grid:not(.place) .fl-ship::after { content: '🔥'; position: absolute; left: 50%; top: 50%; transform: translate(-50%, -60%); font-size: 18px; animation: nv-fire 0.5s ease-in-out infinite alternate; }
@keyframes nv-fire { to { transform: translate(-50%, -75%) scale(1.2); } }

/* Petit Bac : catégories au hasard / ajoutées à la main */
.pbs-tools { display: flex; justify-content: center; margin-bottom: 10px; }
.pbs-add { display: flex; gap: 8px; margin-bottom: 12px; }
.pbs-add .input { flex: 1; min-width: 0; }

/* Make it Meme : un seul texte, bouton de l'admin */
.mm-reroll { display: block; margin: -4px auto 12px; }
.g-text textarea.input { resize: none; font: inherit; }

/* outils de l'admin (écran des jeux) : minuteur et roue */
.pk-tools { margin-top: 12px; }
.pk-tools .btn { flex: 1; }
.pk-timer.on { background: #ffd23a; color: #000; font-variant-numeric: tabular-nums; }
.tm-sheet h3 { margin: 0 0 12px; }
.tm-sheet h4 { margin: 16px 0 8px; font-size: 14px; font-weight: 600; }
.tm-run { display: flex; flex-direction: column; gap: 10px; align-items: stretch; }
.tm-left { font: 800 44px/1 'Orbitron', 'Inter', sans-serif; text-align: center; font-variant-numeric: tabular-nums; }
.tm-presets { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.chip-btn { padding: 10px 4px; border-radius: 10px; border: 2px solid rgba(255,255,255,.15); background: rgba(255,255,255,.06); color: inherit; font: 700 15px 'Inter', sans-serif; }
.chip-btn.on { background: var(--me, #ffd23a); color: #000; border-color: #000; }
.tm-custom { display: flex; gap: 10px; margin: 14px 0; }
.tm-custom label { flex: 1; display: flex; align-items: center; gap: 6px; }
.tm-custom .input { text-align: center; font-size: 22px; font-weight: 800; }
.tm-go { width: 100%; }

/* J'ai déjà / Je n'ai jamais */
.jm-q { padding: 18px 18px 20px; border-radius: 22px; background: #1a1230; border: 4px solid #000; box-shadow: 6px 6px 0 #000; text-align: center; }
.jm-q small { display: block; font: 800 15px 'Inter', sans-serif; color: #ff9ab8; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 8px; }
.jm-q b { font: 900 23px/1.25 'Inter', sans-serif; color: #fff; }
.jm-btns { display: grid; grid-template-columns: 1fr; gap: 14px; margin: 18px 0; }
.jm-b { min-height: 22vh; border-radius: 22px; border: 4px solid #000; box-shadow: 5px 5px 0 #000; color: #fff; font: 900 22px/1.2 'Inter', sans-serif; text-shadow: 2px 2px 0 rgba(0,0,0,.5); transition: transform .15s, opacity .2s; }
.jm-b.yes { background: #ff4d7d; } .jm-b.no { background: #2fa3e8; }
.jm-b.on { box-shadow: 0 0 0 5px #fff, 5px 5px 0 #000; transform: scale(1.03); }
.jm-b.off { opacity: .35; }
.jm-bet { padding: 14px; border-radius: 18px; background: rgba(255,255,255,.06); border: 2px solid rgba(255,255,255,.12); }
.jm-bt { font: 800 16px 'Inter', sans-serif; margin-bottom: 10px; text-align: center; }
.jm-bt small { font-weight: 500; opacity: .7; }
.jm-nums { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.jm-n { width: 46px; height: 46px; border-radius: 12px; border: 3px solid #000; background: #2a2440; color: #fff; font: 900 20px 'Inter', sans-serif; box-shadow: 3px 3px 0 #000; }
.jm-n.on { background: #ffd23a; color: #000; }
.jm-ok { text-align: center; margin-top: 12px; font-size: 14px; }

/* Qui est-ce ? */
.qe-me { display: flex; align-items: center; gap: 14px; padding: 10px; border-radius: 18px; background: #1a1230; border: 4px solid #000; box-shadow: 5px 5px 0 #000; }
.qe-me img { width: 74px; height: 74px; border-radius: 14px; object-fit: cover; object-position: 50% 22%; border: 3px solid #000; }
.qe-me small { display: block; font: 700 13px 'Inter', sans-serif; color: #ffd23a; text-transform: uppercase; letter-spacing: 1px; }
.qe-me b { font: 900 22px/1.15 'Inter', sans-serif; }
.qe-myst .qe-me img { width: 120px; height: 120px; }
.qe-myst .qe-me b { font-size: 28px; }
.qe-hint { text-align: center; margin: 12px 0 8px; opacity: .8; font-size: 14px; }
.qe-ans { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 10px 0; }
.qe-a { min-height: 80px; border-radius: 18px; border: 4px solid #000; box-shadow: 4px 4px 0 #000; font: 900 30px 'Inter', sans-serif; color: #fff; text-shadow: 2px 2px 0 rgba(0,0,0,.4); }
.qe-a.oui { background: #22c55e; } .qe-a.non { background: #ef4444; }
.qe-a.nsp { grid-column: 1 / -1; min-height: 46px; font-size: 17px; background: #5b5675; }
.qe-a:active { transform: scale(.96); }
.qe-myst .qe-ans { margin-top: 16px; } .qe-myst .qe-a { min-height: 130px; font-size: 40px; }
.qe-myst .qe-grid { display: none; }
.qe-cnt { text-align: center; font-size: 14px; margin: 8px 0; opacity: .9; }
.qe-l.oui { color: #22c55e; } .qe-l.non { color: #ef4444; }
.qe-st { margin: 10px 0 4px; padding: 10px 12px; border-radius: 14px; text-align: center; background: rgba(255,255,255,.07); font: 700 16px/1.3 'Inter', sans-serif; }
.qe-st.go { background: #ffd23a; color: #000; } .qe-st.bad { background: #5a1520; }
.qe-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: 8px 0 12px; padding-bottom: 70px; }
.qe-c { position: relative; padding: 0; border: 3px solid #000; border-radius: 12px; overflow: hidden; background: #222; aspect-ratio: 3 / 4; transition: transform .2s, filter .2s, opacity .2s; }
.qe-c img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 22%; display: block; }
.qe-c span { position: absolute; left: 0; right: 0; bottom: 0; padding: 10px 2px 3px; font: 700 10.5px/1.1 'Inter', sans-serif; color: #fff; background: linear-gradient(transparent, rgba(0,0,0,.85)); }
.qe-c.off { filter: grayscale(1) brightness(.35); transform: scale(.9); }
.qe-c.wrong::after, .qe-c.off .qe-x::after { content: '✕'; position: absolute; inset: 0; display: grid; place-items: center; font: 900 46px 'Inter', sans-serif; color: #ff3b47; text-shadow: 2px 2px 0 #000; }
.qe-c.wrong { filter: grayscale(1) brightness(.5); }
.qe-c.mine { outline: 4px solid #ffd23a; outline-offset: -4px; }
.qe-proposing .qe-c:not(.off):not(.wrong) { animation: qe-wiggle .6s ease-in-out infinite alternate; border-color: #ffd23a; }
@keyframes qe-wiggle { from { transform: rotate(-2deg); } to { transform: rotate(2deg); } }
.qe-bar { position: sticky; bottom: 10px; margin-right: 64px; z-index: 3; }
.qe-bar .btn { width: 100%; }
.qe-bar .btn-row .btn { width: auto; flex: 1; }

/* Spaceship knockout : visée */
.ko-tip { text-align: center; font: 800 17px/1.3 'Inter', sans-serif; margin: 6px 0 12px; }
.ko-wrap { display: flex; justify-content: center; }
.ko-cv { touch-action: none; border-radius: 50%; background: radial-gradient(circle, #121628 60%, transparent 71%); }
.ko-st { text-align: center; margin-top: 12px; font-size: 14px; }

.pk-fam { display: block; font: 800 11px 'Inter', sans-serif; text-transform: uppercase; letter-spacing: 1.5px; color: var(--me, #ffd23a); margin-bottom: 3px; }

/* réglages du jeu par l'admin pendant « Prêt » */
.rd-pre { margin: 6px 0 14px; text-align: left; }
.rd-pre-h { font-weight: 800; margin-bottom: 8px; }
button.chip { border: 0; background: none; padding: 0; font: inherit; color: inherit; }
button.chip.on span { background: var(--accent); border-color: transparent; color: #fff; }

.gv-fam { grid-column: 1 / -1; margin: 10px 2px 0; font: 800 13px 'Inter', sans-serif; letter-spacing: .08em; text-transform: uppercase; color: #f5b83d; }
.gv-fam:first-child { margin-top: 0; }
body.drawing #gear-fab, body.drawing #chat-fab { display: none !important; }

/* choix du jeu (admin) : titres de famille dans la roue */
.pk-item.pk-fam-row { font-size: 12px; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-2, #9aa3b8); }

/* Petit Bac (admin) : réponses en double, bouton « = » pour lier deux réponses */
.fl-cell { display: flex; gap: 6px; align-items: stretch; }
.fl-cell .fl-a { flex: 1; min-width: 0; }
.fl-a.dup { box-shadow: inset 0 0 0 3px #f5b83d; }
.fl-eq { flex: none; width: 44px; border-radius: 12px; border: 2px solid #000; background: #1d2440; color: #fff; font: 900 22px 'Inter', sans-serif; }
.fl-eq.on { background: #f5b83d; color: #000; }
.fl-eq.arm { background: #fff; color: #000; outline: 3px solid #f5b83d; }

/* télé de poche : l'écran télé dans le téléphone de l'admin (soirée sans télé). En portrait, l'écran est tourné
   d'un quart de tour pour remplir le téléphone : on le pose en paysage au milieu de la table. */
#pocket { position: fixed; inset: 0; z-index: 400; background: #000; }
#pocket .pk-frame { position: absolute; inset: 0; overflow: hidden; }
#pocket iframe { position: absolute; top: 0; left: 0; border: 0; width: 100%; height: 100%; background: #000; }
@media (orientation: portrait) {
  #pocket iframe { width: 100dvh; height: 100vw; transform-origin: top left; transform: rotate(90deg) translateY(-100%); }
}
#pocket .pk-bar { position: absolute; z-index: 2; display: flex; gap: 8px; right: calc(env(safe-area-inset-right) + 10px); bottom: calc(env(safe-area-inset-bottom) + 10px); }
@media (orientation: portrait) { #pocket .pk-bar { flex-direction: column; } }
#pocket .pk-b, #pocket-fab { width: 46px; height: 46px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, 0.25); background: rgba(10, 12, 24, 0.75); color: #fff; font-size: 20px; display: grid; place-items: center; padding: 0; }
#pocket .pk-b { opacity: 0.55; }
#pocket-fab { position: fixed; z-index: 120; left: calc(env(safe-area-inset-left) + 12px); bottom: calc(env(safe-area-inset-bottom) + 12px); box-shadow: 0 6px 18px rgba(0, 0, 0, 0.5); }
body.pocket-open { overflow: hidden; }
