/* ===================================================================
   MyCare — YTWR Digital Magazine — Stylesheet
   Mode: Pagination (satu artikel = satu halaman, ala buku/majalah cetak)
   =================================================================== */

:root {
    --primary: #6B46C1;
    --secondary: #5B3F99;
    --accent: #A78BFA;

    --bg: #EDE7DA;
    --bg-alt: #F2ECE1;
    --surface: #FFFFFF;
    --ink: #241F2E;
    --ink-soft: #5B5568;
    --hairline: rgba(36, 31, 46, 0.12);
    --shadow: 0 24px 55px -22px rgba(36, 31, 46, 0.4);
    --sidebar-bg: #211B2E;
    --sidebar-ink: #F1ECFA;
    --sidebar-ink-soft: #B9AFD1;
    --sidebar-active: var(--accent);

    --font-display: 'Poppins', 'Inter', -apple-system, sans-serif;
    --font-body: 'Source Serif 4', Georgia, serif;
    --font-ui: 'Inter', -apple-system, sans-serif;

    --sidebar-w: 296px;
}

[data-theme="dark"] {
    --bg: #0C0A11;
    --bg-alt: #1B1725;
    --surface: #1F1A2B;
    --ink: #EDE8F5;
    --ink-soft: #B3A9C9;
    --hairline: rgba(237, 232, 245, 0.12);
    --shadow: 0 24px 60px -18px rgba(0, 0, 0, 0.7);
    --sidebar-bg: #0F0C17;
    --sidebar-ink: #F1ECFA;
    --sidebar-ink-soft: #8C82A6;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: auto;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: var(--font-body);
    -webkit-font-smoothing: antialiased;
    transition: background .35s ease, color .35s ease;
    overscroll-behavior-x: none;
}

a {
    color: inherit;
}

button {
    font: inherit;
}

/* ===== READING PROGRESS BAR (posisi halaman dalam edisi) ===== */
#progressBar {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0%;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    z-index: 100;
    transition: width .3s ease;
}

/* ===== BACK TO TOP FAB ===== */
.fab-top {
    position: fixed;
    right: 26px;
    bottom: 92px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: var(--shadow);
    opacity: 0;
    transform: translateY(12px);
    pointer-events: none;
    transition: opacity .25s ease, transform .25s ease;
    z-index: 55;
}

.fab-top.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.fab-top svg {
    width: 18px;
    height: 18px;
}

/* ===== LAYOUT SHELL ===== */
#app {
    display: grid;
    grid-template-columns: var(--sidebar-w) 1fr;
    min-height: 100vh;
    transition: grid-template-columns .3s cubic-bezier(.4, 0, .2, 1);
}

#app.sidebar-collapsed {
    grid-template-columns: 0 1fr;
}

@media (max-width:1023px) {
    #app {
        grid-template-columns: 1fr;
    }
}

/* ===== SIDEBAR ===== */
.sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    background: var(--sidebar-bg);
    color: var(--sidebar-ink);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-width: 0;
    transition: opacity .22s ease;
}

#app.sidebar-collapsed .sidebar {
    opacity: 0;
    pointer-events: none;
}

.sidebar-header {
    flex-shrink: 0;
    padding: 32px 26px 18px;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
}

.brand {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.brand-mark {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 27px;
    letter-spacing: -0.01em;
    display: flex;
    align-items: baseline;
    gap: 2px;
}

.brand-mark .dot {
    color: var(--accent);
}

.brand-sub {
    font-family: var(--font-ui);
    font-size: 11px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--sidebar-ink-soft);
}

#collapseBtn {
    flex-shrink: 0;
    width: 30px;
    height: 30px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.05);
    color: var(--sidebar-ink-soft);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background .2s ease, color .2s ease;
}

#collapseBtn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--sidebar-ink);
}

#collapseBtn svg {
    width: 14px;
    height: 14px;
}

@media (max-width:1023px) {
    #collapseBtn {
        display: none;
    }
}

#reopenBtn {
    display: none;
    position: fixed;
    top: 22px;
    left: 22px;
    z-index: 60;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    align-items: center;
    justify-content: center;
    background: var(--sidebar-bg);
    color: var(--sidebar-ink);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: var(--shadow);
    cursor: pointer;
}

#app.sidebar-collapsed #reopenBtn {
    display: flex;
}

@media (max-width:1023px) {
    #reopenBtn {
        display: none !important;
    }
}

#reopenBtn svg {
    width: 16px;
    height: 16px;
}

.sidebar-scroll {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 4px 26px 16px;
    display: flex;
    flex-direction: column;
    -webkit-overflow-scrolling: touch;
}

.sidebar-scroll::-webkit-scrollbar {
    width: 6px;
}

.sidebar-scroll::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 4px;
}

.archive-label {
    font-family: var(--font-ui);
    font-size: 11px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--sidebar-ink-soft);
    margin: 14px 0 12px;
    flex-shrink: 0;
}

#archiveTree {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
}

.archive-empty {
    font-family: var(--font-ui);
    font-size: 13.5px;
    color: var(--sidebar-ink-soft);
    padding: 10px 8px;
}

.year-group {
    display: flex;
    flex-direction: column;
}

.year-header {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    background: none;
    border: none;
    text-align: left;
    color: var(--sidebar-ink);
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 16px;
    padding: 10px 8px;
    border-radius: 8px;
    cursor: pointer;
    transition: background .2s ease;
}

.year-header:hover {
    background: rgba(255, 255, 255, 0.06);
}

.year-header .chev {
    display: inline-flex;
    transition: transform .25s ease;
    color: var(--sidebar-ink-soft);
    flex-shrink: 0;
}

.year-header .chev svg {
    width: 11px;
    height: 11px;
}

.year-group.open .chev {
    transform: rotate(90deg);
}

.year-header .ycount {
    margin-left: auto;
    font-family: var(--font-ui);
    font-weight: 400;
    font-size: 11px;
    color: var(--sidebar-ink-soft);
}

.month-list {
    list-style: none;
    margin: 0;
    padding: 2px 0 8px 22px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    overflow: hidden;
    max-height: 900px;
    transition: max-height .3s ease, opacity .25s ease, padding .3s ease;
}

.year-group:not(.open) .month-list {
    max-height: 0;
    padding-top: 0;
    padding-bottom: 0;
    opacity: 0;
}

.archive-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    width: 100%;
    background: none;
    border: none;
    text-align: left;
    color: var(--sidebar-ink-soft);
    font-family: var(--font-ui);
    font-size: 14.5px;
    padding: 9px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: background .2s ease, color .2s ease;
}

.archive-item:hover {
    background: rgba(255, 255, 255, 0.06);
    color: var(--sidebar-ink);
}

.archive-item.active {
    background: linear-gradient(90deg, rgba(167, 139, 250, 0.18), rgba(167, 139, 250, 0.04));
    color: #fff;
    font-weight: 600;
    box-shadow: inset 3px 0 0 var(--accent);
}

.archive-item .count {
    font-size: 11px;
    color: var(--sidebar-ink-soft);
    font-variant-numeric: tabular-nums;
}

.archive-item.active .count {
    color: var(--accent);
}

