/* =====================================================================
   landing.css
   Tema: BLUE CRYSTAL GLASS UI
   Website Publik Pesantren (Landing Page)
   ===================================================================== */

:root {
    --deep-navy: #061A40;
    --crystal-blue: #0B5ED7;
    --sky-blue: #48CAE4;
    --gold-accent: #D4AF37;
    --glass-bg: rgba(255, 255, 255, 0.10);
    --glass-bg-strong: rgba(255, 255, 255, 0.16);
    --glass-border: rgba(255, 255, 255, 0.22);
    --glass-shadow: rgba(6, 26, 64, 0.35);
    --text-light: #F4F8FB;
    --text-muted: #C7D3E0;
    --section-pad: 90px;
}

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

html { scroll-behavior: smooth; }

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--deep-navy);
    color: var(--text-light);
    line-height: 1.6;
    overflow-x: hidden;
}

img { max-width: 100%; display: block; }

.container {
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 24px;
}

a { color: inherit; text-decoration: none; }

.section-tag {
    display: inline-block;
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--gold-accent);
    background: rgba(212,175,55,0.12);
    border: 1px solid rgba(212,175,55,0.3);
    padding: 6px 16px;
    border-radius: 30px;
    margin-bottom: 14px;
}

.section-title {
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 14px;
    line-height: 1.25;
}

.section-desc {
    color: var(--text-muted);
    font-size: 14.5px;
    max-width: 620px;
    margin-bottom: 42px;
}

.section-head { text-align: center; }
.section-head .section-desc { margin-left: auto; margin-right: auto; }

section { padding: var(--section-pad) 0; position: relative; }

/* ---------------- Navbar ---------------- */
.navbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 100;
    background: rgba(6, 26, 64, 0.55);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-bottom: 1px solid var(--glass-border);
    transition: background 0.3s ease;
}

.navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 74px;
}

.navbar .brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    font-size: 15.5px;
}

.navbar .brand .logo-circle {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--sky-blue), var(--crystal-blue));
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 15px;
    box-shadow: 0 8px 18px rgba(11,94,215,0.45);
    overflow: hidden;
    flex-shrink: 0;
}

.logo-circle-img {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
    padding: 6px;
}

.logo-circle-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.navbar .nav-links {
    display: flex;
    align-items: center;
    gap: 4px;
    list-style: none;
}

.navbar .nav-links a {
    font-size: 13.2px;
    font-weight: 600;
    color: var(--text-muted);
    padding: 9px 13px;
    border-radius: 10px;
    transition: all 0.2s ease;
}

