/* ========================================
   CMS Website Sekolah - Design System
   ======================================== */

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

:root {
    --primary-rgb: 30, 64, 175;
    --primary: #1e40af;
    --primary-light: #3b82f6;
    --primary-dark: #1e3a8a;
    --secondary: #0891b2;
    --accent: #f59e0b;
    --accent-light: #fbbf24;
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    --dark: #0f172a;
    --dark-2: #1e293b;
    --dark-3: #334155;
    --gray: #64748b;
    --gray-light: #94a3b8;
    --light: #f8fafc;
    --light-2: #f1f5f9;
    --light-3: #e2e8f0;
    --white: #ffffff;
    --font-main: 'Poppins', sans-serif;
    --font-body: 'Inter', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
    --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 25px -3px rgb(0 0 0 / 0.15);
    --shadow-xl: 0 20px 40px -5px rgb(0 0 0 / 0.2);
    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 20px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --gradient-primary: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    --gradient-dark:    linear-gradient(135deg, var(--dark) 0%, var(--dark-2) 100%);
    --gradient-accent:  linear-gradient(135deg, var(--accent) 0%, #f97316 100%);
    --hero-overlay-bg:  transparent;
    --cut: 26px;
    --clip-corner: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, 0 100%);
    --seam: linear-gradient(135deg,
              transparent calc(50% - 1px), var(--accent-light) calc(50% - 1px),
              var(--accent-light) calc(50% + 1px), transparent calc(50% + 1px));
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font-body);
    color: var(--dark);
    background:
        linear-gradient(rgba(var(--primary-rgb), 0.035) 1px, transparent 1px) 0 0 / 100% 42px,
        linear-gradient(90deg, rgba(var(--primary-rgb), 0.035) 1px, transparent 1px) 0 0 / 42px 100%,
        var(--light);
    line-height: 1.7;
    overflow-x: hidden;
}
a { text-decoration: none; color: inherit; transition: var(--transition); }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
    outline: 2px solid var(--primary-light); outline-offset: 3px; border-radius: 4px;
}
img { max-width: 100%; height: auto; display: block; }
ul { list-style: none; }
h1,h2,h3,h4,h5,h6 { font-family: var(--font-main); font-weight: 700; line-height: 1.3; }
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* ========== NAVBAR ========== */
.navbar {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0,0,0,0.05);
    transition: var(--transition);
}
.navbar::before {
    content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
    background: var(--gradient-primary);
    transform: scaleX(0); transform-origin: left;
    transition: transform 0.5s cubic-bezier(0.4,0,0.2,1);
}
.navbar.scrolled::before { transform: scaleX(1); }
.navbar.scrolled {
    background: rgba(255,255,255,0.95);
    box-shadow: var(--shadow);
}
.navbar .container {
    display: flex; align-items: center; justify-content: space-between;
    height: 75px; gap: 12px;
}
.navbar-brand {
    display: flex; align-items: center; gap: 12px;
    font-weight: 700; color: var(--primary);
    flex-shrink: 0; max-width: calc(100% - 160px);
}
.navbar-brand img { height: 44px; width: auto; }
.navbar-brand span { display: flex; flex-direction: column; overflow: hidden; }
.navbar-brand .school-name {
    font-family: var(--font-main); font-weight: 700; font-size: 1rem; color: var(--dark);
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 280px;
}
.navbar-brand .school-sub {
    font-size: 0.72rem; color: var(--gray); font-family: var(--font-mono);
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 280px;
}
.nav-menu {
    display: flex; align-items: center; gap: 4px;
    flex-wrap: nowrap;
}
.nav-menu > a, .nav-item > a {
    padding: 8px 14px; border-radius: var(--radius-sm);
    font-weight: 500; font-size: 0.9rem; color: var(--dark-3);
    display: flex; align-items: center; gap: 5px;
    white-space: nowrap;
}
.nav-menu > a:hover, .nav-menu > a.active,
.nav-item > a:hover, .nav-item > a.active {
    color: var(--primary); background: rgba(var(--primary-rgb),0.06);
}
.drop-arrow {
    font-size: 0.68rem; opacity: 0.6;
    transition: transform 0.25s ease;
}
.nav-item:hover > a .drop-arrow { transform: rotate(180deg); }

.dropdown {
    position: absolute; top: calc(100% + 8px); left: 0;
    min-width: 210px; background: var(--white);
    border-radius: var(--radius-sm); border: 1px solid var(--light-3);
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
    opacity: 0; pointer-events: none;
    transform: translateY(10px);
    transition: opacity 0.2s ease, transform 0.2s ease;
    z-index: 999;
}
.nav-item:hover .dropdown,
.nav-item:focus-within .dropdown {
    opacity: 1; pointer-events: all; transform: translateY(0);
}
.dropdown::before {
    content: ''; position: absolute; top: -6px; left: 20px;
    width: 12px; height: 12px;
    background: var(--white);
    border-left: 1px solid var(--light-3);
    border-top: 1px solid var(--light-3);
    transform: rotate(45deg);
}
.dropdown a {
    display: flex; align-items: center; gap: 9px;
    padding: 10px 16px; font-size: 0.84rem; font-weight: 500;
    color: var(--dark-3);
    border-bottom: 1px solid var(--light-2);
    transition: background 0.15s, color 0.15s, padding-left 0.18s;
    border-radius: 0;
}
.dropdown a:last-child { border-bottom: none; border-radius: 0 0 var(--radius-sm) var(--radius-sm); }
.dropdown a:first-child { border-radius: var(--radius-sm) var(--radius-sm) 0 0; }
.dropdown a:hover { background: rgba(30,64,175,0.06); color: var(--primary); padding-left: 22px; }
.dropdown a i.sub-icon { font-size: 0.78rem; color: var(--primary-light); width: 14px; text-align: center; flex-shrink: 0; }
.dropdown a.active { color: var(--primary); background: rgba(30,64,175,0.05); font-weight: 600; }

