/* COPA RUSH — Auth gate (visitante no lobby) */

.cr-lobby-header__row {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
}

.cr-lobby-header__brand {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  min-width: 0;
}

.cr-lobby-header__guest-tag {
  margin: 0;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: rgba(148, 163, 184, 0.95);
  text-transform: uppercase;
}

.cr-lobby-header__actions {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  flex-shrink: 0;
}

.cr-auth-header-btn {
  appearance: none;
  border: none;
  cursor: pointer;
  font-weight: 800;
  font-size: 11px;
  line-height: 1;
  padding: 0 12px;
  height: 28px;
  border-radius: 999px;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.cr-auth-header-btn:active {
  transform: scale(0.97);
}

.cr-auth-header-btn--ghost {
  background: rgba(255, 255, 255, 0.06);
  color: #e2e8f0;
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.cr-auth-header-btn--primary {
  background: linear-gradient(135deg, #00ff88 0%, #00d4aa 100%);
  color: #052e16;
  box-shadow: 0 0 18px rgba(0, 255, 136, 0.35);
}

/* Faixa convite — mesmo visual do welcome strip (painel branco) */
.cr-guest-strip {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 20px;
  border-bottom: 1px solid #f3f4f6;
  background: #ffffff;
}

.cr-guest-strip__icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #059669;
  font-size: 22px;
  flex-shrink: 0;
}

.cr-guest-strip__body {
  flex: 1;
  min-width: 0;
}

.cr-guest-strip__title {
  margin: 0 0 6px;
  font-size: 15px;
  font-weight: 800;
  color: #111827;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.cr-guest-strip__text {
  margin: 0 0 10px;
  font-size: 11px;
  line-height: 1.45;
  color: #6b7280;
  font-weight: 500;
}

.cr-guest-strip__cta {
  appearance: none;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  color: #052e16;
  background: linear-gradient(135deg, #00ff88, #00d4aa);
  box-shadow: 0 4px 14px rgba(0, 255, 136, 0.22);
}

/* Modal auth */
.cr-auth-modal {
  position: fixed;
  inset: 0;
  z-index: 99990;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.cr-auth-modal.is-open {
  pointer-events: auto;
  opacity: 1;
  visibility: visible;
}

.cr-auth-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 23, 0.88);
  backdrop-filter: blur(10px);
}

.cr-auth-modal__panel {
  position: relative;
  width: 100%;
  max-width: 400px;
  max-height: min(92vh, 720px);
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(0, 255, 136, 0.18);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
  background: #070b12;
}

/* Estádio / Copa no fundo (fosco para legibilidade do formulário) */
.cr-auth-modal__pitch {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    url('https://nexo-uploads-beta.s3.amazonaws.com/wp-content/uploads/2023/11/29123436/2014-06-12T203819Z_1_MT1ACI12366667_RTRMADP_3_SOCCER-WORLDCUP-BRA-HRV-min_binary_292113-scaled.jpg') center center / cover no-repeat,
    linear-gradient(180deg, #0a1628 0%, #050810 100%);
  opacity: 1;
}

.cr-auth-modal__pitch::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(165deg, rgba(7, 11, 18, 0.88) 0%, rgba(5, 8, 16, 0.92) 50%, rgba(3, 6, 12, 0.96) 100%),
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 28px,
      rgba(255, 255, 255, 0.012) 28px,
      rgba(255, 255, 255, 0.012) 29px
    );
}

.cr-auth-modal__content {
  position: relative;
  z-index: 2;
  padding: 22px 20px 18px;
  max-height: min(92vh, 720px);
  overflow-y: auto;
}

.cr-auth-modal__close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 3;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 0, 0.35);
  color: #94a3b8;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cr-auth-modal__brand {
  text-align: center;
  margin-bottom: 18px;
}

.cr-auth-modal__logo {
  width: 52px;
  height: 52px;
  margin: 0 auto 10px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  color: #00ff88;
  background: rgba(0, 255, 136, 0.1);
  border: 1px solid rgba(0, 255, 136, 0.22);
}

