:root {
    --primary: #4361ee;
    --secondary: #3f37c9;
    --accent: #f72585;
    --bg-light: #f8f9fa;
    --text-dark: #2b2d42;
    --text-grey: #8d99ae;
    --white: #ffffff;
    --sidebar-w: 250px;
    --right-w: 280px;
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Poppins', sans-serif; }

body { background-color: var(--bg-light); color: var(--text-dark); height: 100vh; overflow: hidden; }

/* Layout Grid 3 Kolom */
.app-container {
    display: grid;
    grid-template-columns: var(--sidebar-w) 1fr var(--right-w);
    height: 100%;
}

/* Sidebar Kiri */
.sidebar-left {
    background: var(--white);
    padding: 30px 20px;
    border-right: 1px solid #eee;
    display: flex; flex-direction: column;
}

.logo { margin-bottom: 40px; font-size: 1.1rem; color: var(--primary); }
.secondary-text { color: #f7b801; }

.nav-links li {
    list-style: none; padding: 12px 15px;
    margin-bottom: 10px; border-radius: 12px;
    cursor: pointer; color: var(--text-grey);
    transition: 0.3s; font-weight: 500; display: flex; align-items: center; gap: 15px;
}

.nav-links li:hover, .nav-links li.active {
    background: rgba(67, 97, 238, 0.1); color: var(--primary);
}

/* Konten Utama */
.main-content { padding: 40px; overflow-y: auto; }
.text-blue { color: var(--primary); }
.subtitle { color: var(--text-grey); font-size: 0.9rem; margin-top: 5px; }

/* Animasi Fade In */
.content-section { display: none; animation: fadeIn 0.4s ease; }
.active-section { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* Banner */
.banner {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white; padding: 30px; border-radius: 20px;
    display: flex; justify-content: space-between; align-items: center;
    margin-top: 30px; box-shadow: 0 10px 20px rgba(67, 97, 238, 0.3);
}
.banner-icon { font-size: 3rem; opacity: 0.8; }

/* Grid Kartu Materi */
.course-cards-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 25px; margin-top: 30px;
}

.course-card {
    background: var(--white); padding: 25px; border-radius: 16px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03); transition: 0.3s; border: 1px solid transparent;
}
.course-card:hover { transform: translateY(-5px); border-color: var(--primary); }

.card-icon {
    width: 50px; height: 50px; border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.5rem; margin-bottom: 15px;
}
.math { background: #e0fbf0; color: #2ecc71; }
.lang { background: #fff4e6; color: #ff9f43; }
.sci { background: #e3f2fd; color: #48dbfb; }
.art { background: #fce4ec; color: #f06292; }

/* Progress Bar */
.progress-bg { background: #f1f2f6; height: 8px; border-radius: 4px; overflow: hidden; margin: 15px 0 8px; }
.progress-fill { height: 100%; background: var(--primary); border-radius: 4px; }
.progress-text { font-size: 0.8rem; color: var(--text-grey); font-weight: 600; }

/* Sidebar Kanan */
.sidebar-right { background: var(--white); border-left: 1px solid #eee; padding: 30px; text-align: center; }
.avatar { font-size: 3rem; color: var(--primary); margin-bottom: 15px; }
.badge { background: #f1f2f6; padding: 5px 12px; border-radius: 20px; font-size: 0.8rem; font-weight: 600; }
.stats-box { display: flex; justify-content: space-around; margin-top: 30px; background: var(--bg-light); padding: 15px; border-radius: 15px; }
.stat { display: flex; flex-direction: column; }
.stat .value { font-weight: 700; font-size: 1.1rem; }
.stat .label { font-size: 0.75rem; color: var(--text-grey); }

/* Settings Card */
.settings-grid { display: grid; gap: 20px; margin-top: 20px; }
.setting-card {
    display: flex; align-items: center; gap: 15px;
    background: white; padding: 20px; border-radius: 15px;
    cursor: pointer; box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}
.setting-card:hover { background: #f8f9fa; }
.icon-box { width: 45px; height: 45px; display: flex; align-items: center; justify-content: center; border-radius: 10px; color: white; }
.bg-blue { background: var(--primary); }
.arrow { margin-left: auto; color: #ccc; }

/* --- RESPONSIF (MOBILE) --- */
@media (max-width: 900px) {
    .app-container { grid-template-columns: 1fr; grid-template-rows: auto 1fr; }
    .sidebar-left { 
        flex-direction: row; align-items: center; justify-content: space-between;
        padding: 15px 20px; border-bottom: 1px solid #eee; border-right: none;
    }
    .nav-links { display: flex; gap: 10px; }
    .nav-links li span { display: none; } /* Sembunyikan teks di mobile */
    .sidebar-right { display: none; } /* Sembunyikan sidebar kanan di mobile */
    .logo { margin-bottom: 0; }
}