.sidebar-foot {
    position: sticky;
    bottom: 0;
    margin-top: 20px;
    padding: 20px 26px 26px;
    background: linear-gradient(to top, var(--sidebar-bg) 74%, transparent);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    z-index: 2;
    flex-shrink: 0;
}

.sidebar-foot::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
}

.sidebar-note {
    font-family: var(--font-ui);
    font-size: 11.5px;
    line-height: 1.5;
    color: var(--sidebar-ink-soft);
    position: relative;
}

.theme-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    padding: 5px;
    cursor: pointer;
    flex-shrink: 0;
    position: relative;
}

.theme-toggle .seg {
    width: 30px;
    height: 30px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--sidebar-ink-soft);
    transition: background .2s ease, color .2s ease;
}

.theme-toggle .seg.active {
    background: var(--accent);
    color: #241F2E;
}

.theme-toggle svg {
    width: 15px;
    height: 15px;
}

@media (max-width:1023px) {
    #themeToggleDesktop {
        display: none;
    }
}

/* ===== MOBILE TOP BAR ===== */
.mobile-bar {
    display: none;
    position: sticky;
    top: 0;
    z-index: 40;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 18px;
    background: var(--sidebar-bg);
    color: var(--sidebar-ink);
    min-height: 66px;
}

.mobile-bar .m-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.mobile-bar .hamburger {
    width: 38px;
    height: 38px;
    border-radius: 9px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--sidebar-ink);
    cursor: pointer;
}

.mobile-bar .m-brand {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 18px;
}

.mobile-bar .m-brand .dot {
    color: var(--accent);
}

.mobile-bar .m-month {
    font-family: var(--font-ui);
    font-size: 11.5px;
    color: var(--sidebar-ink-soft);
}

.drawer-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(10, 8, 15, 0.55);
    z-index: 45;
}

@media (max-width:1023px) {
    .mobile-bar {
        display: flex;
    }

    .sidebar {
        position: fixed;
        left: 0;
        top: 0;
        bottom: 0;
        width: min(320px, 84vw);
        height: 100vh;
        transform: translateX(-105%);
        transition: transform .32s cubic-bezier(.4, 0, .2, 1);
        z-index: 50;
        box-shadow: 30px 0 60px rgba(0, 0, 0, 0.35);
        opacity: 1 !important;
        pointer-events: auto !important;
    }

    .sidebar.open {
        transform: translateX(0);
    }

    #app.drawer-open .drawer-overlay {
        display: block;
    }
}

/* ===== MAIN / PAGE VIEWPORT ===== */
main {
    min-width: 0;
    padding-bottom: 96px;
    min-height: 100vh;
    display: flex;
}

.page-viewport {
    flex: 1;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 44px 16px 40px;
    width: 100%;
}

.loading-screen,
.error-screen {
    min-height: 60vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    text-align: center;
    padding: 40px;
    font-family: var(--font-ui);
    color: var(--ink-soft);
}

.loading-mark {
    font-family: var(--font-display);
    font-size: 32px;
    font-weight: 600;
    color: var(--ink);
    letter-spacing: -0.01em;
}

.spinner {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 2.5px solid var(--hairline);
    border-top-color: var(--primary);
    animation: spin 0.9s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ===== "PAGE SHEET" — kartu halaman ala kertas, dengan tumpukan halaman di baliknya ===== */
.page-sheet-wrap {
    position: relative;
    width: 100%;
    max-width: 860px;
    margin: 0 auto;
    isolation: isolate;
}

.page-sheet-wrap::before,
.page-sheet-wrap::after {
    content: '';
    position: absolute;
    left: 10px;
    right: 10px;
    border-radius: 4px;
    box-shadow: 0 10px 30px -18px rgba(36, 31, 46, 0.3);
    z-index: 0;
    pointer-events: none;
}

.page-sheet-wrap::before {
    top: 10px;
    bottom: -8px;
    opacity: .75;
    transform: rotate(-0.6deg);
}

.page-sheet-wrap::after {
    top: 18px;
    bottom: -14px;
    opacity: .5;
    transform: rotate(0.9deg);
    left: 18px;
    right: 18px;
}

#pageStage {
    position: relative;
    z-index: 2;
    background: var(--surface);
    border-radius: 4px;
    box-shadow: var(--shadow);
    padding: clamp(32px, 6vw, 68px) clamp(24px, 6vw, 72px) clamp(48px, 6vw, 72px);
    min-height: calc(100vh - 200px);
    opacity: 1;
    transform: translateX(0) scale(1);
    transition: opacity .26s ease, transform .32s cubic-bezier(.22, .68, .32, 1);
}

/* halaman sedang "keluar" (sebelum konten diganti) */
#pageStage.stage-exit-fwd {
    opacity: 0;
    transform: translateX(-4%) scale(.98);
}

#pageStage.stage-exit-back {
    opacity: 0;
    transform: translateX(4%) scale(.98);
}

/* posisi awal halaman baru sebelum masuk — dipasang TANPA transisi (snap instan),
   lalu dilepas supaya browser meng-animasikan balik ke posisi normal */
#pageStage.stage-enter-prep-fwd,
#pageStage.stage-enter-prep-back {
    transition: none;
}

#pageStage.stage-enter-prep-fwd {
    opacity: 0;
    transform: translateX(4%) scale(.98);
}

#pageStage.stage-enter-prep-back {
    opacity: 0;
    transform: translateX(-4%) scale(.98);
}

@media (prefers-reduced-motion: reduce) {
    #pageStage {
        transition: none !important;
    }
}

@media (max-width:600px) {

    .page-sheet-wrap::before,
    .page-sheet-wrap::after {
        display: none;
    }

    .page-viewport {
        padding: 20px 10px 24px;
    }
}

/* skeleton loader saat pindah bulan */
.skeleton-screen {
    width: 100%;
}

.skeleton-block {
    background: linear-gradient(100deg, var(--bg-alt) 30%, var(--surface) 50%, var(--bg-alt) 70%);
    background-size: 200% 100%;
    animation: shimmer 1.4s ease-in-out infinite;
    border-radius: 6px;
}

@keyframes shimmer {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

/* ---- Masthead / cover ---- */
.cover-top {
    position: relative;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--ink);
}

.cover-eyebrow {
    font-family: var(--font-ui);
    font-size: 12px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--primary);
    font-weight: 600;
    margin-bottom: 6px;
}

.cover-title {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: clamp(34px, 6vw, 50px);
    line-height: 0.98;
    letter-spacing: -0.02em;
}

.cover-title .dot {
    color: var(--accent);
}

.cover-edition {
    font-family: var(--font-ui);
    text-align: right;
    color: var(--ink-soft);
}

.cover-edition .vol {
    font-size: 11px;
    letter-spacing: 0.1em;
    color: var(--primary);
    font-weight: 600;
    margin-bottom: 2px;
}

.cover-edition .month {
    font-family: var(--font-display);
    font-weight: 500;
    font-size: 19px;
    color: var(--ink);
}

.cover-edition .tag {
    font-size: 11px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.toc-heading {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--secondary);
    margin-bottom: 22px;
}

[data-theme="dark"] .toc-heading {
    color: var(--accent);
}

.toc-wrap {
    display: flex;
    flex-direction: column;
    gap: 26px;
}