.navbar .nav-links a:hover { color: #fff; background: rgba(255,255,255,0.08); }

.navbar .nav-actions { display: flex; align-items: center; gap: 10px; }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 22px;
    border-radius: 12px;
    font-size: 13.5px;
    font-weight: 700;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-primary {
    background: linear-gradient(135deg, var(--sky-blue), var(--crystal-blue));
    color: #fff;
    box-shadow: 0 10px 24px rgba(11,94,215,0.4);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(11,94,215,0.55); }

.btn-outline {
    background: rgba(255,255,255,0.08);
    color: #fff;
    border: 1px solid var(--glass-border);
}
.btn-outline:hover { background: rgba(255,255,255,0.16); }

.btn-gold {
    background: linear-gradient(135deg, var(--gold-accent), #b8912c);
    color: #061A40;
    box-shadow: 0 10px 24px rgba(212,175,55,0.35);
}
.btn-gold:hover { transform: translateY(-2px); }

.nav-toggle { display: none; background: none; border: none; color: #fff; font-size: 22px; cursor: pointer; }

/* ---------------- Hero ---------------- */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 100px;
    background:
        radial-gradient(circle at 12% 20%, rgba(72, 202, 228, 0.30), transparent 45%),
        radial-gradient(circle at 88% 75%, rgba(212, 175, 55, 0.18), transparent 40%),
        linear-gradient(155deg, var(--deep-navy) 0%, #0a2a5e 45%, var(--crystal-blue) 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    width: 420px; height: 420px;
    border-radius: 50%;
    background: rgba(72,202,228,0.18);
    filter: blur(80px);
    top: -100px; right: -80px;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: 50px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-content h1 {
    font-size: 44px;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 18px;
}

.hero-content h1 span {
    background: linear-gradient(90deg, var(--sky-blue), var(--gold-accent));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-content p {
    color: var(--text-muted);
    font-size: 15.5px;
    max-width: 520px;
    margin-bottom: 30px;
}

.hero-actions { display: flex; gap: 14px; margin-bottom: 46px; flex-wrap: wrap; }

.hero-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    max-width: 520px;
}

.hero-stats .stat-box {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 16px 12px;
    text-align: center;
    backdrop-filter: blur(14px);
}

.hero-stats .stat-box .num {
    font-size: 24px;
    font-weight: 800;
    color: var(--gold-accent);
}

.hero-stats .stat-box .lbl {
    font-size: 11.5px;
    color: var(--text-muted);
    margin-top: 4px;
}

.hero-visual {
    position: relative;
    border-radius: 28px;
    overflow: hidden;
    border: 1px solid var(--glass-border);
    box-shadow: 0 30px 70px rgba(6,26,64,0.5);
    aspect-ratio: 4/5;
    background: linear-gradient(160deg, rgba(72,202,228,0.25), rgba(11,94,215,0.35));
}

.hero-visual img { width: 100%; height: 100%; object-fit: cover; }

.hero-visual .float-badge {
    position: absolute;
    bottom: 22px; left: 22px; right: 22px;
    background: var(--glass-bg-strong);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(16px);
    border-radius: 16px;
    padding: 16px 18px;
    font-size: 12.5px;
    color: var(--text-light);
}

/* ---------------- Glass Card ---------------- */
.glass-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 15px 35px var(--glass-shadow), inset 0 1px 0 rgba(255,255,255,0.1);
}

/* ---------------- Profil ---------------- */
.profil-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 26px;
    flex-wrap: wrap;
}

.profil-tab-btn {
    padding: 10px 20px;
    border-radius: 12px;
    background: rgba(255,255,255,0.06);
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.profil-tab-btn.active {
    background: linear-gradient(135deg, var(--sky-blue), var(--crystal-blue));
    color: #fff;
    border-color: transparent;
}

.profil-panel { display: none; padding: 30px; }
.profil-panel.active { display: block; }
.profil-panel h3 { font-size: 19px; margin-bottom: 12px; color: var(--gold-accent); }
.profil-panel p { color: var(--text-muted); font-size: 14px; margin-bottom: 12px; }
.profil-panel ul { color: var(--text-muted); font-size: 14px; padding-left: 20px; }
.profil-panel li { margin-bottom: 8px; }

/* ---------------- Program Cards ---------------- */
.program-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 20px;
}

.program-card {
    padding: 26px 22px;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.program-card:hover { transform: translateY(-6px); box-shadow: 0 22px 45px rgba(6,26,64,0.5); }

.program-card .icon {
    width: 52px; height: 52px;
    border-radius: 15px;
    background: linear-gradient(135deg, var(--sky-blue), var(--crystal-blue));
    display: flex; align-items: center; justify-content: center;
    font-size: 22px;
    margin-bottom: 16px;
    box-shadow: 0 10px 22px rgba(11,94,215,0.4);
}

.program-card h3 { font-size: 16px; margin-bottom: 8px; }
.program-card p { font-size: 13px; color: var(--text-muted); }

/* ---------------- Kegiatan / Berita / Galeri Cards ---------------- */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.media-card { overflow: hidden; }

.media-card .thumb {
    width: 100%;
    aspect-ratio: 16/10;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(72,202,228,0.3), rgba(11,94,215,0.4));
}

.media-card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.media-card:hover .thumb img { transform: scale(1.06); }

.media-card .body { padding: 20px; }

.media-card .meta {
    font-size: 11.5px;
    color: var(--gold-accent);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.media-card h3 { font-size: 16px; margin-bottom: 8px; line-height: 1.4; }
.media-card p { font-size: 13px; color: var(--text-muted); }

/* ---------------- Tahfidz Highlight ---------------- */
.tahfidz-wrap {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}

.tahfidz-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 24px; }
.tahfidz-stats .stat-box { padding: 18px; text-align: center; }
.tahfidz-stats .stat-box .num { font-size: 26px; font-weight: 800; color: var(--sky-blue); }
.tahfidz-stats .stat-box .lbl { font-size: 12px; color: var(--text-muted); margin-top: 4px; }

/* ---------------- Prestasi ---------------- */
.prestasi-list { display: flex; flex-direction: column; gap: 14px; }

.prestasi-item {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 18px 22px;
}

.prestasi-item .medal {
    width: 46px; height: 46px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--gold-accent), #b8912c);
    display: flex; align-items: center; justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

.prestasi-item .info h4 { font-size: 14.5px; margin-bottom: 4px; }
.prestasi-item .info span { font-size: 12px; color: var(--text-muted); }

/* ---------------- PPDB ---------------- */
.ppdb-wrap {
    display: grid;
    grid-template-columns: 0.85fr 1.15fr;
    gap: 40px;
}

.ppdb-info-list { display: flex; flex-direction: column; gap: 16px; margin-top: 20px; }

.ppdb-info-item { display: flex; gap: 14px; align-items: flex-start; }

.ppdb-info-item .num-badge {
    width: 32px; height: 32px;
    border-radius: 10px;
    background: rgba(72,202,228,0.18);
    border: 1px solid rgba(72,202,228,0.35);
    color: var(--sky-blue);
    display: flex; align-items: center; justify-content: center;
    font-weight: 800;
    font-size: 13px;
    flex-shrink: 0;
}

.ppdb-info-item p { font-size: 13.5px; color: var(--text-muted); }

.ppdb-form { padding: 32px; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.form-group { margin-bottom: 16px; }

.form-group label {
    display: block;
    font-size: 12.8px;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.form-group input[type="text"],
.form-group input[type="tel"],
.form-group input[type="date"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 14px;
    border-radius: 11px;
    border: 1px solid var(--glass-border);
    background: rgba(255,255,255,0.08);
    color: var(--text-light);
    font-size: 13.5px;
    outline: none;
    transition: all 0.2s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--sky-blue);
    box-shadow: 0 0 0 3px rgba(72,202,228,0.2);
}

.form-group input[type="file"] {
    width: 100%;
    padding: 10px;
    border-radius: 11px;
    border: 1px dashed var(--glass-border);
    background: rgba(255,255,255,0.05);
    color: var(--text-muted);
    font-size: 12.5px;
}

.form-group select option { color: #061A40; }

.alert { padding: 13px 16px; border-radius: 12px; font-size: 13px; margin-bottom: 18px; border: 1px solid transparent; }
.alert-error { background: rgba(220,53,69,0.15); border-color: rgba(220,53,69,0.35); color: #ffd7dc; }
.alert-success { background: rgba(25,135,84,0.15); border-color: rgba(25,135,84,0.35); color: #c8f5dd; }

/* ---------------- Kontak ---------------- */
.kontak-wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; }

.kontak-item { display: flex; gap: 16px; align-items: flex-start; padding: 20px; }

.kontak-item .icon {
    width: 44px; height: 44px;
    border-radius: 13px;
    background: linear-gradient(135deg, var(--sky-blue), var(--crystal-blue));
    display: flex; align-items: center; justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

.kontak-item h4 { font-size: 14px; margin-bottom: 4px; }
.kontak-item p { font-size: 13px; color: var(--text-muted); }

.map-frame { border-radius: 20px; overflow: hidden; border: 1px solid var(--glass-border); min-height: 280px; }
.map-frame iframe { width: 100%; height: 100%; min-height: 280px; border: 0; }

/* ---------------- Footer ---------------- */
footer {
    background: rgba(4, 16, 40, 0.85);
    border-top: 1px solid var(--glass-border);
    padding: 50px 0 24px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.3fr 1fr 1fr 1fr;
    gap: 34px;
    margin-bottom: 36px;
}

.footer-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; font-weight: 800; }
.footer-brand .logo-circle {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--sky-blue), var(--crystal-blue));
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 15px;
    flex-shrink: 0;
    overflow: hidden;
}
.footer-col h4 { font-size: 13.5px; margin-bottom: 16px; color: var(--gold-accent); }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 10px; }
.footer-col a { font-size: 13px; color: var(--text-muted); transition: color 0.2s ease; }
.footer-col a:hover { color: #fff; }
.footer-desc { font-size: 13px; color: var(--text-muted); max-width: 280px; }

.social-icons { display: flex; gap: 10px; margin-top: 16px; }
.social-icons a {
    width: 36px; height: 36px;
    border-radius: 10px;
    background: rgba(255,255,255,0.08);
    border: 1px solid var(--glass-border);
    display: flex; align-items: center; justify-content: center;
    font-size: 14px;
}

.footer-bottom {
    text-align: center;
    font-size: 12.5px;
    color: var(--text-muted);
    padding-top: 22px;
    border-top: 1px solid var(--glass-border);
}

/* ---------------- Back to top ---------------- */
.back-to-top {
    position: fixed;
    bottom: 26px; right: 26px;
    width: 46px; height: 46px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--sky-blue), var(--crystal-blue));
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 12px 26px rgba(11,94,215,0.5);
    z-index: 90;
    cursor: pointer;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
    color: #fff;
    font-size: 18px;
}
.back-to-top.show { opacity: 1; pointer-events: auto; }
.back-to-top:hover { transform: translateY(-3px); }

/* ---------------- Empty state ---------------- */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
    font-size: 13.5px;
    grid-column: 1 / -1;
}

