/* Reset and base styles */
* {
    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;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header */
header {
    text-align: center;
    margin-bottom: 2rem;
}

.logo h1 {
    color: white;
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.logo p {
    color: rgba(255,255,255,0.9);
    font-size: 1.1rem;
}

/* Main content */
main {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    overflow: hidden;
    max-width: 600px;
    width: 100%;
    margin: 2rem 0;
}

.card-header {
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    color: white;
    padding: 2rem;
    text-align: center;
}

.card-header h2 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}

.card-header p {
    opacity: 0.9;
    font-size: 1rem;
}

.card-body {
    padding: 2rem;
}

/* Features section */
.features {
    margin-bottom: 2rem;
}

.feature {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.feature .icon {
    font-size: 1.5rem;
    margin-right: 1rem;
    min-width: 40px;
}

.feature h3 {
    color: #333;
    margin-bottom: 0.25rem;
    font-size: 1.1rem;
}

.feature p {
    color: #666;
    font-size: 0.9rem;
}

/* Auth sections */
.section {
    display: none;
}

.section.active {
    display: block;
}

.auth-section h3 {
    color: #333;
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.auth-section p {
    color: #666;
    margin-bottom: 1.5rem;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 0.5rem 0;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

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

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
    transform: translateY(-1px);
}

.btn-icon {
    margin-right: 0.5rem;
    font-size: 1.1rem;
}

/* Permissions */
.permissions {
    margin-top: 2rem;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.permissions h4 {
    color: #333;
    margin-bottom: 1rem;
    font-size: 1rem;
}

.permissions ul {
    list-style: none;
}

.permissions li {
    color: #28a745;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

/* Success message */
.success-message {
    text-align: center;
    margin-bottom: 2rem;
}

.success-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 1rem;
}

.success-message h3 {
    color: #28a745;
    margin-bottom: 1rem;
}

.user-info {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 6px;
    padding: 1rem;
    margin: 1rem 0;
    color: #155724;
}

/* Next steps */
.next-steps {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.next-steps h4 {
    color: #333;
    margin-bottom: 1rem;
}

.next-steps ol {
    color: #666;
    padding-left: 1.5rem;
}

.next-steps li {
    margin-bottom: 0.5rem;
}

/* Error message */
.error-message {
    text-align: center;
    margin-bottom: 2rem;
}

.error-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 1rem;
}

.error-message h3 {
    color: #dc3545;
    margin-bottom: 1rem;
}

#error-text {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 6px;
    padding: 1rem;
    color: #721c24;
}

/* Footer */
footer {
    text-align: center;
    padding: 1rem 0;
    color: rgba(255,255,255,0.8);
    font-size: 0.9rem;
}

footer a {
    color: rgba(255,255,255,0.9);
    text-decoration: none;
}

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

/* Loading state */
.btn.loading {
    opacity: 0.7;
    cursor: not-allowed;
    pointer-events: none;
}

.btn.loading::after {
    content: "";
    width: 16px;
    height: 16px;
    margin-left: 8px;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Responsive design */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .logo h1 {
        font-size: 2rem;
    }
    
    .card-header, .card-body {
        padding: 1.5rem;
    }
    
    .feature {
        flex-direction: column;
        text-align: center;
    }
    
    .feature .icon {
        margin-right: 0;
        margin-bottom: 0.5rem;
    }
}

@media (max-width: 480px) {
    .logo h1 {
        font-size: 1.5rem;
    }
    
    .card-header, .card-body {
        padding: 1rem;
    }
}
