/* Anti-cheat shield (blackout on blur / visibility hidden) */
#anti-cheat-shield {
  position: fixed;
  inset: 0;
  z-index: 9998;
  background: #000;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.05s linear;
}

#anti-cheat-shield.is-active {
  opacity: 1;
}

/* CheatModal overlay */
.cheat-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgba(5, 10, 18, 0.94);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.cheat-modal-overlay.is-visible {
  opacity: 1;
}

.cheat-modal-card {
  position: relative;
  width: 100%;
  max-width: 26rem;
  padding: 1.75rem;
  border-radius: 1.5rem;
  border-top: 4px solid #ff4b4b;
  text-align: center;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.45);
  transform: scale(0.96) translateY(8px);
  transition: transform 0.2s ease;
}

.cheat-modal-overlay.is-visible .cheat-modal-card {
  transform: scale(1) translateY(0);
}

.cheat-modal-card--warning {
  border-top-color: #ffc800;
}

.cheat-modal-card--violation {
  border-top-color: #ff4b4b;
  animation: cheat-shake 0.3s ease;
}

.cheat-modal-card--ejected {
  border-top-color: #ff4b4b;
  max-width: 28rem;
}

.cheat-modal-card--violation::after {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  border: 2px solid rgba(255, 75, 75, 0.35);
  animation: cheat-pulse 1.5s ease infinite;
  pointer-events: none;
}

.cheat-modal-badge {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: rgba(255, 75, 75, 0.2);
  color: #ff8a8a;
  border: 1px solid rgba(255, 75, 75, 0.35);
}

.cheat-modal-icon {
  width: 5rem;
  height: 5rem;
  margin: 0 auto 1.25rem;
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid rgba(255, 75, 75, 0.3);
  background: rgba(255, 75, 75, 0.12);
}

.cheat-modal-icon i {
  font-size: 2.25rem;
  color: #ff4b4b;
}

.cheat-modal-card--warning .cheat-modal-icon {
  border-color: rgba(255, 200, 0, 0.35);
  background: rgba(255, 200, 0, 0.12);
}

.cheat-modal-card--warning .cheat-modal-icon i {
  color: #ffc800;
}

.cheat-modal-title {
  font-weight: 900;
  font-size: 1.25rem;
  line-height: 1.25;
  color: #fff;
  margin-bottom: 0.5rem;
}

.cheat-modal-subtitle {
  font-size: 0.875rem;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.55);
  font-style: italic;
  margin-bottom: 1rem;
}

.cheat-modal-detail {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.4);
  margin-bottom: 1.25rem;
}

.cheat-modal-actions {
  display: flex;
  gap: 0.75rem;
  width: 100%;
}

.cheat-modal-actions .btn-duo-red,
.cheat-modal-actions .btn-duo-outline {
  flex: 1;
}

.cheat-modal-actions button:focus,
.cheat-modal-actions button:focus-visible {
  outline: none;
  box-shadow: none;
}

/* Room shame banner */
.room-shame-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 0.85rem 1.25rem;
  background: linear-gradient(90deg, rgba(255, 75, 75, 0.92), rgba(200, 40, 40, 0.85));
  border-bottom: 2px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  transform: translateY(-100%);
  opacity: 0;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.room-shame-banner.is-visible {
  transform: translateY(0);
  opacity: 1;
}

.room-shame-banner i {
  font-size: 1.35rem;
  color: #fff;
  flex-shrink: 0;
}

.room-shame-banner-text {
  font-weight: 800;
  font-size: 0.9rem;
  color: #fff;
  text-align: center;
}

.room-shame-banner-text strong {
  font-weight: 900;
}

.room-shame-banner-sub {
  display: block;
  font-weight: 600;
  font-size: 0.78rem;
  font-style: italic;
  opacity: 0.85;
  margin-top: 0.15rem;
}

.participant-badge.is-kicked {
  opacity: 0.55;
  background: rgba(255, 75, 75, 0.15) !important;
  border-color: rgba(255, 75, 75, 0.35) !important;
}

.participant-badge.is-kicked .participant-score {
  text-decoration: line-through;
}

.participant-kick-btn {
  margin-left: auto;
  padding: 0.25rem 0.5rem;
  font-size: 0.7rem;
  font-weight: 800;
  border-radius: 0.5rem;
  border: 1px solid rgba(255, 75, 75, 0.4);
  background: rgba(255, 75, 75, 0.15);
  color: #ff8a8a;
  cursor: pointer;
  flex-shrink: 0;
}

.participant-kick-btn:hover {
  background: rgba(255, 75, 75, 0.3);
}

/* Kicked page */
.room-kicked-page {
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
}

.room-kicked-card {
  max-width: 28rem;
  width: 100%;
  padding: 2rem;
  border-radius: 1.5rem;
  border: 2px solid rgba(255, 75, 75, 0.4);
  text-align: center;
  background: rgba(26, 47, 53, 0.85);
}

.room-kicked-icon {
  width: 5rem;
  height: 5rem;
  margin: 0 auto 1.25rem;
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 75, 75, 0.15);
  border: 2px solid rgba(255, 75, 75, 0.3);
}

.room-kicked-icon i {
  font-size: 2.5rem;
  color: #ff4b4b;
}

.room-kicked-facts {
  margin: 1.25rem 0;
  padding: 1rem;
  border-radius: 1rem;
  background: rgba(0, 0, 0, 0.25);
  text-align: left;
  font-size: 0.85rem;
}

.room-kicked-facts dt {
  font-weight: 800;
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.room-kicked-facts dd {
  margin: 0 0 0.75rem;
  font-weight: 700;
  color: #fff;
}

.room-kicked-facts dd:last-child {
  margin-bottom: 0;
}

@keyframes cheat-shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-6px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(4px); }
}

@keyframes cheat-pulse {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 0.8; }
}
