/* login_modal.css — overlay + box for the shared Login modal. Form
   styling matches the standalone login.php; classes are .lm- prefixed
   so they can't collide with other modals on the same page. */

.lm-overlay {
    position: fixed; inset: 0;
    background: rgba(10, 10, 18, 0.9);
    display: flex; justify-content: center; align-items: center;
    opacity: 0; pointer-events: none; transition: opacity 0.3s ease;
    z-index: 1500;
    padding: 20px;
}
.lm-overlay.active { opacity: 1; pointer-events: auto; }

.lm-box {
    background: var(--bg-secondary);
    border: 1px solid rgba(5,217,232,0.3);
    border-radius: 12px; padding: 30px;
    width: 100%; max-width: 420px;
    max-height: 90vh; overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    transform: translateY(-20px); transition: transform 0.3s ease;
    position: relative;
    box-sizing: border-box;
}
.lm-overlay.active .lm-box { transform: translateY(0); }

.lm-close {
    position: absolute; top: 10px; right: 14px;
    background: transparent; border: none; padding: 0;
    font-size: 1.6rem; line-height: 1; cursor: pointer;
    color: var(--text-secondary);
}
.lm-close:hover { color: #ff4444; }

.lm-title {
    margin: 0 0 20px;
    font-family: var(--main-font);
    font-size: 1.5rem; font-weight: 700; line-height: 1.3;
    color: var(--text-light); text-align: center;
}

/* Form fields — scoped to .lm-box so the rules don't bleed. */
.lm-box .form-group { margin-bottom: 18px; }
.lm-box label { display: block; margin-bottom: 6px; font-weight: 600; font-size: 0.95rem; color: var(--text-secondary); }
.lm-box .form-control {
    display: block; width: 100%; padding: 10px 12px;
    background: rgba(0,0,0,0.25);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 6px;
    color: var(--text-primary); font-family: inherit; font-size: 0.95rem;
    box-sizing: border-box;
}
.lm-box .form-control:focus { outline: none; border-color: var(--neon-blue); box-shadow: 0 0 5px rgba(0,247,255,0.3); }
.lm-box .form-control:required:invalid { border-color: #ff4444; }

.lm-errors {
    margin: 0 0 16px;
    padding: 10px 14px;
    background: rgba(255,68,68,0.08);
    border: 1px solid rgba(255,68,68,0.4);
    border-radius: 6px;
    color: #ff8888; font-size: 0.85rem;
}
.lm-errors ul { margin: 0; padding-left: 18px; }
.lm-errors li { margin: 2px 0; }

.lm-submit { width: 100%; padding: 10px 16px; font-size: 1rem; cursor: pointer; border-radius: 4px; font-weight: 600; }
.lm-submit:disabled { opacity: 0.4; cursor: not-allowed; pointer-events: none; }

.lm-footer { margin-top: 20px; text-align: center; font-size: 0.9rem; color: var(--text-muted); }
.lm-footer a { color: var(--accent-secondary); text-decoration: none; font-weight: 600; }
.lm-footer a:hover { text-decoration: underline; }
.lm-footer .row { margin-bottom: 6px; }

@media (max-width: 600px) {
    .lm-overlay { padding: 12px; }
    .lm-box { padding: 20px; }
}