.toc-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.toc-section-label {
    font-family: var(--font-ui);
    font-size: 11px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--ink-soft);
    margin-bottom: 6px;
}

.toc-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.toc-row {
    border-bottom: 1px dashed var(--hairline);
}

.toc-row:last-child {
    border-bottom: none;
}

.toc-link {
    display: flex;
    align-items: baseline;
    width: 100%;
    background: none;
    border: none;
    text-align: left;
    cursor: pointer;
    padding: 12px 4px;
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 17px;
    transition: color .2s ease;
}

.toc-link:hover {
    color: var(--primary);
}

.toc-title {
    flex-shrink: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 72%;
}

.toc-dots {
    flex: 1;
    border-bottom: 2px dotted var(--hairline);
    margin: 0 8px 5px;
    min-width: 16px;
}

.toc-num {
    flex-shrink: 0;
    font-family: var(--font-ui);
    font-size: 13px;
    color: var(--ink-soft);
    font-variant-numeric: tabular-nums;
}

.toc-empty {
    font-family: var(--font-ui);
    color: var(--ink-soft);
    font-size: 14px;
}

.edition-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 40px;
    padding-top: 22px;
    border-top: 1px solid var(--hairline);
}

.edition-nav-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: none;
    border: none;
    cursor: pointer;
    font-family: var(--font-ui);
    font-size: 13px;
    font-weight: 600;
    color: var(--ink-soft);
    padding: 8px 4px;
    transition: color .2s ease;
}

.edition-nav-btn:hover {
    color: var(--primary);
}

.edition-nav-btn .arr {
    color: var(--accent);
    font-size: 15px;
}

/* ---- Kicker: label section + tombol kembali ke Daftar Isi ---- */
.page-kicker {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px 12px;
    flex-wrap: wrap;
    margin-bottom: 26px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--hairline);
}

.kicker-toc-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--ink-soft);
    font-family: var(--font-ui);
    font-size: 12.5px;
    font-weight: 600;
    padding: 4px 0;
    transition: color .2s ease;
}

.kicker-toc-btn:hover {
    color: var(--primary);
}

.kicker-toc-btn svg {
    width: 14px;
    height: 14px;
}

.page-kicker-sec {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 12px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--secondary);
    display: flex;
    align-items: center;
    gap: 8px;
}

[data-theme="dark"] .page-kicker-sec {
    color: var(--accent);
}

.page-kicker-sec::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent);
}

/* ---- Halaman Hero (cerita sampul) ---- */
.hero-tag {
    font-family: var(--font-ui);
    font-size: 12px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--primary);
    font-weight: 600;
    margin-bottom: 12px;
}

.hero-title {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: clamp(28px, 4.4vw, 42px);
    line-height: 1.05;
    margin: 0 0 14px;
    letter-spacing: -0.01em;
}

.hero-img-wrap {
    overflow: hidden;
    border-radius: 6px;
    box-shadow: var(--shadow);
    margin: 20px 0 28px;
}

.hero-img {
    width: 100%;
    max-height: 420px;
    object-fit: cover;
    display: block;
    transition: transform .7s ease;
}

.hero-img-wrap:hover .hero-img {
    transform: scale(1.03);
}

/* ---- Halaman artikel biasa ---- */
.article-title {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: clamp(24px, 3.6vw, 34px);
    line-height: 1.15;
    letter-spacing: -0.01em;
    margin: 0 0 12px;
}

.article-img-wrap {
    margin: 20px 0 28px;
    overflow: hidden;
    border-radius: 6px;
    box-shadow: var(--shadow);
}

.article-img {
    width: 100%;
    max-height: 460px;
    object-fit: cover;
    display: block;
    transition: transform .7s ease;
}

.article-img-wrap:hover .article-img {
    transform: scale(1.03);
}

.article-meta {
    font-family: var(--font-ui);
    font-size: 12px;
    letter-spacing: 0.03em;
    color: var(--ink-soft);
    text-transform: uppercase;
}

.article-meta .sep {
    opacity: .55;
    margin: 0 2px;
}

.article-body {
    font-family: var(--font-body);
    font-size: 18.5px;
    line-height: 1.75;
    color: var(--ink);
    text-align: justify;
    hyphens: auto;
    -webkit-hyphens: auto;
}

.article-body p {
    margin: 0 0 20px;
}

.article-body p:first-of-type::first-letter {
    font-family: var(--font-display);
    font-size: 3.1em;
    font-weight: 700;
    float: left;
    line-height: 0.85;
    padding: 6px 10px 0 0;
    color: var(--primary);
}

.article-body img {
    width: 100%;
    height: auto;
    border-radius: 6px;
    margin: 16px 0;
    box-shadow: var(--shadow);
}

.article-body h1,
.article-body h2,
.article-body h3,
.article-body h4 {
    font-family: var(--font-display);
    font-weight: 600;
    color: var(--ink);
    margin: 30px 0 14px;
    line-height: 1.25;
}

.article-body a {
    color: var(--primary);
    text-decoration-color: var(--accent);
    text-underline-offset: 3px;
}

.article-body ul,
.article-body ol {
    margin: 0 0 20px;
    padding-left: 24px;
}

.article-body li {
    margin-bottom: 8px;
}

.article-body blockquote {
    position: relative;
    margin: 32px 0;
    padding: 6px 0 6px 30px;
    border-left: 3px solid var(--accent);
    font-family: var(--font-display);
    font-weight: 500;
    font-style: italic;
    font-size: 23px;
    line-height: 1.4;
    color: var(--secondary);
    text-align: left;
}

[data-theme="dark"] .article-body blockquote {
    color: var(--accent);
}

.article-body blockquote::before {
    content: '\201C';
    position: absolute;
    left: -4px;
    top: -20px;
    font-family: var(--font-display);
    font-size: 54px;
    color: var(--accent);
    opacity: 0.35;
}

.article-body figure {
    margin: 16px 0;
}

.article-body figcaption {
    font-family: var(--font-ui);
    font-size: 12.5px;
    color: var(--ink-soft);
    margin-top: 8px;
    font-style: italic;
}

/* ---- Halaman penutup edisi ---- */
/* ===== END OF MAGAZINE PAGE ===== */
.eom-page {
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 200px);
    text-align: center;
    gap: 0;
}

/* Top closing mark */
.eom-top {
    padding: 40px 0 32px;
    border-bottom: 1px solid var(--hairline);
}

.eom-mark {
    font-family: var(--font-display);
    font-weight: 500;
    font-style: italic;
    font-size: 19px;
    color: var(--ink-soft);
    letter-spacing: 0.02em;
}

.eom-mark .dot {
    color: var(--accent);
}

.eom-sub {
    font-family: var(--font-ui);
    font-size: 13px;
    color: var(--ink-soft);
    margin-top: 8px;
}