.nav-toggle {
    display: none; background: none; border: none; cursor: pointer;
    width: 40px; height: 40px; border-radius: var(--radius-sm);
    align-items: center; justify-content: center;
    color: var(--dark); font-size: 1.5rem; flex-shrink: 0;
}

/* ========== HERO SLIDER ========== */
@keyframes kenBurns {
    0%   { transform: scale(1.08) translateX(0)    translateY(0); }
    50%  { transform: scale(1.12) translateX(-1%)  translateY(-0.4%); }
    100% { transform: scale(1.08) translateX(0)    translateY(0); }
}
@keyframes slideContentIn {
    from { opacity: 0; transform: translateY(22px); }
    to   { opacity: 1; transform: translateY(0); }
}
.hero {
    position: relative; height: 85vh; min-height: 550px;
    overflow: hidden; margin-top: 75px;
}
/* Track: semua slide berjejer horizontal */
.hero-track {
    display: flex;
    width: 100%; height: 100%;
    transition: transform 0.85s cubic-bezier(0.77, 0, 0.175, 1);
    will-change: transform;
    position: absolute; top: 0; left: 0;
}
.hero-slide {
    flex: 0 0 100%;
    position: relative;
    height: 100%;
    overflow: hidden;
}
.hero-slide img {
    width: 100%; height: 100%; object-fit: cover;
    transform-origin: center center;
    filter: brightness(1.05) saturate(1.1);
    transform: scale(1.08);
    transition: transform 0.85s cubic-bezier(0.77, 0, 0.175, 1);
    will-change: transform;
}
.hero-slide.active img {
    animation: kenBurns 16s ease-in-out infinite;
}
/* Progress bar auto-slide */
.hero-progress {
    position: absolute; bottom: 0; left: 0; right: 0;
    height: 3px; z-index: 10;
    background: rgba(255,255,255,0.15);
    pointer-events: none;
}
.hero-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-light), var(--accent));
    width: 0%;
    transition: none;
    box-shadow: 0 0 8px rgba(251,191,36,0.6);
}
.hero-progress-bar.running {
    width: 100%;
    transition: width 5s linear;
}
.hero-overlay {
    position: absolute; inset: 0;
    background: var(--hero-overlay-bg);
    z-index: 1;
}
/* Cinematic content panel at bottom */
.hero-content {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    display: flex; flex-direction: column;
    align-items: flex-start;
    text-align: left;
    padding: 40px 60px 40px;
    z-index: 2;
    background: transparent;
    animation: fadeInUp 0.7s ease 0.1s both;
}
.hero-content-inner {
    max-width: 780px;
    background: rgba(5, 10, 28, 0.72);
    backdrop-filter: blur(24px) saturate(1.8);
    -webkit-backdrop-filter: blur(24px) saturate(1.8);
    border: 1px solid rgba(255,255,255,0.18);
    border-radius: 18px 18px 18px 4px;
    clip-path: var(--clip-corner);
    padding: 28px 40px 24px 36px;
    position: relative;
    box-shadow: 0 12px 48px rgba(0,0,0,0.45), inset 0 1px 0 rgba(255,255,255,0.12);
}
.hero-content-inner::after {
    content: ''; position: absolute; top: 0; right: 0; width: var(--cut); height: var(--cut);
    background: var(--seam); pointer-events: none;
}
.hero-content h1 {
    font-size: 2.5rem; color: var(--white); margin-bottom: 10px;
    line-height: 1.2;
    text-shadow: 0 2px 16px rgba(0,0,0,0.7), 0 1px 4px rgba(0,0,0,0.5);
    animation: fadeInUp 0.8s ease;
}
.hero-content p {
    font-size: 1rem; color: rgba(255,255,255,0.88);
    max-width: 580px; margin-bottom: 22px;
    line-height: 1.65;
    animation: fadeInUp 0.8s ease 0.2s both;
}
.hero-content-btns {
    display: flex; gap: 12px; flex-wrap: wrap;
}
.hero-dots {
    position: absolute; bottom: 20px; right: 60px;
    display: flex; gap: 8px; z-index: 3;
    flex-direction: row;
}
.hero-dots .dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: rgba(255,255,255,0.4); cursor: pointer;
    transition: var(--transition); border: 2px solid rgba(255,255,255,0.6);
}
.hero-dots .dot.active {
    background: var(--white);
    width: 26px;
    border-radius: 4px;
    border-color: var(--white);
}

/* ========== BUTTONS ========== */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 12px 28px; border-radius: var(--radius-sm);
    font-family: var(--font-main); font-weight: 600; font-size: 0.95rem;
    border: none; cursor: pointer; transition: var(--transition);
}
.btn-primary {
    background: var(--gradient-primary); color: var(--white);
    box-shadow: 0 4px 15px rgba(var(--primary-rgb),0.3);
    position: relative; isolation: isolate; overflow: hidden;
}
.btn-primary::before {
    content: ''; position: absolute; inset: 0; z-index: -1;
    background: linear-gradient(115deg, transparent 20%, rgba(255,255,255,0.35) 40%, transparent 60%);
    background-size: 250% 100%; background-position: 100% 0;
    transition: background-position 0.7s ease;
}
.btn-primary:hover::before { background-position: -50% 0; }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(var(--primary-rgb),0.4); }
.btn-outline {
    background: transparent; color: var(--white);
    border: 2px solid rgba(255,255,255,0.5);
}
.btn-outline:hover { background: var(--white); color: var(--primary); }
.btn-accent { background: var(--gradient-accent); color: var(--white); }
.btn-sm { padding: 8px 18px; font-size: 0.85rem; }

