/* ============================
   RESET
============================ */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, sans-serif;
}

/* ============================
   HTML / BODY
============================ */
html, body {
  height: 100%;
}

body {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;

  background-color: #000;

  -webkit-user-drag: none;
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
}

/* ============================
   BACKGROUND — img tag
   Sem URL em CSS. Sem ambiguidade de caminho.
============================ */
.login-bg {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  z-index: 0;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
}

.login-overlay {
  position: fixed;
  inset: 0;
  background: radial-gradient(ellipse at center, rgba(0,0,0,0.35) 0%, rgba(0,0,0,0.65) 60%, rgba(0,0,0,0.85) 100%);
  z-index: 1;
  pointer-events: none;
}

/* ============================
   LOGIN CONTAINER
============================ */
.login-container {
  position: relative;
  z-index: 2;

  width: 100%;
  max-width: 400px;
  padding: 36px 32px;
  margin: 0 auto;

  border-radius: 20px;

  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  background: rgba(20, 20, 25, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.75),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);

  text-align: center;

  animation: login-enter 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ============================
   LOGO
============================ */
.login-logo {
  width: 78px;
  margin-bottom: 18px;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.55));
  animation: loginLogo 6s ease-in-out infinite;
  transform-origin: center;
}

@keyframes loginLogo {
  0%   { transform: rotate(0deg); }
  92%  { transform: rotate(0deg); }
  94%  { transform: rotate(-6deg); }
  96%  { transform: rotate(6deg); }
  98%  { transform: rotate(-4deg); }
  100% { transform: rotate(0deg); }
}

/* ============================
   TÍTULO
============================ */
.login-container h2 {
  font-size: 1.55rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: rgba(255, 255, 255, 0.92);
  margin-bottom: 28px;
}

/* ============================
   BOTÃO GOOGLE
============================ */
.btn-google {
  position: relative;
  overflow: hidden;
  width: 100%;
  padding: 16px 18px;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 14px;
  border: none;
  background: linear-gradient(180deg, #ffffff, #f3f3f3);
  color: #333;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  cursor: pointer;
  box-shadow:
    0 12px 30px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition:
    transform 0.18s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.18s ease,
    filter 0.18s ease;
}

.btn-google::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,0.7) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform 0.6s ease;
  pointer-events: none;
}

.btn-google:hover {
  transform: translateY(-3px);
  filter: brightness(1.04);
  box-shadow:
    0 22px 50px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

.btn-google:hover::before { transform: translateX(120%); }

.btn-google:active {
  transform: translateY(0) scale(0.97);
  box-shadow:
    0 10px 20px rgba(0, 0, 0, 0.35),
    inset 0 3px 6px rgba(0, 0, 0, 0.15);
}

.google-icon {
  width: 20px;
  height: 20px;
}

/* ============================
   BOTÃO VOLTAR
============================ */
.btn-voltar {
  position: relative;
  overflow: hidden;
  width: 100%;
  margin-bottom: 14px;
  padding: 14px 18px;
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: linear-gradient(180deg, rgba(40,40,50,0.85), rgba(22,22,28,0.85));
  color: rgba(255, 255, 255, 0.88);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  box-shadow:
    0 12px 30px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  transition:
    transform 0.18s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.18s ease,
    filter 0.18s ease,
    background 0.18s ease;
}

.btn-voltar::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,0.25) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform 0.6s ease;
  pointer-events: none;
}

.btn-voltar:hover {
  transform: translateY(-3px);
  filter: brightness(1.08);
  box-shadow:
    0 22px 50px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.18);
  background: linear-gradient(180deg, rgba(55,55,70,0.9), rgba(28,28,36,0.9));
}

.btn-voltar:hover::before { transform: translateX(120%); }

.btn-voltar:active {
  transform: translateY(0) scale(0.97);
  box-shadow:
    0 10px 20px rgba(0, 0, 0, 0.35),
    inset 0 3px 6px rgba(0, 0, 0, 0.35);
}

/* ============================
   ANIMAÇÃO
============================ */
@keyframes login-enter {
  0%   { opacity: 0; transform: translateY(30px) scale(0.96); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

/* ============================
   FOOTER
============================ */
.login-footer {
  margin-top: 24px;
  font-size: 0.9rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.45);
  text-align: center;
  letter-spacing: 0.04em;
}

.login-footer strong {
  font-weight: 700;
  color: rgba(255, 255, 255, 0.7);
}

.vess-link {
  text-decoration: none;
  color: inherit;
}

.vess-link:hover { opacity: 0.85; }

/* ============================
   POPUP
============================ */
.popup {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(12px);
  background: linear-gradient(135deg, #d900ff, #8a00cc);
  color: #fff;
  padding: 14px 26px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.3px;
  box-shadow:
    0 12px 32px rgba(179, 0, 255, 0.35),
    0 4px 12px rgba(0, 0, 0, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.25s ease,
    transform 0.25s cubic-bezier(0.22, 1, 0.36, 1);
  z-index: 9999;
}

.popup.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.popup::before {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: inherit;
  background: radial-gradient(circle, rgba(179,0,255,0.45), transparent 70%);
  filter: blur(8px);
  opacity: 0.8;
  z-index: -1;
}

.popup::after {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: inherit;
  background: linear-gradient(to bottom, rgba(255,255,255,0.25), transparent 60%);
  pointer-events: none;
}

/* ============================
   MOBILE (≤ 768px)
   Estilos aqui e NÃO no android.css —
   garante que carregam independente do host.
============================ */
@media (max-width: 768px) {
  body {
    justify-content: center;
    align-items: center;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 20px 16px;
  }

  .login-overlay {
    background: linear-gradient(to bottom, rgba(0,0,0,0.35) 0%, rgba(0,0,0,0.72) 65%, #000 100%);
  }

  .login-container {
    max-width: 420px;
    width: 100%;
    margin: auto;
    padding: 28px 22px;
    border-radius: 16px;
    box-shadow:
      0 20px 60px rgba(0, 0, 0, 0.6),
      inset 0 1px 0 rgba(255, 255, 255, 0.05);
  }

  .login-logo {
    width: 64px;
    margin-bottom: 14px;
  }

  .login-container h2 {
    font-size: 1.3rem;
    margin-bottom: 20px;
  }

  .btn-google {
    padding: 14px 16px;
    font-size: 0.9rem;
    border-radius: 12px;
  }

  .btn-voltar {
    padding: 12px 14px;
    font-size: 0.85rem;
    border-radius: 12px;
    margin-bottom: 12px;
  }

  .google-icon {
    width: 18px;
    height: 18px;
  }

  .login-footer {
    margin-top: 18px;
    font-size: 0.8rem;
  }
}

/* Tablet (600px – 768px) */
@media (min-width: 600px) and (max-width: 768px) {
  .login-container {
    max-width: 460px;
    padding: 26px 22px;
    border-radius: 18px;
  }

  .login-logo {
    width: 70px;
    margin-bottom: 16px;
  }

  .login-container h2 {
    font-size: 1.4rem;
    margin-bottom: 22px;
  }

  .btn-google {
    font-size: 0.95rem;
    padding: 15px 18px;
  }

  .btn-voltar {
    font-size: 0.9rem;
    padding: 14px 16px;
  }

  .login-footer {
    font-size: 0.85rem;
  }
}