/* Commitment CTA section */
.eom-cta-wrap {
    padding: 36px 0 32px;
    border-bottom: 1px solid var(--hairline);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.eom-cta-label {
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 700;
    color: var(--ink);
    letter-spacing: -0.01em;
}

.eom-commit-btn {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 14px 36px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: #fff;
    font-family: var(--font-ui);
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0.02em;
    border: none;
    cursor: pointer;
    box-shadow: 0 6px 24px -6px rgba(107, 70, 193, 0.55);
    transition: opacity .2s ease, transform .15s ease, box-shadow .2s ease;
}

.eom-commit-btn:hover {
    opacity: .92;
    transform: translateY(-2px);
    box-shadow: 0 10px 32px -6px rgba(107, 70, 193, 0.65);
}

.eom-commit-btn i {
    font-size: 16px;
}

.eom-cta-sub {
    font-family: var(--font-ui);
    font-size: 12px;
    color: var(--ink-soft);
    max-width: 360px;
    line-height: 1.6;
}

/* Social links grid */
.eom-socials {
    padding: 32px 0 28px;
    border-bottom: 1px solid var(--hairline);
    flex: 1;
}

.eom-socials-label {
    font-family: var(--font-ui);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--ink-soft);
    margin-bottom: 20px;
}

.eom-socials-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    max-width: 560px;
    margin: 0 auto;
}

.eom-social-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 12px;
    background: var(--bg-alt);
    border: 1px solid var(--hairline);
    text-decoration: none;
    color: var(--ink);
    transition: background .2s ease, border-color .2s ease, transform .15s ease;
    text-align: left;
}

.eom-social-item:hover {
    background: var(--surface);
    border-color: var(--accent);
    transform: translateY(-2px);
    color: var(--primary);
}

.eom-social-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: var(--primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 16px;
}

/* Per-platform icon colors */
.eom-social-item:nth-child(1) .eom-social-icon {
    background: linear-gradient(135deg, #E1306C, #833AB4);
}

/* IG */
.eom-social-item:nth-child(2) .eom-social-icon {
    background: #FF0000;
}

/* YouTube */
.eom-social-item:nth-child(3) .eom-social-icon {
    background: #1877F2;
}

/* Facebook */
.eom-social-item:nth-child(4) .eom-social-icon {
    background: #4B39A1;
}

/* Website */
.eom-social-item:nth-child(5) .eom-social-icon {
    background: #C8102E;
}

/* Radio */
.eom-social-item:nth-child(6) .eom-social-icon {
    background: #1DB954;
}

/* Spotify */

.eom-social-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.eom-social-name {
    font-family: var(--font-ui);
    font-size: 12px;
    font-weight: 700;
    color: var(--ink);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.eom-social-handle {
    font-family: var(--font-ui);
    font-size: 11px;
    color: var(--ink-soft);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Footer nav */
.eom-footer {
    padding: 24px 0 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.eom-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 22px;
    border-radius: 999px;
    background: none;
    border: 1.5px solid var(--hairline);
    color: var(--ink-soft);
    font-family: var(--font-ui);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: border-color .2s ease, color .2s ease;
}

.eom-back:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.eom-page .edition-nav {
    width: 100%;
    text-align: left;
}

/* Mobile */
@media (max-width: 600px) {
    .eom-socials-grid {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px !important;
    }

    .eom-social-item {
        display: flex !important;
        padding: 10px 10px;
        gap: 8px;
    }

    .eom-cta-label {
        font-size: 18px;
    }

    .eom-commit-btn {
        font-size: 14px;
        padding: 12px 28px;
    }

    .eom-social-icon {
        width: 32px;
        height: 32px;
        font-size: 14px;
        border-radius: 8px;
    }

    .eom-social-name {
        font-size: 11px;
    }

    .eom-social-handle {
        font-size: 10px;
    }

    .eom-top {
        padding: 28px 0 24px;
    }

    .eom-cta-wrap {
        padding: 24px 0 22px;
    }

    .eom-socials {
        padding: 24px 0 20px;
    }
}

.empty-state {
    max-width: 480px;
    margin: 60px auto;
    text-align: center;
    padding: 0 24px;
    font-family: var(--font-ui);
    color: var(--ink-soft);
}

.empty-state h3 {
    font-family: var(--font-display);
    font-size: 24px;
    color: var(--ink);
    margin-bottom: 10px;
}

/* ===== BOTTOM PAGE-TURN NAV BAR (persisten, seperti kontrol e-reader) ===== */
.page-nav-bar {
    position: fixed;
    /* Tengah area konten: offset dari sidebar di desktop */
    left: calc(var(--sidebar-w) + (100vw - var(--sidebar-w)) / 2);
    bottom: 28px;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 6px;
    background: var(--sidebar-bg);
    color: var(--sidebar-ink);
    border-radius: 999px;
    padding: 8px 10px;
    box-shadow: 0 8px 32px -8px rgba(0, 0, 0, 0.45), 0 2px 8px rgba(0, 0, 0, 0.2);
    z-index: 56;
    transition: opacity .2s ease, transform .2s ease;
    /* Minimum width agar terasa sebagai navigasi, bukan tombol kecil */
    min-width: 260px;
    justify-content: space-between;
}

/* Sembunyikan page nav saat drawer mobile terbuka — pure CSS, no JS needed */
@media (max-width: 1023px) {
    .drawer-open-body .page-nav-bar {
        display: none !important;
    }

    .page-nav-bar.nav-hidden {
        display: none !important;
    }
}

.page-nav-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.10);
    color: var(--sidebar-ink);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background .2s ease, opacity .2s ease;
    flex-shrink: 0;
}

.page-nav-btn:hover:not(:disabled) {
    background: var(--accent);
    color: #241F2E;
}

.page-nav-btn:disabled {
    opacity: .25;
    cursor: default;
}

.page-nav-btn svg {
    width: 20px;
    height: 20px;
}

.page-indicator {
    font-family: var(--font-ui);
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: var(--sidebar-ink);
    background: none;
    border: none;
    cursor: pointer;
    padding: 0 12px;
    white-space: nowrap;
    flex: 1;
    text-align: center;
}

.page-indicator:hover {
    color: var(--accent);
}

@media (max-width:1023px) {
    .page-nav-bar {
        left: 50%;
        bottom: 18px;
        min-width: 220px;
    }
}

@media (max-width:600px) {
    .fab-top {
        right: 16px;
        bottom: 78px;
    }

    .article-body {
        font-size: 17px;
        text-align: left;
    }

    .cover-top {
        flex-direction: column;
        align-items: flex-start;
    }

    .cover-edition {
        text-align: left;
    }

    .toc-title {
        max-width: 60%;
    }
}

/* ===== SIDEBAR FOOT — commitment variant ===== */
.sidebar-foot--commitment {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
}

.sidebar-foot-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

/* ===== COMMITMENT BUTTON (sidebar-foot) ===== */
.commitment-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    width: 100%;
    padding: 10px 16px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: #fff;
    font-family: var(--font-ui);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.03em;
    border: none;
    cursor: pointer;
    transition: opacity .2s ease, transform .15s ease, box-shadow .2s ease;
    box-shadow: 0 4px 18px -4px rgba(107, 70, 193, 0.55);
    flex-shrink: 0;
}

.commitment-btn:hover {
    opacity: .92;
    transform: translateY(-1px);
    box-shadow: 0 8px 24px -4px rgba(107, 70, 193, 0.65);
}

.commitment-btn i {
    font-size: 15px;
    line-height: 1;
}

.commitment-btn:active {
    transform: translateY(0);
}

