/* 
   Kyuliz Cram School - Minimal Black + Blue Design
*/

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    /* Colors - Minimal Black + Blue */
    --bg-body: #1a1a1a;
    --bg-surface: #2a2a2a;

    --text-primary: #ffffff;
    --text-secondary: #cccccc;
    --text-muted: #999999;

    --accent: #3b82f6;
    --border-color: #333333;

    /* Typography */
    --font-main: 'Inter', sans-serif;

    /* Spacing */
    --section-padding: 120px;
    --container-max: 1000px;

    /* Transitions */
    --transition-speed: 0.2s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: var(--font-main);
}

body {
    background-color: var(--bg-body);
    color: var(--text-primary);
    line-height: 1.8;
    min-height: 100vh;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    display: flex;
}

h1,
h2,
h3,
h4 {
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

h1 {
    font-size: clamp(2rem, 4vw, 3rem);
}

h2 {
    font-size: clamp(1.5rem, 3vw, 2rem);
}

h3 {
    font-size: 1.25rem;
}

/* Layout */
.sidebar {
    width: 260px;
    background: var(--bg-surface);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.sidebar-header {
    padding: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-header h2 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.sidebar-header p {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.nav-list {
    list-style: none;
    padding: 1rem;
    flex: 1;
}

.nav-item {
    padding: 0.75rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition-speed);
    margin-bottom: 0.25rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}

.nav-item.active {
    background: var(--accent);
    color: white;
}

.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

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

.user-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.profile-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.view-panel {
    padding: 2rem;
    display: none;
}

.view-panel.active {
    display: block;
}

/* Cards */
.card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 2rem;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.stats-grid .card {
    text-align: center;
    padding: 1.5rem;
}

.stats-grid h3 {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 600;
    color: var(--accent);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 32px;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition-speed);
    border: none;
    text-align: center;
    font-size: 0.95rem;
}

.btn-primary {
    background-color: var(--accent);
    color: white;
}

.btn-primary:hover {
    opacity: 0.85;
}

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

.btn-secondary:hover {
    background-color: #333333;
}

/* Panel Header */
.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

/* Tables */
.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table thead {
    background: rgba(255, 255, 255, 0.03);
}

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

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

.data-table td {
    font-size: 0.9rem;
}

.data-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.02);
}

/* Form Inputs */
.input-group {
    margin-bottom: 1.5rem;
}

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

.input-group input,
.input-group select,
.input-group textarea {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-body);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: white;
    outline: none;
    transition: var(--transition-speed);
    font-size: 0.95rem;
}

.input-group input:focus,
.input-group select:focus,
.input-group textarea:focus {
    border-color: var(--accent);
}

/* Status Indicator */
.status-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid var(--accent);
    border-radius: 8px;
    margin-top: 1rem;
}

.status-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #666;
}

.status-dot.active {
    background: #10b981;
    box-shadow: 0 0 8px #10b981;
}

/* Classes Grid */
.classes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

/* Modal */
.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.modal-overlay.active {
    display: flex;
}

.modal-content {
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.modal-actions button {
    flex: 1;
}

/* Responsive */
@media (max-width: 768px) {
    body {
        flex-direction: column;
    }

    .sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }
}