/* ===================================================================
   SINGLE POST STYLES - REVISI PADDING
=================================================================== */

:root {
    --sp-primary: #775ba3;
    --sp-dark: #2d2d2d;
    --sp-light: #f8f9fa;
    --sp-text: #4a4a4a;
    --sp-border: #eaeaea;
    --sp-radius: 16px;
    --sp-shadow: 0 10px 40px rgba(0,0,0,0.06);
}

/* --- [BARU] Container Layout Fix --- */
/* Class ini memastikan konten tidak menempel ke pinggir layar */
.container-artikel {
    width: 90%;             /* Menggunakan 90% lebar layar */
    max-width: 1200px;      /* Batas maksimal lebar agar tidak terlalu panjang di monitor besar */
    margin-left: auto;      /* Auto margin kiri-kanan agar posisi Center */
    margin-right: auto;
    padding-left: 20px;     /* Jarak aman (padding) kiri */
    padding-right: 20px;    /* Jarak aman (padding) kanan */
    box-sizing: border-box;
}

/* Reading Progress Bar */
.reading-progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 4px;
    background: var(--sp-primary);
    z-index: 99999;
    transition: width 0.1s ease;
}

/* --- 1. Header Section --- */
.single-header-modern {
    padding: 140px 0 40px;
    text-align: center;
    background: linear-gradient(to bottom, #fdfbfd 0%, #ffffff 100%);
    border-bottom: 1px solid #f0f0f0; /* Tambahan garis tipis pemisah */
}

.single-badges {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-bottom: 25px;
}

.cat-badge {
    background-color: rgba(119, 91, 163, 0.1);
    color: var(--sp-primary);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.date-badge {
    color: #888;
    font-size: 0.85rem;
    font-weight: 500;
}

.single-title {
    font-size: clamp(2rem, 5vw, 3.2rem); /* Ukuran font responsif */
    font-weight: 800;
    color: var(--sp-dark);
    line-height: 1.3;
    margin-bottom: 30px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    letter-spacing: -1px;
}

.single-meta {
    display: inline-flex;
    align-items: center;
    gap: 20px;
    background: white;
    padding: 10px 25px;
    border-radius: 50px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
    border: 1px solid #eee;
}

.author-info {
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: left;
}

.author-info img {
    border-radius: 50%;
    width: 40px;
    height: 40px;
    object-fit: cover;
}

.author-text {
    display: flex;
    flex-direction: column;
    font-size: 0.85rem;
    line-height: 1.2;
}

.author-text .muted { color: #999; font-size: 0.75rem; }
.author-text strong { color: var(--sp-dark); }

.meta-divider {
    width: 1px;
    height: 25px;
    background: #eee;
}

.read-time {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #666;
    font-size: 0.85rem;
    font-weight: 600;
}
.read-time svg { stroke: #888; }


/* --- 2. Featured Image --- */
.single-featured-image-wrapper {
    position: relative;
    margin-bottom: -60px;
    z-index: 2;
    padding-top: 40px; /* Jarak dari header */
}

.single-featured-image {
    width: 100%;
    height: auto;
    max-height: 550px;
    object-fit: cover;
    border-radius: var(--sp-radius);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}


/* --- 3. Main Layout & Content --- */
.single-container {
    display: grid;
    grid-template-columns: 1fr 340px; /* Layout 2 Kolom: Konten | Sidebar */
    gap: 60px;
    margin-top: 100px;
    margin-bottom: 80px;
}

/* Pastikan breadcrumb punya jarak */
.single-breadcrumb {
    margin-bottom: 30px;
    font-size: 0.9rem;
    color: #999;
    font-weight: 500;
}
.single-breadcrumb a { text-decoration: none; color: var(--sp-primary); transition: 0.2s; }
.single-breadcrumb a:hover { text-decoration: underline; }
.single-breadcrumb .sep { margin: 0 5px; color: #ccc; }


/* Typography Article Content */
.entry-content {
    font-size: 1.15rem;
    line-height: 1.9;
    color: var(--sp-text);
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

/* Drop Cap untuk paragraf pertama */
.entry-content > p:first-of-type::first-letter {
    font-size: 3.5rem;
    font-weight: 800;
    float: left;
    line-height: 0.8;
    padding-right: 12px;
    margin-top: 5px;
    color: var(--sp-primary);
}

.entry-content h2, 
.entry-content h3, 
.entry-content h4 {
    color: var(--sp-dark);
    margin-top: 50px;
    margin-bottom: 25px;
    font-weight: 800;
    line-height: 1.3;
}
.entry-content h2 { font-size: 1.8rem; letter-spacing: -0.5px; }
.entry-content h3 { font-size: 1.5rem; }

.entry-content p { margin-bottom: 25px; }

.entry-content blockquote {
    border-left: none;
    background: #fdfdfd;
    padding: 30px 40px;
    margin: 40px 0;
    font-style: italic;
    color: #333;
    border-radius: 12px;
    border: 1px solid #eee;
    position: relative;
    box-shadow: 0 5px 15px rgba(0,0,0,0.02);
}
.entry-content blockquote::before {
    content: '"';
    font-size: 4rem;
    color: rgba(119, 91, 163, 0.1);
    position: absolute;
    top: -10px;
    left: 10px;
    font-family: serif;
}

.entry-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 30px 0;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

/* Tags Modern */
.single-tags {
    margin-top: 60px;
    padding-top: 30px;
    border-top: 1px solid var(--sp-border);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}
.tags-label { font-weight: 700; color: var(--sp-dark); font-size: 0.95rem; margin-right: 5px; }
.single-tags a {
    background: #fff;
    border: 1px solid #ddd;
    color: #666;
    padding: 6px 14px;
    border-radius: 50px;
    text-decoration: none;
    font-size: 0.85rem;
    transition: 0.3s;
}
.single-tags a:hover {
    background: var(--sp-primary);
    border-color: var(--sp-primary);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(119, 91, 163, 0.3);
}

/* Author Box */
.single-author-box {
    display: flex;
    gap: 30px;
    background: #fff;
    padding: 40px;
    border-radius: var(--sp-radius);
    margin-top: 50px;
    align-items: center;
    border: 1px solid var(--sp-border);
    box-shadow: var(--sp-shadow);
}
.author-avatar-large img {
    border-radius: 50%;
    width: 100px;
    height: 100px;
    object-fit: cover;
    border: 4px solid #f0f0f0;
}
.author-desc .author-role {
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--sp-primary);
    font-weight: 700;
    margin-bottom: 5px;
}
.author-desc h4 { margin: 0 0 10px 0; font-size: 1.4rem; color: var(--sp-dark); }
.author-desc p { margin: 0; font-size: 1rem; color: #666; line-height: 1.6; }


/* Navigation Links */
.single-navigation {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 40px;
}
.nav-box {
    padding: 20px;
    border: 1px solid #eee;
    border-radius: 12px;
    transition: 0.3s;
    background: #fff;
}
.nav-box:hover {
    border-color: var(--sp-primary);
    transform: translateY(-3px);
}
.nav-label { display: block; font-size: 0.8rem; color: #999; margin-bottom: 5px; }
.nav-box a {
    text-decoration: none;
    font-weight: 700;
    color: var(--sp-dark);
    font-size: 1rem;
    line-height: 1.4;
    display: block;
}
.nav-next { text-align: right; }


/* --- 4. Sidebar Styles (Sticky) --- */
.single-sidebar {
    position: relative;
}
.sidebar-sticky-wrapper {
    position: sticky;
    top: 100px; /* Menempel saat discroll */
}

.sidebar-widget-artikel {
    margin-bottom: 40px;
}

.widget-title-artikel {
    font-size: 1.1rem;
    font-weight: 800;
    margin-bottom: 25px;
    color: var(--sp-dark);
    display: flex;
    align-items: center;
    gap: 10px;
}
.highlight-line {
    width: 4px;
    height: 18px;
    background: var(--sp-primary);
    border-radius: 2px;
    display: inline-block;
}

/* Sidebar Cards */
.related-card {
    display: block;
    text-decoration: none;
    margin-bottom: 20px;
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    transition: 0.3s;
    border: 1px solid transparent;
}
.related-card:hover {
    background: #fff;
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
    transform: translateY(-3px);
}
.related-thumb img {
    width: 100%;
    height: 160px;
    object-fit: cover;
    border-radius: 10px;
}
.related-info { padding: 12px 5px; }
.related-cat {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--sp-primary);
    text-transform: uppercase;
}
.related-title {
    font-size: 1rem;
    margin: 5px 0 0;
    color: var(--sp-dark);
    line-height: 1.4;
}

/* --- Responsive Fix --- */
@media (max-width: 992px) {
    .single-container {
        grid-template-columns: 1fr; /* Stack 1 kolom di tablet */
        gap: 40px;
    }
    .single-header-modern {
        padding-top: 100px;
    }
    .single-featured-image {
        max-height: 400px;
    }
    .single-container {
        margin-top: 40px;
    }
    .single-author-box {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 768px) {
    /* Padding ekstra untuk mobile agar tulisan tidak mepet layar HP */
    .container-artikel {
        width: 100%;
        padding-left: 20px;
        padding-right: 20px;
    }

    .single-title { font-size: 1.8rem; }
    .single-meta {
        flex-direction: column;
        gap: 10px;
        padding: 15px;
        border-radius: 15px;
    }
    .meta-divider { display: none; }
}

/* Dark Mode Support */
html.dark-mode .single-header-modern { background: #1a1822; }
html.dark-mode .single-title { color: #f0f0f0; }
html.dark-mode .single-meta,
html.dark-mode .nav-box,
html.dark-mode .single-author-box,
html.dark-mode .related-card {
    background: #2a2734;
    border-color: #444;
}
html.dark-mode .entry-content { color: #d0d0d0; }
html.dark-mode .entry-content h2, 
html.dark-mode .entry-content h3,
html.dark-mode .author-desc h4,
html.dark-mode .author-info strong,
html.dark-mode .widget-title-artikel,
html.dark-mode .related-title,
html.dark-mode .nav-box a { 
    color: #fff; 
}
html.dark-mode .entry-content blockquote {
    background: #23212d;
    border-color: #444;
    color: #bbb;
}
html.dark-mode .single-tags a {
    background: #333;
    border-color: #444;
    color: #ccc;
}

/* ===================================================================
   #. MINOL
=================================================================== */
.whatsapp-chat-button {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 9999;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.whatsapp-chat-button img {
    width: 120px; /* Ukuran default untuk desktop */
    height: auto;
    /*border-radius: 50%;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2); */
}

.whatsapp-chat-button:hover {
    transform: scale(1.1);
    /* box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3); */
}

/* Responsif untuk tampilan mobile */
@media (max-width: 768px) {
    .whatsapp-chat-button {
        right: 15px;
        bottom: 25px;
    }
    .whatsapp-chat-button img {
        width: 50px; /* Ukuran yang lebih kecil untuk mobile */
    }
}