:root {
    /* --- Palet merek: diambil langsung dari logo Islamic Bilingual School Bandung --- */
    --brand-navy: #3b5284;        /* biru tua logo - warna utama */
    --brand-navy-dark: #2c3e66;
    --brand-navy-soft: #dce3f0;   /* latar badge, avatar, tag */
    --brand-navy-light: #edf1f8;  /* latar menu aktif & hover */
    --brand-cyan: #0791b8;        /* biru muda logo - warna aksen */
    --brand-cyan-dark: #06678a;
    --brand-cyan-soft: #d5eaf3;
    --brand-cyan-light: #eff8fb;
    --brand-gray: #b8b8b8;        /* abu-abu logo */
    --brand-steel: #6b7899;       /* turunan abu-abu, cukup gelap untuk teks */
    --brand-steel-dark: #55627f;
    --brand-steel-soft: #e6e9f1;

    /* Peran warna yang dipakai di seluruh tema.
       Catatan: nama kelas utilitas lama (-indigo, -purple, -blue) dipertahankan
       agar markup tidak perlu diubah, tetapi nilainya kini mengikuti palet merek:
       indigo -> navy, purple -> steel, blue -> cyan. */
    --primary: var(--brand-navy);
    --primary-hover: var(--brand-navy-dark);
    --primary-light: var(--brand-navy-light);
    --accent: var(--brand-cyan);
    --accent-hover: var(--brand-cyan-dark);
    --accent-light: var(--brand-cyan-light);

    --bg-body: #f6f8fb;
    --bg-sidebar: #ffffff;
    --bg-card: #ffffff;
    --text-main: #16233d;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
    --radius: 20px;
}

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

html, body {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    font-family: 'Plus Jakarta Sans', sans-serif;
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.5;
    -webkit-tap-highlight-color: transparent;
}

.app-layout {
    display: flex;
    min-height: 100vh;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    position: relative;
}

/* Off-Canvas Backdrop */
.sidebar-overlay {
    display: none; position: fixed; inset: 0;
    background: rgba(15, 23, 42, 0.5); backdrop-filter: blur(4px);
    z-index: 99; opacity: 0; transition: opacity 0.3s ease;
}
.sidebar-overlay.active { display: block; opacity: 1; }

/* Sidebar */
.sidebar {
    width: 260px; background: var(--bg-sidebar); border-right: 1px solid var(--border-color);
    display: flex; flex-direction: column; padding: 24px 16px; position: fixed; height: 100vh; z-index: 100;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), width 0.3s ease;
}
/* 100dvh mengikuti tinggi yang BENAR-BENAR terlihat di peramban HP: dengan
   100vh saja, bilah alamat Safari/Chrome menutupi bagian bawah sidebar dan
   kartu pengguna tidak pernah bisa dijangkau. Ditulis setelah baris di atas
   agar peramban lama tetap memakai 100vh. */
.sidebar { height: 100dvh; }

.sidebar-brand { display: flex; align-items: center; justify-content: space-between; margin-bottom: 32px; padding: 0 4px; }
.brand-brand-wrapper { display: flex; align-items: center; gap: 12px; }
.brand-icon {
    width: 40px; height: 40px; background: linear-gradient(135deg, var(--brand-navy), var(--brand-cyan));
    color: white; font-weight: 800; font-size: 20px; border-radius: 12px;
    display: flex; align-items: center; justify-content: center; flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(59, 82, 132, 0.28);
}
.brand-text { margin-left: 2px; flex-grow: 1; }
.brand-title { display: block; font-size: 17px; font-weight: 800; color: var(--text-main); white-space: nowrap; }
.brand-subtitle { display: block; font-size: 11px; color: var(--text-muted); white-space: nowrap; }

/* Brand: logo Islamic Bilingual School Bandung */
.brand-brand-wrapper { text-decoration: none; color: inherit; }
.brand-stack { flex-direction: column; align-items: flex-start; gap: 6px; width: 100%; }
.brand-logo-full { width: 100%; max-width: 186px; height: auto; display: block; }
.brand-logo-mark { width: 40px; height: 40px; object-fit: contain; display: none; }
.brand-app-label { letter-spacing: 0.02em; }
.mobile-brand-logo { width: 28px; height: 28px; object-fit: contain; flex-shrink: 0; }

