/* ================================================================
   STYLE.CSS - PESANTREN MODERN TA'DIB AL-SYAKIRIN
   File CSS Gabungan untuk: index.html + semua halaman profil
   (sambutan, sejarah, visimisi, guru, fasilitas)
   ================================================================ */

/* --- VARIABLES & RESET (TEMA BIRU) --- */
:root {
    --primary: #1E3A8A;
    --secondary: #3B82F6;
    --accent: #FBBF24;
    --accent-hover: #F59E0B;
    --text: #111111;
    --bg: #F0F9FF;
    --white: #FFF;
}
* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Poppins', sans-serif; }
body { background-color: var(--bg); color: var(--text); overflow-x: hidden; }
a { text-decoration: none; }

/* ================================================================
   LOADING SCREEN (index.html)
   ================================================================ */
#loader { position: fixed; top: 0; left: 0; width: 100%; height: 100vh; background: var(--primary); z-index: 99999; display: flex; flex-direction: column; justify-content: center; align-items: center; transition: opacity 0.8s ease, visibility 0.8s ease; }
.loader-content { text-align: center; color: var(--white); animation: fadeIn 1s ease-in-out; }
.loader-logo { width: 110px; height: 110px; object-fit: contain; background-color: var(--white); padding: 10px; border-radius: 50%; margin-bottom: 20px; animation: pulse 2s infinite; box-shadow: 0 0 20px rgba(255, 255, 255, 0.5); }
.loader-quote { font-family: 'Amiri', serif; font-size: 1.5rem; color: var(--accent); margin-bottom: 10px; }
.loader-text { font-size: 0.9rem; font-weight: 300; letter-spacing: 1px; opacity: 0.8; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
@keyframes pulse { 0% { transform: scale(1); } 50% { transform: scale(1.05); } 100% { transform: scale(1); } }

/* ================================================================
   NAVBAR
   ================================================================ */
.navbar { background: rgba(30, 58, 138, 0.98); backdrop-filter: blur(10px); height: 80px; display: flex; justify-content: space-between; align-items: center; padding: 0 5%; position: fixed; width: 100%; top: 0; z-index: 1000; box-shadow: 0 4px 30px rgba(0,0,0,0.1); transition: 0.3s; }
/* Navbar sticky untuk halaman profil */
.navbar.sticky { position: sticky; }
.brand-container { display: flex; align-items: center; gap: 12px; }
.brand-logo { height: 50px; width: 50px; object-fit: contain; background-color: var(--white); padding: 5px; border-radius: 50%; box-shadow: 0 2px 10px rgba(0,0,0,0.2); }
.brand-text { color: var(--white); font-size: 0.9rem; font-weight: 400; line-height: 1.2; text-shadow: 1px 1px 3px rgba(0,0,0,0.2); }
.brand-text span { color: var(--accent); font-size: 1.2rem; font-weight: 700; display: block; margin-top: 2px; letter-spacing: 0.5px; }

/* --- MENU & BUTTONS --- */
.nav-links { display: flex; list-style: none; align-items: center; gap: 5px; }
.nav-links li { position: relative; }
.nav-links li a { color: var(--white); font-size: 15px; font-weight: 600; padding: 10px 15px; border-radius: 8px; transition: 0.3s; display: flex; align-items: center; text-shadow: 1px 1px 2px rgba(0,0,0,0.1); }
.nav-links li a:hover { background: rgba(255,255,255,0.15); color: var(--accent); }
.btn-login { background-color: var(--accent); color: var(--text) !important; padding: 10px 25px !important; border-radius: 50px !important; font-weight: 700 !important; margin-left: 15px; box-shadow: 0 4px 15px rgba(251,191,36,0.3); text-shadow: none !important; }
.btn-login:hover { background-color: var(--accent-hover) !important; transform: translateY(-2px); }

/* --- DROPDOWN --- */
.dropdown-menu { position: absolute; top: 100%; left: 0; background: var(--white); min-width: 230px; list-style: none; opacity: 0; visibility: hidden; transform: translateY(10px); box-shadow: 0 10px 30px rgba(0,0,0,0.1); border-radius: 10px; overflow: hidden; transition: 0.3s; }
.dropdown:hover .dropdown-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.dropdown-menu li a { color: var(--text); padding: 15px 20px; border-bottom: 1px solid #eee; border-radius: 0; font-weight: 500; text-shadow: none; }
.dropdown-menu li a:hover { background: var(--bg); color: var(--secondary); padding-left: 25px; }

/* --- HAMBURGER --- */
.hamburger { display: none; cursor: pointer; padding: 10px; }
.bar { display: block; width: 25px; height: 3px; margin: 5px auto; background: var(--white); transition: 0.3s; }
.hamburger.active .bar:nth-child(2) { opacity: 0; }
.hamburger.active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.hamburger.active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ================================================================
   HERO SECTION (index.html)
   ================================================================ */
.hero { height: 100vh; background: linear-gradient(rgba(30, 58, 138, 0.85), rgba(59, 130, 246, 0.7)), url('https://images.unsplash.com/photo-1584551246679-0daf3d275d0f?ixlib=rb-4.0.3&auto=format&fit=crop&w=1920&q=80'); background-size: cover; background-position: center; background-attachment: fixed; display: flex; align-items: center; justify-content: center; text-align: center; padding: 0 20px; position: relative; }
.hero-content { max-width: 800px; color: var(--white); margin-top: -50px; animation: fadeIn 1.5s ease-out; }
.hero-subtitle { font-family: 'Amiri', serif; font-size: 1.5rem; color: var(--accent); margin-bottom: 15px; display: block; text-shadow: 1px 1px 3px rgba(0,0,0,0.2); }
.hero h1 { font-size: 3.5rem; font-weight: 700; margin-bottom: 20px; line-height: 1.2; text-shadow: 2px 2px 5px rgba(0,0,0,0.2); }
.hero p { font-size: 1.1rem; margin-bottom: 30px; color: #fff; font-weight: 400; text-shadow: 1px 1px 3px rgba(0,0,0,0.2); }

/* --- JADWAL SHOLAT OVERLAY --- */
.hero-jadwal-overlay { position: absolute; bottom: 80px; left: 50%; transform: translateX(-50%); width: 90%; max-width: 900px; z-index: 5; animation: fadeIn 2s ease-out; }
.hero-jadwal-inner { background: rgba(15, 30, 80, 0.72); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border: 1px solid rgba(255,255,255,0.18); border-radius: 16px; padding: 18px 28px; display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.jadwal-label { color: var(--accent); font-weight: 700; font-size: 0.85rem; letter-spacing: 1px; text-transform: uppercase; display: flex; align-items: center; gap: 8px; white-space: nowrap; flex-shrink: 0; }
.jadwal-label i { font-size: 1.1rem; }
.jadwal-divider { width: 1px; height: 40px; background: rgba(255,255,255,0.25); flex-shrink: 0; }
.jadwal-cards { display: flex; gap: 8px; flex: 1; flex-wrap: wrap; justify-content: center; }
.jadwal-item { background: rgba(255,255,255,0.1); border-radius: 10px; padding: 8px 14px; text-align: center; min-width: 80px; border: 1px solid rgba(255,255,255,0.15); transition: 0.3s; }
.jadwal-item:hover { background: rgba(255,255,255,0.2); transform: translateY(-2px); }
.jadwal-item.aktif { background: var(--accent); border-color: var(--accent); }
.jadwal-item.aktif .jadwal-name { color: #1a1a1a; }
.jadwal-item.aktif .jadwal-time { color: #1a1a1a; }
.jadwal-name { font-size: 0.72rem; font-weight: 600; color: rgba(255,255,255,0.75); letter-spacing: 0.5px; }
.jadwal-time { font-size: 1rem; font-weight: 700; color: #fff; margin-top: 2px; }
.jadwal-lokasi { font-size: 0.7rem; color: rgba(255,255,255,0.55); margin-top: 2px; }

/* ================================================================
   ABOUT & STATS (index.html)
   ================================================================ */
.about-section { padding: 80px 5%; background: var(--white); display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; max-width: 1200px; margin: 0 auto; }
.about-section-wrap { background: var(--white); padding: 0 0 20px; }
.about-text h2 { font-size: 2rem; color: var(--primary); font-weight: 700; margin-bottom: 6px; }
.about-eyebrow { font-size: 0.8rem; font-weight: 700; letter-spacing: 3px; text-transform: uppercase; color: var(--secondary); display: block; margin-bottom: 12px; }
.about-text .divider-line { width: 50px; height: 4px; background: var(--accent); border-radius: 2px; margin: 12px 0 22px; }
.about-text p { line-height: 1.85; color: #444; margin-bottom: 18px; font-size: 1rem; }
.stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 28px; }
.stat-box { background: var(--bg); padding: 18px 20px; border-radius: 12px; border-left: 4px solid var(--secondary); transition: 0.3s; }
.stat-box:hover { transform: translateX(5px); border-left-color: var(--accent); background: #e0f2fe; }
.stat-number { font-size: 2rem; font-weight: 700; color: var(--primary); line-height: 1; }
.stat-label { color: #555; font-size: 0.88rem; font-weight: 500; margin-top: 4px; }
.about-image img { width: 100%; border-radius: 20px; box-shadow: 20px 20px 0px rgba(30, 58, 138, 0.12); transition: 0.5s; display: block; }
.about-image img:hover { transform: scale(1.02); }

/* ================================================================
   BERITA TERKINI (index.html)
   ================================================================ */
.berita-section { padding: 90px 5% 80px; background: var(--white); }
.section-title-wrap { text-align: center; margin-bottom: 50px; }
.section-eyebrow { font-size: 0.8rem; font-weight: 700; letter-spacing: 3px; text-transform: uppercase; color: var(--secondary); margin-bottom: 10px; display: block; }
.section-title-wrap h2 { font-size: 2.2rem; color: var(--primary); font-weight: 700; position: relative; display: inline-block; }
.section-title-wrap h2::after { content: ''; display: block; width: 60px; height: 4px; background: var(--accent); border-radius: 2px; margin: 14px auto 0; }
.section-title-wrap p { color: #666; margin-top: 16px; font-size: 0.95rem; max-width: 520px; margin-left: auto; margin-right: auto; line-height: 1.7; }
.berita-wrap { max-width: 1300px; margin: 0 auto; }
.berita-featured { position: relative; border-radius: 20px; overflow: hidden; box-shadow: 0 12px 40px rgba(30,58,138,0.15); margin-bottom: 28px; display: block; }
.berita-featured img { width: 100%; height: 520px; object-fit: cover; display: block; transition: transform 0.6s ease; }
.berita-featured:hover img { transform: scale(1.03); }
.berita-featured-overlay { position: absolute; inset: 0; background: linear-gradient(to top, rgba(5,15,50,0.95) 35%, rgba(5,15,50,0.15) 70%, transparent 100%); padding: 44px; display: flex; flex-direction: column; justify-content: flex-end; }
.berita-badge { display: inline-block; width: fit-content; font-size: 0.7rem; font-weight: 700; padding: 5px 14px; border-radius: 20px; letter-spacing: 0.6px; text-transform: uppercase; margin-bottom: 14px; background: var(--accent); color: #1a1a1a; }
.berita-featured-overlay h2 { color: #fff; font-size: 2rem; font-weight: 700; line-height: 1.35; margin-bottom: 12px; max-width: 780px; }
.berita-featured-overlay .kutipan-featured { color: rgba(255,255,255,0.78); font-size: 0.98rem; line-height: 1.65; max-width: 620px; margin-bottom: 22px; }
.berita-meta-bar { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.berita-meta-item { color: rgba(255,255,255,0.6); font-size: 0.82rem; display: flex; align-items: center; gap: 7px; }
.berita-meta-item i { color: var(--accent); }
.btn-baca { display: inline-flex; align-items: center; gap: 8px; background: var(--accent); color: #1a1a1a; font-weight: 700; font-size: 0.88rem; padding: 11px 26px; border-radius: 50px; transition: 0.3s; margin-left: auto; flex-shrink: 0; }
.btn-baca:hover { background: var(--accent-hover); transform: translateY(-2px); box-shadow: 0 6px 18px rgba(251,191,36,0.4); }
.berita-grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.berita-card-v { background: var(--white); border-radius: 16px; overflow: hidden; box-shadow: 0 4px 20px rgba(30,58,138,0.07); border: 1px solid #e8efff; transition: 0.35s; display: flex; flex-direction: column; }
.berita-card-v:hover { transform: translateY(-8px); box-shadow: 0 14px 35px rgba(30,58,138,0.13); border-color: #c7d7ff; }
.bkv-img { position: relative; overflow: hidden; }
.bkv-img img { width: 100%; height: 200px; object-fit: cover; display: block; transition: transform 0.5s ease; }
.berita-card-v:hover .bkv-img img { transform: scale(1.07); }
.bkv-img .berita-badge { position: absolute; top: 12px; left: 12px; margin: 0; }
.bkv-body { padding: 18px 18px 16px; flex: 1; display: flex; flex-direction: column; }
.bkv-body h4 { font-size: 0.96rem; font-weight: 700; color: var(--text); line-height: 1.45; margin-bottom: 9px; }
.bkv-body .kutipan { font-size: 0.83rem; color: #666; line-height: 1.6; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; flex: 1; margin-bottom: 14px; }
.bkv-footer { display: flex; align-items: center; justify-content: space-between; border-top: 1px solid #edf0fb; padding-top: 13px; margin-top: auto; flex-wrap: wrap; gap: 6px; }
.bkv-kiri { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.bkv-badge { font-size: 0.68rem; font-weight: 700; padding: 3px 9px; border-radius: 12px; letter-spacing: 0.4px; text-transform: uppercase; white-space: nowrap; }
.bkv-tgl { font-size: 0.76rem; color: #aaa; display: flex; align-items: center; gap: 5px; }
.bkv-tgl i { color: var(--secondary); }
.bkv-link { font-size: 0.78rem; font-weight: 700; color: var(--secondary); display: flex; align-items: center; gap: 5px; transition: gap 0.2s, color 0.2s; white-space: nowrap; }
.berita-card-v:hover .bkv-link { gap: 8px; color: var(--primary); }
.berita-btn-wrap { text-align: center; margin-top: 40px; }
.btn-outline { display: inline-flex; align-items: center; gap: 8px; border: 2px solid var(--primary); color: var(--primary); font-weight: 600; padding: 12px 32px; border-radius: 50px; transition: 0.3s; font-size: 0.9rem; }
.btn-outline:hover { background: var(--primary); color: #fff; transform: translateY(-2px); box-shadow: 0 6px 20px rgba(30,58,138,0.2); }

/* ================================================================
   PUSAT INFORMASI (index.html)
   ================================================================ */
.info-section { padding: 90px 5%; background: linear-gradient(160deg, #EFF6FF 0%, #DBEAFE 100%); }
.info-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; max-width: 1100px; margin: 0 auto; }
.info-card { background: var(--white); border-radius: 18px; overflow: hidden; box-shadow: 0 6px 25px rgba(30,58,138,0.09); transition: 0.35s; cursor: pointer; }
.info-card:hover { transform: translateY(-8px); box-shadow: 0 18px 40px rgba(30,58,138,0.15); }
.info-card-img { position: relative; overflow: hidden; }
.info-card-img img { width: 100%; height: 210px; object-fit: cover; display: block; transition: transform 0.5s ease; }
.info-card:hover .info-card-img img { transform: scale(1.06); }
.info-card-tag { position: absolute; top: 14px; left: 14px; background: var(--primary); color: #fff; font-size: 0.7rem; font-weight: 700; padding: 4px 12px; border-radius: 20px; letter-spacing: 0.5px; text-transform: uppercase; }
.info-card-body { padding: 22px 22px 8px; }
.info-card-body h3 { font-size: 1.05rem; font-weight: 700; color: var(--text); margin-bottom: 9px; }
.info-card-body p { font-size: 0.87rem; color: #666; line-height: 1.65; }
.info-card-action { max-height: 0; overflow: hidden; transition: max-height 0.38s ease, padding 0.3s ease; padding: 0 22px; }
.info-card.terbuka .info-card-action { max-height: 80px; padding: 14px 22px 22px; }
.btn-info-baca { display: inline-flex; align-items: center; gap: 8px; background: var(--primary); color: #fff; font-weight: 700; font-size: 0.85rem; padding: 10px 22px; border-radius: 50px; transition: 0.3s; }
.btn-info-baca:hover { background: var(--secondary); transform: translateY(-2px); }
.info-klik-hint { font-size: 0.76rem; color: #aaa; text-align: center; padding: 10px 22px 20px; transition: 0.3s; }
.info-card.terbuka .info-klik-hint { display: none; }

/* ================================================================
   FOOTER LENGKAP (index.html)
   ================================================================ */
.footer { background: var(--primary); color: var(--white); padding: 60px 5% 0; margin-top: 0; }
.footer-top { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.2fr; gap: 40px; padding-bottom: 40px; border-bottom: 1px solid rgba(255,255,255,0.12); }
.footer-brand p { color: rgba(255,255,255,0.75); font-size: 0.88rem; line-height: 1.7; margin-top: 12px; margin-bottom: 20px; }
.footer-sosmed { display: flex; gap: 10px; flex-wrap: wrap; }
.footer-sosmed a { width: 38px; height: 38px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 1rem; color: #fff; transition: 0.3s; }
.footer-sosmed a:hover { transform: translateY(-3px); }
.footer-sosmed a.fb { background: #1877F2; }
.footer-sosmed a.ig { background: linear-gradient(135deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); }
.footer-sosmed a.yt { background: #FF0000; }
.footer-sosmed a.wa { background: #25D366; }
.footer h4 { font-family: 'Poppins', sans-serif; font-size: 0.9rem; font-weight: 700; color: var(--accent); margin-bottom: 18px; text-transform: uppercase; letter-spacing: 1px; }
.footer-links { list-style: none; }
.footer-links li { margin-bottom: 10px; }
.footer-links a { color: rgba(255,255,255,0.8); font-size: 0.88rem; transition: 0.3s; display: flex; align-items: center; gap: 8px; }
.footer-links a:hover { color: var(--accent); padding-left: 5px; }
.footer-links a i { font-size: 0.75rem; color: var(--accent); opacity: 0.7; }
.footer-kontak li { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 14px; color: rgba(255,255,255,0.8); font-size: 0.88rem; line-height: 1.5; }
.footer-kontak li i { color: var(--accent); font-size: 0.9rem; margin-top: 3px; flex-shrink: 0; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; padding: 18px 0; font-size: 0.82rem; color: rgba(255,255,255,0.55); flex-wrap: wrap; gap: 10px; }
.footer-bottom a { color: var(--accent); }

/* Footer simpel (halaman profil) */
.copyright { border-top: 1px solid rgba(255,255,255,0.2); padding-top: 20px; font-size: 0.9rem; opacity: 0.8; }

/* ================================================================
   PAGE HERO - BLUR (halaman profil) - UPDATED: Gambar tidak ter-zoom
   ================================================================ */
.page-hero {
    position: relative;
    height: 360px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
}
.page-hero-bg {
    position: absolute;
    inset: -10px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    filter: brightness(0.35);
    transition: filter 0.5s ease;
}
/* Jika pakai gambar upload lokal, jangan terlalu blur */
.page-hero-bg.has-image {
    filter: brightness(0.38) saturate(1.1);
    inset: 0;
}
.page-hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(30,58,138,0.3) 0%, rgba(30,58,138,0.6) 100%);
    z-index: 1;
}
.page-hero-content { position: relative; z-index: 2; color: var(--white); animation: fadeIn 0.8s ease; }
.hero-eyebrow { font-size: 0.8rem; font-weight: 700; letter-spacing: 3px; text-transform: uppercase; color: var(--accent); display: block; margin-bottom: 12px; }
.page-hero-content h1 { font-family: 'Amiri', serif; font-size: 2.8rem; color: var(--white); text-shadow: 2px 2px 8px rgba(0,0,0,0.4); margin-bottom: 10px; }
.page-hero-content p { font-size: 1rem; color: rgba(255,255,255,0.9); font-weight: 400; max-width: 600px; margin: 0 auto; }
.hero-breadcrumb { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); z-index: 2; display: flex; align-items: center; gap: 8px; font-size: 0.8rem; color: rgba(255,255,255,0.7); white-space: nowrap; }
.hero-breadcrumb a { color: var(--accent); }
.hero-breadcrumb i { font-size: 0.65rem; }

/* Dekorasi hero */
.page-hero .hero-pattern {
    position: absolute;
    inset: 0;
    z-index: 1;
    background-image:
        radial-gradient(circle at 20% 80%, rgba(251,191,36,0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(59,130,246,0.08) 0%, transparent 50%);
    pointer-events: none;
}

/* ================================================================
   CONTENT WRAPPER (halaman profil)
   ================================================================ */
.content-wrap { max-width: 1100px; margin: -50px auto 60px; padding: 0 20px; position: relative; z-index: 3; }

/* ================================================================
   CONTENT CARD (dipakai oleh banyak halaman profil)
   ================================================================ */
.content-card { background: var(--white); border-radius: 16px; box-shadow: 0 10px 30px rgba(0,0,0,0.08); padding: 44px 50px; animation: fadeInUp 0.8s ease; }
.content-card h2 { color: var(--primary); font-size: 1.5rem; margin-bottom: 8px; position: relative; display: inline-block; }
.content-card h2::after { content: ''; position: absolute; width: 50%; height: 3px; background: var(--accent); bottom: -8px; left: 0; border-radius: 2px; }
.content-card p { line-height: 1.85; margin-bottom: 20px; color: #444; font-size: 1rem; }
.content-card p:first-of-type { margin-top: 30px; }
.content-card p::first-letter { font-size: 2rem; color: var(--secondary); font-family: 'Amiri', serif; font-weight: bold; float: left; margin-right: 8px; line-height: 1; }

@keyframes fadeInUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }

/* ================================================================
   HALAMAN SAMBUTAN PIMPINAN
   ================================================================ */
.main-wrap { max-width: 1100px; margin: -50px auto 60px; padding: 0 20px; display: grid; grid-template-columns: 300px 1fr; gap: 30px; align-items: start; position: relative; z-index: 3; }
.splash-col { display: flex; flex-direction: column; gap: 16px; }

/* Foto splash pimpinan */
.foto-splash { background: var(--white); border-radius: 16px; box-shadow: 0 10px 30px rgba(0,0,0,0.1); overflow: hidden; }
.foto-splash-preview { width: 100%; height: 320px; position: relative; background: linear-gradient(135deg, #e0f2fe, #dbeafe); display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: pointer; transition: 0.3s; }
.foto-splash-preview:hover { background: linear-gradient(135deg, #bae6fd, #bfdbfe); }
.foto-splash-preview img.foto-preview { width: 100%; height: 100%; object-fit: cover; display: none; }
.foto-splash-preview img.foto-preview.ada { display: block; }
.foto-splash-placeholder { text-align: center; pointer-events: none; }
.foto-splash-placeholder i { font-size: 3rem; color: var(--secondary); opacity: 0.5; display: block; margin-bottom: 12px; }
.foto-splash-placeholder p { font-size: 0.82rem; color: #888; line-height: 1.5; }
.foto-splash-placeholder span { display: block; font-size: 0.7rem; color: #aaa; margin-top: 6px; }
.foto-splash input[type="file"] { display: none; }
.foto-splash-info { padding: 18px 20px; border-top: 1px solid #f0f4ff; }
.foto-splash-info h3 { font-size: 1rem; font-weight: 700; color: var(--primary); margin-bottom: 4px; }
.foto-splash-info p { font-size: 0.82rem; color: #777; }
.btn-upload-foto { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; padding: 10px; margin-top: 10px; background: var(--secondary); color: #fff; border: none; border-radius: 8px; font-size: 0.82rem; font-weight: 600; cursor: pointer; transition: 0.2s; }
.btn-upload-foto:hover { background: var(--primary); }

/* Tanda tangan splash */
.ttd-splash { background: var(--white); border-radius: 16px; box-shadow: 0 10px 30px rgba(0,0,0,0.1); padding: 20px; }
.ttd-splash h4 { font-size: 0.82rem; font-weight: 700; color: var(--primary); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.ttd-preview { width: 100%; height: 90px; background: #f8faff; border: 2px dashed #c7d9f7; border-radius: 10px; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: 0.2s; position: relative; overflow: hidden; }
.ttd-preview:hover { border-color: var(--secondary); background: #eff6ff; }
.ttd-preview img.ttd-img { width: 100%; height: 100%; object-fit: contain; display: none; }
.ttd-preview img.ttd-img.ada { display: block; }
.ttd-hint { font-size: 0.75rem; color: #aaa; text-align: center; pointer-events: none; }
.ttd-hint i { display: block; font-size: 1.4rem; margin-bottom: 5px; color: #c7d9f7; }
.ttd-splash input[type="file"] { display: none; }

/* Konten sambutan */
.penutup { margin-top: 40px; padding-top: 30px; border-top: 1px solid #edf0f7; }
.penutup p { font-weight: 600; color: var(--primary); margin-bottom: 8px; }

/* Sambutan content-card override (no first-letter) */
.sambutan-card p::first-letter { font-size: inherit; color: inherit; font-family: inherit; font-weight: inherit; float: none; margin-right: 0; line-height: inherit; }
.sambutan-card p { margin-top: 0; }
.sambutan-card p:first-of-type { margin-top: 30px; }

/* ================================================================
   HALAMAN SEJARAH
   ================================================================ */
.sejarah-foto-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 30px; }
.splash-foto-box { background: var(--white); border-radius: 14px; box-shadow: 0 8px 24px rgba(0,0,0,0.08); overflow: hidden; cursor: pointer; transition: transform 0.2s, box-shadow 0.2s; }
.splash-foto-box:hover { transform: translateY(-4px); box-shadow: 0 14px 30px rgba(0,0,0,0.12); }
.splash-foto-area { height: 200px; position: relative; background: linear-gradient(135deg, #e0f2fe, #dbeafe); display: flex; flex-direction: column; align-items: center; justify-content: center; transition: 0.2s; }
.splash-foto-area:hover { background: linear-gradient(135deg, #bae6fd, #bfdbfe); }
.splash-foto-area img.foto-preview { width: 100%; height: 100%; object-fit: cover; display: none; }
.splash-foto-area img.foto-preview.ada { display: block; }
.splash-foto-area .ph { text-align: center; pointer-events: none; }
.splash-foto-area .ph i { font-size: 2.2rem; color: var(--secondary); opacity: 0.4; display: block; margin-bottom: 8px; }
.splash-foto-area .ph p { font-size: 0.78rem; color: #999; }
.splash-foto-area input[type="file"] { display: none; }
.splash-foto-caption { padding: 12px 16px; font-size: 0.8rem; color: #555; font-weight: 600; border-top: 1px solid #f0f4ff; background: var(--white); }

/* Timeline */
.timeline { margin-top: 40px; padding-top: 30px; border-top: 1px solid #edf0f7; }
.timeline h3 { color: var(--primary); font-size: 1.1rem; margin-bottom: 24px; }
.tl-item { display: flex; gap: 20px; margin-bottom: 24px; align-items: flex-start; }
.tl-year { background: var(--primary); color: #fff; font-weight: 700; font-size: 0.8rem; padding: 6px 12px; border-radius: 20px; white-space: nowrap; flex-shrink: 0; margin-top: 2px; }
.tl-text { font-size: 0.92rem; color: #555; line-height: 1.6; }

/* ================================================================
   HALAMAN VISI & MISI
   ================================================================ */
.vm-splash { background: var(--white); border-radius: 16px; box-shadow: 0 8px 24px rgba(0,0,0,0.08); overflow: hidden; margin-bottom: 28px; display: grid; grid-template-columns: 1fr 1fr; }
.splash-side { position: relative; height: 220px; background: linear-gradient(135deg, #e0f2fe, #dbeafe); display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: pointer; transition: 0.2s; overflow: hidden; }
.splash-side:first-child { border-right: 2px solid #f0f4ff; }
.splash-side:hover { background: linear-gradient(135deg, #bae6fd, #bfdbfe); }
.splash-side img.foto-preview { width: 100%; height: 100%; object-fit: cover; display: none; position: absolute; inset: 0; }
.splash-side img.foto-preview.ada { display: block; }
.splash-side .ph { text-align: center; pointer-events: none; position: relative; z-index: 1; }
.splash-side .ph i { font-size: 2.5rem; color: var(--secondary); opacity: 0.35; display: block; margin-bottom: 10px; }
.splash-side .ph p { font-size: 0.8rem; color: #888; font-weight: 600; }
.splash-side .ph span { font-size: 0.7rem; color: #aaa; }
.splash-side input[type="file"] { display: none; }
.splash-side .side-label { position: absolute; bottom: 0; left: 0; right: 0; background: rgba(30,58,138,0.75); color: #fff; font-size: 0.75rem; font-weight: 600; padding: 8px 14px; text-align: center; z-index: 2; }

/* Konten visi misi */
.section-title { color: var(--primary); font-size: 1.15rem; font-weight: 700; margin-bottom: 20px; display: flex; align-items: center; gap: 12px; }
.section-title i { width: 38px; height: 38px; background: var(--primary); color: #fff; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 1rem; flex-shrink: 0; }
.visi-text { font-family: 'Amiri', serif; font-size: 1.35rem; color: var(--primary); background: linear-gradient(135deg, #eff6ff, #e0f2fe); border-left: 5px solid var(--accent); padding: 22px 26px; border-radius: 0 12px 12px 0; line-height: 1.7; margin-bottom: 14px; }
.vm-divider { border: 0; border-top: 1px solid #edf0f7; margin: 36px 0; }
.misi-list { list-style: none; padding: 0; }
.misi-list li { display: flex; align-items: flex-start; gap: 14px; padding: 14px 18px; border-radius: 10px; margin-bottom: 10px; background: #f8faff; border: 1px solid #edf0f7; font-size: 0.95rem; color: #444; line-height: 1.6; transition: 0.2s; }
.misi-list li:hover { background: #eff6ff; border-color: #bfdbfe; }
.misi-list li::before { content: ''; width: 22px; height: 22px; flex-shrink: 0; background: var(--accent); border-radius: 50%; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%231E3A8A'%3E%3Cpath fill-rule='evenodd' d='M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z' clip-rule='evenodd'/%3E%3C/svg%3E"); background-size: 14px; background-position: center; background-repeat: no-repeat; margin-top: 2px; }
.nilai-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 36px; padding-top: 30px; border-top: 1px solid #edf0f7; }
.nilai-item { background: linear-gradient(135deg, #eff6ff, #e0f2fe); border-radius: 12px; padding: 20px; text-align: center; transition: transform 0.3s, box-shadow 0.3s; }
.nilai-item:hover { transform: translateY(-4px); box-shadow: 0 8px 20px rgba(30,58,138,0.1); }
.nilai-item i { font-size: 1.6rem; color: var(--primary); margin-bottom: 10px; display: block; }
.nilai-item h4 { font-size: 0.9rem; color: var(--primary); font-weight: 700; }

/* ================================================================
   HALAMAN GURU / ASATIDZ
   ================================================================ */
.section-head { background: var(--white); border-radius: 16px; box-shadow: 0 8px 24px rgba(0,0,0,0.07); padding: 28px 36px; margin-bottom: 28px; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 14px; }
.section-head h2 { color: var(--primary); font-size: 1.3rem; position: relative; display: inline-block; }
.section-head h2::after { content: ''; position: absolute; width: 50%; height: 3px; background: var(--accent); bottom: -8px; left: 0; border-radius: 2px; }
.section-head p { color: #777; font-size: 0.88rem; margin-top: 14px; }
.guru-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.guru-card { background: var(--white); border-radius: 16px; box-shadow: 0 8px 24px rgba(0,0,0,0.07); overflow: hidden; transition: transform 0.25s, box-shadow 0.25s; animation: fadeInUp 0.6s ease both; }
.guru-card:hover { transform: translateY(-6px); box-shadow: 0 18px 40px rgba(30,58,138,0.13); }
.guru-foto-splash { width: 100%; height: 220px; position: relative; background: linear-gradient(135deg, #e0f2fe, #dbeafe); display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: pointer; overflow: hidden; transition: 0.2s; }
.guru-foto-splash:hover { background: linear-gradient(135deg, #bae6fd, #bfdbfe); }
.guru-foto-splash img.foto-guru { width: 100%; height: 100%; object-fit: cover; display: none; position: absolute; inset: 0; }
.guru-foto-splash img.foto-guru.ada { display: block; }
.guru-foto-splash .splash-ph { text-align: center; pointer-events: none; position: relative; z-index: 1; }
.guru-foto-splash .splash-ph i { font-size: 3rem; color: var(--secondary); opacity: 0.3; display: block; margin-bottom: 8px; }
.guru-foto-splash .splash-ph p { font-size: 0.75rem; color: #aaa; }
.guru-foto-splash input[type="file"] { display: none; }
.jabatan-badge { position: absolute; top: 10px; right: 10px; z-index: 2; background: var(--accent); color: var(--primary); font-size: 0.65rem; font-weight: 800; padding: 4px 10px; border-radius: 20px; text-transform: uppercase; letter-spacing: 0.5px; }
.jabatan-badge.biru { background: var(--primary); color: #fff; }
.guru-info { padding: 18px 20px 22px; text-align: center; }
.guru-info h3 { font-size: 0.95rem; font-weight: 700; color: var(--primary); margin-bottom: 4px; }
.guru-info p { font-size: 0.78rem; color: #777; margin-bottom: 14px; }
.guru-sosmed { display: flex; justify-content: center; gap: 8px; }
.guru-sosmed a { width: 32px; height: 32px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 0.85rem; color: #fff; transition: 0.2s; }
.guru-sosmed a:hover { transform: translateY(-2px); }
.guru-sosmed a.li { background: #0077B5; }
.guru-sosmed a.wa { background: #25D366; }
.btn-ganti-foto { width: 100%; padding: 8px; margin-top: 6px; background: #f0f4ff; color: var(--secondary); border: 1px solid #dbeafe; border-radius: 8px; font-size: 0.75rem; font-weight: 600; cursor: pointer; transition: 0.2s; display: flex; align-items: center; justify-content: center; gap: 6px; }
.btn-ganti-foto:hover { background: var(--secondary); color: #fff; }
.guru-card:nth-child(2) { animation-delay: 0.1s; }
.guru-card:nth-child(3) { animation-delay: 0.2s; }
.guru-card:nth-child(4) { animation-delay: 0.3s; }

/* ================================================================
   HALAMAN FASILITAS
   ================================================================ */
.splash-utama { background: var(--white); border-radius: 16px; box-shadow: 0 10px 30px rgba(0,0,0,0.08); overflow: hidden; margin-bottom: 28px; cursor: pointer; }
.splash-utama-area { width: 100%; height: 280px; position: relative; background: linear-gradient(135deg, #e0f2fe, #dbeafe); display: flex; flex-direction: column; align-items: center; justify-content: center; transition: 0.2s; }
.splash-utama-area:hover { background: linear-gradient(135deg, #bae6fd, #bfdbfe); }
.splash-utama-area img.foto-utama { width: 100%; height: 100%; object-fit: cover; display: none; position: absolute; inset: 0; }
.splash-utama-area img.foto-utama.ada { display: block; }
.splash-utama-area .ph { text-align: center; pointer-events: none; position: relative; z-index: 1; }
.splash-utama-area .ph i { font-size: 3.5rem; color: var(--secondary); opacity: 0.3; display: block; margin-bottom: 14px; }
.splash-utama-area .ph p { font-size: 0.9rem; color: #888; font-weight: 600; }
.splash-utama-area .ph span { font-size: 0.78rem; color: #aaa; margin-top: 4px; display: block; }
.splash-utama-area input[type="file"] { display: none; }
.splash-utama-caption { padding: 16px 24px; display: flex; align-items: center; justify-content: space-between; }
.splash-utama-caption span { font-size: 0.88rem; color: #555; font-weight: 600; }
.btn-ubah { background: var(--secondary); color: #fff; border: none; padding: 8px 18px; border-radius: 8px; font-size: 0.78rem; font-weight: 600; cursor: pointer; display: flex; align-items: center; gap: 7px; transition: 0.2s; }
.btn-ubah:hover { background: var(--primary); }
.fasilitas-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 28px; }
.fas-card { background: var(--white); border-radius: 14px; box-shadow: 0 6px 20px rgba(0,0,0,0.06); overflow: hidden; transition: transform 0.2s, box-shadow 0.2s; animation: fadeInUp 0.6s ease both; }
.fas-card:hover { transform: translateY(-5px); box-shadow: 0 14px 30px rgba(30,58,138,0.12); }
.fas-foto-splash { width: 100%; height: 160px; position: relative; background: linear-gradient(135deg, #e0f2fe, #dbeafe); display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: pointer; transition: 0.2s; overflow: hidden; }
.fas-foto-splash:hover { background: linear-gradient(135deg, #bae6fd, #bfdbfe); }
.fas-foto-splash img.foto-fas { width: 100%; height: 100%; object-fit: cover; display: none; position: absolute; inset: 0; }
.fas-foto-splash img.foto-fas.ada { display: block; }
.fas-foto-splash .ph { text-align: center; pointer-events: none; position: relative; z-index: 1; }
.fas-foto-splash .ph i.icon-fas { font-size: 2rem; display: block; margin-bottom: 6px; }
.fas-foto-splash .ph p { font-size: 0.7rem; color: #aaa; }
.fas-foto-splash input[type="file"] { display: none; }
.fas-info { padding: 14px 16px 16px; }
.fas-info h4 { font-size: 0.88rem; font-weight: 700; color: var(--primary); margin-bottom: 4px; }
.fas-info p { font-size: 0.75rem; color: #888; line-height: 1.5; }
.btn-foto-fas { width: 100%; padding: 7px; margin-top: 10px; background: #f0f4ff; color: var(--secondary); border: 1px solid #dbeafe; border-radius: 7px; font-size: 0.72rem; font-weight: 600; cursor: pointer; transition: 0.2s; display: flex; align-items: center; justify-content: center; gap: 5px; }
.btn-foto-fas:hover { background: var(--secondary); color: #fff; }
.fas-card:nth-child(2) { animation-delay: 0.08s; }
.fas-card:nth-child(3) { animation-delay: 0.16s; }
.fas-card:nth-child(4) { animation-delay: 0.24s; }
.fas-card:nth-child(5) { animation-delay: 0.32s; }
.fas-card:nth-child(6) { animation-delay: 0.4s; }
.fas-card:nth-child(7) { animation-delay: 0.48s; }
.fas-card:nth-child(8) { animation-delay: 0.56s; }

/* ================================================================
   RTL SUPPORT (index.html)
   ================================================================ */
html[dir="rtl"] body { font-family: 'Amiri', 'Cairo', serif; }
html[dir="rtl"] .navbar { flex-direction: row-reverse; }
html[dir="rtl"] .nav-links { flex-direction: row-reverse; }
html[dir="rtl"] .dropdown-menu { left: auto; right: 0; }
html[dir="rtl"] .footer-top { direction: rtl; }
html[dir="rtl"] .footer-links a { flex-direction: row-reverse; padding-left: 0; }
html[dir="rtl"] .footer-links a:hover { padding-left: 0; padding-right: 5px; }
html[dir="rtl"] .footer-kontak li { flex-direction: row-reverse; text-align: right; }
html[dir="rtl"] .about-text { text-align: right; direction: rtl; }
html[dir="rtl"] .about-text .divider-line { margin-left: auto; margin-right: 0; }
html[dir="rtl"] .stat-box { border-left: none; border-right: 4px solid var(--secondary); }
html[dir="rtl"] .stat-box:hover { transform: translateX(-5px); border-right-color: var(--accent); }
html[dir="rtl"] .berita-featured-overlay { text-align: right; direction: rtl; }
html[dir="rtl"] .berita-meta-bar { flex-direction: row-reverse; }
html[dir="rtl"] .btn-baca { margin-left: 0; margin-right: auto; }
html[dir="rtl"] .bkv-body { text-align: right; direction: rtl; }
html[dir="rtl"] .bkv-footer { flex-direction: row-reverse; }
html[dir="rtl"] .bkv-kiri { flex-direction: row-reverse; }
html[dir="rtl"] .info-card-body { text-align: right; direction: rtl; }
html[dir="rtl"] .section-title-wrap { direction: rtl; }
html[dir="rtl"] .hero-content { direction: rtl; }
html[dir="rtl"] .hamburger { order: -1; }

/* ================================================================
   MEDIA QUERIES
   ================================================================ */
@media (max-width: 768px) {
    html[dir="rtl"] .nav-links { flex-direction: column; }
}
@media (max-width: 1100px) {
    .footer-top { grid-template-columns: 1fr 1fr; }
    .berita-grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 991px) {
    .hero h1 { font-size: 2.5rem; }
    .about-section { grid-template-columns: 1fr; gap: 30px; }
    .about-image { order: -1; }
    .berita-featured img { height: 340px; }
    .berita-featured-overlay { padding: 28px; }
    .berita-featured-overlay h2 { font-size: 1.5rem; }
    .info-grid-3 { grid-template-columns: 1fr; max-width: 480px; }
    .hero-jadwal-overlay { bottom: 20px; }
}
@media (max-width: 900px) {
    .guru-grid { grid-template-columns: repeat(2, 1fr); }
    .fasilitas-grid { grid-template-columns: repeat(2, 1fr); }
    .main-wrap { grid-template-columns: 1fr; margin-top: -30px; }
    .splash-col { flex-direction: row; flex-wrap: wrap; }
    .foto-splash { flex: 1; min-width: 240px; }
    .ttd-splash { flex: 1; min-width: 240px; }
    .foto-splash-preview { height: 260px; }
}
@media (max-width: 768px) {
    .hamburger { display: block; }
    .nav-links { position: fixed; top: 80px; left: -100%; width: 100%; height: calc(100vh - 80px); background: var(--primary); flex-direction: column; padding-top: 20px; transition: 0.4s ease; overflow-y: auto; }
    .nav-links.active { left: 0; }
    .nav-links li { width: 100%; text-align: center; }
    .nav-links li a { justify-content: center; padding: 15px; }
    .dropdown-menu { position: static; width: 100%; box-shadow: none; background: rgba(0,0,0,0.05); display: none; opacity: 1; visibility: visible; transform: none; border-radius: 0; }
    .dropdown.active .dropdown-menu { display: block; }
    .btn-login { margin: 15px auto; width: 80%; display: block; }
    /* Hero index */
    .hero-jadwal-inner { flex-direction: column; align-items: flex-start; gap: 12px; }
    .jadwal-divider { display: none; }
    .jadwal-cards { justify-content: flex-start; }
    .berita-grid-4 { grid-template-columns: 1fr; }
    .berita-featured img { height: 260px; }
    .berita-meta-bar { gap: 12px; }
    .btn-baca { margin-left: 0; margin-top: 14px; }
    .berita-featured-overlay { padding: 22px; }
    .info-grid-3 { grid-template-columns: 1fr; }
    .footer-top { grid-template-columns: 1fr; gap: 30px; }
    .footer-bottom { flex-direction: column; text-align: center; }
    /* Page hero profil */
    .page-hero { height: 280px; }
    .page-hero-content h1 { font-size: 2rem; }
    /* Sejarah */
    .sejarah-foto-row { grid-template-columns: 1fr; }
    /* Visi Misi */
    .vm-splash { grid-template-columns: 1fr; }
    .splash-side:first-child { border-right: none; border-bottom: 2px solid #f0f4ff; }
    .nilai-grid { grid-template-columns: 1fr 1fr; }
    /* Fasilitas */
    .splash-utama-area { height: 200px; }
    .fasilitas-grid { grid-template-columns: repeat(2, 1fr); }
    /* Sambutan */
    .splash-col { flex-direction: column; }
    /* Semua content card */
    .content-card { padding: 28px 22px; }
}
@media (max-width: 480px) {
    .guru-grid { grid-template-columns: 1fr; }
    .fasilitas-grid { grid-template-columns: 1fr; }
}
/* ================================================================
   HALAMAN PUBLIK PHP (public/profil, public/kesiswaan, public/informasi)
   Menggunakan tema biru yang sama dengan index.html
   ================================================================ */
.content-container { max-width: 1100px; margin: -40px auto 50px; background: var(--white); padding: 50px; border-radius: 15px; box-shadow: 0 10px 30px rgba(0,0,0,0.08); position: relative; animation: fadeInUp 0.8s ease; }
.content-container h2 { color: var(--primary); margin-bottom: 25px; position: relative; display: inline-block; font-size: 1.5rem; }
.content-container h2::after { content: ''; position: absolute; width: 50%; height: 3px; background: var(--accent); bottom: -8px; left: 0; border-radius: 2px; }
.content-container p { line-height: 1.85; margin-bottom: 15px; color: #444; font-size: 1rem; }
.content-container h3 { color: var(--primary); margin: 25px 0 10px; font-size: 1.1rem; font-weight: 700; }
.content-container h4 { color: var(--primary); margin: 20px 0 8px; font-size: 1rem; font-weight: 700; }
.content-container ul { margin: 0 0 15px 20px; }
.content-container ul li { line-height: 1.9; color: #444; }
.content-container ol { margin: 0 0 15px 20px; }
.content-container ol li { line-height: 1.9; color: #444; }
.content-container img { max-width: 100%; border-radius: 10px; margin: 10px 0; }
/* Halaman publik - navbar sticky bukan fixed */
.navbar-sticky { position: sticky; top: 0; }
/* Footer simpel halaman publik */
.footer-simple { background: var(--primary); color: var(--white); padding: 30px 5%; text-align: center; margin-top: auto; }
.footer-simple .copyright { border-top: 1px solid rgba(255,255,255,0.2); padding-top: 20px; font-size: 0.9rem; opacity: 0.8; }
@media (max-width: 768px) {
    .content-container { padding: 30px 20px; margin: -20px 20px 40px; }
}

/* ================================================================
   V2 — GLOBAL: HALUS, RAPI, RESPONSIF
   ================================================================ */
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
img, video, iframe { max-width: 100%; }
a, button { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
::selection { background: rgba(251,191,36,0.35); }

@keyframes riseIn   { from { opacity: 0; transform: translate3d(0, 26px, 0); } to { opacity: 1; transform: none; } }
@keyframes fadeInDown { from { opacity: 0; transform: translate3d(0, -20px, 0); } to { opacity: 1; transform: none; } }
@keyframes bnIn     { from { opacity: 0; transform: translate3d(0, 18px, 0) scale(.985); } to { opacity: 1; transform: none; } }

/* Navbar: transisi halus saat discroll */
.navbar { transition: background .4s ease, box-shadow .4s ease, padding .4s cubic-bezier(.22,1,.36,1); }
.navbar.scrolled { background: rgba(15, 25, 60, 0.97); box-shadow: 0 8px 30px rgba(0,0,0,0.18); }
.nav-links li a { transition: background .25s ease, color .25s ease, transform .25s ease; }

/* Muncul halus saat di-scroll (aktif hanya jika JS jalan) */
html.js .reveal { opacity: 0; transform: translate3d(0, 28px, 0); transition: opacity .85s cubic-bezier(.22,1,.36,1), transform .85s cubic-bezier(.22,1,.36,1); transition-delay: var(--d, 0s); will-change: opacity, transform; }
html.js .reveal.from-left  { transform: translate3d(-34px, 0, 0); }
html.js .reveal.from-right { transform: translate3d(34px, 0, 0); }
html.js .reveal.zoom       { transform: scale(.96); }
html.js .reveal.in { opacity: 1; transform: none; will-change: auto; }

/* ================================================================
   BANNER HALAMAN (profil & kesiswaan)
   Gambar tampil UTUH sesuai hasil crop di admin: rasio banner
   mengikuti rasio gambar, tidak di-zoom / dipotong.
   ================================================================ */
.pg-banner {
    --r: 1.7778;
    position: relative;
    display: grid;
    width: min(calc(100% - 40px), 1060px, calc(var(--r) * 78vh));
    aspect-ratio: var(--r);
    margin: 24px auto 0;
    border-radius: 22px;
    overflow: hidden;
    background: #0f2561;
    box-shadow: 0 20px 50px rgba(15,37,97,0.22);
    isolation: isolate;
    animation: bnIn .9s cubic-bezier(.22,1,.36,1) both;
}
.pg-banner__img {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    object-fit: cover;          /* wadah memakai rasio gambar, jadi tidak ada bagian yang terpotong */
    display: block;
    opacity: 0;
    transition: opacity .8s ease;
}
.pg-banner__img.is-loaded { opacity: 1; }
.pg-banner::after {              /* bayangan tipis hanya di bagian bawah agar teks terbaca; gambar tetap jernih */
    content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none;
    background: linear-gradient(180deg, rgba(6,12,30,0.28) 0%, rgba(6,12,30,0) 22%, rgba(6,12,30,0) 38%, rgba(6,12,30,0.86) 100%);
}
.pg-banner .hero-pattern { display: none; }
.pg-banner .page-hero-content {
    position: relative; z-index: 3;
    grid-area: 1 / 1; align-self: end;
    width: 100%; max-width: 820px;
    padding: clamp(20px, 3.6vw, 44px);
    text-align: left; color: #fff; animation: none;
}
.pg-banner .hero-eyebrow {
    display: inline-block; font-size: .74rem; font-weight: 700; letter-spacing: .18em; text-transform: uppercase;
    color: var(--accent); margin-bottom: 10px; text-shadow: 0 1px 10px rgba(0,0,0,0.65);
    animation: riseIn .8s cubic-bezier(.22,1,.36,1) .15s both;
}
.pg-banner .page-hero-content h1 {
    font-family: 'Amiri', serif; font-size: clamp(1.7rem, 4.4vw, 3rem); line-height: 1.15;
    color: #fff; margin: 0 0 10px; text-shadow: 0 2px 14px rgba(0,0,0,0.45);
    animation: riseIn .9s cubic-bezier(.22,1,.36,1) .25s both;
}
.pg-banner .page-hero-content p {
    font-size: clamp(.88rem, 1.6vw, 1.05rem); line-height: 1.6; color: rgba(255,255,255,0.94);
    margin: 0; max-width: 62ch; text-shadow: 0 1px 8px rgba(0,0,0,0.4);
    animation: riseIn .9s cubic-bezier(.22,1,.36,1) .38s both;
}
.pg-banner .hero-breadcrumb {
    position: relative; left: auto; bottom: auto; transform: none; white-space: normal;
    grid-area: 1 / 1; align-self: start; justify-self: start; z-index: 3;
    margin: 16px 18px; padding: 6px 13px; border-radius: 999px;
    display: inline-flex; align-items: center; gap: 8px; font-size: .78rem; color: #fff;
    background: rgba(8,15,40,0.45); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
    animation: fadeIn .9s ease .5s both;
}
.pg-banner .hero-breadcrumb a { color: var(--accent); }

/* Tanpa gambar: banner polos bergradasi */
.pg-banner.is-plain {
    aspect-ratio: auto; min-height: clamp(220px, 30vw, 320px);
    background: radial-gradient(900px 320px at 12% 0%, rgba(59,130,246,0.5), transparent 60%), linear-gradient(135deg, #0f2561, #1E3A8A 60%, #2563eb);
}
.pg-banner.is-plain::after { display: none; }

/* Konten tepat di bawah banner tidak lagi menimpa gambar */
.pg-banner ~ .content-wrap, .pg-banner ~ .main-wrap, .pg-banner ~ .sambutan-wrap { margin-top: 28px !important; }

@media (max-width: 640px) {
    .pg-banner { display: block; width: calc(100% - 24px); aspect-ratio: auto; margin-top: 14px; border-radius: 16px; background: linear-gradient(135deg, #0f2561, #1E3A8A); }
    .pg-banner__img { position: static; height: auto; aspect-ratio: var(--r); }
    .pg-banner::after { display: none; }
    .pg-banner .hero-breadcrumb { position: absolute; top: 0; left: 0; margin: 10px; font-size: .7rem; padding: 5px 10px; }
    .pg-banner .page-hero-content { padding: 18px 18px 22px; max-width: none; }
    .pg-banner.is-plain { min-height: 0; }
    .pg-banner.is-plain .page-hero-content { padding-top: 54px; }
    .pg-banner ~ .content-wrap, .pg-banner ~ .main-wrap, .pg-banner ~ .sambutan-wrap { margin-top: 18px !important; }
}

/* Foto banner di dalam isi halaman: utuh, tidak dipotong */
.banner-content-img { width: 100%; border-radius: 14px; overflow: hidden; box-shadow: 0 4px 20px rgba(0,0,0,0.08); margin-bottom: 28px; background: #eef3ff; }
.banner-content-img img { width: 100%; height: auto; max-height: 76vh; object-fit: contain; display: block; }

/* ================================================================
   HEADER HALAMAN INFORMASI (berita, pengumuman, galeri, artikel)
   Ringkas dan rapi — tidak lagi dipaksa 16:9
   ================================================================ */
.page-header {
    position: relative; overflow: hidden; text-align: center; color: #fff; margin: 0;
    padding: clamp(56px, 9vw, 92px) 20px clamp(84px, 11vw, 116px);
    background: radial-gradient(1100px 380px at 14% -10%, rgba(59,130,246,0.45), transparent 60%), linear-gradient(135deg, #0f2561, #1E3A8A 55%, #2563eb);
}
.page-header h1 {
    font-family: 'Amiri', serif; font-size: clamp(1.9rem, 4.6vw, 2.9rem); line-height: 1.2; color: #fff; margin: 0;
    animation: riseIn .85s cubic-bezier(.22,1,.36,1) both;
}
.page-header h1::after { content: ''; display: block; width: 56px; height: 4px; border-radius: 2px; background: var(--accent); margin: 14px auto 0; }
.page-header p {
    max-width: 680px; margin: 14px auto 0; color: rgba(255,255,255,0.88); font-size: clamp(.9rem, 1.8vw, 1.05rem); line-height: 1.65;
    animation: riseIn .85s cubic-bezier(.22,1,.36,1) .15s both;
}
.content-container { margin-top: -56px; z-index: 2; }
@media (max-width: 768px) { .content-container { margin-top: -40px; } }

/* ================================================================
   RESPONSIF TAMBAHAN
   ================================================================ */
@media (max-width: 768px) {
    .navbar { padding: 0 4%; }
    .brand-text { font-size: .8rem; }
    .brand-text span { font-size: 1rem; }
    .nav-links { box-shadow: 0 20px 40px rgba(0,0,0,0.25); }
}
/* Navbar di lebar menengah: tombol tidak patah baris */
@media (min-width: 769px) and (max-width: 1020px) {
    .nav-links { gap: 2px; }
    .nav-links li a { padding: 10px 9px; font-size: 14px; }
    .btn-login { margin-left: 6px; padding: 10px 16px !important; white-space: nowrap; }
    .brand-text { white-space: nowrap; }
    .brand-logo { flex-shrink: 0; }
}
/* Tablet potret (±769-900px, mis. iPad): navbar dirapatkan supaya tombol "Daftar PSB" tidak terpotong */
@media (min-width: 769px) and (max-width: 900px) {
    .navbar { padding: 0 3%; }
    .brand-container { gap: 8px; }
    .brand-text { font-size: .72rem; }
    .brand-text span { font-size: .95rem; letter-spacing: .2px; }
    .nav-links li a { padding: 10px 6px; font-size: 13px; }
    .btn-login { margin-left: 3px; padding: 9px 12px !important; }
}
@media (max-width: 480px) {
    .content-card { padding: 22px 16px; border-radius: 14px; }
    .content-container { padding: 22px 16px; margin-left: 12px; margin-right: 12px; }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
    html.js .reveal { opacity: 1; transform: none; }
}