/* =============================================================================
   auth.css – Authentifizierung & Login
   Login-Layout, Icon-Overrides, Passwort-Toggle, Login-Button
   Später: Profil-Seite, Nutzerverwaltung
   ============================================================================= */

/* --- Login-Seite Layout ---------------------------------------------------- */
.login-scene {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px var(--spacing-xl);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    transition: background-image 0.6s ease;
    min-height: calc(100vh - var(--footer-height));
}

.login-card {
    /* Nutzt .card aus styles.css als Basis (Glassmorphism) */
    width: 100%;
    max-width: 400px;
    padding: 36px var(--spacing-3xl);
    color: var(--color-foreground-inverse);
}

/* --- Branding -------------------------------------------------------------- */
.login-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 28px;
}

.login-brand-icon {
    font-size: 2.4rem;
    color: var(--color-foreground-inverse);
    opacity: 0.92;
    flex-shrink: 0;
    width: 2.4rem;
    height: 2.4rem;
}

.login-brand-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--color-foreground-inverse);
    line-height: 1.2;
}

.login-brand-sub {
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

/* --- Formular-Struktur ----------------------------------------------------- */
.login-form {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

/* Login-Felder nutzen Floating Label aus formular.css */
.login-field {
    position: relative;
}

/* Floating Label Overrides für Login (helle Farben auf dunklem Glassmorphism) */
.login-field label {
    color: rgba(255, 255, 255, 0.7);        /* Hellere Farbe für dunklen Hintergrund */
}

.login-field input:focus + label,
.login-field input:not(:placeholder-shown) + label {
    color: var(--color-foreground-inverse);  /* Weiß wenn aktiv */
    background: var(--color-glass);          /* Dunkler Glas-Hintergrund */
}

/* --- Eingabefeld-Container ------------------------------------------------- */
.login-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.login-input-icon {
    position: absolute;
    left: 12px;
    color: rgba(255, 255, 255, 0.5);       /* Hellere Icon-Farbe für dunklen Hintergrund */
    font-size: 1rem;
    pointer-events: none;
    z-index: 1;
}

/* --- Input-Overrides für Login-Kontext (Glassmorphism, Icon-Padding) ------- */
/* Basis-Style kommt aus formular.css; hier nur was abweicht               */
.login-input-wrap input {
    padding-left: 38px;                         /* Platz für Icon links */
    padding-right: 44px;                        /* Platz für Toggle-Button rechts */
    background: var(--color-glass);             /* Glassmorphism statt transparent */
    color: var(--color-foreground-inverse);     /* Heller Text auf dunklem Hintergrund */
    border-bottom-color: rgba(255, 255, 255, 0.2);  /* Hellerer Border */
    transition: border-bottom-color 0.2s, background 0.2s;
}

.login-input-wrap input::placeholder {
    color: rgba(255, 255, 255, 0.3);           /* Placeholder nur bei Focus sichtbar */
}

.login-input-wrap input:focus {
    background: var(--color-glass-focus);
    border-bottom-color: var(--color-foreground-inverse);
}

/* --- Passwort-Toggle ------------------------------------------------------- */
.login-pw-toggle {
    position: absolute;
    right: 10px;
    background: none;
    border: none;
    color: var(--color-text-muted);
    cursor: pointer;
    font-size: 1rem;
    padding: 2px var(--spacing-xs);
    transition: color 0.2s;
    line-height: 1;
}

.login-pw-toggle:hover {
    color: var(--color-foreground-inverse);
}

/* --- Login-Button ---------------------------------------------------------- */
.login-btn {
    /* Nutzt .btn aus styles.css als Basis */
    margin-top: var(--spacing-sm);
    width: 100%;
    padding: 11px;
    background: var(--color-glass-hover);
    border-color: rgba(255, 255, 255, 0.35);
    border-radius: var(--radius-input);
    color: var(--color-foreground-inverse);
    font-size: 0.95rem;
    font-weight: 600;
}

.login-btn:hover {
    background: rgba(255, 255, 255, 0.32);
    border-color: rgba(255, 255, 255, 0.6);
}

.login-btn:active {
    background: rgba(255, 255, 255, 0.38);
}
