/* ═════════════════════════════════════════════════════════════════
   BeauOuPas TV — Styles globaux

   Conçu pour être affiché sur écran 16:9 (TV, projecteur, Chromecast)
   en plein écran. Tout est dimensionné en pourcentage / vw / vh pour
   s'adapter à toutes les tailles d'écran.

   Couleurs principales :
   - Fond : #1A1A2E (sombre chaleureux)
   - Accent : #C2754C (rose BeauOuPas)
   - Texte clair : #3D2817
   - Texte secondaire : #BBBBBB
   - Texte tertiaire (hints) : #8A6F4A
   ═════════════════════════════════════════════════════════════════ */

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  width: 100%;
  height: 100%;
  background: #1A1A2E;
  color: #F4EFE6;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
  overflow: hidden;
  user-select: none;
  -webkit-user-select: none;
}

/* ─────────────────────────────────────────────────────────────────
   Page d'accueil TV (saisie du code)
   ───────────────────────────────────────────────────────────────── */

.tv-home {
  width: 100%;
  height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
  padding: 40px;
}

.tv-home-logo {
  font-size: 72px;
  font-weight: 700;
  color: #C2754C;
  letter-spacing: -2px;
  margin-bottom: 8px;
}

.tv-home-tagline {
  font-size: 22px;
  color: #BBBBBB;
  margin-bottom: 32px;
}

.tv-home-input-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.tv-home-label {
  font-size: 18px;
  color: #BBBBBB;
  text-transform: uppercase;
  letter-spacing: 2px;
}

.tv-home-input {
  background: rgba(255, 255, 255, 0.08);
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 24px 32px;
  font-size: 48px;
  font-weight: 600;
  color: #F4EFE6;
  letter-spacing: 8px;
  text-align: center;
  font-family: 'Courier New', monospace;
  width: 360px;
  outline: none;
  transition: border-color 0.2s, background 0.2s;
}

.tv-home-input:focus {
  border-color: #C2754C;
  background: rgba(194,117,76, 0.1);
}

.tv-home-button {
  background: #C2754C;
  color: white;
  border: none;
  border-radius: 12px;
  padding: 18px 48px;
  font-size: 20px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.15s, background 0.15s;
}

.tv-home-button:hover {
  background: #d11878;
  transform: scale(1.02);
}

.tv-home-button:active {
  transform: scale(0.98);
}

.tv-home-button:disabled {
  background: #6B5234;
  cursor: not-allowed;
}

.tv-home-error {
  color: #B5482F;
  font-size: 16px;
  min-height: 24px;
  text-align: center;
  max-width: 500px;
}

/* ─────────────────────────────────────────────────────────────────
   Containeur principal des écrans TV
   ───────────────────────────────────────────────────────────────── */

.tv-container {
  width: 100vw;
  height: 100vh;
  position: relative;
  overflow: hidden;
}

.tv-screen {
  position: absolute;
  inset: 0;
  display: none;
  flex-direction: column;
  animation: screenFadeIn 0.4s ease-out;
}

.tv-screen.active {
  display: flex;
}

@keyframes screenFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ─────────────────────────────────────────────────────────────────
   Écran 1 : Salle d'attente (lobby)
   ───────────────────────────────────────────────────────────────── */

.tv-lobby {
  align-items: center;
  justify-content: center;
  gap: 4vh;
  padding: 4vh 4vw;
}

.tv-lobby-title {
  font-size: 5vw;
  font-weight: 600;
  color: white;
  text-align: center;
  margin-bottom: 1vh;
}

.tv-lobby-subtitle {
  font-size: 1.6vw;
  color: #8A6F4A;
  text-align: center;
  margin-bottom: 3vh;
}

.tv-lobby-card {
  background: rgba(255, 255, 255, 0.06);
  border-radius: 24px;
  padding: 4vh 4vw;
  display: flex;
  align-items: center;
  gap: 4vw;
}