/* ========== SECTIONS ========== */
.section { padding: 80px 0; }
.section-header {
    text-align: center; margin-bottom: 50px;
}
.section-header h2 {
    font-size: 2.2rem; color: var(--dark); margin-bottom: 12px;
    position: relative; display: inline-block;
}
.section-header h2::before {
    content: ''; position: absolute; bottom: -8px; left: 50%; transform: translateX(-50%);
    width: 60px; height: 4px; background: var(--gradient-primary); border-radius: 4px;
}
.section-header h2::after {
    content: ''; position: absolute; bottom: -8px; left: 50%; transform: translateX(-50%);
    width: 76px; height: 4px; border-left: 2px solid var(--accent); border-right: 2px solid var(--accent);
}
.section-header p { color: var(--gray); font-size: 1.05rem; max-width: 600px; margin: 20px auto 0; }
.section-alt { background: var(--light-2); }

/* ========== STATS ========== */
.stats-section {
    background: var(--gradient-primary); padding: 24px 0;
    position: relative; overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}
.stats-section::before {
    content: ''; position: absolute; inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2V6h4V4H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.stats-grid {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 0;
    position: relative; z-index: 1; align-items: center;
}
.stat-card {
    display: flex; align-items: center; justify-content: flex-start; gap: 16px;
    text-align: left; color: var(--white);
    background: transparent; border: none; border-radius: 0;
    padding: 12px 24px; position: relative;
    transition: var(--transition); box-shadow: none;
}
.stat-card:not(:last-child)::before {
    content: ''; position: absolute; right: 0; top: 15%;
    height: 70%; width: 1px; background: rgba(255,255,255,0.22);
}
.stat-card:hover {
    transform: translateY(-3px);
    background: rgba(255,255,255,0.06);
    border-radius: var(--radius-sm);
}
.stat-card .stat-icon {
    display: flex; align-items: center; justify-content: center;
    width: 44px; height: 44px; border-radius: 50%;
    background: rgba(255,255,255,0.15); font-size: 1.4rem;
    color: var(--accent-light); flex-shrink: 0; margin-bottom: 0;
}
.stat-card-content {
    display: flex; flex-direction: column; justify-content: center;
}
.stat-card .stat-number {
    font-family: var(--font-mono); font-size: 1.8rem; font-weight: 700;
    font-variant-numeric: tabular-nums; line-height: 1.1;
    margin-bottom: 2px; color: var(--white);
}
.stat-card .stat-label {
    font-size: 0.8rem; opacity: 0.9; margin-top: 0;
    text-transform: uppercase; letter-spacing: 0.04em; font-weight: 600;
    color: rgba(255,255,255,0.9); white-space: nowrap;
}

/* ========== CARDS ========== */
.card {
    background: var(--white); border-radius: var(--radius) var(--radius) var(--radius) 4px;
    clip-path: var(--clip-corner);
    overflow: hidden; transition: var(--transition);
    border: 1px solid var(--light-3);
    position: relative;
}
.card::after {
    content: ''; position: absolute; top: 0; right: 0; width: var(--cut); height: var(--cut);
    background: var(--seam); z-index: 2; pointer-events: none;
}
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.card-img {
    width: 100%; height: 220px; object-fit: cover;
    transition: var(--transition);
}
.card:hover .card-img { transform: scale(1.05); }
.card-img-wrapper { overflow: hidden; position: relative; }
.card-img-wrapper::after {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.35) 0%, transparent 45%);
    pointer-events: none;
}
.card-body { padding: 22px; }
.card-body h3 {
    font-size: 1.15rem; margin-bottom: 8px; color: var(--dark);
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card-body p { color: var(--gray); font-size: 0.92rem; line-height: 1.6; }
.card-meta {
    display: flex; align-items: center; gap: 15px;
    font-size: 0.8rem; color: var(--gray-light); margin-bottom: 10px;
    font-family: var(--font-mono);
}
.card-meta i { color: var(--primary-light); }
.card-badge {
    position: absolute; top: 15px; left: 15px;
    background: var(--gradient-primary); color: var(--white);
    padding: 4px 14px; border-radius: 20px; font-size: 0.78rem; font-weight: 600;
    z-index: 1;
}
.card-footer-link {
    display: inline-flex; align-items: center; gap: 6px;
    color: var(--primary); font-weight: 600; font-size: 0.9rem;
    margin-top: 12px;
}
.card-footer-link:hover { gap: 10px; }

/* Grids */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 30px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 25px; }

/* ========== WELCOME SECTION ========== */
.welcome-grid {
    display: grid; grid-template-columns: 1.1fr 1.9fr; gap: 60px;
    align-items: center;
}

/* Profile Card */
.welcome-img {
    position: relative;
    display: flex; flex-direction: column; align-items: center;
    justify-content: center;
    padding: 48px 32px 40px;
    border-radius: 24px;
    background: var(--gradient-primary);
    box-shadow: 0 20px 60px rgba(var(--primary-rgb), 0.35);
    overflow: hidden;
    clip-path: var(--clip-corner);
}
.welcome-img::before {
    content: '';
    position: absolute; top: -60px; right: -60px;
    width: 220px; height: 220px;
    border-radius: 50%;
    background: rgba(255,255,255,0.06);
    pointer-events: none;
}
.welcome-img::after {
    content: '';
    position: absolute; bottom: -80px; left: -50px;
    width: 260px; height: 260px;
    border-radius: 50%;
    background: rgba(255,255,255,0.05);
    pointer-events: none;
}
.welcome-img img {
    width: 170px; height: 170px;
    object-fit: cover; object-position: top center;
    border-radius: 50%;
    border: 5px solid rgba(255,255,255,0.9);
    box-shadow: 0 8px 32px rgba(0,0,0,0.28),
                0 0 0 10px rgba(255,255,255,0.12),
                0 0 0 20px rgba(255,255,255,0.06);
    position: relative; z-index: 1;
    display: block; margin: 0 auto;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}
