/* AERN auth pages — same visual language as landing */

.auth-page {
  min-height: 100vh;
  color: var(--text, #eef1f6);
  background: #0c0a08;
}

.aern-page-bg,
.aern-page-vignette {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.aern-page-bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  opacity: 0;
  transition: opacity 1.2s ease;
}

#aernPageBgDay { opacity: 1; }
html.aern-night #aernPageBgDay { opacity: 0; }
html.aern-night #aernPageBgNight { opacity: 1; }

.aern-page-bg-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(12, 10, 8, 0.2), rgba(12, 10, 8, 0.88) 70%, #0c0a08);
}

.aern-page-vignette {
  background: linear-gradient(90deg, rgba(12, 10, 8, 0.45), transparent 14%, transparent 86%, rgba(12, 10, 8, 0.45));
}

.auth-header {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-gold-strong, rgba(232, 200, 104, 0.35));
  background: rgba(8, 6, 5, 0.92);
  backdrop-filter: blur(12px);
}

.auth-header .brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--gold-light, #f0d890);
}

.auth-header-nav {
  display: flex;
  gap: 10px;
  align-items: center;
}

.auth-main {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  min-height: calc(100vh - 80px);
  padding: 32px 16px 48px;
}

.auth-card {
  width: min(100%, 460px);
  padding: 28px 24px 24px;
}

.auth-card h1 {
  margin: 0 0 8px;
  font-family: var(--font-display, "Alumni Sans", sans-serif);
  color: #fff;
  font-size: 1.85rem;
}

.auth-lead {
  margin: 0 0 20px;
  color: var(--text-dim, rgba(255, 255, 255, 0.76));
  font-size: 1.05rem;
  line-height: 1.55;
}

.auth-form {
  display: grid;
  gap: 14px;
}

.auth-field {
  display: grid;
  gap: 6px;
}

.auth-field[hidden],
.auth-error[hidden],
.auth-lead[hidden] {
  display: none !important;
}

.auth-field span {
  font-size: 0.88rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-dim, rgba(255, 255, 255, 0.76));
}

.auth-field input {
  width: 100%;
  box-sizing: border-box;
  padding: 13px 15px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(8, 6, 5, 0.75);
  color: #fff;
  font: inherit;
  font-size: 1rem;
}

.auth-field input:focus {
  outline: none;
  border-color: rgba(240, 184, 80, 0.55);
  box-shadow: 0 0 0 2px rgba(232, 200, 104, 0.12);
}

.auth-error {
  margin: 0;
  color: #ff8f8f;
  font-size: 0.98rem;
}

.auth-switch {
  margin: 18px 0 0;
  color: var(--text-dim, rgba(255, 255, 255, 0.76));
  font-size: 1rem;
}

.auth-switch a {
  color: #f0d890;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 0.18em;
  text-decoration-color: rgba(240, 216, 144, 0.45);
}

.auth-switch a:hover {
  color: #fff;
  text-decoration-color: rgba(255, 255, 255, 0.55);
}

.profile-list {
  margin: 0 0 18px;
  display: grid;
  gap: 12px;
}

.profile-list > div {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 10px;
  align-items: start;
}

.profile-list dt {
  margin: 0;
  color: var(--text-dim, rgba(255, 255, 255, 0.76));
  font-size: 0.88rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.profile-list dd {
  margin: 0;
  word-break: break-word;
}

.profile-list .mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.82rem;
}

.profile-security {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid rgba(232, 200, 104, 0.2);
}

.profile-security-title {
  margin: 0 0 8px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.1rem;
  color: var(--gold-light, #f0d890);
  font-weight: 600;
}

#passwordResetMsg.ok {
  color: #8fd48f;
}

@media (max-width: 520px) {
  .profile-list > div {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}

/* Cloudflare Turnstile */
.aern-turnstile-slot,
.cf-turnstile {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 70px;
  min-width: 300px;
  margin: 0.75rem auto 0.5rem;
  overflow: visible !important;
}

.aern-turnstile-slot iframe,
.cf-turnstile iframe {
  display: block !important;
  visibility: visible !important;
  max-width: 100%;
}

.aern-turnstile-slot.aern-turnstile-missing::after {
  content: "Капча не загрузилась. Обновите страницу (Ctrl+F5) или отключите блокировщик рекламы.";
  display: block;
  color: #f0b850;
  font-size: 0.82rem;
  text-align: center;
  line-height: 1.45;
  padding: 8px;
}
