/* SMCare Login Styling */
/* This file provides styling for SMCare-specific login components and branding */

.smcare-login-container {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.smcare-login-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    padding: 2rem;
    width: 100%;
    max-width: 400px;
    backdrop-filter: blur(10px);
}

.smcare-logo {
    text-align: center;
    margin-bottom: 2rem;
}

.smcare-logo h1 {
    color: #764ba2;
    font-weight: 600;
    font-size: 1.8rem;
    margin: 0;
}

.smcare-logo .subtitle {
    color: #666;
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.smcare-form-group {
    margin-bottom: 1.5rem;
}

.smcare-form-label {
    display: block;
    margin-bottom: 0.5rem;
    color: #555;
    font-weight: 500;
}

.smcare-form-input {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.smcare-form-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.smcare-login-button {
    width: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 0.875rem;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.smcare-login-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
}

.smcare-login-button:active {
    transform: translateY(0);
}

.smcare-login-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.smcare-remember-me {
    display: flex;
    align-items: center;
    margin: 1rem 0;
}

.smcare-remember-me input[type="checkbox"] {
    margin-right: 0.5rem;
    transform: scale(1.1);
}

.smcare-footer {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #e0e0e0;
}

.smcare-footer .copyright {
    color: #999;
    font-size: 0.85rem;
}

.smcare-footer .support-link {
    color: #667eea;
    text-decoration: none;
    font-size: 0.9rem;
    margin-top: 0.5rem;
    display: block;
}

.smcare-footer .support-link:hover {
    text-decoration: underline;
}

/* Error states */
.smcare-error {
    background: #fee;
    border: 1px solid #fcc;
    color: #c66;
    padding: 0.75rem;
    border-radius: 6px;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.smcare-success {
    background: #efe;
    border: 1px solid #cfc;
    color: #6c6;
    padding: 0.75rem;
    border-radius: 6px;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

/* Loading states */
.smcare-loading {
    position: relative;
    pointer-events: none;
}

.smcare-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #fff;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: smcare-spin 1s linear infinite;
}

@keyframes smcare-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive design */
@media (max-width: 480px) {
    .smcare-login-card {
        margin: 1rem;
        padding: 1.5rem;
    }
    
    .smcare-logo h1 {
        font-size: 1.5rem;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .smcare-login-card {
        background: rgba(30, 30, 30, 0.95);
        color: #e0e0e0;
    }
    
    .smcare-logo h1 {
        color: #8a7bff;
    }
    
    .smcare-form-input {
        background: rgba(50, 50, 50, 0.8);
        border-color: #555;
        color: #e0e0e0;
    }
    
    .smcare-form-input:focus {
        border-color: #8a7bff;
        box-shadow: 0 0 0 3px rgba(138, 123, 255, 0.1);
    }
    
    .smcare-footer {
        border-top-color: #555;
    }
    
    .smcare-footer .copyright {
        color: #aaa;
    }
}

/* Animation for form appearance */
.smcare-login-card {
    animation: smcare-slideIn 0.6s ease-out;
}

@keyframes smcare-slideIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Focus management for accessibility */
.smcare-form-input:focus,
.smcare-login-button:focus,
.smcare-remember-me input:focus {
    outline: 2px solid #667eea;
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .smcare-login-card {
        border: 2px solid #000;
    }
    
    .smcare-form-input {
        border-width: 2px;
    }
    
    .smcare-login-button {
        border: 2px solid #000;
    }
}

/* Enhanced form validation styles */
.smcare-input-error {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.1) !important;
}

.smcare-field-error {
    color: #dc3545;
    font-size: 0.8rem;
    margin-top: 0.25rem;
    display: flex;
    align-items: center;
}

.smcare-field-error::before {
    content: '?';
    margin-right: 0.25rem;
}

.smcare-form-error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
    padding: 0.75rem;
    border-radius: 6px;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
}

.smcare-form-error i {
    margin-right: 0.5rem;
}

.smcare-enhanced-error {
    position: relative;
    padding-right: 2rem;
}

.smcare-error-close {
    position: absolute;
    top: 0.25rem;
    right: 0.5rem;
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    color: inherit;
    opacity: 0.7;
}

.smcare-error-close:hover {
    opacity: 1;
}

.smcare-input-focused .smcare-form-input {
    transform: scale(1.02);
}

.remember-me-updated {
    background: rgba(40, 167, 69, 0.1);
    border-radius: 4px;
    transition: background 0.3s ease;
}

.smcare-message {
    padding: 0.75rem;
    border-radius: 6px;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
}

.smcare-message i {
    margin-right: 0.5rem;
}

.smcare-message-info {
    background: #d1ecf1;
    border: 1px solid #bee5eb;
    color: #0c5460;
}

.smcare-message-success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.smcare-message-warning {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
}

.smcare-message-error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}