/* Modern Minimal Theme */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    overflow-x: hidden;
}

:root {
    --primary-color: #000000;
    --secondary-color: #ffffff;
    --accent-color: #667eea;
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --text-color: #1d1d1f;
    --text-secondary: #86868b;
    --background-light: #f5f5f7;
    --border-color: #d2d2d7;
    --card-shadow: 0 2px 20px rgba(0, 0, 0, 0.04);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", sans-serif;
    color: var(--text-color);
    background-color: #0a0a0a;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

/* Navigation */
.navbar {
    background-color: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: none;
    padding: 1rem 0;
    margin: 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar .container {
    padding-left: 2rem;
    padding-right: 2rem;
}

/* Remove any gaps between navbar and content */
main, .container-fluid, .hero-section {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* Ensure sections connect seamlessly */
section {
    margin: 0 !important;
    display: block;
}

/* Container adjustments */
.container {
    max-width: 100%;
    padding: 0;
    margin: 0;
}

.navbar + * {
    margin-top: 0 !important;
}

/* AUXYON Brand Styling */
.navbar-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none !important;
    color: #ffffff !important;
}

.brand-icon {
    font-size: 1.2rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 8px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.brand-text {
    font-size: 1.2rem;
    font-weight: 800;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.5px;
}

.brand-subtitle {
    font-size: 0.65rem;
    color: rgba(255, 255, 255, 0.5);
    font-weight: 400;
    margin-left: 4px;
}

.navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.8) !important;
    font-weight: 500;
    transition: var(--transition);
    padding: 0.5rem 1rem !important;
    border-radius: 8px;
}

.navbar-nav .nav-link:hover {
    color: #ffffff !important;
    background-color: rgba(255, 255, 255, 0.1);
}

/* Navbar Get Started Button */
.navbar-nav .btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 50px;
    padding: 8px 20px;
    font-size: 0.9rem;
    font-weight: 600;
    color: #ffffff;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.navbar-nav .btn-primary:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
    color: #ffffff;
}

.navbar-nav .btn-primary:active {
    transform: translateY(0);
}

.card {
    background: #fff;
    border-radius: 16px;
    border: none;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(8px);
}

.hover-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* Search Bar Styling */
.search-wrapper {
    position: relative;
}

.search-wrapper .form-control {
    padding-left: 3rem;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(8px);
    height: 54px;
    font-size: 1rem;
}

.search-wrapper .form-control:focus {
    border-color: rgba(0, 0, 0, 0.2);
    box-shadow: 0 0 0 4px rgba(0, 0, 0, 0.03);
}

/* Select Styling */
.form-select {
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(8px);
    height: 54px;
    padding: 0 1rem;
    font-size: 1rem;
}

.form-select:focus {
    border-color: rgba(0, 0, 0, 0.2);
    box-shadow: 0 0 0 4px rgba(0, 0, 0, 0.03);
}

/* Badge Styling */
.badge {
    padding: 0.5rem 1rem;
    font-weight: 500;
    font-size: 0.875rem;
    border-radius: 8px;
}

.badge.bg-light {
    background-color: rgba(0, 0, 0, 0.05) !important;
    color: rgba(0, 0, 0, 0.7) !important;
}

/* Tab Content Styling */
.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* Button Styling */
.btn {
    padding: 0.75rem 1.5rem;
    border-radius: 12px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-dark, 
.btn-outline-dark {
    border-width: 1.5px;
}

.btn-dark:hover {
    background-color: #000;
    transform: translateY(-1px);
}

.btn-outline-dark:hover {
    background-color: #000;
    transform: translateY(-1px);
}

/* Toast Styling */
.toast {
    border-radius: 12px;
    backdrop-filter: blur(8px);
    z-index: 1051;
}

/* Hero & Features */
.hero-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, #1a1a1a 100%);
    padding: 8rem 0;
    margin: 0;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 50%, rgba(255,255,255,0.1) 0%, transparent 80%);
}