/* ===== COMMITMENT MODAL OVERLAY ===== */
.commitment-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(10, 8, 20, 0.72);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 200;
    align-items: flex-start;
    /* flex-start agar panel tidak terpotong di layar pendek */
    justify-content: center;
    padding: 20px 16px 32px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.commitment-overlay.open {
    display: flex;
}

/* ===== COMMITMENT MODAL PANEL ===== */
.commitment-panel {
    background: var(--surface);
    border-radius: 18px;
    width: 100%;
    max-width: 820px;
    box-shadow: 0 32px 80px -16px rgba(0, 0, 0, 0.55);
    overflow: hidden;
    animation: modalIn .3s cubic-bezier(.22, .68, .32, 1) forwards;
    position: relative;
    margin: auto;
    /* center horizontal */
    align-self: center;
    /* center vertical when content shorter than viewport */
}

@keyframes modalIn {
    from {
        opacity: 0;
        transform: translateY(24px) scale(.97);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.commitment-panel-head {
    background: linear-gradient(135deg, var(--primary) 0%, #9B6DFA 100%);
    padding: 28px 32px 24px;
    position: relative;
    text-align: center;
}

.commitment-panel-head .modal-eyebrow {
    font-family: var(--font-ui);
    font-size: 11px;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 8px;
}

.commitment-panel-head h2 {
    font-family: var(--font-display);
    font-size: clamp(18px, 5vw, 26px);
    /* 5vw = 19px at 375px — readable on mobile */
    font-weight: 700;
    color: #fff;
    margin: 0;
    letter-spacing: -0.01em;
    line-height: 1.2;
}

.commitment-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.18);
    border: none;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background .2s ease;
}

.commitment-close:hover {
    background: rgba(255, 255, 255, 0.32);
}

.commitment-close svg {
    width: 16px;
    height: 16px;
}

/* ===== MINISTRY SECTION ===== */
.commitment-body {
    padding: 20px 24px 28px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    /* tighter gap between sections */
}

.ministry-section-label {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 15px;
    color: var(--ink);
    margin: 0 0 4px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.ministry-section-label::before {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    flex-shrink: 0;
}

.ministry-tagline {
    font-family: var(--font-body);
    font-size: 13.5px;
    font-style: italic;
    color: var(--ink-soft);
    margin: 0 0 14px;
    padding-left: 16px;
}

/* ===== MINISTRY SECTION WRAPPER — visual grouping ===== */
.ministry-section {
    border-radius: 16px;
    overflow: hidden;
    border: 1.5px solid var(--hairline);
}

/* ===== COMMITMENT CARDS GRID ===== */
.commitment-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    border-top: 1.5px solid var(--hairline);
}

.commitment-card {
    border: none;
    border-right: 1.5px solid var(--hairline);
    border-radius: 0;
    padding: 18px 14px 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    text-align: center;
    transition: background .2s ease, transform .15s ease;
    background: transparent;
}

.commitment-card:last-child {
    border-right: none;
}

.commitment-card:hover {
    transform: none;
    box-shadow: none;
}

.commitment-card .card-amount {
    font-family: var(--font-display);
    font-size: 26px;
    font-weight: 700;
    color: var(--ink);
    letter-spacing: -0.02em;
    line-height: 1;
}

.commitment-card .card-amount span {
    font-size: 14px;
    font-weight: 500;
    color: var(--ink-soft);
    margin-left: 1px;
}

.commitment-card .card-freq {
    font-family: var(--font-ui);
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink-soft);
}

.commitment-card .card-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    margin-top: 10px;
    width: 100%;
    padding: 8px 12px;
    border-radius: 999px;
    background: transparent;
    color: var(--primary);
    font-family: var(--font-ui);
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-decoration: none;
    transition: background .2s ease, color .2s ease, box-shadow .2s ease;
    border: 2px solid currentColor;
    cursor: pointer;
}

.commitment-card .card-cta:hover {
    background: var(--primary);
    color: #fff;
    box-shadow: 0 4px 14px -4px rgba(107, 70, 193, 0.45);
}

.commitment-card .card-cta svg {
    width: 13px;
    height: 13px;
}

/* Divider between ministry sections */
.ministry-divider {
    height: 1px;
    background: var(--hairline);
    margin: 0;
}

/* Modal footer note */
.commitment-foot-note {
    text-align: center;
    font-family: var(--font-ui);
    font-size: 11.5px;
    color: var(--ink-soft);
    padding: 0 28px 20px;
    line-height: 1.6;
}

.commitment-foot-note a {
    color: var(--primary);
    text-underline-offset: 2px;
}