.welcome-img:hover img {
    transform: scale(1.04);
    box-shadow: 0 12px 40px rgba(0,0,0,0.35),
                0 0 0 10px rgba(255,255,255,0.18),
                0 0 0 22px rgba(255,255,255,0.08);
}
.welcome-img .principal-info {
    position: relative; z-index: 1;
    text-align: center; margin-top: 22px;
}
.welcome-img .principal-name {
    font-family: var(--font-main);
    font-size: 1.1rem; font-weight: 700;
    color: var(--white);
    margin-bottom: 4px;
    text-shadow: 0 1px 4px rgba(0,0,0,0.2);
}
.welcome-img .principal-title {
    font-size: 0.78rem; font-weight: 500;
    color: rgba(255,255,255,0.75);
    text-transform: uppercase; letter-spacing: 0.08em;
    font-family: var(--font-mono);
}
.welcome-img .principal-divider {
    width: 40px; height: 2px;
    background: var(--accent-light);
    border-radius: 2px;
    margin: 10px auto 0;
    opacity: 0.8;
}
.welcome-img .card-cut-seam {
    position: absolute; top: 0; right: 0;
    width: var(--cut); height: var(--cut);
    background: var(--seam);
    pointer-events: none; z-index: 2;
}
.welcome-text .subtitle {
    color: var(--primary); font-weight: 600; font-size: 0.85rem;
    margin-bottom: 20px; display: inline-flex; align-items: center; gap: 8px;
    font-family: var(--font-mono); text-transform: uppercase; letter-spacing: 0.06em;
    padding: 6px 14px; border-radius: 20px; background: rgba(var(--primary-rgb),0.08);
    border: 1px solid rgba(var(--primary-rgb),0.15);
}
.welcome-text h2 { font-size: 2rem; margin-bottom: 8px; color: var(--dark); }
.welcome-text p { color: var(--gray); margin-bottom: 20px; }

/* ========== SAMBUTAN READ MORE ========== */
.sambutan-text-wrapper { position: relative; }
.sambutan-body {
    color: var(--gray);
    line-height: 1.85;
    font-size: 0.97rem;
    text-align: justify;
    text-justify: inter-word;
    max-height: 140px;
    overflow: hidden;
    transition: max-height 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}
.sambutan-body.expanded { max-height: 2000px; }
.sambutan-fade {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 80px;
    background: linear-gradient(to bottom, transparent, var(--white));
    pointer-events: none;
    transition: opacity 0.4s ease;
}
.sambutan-fade.hidden { opacity: 0; }
.section-alt .sambutan-fade {
    background: linear-gradient(to bottom, transparent, var(--light-2));
}
.btn-readmore {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 18px;
    padding: 9px 22px;
    border-radius: 30px;
    font-family: var(--font-main);
    font-weight: 600;
    font-size: 0.88rem;
    color: var(--primary);
    background: rgba(30,64,175,0.08);
    border: 1.5px solid rgba(30,64,175,0.2);
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}
.btn-readmore:hover {
    background: var(--primary); color: var(--white);
    border-color: var(--primary); transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(30,64,175,0.25);
}
.btn-readmore .rm-icon {
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 0.78rem;
}
.btn-readmore.expanded .rm-icon { transform: rotate(180deg); }
.sambutan-quote-deco {
    position: absolute; top: -20px; left: -15px;
    font-size: 8rem; line-height: 1;
    color: var(--primary); opacity: 0.06;
    font-family: Georgia, serif; pointer-events: none; user-select: none;
}

