
:root {
    --primary-color: #4f46e5;
    --sidebar-width: 260px;
    --bg-light: #f8fafc;
    --indigo-soft: #eef2ff;
    --green-soft: #f0fdf4;
    --orange-soft: #fff7ed;
    --red-soft: #fef2f2;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-light);
    overflow-x: hidden;
}

/* Sidebar Styling */
#sidebar-wrapper {
    min-height: 100vh;
    width: var(--sidebar-width);
    transition: margin 0.25s ease-out;
}

#sidebar-wrapper .sidebar-heading {
    padding: 1.5rem 1.25rem;
    font-size: 1.0rem;
}

#sidebar-wrapper .list-group {
    width: var(--sidebar-width);
}

#sidebar-wrapper .list-group-item {
    border: none;
    padding: 0.8rem 1.5rem;
    font-size: 0.95rem;
    color: #64748b;
    transition: all 0.2s ease;
}

#sidebar-wrapper .list-group-item.active {
    background-color: var(--indigo-soft) !important;
    color: var(--primary-color) !important;
    border-right: 4px solid var(--primary-color);
    font-weight: 600;
}

#sidebar-wrapper .list-group-item:hover:not(.active) {
    background-color: #f1f5f9;
    color: #334155;
    padding-left: 1.8rem;
}

/* Layout Wrapper */
#wrapper.toggled #sidebar-wrapper {
    margin-left: calc(-1 * var(--sidebar-width));
}

#page-content-wrapper {
    min-width: 100vw;
    transition: margin 0.25s ease-out;
}

@media (min-width: 768px) {
    #page-content-wrapper {
        min-width: 0;
        width: 100%;
    }
}

/* Card Styling */
.stat-card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border-radius: 12px;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1) !important;
}

.icon-box {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    font-size: 1.25rem;
}

/* Map Styling */
#map {
    height: 550px;
    width: 100%;
    z-index: 1;
}

.custom-popup .leaflet-popup-content-wrapper {
    border-radius: 12px;
    padding: 8px;
}

.badge-legend {
    font-size: 0.85rem;
}

/* Utils */
.bg-indigo-soft { background-color: var(--indigo-soft); }
.bg-green-soft { background-color: var(--green-soft); }
.bg-orange-soft { background-color: var(--orange-soft); }
.bg-red-soft { background-color: var(--red-soft); }

/* School Card Styling */
.school-card {
    border-radius: 16px;
    transition: all 0.3s ease;
    border: 1px solid #e2e8f0;
}

.school-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04) !important;
    border-color: var(--primary-color);
}

.school-card .card-body {
    padding: 1.5rem;
}

.school-card .badge-group .badge {
    font-weight: 500;
    padding: 0.5em 0.8em;
}

.btn-detail {
    border-radius: 10px;
    font-weight: 600;
    transition: all 0.2s;
}

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

/* =========================================
   STYLE UNTUK HALAMAN DETAIL (detail.html)
   ========================================= */

/* Header & Breadcrumb */
.detail-header {
    background: white;
    border-bottom: 1px solid #e2e8f0;
    padding: 2.5rem 0;
}

/* Stats Box */
.stat-box {
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    background: white;
    padding: 1.25rem;
}

/* Map pada Halaman Detail */
#school-location-map {
    height: 350px;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    z-index: 1;
}

/* Gallery Styling */
.gallery-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    height: 200px;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    inset: 0;
    background: rgba(79, 70, 229, 0.3);
    opacity: 0;
    transition: 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

/* Facility Tags */
.facility-tag {
    background: #f1f5f9;
    color: #475569;
    padding: 0.5rem 1rem;
    border-radius: 30px;
    display: inline-block;
    margin: 4px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid #e2e8f0;
}

/* Section Titles */
.section-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
}

.section-title i {
    color: #4f46e5;
    margin-right: 10px;
}

/* Custom Modal Close Button */
.btn-close-white {
    filter: invert(1) grayscale(100%) brightness(200%);
}

/* Penyesuaian Global untuk Halaman Detail */
body {
    /* Pastikan warna teks global konsisten jika belum ada di atas */
    color: #1e293b;
}

.navbar-brand {
    font-weight: 700;
    color: var(--primary-color) !important;
}