@media (max-width: 600px) {

    /* Overlay: full bleed, no side padding so panel can go edge-to-edge */
    .commitment-overlay {
        padding: 0;
        align-items: flex-end;
        /* sheet slides up from bottom on mobile */
    }

    /* Panel: bottom sheet style */
    .commitment-panel {
        border-radius: 20px 20px 0 0;
        max-width: 100%;
        align-self: flex-end;
        animation: modalInMobile .3s cubic-bezier(.22, .68, .32, 1) forwards;
    }

    @keyframes modalInMobile {
        from {
            opacity: 0;
            transform: translateY(40px);
        }

        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .commitment-panel-head {
        padding: 20px 18px 18px;
    }

    /* Drag handle hint */
    .commitment-panel-head::before {
        content: '';
        display: block;
        width: 36px;
        height: 4px;
        border-radius: 999px;
        background: rgba(255, 255, 255, 0.4);
        margin: 0 auto 14px;
    }

    .commitment-body {
        padding: 18px 14px 20px;
        gap: 20px;
    }

    .commitment-cards {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    /* Horizontal card layout: amount left, button right */
    .commitment-card {
        flex-direction: row;
        text-align: left;
        justify-content: space-between;
        align-items: center;
        padding: 13px 14px;
        gap: 12px;
    }

    .commitment-card .card-amount {
        font-size: 22px;
    }

    .commitment-card .card-freq {
        font-size: 10px;
    }

    /* CTA button: right side, min 44px tap target */
    .commitment-card .card-cta {
        width: auto;
        flex-shrink: 0;
        margin-top: 0;
        padding: 10px 20px;
        min-height: 44px;
        white-space: nowrap;
    }

    .commitment-foot-note {
        padding: 0 14px 20px;
        font-size: 11px;
    }
}

/* ===== MINISTRY SECTION HEADERS — distinct visual identity ===== */

/* Shared header structure */
.ministry-sec-header {
    position: relative;
    border-radius: 0;
    overflow: hidden;
    margin-bottom: 0;
    padding: 20px 22px;
}

.ministry-sec-pattern {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}

.ministry-sec-header-content {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 16px;
}

.ministry-sec-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.ministry-sec-title {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 17px;
    margin-bottom: 4px;
}

.ministry-sec-tagline {
    font-family: var(--font-body);
    font-style: italic;
    font-size: 13px;
    line-height: 1.45;
    opacity: 0.85;
}

/* ---- Children Ministry — dots pattern, purple-indigo ---- */
.ministry-children .ministry-sec-header {
    background: linear-gradient(135deg, #5B35A8 0%, #7C4DCC 60%, #9B6DFA 100%);
    color: #fff;
}

.ministry-children .ministry-sec-pattern {
    background-image: radial-gradient(circle, rgba(255, 255, 255, 0.18) 1.5px, transparent 1.5px);
    background-size: 18px 18px;
}

.ministry-children .ministry-sec-icon {
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

/* Children cards — indigo tint */
.ministry-children .commitment-cards {
    background: #F5F0FF;
}

.ministry-children .commitment-card {
    background: transparent;
}

.ministry-children .commitment-card:hover {
    background: rgba(107, 70, 193, 0.07);
}

.ministry-children .commitment-card .card-amount {
    color: var(--ink);
}

.ministry-children .commitment-card .card-cta {
    color: #6B46C1;
    border-color: #6B46C1;
}

.ministry-children .commitment-card .card-cta:hover {
    background: #6B46C1;
    color: #fff;
    box-shadow: 0 4px 14px -4px rgba(107, 70, 193, 0.45);
}

.ministry-children {
    border-color: #C4B0F0;
}

/* ---- Women Ministry — diagonal lines pattern, violet-rose ---- */
.ministry-women .ministry-sec-header {
    background: linear-gradient(135deg, #7B3F9E 0%, #9D5BB5 55%, #C084D4 100%);
    color: #fff;
}

.ministry-women .ministry-sec-pattern {
    background-image: repeating-linear-gradient(45deg,
            rgba(255, 255, 255, 0.10) 0px,
            rgba(255, 255, 255, 0.10) 1.5px,
            transparent 1.5px,
            transparent 12px);
}

.ministry-women .ministry-sec-icon {
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

/* Women cards — rose-violet tint */
.ministry-women .commitment-cards {
    background: #FBF5FF;
}

.ministry-women .commitment-card {
    background: transparent;
}

.ministry-women .commitment-card:hover {
    background: rgba(139, 63, 174, 0.07);
}

.ministry-women .commitment-card .card-amount {
    color: var(--ink);
}

.ministry-women .commitment-card .card-cta {
    color: #8B3FAE;
    border-color: #8B3FAE;
}

.ministry-women .commitment-card .card-cta:hover {
    background: #8B3FAE;
    color: #fff;
    box-shadow: 0 4px 14px -4px rgba(139, 63, 174, 0.45);
}

.ministry-women {
    border-color: #D4A8E8;
}

/* Remove old ministry-section-label & tagline since replaced */
.ministry-section-label,
.ministry-tagline,
.ministry-divider {
    display: none;
}

/* Dark mode adjustments */
[data-theme="dark"] .ministry-children .commitment-cards {
    background: rgba(107, 70, 193, 0.1);
}

[data-theme="dark"] .ministry-children .commitment-card:hover {
    background: rgba(107, 70, 193, 0.15);
}

[data-theme="dark"] .ministry-children .commitment-card .card-amount {
    color: var(--ink);
}

[data-theme="dark"] .ministry-children .commitment-card .card-cta {
    color: #A78BFA;
    border-color: #A78BFA;
}

[data-theme="dark"] .ministry-children .commitment-card .card-cta:hover {
    background: #7C4DCC;
    color: #fff;
}

[data-theme="dark"] .ministry-children {
    border-color: #5B35A8;
}

[data-theme="dark"] .ministry-women .commitment-cards {
    background: rgba(139, 63, 174, 0.1);
}

[data-theme="dark"] .ministry-women .commitment-card:hover {
    background: rgba(139, 63, 174, 0.15);
}

[data-theme="dark"] .ministry-women .commitment-card .card-amount {
    color: var(--ink);
}

[data-theme="dark"] .ministry-women .commitment-card .card-cta {
    color: #C084D4;
    border-color: #C084D4;
}

[data-theme="dark"] .ministry-women .commitment-card .card-cta:hover {
    background: #9D5BB5;
    color: #fff;
}

[data-theme="dark"] .ministry-women {
    border-color: #7B3F9E;
}

/* Mobile: tighter header + stacked cards */
@media (max-width: 600px) {
    .commitment-body {
        padding: 16px 14px 20px;
        gap: 12px;
    }

    .ministry-sec-header {
        padding: 14px 14px;
    }

    .ministry-sec-icon {
        width: 38px;
        height: 38px;
        font-size: 17px;
        border-radius: 10px;
    }

    .ministry-sec-title {
        font-size: 14px;
    }

    .ministry-sec-tagline {
        font-size: 11.5px;
    }

    /* Mobile cards: stacked vertically, horizontal layout */
    .commitment-cards {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .commitment-card {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        text-align: left;
        padding: 12px 14px;
        border-right: none;
        border-bottom: 1.5px solid var(--hairline);
    }

    .commitment-card:last-child {
        border-bottom: none;
    }

    .commitment-card .card-amount {
        font-size: 20px;
    }

    .commitment-card .card-cta {
        width: auto;
        flex-shrink: 0;
        margin-top: 0;
        padding: 8px 20px;
        min-height: 40px;
        white-space: nowrap;
    }
}

/* ===== MOST FAITHFUL / POPULAR CARD ===== */
.card-popular {
    position: relative;
}

/* Children ministry popular card */
.ministry-children .card-popular {
    background: rgba(107, 70, 193, 0.08);
}

/* Women ministry popular card */
.ministry-women .card-popular {
    background: rgba(139, 63, 174, 0.08);
}

.card-popular-badge {
    font-family: var(--font-ui);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    padding: 3px 10px;
    border-radius: 999px;
    margin-bottom: 8px;
    display: inline-block;
}

.ministry-children .card-popular-badge {
    background: #6B46C1;
    color: #fff;
}

.ministry-women .card-popular-badge {
    background: #8B3FAE;
    color: #fff;
}

/* Popular card CTA — filled by default */
.ministry-children .card-popular .card-cta {
    background: #6B46C1;
    color: #fff;
}

.ministry-children .card-popular .card-cta:hover {
    background: #5B35A8;
    box-shadow: 0 4px 14px -4px rgba(107, 70, 193, 0.55);
}

.ministry-women .card-popular .card-cta {
    background: #8B3FAE;
    color: #fff;
}

.ministry-women .card-popular .card-cta:hover {
    background: #7B3F9E;
    box-shadow: 0 4px 14px -4px rgba(139, 63, 174, 0.55);
}

/* Dark mode popular */
[data-theme="dark"] .ministry-children .card-popular {
    background: rgba(107, 70, 193, 0.18);
}

[data-theme="dark"] .ministry-women .card-popular {
    background: rgba(139, 63, 174, 0.18);
}

/* ===== FOOTER NOTE — improved trust signal ===== */
.commitment-foot-note {
    text-align: center;
    font-family: var(--font-ui);
    font-size: 12px;
    color: var(--ink-soft);
    padding: 14px 28px 22px;
    line-height: 1.7;
    border-top: 1px solid var(--hairline);
}

.commitment-foot-note i {
    color: var(--primary);
    margin-right: 4px;
    font-size: 12px;
}

/* Mobile popular badge in horizontal layout */
@media (max-width: 600px) {
    .card-popular-badge {
        margin-bottom: 0;
        margin-right: 8px;
        font-size: 9px;
        padding: 2px 8px;
    }

    .card-popular {
        flex-wrap: wrap;
        gap: 8px;
    }

    .card-popular>div:first-child {
        display: flex;
        align-items: center;
        flex-wrap: wrap;
        gap: 6px;
    }
}

/* ===== CARD TIER TYPOGRAPHY — unified font sizes, no opacity diff ===== */

/* €20 */
.card-tier-sm .card-amount {
    font-size: 30px;
    font-weight: 700;
    letter-spacing: -0.03em;
    opacity: 1;
}

.card-tier-sm .card-freq {
    font-size: 11px;
    opacity: 1;
}

.card-tier-sm .card-cta {
    font-size: 12px;
    padding: 8px 12px;
    opacity: 1;
}

/* €35 — same size, heavier weight only */
.card-tier-md .card-amount {
    font-size: 30px;
    font-weight: 800;
    letter-spacing: -0.03em;
    opacity: 1;
}

.card-tier-md .card-freq {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.14em;
}

.card-tier-md .card-cta {
    font-size: 12px;
    padding: 8px 12px;
}

/* €50 */
.card-tier-lg .card-amount {
    font-size: 30px;
    font-weight: 700;
    letter-spacing: -0.03em;
    opacity: 1;
}

.card-tier-lg .card-freq {
    font-size: 11px;
}

.card-tier-lg .card-cta {
    font-size: 12px;
    padding: 8px 12px;
}

/* Mobile */
@media (max-width: 600px) {

    .card-tier-sm .card-amount,
    .card-tier-md .card-amount,
    .card-tier-lg .card-amount {
        font-size: 22px;
    }
}

/* Mobile: keep same size, reduce slightly */
@media (max-width: 600px) {

    .card-tier-sm .card-amount,
    .card-tier-md .card-amount,
    .card-tier-lg .card-amount {
        font-size: 22px;
    }
}

/* ============================================================
   MAGAZINE COVER — TIME-style, B&W collage
   ============================================================ */
.magazine-cover {
    margin: -clamp(32px, 6vw, 68px) -clamp(24px, 6vw, 72px) 0;
    overflow: hidden;
}

/* Red masthead bar */
.mc-header {
    background: #C8102E;
    padding: 10px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.mc-logo {
    font-family: var(--font-display);
    font-size: clamp(32px, 5vw, 48px);
    font-weight: 900;
    color: #fff;
    letter-spacing: -0.04em;
    line-height: 1;
    font-style: italic;
    text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.25);
}

.mc-header-meta {
    font-family: var(--font-ui);
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.8);
    text-align: right;
    flex-shrink: 0;
}

/* Collage container */
.mc-collage {
    position: relative;
    width: 100%;
    height: clamp(260px, 42vw, 420px);
    background: #111;
    overflow: hidden;
    display: grid;
    grid-template-columns: 1fr auto;
}

/* Main large image — left */
.mc-main-img {
    overflow: hidden;
    height: 100%;
}

.mc-main-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    filter: grayscale(100%) contrast(1.05);
    transition: transform .6s ease;
}

.mc-collage:hover .mc-main-img img {
    transform: scale(1.03);
}

/* Sub images strip — right */
.mc-sub-imgs {
    display: flex;
    flex-direction: column;
    width: clamp(80px, 16%, 130px);
    gap: 2px;
}

.mc-sub-img {
    flex: 1;
    overflow: hidden;
}

.mc-sub-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    filter: grayscale(100%) contrast(1.05);
    transition: transform .5s ease;
}

.mc-sub-img:hover img {
    transform: scale(1.06);
}

/* Dark gradient overlay — bottom third */
.mc-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top,
            rgba(0, 0, 0, 0.82) 0%,
            rgba(0, 0, 0, 0.35) 40%,
            rgba(0, 0, 0, 0.08) 70%,
            transparent 100%);
    pointer-events: none;
}

/* Cover text over image */
.mc-cover-text {
    position: absolute;
    bottom: 18px;
    left: 20px;
    right: calc(clamp(80px, 16%, 130px) + 12px);
    color: #fff;
    pointer-events: none;
}

.mc-edition-label {
    font-family: var(--font-ui);
    font-size: 10px;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 4px;
}

.mc-cover-month {
    font-family: var(--font-display);
    font-size: clamp(22px, 4vw, 34px);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.5);
}

/* Mobile — simpler single image layout */
@media (max-width: 600px) {
    .mc-sub-imgs {
        display: none;
    }

    .mc-collage {
        grid-template-columns: 1fr;
    }

    .mc-cover-text {
        right: 16px;
        left: 16px;
    }

    .mc-header {
        padding: 8px 16px;
    }
}

/* ============================================================
   GOOGLE TRANSLATE WIDGET — minimal styling
   ============================================================ */
#google_translate_element {
    font-family: var(--font-ui);
    font-size: 12px;
}