/* Menu tumbuh seiring modul bertambah dan sekarang lebih tinggi daripada
   layar. `flex-grow: 1` saja tidak cukup: item flex punya `min-height: auto`,
   jadi nav menolak menyusut di bawah tinggi isinya — menu meluber keluar
   sidebar dan kartu pengguna di bawahnya ikut terdorong hilang. `min-height: 0`
   mengizinkannya menyusut, barulah `overflow-y` punya sesuatu untuk digulir.

   Padding + margin negatif 4px menyediakan ruang bagi cincin fokus keyboard,
   yang tanpa itu terpotong tepi area gulir. */
.sidebar-nav {
    display: flex; flex-direction: column; gap: 6px;
    flex-grow: 1; min-height: 0;
    overflow-y: auto; overflow-x: hidden;
    overscroll-behavior: contain;          /* gulir tidak merambat ke halaman */
    padding: 4px; margin: -4px;
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 transparent;
}
.sidebar-nav::-webkit-scrollbar { width: 6px; }
.sidebar-nav::-webkit-scrollbar-track { background: transparent; }
.sidebar-nav::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }
.sidebar-nav::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

/* Item menu tidak boleh ikut menyusut saat menu lebih tinggi daripada layar —
   tanpa ini flexbox meratakan tingginya dan label mulai terpotong. */
.sidebar-nav > * { flex-shrink: 0; }
.nav-item {
    display: flex; align-items: center; gap: 12px; padding: 10px 14px;
    border-radius: 12px; color: var(--text-muted); text-decoration: none;
    font-size: 14px; font-weight: 600; transition: all 0.2s ease;
}
.nav-item:hover, .nav-item.active { background: var(--primary-light); color: var(--primary); font-weight: 700; }
.nav-icon { width: 20px; height: 20px; flex-shrink: 0; }
.nav-label { white-space: nowrap; }

