/* Modern Authentication Pages Styles */

/* Remove page-header bottom margin on auth pages */
.main:has(.auth-page-content) .page-header {
    margin-bottom: 0;
}

/* Background for auth pages */
.auth-page-content {
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8ec 100%);
    min-height: 60vh;
    padding: 3rem 0;
}

/* Modern card styling */
.auth-card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
    border: none;
    padding: 2.5rem;
    max-width: 520px;
    margin: 0 auto;
}

/* Header text */
.auth-card-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #f0f0f0;
}

.auth-card-header h2 {
    font-size: 1.75rem;
    font-weight: 600;
    color: #1a1a2e;
    margin-bottom: 0.5rem;
}

.auth-card-header p {
    color: #6c757d;
    font-size: 0.95rem;
    margin: 0;
}

/* Floating label inputs */
.auth-card .form-floating {
    position: relative;
    margin-bottom: 1rem;
}

.auth-card .form-floating .form-control {
    border: 1px solid #c0c4c8;
    border-radius: 10px;
    padding: 1.25rem 1rem 0.5rem;
    height: auto;
    font-size: 1rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    background-color: #fafafa;
}

.auth-card .form-floating .form-control:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.1);
    background-color: #fff;
}

.auth-card .form-floating label {
    position: absolute;
    top: 0;
    left: 0;
    padding: 1rem;
    pointer-events: none;
    transform-origin: 0 0;
    transition: opacity 0.15s ease-in-out, transform 0.15s ease-in-out;
    color: #6c757d;
    font-size: 1rem;
}

.auth-card .form-floating .form-control:focus ~ label,
.auth-card .form-floating .form-control:not(:placeholder-shown) ~ label {
    opacity: 0.8;
    transform: scale(0.75) translateY(-0.5rem);
    color: #0d6efd;
}

.auth-card .form-floating .form-control:not(:focus):not(:placeholder-shown) ~ label {
    color: #6c757d;
}

/* Input with icon (password field) */
.auth-card .input-group-floating {
    position: relative;
}

.auth-card .input-group-floating .form-control {
    border: 1px solid #c0c4c8;
    border-radius: 10px;
    padding: 1.25rem 3rem 0.5rem 1rem;
    height: auto;
    font-size: 1rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    background-color: #fafafa;
    width: 100%;
}

.auth-card .input-group-floating .form-control:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.1);
    background-color: #fff;
}

.auth-card .input-group-floating label {
    position: absolute;
    top: 0;
    left: 0;
    padding: 1rem;
    pointer-events: none;
    transform-origin: 0 0;
    transition: opacity 0.15s ease-in-out, transform 0.15s ease-in-out;
    color: #6c757d;
    font-size: 1rem;
    z-index: 2;
}

.auth-card .input-group-floating .form-control:focus ~ label,
.auth-card .input-group-floating .form-control:not(:placeholder-shown) ~ label {
    opacity: 0.8;
    transform: scale(0.75) translateY(-0.5rem);
    color: #0d6efd;
}

.auth-card .input-group-floating .form-control:not(:focus):not(:placeholder-shown) ~ label {
    color: #6c757d;
}

.auth-card .input-group-floating .btn-toggle-password {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    border: none;
    background: transparent;
    color: #6c757d;
    padding: 0 1rem;
    z-index: 3;
    border-radius: 0 10px 10px 0;
}

.auth-card .input-group-floating .btn-toggle-password:hover {
    color: #495057;
    background: rgba(0,0,0,0.03);
}

/* Primary button */
.auth-card .btn-primary {
    border-radius: 10px;
    padding: 0.875rem 1.5rem;
    font-size: 1.05rem;
    font-weight: 600;
    border: none;
    background: linear-gradient(135deg, #0d6efd 0%, #0b5ed7 100%);
    box-shadow: 0 2px 8px rgba(13, 110, 253, 0.25);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.auth-card .btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(13, 110, 253, 0.35);
}

.auth-card .btn-primary:active {
    transform: translateY(0);
}

/* Remember me / forgot password row */
.auth-card .auth-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 1rem 0;
    font-size: 0.9rem;
}

.auth-card .auth-options a {
    color: #0d6efd;
    text-decoration: none;
}

.auth-card .auth-options a:hover {
    text-decoration: underline;
}

.auth-card .form-check-input {
    border-radius: 4px;
}

/* Divider */
.auth-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 1.5rem 0;
    color: #adb5bd;
    font-size: 0.85rem;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid #e0e0e0;
}

.auth-divider span {
    padding: 0 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Google button */
.auth-card .btn-google {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    background: #fff;
    color: #495057;
    font-weight: 500;
    transition: background-color 0.15s ease, border-color 0.15s ease;
}

.auth-card .btn-google:hover {
    background: #f8f9fa;
    border-color: #d0d0d0;
}

.auth-card .btn-google img {
    width: 20px;
    height: 20px;
}

/* Footer text */
.auth-card-footer {
    text-align: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #f0f0f0;
    font-size: 0.9rem;
    color: #6c757d;
}

.auth-card-footer a {
    color: #0d6efd;
    font-weight: 500;
    text-decoration: none;
}

.auth-card-footer a:hover {
    text-decoration: underline;
}

/* Error messages */
.auth-card .alert-danger {
    border-radius: 10px;
    border: none;
    background-color: #fff5f5;
    color: #dc3545;
    font-size: 0.9rem;
}

/* Responsive adjustments */
@media (max-width: 576px) {
    .auth-card {
        margin: 0 1rem;
        padding: 1.5rem;
    }

    .auth-page-content {
        padding: 1.5rem 0;
    }
}