/* Hide Google's default banner & branding */
.goog-te-banner-frame,
.skiptranslate>iframe {
    display: none !important;
}

body {
    top: 0 !important;
}

.goog-te-gadget {
    color: transparent !important;
    font-size: 0 !important;
}

.goog-te-gadget .goog-te-combo {
    font-family: var(--font-ui) !important;
    font-size: 11px !important;
    background: rgba(255, 255, 255, 0.1) !important;
    color: var(--sidebar-ink) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    border-radius: 6px !important;
    padding: 4px 6px !important;
    cursor: pointer !important;
    max-width: 90px;
}

.goog-te-gadget .goog-te-combo:focus {
    outline: none !important;
    border-color: var(--accent) !important;
}

/* Sidebar foot controls wrapper */
.sidebar-foot-controls {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
    flex-shrink: 0;
}

@media (max-width: 1023px) {
    .sidebar-foot-controls #google_translate_element {
        display: none;
    }
}

/* ============================================================
   MAGAZINE COVER PAGE — full viewport, B&W collage, TIME-style
   ============================================================ */

/* Override page-sheet padding untuk cover agar full bleed */
#pageStage:has(.magazine-cover-page) {
    padding: 0 !important;
    border-radius: 4px;
    overflow: hidden;
}

.magazine-cover-page {
    position: relative;
    width: 100%;
}

/* Collage container — tinggi viewport dikurangi nav bar */
.mc-collage {
    position: relative;
    width: 100%;
    height: calc(100vh - 80px);
    min-height: 500px;
    max-height: 900px;
    display: grid;
    overflow: hidden;
    gap: 3px;
    background: #000;
}

/* Layout 3 gambar: kiri besar + kanan 2 kecil */
.mc-layout-3 {
    grid-template-columns: 1fr 38%;
}

.mc-layout-2 {
    grid-template-columns: 1fr 38%;
}

.mc-layout-1 {
    grid-template-columns: 1fr;
}

.mc-left,
.mc-right {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.mc-img {
    overflow: hidden;
    flex: 1;
}

.mc-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    filter: grayscale(100%) contrast(1.08) brightness(0.92);
    transition: transform .7s ease;
}

.mc-collage:hover .mc-img-main img {
    transform: scale(1.04);
}

/* Gradient overlay — gelap di atas (untuk masthead) & bawah (untuk teks) */
.mc-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(to bottom, rgba(0, 0, 0, 0.75) 0%, rgba(0, 0, 0, 0) 28%),
        linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0) 45%);
    pointer-events: none;
    z-index: 1;
}

