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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

header {
    background: linear-gradient(135deg, #2c3e50, #34495e);
    color: white;
    padding: 2rem;
    text-align: center;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

.main-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    padding: 2rem;
}

@media (max-width: 768px) {
    .main-content {
        grid-template-columns: 1fr;
    }
}

.form-section, .users-section {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 10px;
    border: 1px solid #e9ecef;
}

h2 {
    color: #2c3e50;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

/* Enhanced Form Group with Validation Support */
.form-group {
    position: relative;
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #495057;
}

input {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e9ecef;
    border-radius: 5px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

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

/* Validation States */
input.success {
    border-color: #28a745;
    background-color: #f8fff9;
}

input.success:focus {
    border-color: #28a745;
    box-shadow: 0 0 0 3px rgba(40, 167, 69, 0.1);
}

input.error {
    border-color: #dc3545;
    background-color: #fff5f5;
}

input.error:focus {
    border-color: #dc3545;
    box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.1);
}

/* Error Message Styling */
.error-message {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.5rem;
    display: block;
    font-weight: 500;
    padding-left: 0.25rem;
}

/* Password Strength Indicator */
.password-strength {
    margin-top: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
}

.strength-weak { 
    color: #dc3545; 
}

.strength-medium { 
    color: #ffc107; 
}

.strength-strong { 
    color: #28a745; 
}

/* Button Styles */
button {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 5px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

button:active {
    transform: translateY(0);
}

/* Loading State for Buttons */
button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

.loading {
    position: relative;
    color: transparent;
}

.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-right-color: transparent;
    animation: spin 1s linear infinite;
}

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

#loadUsers {
    background: linear-gradient(135deg, #11998e, #38ef7d);
    margin-bottom: 1rem;
}

#loadUsers:hover {
    background: linear-gradient(135deg, #0f8a7f, #2fd56a);
}

/* Users List Styles */
.users-list {
    max-height: 400px;
    overflow-y: auto;
    margin-top: 1rem;
}

.user-item {
    background: white;
    padding: 1rem;
    margin-bottom: 0.75rem;
    border-radius: 8px;
    border-left: 4px solid #667eea;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.user-item:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.user-item strong {
    color: #2c3e50;
}

.no-users {
    text-align: center;
    color: #6c757d;
    font-style: italic;
    padding: 2rem;
    background: white;
    border-radius: 8px;
    border: 2px dashed #dee2e6;
}

/* Message Styles */
.message {
    padding: 1rem 1.5rem;
    margin: 1rem 2rem;
    border-radius: 8px;
    text-align: center;
    font-weight: 600;
    line-height: 1.5;
    transition: all 0.3s ease;
}

.message.success {
    background: linear-gradient(135deg, #d4edda, #c3e6cb);
    color: #155724;
    border: 1px solid #b1dfbb;
    box-shadow: 0 2px 8px rgba(21, 87, 36, 0.1);
}

.message.error {
    background: linear-gradient(135deg, #f8d7da, #f5c6cb);
    color: #721c24;
    border: 1px solid #f1b0b7;
    box-shadow: 0 2px 8px rgba(114, 28, 36, 0.1);
}

.message.hidden {
    display: none;
}

/* Form Placeholder Styling */
input::placeholder {
    color: #6c757d;
    opacity: 0.7;
}

/* Focus states for accessibility */
input:focus-visible {
    outline: 2px solid #667eea;
    outline-offset: 2px;
}

button:focus-visible {
    outline: 2px solid #2c3e50;
    outline-offset: 2px;
}

/* Scrollbar styling for users list */
.users-list::-webkit-scrollbar {
    width: 6px;
}

.users-list::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.users-list::-webkit-scrollbar-thumb {
    background: #667eea;
    border-radius: 3px;
}

.users-list::-webkit-scrollbar-thumb:hover {
    background: #5a6fd8;
}

/* Success checkmark animation */
@keyframes checkmark {
    0% {
        transform: scale(0);
        opacity: 0;
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.success-check {
    animation: checkmark 0.5s ease-in-out;
}

/* Responsive improvements */
@media (max-width: 480px) {
    body {
        padding: 10px;
    }
    
    .container {
        border-radius: 10px;
    }
    
    header {
        padding: 1.5rem 1rem;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .main-content {
        padding: 1rem;
        gap: 1rem;
    }
    
    .form-section, .users-section {
        padding: 1rem;
    }
    
    .message {
        margin: 1rem;
        padding: 0.75rem 1rem;
    }
}

/* Print styles */
@media print {
    body {
        background: white !important;
        padding: 0;
    }
    
    .container {
        box-shadow: none;
        border-radius: 0;
    }
    
    button {
        display: none;
    }
}