/* Login page specific styles */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f8fafc;
    padding: 3rem 1rem;
}

.login-form-container {
    max-width: 28rem;
    width: 100%;
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    padding: 2rem;
    border: 1px solid #e2e8f0;
}

.login-header {
    margin-top: 0;
    text-align: center;
    font-size: 1.875rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.login-subtitle {
    margin-top: 0;
    text-align: center;
    font-size: 0.875rem;
    color: #6b7280;
    font-weight: 400;
    margin-bottom: 2rem;
}

.login-form {
    margin-top: 0;
    space-y: 1.5rem;
}

.form-input {
    appearance: none;
    border-radius: 0.375rem;
    position: relative;
    display: block;
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #d1d5db;
    color: #374151;
    background-color: white;
    font-size: 0.875rem;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-input.pl-10 {
    padding-left: 2.5rem;
}

.form-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.form-input:hover {
    border-color: #9ca3af;
}

.form-input:focus + .absolute svg {
    color: #3b82f6;
}

/* Label styling */
label[for="username"], label[for="password"] {
    color: #374151;
    font-weight: 500;
    margin-bottom: 0.5rem;
    display: block;
    font-size: 0.875rem;
}

.remember-me-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 1.5rem 0;
}

.remember-me-checkbox {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.remember-me-checkbox input {
    height: 1rem;
    width: 1rem;
    color: #3b82f6;
    border: 1px solid #d1d5db;
    border-radius: 0.25rem;
    background-color: white;
    transition: border-color 0.15s ease-in-out;
    cursor: pointer;
}

.remember-me-checkbox input:checked {
    background-color: #3b82f6;
    border-color: #3b82f6;
}

.remember-me-checkbox input:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.remember-me-checkbox label {
    margin-left: 0.5rem;
    display: block;
    font-size: 0.875rem;
    color: #374151;
    font-weight: 400;
    cursor: pointer;
    user-select: none;
}

.login-button {
    position: relative;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0.75rem 1rem;
    border: none;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 0.375rem;
    color: white;
    background-color: #3b82f6;
    transition: background-color 0.15s ease-in-out;
    cursor: pointer;
}

.login-button:hover {
    background-color: #2563eb;
}

.login-button:active {
    background-color: #1d4ed8;
}

.login-button:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.login-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background-color: #9ca3af;
}

.login-button-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    z-index: 1;
}

.login-button-icon svg {
    height: 1rem;
    width: 1rem;
    color: white;
    opacity: 0.9;
}

.login-button:hover .login-button-icon svg {
    opacity: 1;
}

.error-message {
    display: none;
    background-color: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
    padding: 0.75rem 1rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    margin-top: 1rem;
}

.error-message.show {
    display: block;
}

.error-content {
    display: flex;
    align-items: center;
}

.error-icon {
    flex-shrink: 0;
}

.error-icon svg {
    height: 1.25rem;
    width: 1.25rem;
    color: #ef4444;
}

.error-text {
    margin-left: 0.75rem;
    font-weight: 400;
}

.loading-spinner {
    animation: spin 1s linear infinite;
    margin-right: 0.75rem;
    height: 1.25rem;
    width: 1.25rem;
    color: white;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* CAPTCHA Styles */
.captcha-section {
    margin: 1rem 0;
    padding: 1rem;
    background-color: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 0.375rem;
}

.captcha-container {
    space-y: 0.75rem;
}

.captcha-challenge {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.captcha-question {
    flex: 1;
    padding: 0.75rem 1rem;
    background-color: white;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    font-family: 'Courier New', monospace;
    font-size: 1.125rem;
    font-weight: 600;
    color: #374151;
    text-align: center;
    min-height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.captcha-refresh {
    padding: 0.5rem;
    background-color: #3b82f6;
    color: white;
    border: none;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: background-color 0.15s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: center;
}

.captcha-refresh:hover {
    background-color: #2563eb;
}

.captcha-refresh:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Responsive design */
@media (max-width: 640px) {
    .login-container {
        padding: 1rem;
    }
    
    .login-form-container {
        padding: 1.5rem;
    }
    
    .login-header {
        font-size: 1.5rem;
    }
    
    .login-subtitle {
        font-size: 0.8rem;
    }
    
    .captcha-challenge {
        flex-direction: column;
        align-items: stretch;
    }
    
    .captcha-refresh {
        align-self: center;
        width: fit-content;
    }
}