/* ---------------- Responsive ---------------- */
@media (max-width: 980px) {
    .hero-grid { grid-template-columns: 1fr; }
    .hero-visual { max-width: 420px; margin: 0 auto; }
    .tahfidz-wrap { grid-template-columns: 1fr; }
    .ppdb-wrap { grid-template-columns: 1fr; }
    .kontak-wrap { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 760px) {
    :root { --section-pad: 60px; }
    .nav-links, .nav-actions .btn-outline { display: none; }
    .nav-toggle { display: block; }
    .hero-content h1 { font-size: 32px; }
    .hero-stats { grid-template-columns: repeat(3, 1fr); }
    .form-row { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .section-title { font-size: 26px; }
}

@media (max-width: 480px) {
    .container { padding: 0 16px; }
    .navbar .container { height: 64px; }
    .navbar .brand span { max-width: 130px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .nav-actions .btn-primary { padding: 9px 14px; font-size: 12.5px; }
    .hero { padding-top: 84px; }
    .hero-content h1 { font-size: 26px; }
    .hero-content p { font-size: 14px; }
    .hero-stats { gap: 10px; }
    .hero-stats .stat-box { padding: 12px 8px; }
    .hero-stats .stat-box .num { font-size: 19px; }
    .hero-actions { flex-direction: column; align-items: stretch; }
    .hero-actions .btn { width: 100%; }
    .section-title { font-size: 22px; }
    .section-desc { font-size: 13.5px; }
    .program-grid, .card-grid { grid-template-columns: 1fr; }
    .profil-tabs { gap: 6px; }
    .profil-tab-btn { padding: 8px 12px; font-size: 12px; }
    .ppdb-form { padding: 20px; }
    .kontak-item { padding: 14px; }
    .footer-grid { gap: 24px; }
    .mobile-nav { top: 64px; }
}

/* Mobile nav drawer */
.mobile-nav {
    position: fixed;
    top: 74px; left: 0; right: 0;
    background: rgba(6,26,64,0.97);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    padding: 18px 24px 26px;
    display: none;
    flex-direction: column;
    gap: 4px;
    z-index: 99;
}
.mobile-nav.show { display: flex; }
.mobile-nav a { padding: 12px 8px; font-size: 14px; font-weight: 600; color: var(--text-muted); border-bottom: 1px solid rgba(255,255,255,0.06); }
.mobile-nav .btn { margin-top: 10px; }