.tv-lobby-qr {
  width: 18vh;
  height: 18vh;
  background: white;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1vh;
}

.tv-lobby-qr canvas,
.tv-lobby-qr img,
.tv-lobby-qr svg {
  width: 100%;
  height: 100%;
}

.tv-lobby-code-block {
  display: flex;
  flex-direction: column;
  gap: 0.8vh;
}

.tv-lobby-code-label {
  font-size: 1.2vw;
  color: #BBBBBB;
  text-transform: uppercase;
  letter-spacing: 4px;
}

.tv-lobby-code {
  font-size: 8vw;
  font-weight: 600;
  color: #C2754C;
  letter-spacing: 1vw;
  font-family: 'Courier New', monospace;
  line-height: 1;
}

.tv-lobby-code-hint {
  font-size: 1vw;
  color: #8A6F4A;
}

.tv-lobby-participants {
  font-size: 2.2vw;
  color: white;
  font-weight: 500;
  margin-top: 2vh;
}

.tv-lobby-waiting {
  font-size: 1.2vw;
  color: #8A6F4A;
  margin-top: 1vh;
}

/* ─────────────────────────────────────────────────────────────────
   Écran 2 : Vote en cours
   ───────────────────────────────────────────────────────────────── */

.tv-vote {
  padding: 2vh 3vw;
  gap: 2vh;
}

.tv-vote-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-shrink: 0;
}

.tv-vote-progress {
  font-size: 1.6vw;
  color: #BBBBBB;
}

.tv-vote-countdown {
  background: rgba(194,117,76, 0.18);
  border-radius: 100px;
  padding: 1vh 2vw;
  font-size: 2.2vw;
  color: #C2754C;
  font-weight: 600;
  min-width: 8vw;
  text-align: center;
}

.tv-vote-countdown.urgent {
  background: rgba(181,72,47, 0.25);
  color: #B5482F;
  animation: pulseUrgent 0.8s ease-in-out infinite;
}

