/* --------------------------------------------------------------------------
   5. Login-Bildschirm
   -------------------------------------------------------------------------- */
@keyframes auth-fade-in {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

.auth-screen {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--wood-950);
}

/* Kein Foto mehr - dieselbe ruhige, technische Rasterfläche wie im
   eingeloggten Bereich (siehe .app in css/base/textures.css), nur ohne
   Sidebar drumherum. */
.auth-screen__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(circle at 50% 0%, rgba(53, 181, 189, 0.07) 0%, transparent 50%),
    repeating-linear-gradient(0deg, rgba(130, 170, 190, 0.035) 0, rgba(130, 170, 190, 0.035) 1px, transparent 1px, transparent 48px),
    repeating-linear-gradient(90deg, rgba(130, 170, 190, 0.035) 0, rgba(130, 170, 190, 0.035) 1px, transparent 1px, transparent 48px),
    linear-gradient(180deg, var(--wood-950) 0%, var(--wood-900) 100%);
}

.auth-screen__vignette {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: radial-gradient(ellipse 1300px 950px at 50% 32%, transparent 45%, rgba(2, 5, 8, 0.5) 100%);
  pointer-events: none;
}

.auth-gate {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 22px;
  animation: auth-fade-in 0.7s ease both;
}

.auth-gate__sign-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

/* Icon-Badge statt Hänge-Schild-Foto - derselbe Puls-/EKG-Strich wie in der
   Sidebar (siehe .sidebar__brand-icon in css/layout/shell.css), hier nur
   größer für die Login-Seite. */
.auth-gate__sign-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background: #f4f7f8;
  border: 2px solid var(--brass-bright);
  color: var(--brass-bright);
  box-shadow: var(--shadow-modal), 0 0 0 8px var(--brass-soft);
}

.auth-gate__sign-icon svg {
  width: 40px;
  height: 40px;
}

.auth-gate__sign-name {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--wood-text);
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
}

/* Schlichte, hochwertige Anmelde-Karte: dunkles Leder mit Messing-Kante,
   damit Login und Anwendung optisch aus einem Guss wirken. */
.auth-card {
  width: 420px;
  background: var(--leather-800);
  border: 1px solid var(--leather-edge);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-modal);
  padding: 40px 40px 36px;
  position: relative;
  animation: auth-fade-in 0.75s ease 0.05s both;
}

.auth-card__brand {
  text-align: center;
  margin-bottom: 20px;
}

.auth-card__eyebrow {
  display: block;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--brass-bright);
}

.auth-card__heading {
  display: block;
  margin-top: 5px;
  font-family: var(--font-brand);
  font-size: 30px;
  letter-spacing: 0.03em;
  color: var(--wood-text);
}

.auth-form {
  display: none;
  flex-direction: column;
  gap: 4px;
}

.auth-form--active {
  display: flex;
}

.auth-submit {
  margin-top: 16px;
  width: 100%;
}

.auth-hint {
  margin-top: 18px;
  font-size: 12px;
  color: var(--status-danger-bright);
  background: var(--status-danger-soft);
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(217, 83, 79, 0.3);
}

.auth-hint code {
  font-family: monospace;
  font-size: 11px;
}

.auth-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 16px;
  align-items: center;
}

.auth-link {
  background: none;
  border: none;
  padding: 0;
  font-size: 12px;
  color: var(--wood-text-muted);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
  font-style: italic;
  transition: color 0.15s ease;
}

.auth-link:hover {
  color: var(--brass-bright);
}

/* Fußzeile ("Datenschutz"/"Informationen") liegt hier direkt auf dem
   Seitenhintergrund statt auf der Leder-Karte wie die übrigen
   .auth-link-Vorkommen - ein leichter Schlagschatten hält den Text auch auf
   der dunklen Fläche lesbar. */
.auth-screen .page-footer .auth-link {
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.65);
}

.auth-status {
  display: none;
  flex-direction: column;
  gap: 16px;
  text-align: center;
}

.auth-status--active {
  display: flex;
}

.auth-status__text {
  font-size: 13.5px;
  color: var(--wood-text-muted);
  line-height: 1.65;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 10px 0;
  color: var(--wood-text-soft);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--leather-edge);
}

/* Eingabefelder mit Icon (nur im Login-Bereich, keine Änderung an den
   geteilten Basis-Klassen .field-label/.field-input, die auch anderswo
   in der App verwendet werden) */
#auth-screen .field-icon-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

#auth-screen .field-icon {
  position: absolute;
  left: 12px;
  width: 15px;
  height: 15px;
  color: var(--wood-text-soft);
  pointer-events: none;
  transition: color 0.15s ease;
}

#auth-screen .field-input--icon {
  padding-left: 36px;
}

#auth-screen .field-icon-wrap:focus-within .field-icon {
  color: var(--brass-bright);
}

#auth-screen .field-checkbox-row {
  margin-top: 14px;
  cursor: pointer;
  user-select: none;
}

#auth-screen .field-checkbox-row span {
  font-style: italic;
}

/* Auf niedrigeren Bildschirmen (kleine Laptop-Fenster) etwas kompakter, damit
   Schild + Pergament-Karte + Footer nicht durch die feste Bildschirmhöhe
   abgeschnitten werden. */
@media (max-height: 800px) {
  .auth-gate {
    gap: 14px;
  }

  .auth-gate__sign-icon {
    width: 66px;
    height: 66px;
  }

  .auth-gate__sign-icon svg {
    width: 32px;
    height: 32px;
  }

  .auth-card {
    padding: 32px 32px 26px;
  }

  .auth-card__brand {
    margin-bottom: 12px;
  }
}

@media (max-height: 700px) {
  .auth-gate__sign-icon {
    width: 52px;
    height: 52px;
  }

  .auth-gate__sign-icon svg {
    width: 26px;
    height: 26px;
  }

  .auth-card {
    padding: 24px 28px 20px;
  }

  .auth-card__brand {
    margin-bottom: 6px;
  }

  #auth-screen .field-label {
    margin: 8px 0 4px;
  }
}

