/* Reset & Grundlayout */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html,
body {
    height: 100%;
}

body {
    font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
        sans-serif;
    color: #f5f5f5;
    background-color: #050711;
}

/* Hintergrundbereich */
.login-page {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 16px;

    background: url("../img/Login_Background.jpg") center center / cover no-repeat fixed;
}

/* Leichte Abdunkelung darüber */
.login-overlay {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 10% 0, rgba(32, 132, 252, 0.25), transparent 55%),
                linear-gradient(135deg, rgba(5, 7, 17, 0.80), rgba(5, 7, 17, 0.94));
    backdrop-filter: blur(3px);
    z-index: 0;
}

/* Container & Card */
.login-container {
    position: relative;
    z-index: 1;
    max-width: 460px;
    width: 100%;
    margin: 0 auto;
}

.login-card {
    background: rgba(10, 12, 24, 0.94);
    border-radius: 22px;
    border: 1px solid rgba(120, 144, 255, 0.4);
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.65);
    padding: 24px 24px 20px;
}

/* Header + Logo */
.login-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}

.login-title h1 {
    font-size: 1.6rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    color: #ffffff;
    margin-bottom: 6px;
}

.login-title p {
    font-size: 0.88rem;
    color: rgba(230, 236, 255, 0.85);
    line-height: 1.45;
}

/* Logo oben rechts rund, klein & scharf */
.login-logo-wrapper {
    flex-shrink: 0;
    display: flex;
    align-items: flex-start;
    justify-content: flex-end;
}

.login-logo {
    height: 40px;
    width: auto;
    max-width: 100%;
    border-radius: 999px;
    object-fit: contain;
    border: 1px solid rgba(120, 144, 255, 0.6);
    box-shadow: 0 0 6px rgba(32, 132, 252, 0.35);
}

/* Formular */
.login-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 0.85rem;
    color: rgba(220, 230, 255, 0.92);
}

/* Inputs */
.form-group input {
    border-radius: 10px;
    border: 1px solid rgba(120, 144, 255, 0.55);
    background: rgba(8, 10, 22, 0.9);
    padding: 9px 11px;
    font-size: 0.9rem;
    color: #f5f7ff;
    outline: none;
    transition: border-color 0.18s ease, box-shadow 0.18s ease,
                background-color 0.18s ease;
    font-family: "Inter", system-ui, sans-serif;
}

.form-group input::placeholder {
    color: rgba(160, 190, 255, 0.7);
    font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Monaco,
        Consolas, "Liberation Mono", "Courier New", monospace;
}

/* Fokus */
.form-group input:focus {
    border-color: #4c8dff;
    box-shadow: 0 0 0 1px rgba(76, 141, 255, 0.5);
    background-color: rgba(10, 13, 30, 0.97);
}

/* Aktionen / Buttons */
.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 10px;
    flex-wrap: wrap;
}

/* Basis-Button */
.btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 1 1 auto;
    min-width: 120px;
    padding: 9px 18px;
    font-size: 0.9rem;
    border-radius: 999px;
    border: 1px solid transparent;
    text-decoration: none;
    cursor: pointer;
    white-space: nowrap;
    overflow: hidden;

    transition:
        transform 0.18s ease-out,
        box-shadow 0.18s ease-out,
        background-color 0.18s ease-out,
        color 0.18s ease-out,
        border-color 0.18s ease-out;
}

/* Wasser-Fill-Button (Registrieren) */
.btn-primary {
    background-color: transparent;
    border-color: #2f7bff;
    color: #d0e4ff;
    font-weight: 500;
    box-shadow: 0 8px 18px rgba(32, 132, 252, 0.3);
}

/* Flüssigkeitsebene */
.btn-primary::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -110%;
    height: 210%;
    background:
        radial-gradient(circle at 20% 0, rgba(255, 255, 255, 0.28) 0, transparent 50%),
        radial-gradient(circle at 80% 10%, rgba(255, 255, 255, 0.18) 0, transparent 55%),
        linear-gradient(180deg, #6fa8ff 0%, #2f7bff 45%, #1f4fd1 100%);
    background-size: 140% 140%;
    background-position: 0 0;
    transition: bottom 0.4s ease-out;
    z-index: 0;
}

