/* tg-gate: оверлей на плеере до подтверждения подписки на Telegram.
   Разметку см. в README.md "Встраивание в film.ejs". Плеер рендерится сервером как обычно —
   оверлей только накладывается сверху и снимается классом tg-gate--unlocked. */

.tg-gate { position: relative; }

.tg-gate__lock {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  text-align: center;
  padding: 0 24px;
  background: radial-gradient(circle at 50% 38%, rgba(60, 56, 50, 0.92), rgba(10, 10, 9, 0.98));
  backdrop-filter: blur(6px);
  border-radius: inherit;
  z-index: 5;
}

.tg-gate--unlocked .tg-gate__lock,
.tg-gate--unlocked .tg-gate__code {
  display: none;
}

.tg-gate__icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
}

.tg-gate__title {
  color: #f5f2ec;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.35;
  max-width: 420px;
}

.tg-gate__hint {
  color: #a9a59e;
  font-size: 13px;
  max-width: 360px;
  line-height: 1.5;
}

.tg-gate__btn {
  border: none;
  border-radius: 10px;
  padding: 12px 22px;
  background: #D97757;
  color: #1c1b19;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}
.tg-gate__btn:hover { background: #e4855f; }

.tg-gate__code {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-top: 4px;
}
.tg-gate--waiting .tg-gate__code { display: flex; }
.tg-gate--waiting .tg-gate__hint { display: none; }

.tg-gate__code-input {
  width: 140px;
  text-align: center;
  letter-spacing: 4px;
  font-size: 18px;
  font-weight: 700;
  border-radius: 8px;
  border: 1px solid #3a372f;
  background: #0d0c0b;
  color: #f5f2ec;
  padding: 9px 10px;
}

.tg-gate__error {
  color: #c0605a;
  font-size: 12.5px;
  display: none;
}
.tg-gate--error .tg-gate__error { display: block; }

@media (max-width: 480px) {
  .tg-gate__title { font-size: 14.5px; }
  .tg-gate__btn { padding: 10px 16px; font-size: 13px; }
}
