/* =====================================================
   AUTH MODALS – FINAL (PASST ZU header.php + header.js)
   ===================================================== */

/* OVERLAY */
.bottom-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.45);
    backdrop-filter: blur(6px);

    display: flex;
    align-items: center;
    justify-content: center;

    opacity: 0;
    pointer-events: none;
    transition: opacity .25s ease;

    z-index: 9999;
}

/* AKTIV */
.bottom-modal.active {
    opacity: 1;
    pointer-events: auto;
}

/* MODAL BOX */
.modal-box {
    width: 100%;
    max-width: 460px;

    background: var(--surface-light);
    color: var(--text-light);

    border-radius: 18px;
    padding: 36px 34px 38px;

    transform: translateY(10px) scale(.96);
    opacity: 0;
    transition: transform .3s ease, opacity .3s ease;

    box-shadow:
        0 30px 60px rgba(0,0,0,.35),
        0 0 0 1px rgba(0,0,0,.04);
}

/* MODAL EINBLENDEN */
.bottom-modal.active .modal-box {
    transform: translateY(0) scale(1);
    opacity: 1;
}

/* DARK MODE */
body.dark .modal-box {
    background: linear-gradient(180deg,#1f2937,#111827);
    color: #f9fafb;
}

/* CLOSE */
.close-btn {
    position: absolute;
    top: 14px;
    right: 16px;
    font-size: 1.6rem;
    background: none;
    border: none;
    cursor: pointer;
    opacity: .75;
    color: inherit;
}
.close-btn:hover {
    opacity: 1;
}

/* TITLE */
.modal-box h2 {
    margin: 0 0 24px;
    text-align: center;
    font-size: 1.6rem;
    font-weight: 700;
}

/* INPUTS */
.modal-box input {
    width: 100%;
    padding: 14px 16px;
    margin-bottom: 16px;

    border-radius: 12px;
    border: 1px solid rgba(0,0,0,.18);
    font-size: 1rem;
}
.modal-box input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79,70,229,.15);
}

/* DARK INPUT */
body.dark .modal-box input {
    background: #020617;
    border-color: rgba(255,255,255,.25);
    color: #f9fafb;
}

/* BUTTON */
.modal-box button.primary {
    width: 100%;
    padding: 14px;
    margin-top: 8px;

    border-radius: 14px;
    border: none;

    background: linear-gradient(135deg,#4f46e5,#6366f1);
    color: #fff;

    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
}

/* ERROR */
.inline-error {
    background: rgba(220,38,38,.12);
    color: #dc2626;
    padding: 10px 12px;
    border-radius: 10px;
    margin-bottom: 14px;
    font-size: .9rem;
}

/* MOBILE */
@media (max-width:520px) {
    .modal-box {
        margin: 0 18px;
        padding: 30px 26px 32px;
    }
}