.nav-highlight { background: #ecfdf5; color: #047857; }
.nav-highlight-blue { background: var(--brand-cyan-light); color: var(--brand-cyan-dark); }
.nav-highlight-blue:hover { background: var(--brand-cyan-soft); }
.nav-tag { margin-left: auto; background: #10b981; color: white; font-size: 10px; font-weight: 800; padding: 2px 6px; border-radius: 8px; }
.tag-blue { background: var(--brand-cyan); }

.sidebar-footer { padding-top: 16px; border-top: 1px solid var(--border-color); }
.user-card { display: flex; align-items: center; gap: 12px; padding: 8px; }
.user-avatar { width: 36px; height: 36px; border-radius: 10px; background: #e2e8f0; color: #334155; font-weight: 700; font-size: 12px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.user-name { display: block; font-size: 13px; font-weight: 700; white-space: nowrap; }
.user-role { display: block; font-size: 11px; color: var(--text-muted); white-space: nowrap; }

/* Main Content */
.main-content {
    margin-left: 260px; flex-grow: 1; display: flex; flex-direction: column;
    width: calc(100% - 260px); max-width: calc(100% - 260px); min-width: 0;
    transition: margin-left 0.3s cubic-bezier(0.4, 0, 0.2, 1), width 0.3s ease;
}

/* Topbar */
.topbar {
    background: white; border-bottom: 1px solid var(--border-color);
    display: flex; flex-direction: column; gap: 10px; padding: 12px 24px;
    position: sticky; top: 0; z-index: 5; width: 100%; box-sizing: border-box;
}

.topbar-row-main {
    display: flex; align-items: center; justify-content: space-between; width: 100%; gap: 12px;
}

.topbar-left { display: flex; align-items: center; gap: 12px; min-width: 0; }
.btn-topbar-toggle {
    background: #f1f5f9; border: 1px solid var(--border-color); color: var(--text-main);
    padding: 8px; border-radius: 10px; cursor: pointer; display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.btn-topbar-toggle:hover { background: var(--primary-light); color: var(--primary); }

.mobile-brand { display: none; align-items: center; gap: 8px; flex-shrink: 0; }
.brand-icon-sm { width: 28px; height: 28px; background: linear-gradient(135deg, var(--brand-navy), var(--brand-cyan)); color: white; font-weight: 800; font-size: 14px; border-radius: 8px; display: flex; align-items: center; justify-content: center; }
.mobile-brand-title { font-size: 15px; font-weight: 800; color: var(--text-main); }

.topbar-row-search { width: 100%; }
.topbar-search { width: 100%; }
.topbar-search input { width: 100%; padding: 10px 16px; border-radius: 12px; border: 1px solid var(--border-color); background: #f8fafc; font-size: 13px; outline: none; box-sizing: border-box; }

.topbar-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.academic-badge { background: #f1f5f9; color: #475569; padding: 6px 12px; border-radius: 20px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.btn-icon { width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--border-color); background: white; cursor: pointer; display: flex; align-items: center; justify-content: center; position: relative; flex-shrink: 0; }
.notify-dot { position: absolute; top: 6px; right: 6px; width: 7px; height: 7px; background: #ef4444; border-radius: 50%; }

/* Dashboard Body */
.dashboard-body { padding: 28px; display: flex; flex-direction: column; gap: 24px; width: 100%; box-sizing: border-box; min-width: 0; }
.tab-content { display: none; width: 100%; }
.tab-content.active { display: block; }

/* Hero Welcome Card */
.hero-welcome-card {
    background: linear-gradient(135deg, #1e2c4d, #3b5284, #0b6f92);
    color: white; border-radius: var(--radius); padding: 28px 32px;
    display: flex; justify-content: space-between; align-items: center;
    box-shadow: 0 10px 25px -5px rgba(30, 44, 77, 0.28); margin-bottom: 20px;
}
.badge-tag-hero {
    background: rgba(255, 255, 255, 0.15); border: 1px solid rgba(255, 255, 255, 0.25);
    padding: 4px 12px; border-radius: 20px; font-size: 11px; font-weight: 700;
    display: inline-block; margin-bottom: 10px; text-transform: uppercase; tracking: 0.5px;
}
.hero-welcome-card h2 { font-size: 24px; font-weight: 800; margin-bottom: 6px; }
.hero-welcome-card p { font-size: 13px; opacity: 0.85; max-width: 650px; }

.date-chip {
    background: rgba(255, 255, 255, 0.1); border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 8px 16px; border-radius: 14px; font-size: 12px; font-weight: 700;
    display: flex; align-items: center; gap: 8px; white-space: nowrap;
}

/* Shortcuts Bar */
.shortcuts-bar { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 24px; }
.shortcut-btn {
    background: white; border: 1px solid var(--border-color); border-radius: 14px;
    padding: 12px 16px; display: flex; align-items: center; gap: 10px;
    font-size: 12px; font-weight: 700; color: var(--text-main); text-decoration: none;
    box-shadow: 0 2px 4px rgba(0,0,0,0.02); transition: all 0.2s ease; cursor: pointer;
}
.shortcut-btn:hover { transform: translateY(-2px); border-color: var(--primary); box-shadow: 0 4px 12px rgba(59, 82, 132, 0.14); }
.shortcut-icon { width: 32px; height: 32px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 14px; }
.icon-emerald { background: #dcfce7; }
.icon-indigo { background: var(--brand-navy-soft); }
.icon-purple { background: var(--brand-steel-soft); }
.icon-amber { background: #fef3c7; }

/* Metrics Cards Grid */
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; width: 100%; box-sizing: border-box; }
.stat-card {
    background: white; border: 1px solid var(--border-color); border-radius: var(--radius);
    padding: 22px; display: flex; flex-direction: column; gap: 10px; box-shadow: 0 4px 6px -1px rgba(0,0,0,0.03);
    transition: all 0.25s ease;
}
.stat-card:hover { transform: translateY(-3px); box-shadow: 0 10px 20px -5px rgba(0,0,0,0.08); }

.stat-header { display: flex; justify-content: space-between; align-items: center; }
.stat-icon-wrapper { width: 44px; height: 44px; border-radius: 14px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.bg-indigo-light { background: var(--brand-navy-soft); }
.bg-emerald-light { background: #dcfce7; }
.bg-teal-light { background: #ccfbf1; }
.bg-purple-light { background: var(--brand-steel-soft); }

.stat-title { font-size: 11px; font-weight: 800; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }
.stat-badge { font-size: 11px; font-weight: 800; padding: 2px 8px; border-radius: 8px; }
.badge-green { background: #dcfce7; color: #15803d; }
.badge-blue { background: var(--brand-cyan-soft); color: var(--brand-cyan-dark); }
.badge-purple { background: var(--brand-steel-soft); color: var(--brand-steel-dark); }

.stat-value { font-size: 32px; font-weight: 800; color: var(--text-main); line-height: 1; }
.stat-footer { font-size: 12px; color: var(--text-muted); display: flex; align-items: center; gap: 6px; }

.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.dot-indigo { background: var(--brand-navy); }
.dot-pink { background: #ec4899; }
.dot-emerald { background: #10b981; }

.text-emerald { color: #059669; }
.text-indigo { color: var(--brand-navy); }
.text-teal { color: #0d9488; }
.text-purple { color: var(--brand-steel); }
.text-amber { color: #d97706; }
.text-blue { color: var(--brand-cyan); }

/* Clock In / Out Terminal Card */
.clock-app-card {
    background: white; border: 1px solid var(--border-color); border-radius: var(--radius);
    padding: 28px; display: flex; justify-content: space-between; align-items: center;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.03); margin-top: 20px; gap: 24px; width: 100%; box-sizing: border-box;
}
.clock-left { flex: 1; min-width: 0; }
.clock-label { font-size: 11px; font-weight: 800; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }
.clock-display { font-size: 36px; font-weight: 800; color: var(--text-main); font-family: monospace; line-height: 1.1; }
.clock-ampm { font-size: 15px; font-weight: 700; color: var(--primary); }
.clock-date { font-size: 14px; font-weight: 700; color: var(--text-muted); margin-top: 4px; margin-bottom: 8px; }
.location-tag { font-size: 12px; color: var(--text-muted); }

.clock-right { flex: 1; display: flex; flex-direction: column; gap: 16px; align-items: flex-end; min-width: 0; }
.clock-status-box { background: #f8fafc; border: 1px solid var(--border-color); border-radius: 14px; padding: 12px 16px; width: 100%; text-align: right; box-sizing: border-box; }
.status-text { display: block; font-size: 13px; font-weight: 700; }
.status-sub { display: block; font-size: 11px; color: var(--text-muted); }
.clock-buttons-row { display: flex; gap: 12px; width: 100%; justify-content: flex-end; }

.btn-clock { padding: 14px 22px; border-radius: 14px; border: none; font-weight: 800; font-size: 13px; cursor: pointer; transition: all 0.2s ease; }
.btn-clock-in { background: #10b981; color: white; box-shadow: 0 4px 12px rgba(16, 185, 129, 0.25); }
.btn-clock-in:hover { background: #059669; }
.btn-clock-out { background: #ef4444; color: white; box-shadow: 0 4px 12px rgba(239, 68, 68, 0.25); }
.btn-clock-out:hover { background: #dc2626; }

/* Table User Cells & Avatars */
.user-cell { display: flex; align-items: center; gap: 10px; }
.avatar-sm { width: 34px; height: 34px; border-radius: 10px; background: var(--brand-navy-soft); color: var(--brand-navy-dark); font-weight: 800; font-size: 12px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.avatar-pink { background: #fce7f3; color: #be185d; }
.avatar-blue { background: var(--brand-cyan-soft); color: var(--brand-cyan-dark); }
.u-name { display: block; font-size: 13px; font-weight: 700; color: var(--text-main); }
.u-sub { display: block; font-size: 11px; color: var(--text-muted); }

.btn-sm { padding: 6px 12px; border-radius: 8px; border: 1px solid var(--border-color); background: white; font-size: 11px; font-weight: 700; color: var(--text-main); cursor: pointer; transition: all 0.2s; }
.btn-sm:hover { background: #f1f5f9; border-color: #cbd5e1; }
.btn-filter { background: #f8fafc; }

/* Parent Student Card */
.parent-student-card {
    background: white; border: 1px solid var(--border-color); border-radius: var(--radius);
    padding: 24px; display: flex; justify-content: space-between; align-items: center;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.03); margin-top: 20px; width: 100%; box-sizing: border-box;
}
.student-info-main { display: flex; align-items: center; gap: 16px; min-width: 0; }
.student-avatar-lg { width: 56px; height: 56px; border-radius: 16px; background: var(--brand-navy-soft); color: var(--primary); font-size: 20px; font-weight: 800; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.parent-label { font-size: 11px; font-weight: 800; color: var(--primary); text-transform: uppercase; }
.student-name { font-size: 20px; font-weight: 800; color: var(--text-main); }
.student-meta { font-size: 13px; color: var(--text-muted); }

.btn-whatsapp {
    background: #25D366; color: white; border: none; padding: 12px 20px; border-radius: 12px;
    font-weight: 800; font-size: 13px; cursor: pointer; box-shadow: 0 4px 12px rgba(37, 211, 102, 0.25); flex-shrink: 0;
}

/* Content Grid */
.content-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 24px; margin-top: 24px; width: 100%; box-sizing: border-box; }
.space-y-6 > * + * { margin-top: 24px; }

.panel-card {
    background: white; border: 1px solid var(--border-color); border-radius: var(--radius);
    padding: 24px; width: 100%; box-sizing: border-box; min-width: 0;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.03);
}

.panel-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 20px; }
.panel-header h3 { font-size: 16px; font-weight: 800; color: var(--text-main); }
.panel-sub { font-size: 12px; color: var(--text-muted); margin-top: 2px; }

/* Bar Chart styling */
.chart-legend { display: flex; gap: 14px; font-size: 12px; font-weight: 700; color: var(--text-muted); }
.legend-item { display: flex; align-items: center; gap: 6px; }
.legend-dot { width: 10px; height: 10px; border-radius: 3px; }
.bg-indigo { background: var(--brand-navy); }
.bg-emerald { background: #10b981; }

.bar-chart-wrapper { display: flex; justify-content: space-between; align-items: flex-end; height: 180px; padding-top: 20px; border-bottom: 1px solid var(--border-color); }
.chart-bar-group { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 8px; height: 100%; justify-content: flex-end; }
.bars-pair { display: flex; gap: 4px; align-items: flex-end; height: 140px; }
.bar { width: 14px; border-radius: 4px 4px 0 0; transition: height 0.4s ease; cursor: pointer; }
.bar:hover { opacity: 0.8; }
.bar-indigo { background: var(--brand-navy); }
.bar-emerald { background: #10b981; }
.chart-label { font-size: 11px; font-weight: 700; color: var(--text-muted); }

/* Class Summary Pro Cards */
.class-list-pro { display: flex; flex-direction: column; gap: 16px; }
.class-card-item {
    background: #f8fafc; border: 1px solid var(--border-color); border-radius: 16px;
    padding: 16px; display: flex; flex-direction: column; gap: 12px;
}

.class-card-top { display: flex; align-items: center; gap: 12px; }
.class-badge-box {
    padding: 8px 12px; border-radius: 12px; background: var(--brand-navy-soft); color: var(--brand-navy-dark);
    font-weight: 800; font-size: 12px; flex-shrink: 0;
}
.bg-purple-sub { background: var(--brand-steel-soft); color: var(--brand-steel-dark); }
.bg-teal-sub { background: #ccfbf1; color: #0f766e; }

.c-title { font-size: 14px; font-weight: 800; }
.c-teacher { font-size: 11px; color: var(--text-muted); display: block; }

.class-progress-wrapper { display: flex; flex-direction: column; gap: 6px; }
.progress-bar-bg { width: 100%; height: 8px; background: #e2e8f0; border-radius: 10px; overflow: hidden; }
.progress-bar-fill { height: 100%; border-radius: 10px; transition: width 0.4s ease; }
.progress-labels { display: flex; justify-content: space-between; align-items: center; font-size: 11px; }

/* Table styling */
.table-responsive { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; box-sizing: border-box; }
.data-table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 540px; }
.data-table th { text-align: left; padding: 12px; background: #f8fafc; color: var(--text-muted); font-weight: 700; font-size: 11px; text-transform: uppercase; }
.data-table td { padding: 14px 12px; border-bottom: 1px solid var(--border-color); }

.tag { padding: 4px 8px; border-radius: 6px; font-size: 11px; font-weight: 700; }
.tag-indigo { background: var(--brand-navy-soft); color: var(--brand-navy-dark); }
.tag-green { background: #dcfce7; color: #15803d; }
.tag-orange { background: #ffedd5; color: #c2410c; }

.status-pill { padding: 4px 10px; border-radius: 12px; font-size: 11px; font-weight: 700; }
.pill-upcoming { background: #fef3c7; color: #b45309; }
.pill-active { background: #dcfce7; color: #15803d; }
.pill-completed { background: #f1f5f9; color: #475569; }

.mt-6 { margin-top: 24px; }
.font-bold { font-weight: 700; }
.font-mono { font-family: monospace; }
.text-right { text-align: right; }

/* DESKTOP COLLAPSED SIDEBAR STATE */
@media (min-width: 901px) {
    .sidebar-collapsed .sidebar { width: 76px; padding: 24px 10px; }
    .sidebar-collapsed .brand-text,
    .sidebar-collapsed .nav-label,
    .sidebar-collapsed .nav-tag,
    .sidebar-collapsed .user-info { display: none !important; }
    .sidebar-collapsed .sidebar-brand { justify-content: center; }
    .sidebar-collapsed .brand-logo-full,
    .sidebar-collapsed .brand-app-label { display: none !important; }
    .sidebar-collapsed .brand-stack { align-items: center; }
    .sidebar-collapsed .brand-logo-mark { display: block; }
    .sidebar-collapsed .nav-item { justify-content: center; padding: 12px 0; }
    .sidebar-collapsed .user-card { justify-content: center; }
    .sidebar-collapsed .main-content { margin-left: 76px; width: calc(100% - 76px); max-width: calc(100% - 76px); }
}

/* MOBILE RESPONSIVENESS (< 900px) */
@media (max-width: 900px) {
    .sidebar { transform: translateX(-100%); width: 270px; box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.15); }
    .sidebar.mobile-open { transform: translateX(0); }
    .main-content { margin-left: 0 !important; width: 100% !important; max-width: 100% !important; }

    .mobile-brand { display: flex; }
    .topbar { padding: 10px 14px; }
    .dashboard-body { padding: 16px 12px; gap: 16px; }

    .hero-welcome-card { flex-direction: column; align-items: flex-start; gap: 14px; padding: 20px; }
    .shortcuts-bar { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }

    .content-grid { grid-template-columns: 1fr; gap: 16px; }
    .bar-chart-wrapper { height: 140px; }

    .clock-app-card { flex-direction: column; align-items: stretch; padding: 16px; gap: 16px; }
    .clock-display { font-size: 30px; }
    .clock-right { align-items: stretch; }
    .clock-status-box { text-align: left; }
    .clock-buttons-row { flex-direction: column; gap: 10px; }
    .btn-clock { width: 100%; text-align: center; }

    .parent-student-card { flex-direction: column; align-items: stretch; gap: 16px; padding: 16px; }
    .student-info-main { flex-direction: row; }
    .btn-whatsapp { width: 100%; text-align: center; }
}

@media (max-width: 600px) {
    .shortcuts-bar { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: 1fr; }
}
