/* Global auth card / form / button styles.
   Used by both the routed auth pages (under LoginLayout) and the in-page AuthModal,
   so it lives outside any component's scoped CSS. Page background + modal positioning
   stay in their respective scoped CSS files. */

.login-container {
    position: relative;
    background: #ffffff;
    border-radius: 16px;
    padding: 2.5rem 2.25rem 2rem;
    text-align: center;
    max-width: 440px;
    width: 100%;
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.6) inset,
        0 25px 60px -20px rgba(13, 64, 83, 0.45),
        0 10px 30px -12px rgba(13, 64, 83, 0.25);
    font-family: 'Open Sans', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
    color: #0d4053;
}

/* Headings */
.login-container h1,
.login-container h2,
.login-container h3 {
    color: #0d4053;
    margin: 0;
    letter-spacing: -0.015em;
    text-align: center;
}

.login-container h1 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.login-container h2,
.login-container h3 {
    font-size: 1rem;
    font-weight: 500;
    color: #6b7785;
    margin-bottom: 1.5rem;
}

.login-container h4 {
    font-size: 0.95rem;
    font-weight: 500;
    color: #6b7785;
    margin: 0 0 1.5rem;
    text-align: center;
}

.login-container hr {
    border: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(13, 64, 83, 0.12), transparent);
    margin: 1rem 0 1.5rem;
}

/* Form */
.login-form {
    text-align: left;
}

.login-form .form-floating {
    margin-bottom: 1rem;
}

.login-form .form-control {
    border: 1px solid rgba(13, 64, 83, 0.10);
    border-radius: 10px;
    padding: 1rem 0.875rem 0.5rem;
    background: #f5f8fb;
    font-size: 0.95rem;
    color: #0d4053;
    transition: border-color 160ms ease, box-shadow 220ms ease, background 160ms ease;
    height: auto;
    min-height: 58px;
    width: 100%;
    font-family: inherit;
}

.login-form .form-control:focus {
    border-color: #00aaff;
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(0, 170, 255, 0.15);
    outline: none;
}

.login-form .form-floating > label {
    color: #6b7785;
    padding-left: 0.95rem;
}

/* Buttons — single base + variants; works on <button> and <a class="btn ..."> */
.login-form .btn {
    display: block;
    width: 100%;
    padding: 0.85rem 1rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    text-align: center;
    border: 1px solid transparent;
    cursor: pointer;
    font-family: inherit;
    transition: background 180ms ease, color 180ms ease, border-color 180ms ease, transform 140ms ease, box-shadow 220ms ease;
}

.login-form a.btn {
    text-decoration: none;
}

.login-form .btn:disabled,
.login-form .btn[disabled] {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none !important;
}

.login-form .btn-primary {
    background: #11b981;
    color: #ffffff;
    border-color: #11b981;
    box-shadow: 0 8px 20px -8px rgba(17, 185, 129, 0.55);
}

.login-form .btn-primary:hover:not(:disabled),
.login-form .btn-primary:focus:not(:disabled) {
    background: #0fa572;
    border-color: #0fa572;
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 12px 24px -8px rgba(17, 185, 129, 0.65);
}

.login-form .btn-primary:active:not(:disabled) {
    transform: translateY(0);
}

.login-form .btn-secondary {
    background: transparent;
    color: #6b7785;
    border-color: rgba(13, 64, 83, 0.18);
    font-weight: 500;
    margin-top: 0.5rem;
}

.login-form .btn-secondary:hover:not(:disabled),
.login-form .btn-secondary:focus:not(:disabled) {
    background: #f5f8fb;
    color: #0d4053;
    border-color: rgba(13, 64, 83, 0.32);
}

/* Bare submit button (no explicit variant class) defaults to primary look */
.login-form button[type="submit"]:not(.btn-secondary) {
    background: #11b981;
    color: #ffffff;
    border: none;
    box-shadow: 0 8px 20px -8px rgba(17, 185, 129, 0.55);
}

/* Plain text links (e.g. "Forgot your password?") */
.login-form a:not(.btn),
.login-form button.linklike {
    color: #00aaff;
    text-decoration: none;
    font-weight: 500;
    background: transparent;
    border: none;
    padding: 0;
    font: inherit;
    cursor: pointer;
}

.login-form a:not(.btn):hover,
.login-form button.linklike:hover {
    color: #0088cc;
    text-decoration: underline;
}

/* Helper text below the primary action */
.login-form-meta {
    margin: 1.25rem 0 0;
    text-align: center;
    color: #6b7785;
    font-size: 0.9rem;
}

.login-form-meta a,
.login-form-meta button.linklike {
    color: #00aaff;
    text-decoration: none;
    font-weight: 500;
    background: transparent;
    border: none;
    padding: 0;
    font: inherit;
    cursor: pointer;
}

.login-form-meta a:hover,
.login-form-meta button.linklike:hover {
    color: #0088cc;
    text-decoration: underline;
}

/* Remember-me checkbox */
.login-form .checkbox {
    margin: 0.5rem 0 1.25rem;
    font-size: 0.9rem;
    color: #4a5569;
}

.login-form .checkbox .form-check-input {
    margin-right: 0.5rem;
    border-color: rgba(13, 64, 83, 0.3);
}

.login-form .checkbox .form-check-input:checked {
    background-color: #11b981;
    border-color: #11b981;
}

/* Validation / error banner inside login-form */
.login-form .text-danger,
.login-form .validation-message {
    font-size: 0.825rem;
    color: #d63b3b !important;
    margin-top: 0.25rem;
}

.login-form-error {
    background: rgba(214, 59, 59, 0.08);
    border: 1px solid rgba(214, 59, 59, 0.18);
    color: #b02525;
    border-radius: 10px;
    padding: 0.7rem 0.9rem;
    font-size: 0.875rem;
    margin-bottom: 1rem;
}

@media (max-width: 480px) {
    .login-container {
        padding: 2rem 1.5rem 1.75rem;
        border-radius: 14px;
    }
    .login-container h1 { font-size: 1.5rem; }
}