/* ========== PROFIL CONTENT BOX ========== */
.profil-content-box {
    max-width: 800px; margin: 0 auto;
    background: var(--white);
    padding: 40px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

/* ========== GURU CARD ========== */
.guru-card {
    background: var(--white); border-radius: var(--radius) var(--radius) var(--radius) 4px;
    clip-path: var(--clip-corner);
    padding: 30px; text-align: center; transition: var(--transition);
    border: 1px solid var(--light-3);
    position: relative;
}
.guru-card::after {
    content: ''; position: absolute; top: 0; right: 0; width: var(--cut); height: var(--cut);
    background: var(--seam); pointer-events: none;
}
.guru-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.guru-card img {
    width: 120px; height: 120px; border-radius: 50%;
    object-fit: cover; margin: 0 auto 16px;
    border: 4px solid var(--light-2);
    box-shadow: 0 0 0 3px rgba(var(--primary-rgb),0.15);
    transition: var(--transition);
}
.guru-card:hover img { box-shadow: 0 0 0 4px rgba(var(--primary-rgb),0.3); }
.guru-card h4 { font-size: 1.05rem; margin-bottom: 4px; }
.guru-card .jabatan { color: var(--primary); font-size: 0.85rem; font-weight: 500; }
.guru-card .bidang { color: var(--gray); font-size: 0.82rem; margin-top: 4px; font-family: var(--font-mono); }

/* ========== FOOTER ========== */
.footer {
    background: var(--gradient-dark); color: rgba(255,255,255,0.8);
    padding: 60px 0 0; position: relative; overflow: hidden;
}
.footer::before {
    content: ''; position: absolute; inset: 0; pointer-events: none;
    background:
        linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px) 0 0 / 100% 36px,
        linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px) 0 0 / 36px 100%;
    -webkit-mask-image: linear-gradient(to bottom, black, transparent 70%);
    mask-image: linear-gradient(to bottom, black, transparent 70%);
}
.footer .container { position: relative; z-index: 1; }
.footer-grid {
    display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px;
    padding-bottom: 40px; border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-about h3 {
    color: var(--white); font-size: 1.3rem; margin-bottom: 15px;
    display: flex; align-items: center; gap: 10px;
}
.footer-about p { font-size: 0.9rem; line-height: 1.8; }
.footer h4 {
    color: var(--white); font-size: 1rem; margin-bottom: 20px;
    position: relative; padding-bottom: 10px;
}
.footer h4::after {
    content: ''; position: absolute; bottom: 0; left: 0;
    width: 30px; height: 3px; background: var(--accent); border-radius: 3px;
}
.footer-links a {
    display: block; padding: 6px 0; font-size: 0.9rem;
    color: rgba(255,255,255,0.7);
}
.footer-links a:hover { color: var(--accent); padding-left: 5px; }
.footer-contact li {
    display: flex; align-items: flex-start; gap: 10px;
    margin-bottom: 12px; font-size: 0.9rem;
    word-break: break-word; overflow-wrap: break-word;
}
.footer-contact i { color: var(--accent); margin-top: 3px; width: 16px; }
.footer-social {
    display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap;
}
.footer-social a {
    width: 38px; height: 38px; border-radius: 50%;
    background: rgba(255,255,255,0.1);
    display: flex; align-items: center; justify-content: center;
    color: var(--white); font-size: 1rem;
}
.footer-social a:hover { background: var(--primary); transform: translateY(-3px); }
.footer-bottom {
    text-align: center; padding: 20px 0;
    font-size: 0.85rem; color: rgba(255,255,255,0.5);
}

/* ========== PAGE HEADER ========== */
.page-header {
    background: var(--gradient-primary); padding: 120px 0 74px;
    text-align: center; position: relative; overflow: hidden;
    margin-top: 75px;
    clip-path: polygon(0 0, 100% 0, 100% calc(100% - 22px), 0 100%);
}
.page-header::before {
    content: ''; position: absolute; inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M20 20.5V18H0v-2h20v-2h2v2h20v2H22v2.5a.5.5 0 01-1 0z'/%3E%3C/g%3E%3C/svg%3E");
}
.page-header h1 {
    color: var(--white); font-size: 2.5rem;
    position: relative; z-index: 1;
}
.page-header .breadcrumb {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    color: rgba(255,255,255,0.75); font-size: 0.82rem;
    margin-top: 16px; position: relative; z-index: 1;
    font-family: var(--font-mono);
    padding: 7px 18px; border-radius: 20px;
    background: rgba(0,0,0,0.15); border: 1px solid rgba(255,255,255,0.15);
}
.page-header .breadcrumb a { color: rgba(255,255,255,0.95); }
.page-header .breadcrumb a:hover { color: var(--accent-light); }

/* ========== PAGINATION ========== */
.pagination {
    display: flex; justify-content: center; gap: 8px; margin-top: 40px; flex-wrap: wrap;
}
.pagination a, .pagination span {
    width: 42px; height: 42px; display: flex; align-items: center; justify-content: center;
    border-radius: var(--radius-sm); font-weight: 600; font-size: 0.9rem;
    border: 1px solid var(--light-3);
}
.pagination a { color: var(--dark-3); }
.pagination a:hover { background: var(--primary); color: var(--white); border-color: var(--primary); }
.pagination span.active { background: var(--primary); color: var(--white); border-color: var(--primary); }

/* ========== FORMS ========== */
.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 6px; font-weight: 600; font-size: 0.9rem; color: var(--dark-2); }
.form-control {
    width: 100%; padding: 12px 16px; border: 1px solid var(--light-3);
    border-radius: var(--radius-sm); font-family: var(--font-body);
    font-size: 0.95rem; transition: var(--transition); background: var(--white);
}
.form-control:focus { outline: none; border-color: var(--primary-light); box-shadow: 0 0 0 3px rgba(59,130,246,0.15); }
textarea.form-control { min-height: 130px; resize: vertical; }

