/* ─────────────────────────────────────────────────────────────────────────────
   PokéStock Live — Modal / overlay styles
   Generic modal scaffold used by login, signup, refund, cookie consent,
   shipping info, etc. Plus auth dialog helpers.
   ───────────────────────────────────────────────────────────────────────────── */

/* ─── Modal backdrop + sheet ─────────────────────────────────────────────── */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(4, 7, 13, .85);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 950;
  backdrop-filter: blur(4px);
  overflow-y: auto;
}
.modal .sheet {
  background: var(--surf);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 28px;
  width: 100%;
  max-width: 380px;
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.modal h3 {
  font-family: "Anton";
  letter-spacing: .5px;
  margin: 0 0 4px;
  font-size: 26px;
}
.modal p   { color: var(--mut);  font-size: 14px; margin: 0 0 8px; }
.modal .err { color: var(--live); font-size: 13px; min-height: 18px; }

/* ─── Auth dialog helpers ────────────────────────────────────────────────── */
.auth-divider {
  text-align: center;
  color: var(--mut);
  font-size: 12px;
  margin: 8px 0;
}
.auth-toggle {
  background: none;
  border: none;
  color: var(--cool);
  cursor: pointer;
  font-size: 13px;
  font-weight: bold;
}

/* ─── Mobile (≤ 640px) ───────────────────────────────────────────────────── */
@media (max-width: 640px) {
  .modal { padding: 0 !important; align-items: flex-start !important; }
  .modal .sheet {
    padding: 20px 16px;
    gap: 10px;
    max-width: 100% !important;
    max-height: 100vh !important;
    min-height: 100vh;
    border-radius: 0 !important;
    border: none !important;
  }
}
