/**
 * Login Page Styles
 * Provides consistent styling for the login page to match the VIBE template
 */

.login-page-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12rem 0 2rem 0;
    background: #f9fafb;
    position: relative;
    overflow: hidden;
}

.login-page-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 50%, rgba(73, 2, 81, 0.03) 0%, transparent 50%),
                radial-gradient(circle at 80% 80%, rgba(107, 3, 117, 0.03) 0%, transparent 50%);
    pointer-events: none;
}

/* Container uses standard container class from main layout */

.login-card {
    background: white;
    border-radius: 1.5rem;
    position: relative;
    overflow: hidden;
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 600px;
}

/* Left section: Login Form */
.login-form-section {
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    z-index: 2;
}

/* Right section: Image */
.login-image-section {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #490251 0%, #6b0375 100%);
}

.login-side-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: right center;
    opacity: 0.95;
}

.login-header {
    text-align: center;
    margin-bottom: 2rem;
    position: relative;
    z-index: 2;
}

.login-logo {
    display: none;
}

.login-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.login-subtitle {
    color: #6b7280;
    font-size: 0.95rem;
}

/* Form Styles */
#loginForm {
    position: relative;
    z-index: 2;
}

#loginForm form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.heading1 {
    font-size: 0.875rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
    display: block;
}

.login_input {
    width: 100%;
}

.login_input input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 0.75rem;
    font-size: 1rem;
    color: #1f2937;
    transition: all 0.2s ease;
    background-color: #f9fafb;
}

.login_input input:focus {
    outline: none;
    border-color: #6b0375;
    background-color: white;
    box-shadow: 0 0 0 3px rgba(107, 3, 117, 0.1);
}

.login_input input::placeholder {
    color: #9ca3af;
}

/* Remember Me & Forgot Password */
.remember_forgot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.remember {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.remember input[type="checkbox"] {
    width: 1.125rem;
    height: 1.125rem;
    border-radius: 0.375rem;
    border: 2px solid #d1d5db;
    cursor: pointer;
    accent-color: #490251;
}

.remember label {
    font-size: 0.875rem;
    color: #4b5563;
    cursor: pointer;
    user-select: none;
}

.forgot-link {
    font-size: 0.875rem;
    color: #6b0375;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.forgot-link:hover {
    color: #490251;
    text-decoration: underline;
}

/* Buttons */
.marginTop {
    margin-top: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.loginButton,
.homeButton {
    width: 100%;
    padding: 0.875rem 1.5rem;
    border-radius: 0.75rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.loginButton {
    background: linear-gradient(135deg, #490251 0%, #6b0375 100%);
    color: white;
}

.loginButton:hover {
    background: linear-gradient(135deg, #3d0142 0%, #5a0261 100%);
}

.loginButton:active {
    transform: translateY(0);
}

.homeButton {
    background: white;
    color: #6b0375;
    border: 2px solid #6b0375;
}

.homeButton:hover {
    background: #faf5fb;
    border-color: #490251;
    color: #490251;
}

/* Alert Messages */
.alert {
    padding: 1rem;
    border-radius: 0.75rem;
    margin-bottom: 1.5rem;
    font-size: 0.875rem;
    display: flex;
    align-items: start;
    gap: 0.75rem;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.alert-danger {
    background-color: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.alert-success {
    background-color: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.alert-info {
    background-color: #eff6ff;
    color: #1e40af;
    border: 1px solid #bfdbfe;
}

/* Captcha Styles */
.captchaAdmin {
    margin: 1rem 0;
    padding: 1rem;
    background: #f9fafb;
    border-radius: 0.75rem;
    border: 2px solid #e5e7eb;
}

/* Responsive */
@media (max-width: 1024px) {
    .login-card {
        grid-template-columns: 1fr;
        min-height: auto;
    }
    
    .login-image-section {
        display: none;
    }
    
    .login-form-section {
        padding: 3rem 2rem;
    }
}

@media (max-width: 640px) {
    .login-form-section {
        padding: 2rem 1.5rem;
    }

    .login-title {
        font-size: 1.5rem;
    }

    .login-logo {
        width: 64px;
        height: 64px;
    }

    .remember_forgot {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* Loading State */
.loginButton:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

/* Focus visible for accessibility */
.loginButton:focus-visible,
.homeButton:focus-visible {
    outline: 2px solid #490251;
    outline-offset: 2px;
}

/* Smooth transitions */
* {
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}