/* ========== ALERTS ========== */
.alert {
    padding: 14px 20px; border-radius: var(--radius-sm);
    margin-bottom: 20px; font-size: 0.92rem;
    display: flex; align-items: center; gap: 10px;
}
.alert-success { background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; }
.alert-danger { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }
.alert-warning { background: #fffbeb; color: #92400e; border: 1px solid #fde68a; }
.alert-info { background: #eff6ff; color: #1e40af; border: 1px solid #bfdbfe; }

/* ========== ANIMATIONS ========== */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes ripple { to { transform: scale(4); opacity: 0; } }
.animate-fadeInUp { animation: fadeInUp 0.6s ease forwards; }
.animate-fadeIn { animation: fadeIn 0.5s ease forwards; }

/* Scroll reveal */
.reveal {
    opacity: 0; transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ========== HERO ARROWS ========== */
.hero-prev, .hero-next {
    position: absolute; top: 50%; transform: translateY(-50%);
    z-index: 4; background: rgba(255,255,255,0.2);
    border: none; color: white; width: 50px; height: 50px;
    border-radius: 50%; font-size: 1.1rem; cursor: pointer;
    transition: var(--transition); backdrop-filter: blur(4px);
}
.hero-prev { left: 20px; }
.hero-next { right: 20px; }
.hero-prev:hover, .hero-next:hover { background: rgba(255,255,255,0.4); transform: translateY(-50%) scale(1.1); }

/* ========== LIGHTBOX ========== */
#lightbox {
    position: fixed; inset: 0; z-index: 9999;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; pointer-events: none; transition: opacity 0.3s ease;
}
#lightbox.active { opacity: 1; pointer-events: all; }
.lb-overlay { position: absolute; inset: 0; background: rgba(0,0,0,0.92); }
.lb-container {
    position: relative; z-index: 1; max-width: 90vw; max-height: 90vh;
    display: flex; flex-direction: column; align-items: center;
}
.lb-img-wrap { position: relative; }
.lb-img {
    max-width: 90vw; max-height: 80vh; object-fit: contain;
    border-radius: var(--radius); transition: opacity 0.3s ease;
    box-shadow: 0 25px 60px rgba(0,0,0,0.5);
}
.lb-spinner {
    position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
    color: white; font-size: 2rem;
}
.lb-caption {
    color: rgba(255,255,255,0.8); font-size: 0.95rem;
    margin-top: 15px; text-align: center;
}
.lb-close {
    position: fixed; top: 20px; right: 25px;
    background: rgba(255,255,255,0.15); border: none; color: white;
    width: 44px; height: 44px; border-radius: 50%; font-size: 1.1rem;
    cursor: pointer; transition: var(--transition); z-index: 2;
}
.lb-close:hover { background: var(--danger); transform: rotate(90deg); }
.lb-prev, .lb-next {
    position: fixed; top: 50%; transform: translateY(-50%);
    background: rgba(255,255,255,0.15); border: none; color: white;
    width: 50px; height: 50px; border-radius: 50%; font-size: 1.1rem;
    cursor: pointer; transition: var(--transition); z-index: 2;
}
.lb-prev { left: 20px; }
.lb-next { right: 20px; }
.lb-prev:hover, .lb-next:hover { background: rgba(255,255,255,0.3); }
[data-lightbox] { cursor: zoom-in; }

/* ========== BACK TO TOP ========== */
#back-to-top {
    position: fixed; bottom: 30px; right: 30px; z-index: 500;
    width: 48px; height: 48px; border-radius: 50%;
    background: var(--gradient-primary); color: white;
    border: none; font-size: 1rem; cursor: pointer;
    box-shadow: var(--shadow-lg); transition: var(--transition);
    opacity: 0; pointer-events: none; transform: translateY(10px);
}
#back-to-top.visible { opacity: 1; pointer-events: all; transform: translateY(0); }
#back-to-top:hover { transform: translateY(-3px); box-shadow: var(--shadow-xl); }

/* ========== BTN RIPPLE ========== */
.btn-ripple {
    position: absolute; border-radius: 50%;
    width: 100px; height: 100px; margin-top: -50px; margin-left: -50px;
    background: rgba(255,255,255,0.25);
    animation: ripple 0.6s linear;
    pointer-events: none;
}

/* ========== GALLERY ========== */
.gallery-item {
    border-radius: var(--radius) var(--radius) var(--radius) 4px;
    clip-path: var(--clip-corner);
    overflow: hidden; cursor: zoom-in; aspect-ratio: 1;
    border: 1px solid var(--light-3); position: relative;
}
.gallery-item::after {
    content: ''; position: absolute; top: 0; right: 0; width: var(--cut); height: var(--cut);
    background: var(--seam); z-index: 2; pointer-events: none;
}
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.gallery-item:hover img { transform: scale(1.08); }
.gallery-item-overlay {
    position: absolute; inset: 0;
    background: rgba(30,64,175,0.5);
    display: flex; align-items: center; justify-content: center;
    opacity: 0; transition: var(--transition);
}
.gallery-item:hover .gallery-item-overlay { opacity: 1; }
.gallery-item-overlay i { color: white; font-size: 1.8rem; }

/* ========== EMPTY STATE ========== */
.empty-state { text-align: center; padding: 60px 20px; color: var(--gray); }
.empty-state i { font-size: 3rem; color: var(--light-3); margin-bottom: 16px; display: block; }
.empty-state h3 { font-size: 1.3rem; margin-bottom: 8px; color: var(--dark-3); }

/* ========== TABLE RESPONSIVE WRAPPER ========== */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: var(--radius-sm);
}

/* ========== ARTICLE CONTENT (WYSIWYG) ========== */
/* Handle gambar, tabel, iframe dari rich text editor */
.article-content {
    line-height: 1.9;
    font-size: 1rem;
    color: var(--dark-2);
    word-break: break-word;
    overflow-wrap: break-word;
}
.article-content img {
    max-width: 100% !important;
    height: auto !important;
    border-radius: var(--radius-sm);
    display: block;
    margin: 16px auto;
}
.article-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
    font-size: 0.9rem;
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
.article-content table th,
.article-content table td {
    padding: 10px 14px;
    border: 1px solid var(--light-3);
    text-align: left;
    white-space: nowrap;
}
.article-content table th {
    background: var(--light-2);
    font-weight: 600;
    color: var(--dark);
}
.article-content iframe {
    max-width: 100% !important;
    border-radius: var(--radius-sm);
}
/* Embed video di dalam artikel */
.article-content .iframe-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    margin: 16px 0;
    border-radius: var(--radius-sm);
    overflow: hidden;
    background: var(--dark);
}
.article-content .iframe-wrapper iframe {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    border: none;
}
.article-content h2,
.article-content h3,
.article-content h4 {
    margin: 20px 0 10px;
    font-family: var(--font-main);
    color: var(--dark);
}
.article-content p { margin-bottom: 14px; }
.article-content ul,
.article-content ol {
    padding-left: 24px;
    margin-bottom: 14px;
}
.article-content li { margin-bottom: 6px; }
.article-content blockquote {
    border-left: 4px solid var(--primary);
    padding: 12px 20px;
    margin: 16px 0;
    background: rgba(var(--primary-rgb), 0.05);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    color: var(--dark-3);
    font-style: italic;
}
.article-content a { color: var(--primary); text-decoration: underline; }

/* ========== KONTAK MAP ========== */
.kontak-map {
    margin-top: 30px;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    position: relative;
    width: 100%;
    padding-bottom: 45%;  /* 45% = aspek rasio peta */
    min-height: 200px;
}
.kontak-map iframe {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    border: 0;
}

