:root {
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --bg-dark: #0f172a;
    --card-bg: rgba(30, 41, 59, 0.7);
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --border: rgba(255, 255, 255, 0.1);

    /* Seat Colors */
    --color-vacant: #ef4444;
    /* Red */
    --color-full: #22c55e;
    /* Green */
    --color-morning: #3b82f6;
    /* Blue */
    --color-evening: #eab308;
    /* Yellow */

    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', 'Inter', sans-serif;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    min-height: 100vh;
    overflow-x: hidden;
}

/* Glassmorphism Background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 20% 30%, rgba(99, 102, 241, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(239, 68, 68, 0.05) 0%, transparent 50%);
    z-index: -1;
}

/* Navigation */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, #fff 0%, #94a3b8 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text-main);
}

/* Main Content */
main {
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

h1 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

/* Seat Grid */
.seat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1.5rem;
}

.seat-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 1rem;
    padding: 1.5rem;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    text-align: center;
}

.seat-card:hover {
    transform: translateY(-5px);
    background: rgba(30, 41, 59, 0.9);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3);
}

.seat-card .seat-icon {
    font-size: 2rem;
    margin-bottom: 1rem;
    opacity: 0.8;
}

.seat-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.seat-number {
    font-weight: 800;
    font-size: 1.5rem;
}

.seat-status {
    font-size: 0.875rem;
    font-weight: 600;
    padding: 0.25rem 0.75rem;
    border-radius: 2rem;
    display: inline-block;
    margin-top: 0.5rem;
}

/* Seat States */
.seat-card.vacant {
    border-top: 4px solid var(--color-vacant);
}

.seat-card.vacant .seat-status {
    background: rgba(239, 68, 68, 0.1);
    color: var(--color-vacant);
}

.seat-card.full {
    border-top: 4px solid var(--color-full);
}

.seat-card.full .seat-status {
    background: rgba(34, 197, 94, 0.1);
    color: var(--color-full);
}

.seat-card.morning {
    border-top: 4px solid var(--color-morning);
}

.seat-card.morning .seat-status {
    background: rgba(59, 130, 246, 0.1);
    color: var(--color-morning);
}

.seat-card.evening {
    border-top: 4px solid var(--color-evening);
}

.seat-card.evening .seat-status {
    background: rgba(234, 179, 8, 0.1);
    color: var(--color-evening);
}

/* Buttons */
.btn {
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary {
    background: var(--primary);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-hover);
}

.mobile-only {
    display: none;
}

.desktop-only {
    display: inline-flex;
}

.mobile-toggle {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
    color: var(--text-main);
}

nav {
    position: relative;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-links {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(15, 23, 42, 0.95);
        padding: 1rem;
        border-bottom: 1px solid var(--border);
        backdrop-filter: blur(20px);
    }

    .nav-links.show {
        display: flex;
        gap: 1rem;
    }

    .mobile-toggle {
        display: block !important;
        cursor: pointer;
        font-size: 1.5rem;
    }

    .seat-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 0.75rem;
    }

    /* Table responsiveness */
    .table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin-top: 1rem;
    }

    table {
        min-width: 600px;
    }

    main {
        padding: 1rem;
    }

    .mobile-only {
        display: block;
    }

    .desktop-only {
        display: none;
    }
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    padding: 1rem;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: 1.5rem;
    max-width: 500px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid var(--border);
}

.modal-header h2 {
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 2rem;
    cursor: pointer;
    line-height: 1;
}

.modal-close:hover {
    color: var(--text-main);
}

.modal-body {
    padding: 1.5rem;
}

.modal-body ul {
    list-style: none;
    margin: 1rem 0;
}

.modal-body li {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border);
}

.seat-status-large {
    font-size: 1.25rem;
    font-weight: 700;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    display: inline-block;
    margin-bottom: 1rem;
}

.seat-status-large.vacant {
    background: rgba(239, 68, 68, 0.1);
    color: var(--color-vacant);
}

.seat-status-large.full {
    background: rgba(34, 197, 94, 0.1);
    color: var(--color-full);
}

.seat-status-large.morning {
    background: rgba(59, 130, 246, 0.1);
    color: var(--color-morning);
}

.seat-status-large.evening {
    background: rgba(234, 179, 8, 0.1);
    color: var(--color-evening);
}

/* Stats */
.stats-overview {
    display: flex;
    gap: 1.5rem;
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-size: 1.5rem;
    font-weight: 800;
}

.student-name {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}