@keyframes pulseUrgent {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

.tv-vote-title {
  font-size: 3vw;
  font-weight: 500;
  color: white;
  text-align: center;
  line-height: 1.2;
  flex-shrink: 0;
}

.tv-vote-description {
  font-size: 1.6vw;
  color: #BBBBBB;
  text-align: center;
  line-height: 1.4;
  flex-shrink: 0;
}

.tv-vote-photos {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2vw;
  min-height: 0;
}

.tv-vote-photos.duel {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.tv-vote-photos.poll {
  flex-direction: column;
  gap: 1.5vh;
}

.tv-vote-photo {
  width: 100%;
  height: 100%;
  border-radius: 16px;
  background: #2A2A3E;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}

.tv-vote-photo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.tv-vote-photo-label {
  position: absolute;
  top: 2vh;
  left: 2vh;
  background: rgba(0, 0, 0, 0.7);
  color: white;
  font-size: 2vw;
  font-weight: 700;
  padding: 0.6vh 1.6vh;
  border-radius: 8px;
}

.tv-vote-poll-options {
  display: flex;
  flex-direction: column;
  gap: 1.2vh;
  width: 60%;
  max-width: 800px;
}

.tv-vote-poll-option {
  background: rgba(255, 255, 255, 0.08);
  border: 2px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  padding: 2vh 2vw;
  font-size: 2vw;
  color: white;
  text-align: left;
}

.tv-vote-counter {
  display: flex;
  flex-direction: column;
  gap: 0.8vh;
  padding: 1.2vh 2vw;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 12px;
  flex-shrink: 0;
}

.tv-vote-counter-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.tv-vote-counter-text {
  font-size: 1.6vw;
  color: white;
  font-weight: 500;
}

.tv-vote-counter-percent {
  font-size: 1.4vw;
  color: #8A6F4A;
}

.tv-vote-counter-bar {
  background: rgba(255, 255, 255, 0.1);
  height: 0.8vh;
  border-radius: 100px;
  overflow: hidden;
}

.tv-vote-counter-fill {
  background: #C2754C;
  height: 100%;
  border-radius: 100px;
  transition: width 0.5s ease-out;
}

.tv-vote-counter-fill.complete {
  background: #4A7A52;
}

/* ─────────────────────────────────────────────────────────────────
   Écran 3 : Transition entre 2 projets
   ───────────────────────────────────────────────────────────────── */

.tv-transition {
  align-items: center;
  justify-content: center;
  gap: 2vh;
}

.tv-transition-icon {
  font-size: 12vw;
  transform: scale(0);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.tv-transition-icon.show {
  transform: scale(1);
}

.tv-transition-title {
  font-size: 3vw;
  font-weight: 600;
  color: white;
  opacity: 0;
  transition: opacity 0.5s ease-out;
}

.tv-transition-title.show {
  opacity: 1;
}

.tv-transition-subtitle {
  font-size: 1.8vw;
  color: #8A6F4A;
  opacity: 0;
  transition: opacity 0.5s ease-out;
}

.tv-transition-subtitle.show {
  opacity: 1;
}

/* ═════════════════════════════════════════════════════════════════
   Écran 4 : RÉSULTATS (big reveal)
   ───────────────────────────────────────────────────────────────────
   Boucle infinie : pour chaque projet, 2 phases de 20s chacune :
     - Phase 1 (raw)  : votes par option + galerie polaroids
     - Phase 2 (stats): répartition par genre + tranche d'âge
   ═════════════════════════════════════════════════════════════════ */

.tv-reveal {
  padding: 2vh 3vw;
  gap: 1vh;
  position: relative;
}

/* En-tête : titre du projet + position dans la série */
.tv-reveal-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6vh;
  flex-shrink: 0;
}

.tv-reveal-progress {
  font-size: 1.2vw;
  color: #8A6F4A;
  text-transform: uppercase;
  letter-spacing: 3px;
}

.tv-reveal-title {
  font-size: 2.6vw;
  font-weight: 600;
  color: white;
  text-align: center;
  line-height: 1.2;
}

.tv-reveal-description {
  font-size: 1.2vw;
  color: #BBBBBB;
  text-align: center;
}

/* Phase tag (RÉSULTATS / STATISTIQUES) */
.tv-reveal-phase-tag {
  display: inline-block;
  background: rgba(194,117,76, 0.18);
  color: #C2754C;
  font-size: 1vw;
  font-weight: 600;
  padding: 0.4vh 1.5vw;
  border-radius: 100px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

/* Zone principale : contenu + galerie polaroids en arrière-plan */
.tv-reveal-stage {
  flex: 1;
  position: relative;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ─── Galerie de polaroids qui défilent ─────────────────────────── */
/* Couche absolute en arrière-plan, derrière les graphiques. */
.tv-reveal-polaroids {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}

.tv-polaroid {
  position: absolute;
  background: white;
  padding: 1vh 1vh 3vh 1vh;
  box-shadow: 0 1vh 3vh rgba(0, 0, 0, 0.5);
  width: 22vh;
  /* Sera ajusté dynamiquement en JS pour position + rotation. */
  /* Animation de glissement de droite à gauche : */
  animation: polaroidDrift linear forwards;
  opacity: 0;
}

.tv-polaroid.visible {
  opacity: 1;
}

.tv-polaroid img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  background: #2A2A3E;
  display: block;
}

.tv-polaroid-caption {
  font-family: 'Caveat', 'Brush Script MT', cursive;
  font-size: 2.6vh;
  color: #D4C7B5;
  text-align: center;
  margin-top: 0.5vh;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Animation : glissement de droite vers la gauche, rotation conservée */
@keyframes polaroidDrift {
  0%   { transform: translateX(110vw)  rotate(var(--polaroid-rot, 0deg)); opacity: 0; }
  5%   { opacity: 1; }
  95%  { opacity: 1; }
  100% { transform: translateX(-30vw)  rotate(var(--polaroid-rot, 0deg)); opacity: 0; }
}

/* ─── Contenu principal au-dessus des polaroids ─────────────────── */
.tv-reveal-content {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2vh;
  animation: revealFadeIn 0.5s ease-out;
}

@keyframes revealFadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ─── PHASE 1 : Photo + options de vote avec compteurs ──────────── */

.tv-reveal-photos {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2vw;
  width: 100%;
  max-height: 45vh;
}

.tv-reveal-photos.duel {
  gap: 1vw;
}

.tv-reveal-photo {
  position: relative;
  height: 45vh;
  max-width: 40vw;
  background: #2A2A3E;
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1vh 4vh rgba(0, 0, 0, 0.4);
}

.tv-reveal-photo.is-winner {
  outline: 0.5vh solid #C2754C;
  outline-offset: 0;
}

.tv-reveal-photo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* Bandeau de score sous la photo (duel) */
.tv-reveal-photo-score {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0) 100%);
  padding: 4vh 1vw 1vh 1vw;
  text-align: center;
  font-size: 2.4vw;
  font-weight: 700;
  color: white;
}

.tv-reveal-photo-score-letter {
  display: inline-block;
  background: rgba(194,117,76, 0.85);
  color: white;
  font-size: 1.6vw;
  width: 3vw;
  height: 3vw;
  line-height: 3vw;
  text-align: center;
  border-radius: 50%;
  margin-right: 1vw;
}

/* Options de vote (photo_vote : like/meh/dislike) */
.tv-reveal-options {
  display: flex;
  gap: 3vw;
  align-items: stretch;
  justify-content: center;
  flex-wrap: wrap;
  width: 100%;
}

.tv-reveal-option {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6vh;
  background: rgba(255, 255, 255, 0.05);
  border: 2px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 1.5vh 2.5vw;
  min-width: 11vw;
  transition: transform 0.3s, border-color 0.3s;
}

.tv-reveal-option.is-winner {
  border-color: #C2754C;
  background: rgba(194,117,76, 0.12);
  transform: scale(1.06);
}

.tv-reveal-option-emoji {
  font-size: 4vw;
  line-height: 1;
}

.tv-reveal-option-count {
  font-size: 2.6vw;
  font-weight: 700;
  color: white;
  line-height: 1;
  font-family: 'Courier New', monospace;
}

.tv-reveal-option-label {
  font-size: 1vw;
  color: #BBBBBB;
  text-transform: uppercase;
  letter-spacing: 2px;
}

/* Options de poll : barres horizontales */
.tv-reveal-poll-list {
  display: flex;
  flex-direction: column;
  gap: 1.2vh;
  width: 70%;
  max-width: 1100px;
}

.tv-reveal-poll-row {
  background: rgba(255, 255, 255, 0.05);
  border: 2px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 1.2vh 1.5vw;
  display: flex;
  flex-direction: column;
  gap: 0.6vh;
  transition: border-color 0.3s, background 0.3s;
}

.tv-reveal-poll-row.is-winner {
  border-color: #C2754C;
  background: rgba(194,117,76, 0.12);
}

.tv-reveal-poll-row-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1vw;
}

.tv-reveal-poll-row-text {
  font-size: 1.5vw;
  color: white;
  font-weight: 500;
}

.tv-reveal-poll-row-count {
  font-size: 1.5vw;
  color: #C2754C;
  font-weight: 700;
  font-family: 'Courier New', monospace;
  flex-shrink: 0;
}

.tv-reveal-poll-row-bar {
  background: rgba(255, 255, 255, 0.08);
  height: 0.8vh;
  border-radius: 100px;
  overflow: hidden;
}

.tv-reveal-poll-row-fill {
  background: linear-gradient(90deg, #C2754C 0%, #FF4081 100%);
  height: 100%;
  border-radius: 100px;
  transition: width 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Compteur total de votes (footer) */
.tv-reveal-total {
  font-size: 1.3vw;
  color: #BBBBBB;
  text-align: center;
}

.tv-reveal-total strong {
  color: white;
  font-family: 'Courier New', monospace;
}

/* État vide (pas de votes) */
.tv-reveal-empty {
  font-size: 1.6vw;
  color: #8A6F4A;
  font-style: italic;
}

/* ═════════════════════════════════════════════════════════════════
   PHASE 2 : Stats par genre / par âge — VERSION REFONDUE
   Couleurs vives + nombre + pourcentage à l'intérieur des barres
   Légende COMMUNE en haut avec compteurs totaux
   ═════════════════════════════════════════════════════════════════ */

/* Légende globale au-dessus des graphes (COMMUNE genre + âge) */
.tv-reveal-stats-legend {
  display: flex;
  gap: 2vw;
  justify-content: center;
  flex-wrap: wrap;
  width: 90%;
  max-width: 1600px;
  margin-bottom: 0.5vh;
}

.tv-reveal-stats-legend-item {
  display: flex;
  align-items: center;
  gap: 0.6vw;
  font-size: 1.3vw;
  color: white;
  background: rgba(255, 255, 255, 0.05);
  padding: 0.8vh 1.5vw;
  border-radius: 100px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.tv-reveal-stats-legend-item .legend-emoji {
  font-size: 1.4vw;
}

.tv-reveal-stats-legend-item .legend-label {
  color: #DDDDDD;
}

.tv-reveal-stats-legend-item .legend-count {
  color: white;
  font-weight: 700;
  font-family: 'Courier New', monospace;
}

.tv-reveal-stats-legend-item .legend-percent {
  color: #8A6F4A;
  font-size: 1.1vw;
}

.tv-reveal-stats-legend-dot {
  width: 1.1vw;
  height: 1.1vw;
  border-radius: 50%;
  flex-shrink: 0;
}

/* Couleurs des points de légende — couleurs vives */
.tv-reveal-stats-legend-dot.val-like     { background: #4A7A52; }
.tv-reveal-stats-legend-dot.val-meh      { background: #FFC107; }
.tv-reveal-stats-legend-dot.val-dislike  { background: #B5482F; }
.tv-reveal-stats-legend-dot.val-A        { background: #C2754C; }
.tv-reveal-stats-legend-dot.val-B        { background: #00BCD4; }
.tv-reveal-stats-legend-dot.val-poll-1   { background: #4A7A52; }
.tv-reveal-stats-legend-dot.val-poll-2   { background: #FFC107; }
.tv-reveal-stats-legend-dot.val-poll-3   { background: #C2754C; }
.tv-reveal-stats-legend-dot.val-poll-4   { background: #00BCD4; }
.tv-reveal-stats-legend-dot.val-poll-5   { background: #9C27B0; }

/* Grille des 2 blocs (genre / âge) */
.tv-reveal-stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2vw;
  width: 90%;
  max-width: 1600px;
}

.tv-reveal-stats-block {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 16px;
  padding: 2vh 2vw;
  display: flex;
  flex-direction: column;
  gap: 1.5vh;
}

.tv-reveal-stats-block-title {
  font-size: 1.3vw;
  color: #8A6F4A;
  text-transform: uppercase;
  letter-spacing: 3px;
  text-align: center;
  margin-bottom: 0.5vh;
}

.tv-reveal-stats-row {
  display: flex;
  flex-direction: column;
  gap: 0.5vh;
}

.tv-reveal-stats-row-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 1.3vw;
}

.tv-reveal-stats-row-label {
  color: white;
  font-weight: 500;
}

.tv-reveal-stats-row-count {
  color: #BBBBBB;
  font-family: 'Courier New', monospace;
}

/* Barre empilée — hauteur augmentée pour pouvoir afficher du contenu dedans */
.tv-reveal-stats-bar {
  display: flex;
  height: 5vh;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 100px;
  overflow: hidden;
}

/* Chaque segment : flexbox pour centrer le contenu (nombre + %) */
.tv-reveal-stats-bar-segment {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1;
  transition: width 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

/* Contenu du segment : 2 lignes (nombre gros + % petit) */
.tv-reveal-stats-bar-segment .seg-count {
  font-size: 1.3vw;
  font-weight: 700;
  font-family: 'Courier New', monospace;
}

.tv-reveal-stats-bar-segment .seg-percent {
  font-size: 0.85vw;
  opacity: 0.85;
  font-weight: 500;
}

/* Couleurs vives + couleur de texte foncée pour contraster sur les fonds clairs */
.tv-reveal-stats-bar-segment.val-like     { background: #4A7A52; color: #0a3d12; }
.tv-reveal-stats-bar-segment.val-meh      { background: #FFC107; color: #5a4500; }
.tv-reveal-stats-bar-segment.val-dislike  { background: #B5482F; color: #F4EFE6; }
.tv-reveal-stats-bar-segment.val-A        { background: #C2754C; color: #4a0c2c; }
.tv-reveal-stats-bar-segment.val-B        { background: #00BCD4; color: #00343b; }
.tv-reveal-stats-bar-segment.val-poll-1   { background: #4A7A52; color: #0a3d12; }
.tv-reveal-stats-bar-segment.val-poll-2   { background: #FFC107; color: #5a4500; }
.tv-reveal-stats-bar-segment.val-poll-3   { background: #C2754C; color: #4a0c2c; }
.tv-reveal-stats-bar-segment.val-poll-4   { background: #00BCD4; color: #00343b; }
.tv-reveal-stats-bar-segment.val-poll-5   { background: #9C27B0; color: #F4EFE6; }

/* ─── Bouton "Arrêter" en bas à droite ──────────────────────────── */
.tv-reveal-stop-btn {
  position: absolute;
  bottom: 2vh;
  right: 2vw;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #BBBBBB;
  padding: 1vh 2vw;
  border-radius: 100px;
  font-size: 1vw;
  cursor: pointer;
  z-index: 10;
  transition: background 0.2s, color 0.2s;
}

.tv-reveal-stop-btn:hover {
  background: rgba(181,72,47, 0.25);
  color: #B5482F;
}

/* ─────────────────────────────────────────────────────────────────
   États d'erreur / chargement
   ───────────────────────────────────────────────────────────────── */

.tv-loading {
  align-items: center;
  justify-content: center;
}

.tv-loading-spinner {
  width: 8vh;
  height: 8vh;
  border: 4px solid rgba(255, 255, 255, 0.1);
  border-top-color: #C2754C;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.tv-error {
  align-items: center;
  justify-content: center;
  gap: 2vh;
  padding: 4vw;
}

.tv-error-icon {
  font-size: 8vw;
}

.tv-error-title {
  font-size: 3vw;
  font-weight: 600;
  color: white;
}

.tv-error-message {
  font-size: 1.6vw;
  color: #BBBBBB;
  text-align: center;
  max-width: 60%;
}

/* ─────────────────────────────────────────────────────────────────
   Barre de pause (overlay quand l'animateur a mis en pause)
   ───────────────────────────────────────────────────────────────── */

.tv-pause-overlay {
  position: absolute;
  inset: 0;
  background: rgba(26, 26, 46, 0.92);
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2vh;
  z-index: 1000;
  backdrop-filter: blur(8px);
}

.tv-pause-overlay.active {
  display: flex;
  animation: screenFadeIn 0.3s ease-out;
}

.tv-pause-icon {
  font-size: 12vw;
}

.tv-pause-title {
  font-size: 3vw;
  font-weight: 600;
  color: #C2754C;
}

.tv-pause-subtitle {
  font-size: 1.6vw;
  color: #BBBBBB;
}