.feature-icon {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    background: rgba(0, 0, 0, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    transition: transform 0.3s ease;
}

.feature-icon:hover {
    transform: scale(1.05);
}

.feature-icon i {
    color: var(--primary-color);
    font-size: 1.5rem;
}

/* Statistics Section */
.stats-section {
    background-color: var(--background-light);
    padding: 4rem 0;
}

.stats-item {
    text-align: center;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(8px);
    border-radius: 16px;
    transition: transform 0.3s ease;
}

.stats-item:hover {
    transform: translateY(-4px);
}

.stats-number {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, var(--primary-color) 0%, #1a1a1a 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Custom Button Styles */
.btn-icon {
    padding: 0.5rem;
    line-height: 1;
    border: none;
    background: none;
    transition: transform 0.2s ease;
}

.btn-icon:hover {
    transform: scale(1.1);
}

.btn-icon .fas {
    font-size: 1.1rem;
    opacity: 0.7;
    transition: opacity 0.2s ease;
}

.btn-icon:hover .fas {
    opacity: 1;
}

/* Loading States */
.btn-loading {
    position: relative;
    pointer-events: none;
    opacity: 0.8;
}

.btn-loading:after {
    content: '';
    width: 1rem;
    height: 1rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s linear infinite;
    position: absolute;
    top: 50%;
    right: 1rem;
    transform: translateY(-50%);
}

@keyframes spin {
    to { transform: translateY(-50%) rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 768px) {
    .search-wrapper .form-control,
    .form-select {
        height: 48px;
        font-size: 0.9rem;
    }
    
    .hero-section {
        padding: 4rem 0;
    }
    
    .stats-number {
        font-size: 2.5rem;
    }
    
    .display-3 {
        font-size: 2.5rem;
    }
    
    .display-4 {
        font-size: 2rem;
    }
    
    .btn {
        padding: 0.625rem 1.25rem;
        font-size: 0.9rem;
    }
    .lead {
        font-size: 1.1rem;
    }
    
    .feature-icon {
        width: 60px;
        height: 60px;
    }
    
    .card {
        margin-bottom: 1rem;
    }
}

/* Admin Panel Styles */
.admin-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: var(--card-shadow);
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 25px rgba(0, 0, 0, 0.08);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--accent-color), #0066ff);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
}

.stat-info h3 {
    margin: 0;
    font-size: 2rem;
    font-weight: 600;
    color: var(--text-color);
}

.stat-info p {
    margin: 0;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.admin-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    border-bottom: 2px solid var(--background-light);
}

.tab-button {
    background: none;
    border: none;
    padding: 1rem 1.5rem;
    cursor: pointer;
    font-size: 1rem;
    color: var(--text-secondary);
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-radius: 8px 8px 0 0;
    position: relative;
}

.tab-button.active {
    color: var(--accent-color);
    background: white;
    border-bottom: 2px solid var(--accent-color);
}

.tab-button:hover:not(.active) {
    color: var(--text-color);
    background: var(--background-light);
}

.tab-content {
    display: none;
    background: white;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: var(--card-shadow);
}

.tab-content.active {
    display: block;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.section-header h2 {
    margin: 0;
    color: var(--text-color);
    font-size: 1.5rem;
    font-weight: 600;
}

.table-container {
    overflow-x: auto;
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

.admin-table thead {
    background: var(--background-light);
}

.admin-table th,
.admin-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.admin-table th {
    font-weight: 600;
    color: var(--text-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.admin-table td {
    color: var(--text-secondary);
    vertical-align: middle;
}

.admin-table tr:hover {
    background-color: var(--background-light);
}

.action-buttons {
    display: flex;
    gap: 0.5rem;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.btn-primary {
    background: var(--accent-color);
    color: white;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
}

.btn-primary:hover {
    background: #0052a3;
    transform: translateY(-1px);
}

.btn-secondary {
    background: var(--background-light);
    color: var(--text-color);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--border-color);
}

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

.btn-danger:hover {
    background: #d70015;
}

.btn-edit {
    background: #34c759;
    color: white;
}

.btn-edit:hover {
    background: #28a745;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    border-radius: 16px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    margin: 0;
    color: var(--text-color);
    font-size: 1.25rem;
    font-weight: 600;
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-secondary);
    padding: 0;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.close-btn:hover {
    background: var(--background-light);
    color: var(--text-color);
}

.modal-body {
    padding: 2rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-color);
    font-weight: 500;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    transition: var(--transition);
    background: white;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    padding: 1.5rem 2rem;
    border-top: 1px solid var(--border-color);
}

/* Role badges */
.role-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.role-admin {
    background: #ff3b30;
    color: white;
}

.role-teacher {
    background: #007aff;
    color: white;
}

.role-student {
    background: #34c759;
    color: white;
}

/* Footer Section */
.footer-section {
    background: #0a0a0a;
    padding: 2rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: auto;
}

.footer-section .container {
    padding-left: 2rem;
    padding-right: 2rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-icon {
    font-size: 1.2rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 8px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.footer-text {
    font-size: 1.2rem;
    font-weight: 800;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.5px;
}

.footer-subtitle {
    font-size: 0.65rem;
    color: rgba(255, 255, 255, 0.5);
    font-weight: 400;
    margin-left: 4px;
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .navbar .container,
    .footer-section .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    .admin-container {
        padding: 1rem;
    }
    
    .admin-stats {
        grid-template-columns: 1fr;
    }
    
    .section-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .modal-content {
        margin: 10% auto;
        width: 95%;
    }
    
    .table-container {
        font-size: 0.9rem;
    }
    
    .admin-table th,
    .admin-table td {
        padding: 0.75rem 0.5rem;
    }
    
    .action-buttons {
        flex-direction: column;
    }
}