@extends('layouts.teacher')
@section('title', 'Beranda')
@section('header_title', 'Beranda')
@section('content')
{{-- ================= HERO SECTION (Modern Gradient) ================= --}}
@php
$cards = [
['label' => 'Total Siswa', 'val' => $stats->total_siswa, 'icon' => 'users', 'color' => 'blue', 'bg' => 'bg-blue-50', 'text' => 'text-blue-600'],
['label' => 'Mata Pelajaran', 'val' => $stats->modul_aktif, 'icon' => 'book-open', 'color' => 'emerald', 'bg' => 'bg-emerald-50', 'text' => 'text-emerald-600'],
['label' => 'Perlu Dinilai', 'val' => $stats->tugas_pending, 'icon' => 'clipboard-check', 'color' => 'amber', 'bg' => 'bg-amber-50', 'text' => 'text-amber-600'],
['label' => 'Kuis Selesai', 'val' => $stats->kuis_selesai, 'icon' => 'graduation-cap', 'color' => 'purple', 'bg' => 'bg-purple-50', 'text' => 'text-purple-600'],
];
@endphp
@foreach($cards as $card)
{{ $card['val'] }}
{{ $card['label'] }}
@endforeach
{{-- ================= KONTEN UTAMA (MODUL) ================= --}}
Mata Pelajaran
Kelola materi pelajaran untuk kelas aktif Anda
{{-- ================= GRID MODUL (Modern Cards) ================= --}}
@foreach($active_modules as $modul)
@forelse(($modul->schedules ?? []) as $sch)
{{ $sch['hari'] }} • {{ $sch['periode'] }}
{{ $sch['jam'] }}
@empty
Belum ada jadwal
@endforelse
{{ $modul->department }}
{{ $modul->title }}
{{ $modul->kelas }}
{{ $modul->students_count }} Siswa
Progres Kelas
{{ $modul->progress }}%
@endforeach
@if($active_modules->isEmpty())
Belum ada modul
Silakan buat mata pembelajaran baru.
@endif
{{-- ================= MODAL THUMBNAIL (Refined) ================= --}}