/* ============================================================
   Blog Pribadi — Frontend Styles (Bootstrap 5 + custom)
   ============================================================ */
:root {
    --bs-primary: #4f46e5;
    --brand-grad: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    overflow-x: hidden;
}

a { transition: color .15s ease; }

/* ---------- Navbar ---------- */
.navbar { backdrop-filter: blur(8px); }
.navbar .nav-link { font-weight: 500; position: relative; }
.navbar .nav-link.active { color: var(--bs-primary) !important; }
.navbar .nav-link.active::after {
    content: ''; position: absolute; bottom: 2px; left: 12px; right: 12px;
    height: 2px; background: var(--bs-primary); border-radius: 2px;
}

/* ---------- Hero ---------- */
.hero-banner {
    background: var(--brand-grad);
    overflow: hidden;
}
.hero-banner::after {
    content: ''; position: absolute; inset: 0;
    background: radial-gradient(circle at 80% 20%, rgba(255,255,255,.15), transparent 50%);
    pointer-events: none;
}
.hero-photo { width: 280px; height: 280px; object-fit: cover; border: 6px solid rgba(255,255,255,.3); }
.opacity-90 { opacity: .9; }

/* ---------- Cards & thumbnails ---------- */
.post-card, .video-card, .post-list-card { transition: transform .2s ease, box-shadow .2s ease; }
.post-card:hover, .video-card:hover, .post-list-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 .8rem 1.5rem rgba(0,0,0,.12) !important;
}
.post-thumb { height: 200px; object-fit: cover; }
.post-thumb-sm { height: 130px; object-fit: cover; }
.post-list-thumb { width: 100%; height: 100%; min-height: 180px; object-fit: cover; }
.popular-thumb { width: 64px; height: 64px; object-fit: cover; }

/* ---------- Video overlay ---------- */
.video-play-overlay {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    font-size: 3rem; color: rgba(255,255,255,.9); text-shadow: 0 2px 12px rgba(0,0,0,.5);
    transition: transform .2s ease;
}
.video-card:hover .video-play-overlay { transform: translate(-50%, -50%) scale(1.15); }

/* ---------- Content (artikel) ---------- */
.content-html img { max-width: 100%; height: auto; border-radius: .5rem; margin: 1rem 0; }
.content-html h2, .content-html h3 { margin-top: 1.5rem; font-weight: 700; }
.content-html p { margin-bottom: 1rem; }
.content-html iframe { max-width: 100%; border-radius: .5rem; }
.content-html blockquote {
    border-left: 4px solid var(--bs-primary); padding-left: 1rem; color: var(--bs-secondary-color);
}

/* ---------- About timeline ---------- */
.about-photo { width: 160px; height: 160px; object-fit: cover; }
.timeline { position: relative; padding-left: 1.5rem; }
.timeline::before {
    content: ''; position: absolute; left: 5px; top: 5px; bottom: 5px;
    width: 2px; background: var(--bs-border-color);
}
.timeline-item { position: relative; margin-bottom: 1.2rem; }
.timeline-item::before {
    content: ''; position: absolute; left: -1.5rem; top: 4px;
    width: 12px; height: 12px; border-radius: 50%; background: var(--bs-primary);
    box-shadow: 0 0 0 3px var(--bs-body-bg);
}

/* ---------- Gallery ---------- */
.gallery-item img { transition: transform .3s ease; aspect-ratio: 1; object-fit: cover; }
.gallery-item:hover img { transform: scale(1.05); }

/* ---------- Footer ---------- */
.footer-pro h5, .footer-pro h6 { color: var(--bs-emphasis-color); }

/* ---------- Back to top ---------- */
#backToTop {
    position: fixed; bottom: 24px; right: 24px; width: 46px; height: 46px;
    display: none; z-index: 1030; padding: 0;
}
#backToTop.show { display: inline-flex; align-items: center; justify-content: center; }

/* ---------- Dark mode tweaks ---------- */
[data-bs-theme="dark"] {
    --bs-primary: #6366f1;
}
[data-bs-theme="dark"] .hero-banner { background: linear-gradient(135deg, #312e81 0%, #4c1d95 100%); }
