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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 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;
    justify-content: center;
    align-items: center;
}

/* Header Styles */
.header {
    text-align: center;
    margin-bottom: 40px;
}

.logo {
    background: white;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.logo-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.logo h1 {
    font-size: 2.5rem;
    color: #333;
    margin-bottom: 10px;
}

.logo p {
    color: #666;
    font-size: 1.1rem;
}

/* Portal Selection */
.portal-selection {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    width: 100%;
    max-width: 800px;
}

.portal-card {
    background: white;
    padding: 40px 30px;
    border-radius: 15px;
    text-decoration: none;
    color: #333;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    text-align: center;
}

.portal-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.portal-card.admin {
    border-top: 4px solid #3b82f6;
}

.portal-card.student {
    border-top: 4px solid #10b981;
}

.portal-icon {
    font-size: 48px;
    margin-bottom: 20px;
}

.portal-card h2 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: #333;
}

.portal-card p {
    color: #666;
    font-size: 1rem;
}

/* Footer */
.footer {
    margin-top: 40px;
    text-align: center;
}

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

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

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

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #3b82f6;
}

.form-group input:disabled,
.form-group select:disabled {
    background-color: #f9fafb;
    color: #9ca3af;
    cursor: not-allowed;
}

/* Button Styles */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-primary {
    background-color: #3b82f6;
    color: white;
}

.btn-primary:hover:not(:disabled) {
    background-color: #2563eb;
}

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

.btn-secondary:hover:not(:disabled) {
    background-color: #4b5563;
}

.btn-success {
    background-color: #10b981;
    color: white;
}

.btn-success:hover:not(:disabled) {
    background-color: #059669;
}

.btn-danger {
    background-color: #ef4444;
    color: white;
}

.btn-danger:hover:not(:disabled) {
    background-color: #dc2626;
}

.btn-warning {
    background-color: #f59e0b;
    color: white;
}

.btn-warning:hover:not(:disabled) {
    background-color: #d97706;
}

/* Error Message */
.error-message {
    background-color: #fef2f2;
    color: #dc2626;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #fecaca;
    margin-bottom: 16px;
    font-size: 14px;
}

/* Success Message */
.success-message {
    background-color: #f0fdf4;
    color: #16a34a;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #bbf7d0;
    margin-bottom: 16px;
    font-size: 14px;
}

/* Loading Spinner */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #3b82f6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    .portal-selection {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .portal-card {
        padding: 30px 20px;
    }
    
    .logo h1 {
        font-size: 2rem;
    }
    
    .portal-icon {
        font-size: 40px;
    }
}

@media (max-width: 480px) {
    .logo {
        padding: 20px;
    }
    
    .logo h1 {
        font-size: 1.8rem;
    }
    
    .portal-card {
        padding: 25px 15px;
    }
    
    .portal-card h2 {
        font-size: 1.3rem;
    }
}