* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
}

body { 
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; 
    background: #f5f5f5; 
}

/* Login/Register Container */
.auth-container { 
    min-height: 100vh; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); 
}

.auth-card { 
    background: white; 
    padding: 40px; 
    border-radius: 12px; 
    width: 100%; 
    max-width: 450px; 
    box-shadow: 0 10px 40px rgba(0,0,0,0.2); 
}

.auth-card h2 { 
    text-align: center; 
    margin-bottom: 10px; 
    color: #333; 
}

.auth-card p { 
    text-align: center; 
    margin-bottom: 30px; 
    color: #666; 
    font-size: 14px; 
}

/* Forms */
.form-group { 
    margin-bottom: 20px; 
}

.form-group label { 
    display: block; 
    margin-bottom: 8px; 
    font-weight: 500; 
    color: #374151; 
}

.form-hint {
    color: #666;
    font-size: 12px;
    margin-top: 4px;
}

.form-control { 
    width: 100%; 
    padding: 12px; 
    border: 1px solid #e5e7eb; 
    border-radius: 8px; 
    font-size: 14px; 
}

.form-control:focus { 
    outline: none; 
    border-color: #667eea; 
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1); 
}

/* Buttons */
.btn { 
    display: inline-block; 
    padding: 12px 20px; 
    border-radius: 8px; 
    text-decoration: none; 
    cursor: pointer; 
    border: none; 
    font-size: 14px; 
    transition: all 0.3s; 
    font-weight: 500; 
}

.btn-primary { 
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); 
    color: white; 
    width: 100%; 
}

.btn-primary:hover { 
    transform: translateY(-2px); 
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4); 
}

.btn-secondary { 
    background: #6b7280; 
    color: white; 
    width: 100%; 
    margin-top: 10px; 
}

.btn-secondary:hover { 
    background: #4b5563; 
}

/* Alerts */
.alert { 
    padding: 12px 15px; 
    border-radius: 8px; 
    margin-bottom: 20px; 
    font-size: 14px; 
}

.alert-error { 
    background: #fee2e2; 
    color: #991b1b; 
    border-left: 4px solid #dc2626; 
}

.alert-error ul { 
    margin: 5px 0 0 20px; 
}

/* Links */
.auth-footer { 
    text-align: center; 
    margin-top: 20px; 
}

.auth-footer a { 
    color: #667eea; 
    text-decoration: none; 
    font-weight: 500; 
}

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

/* Spinner */
.spinner {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border: 8px solid #5a5d5e;
    border-top: 8px solid #3498db;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 2s linear infinite;
    display: none;
    z-index: 9999;
}

@keyframes spin {
    0% { 
        transform: translate(-50%, -50%) rotate(0deg); 
    }
    100% { 
        transform: translate(-50%, -50%) rotate(360deg); 
    }
}

/* Test Users Section */
.test-users-section { 
    margin-bottom: 30px; 
    padding-bottom: 30px; 
    border-bottom: 1px solid #e5e7eb; 
}

.test-users-title { 
    text-align: center; 
    color: #667eea; 
    font-size: 16px; 
    font-weight: 600; 
    margin-bottom: 8px; 
}

.test-users-subtitle { 
    text-align: center; 
    color: #6b7280; 
    font-size: 13px; 
    margin-bottom: 20px; 
}

.test-users-grid { 
    display: grid; 
    grid-template-columns: repeat(2, 1fr); 
    gap: 15px; 
    margin-bottom: 10px; 
}

.user-card { 
    background: #f9fafb; 
    border: 2px solid #e5e7eb; 
    border-radius: 8px; 
    padding: 18px 12px; 
    text-align: center; 
    cursor: pointer; 
    transition: all 0.3s; 
}

.user-card:hover { 
    border-color: #667eea; 
    background: #f3f4f6; 
    transform: translateY(-2px); 
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15); 
}

.user-card-role { 
    font-weight: 600; 
    color: #374151; 
    margin-bottom: 8px; 
    font-size: 14px; 
}

.user-card-username { 
    color: #667eea; 
    font-size: 13px; 
    margin-bottom: 10px; 
    font-family: monospace; 
}

.user-card-action { 
    color: #667eea; 
    font-size: 12px; 
    font-weight: 500; 
    text-decoration: none; 
    display: inline-block; 
}

.user-card-action:hover { 
    text-decoration: underline; 
}

/* Auth Copyright */
.auth-copyright {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #e5e7eb;
    text-align: center;
}

.auth-copyright p {
    margin: 0;
    color: #6b7280;
    font-size: 13px;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .auth-container {
        padding: 20px;
    }
    
    .auth-card {
        padding: 30px 20px;
        max-width: 100%;
    }
    
    .auth-card h2 {
        font-size: 1.5rem;
    }
    
    .test-users-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .user-card {
        padding: 15px 10px;
    }
    
    .form-control {
        font-size: 16px; /* Evita zoom en iOS */
    }
}

@media (max-width: 480px) {
    .auth-card {
        padding: 25px 15px;
    }
    
    .auth-card h2 {
        font-size: 1.3rem;
    }
    
    .test-users-section {
        margin-bottom: 25px;
        padding-bottom: 25px;
    }
    
    .test-users-title {
        font-size: 14px;
    }
    
    .test-users-subtitle {
        font-size: 12px;
    }
    
    .user-card-role {
        font-size: 13px;
    }
    
    .user-card-username {
        font-size: 12px;
    }
    
    .btn {
        padding: 14px 20px;
        font-size: 16px;
    }
}