/* ---- Masthead ---- */
.mc-masthead {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 2;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 18px 24px 14px;
    background: linear-gradient(to bottom,
            rgba(90, 40, 160, 0.95) 0%,
            rgba(107, 70, 193, 0.7) 60%,
            transparent 100%);
}

.mc-logo {
    font-family: var(--font-display);
    font-size: clamp(36px, 7vw, 64px);
    font-weight: 900;
    font-style: italic;
    color: #fff;
    letter-spacing: -0.04em;
    line-height: 1;
    text-shadow: 2px 3px 12px rgba(0, 0, 0, 0.4);
}

.mc-dot {
    color: #fff;
}

.mc-masthead-right {
    text-align: right;
    color: rgba(255, 255, 255, 0.85);
    padding-top: 6px;
}

.mc-vol {
    font-family: var(--font-ui);
    font-size: 11px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    margin-bottom: 2px;
}

.mc-ytwr {
    font-family: var(--font-ui);
    font-size: 11px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    opacity: 0.7;
}

/* ---- Body text (bawah) ---- */
.mc-body-text {
    position: absolute;
    bottom: 72px;
    left: 24px;
    right: 42%;
    /* hindari panel kanan */
    z-index: 2;
    color: #fff;
}

.mc-layout-1 .mc-body-text,
.mc-layout-2 .mc-body-text {
    right: 24px;
}

.mc-edition-tag {
    font-family: var(--font-ui);
    font-size: 11px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 8px;
}

.mc-headline {
    font-family: var(--font-display);
    font-size: clamp(20px, 3.5vw, 36px);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.01em;
    text-shadow: 0 2px 16px rgba(0, 0, 0, 0.6);
    max-width: 480px;
}

/* ---- Enter button ---- */
.mc-enter-btn {
    position: absolute;
    bottom: 22px;
    left: 24px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.35);
    color: #fff;
    font-family: var(--font-ui);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.04em;
    padding: 10px 22px;
    border-radius: 999px;
    cursor: pointer;
    transition: background .2s ease, border-color .2s ease;
}

.mc-enter-btn:hover {
    background: rgba(255, 255, 255, 0.28);
    border-color: rgba(255, 255, 255, 0.6);
}

/* Mobile — completely different layout: full bg image + thumbnail strip */
@media (max-width: 600px) {
    .mc-collage {
        height: calc(100vh - 66px);
        min-height: 480px;
        display: block;
        /* tidak pakai grid di mobile */
        position: relative;
    }

    /* Sembunyikan panel kanan di mobile */
    .mc-right {
        display: none;
    }

    /* Gambar utama jadi full background */
    .mc-left {
        position: absolute;
        inset: 0;
    }

    .mc-img-main {
        width: 100%;
        height: 100%;
    }

    .mc-img-main img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    /* Thumbnail strip: gambar 2 & 3 di bawah sebagai strip kecil */
    .mc-thumb-strip {
        display: flex;
        position: absolute;
        bottom: 60px;
        right: 0;
        width: 90px;
        flex-direction: column;
        gap: 2px;
        z-index: 2;
    }

    .mc-thumb-strip .mc-thumb {
        height: 70px;
        overflow: hidden;
    }

    .mc-thumb-strip .mc-thumb img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        filter: grayscale(100%) contrast(1.08) brightness(0.92);
    }

    .mc-masthead {
        padding: 12px 16px 10px;
    }

    .mc-body-text {
        left: 16px;
        right: 104px;
        /* beri ruang untuk thumb strip */
        bottom: 68px;
    }

    .mc-headline {
        font-size: clamp(18px, 5.5vw, 26px);
    }

    .mc-enter-btn {
        left: 16px;
        bottom: 16px;
        font-size: 12px;
        padding: 9px 18px;
    }
}

/* ============================================================
   CUSTOM TRANSLATE WIDGET
   ============================================================ */
.translate-widget {
    position: relative;
}

.tw-wrap {
    position: relative;
}

.tw-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(167, 139, 250, 0.18);
    border: 1px solid rgba(167, 139, 250, 0.45);
    color: #fff;
    font-family: var(--font-ui);
    font-size: 12px;
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 999px;
    cursor: pointer;
    white-space: nowrap;
    transition: background .2s ease, border-color .2s ease, box-shadow .2s ease;
    letter-spacing: 0.01em;
}

.tw-btn:hover {
    background: rgba(167, 139, 250, 0.32);
    border-color: rgba(167, 139, 250, 0.7);
    box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.12);
}

.tw-btn .bi-translate {
    font-size: 13px;
    color: var(--accent);
}

.tw-chev {
    font-size: 10px;
    opacity: 0.8;
    transition: transform .2s ease;
    color: var(--accent);
}

.tw-dropdown.open~* .tw-chev,
.tw-wrap:has(.tw-dropdown.open) .tw-chev {
    transform: rotate(180deg);
}

.tw-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: #1E1830;
    border: 1px solid rgba(167, 139, 250, 0.3);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 16px 48px -8px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(167, 139, 250, 0.08);
    z-index: 300;
    min-width: 170px;
    animation: twDropIn .18s ease forwards;
}

@keyframes twDropIn {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.tw-dropdown.open {
    display: block;
}

.tw-option {
    display: block;
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    padding: 10px 16px;
    font-family: var(--font-ui);
    font-size: 13px;
    color: rgba(255, 255, 255, 0.75);
    cursor: pointer;
    transition: background .15s ease, color .15s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.tw-option:last-child {
    border-bottom: none;
}

.tw-option:hover {
    background: rgba(167, 139, 250, 0.15);
    color: #fff;
}

/* Desktop: widget di bawah sidebar-header */
.translate-widget--sidebar {
    padding: 0 26px 12px;
}

.translate-widget--sidebar .tw-btn {
    width: 100%;
    justify-content: space-between;
}

.translate-widget--sidebar .tw-dropdown {
    left: 0;
    right: 0;
    min-width: unset;
}

/* Mobile translate widget */
@media (max-width: 1023px) {
    .translate-widget--sidebar {
        display: none;
    }

    /* Mobile dropdown: fixed position, full width, below mobile-bar */
    #translateWidgetMobile .tw-dropdown {
        position: fixed;
        top: 66px;
        /* tinggi mobile-bar */
        left: 0;
        right: 0;
        width: 100%;
        min-width: unset;
        border-radius: 0 0 16px 16px;
        z-index: 1000;
        max-height: 70vh;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    #translateWidgetMobile .tw-option {
        font-size: 15px;
        padding: 14px 20px;
    }

    /* Overlay gelap di belakang dropdown */
    #translateWidgetMobile .tw-dropdown.open::before {
        content: '';
        position: fixed;
        inset: 0;
        top: 66px;
        background: rgba(0, 0, 0, 0.5);
        z-index: -1;
    }
}

@media (min-width: 1024px) {
    #translateWidgetMobile {
        display: none;
    }
}

/* Sembunyikan Google's default UI */
.goog-te-banner-frame,
.skiptranslate>iframe {
    display: none !important;
}

body {
    top: 0 !important;
}

.goog-te-gadget {
    font-size: 0 !important;
    color: transparent !important;
}