.cr-auth-modal__title {
  margin: 0 0 6px;
  font-size: 20px;
  font-weight: 800;
  color: #f8fafc;
  letter-spacing: -0.03em;
}

.cr-auth-modal__sub {
  margin: 0;
  font-size: 12px;
  color: #94a3b8;
  line-height: 1.4;
}

.cr-auth-modal__tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 4px;
  margin-bottom: 14px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.cr-auth-tab {
  appearance: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  border-radius: 9px;
  font-size: 13px;
  font-weight: 700;
  color: #94a3b8;
  background: transparent;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
  box-shadow: none;
}

.cr-auth-tab.is-active {
  color: #052e16;
  background: linear-gradient(135deg, #00ff88, #00d4aa);
  box-shadow: none;
}

.cr-auth-modal__alert {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 12px;
  margin-bottom: 12px;
  border-radius: 10px;
  font-size: 12px;
  line-height: 1.45;
  color: #fecaca;
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.28);
}

.cr-auth-modal__alert i {
  flex-shrink: 0;
  margin-top: 1px;
}

.cr-auth-modal__forms {
  position: relative;
}

.cr-auth-form {
  display: none;
  flex-direction: column;
  gap: 12px;
  margin: 0;
  padding: 0;
}

.cr-auth-form.is-active {
  display: flex;
}

.cr-auth-form[hidden] {
  display: none !important;
}

/* Bloqueia efeitos premium-interface (ripple laranja / progress-button) */
.cr-auth-modal .ripple-effect,
.cr-auth-modal .progress-spinner {
  display: none !important;
}

.cr-auth-modal .cr-auth-submit.progress-button,
.cr-auth-modal .cr-auth-submit.click-ripple,
.cr-auth-modal .cr-auth-submit.hover-lift {
  overflow: visible;
  transform: none;
}

.cr-auth-field__label {
  display: block;
  margin-bottom: 5px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #94a3b8;
}

.cr-auth-field__wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  height: 48px;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.cr-auth-field__wrap:focus-within {
  border-color: rgba(0, 255, 136, 0.55);
  box-shadow: 0 0 0 3px rgba(0, 255, 136, 0.14);
}

.cr-auth-field__wrap i {
  color: #9ca3af;
  font-size: 16px;
  flex-shrink: 0;
}

.cr-auth-field__wrap input {
  flex: 1;
  min-width: 0;
  border: none;
  outline: none;
  background: transparent;
  color: #374151;
  /* iOS Safari dá zoom se font-size < 16px ao focar */
  font-size: 16px;
  font-weight: 500;
  -webkit-text-size-adjust: 100%;
}

.cr-auth-field__wrap input::placeholder {
  color: #9ca3af;
}

.cr-auth-toggle-pass {
  appearance: none;
  border: none;
  background: transparent;
  color: #9ca3af;
  cursor: pointer;
  padding: 4px;
  flex-shrink: 0;
}

.cr-auth-submit {
  appearance: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  height: 46px;
  margin-top: 4px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 800;
  color: #052e16;
  background: linear-gradient(135deg, #00ff88 0%, #00d4aa 100%);
  box-shadow: 0 8px 24px rgba(0, 255, 136, 0.22);
}

.cr-auth-modal__foot {
  margin: 14px 0 0;
  text-align: center;
  font-size: 10px;
  color: #64748b;
}

body.cr-guest-mode .cr-game-card__btn,
body.cr-guest-mode [data-auth-gate] {
  cursor: pointer;
}

body.cr-guest-mode .cr-bottom-bar__item:not([data-auth-free]) {
  opacity: 0.92;
}

body.cr-auth-open {
  overflow: hidden;
}

@media (max-width: 380px) {
  .cr-auth-header-btn {
    padding: 0 9px;
    font-size: 10px;
  }
}