/* ========== MEDIA SOSIAL BENTO BOX GRID ========== */
.bento-grid {
    display: grid;
    grid-template-columns: 1.3fr 1fr;
    gap: 24px;
    align-items: stretch;
}
.bento-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    border: 1px solid var(--light-3);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: var(--transition);
}
.bento-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}
/* Main featured card (first item) takes 2 rows on desktop */
.bento-card-main {
    grid-row: span 2;
}
.bento-card-header {
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--light-2);
    background: var(--light);
}
.bento-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    font-size: 0.88rem;
    padding: 6px 14px;
    border-radius: 20px;
    color: var(--white);
}
.bento-badge.platform-youtube { background: linear-gradient(135deg, #FF0000 0%, #cc0000 100%); box-shadow: 0 4px 12px rgba(255,0,0,0.25); }
.bento-badge.platform-instagram { background: linear-gradient(135deg, #833AB4 0%, #E1306C 50%, #F77737 100%); box-shadow: 0 4px 12px rgba(225,48,108,0.25); }
.bento-badge.platform-tiktok { background: linear-gradient(135deg, #25F4EE 0%, #FE2C55 100%); box-shadow: 0 4px 12px rgba(254,44,85,0.25); }

.bento-link-btn {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: var(--transition);
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    background: rgba(0,0,0,0.04);
}
.bento-link-btn:hover {
    color: var(--white);
    background: var(--primary);
}
.bento-card-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}
.bento-title {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--dark);
    line-height: 1.5;
    word-break: break-word;
}
.bento-card-main .bento-title {
    font-size: 1.25rem;
    font-weight: 700;
}
.bento-embed {
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--dark);
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    width: 100%;
}
.embed-responsive {
    position: relative; width: 100%;
    border-radius: var(--radius); overflow: hidden; background: var(--dark);
    box-sizing: border-box;
}
.embed-responsive iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: none; }
.embed-16by9 { padding-bottom: 56.25%; }
.embed-1by1  { padding-bottom: 100%; max-width: 450px; margin: 0 auto; }
.embed-9by16 { padding-bottom: 177.78%; max-width: 320px; margin: 0 auto; }

.bento-fallback-link {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 12px; padding: 40px 20px; color: var(--white); text-decoration: none;
    background: var(--gradient-primary); border-radius: var(--radius); width: 100%;
    transition: var(--transition);
}
.bento-fallback-link i { font-size: 2.5rem; }
.bento-fallback-link:hover { transform: scale(1.02); opacity: 0.95; }
.media-external-link {
    display: flex; align-items: center; justify-content: center; gap: 12px;
    padding: 40px 20px; background: var(--light-2); border-radius: var(--radius);
    color: var(--dark); text-decoration: none;
    font-family: var(--font-main); font-weight: 600;
    transition: var(--transition); border: 2px dashed var(--light-3);
    width: 100%; box-sizing: border-box;
}
.media-external-link:hover { background: var(--primary); color: var(--white); border-color: var(--primary); transform: scale(1.02); }
.media-external-link i:first-child { font-size: 2.5rem; }

/* =========================================
   RESPONSIVE — Mobile First Breakpoints
   ========================================= */

/* ── Large Tablet / Small Desktop (≤992px) ── */
@media (max-width: 992px) {
    .nav-toggle { display: flex; }
    .nav-menu {
        position: fixed; top: 75px; left: 0; right: 0;
        background: var(--white); flex-direction: column;
        padding: 20px; gap: 5px;
        transform: translateY(-120%); transition: var(--transition);
        box-shadow: var(--shadow-lg); overflow-y: auto;
        max-height: calc(100vh - 75px); z-index: 999;
    }
    .nav-menu.active { transform: translateY(0); }
    .nav-menu > a, .nav-item { width: 100%; }
    .nav-menu > a, .nav-item > a {
        padding: 12px 16px; width: 100%;
        display: flex; justify-content: space-between;
    }
    .nav-item .dropdown {
        position: static; opacity: 1; pointer-events: all;
        transform: none; box-shadow: none; border: none;
        background: var(--light); border-radius: var(--radius-sm);
        display: none; margin: 2px 0 4px;
    }
    .nav-item .dropdown::before { display: none; }
    .nav-item.open .dropdown { display: block; }
    .nav-item.open > a .drop-arrow { transform: rotate(180deg); }
    .dropdown a { padding: 10px 20px; border-bottom: 1px solid var(--light-3); }

    .hero-content h1 { font-size: 2.2rem; }
    .stats-section { padding: 20px 0; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
    .stat-card { padding: 14px 16px; gap: 14px; }
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 30px; }
    .welcome-grid { grid-template-columns: 1fr; gap: 30px; }
    .welcome-img { max-width: 300px; margin: 0 auto; padding: 40px 28px 34px; }
    .welcome-img img { width: 140px; height: 140px; }
    .navbar-brand .school-name { max-width: 200px; }
    .navbar-brand .school-sub { max-width: 200px; }
}

/* ── Tablet (≤768px) ── */
@media (max-width: 768px) {
    .hero-content h1 { font-size: 2rem; }
    .hero-content { padding: 30px 30px 35px; }
    .hero-dots { right: 30px; bottom: 16px; }
    .hero { height: auto; min-height: unset; aspect-ratio: 16/9; margin-top: 65px; background: #000; }
    .hero-slide img { width: 100%; height: 100%; object-fit: contain; }
    .stats-section { padding: 18px 0; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 14px 0; }
    .stat-card { padding: 12px 16px; gap: 12px; }
    .stat-card .stat-icon { width: 42px; height: 42px; font-size: 1.3rem; }
    .stat-card .stat-number { font-size: 1.5rem; }
    .stat-card .stat-label { font-size: 0.75rem; }
    .stat-card::before { display: none !important; }
    .stat-card:nth-child(odd)::before {
        content: '' !important; display: block !important;
        position: absolute; right: 0; top: 15%; height: 70%; width: 1px;
        background: rgba(255,255,255,0.22);
    }
    .section { padding: 60px 0; }
    .section-header h2 { font-size: 1.8rem; }
    .section-header { margin-bottom: 36px; }
    .footer-grid { grid-template-columns: 1fr; gap: 24px; }
    .page-header { clip-path: none; padding: 100px 0 50px; }
    .page-header h1 { font-size: 2rem; }
    #back-to-top { bottom: 20px; right: 16px; width: 42px; height: 42px; }
    /* Bento Grid — tablet */
    .bento-grid { grid-template-columns: 1fr; gap: 20px; }
    .bento-card-main { grid-row: auto; }
    .bento-card-header { padding: 14px 16px; }
    .bento-card-body { padding: 16px; }
    .embed-9by16 { max-width: 260px; }
}

/* ── Mobile (≤576px) ── */
@media (max-width: 576px) {
    :root { --cut: 16px; }

    body {
        background:
            linear-gradient(rgba(var(--primary-rgb), 0.03) 1px, transparent 1px) 0 0 / 100% 60px,
            var(--light);
    }

    .container { padding: 0 16px; }

    /* Navbar */
    .navbar .container { height: 65px; }
    .navbar-brand img { height: 36px; }
    .navbar-brand .school-name { font-size: 0.88rem; max-width: 155px; }
    .navbar-brand .school-sub { display: none; }
    .nav-menu { top: 65px; max-height: calc(100vh - 65px); }

    /* Hero */
    .hero { height: auto; min-height: unset; aspect-ratio: 16/9; margin-top: 65px; background: #000; }
    .hero-slide img { width: 100%; height: 100%; object-fit: contain; }
    .hero-content { padding: 10px; }
    .hero-content-inner { padding: 12px 14px; clip-path: none; border-radius: 8px; }
    .hero-content-inner::after { display: none; }
    .hero-content h1 { font-size: 1.1rem; margin-bottom: 5px; }
    .hero-content p {
        font-size: 0.8rem; line-height: 1.4; margin-bottom: 10px;
        display: -webkit-box; -webkit-line-clamp: 2;
        -webkit-box-orient: vertical; overflow: hidden;
    }
    .hero-content .btn { padding: 6px 12px; font-size: 0.8rem; }
    .hero-prev, .hero-next { width: 32px; height: 32px; font-size: 0.8rem; }
    .hero-prev { left: 8px; }
    .hero-next { right: 8px; }
    .hero-dots { bottom: 8px; right: 12px; }
    .hero-dots .dot { width: 6px; height: 6px; }
    .hero-dots .dot.active { width: 20px; }

    /* Stats */
    .stats-section { padding: 16px 0; }
    .stats-grid { grid-template-columns: 1fr 1fr; gap: 10px 0; }
    .stat-card { padding: 8px 10px; gap: 10px; flex-direction: row; align-items: center; }
    .stat-card .stat-icon { width: 36px; height: 36px; font-size: 1.15rem; margin-bottom: 0; }
    .stat-card .stat-number { font-size: 1.3rem; }
    .stat-card .stat-label { font-size: 0.68rem; }
    .stat-card::before { display: none !important; }
    .stat-card:nth-child(odd)::before {
        content: '' !important; display: block !important;
        position: absolute; right: 0; top: 15%; height: 70%; width: 1px;
        background: rgba(255,255,255,0.22);
    }

    /* Sections */
    .section { padding: 36px 0; }
    .section-header { margin-bottom: 28px; }
    .section-header h2 { font-size: 1.45rem; }
    .section-header p { font-size: 0.93rem; }

    /* Welcome / Profile Card */
    .welcome-grid { gap: 24px; }
    .welcome-img { max-width: 260px; padding: 32px 22px 28px; }
    .welcome-img img { width: 120px; height: 120px; }
    .welcome-img .principal-name { font-size: 0.95rem; }
    .welcome-img .principal-title { font-size: 0.7rem; }
    .welcome-text h2 { font-size: 1.5rem; }
    .btn-readmore { font-size: 0.82rem; padding: 7px 16px; }

    /* Grids */
    .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; gap: 20px; }

    /* Cards */
    .card-img { height: 180px; }
    .card-body { padding: 16px; }
    .card-body h3 { font-size: 1rem; }

    /* Profil */
    .profil-content-box { padding: 20px 16px; }

    /* Page header */
    .page-header { clip-path: none; padding: 85px 0 28px; }
    .page-header h1 { font-size: 1.5rem; }

    /* Footer */
    .footer-grid { grid-template-columns: 1fr; gap: 20px; }
    .footer { padding: 40px 0 0; }

    /* Bento Grid — HP */
    .bento-badge { font-size: 0.8rem; padding: 5px 12px; }
    .bento-link-btn span { display: none; }
    .bento-card-main .bento-title, .bento-title { font-size: 0.95rem; margin-bottom: 12px; }
    .embed-9by16 { max-width: 200px; }
    .embed-1by1 { max-width: 100%; }

    /* Back to top */
    #back-to-top { bottom: 16px; right: 12px; width: 38px; height: 38px; font-size: 0.85rem; }

    /* Pagination */
    .pagination a, .pagination span { width: 36px; height: 36px; font-size: 0.82rem; }
}

/* ── Extra Small (≤380px) ── */
@media (max-width: 380px) {
    .stats-grid { grid-template-columns: repeat(2, 1fr) !important; gap: 6px 0; }
    .stat-card { padding: 6px 8px; gap: 6px; }
    .stat-card .stat-icon { width: 30px; height: 30px; font-size: 1rem; }
    .stat-card .stat-number { font-size: 1.15rem; }
    .stat-card .stat-label { font-size: 0.6rem; }
    .stat-card:nth-child(odd)::before {
        content: '' !important; display: block !important;
        position: absolute; right: 0; top: 15%; height: 70%; width: 1px;
        background: rgba(255,255,255,0.22);
    }
    .hero-content h1 { font-size: 0.95rem; }
    .hero-content p { display: none; }
    .hero-content .btn-outline { display: none; }
    .welcome-img { max-width: 220px; padding: 26px 18px 22px; }
    .welcome-img img { width: 100px; height: 100px; }
    .section-header h2 { font-size: 1.25rem; }
    .navbar-brand .school-name { max-width: 120px; }
}