/* Wellen-/Glow-Ebene */
.btn-primary::after {
    content: "";
    position: absolute;
    left: -20%;
    top: -40%;
    width: 140%;
    height: 120%;
    background:
        radial-gradient(circle at 10% 40%, rgba(255, 255, 255, 0.16) 0, transparent 55%),
        radial-gradient(circle at 90% 50%, rgba(255, 255, 255, 0.12) 0, transparent 55%);
    opacity: 0;
    mix-blend-mode: screen;
    pointer-events: none;
    z-index: 1;
}

/* Text immer über der Füllung */
.btn-primary span,
.btn-primary {
    position: relative;
    z-index: 2;
}

/* Hover: Wasser steigt + Button hebt leicht ab */
.btn-primary:hover {
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 18px 32px rgba(32, 132, 252, 0.6);
}

.btn-primary:hover::before {
    bottom: -5%;
    animation: btnWaveMove 3s ease-in-out infinite alternate;
}

.btn-primary:hover::after {
    opacity: 1;
    animation: btnWaveGlow 3s ease-in-out infinite alternate;
}

/* Wellenbewegung */
@keyframes btnWaveMove {
    0% { background-position: 0 0; }
    50% { background-position: 40% 20%; }
    100% { background-position: 80% 0; }
}

@keyframes btnWaveGlow {
    0%   { transform: translateX(0);   opacity: 0.5; }
    50%  { transform: translateX(6%);  opacity: 0.9; }
    100% { transform: translateX(-4%); opacity: 0.6; }
}

/* Sekundärer Button: Zum Login */
.btn-secondary {
    background-color: transparent;
    border-color: rgba(156, 174, 255, 0.6);
    color: #e0e4ff;
}

.btn-secondary:hover {
    transform: translateY(-1px);
    background-color: rgba(120, 144, 255, 0.12);
    border-color: rgba(156, 174, 255, 0.9);
}

/* Meta-Infos */
.form-meta {
    margin-top: 12px;
}

.form-meta p {
    font-size: 0.8rem;
    color: rgba(190, 202, 240, 0.8);
}

/* Footer */
.login-footer {
    margin-top: 16px;
    text-align: center;
    font-size: 0.75rem;
    color: rgba(180, 192, 230, 0.78);
}

/* SweetAlert2 Dark Theme */
.swal2-dark-popup {
    border-radius: 16px !important;
    border: 1px solid rgba(120, 144, 255, 0.5);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.7);
}

.swal2-dark-title {
    font-size: 1.2rem !important;
    color: #ffffff !important;
}

.swal2-dark-html {
    font-size: 0.9rem !important;
    color: #dfe6ff !important;
}

.swal2-dark-confirm,
.swal2-dark-cancel {
    border-radius: 999px !important;
    padding: 8px 18px !important;
    font-size: 0.9rem !important;
}

/* Mobil */
@media (max-width: 480px) {
    .login-card {
        padding: 22px 18px 18px;
    }

    .login-title h1 {
        font-size: 1.4rem;
    }

    .form-actions {
        flex-direction: column;
    }

    .btn {
        width: 100%;
    }

    .login-header {
        align-items: center;
    }
}
a.btn-startpage {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 10px 18px;
    border-radius: 999px;

    /* KLAR anders als Primary/Secondary: Neon-Orange/Gold */
    background: linear-gradient(135deg, #f97316, #facc15);
    border: 1px solid rgba(250, 204, 21, 0.9);
    color: #111827; /* dunkler Text für Kontrast */

    text-decoration: none;
    font-weight: 600;
    font-size: 0.92rem;
    letter-spacing: 0.02em;

    box-shadow:
        0 0 20px rgba(250, 204, 21, 0.55),
        0 12px 30px rgba(0, 0, 0, 0.75);

    transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

a.btn-startpage:hover {
    transform: translateY(-1px) scale(1.01);
    filter: brightness(1.05);
    box-shadow:
        0 0 28px rgba(250, 204, 21, 0.9),
        0 16px 40px rgba(0, 0, 0, 0.85);
}