/* ============================================================
   EDUKASI HS - CLEANED & OPTIMIZED CSS 2026
   Semua duplikat, !important berlebihan, dan sintaks rusak 
   telah diperbaiki. Layout tidak lagi bertumpuk.
   ============================================================ */

/* === RESET & GLOBAL === */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
    font-family: 'Inter', sans-serif;
    background: #f5f0eb;
    min-height: 100vh;
    padding: 12px 12px calc(100px + env(safe-area-inset-bottom));
    display: flex;
    justify-content: center;
    align-items: flex-start;
    color: #1a2a4a;
}

/* === APP CONTAINER === */
.app-container {
    width: 100%;
    max-width: 760px;
    margin: 0 auto;
    background: rgba(255,255,255,0.92);
    backdrop-filter: blur(12px);
    border-radius: 28px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.1);
    padding: 20px 16px 24px;
    border: 1px solid rgba(201,168,76,0.2);
    min-height: 90vh;
    position: relative;
    overflow: visible;
}

/* === HEADER === */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid rgba(201,168,76,0.2);
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-icon {
    width: 44px; height: 44px;
    background: linear-gradient(145deg,#c9a84c,#b8923a);
    border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 20px;
    box-shadow: 0 4px 12px rgba(201,168,76,0.3);
}
.brand h1 { font-family: 'Playfair Display',serif; font-weight: 900; font-size: 20px; color: #1a2a4a; }
.brand h1 span { color: #c9a84c; }
.brand .tagline { font-size: 9px; font-weight: 500; color: #7a7a7a; letter-spacing: 1px; text-transform: uppercase; }

.admin-link {
    font-size: 11px; color: #8a7a6a; text-decoration: none;
    padding: 6px 14px; border-radius: 30px;
    border: 1px solid #ede8e2; transition: all 0.3s;
    background: transparent; cursor: pointer;
    font-family: 'Inter',sans-serif;
    display: inline-flex; align-items: center; gap: 6px;
}
.admin-link:hover { border-color: #c9a84c; color: #1a2a4a; background: rgba(201,168,76,0.05); }
.admin-link.login-btn { border-color: #1a2a4a; color: #1a2a4a; }
.admin-link.login-btn:hover { background: #1a2a4a; color: #fff; }

/* === HERO === */
.hero {
    background: linear-gradient(135deg,#1a2a4a,#2a3a5a);
    border-radius: 20px; padding: 24px 20px; color: #fff;
    margin-bottom: 20px; position: relative; overflow: hidden;
}
.hero::before {
    content: 'EDUKASI HS'; position: absolute; right: -20px; bottom: -30px;
    font-size: 70px; opacity: 0.05; font-weight: 900; font-family: 'Playfair Display',serif;
}
.hero .badge {
    display: inline-block; background: #c9a84c; color: #fff;
    font-size: 10px; font-weight: 700; padding: 3px 14px;
    border-radius: 30px; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 8px;
}
.hero h2 { font-family: 'Playfair Display',serif; font-size: 22px; font-weight: 700; line-height: 1.3; }
.hero p { font-size: 13px; opacity: 0.8; margin-top: 6px; line-height: 1.6; }
.hero .btn-hero {
    margin-top: 14px; padding: 12px 28px; background: #c9a84c;
    border: none; border-radius: 60px; color: #fff; font-weight: 600;
    font-size: 14px; cursor: pointer; transition: all 0.3s;
    display: inline-flex; align-items: center; gap: 8px; font-family: 'Inter',sans-serif;
}
.hero .btn-hero:hover { background: #b8923a; transform: scale(1.02); }

/* === TABS === */
.tabs {
    display: flex; gap: 0; margin-bottom: 18px;
    border-radius: 14px; overflow: hidden;
    border: 2px solid #ede8e2; background: #fff;
}
.tab-btn {
    flex: 1; padding: 10px 12px; border: none;
    background: #fcfaf8; font-size: 13px; font-weight: 600;
    color: #6a5a4a; cursor: pointer; transition: all 0.3s ease;
    font-family: 'Inter',sans-serif;
    display: flex; align-items: center; justify-content: center; gap: 6px;
}
.tab-btn:hover { background: #f5f0eb; }
.tab-btn.active { background: linear-gradient(145deg,#c9a84c,#b8923a); color: #fff; }
.tab-btn i { font-size: 14px; }
.tab-content { display: none; animation: fadeSlide 0.4s ease; }
.tab-content.active { display: block; }

@keyframes fadeSlide {
    0% { opacity: 0; transform: translateY(10px); }
    100% { opacity: 1; transform: translateY(0); }
}

/* === FORMS === */
.form-group { display: flex; flex-direction: column; gap: 4px; margin-bottom: 14px; }
.form-group label { font-weight: 600; font-size: 12px; color: #2a2a2a; display: flex; align-items: center; gap: 6px; }
.form-group label i { color: #c9a84c; width: 16px; font-size: 13px; }
.form-group input, .form-group select {
    padding: 10px 14px; border: 2px solid #e8e0d8; border-radius: 12px;
    font-size: 14px; font-family: 'Inter',sans-serif; background: #fcfaf8;
    transition: all 0.25s ease; outline: none; color: #1a1a1a; width: 100%;
    min-height: 44px;
}
.form-group input:focus, .form-group select:focus {
    border-color: #c9a84c; box-shadow: 0 0 0 3px rgba(201,168,76,0.15);
}
.password-wrapper { position: relative; }
.password-wrapper input { padding-right: 44px; }
.password-wrapper .toggle-password {
    position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
    background: none; border: none; color: #8a7a6a; cursor: pointer; font-size: 16px; padding: 4px;
}

/* === BUTTONS === */
.btn {
    padding: 12px 20px; border: none; border-radius: 60px;
    font-weight: 600; font-size: 14px; font-family: 'Inter',sans-serif;
    cursor: pointer; transition: all 0.3s ease;
    display: inline-flex; align-items: center; justify-content: center; gap: 8px; width: 100%;
    min-height: 44px;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(0,0,0,0.08); }
.btn-primary, .btn-gold {
    background: linear-gradient(145deg,#c9a84c,#b8923a); color: #fff;
    box-shadow: 0 4px 14px rgba(201,168,76,0.3);
}
.mt-8 { margin-top: 8px; }
.mb-8 { margin-bottom: 8px; }

/* === PAGE VISIBILITY (Single Frame System) === */
.page-content { display: none; width: 100%; position: relative; animation: fadeSlide 0.4s ease; }
.page-content.active { display: block; }

/* === BOTTOM NAVIGATION === */
.bottom-nav {
    position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
    width: 100%; max-width: 760px;
    display: grid; grid-template-columns: repeat(5, minmax(0,1fr));
    gap: 0; background: #fff;
    border-top: 1px solid #e8e3db;
    box-shadow: 0 -5px 20px rgba(0,0,0,0.08);
    z-index: 9999;
    padding: 8px 4px calc(8px + env(safe-area-inset-bottom));
    min-height: 82px;
}
.bottom-nav .nav-item {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 3px; padding: 5px 0; background: transparent; border: 0;
    color: #8a7a6a; cursor: pointer; transition: all 0.3s;
    font-family: 'Inter',sans-serif; position: relative;
    min-height: 62px;
}
.bottom-nav .nav-item i { font-size: 24px; transition: all 0.3s; }
.bottom-nav .nav-item span { font-size: 10px; line-height: 1.1; font-weight: 700; }
.bottom-nav .nav-item.active { color: #c9a84c; background: #f5efd9; border-radius: 13px; }
.bottom-nav .nav-item.active i { transform: scale(1.1); }
.bottom-nav .nav-item .badge-nav {
    position: absolute; top: 0; right: 0;
    background: #c0392b; color: #fff; font-size: 8px;
    padding: 1px 6px; border-radius: 30px; font-weight: 700;
}

/* === PORTAL === */
.portal-hero {
    background: linear-gradient(135deg,#1a2a4a,#304b7d); color: #fff;
    border-radius: 20px; padding: 20px 18px; margin-bottom: 14px;
    display: flex; gap: 14px; align-items: center;
    box-shadow: 0 12px 28px rgba(26,42,74,0.18);
}
.portal-hero > i { font-size: 28px; color: #e5c976; }
.portal-hero small { color: #e5c976; font-size: 10px; font-weight: 800; letter-spacing: 1px; }
.portal-hero h2 { font-family: 'Playfair Display',serif; font-size: 25px; margin: 3px 0; }
.portal-hero p { font-size: 14px; line-height: 1.5; color: rgba(255,255,255,0.85); }
.portal-hint {
    font-size: 13px; text-align: center; padding: 11px;
    background: #fff; border: 1px solid #e9e4dc; border-radius: 12px;
    margin-bottom: 14px; color: #667085;
}
.portal-hint i { color: #c9a84c; }
.portal-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.flip-card { height: 210px; perspective: 1000px; cursor: pointer; }
.flip-inner { position: relative; width: 100%; height: 100%; transition: transform 0.65s; transform-style: preserve-3d; }
.flip-card.flipped .flip-inner { transform: rotateY(180deg); }
.flip-front, .flip-back {
    position: absolute; inset: 0; backface-visibility: hidden;
    border-radius: 18px; padding: 15px;
    box-shadow: 0 9px 24px rgba(26,42,74,0.11);
    border: 1px solid #e9e4dc;
    display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
}
.flip-front { background: linear-gradient(145deg,#fff,#faf8f4); }
.portal-icon {
    width: 55px; height: 55px; border-radius: 16px;
    background: linear-gradient(135deg,#1a2a4a,#304b7d); color: #e5c976;
    display: flex; align-items: center; justify-content: center;
    font-size: 24px; margin-bottom: 11px;
}
.flip-front h3, .flip-back h3 { font-size: 16px; margin-bottom: 6px; }
.flip-front h3 { color: #1a2a4a; }
.flip-front p { font-size: 12px; color: #8b8175; }
.flip-front span { font-size: 10px; color: #b18f35; margin-top: 12px; font-weight: 700; }
.flip-back { transform: rotateY(180deg); background: linear-gradient(145deg,#1a2a4a,#263f70); color: #fff; }
.flip-back > i { font-size: 26px; color: #e5c976; margin-bottom: 10px; }
.flip-back p { font-size: 12.5px; line-height: 1.55; color: rgba(255,255,255,0.86); }
.portal-summary {
    margin-top: 16px; padding: 18px;
    background: linear-gradient(135deg,#f5efd9,#fffaf0);
    border: 1px solid #e8d9a9; border-radius: 17px;
    display: flex; gap: 13px;
}
.portal-summary > i { font-size: 25px; color: #b18f35; }
.portal-summary strong { font-size: 15px; color: #1a2a4a; }
.portal-summary p { font-size: 13px; line-height: 1.55; color: #6f655b; margin-top: 5px; }
.portal-open-link {
    display: inline-flex; align-items: center; justify-content: center; gap: 5px;
    margin-top: 12px; padding: 8px 11px; border-radius: 9px;
    background: #e5c976; color: #1a2a4a; text-decoration: none;
    font-size: 10px; font-weight: 800;
}
.portal-open-link:hover { background: #f2d982; }

/* === PROMO & TESTIMONI === */
.promo-section { margin: 16px 0; }
.promo-section .section-title {
    font-size: 16px; font-weight: 700; color: #1a2a4a; margin-bottom: 10px;
    display: flex; align-items: center; gap: 8px;
}
.promo-section .section-title i { color: #c9a84c; }
.promo-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.promo-card {
    background: #fff; border-radius: 14px; padding: 14px 12px;
    border: 1px solid #ede8e2; text-align: center; transition: all 0.3s;
}
.promo-card:hover { border-color: #c9a84c; transform: translateY(-2px); }
.promo-card .icon { font-size: 28px; margin-bottom: 6px; color: #c9a84c; }
.promo-card .title { font-size: 12px; font-weight: 600; color: #1a2a4a; }
.promo-card .desc { font-size: 10px; color: #8a7a6a; margin-top: 2px; }
.testimoni-box {
    background: #fcfaf8; border-radius: 14px; padding: 14px 16px;
    border: 1px solid #ede8e2; margin-bottom: 10px;
}
.testimoni-box .nama { font-weight: 600; font-size: 13px; color: #1a2a4a; }
.testimoni-box .peran { font-size: 11px; color: #8a7a6a; }
.testimoni-box .isi { font-size: 13px; color: #4a3a2a; margin-top: 4px; font-style: italic; }
.testimoni-box .stars { color: #c9a84c; font-size: 12px; margin-top: 4px; }

/* === CEK STATUS === */
.cek-status-box {
    background: #fcfaf8; border-radius: 16px; padding: 16px;
    margin-top: 16px; border: 1px solid #ede8e2;
}
.cek-status-box h4 { font-size: 14px; color: #1a2a4a; }
.cek-status-box .flex-row { display: flex; gap: 8px; margin-top: 8px; }
.cek-status-box .flex-row input {
    flex: 1; padding: 10px 14px; border: 2px solid #e8e0d8;
    border-radius: 12px; font-size: 14px; outline: none; font-family: 'Inter',sans-serif;
}
.cek-status-box .flex-row input:focus { border-color: #c9a84c; }
.cek-status-box .btn { width: auto; padding: 10px 18px; }
.status-result {
    margin-top: 12px; padding: 12px 14px; background: #fff;
    border-radius: 12px; border: 1px solid #ede8e2; display: none;
}
.status-result.show { display: block; }
.status-label { display: inline-block; padding: 2px 12px; border-radius: 30px; font-size: 11px; font-weight: 700; }
.status-label.pending { background: #fef3d0; color: #a87d2a; }
.status-label.verified { background: #d4edda; color: #1a7a3a; }
.status-label.completed { background: #c9a84c; color: #fff; }

/* === CONTACT === */
.contact-info {
    background: #1a2a4a; border-radius: 14px; padding: 14px 16px;
    color: #fff; margin: 12px 0;
}
.contact-info .row { display: flex; align-items: center; gap: 10px; font-size: 13px; padding: 4px 0; }
.contact-info .row i { color: #c9a84c; width: 20px; }

/* === NOTIFICATION & MODAL === */
.notification { padding: 14px 16px; border-radius: 14px; margin: 14px 0; }
.notification.success { background: #fef9f0; border-left: 4px solid #c9a84c; }
.notification h3 { font-size: 16px; color: #1a2a4a; font-family: 'Playfair Display',serif; }
.notification p { font-size: 13px; color: #4a3a2a; }
.modal-overlay {
    display: none; position: fixed; inset: 0;
    background: rgba(0,0,0,0.4); backdrop-filter: blur(4px);
    z-index: 200; align-items: center; justify-content: center; padding: 16px;
}
.modal-overlay.open { display: flex; }
.modal-box { background: #fff; border-radius: 24px; max-width: 400px; width: 100%; padding: 24px; }
.modal-box .modal-close { float: right; background: none; border: none; font-size: 20px; color: #6a5a4a; cursor: pointer; }
.modal-box .modal-title { font-family: 'Playfair Display',serif; font-size: 18px; color: #1a2a4a; margin-bottom: 12px; }

/* === QUOTE FOOTER === */
.quote-footer {
    margin-top: 24px; padding: 20px 18px; border: 0; border-radius: 18px;
    background: linear-gradient(135deg,#1a2a4a,#263d68); color: #fff;
    position: relative; overflow: hidden; text-align: center;
    box-shadow: 0 10px 28px rgba(26,42,74,0.16);
}
.quote-footer::before {
    content: ""; position: absolute; width: 100px; height: 100px;
    right: -35px; top: -45px; border-radius: 50%; background: rgba(201,168,76,0.18);
}
.quote-icon {
    width: 36px; height: 36px; margin: 0 auto 10px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: #c9a84c; color: #fff; font-size: 15px;
}
.education-quote {
    position: relative; z-index: 1; font-family: 'Playfair Display',serif;
    font-size: 15px; font-weight: 700; line-height: 1.55;
}
.quote-author {
    position: relative; z-index: 1; margin-top: 8px; color: #e5c976;
    font-size: 11px; font-weight: 600; letter-spacing: 0.5px;
}
.quote-refresh {
    position: relative; z-index: 1; margin-top: 12px; padding-top: 10px;
    border-top: 1px solid rgba(255,255,255,0.12);
    font-size: 9px; color: rgba(255,255,255,0.6);
}

/* === GLOBAL FOOTER === */
.edukasi-global-footer { width: 100%; margin: 24px 0 18px; text-align: center; }
.education-inspiration {
    display: flex; align-items: center; gap: 13px; text-align: left;
    padding: 17px 18px; border-radius: 18px;
    background: linear-gradient(135deg,#1a2a4a,#2d4b7e); color: #fff;
    box-shadow: 0 10px 26px rgba(26,42,74,0.14);
}
.inspiration-mark {
    flex: 0 0 42px; width: 42px; height: 42px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: #c9a84c; color: #fff; font-size: 17px;
}
.inspiration-label { display: block; color: #e5c976; font-size: 9px; font-weight: 800; letter-spacing: 1px; margin-bottom: 4px; }
.education-inspiration p { margin: 0 0 5px; font-family: 'Playfair Display',serif; font-size: 13px; line-height: 1.5; font-weight: 700; }
.education-inspiration small { color: #e5c976; font-size: 9px; font-weight: 700; }
.footer-copyright { margin-top: 13px; color: #5f574f; font-size: 10px; font-weight: 700; line-height: 1.45; }
.footer-pmkka { margin-top: 4px; color: #948a80; font-size: 8.5px; line-height: 1.4; }
.footer { margin-top: 20px; text-align: center; font-size: 10px; color: #a09080; border-top: 1px solid #ede8e2; padding-top: 12px; }

/* ============================================================
   KABAR / NEWS — FINAL CLEAN LAYOUT 2026
   ============================================================ */
.kabar-slide { min-height: calc(100vh - 155px); }
body.kabar-mode .app-container > .header,
body.kabar-mode .app-container > .edukasi-global-footer { display: none; }
body.kabar-mode .app-container { padding-top: 0; }
body.kabar-mode #pageKabar { margin: 0; padding: 0; }
body.kabar-mode { background: #f2eee8; }

#pageKabar {
    --en-navy: #10264a; --en-gold: #f1bd3f; --en-blue: #2474b5;
    --en-purple: #7656d6; --en-orange: #e98b36; --en-green: #27966f;
    --en-ink: #17233b; --en-muted: #7d8795; --en-paper: #f7f4ef;
    font-family: Inter,Arial,sans-serif; background: var(--en-paper);
}

/* News Hero */
#pageKabar .news-hero {
    position: relative; width: 100%; min-height: 178px;
    margin: 0 0 14px; padding: 27px 28px 22px;
    border-radius: 0 0 24px 24px; text-align: center;
    overflow: hidden; color: #fff;
    background: radial-gradient(circle at 93% 8%,rgba(64,176,190,0.25),transparent 27%),
                linear-gradient(118deg,#102d57 0%,#17466f 63%,#247a8d 100%);
}
#pageKabar .news-hero::after {
    content: "NEWS"; position: absolute; right: -10px; bottom: -31px;
    font: 900 91px/1 'Playfair Display',Georgia,serif;
    letter-spacing: -5px; color: rgba(255,255,255,0.045);
}
#pageKabar .news-hero-kicker {
    position: relative; z-index: 2; color: #ffd24f;
    font-size: 8px; line-height: 1; font-weight: 900; letter-spacing: 1.7px;
}
#pageKabar .news-hero h1, #pageKabar .news-hero h2 {
    position: relative; z-index: 2; margin: 11px 0 6px;
    font: 900 43px/0.92 'Playfair Display',Georgia,serif;
    letter-spacing: -2px; color: #fff;
}
#pageKabar .news-hero h1 span, #pageKabar .news-hero h2 span { color: #ffd24f; }
#pageKabar .news-hero p {
    position: relative; z-index: 2; max-width: 610px; margin: 0 auto;
    font-size: 9.5px; line-height: 1.55; color: rgba(255,255,255,0.79);
}
#pageKabar .news-hero-bottom {
    position: relative; z-index: 2; display: flex; align-items: center;
    justify-content: space-between; gap: 12px; margin-top: 16px;
    padding-top: 10px; border-top: 1px solid rgba(255,255,255,0.10);
    font-size: 7px; color: rgba(255,255,255,0.68);
}
#pageKabar #newsTotalBadge {
    padding: 4px 8px; border-radius: 999px;
    background: rgba(255,255,255,0.12); color: #fff; font-size: 7px; font-weight: 900;
}

/* News Tabs */
#pageKabar .news-tabs {
    width: 100%; margin: 0 0 25px; padding: 7px;
    display: grid; grid-template-columns: repeat(5,minmax(0,1fr));
    gap: 6px; background: #fbfaf8; border: 1px solid #ded8d0;
    border-radius: 14px; box-shadow: 0 7px 20px rgba(16,38,74,0.045);
}
#pageKabar .news-tab {
    width: 100%; min-height: 42px; padding: 8px 5px; border: 0;
    border-radius: 10px; background: #ece8e2; color: #625b53;
    font-size: 8px; font-weight: 800; white-space: nowrap; cursor: pointer;
}
#pageKabar .news-tab.active {
    background: #102d57; color: #fff; box-shadow: 0 7px 17px rgba(16,45,87,0.15);
}

/* News Feed */
#pageKabar .mf-news-feed { width: 100%; margin: 0; }
#pageKabar .mf-news-feed-head {
    display: flex; align-items: end; justify-content: space-between;
    gap: 14px; padding: 0 1px 9px; border-bottom: 2px solid #102d57;
}
#pageKabar .mf-news-feed-head span {
    display: block; margin-bottom: 4px; color: #b88c24;
    font-size: 6.5px; font-weight: 900; letter-spacing: 1.4px;
}
#pageKabar .mf-news-feed-head h3 {
    margin: 0; font: 900 21px/1 'Playfair Display',Georgia,serif; color: #15243e;
}
#pageKabar .mf-news-feed-head small { color: #9aa0a9; font-size: 7px; }

/* News Row */
#pageKabar .mf-news-row {
    display: grid; grid-template-columns: 118px minmax(0,1fr);
    gap: 13px; align-items: center; padding: 13px 2px;
    border-bottom: 1px solid #e4dfd8; cursor: pointer;
    background: transparent; transition: background 0.18s ease;
}
#pageKabar .mf-news-row:active { background: #f2eee9; }
#pageKabar .mf-news-photo {
    width: 118px; height: 82px; border-radius: 11px;
    overflow: hidden; background: #e8edf2; position: relative;
}
#pageKabar .mf-news-photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
#pageKabar .mf-news-placeholder {
    position: absolute; inset: 0; display: grid; place-items: center;
    color: #2474b5; font-size: 20px; background: linear-gradient(135deg,#edf3f8,#e1e9f0);
}
#pageKabar .mf-news-copy { min-width: 0; }
#pageKabar .mf-news-top { display: flex; align-items: center; gap: 5px; margin: 0 0 4px; }
#pageKabar .mf-news-category, #pageKabar .mf-news-headline-label {
    display: inline-flex; align-items: center; border-radius: 999px;
    padding: 3px 6px; font-size: 6.5px; line-height: 1;
    font-weight: 900; letter-spacing: 0.07em; text-transform: uppercase;
}
#pageKabar .mf-berita { background: #dfeeff; color: #1769aa; }
#pageKabar .mf-pengumuman { background: #fff0c9; color: #a2620b; }
#pageKabar .mf-artikel { background: #eee8ff; color: #6845bd; }
#pageKabar .mf-info { background: #ddf5eb; color: #197858; }
#pageKabar .mf-news-headline-label { background: #10264a; color: #fff; }
#pageKabar .mf-news-copy h3 {
    font-family: 'Playfair Display',Georgia,serif; font-size: 15px;
    line-height: 1.23; font-weight: 800; color: #17233b; margin: 0 0 4px;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
#pageKabar .mf-news-copy p {
    margin: 0 0 6px; color: #7d8795; font-size: 8.5px; line-height: 1.4;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
#pageKabar .mf-news-meta {
    display: flex; align-items: center; gap: 7px; min-width: 0;
    color: #969da6; font-size: 7px;
}
#pageKabar .mf-news-meta b { margin-left: auto; color: #10264a; font-size: 7px; white-space: nowrap; }

/* News Lead (Headline) */
#pageKabar .mf-news-row.mf-news-lead {
    grid-template-columns: 1fr; gap: 0; margin: 12px 0 3px;
    padding: 0 0 17px; border-bottom: 2px solid #10264a;
}
#pageKabar .mf-news-lead .mf-news-photo {
    width: 100%; height: 300px; margin: 0 0 12px;
    border-radius: 18px; box-shadow: 0 10px 25px rgba(15,35,65,0.10);
}
#pageKabar .mf-news-lead .mf-news-copy h3 {
    max-width: 650px; margin: 5px 0 7px;
    font: 900 28px/1.08 'Playfair Display',Georgia,serif;
    letter-spacing: -0.5px; -webkit-line-clamp: 3;
}
#pageKabar .mf-news-lead .mf-news-copy p {
    max-width: 620px; margin: 0 0 8px; font-size: 10px; line-height: 1.55; -webkit-line-clamp: 2;
}

/* Loading & Empty States */
#pageKabar .news-loading-new, #pageKabar .news-empty-new {
    min-height: 210px; display: flex; flex-direction: column;
    align-items: center; justify-content: center; gap: 9px;
    color: #9aa2ad; text-align: center;
}

/* News Magazine Section */
#pageKabar .news-magazine {
    position: relative; overflow: hidden; margin-top: 22px; padding: 24px 20px;
    border-radius: 24px;
    background: linear-gradient(135deg,#552e96,#344fb0 55%,#1686a0);
    color: #fff; box-shadow: 0 14px 28px rgba(69,57,151,0.16);
}
#pageKabar .news-magazine small { font-size: 8px; font-weight: 900; letter-spacing: 1.4px; color: #ffd35d; }
#pageKabar .news-magazine h2 { font: 900 29px/0.95 'Playfair Display',serif; margin: 7px 0; }
#pageKabar .news-magazine p { font-size: 9.5px; line-height: 1.55; color: rgba(255,255,255,0.78); max-width: 520px; }
#pageKabar .news-magazine button {
    margin-top: 12px; border: 0; border-radius: 999px; padding: 9px 13px;
    background: #ffd35d; color: #17233b; font-size: 8px; font-weight: 900; cursor: pointer;
}
#pageKabar .news-magazine-art {
    position: absolute; right: -18px; bottom: -55px;
    font: 900 180px/1 'Playfair Display',serif; color: rgba(255,255,255,0.055);
}

/* News Portal Box */
#pageKabar .news-portal-box {
    margin-top: 20px; padding: 18px; border: 1px solid #eadfce;
    border-radius: 22px; background: #fffdfa;
}
#pageKabar .news-portal-head {
    display: flex; justify-content: space-between; align-items: center;
    gap: 13px; margin-bottom: 13px;
}
#pageKabar .news-portal-head small { font-size: 7.5px; font-weight: 900; letter-spacing: 1.2px; color: #b68a27; }
#pageKabar .news-portal-head h2 { font: 900 21px/1 'Playfair Display',serif; color: #10264a; margin: 4px 0; }
#pageKabar .news-portal-head h2 i { color: #d0a43a; }
#pageKabar .news-portal-head p { font-size: 9px; color: #7d756c; }
#pageKabar .news-portal-head button {
    border: 0; border-radius: 12px; padding: 10px 12px;
    background: #10264a; color: #fff; font-size: 8px; font-weight: 900; cursor: pointer;
}
#pageKabar .news-portal-grid { display: grid; grid-template-columns: repeat(5,1fr); gap: 7px; }
#pageKabar .news-portal-grid div {
    min-height: 65px; border: 1px solid #ece3d8; border-radius: 12px;
    background: #fff; display: flex; flex-direction: column;
    align-items: center; justify-content: center; gap: 5px; text-align: center;
}
#pageKabar .news-portal-grid i { font-size: 16px; color: #d0a43a; }
#pageKabar .news-portal-grid b { font-size: 7px; color: #10264a; }

/* Image Performance */
#pageKabar img { max-width: 100%; height: auto; }
#pageKabar .mf-news-photo { contain: layout paint; }

/* === RESPONSIVE === */
@media (max-width: 520px) {
    body { padding: 12px 12px calc(96px + env(safe-area-inset-bottom)); }
    .app-container { padding: 14px 12px; border-radius: 24px; }
    .hero h2 { font-size: 18px; }
    .promo-grid { grid-template-columns: 1fr 1fr; }
    .bottom-nav .nav-item span { font-size: 9px; }
    .bottom-nav .nav-item i { font-size: 21px; }
    
    body.kabar-mode .app-container { padding: 0 12px 22px; border-radius: 24px; }
    body.kabar-mode #pageKabar { padding: 0 12px 25px; }
    #pageKabar .news-hero { min-height: 164px; padding: 24px 15px 18px; border-radius: 0 0 20px 20px; }
    #pageKabar .news-hero h1, #pageKabar .news-hero h2 { font-size: 36px; }
    #pageKabar .news-hero p { font-size: 8.5px; }
    #pageKabar .news-tabs { gap: 4px; padding: 5px; margin-bottom: 20px; }
    #pageKabar .news-tab { min-height: 38px; padding: 6px 2px; font-size: 6.6px; }
    #pageKabar .news-tab i { display: none; }
    #pageKabar .mf-news-lead .mf-news-photo { height: 205px; border-radius: 15px; }
    #pageKabar .mf-news-lead .mf-news-copy h3 { font-size: 23px; }
    #pageKabar .mf-news-row:not(.mf-news-lead) { grid-template-columns: 88px minmax(0,1fr); gap: 10px; padding: 11px 1px; }
    #pageKabar .mf-news-row:not(.mf-news-lead) .mf-news-photo { width: 88px; height: 66px; }
    #pageKabar .mf-news-row:not(.mf-news-lead) .mf-news-copy h3 { font-size: 14px; }
    #pageKabar .mf-news-row:not(.mf-news-lead) .mf-news-copy p { display: none; }
    #pageKabar .news-portal-grid { grid-template-columns: repeat(2,1fr); }
    #pageKabar .news-portal-head { align-items: flex-start; flex-direction: column; }
}

@media (min-width: 600px) {
    body { padding: 24px 24px 90px; }
    .app-container { max-width: 760px; padding: 28px; }
    .promo-grid { grid-template-columns: repeat(3,1fr); }
    .portal-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
    #pageKabar .news-hero { padding: 28px 25px 22px; border-radius: 20px; }
    #pageKabar .news-hero h2 { font-size: 40px; }
    #pageKabar .news-tab { font-size: 9px; padding: 11px 8px; }
    #pageKabar .mf-news-lead .mf-news-photo { height: 390px; border-radius: 20px; }
    #pageKabar .mf-news-lead .mf-news-copy h3 { max-width: 800px; font-size: 36px; }
    #pageKabar .mf-news-lead .mf-news-copy p { max-width: 720px; font-size: 12px; }
    #pageKabar .mf-news-row:not(.mf-news-lead) { grid-template-columns: 145px minmax(0,1fr); gap: 16px; padding: 15px 2px; }
    #pageKabar .mf-news-row:not(.mf-news-lead) .mf-news-photo { width: 145px; height: 98px; }
    #pageKabar .mf-news-row:not(.mf-news-lead) .mf-news-copy h3 { font-size: 19px; }
}