/* ==========================================================================
   Website Fakultas Kedokteran — CSS Frontend

   ATURAN: jangan menulis warna tema langsung (#006633, dll.) di file ini.
   Gunakan variabel yang diisi dari Admin > Pengaturan > Tema:

   --primary-color   --primary-text     (teks di atas warna utama)
   --secondary-color --secondary-text
   --header-bg       --header-text      --header-accent (aksen yang terbaca di header)
   --footer-bg       --footer-text
   --btn-color       --btn-text
   --text-color      --body-bg          --font-family

   Warna turunan (lebih gelap/terang) dibuat dengan color-mix().
   ========================================================================== */

:root {
    --primary-dark:  color-mix(in srgb, var(--primary-color) 80%, #000);
    --primary-soft:  color-mix(in srgb, var(--primary-color) 8%, #fff);
    --btn-hover:     color-mix(in srgb, var(--btn-color) 85%, #000);
    --muted-color:   color-mix(in srgb, var(--text-color) 60%, #fff);
    --border-color:  color-mix(in srgb, var(--text-color) 12%, #fff);
    --surface-alt:   color-mix(in srgb, var(--primary-color) 4%, #f8f9fa);
    --radius:        12px;
    --shadow-sm:     0 2px 8px rgba(0, 0, 0, .06);
    --shadow-md:     0 10px 30px rgba(0, 0, 0, .10);
    --transition:    .25s ease;
}

/* --------------------------------------------------------------------------
   1. DASAR
   -------------------------------------------------------------------------- */
body {
    font-family: var(--font-family);
    color: var(--text-color);
    background-color: var(--body-bg);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 { font-weight: 600; line-height: 1.3; }

a { color: var(--primary-color); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--primary-dark); }

img { max-width: 100%; height: auto; }

.skip-link {
    position: absolute; top: 8px; left: 8px; z-index: 2000;
    padding: .5rem 1rem; border-radius: 6px;
    background: var(--primary-color); color: var(--primary-text);
}

/* Bootstrap mengikuti warna tema */
.btn-primary {
    --bs-btn-bg: var(--btn-color);
    --bs-btn-border-color: var(--btn-color);
    --bs-btn-color: var(--btn-text);
    --bs-btn-hover-bg: var(--btn-hover);
    --bs-btn-hover-border-color: var(--btn-hover);
    --bs-btn-hover-color: var(--btn-text);
    --bs-btn-active-bg: var(--btn-hover);
    --bs-btn-active-border-color: var(--btn-hover);
    --bs-btn-active-color: var(--btn-text);
    --bs-btn-focus-shadow-rgb: 0, 0, 0;
}
.btn-outline-primary {
    --bs-btn-color: var(--btn-color);
    --bs-btn-border-color: var(--btn-color);
    --bs-btn-hover-bg: var(--btn-color);
    --bs-btn-hover-border-color: var(--btn-color);
    --bs-btn-hover-color: var(--btn-text);
    --bs-btn-active-bg: var(--btn-hover);
    --bs-btn-active-color: var(--btn-text);
}
.btn-secondary-theme {
    background: var(--secondary-color); color: var(--secondary-text); border: 0;
}
.btn-secondary-theme:hover { filter: brightness(.92); color: var(--secondary-text); }
.btn { border-radius: 8px; font-weight: 500; padding: .55rem 1.25rem; }

.text-primary  { color: var(--primary-color) !important; }
.bg-primary    { background-color: var(--primary-color) !important; color: var(--primary-text); }
.text-muted    { color: var(--muted-color) !important; }

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 .2rem color-mix(in srgb, var(--primary-color) 20%, transparent);
}

.page-link { color: var(--primary-color); }
.page-item.active .page-link { background: var(--primary-color); border-color: var(--primary-color); color: var(--primary-text); }

/* --------------------------------------------------------------------------
   2. TOPBAR
   -------------------------------------------------------------------------- */
.topbar {
    background: var(--primary-dark);
    color: var(--primary-text);
    font-size: .85rem;
    padding: .45rem 0;
}
.topbar a, .topbar span { color: var(--primary-text); opacity: .9; }
.topbar a:hover { opacity: 1; }
.topbar i { margin-right: .4rem; }
.topbar-contact { display: flex; gap: 1.5rem; }
.topbar-social { display: flex; align-items: center; gap: 1rem; }
.topbar-social i { margin-right: 0; }
.topbar-univ { padding-left: 1rem; border-left: 1px solid color-mix(in srgb, var(--primary-text) 30%, transparent); }
.topbar-univ i { margin-right: .4rem; }

/* --------------------------------------------------------------------------
   3. HEADER & NAVBAR
   -------------------------------------------------------------------------- */
.site-header {
    background: var(--header-bg);
    border-bottom: 1px solid var(--border-color);
    transition: box-shadow var(--transition);
    z-index: 1030;
}
.site-header.scrolled { box-shadow: var(--shadow-md); }

.navbar { padding: .6rem 0; }
.navbar-brand { display: flex; align-items: center; gap: .75rem; margin-right: 1.5rem; white-space: normal; }
.brand-logo { height: 52px; width: auto; }
.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-title { font-weight: 700; font-size: 1.05rem; color: var(--header-accent); }
.brand-subtitle { font-size: .8rem; color: var(--header-text); opacity: .75; }

.navbar .nav-link {
    color: var(--header-text);
    font-weight: 500;
    font-size: .95rem;
    padding: .5rem .8rem !important;
    border-radius: 6px;
    white-space: nowrap;
}
.navbar .nav-link:hover,
.navbar .nav-link:focus,
.navbar .nav-link.active,
.navbar .nav-link.show { color: var(--header-accent); }
.navbar .nav-link.active { background: color-mix(in srgb, var(--header-accent) 10%, transparent); }

.dropdown-menu {
    border: 0;
    border-radius: 10px;
    box-shadow: var(--shadow-md);
    padding: .5rem;
    min-width: 230px;
    border-top: 3px solid var(--secondary-color);
}
.dropdown-item { border-radius: 6px; padding: .5rem .85rem; font-size: .92rem; }
.dropdown-item:hover, .dropdown-item:focus { background: var(--primary-soft); color: var(--primary-color); }
.dropdown-item.active, .dropdown-item:active { background: var(--primary-color); color: var(--primary-text); }

.navbar-toggler, .btn-search {
    border: 1px solid var(--border-color);
    color: var(--header-text);
    width: 42px; height: 42px;
    display: inline-flex; align-items: center; justify-content: center;
    padding: 0; border-radius: 8px; background: transparent;
}
.navbar-toggler:focus { box-shadow: none; }
.btn-search:hover, .navbar-toggler:hover { color: var(--header-accent); border-color: var(--header-accent); }

.search-bar { background: var(--surface-alt); border-top: 1px solid var(--border-color); }

/* Desktop: dropdown terbuka saat hover */
@media (min-width: 1200px) {
    .navbar .dropdown:hover > .dropdown-menu { display: block; margin-top: 0; }
    .btn-search { margin-left: .5rem; }
    .brand-title { white-space: nowrap; }
}
/* Laptop 1200–1399 px: menu dirapatkan agar 9 menu utama muat satu baris */
@media (min-width: 1200px) and (max-width: 1399.98px) {
    .navbar .nav-link { padding: .5rem .55rem !important; font-size: .9rem; }
    .navbar-brand { margin-right: .75rem; }
}

/* Mobile / tablet: menu dalam bentuk daftar */
@media (max-width: 1199.98px) {
    .navbar-collapse {
        margin-top: .75rem;
        padding-top: .75rem;
        border-top: 1px solid var(--border-color);
        max-height: 70vh;
        overflow-y: auto;
    }
    .dropdown-menu { box-shadow: none; border-top: 0; background: var(--surface-alt); }
}
@media (max-width: 575.98px) {
    .brand-logo { height: 42px; }
    .brand-title { font-size: .95rem; }
    .brand-subtitle { font-size: .72rem; }
}

/* --------------------------------------------------------------------------
   4. SECTION & JUDUL
   -------------------------------------------------------------------------- */
.section { padding: 4.5rem 0; }
.section-alt { background: var(--surface-alt); }
.section-primary { background: var(--primary-color); color: var(--primary-text); }

.section-heading { margin-bottom: 2.5rem; }
.text-center .section-title::after { margin-left: auto; margin-right: auto; }
.section-title { font-size: 1.85rem; font-weight: 700; margin-bottom: .5rem; }
.section-title::after {
    content: ''; display: block;
    width: 60px; height: 4px; margin-top: .75rem;
    background: var(--secondary-color); border-radius: 4px;
}
.section-subtitle { color: var(--muted-color); margin: .75rem 0 0; }
.section-primary .section-subtitle { color: var(--primary-text); opacity: .85; }

.section-heading-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; flex-wrap: wrap; }

.eyebrow {
    display: inline-block;
    font-size: .8rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
    color: var(--primary-color);
    margin-bottom: .5rem;
}

@media (max-width: 767.98px) {
    .section { padding: 3rem 0; }
    .section-title { font-size: 1.5rem; }
}

/* --------------------------------------------------------------------------
   5. HERO / SLIDER
   -------------------------------------------------------------------------- */
.hero .carousel-item { height: clamp(380px, 72vh, 640px); background: var(--primary-dark); }
.hero-image { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-fallback {
    position: absolute; inset: 0;
    background:
        radial-gradient(circle at 80% 20%, color-mix(in srgb, var(--secondary-color) 35%, transparent), transparent 45%),
        linear-gradient(135deg, var(--primary-color), var(--primary-dark));
}
.hero .carousel-item::after {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(90deg, rgba(0,0,0,.65) 0%, rgba(0,0,0,.25) 60%, rgba(0,0,0,.05) 100%);
}
.hero-caption {
    position: relative; z-index: 2; height: 100%;
    display: flex; align-items: center;
    color: #fff;
}
.hero-caption h2 { font-size: clamp(1.75rem, 4vw, 3rem); font-weight: 700; max-width: 720px; }
.hero-caption p  { font-size: clamp(1rem, 1.6vw, 1.25rem); max-width: 620px; opacity: .92; margin: 1rem 0 1.75rem; }
.hero .carousel-indicators [data-bs-target] { width: 28px; height: 4px; border-radius: 2px; }

/* Ponsel: panah disembunyikan agar tidak menutupi teks (geser/indikator tetap berfungsi) */
@media (max-width: 767.98px) {
    .hero .carousel-control-prev, .hero .carousel-control-next { display: none; }
}

/* --------------------------------------------------------------------------
   6. KARTU UMUM
   -------------------------------------------------------------------------- */
.card-item {
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    overflow: hidden;
    height: 100%;
    background: #fff;
    transition: transform var(--transition), box-shadow var(--transition);
}
.card-item:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.card-item .card-img-top { aspect-ratio: 16 / 10; object-fit: cover; }
.card-item .card-body { padding: 1.25rem; }
.card-item .card-title { font-size: 1.05rem; margin-bottom: .5rem; }
.card-item .card-title a { color: var(--text-color); }
.card-item .card-title a:hover { color: var(--primary-color); }
.card-meta { font-size: .82rem; color: var(--muted-color); display: flex; flex-wrap: wrap; gap: .25rem 1rem; margin-bottom: .5rem; }
.card-meta i { margin-right: .3rem; }
.card-text-muted { color: var(--muted-color); font-size: .92rem; }

.badge-theme {
    background: var(--primary-soft); color: var(--primary-color);
    font-weight: 600; font-size: .75rem; padding: .35em .75em; border-radius: 50px;
}

.link-more { font-weight: 600; font-size: .92rem; }
.link-more i { margin-left: .35rem; transition: transform var(--transition); }
.link-more:hover i { transform: translateX(4px); }

.min-w-0 { min-width: 0; }

.line-clamp-2, .line-clamp-3 { display: -webkit-box; -webkit-box-orient: vertical; overflow: hidden; }
.line-clamp-2 { -webkit-line-clamp: 2; }
.line-clamp-3 { -webkit-line-clamp: 3; }

/* --------------------------------------------------------------------------
   7. SECTION KHUSUS HOMEPAGE
   -------------------------------------------------------------------------- */
/* Tentang & sambutan */
.about-image, .sambutan-image {
    border-radius: var(--radius); width: 100%; object-fit: cover; box-shadow: var(--shadow-md);
}
.about-image { aspect-ratio: 4 / 3; }
.sambutan-image { aspect-ratio: 3 / 4; max-width: 340px; }
@media (max-width: 991.98px) {
    .sambutan-image { max-width: 240px; }
}
.sambutan-quote { font-size: 1.05rem; position: relative; padding-left: 1.5rem; border-left: 4px solid var(--secondary-color); }

/* Statistik */
.stat-item { text-align: center; padding: 1rem; }
.stat-icon { font-size: 2rem; color: var(--secondary-color); margin-bottom: .5rem; }
.stat-number { font-size: 2.25rem; font-weight: 700; line-height: 1.1; }
.stat-label { opacity: .85; font-size: .95rem; }

/* Program studi */
.prodi-card { padding: 1.75rem; }
.prodi-icon {
    width: 56px; height: 56px; border-radius: 12px;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--primary-soft); color: var(--primary-color); font-size: 1.5rem; margin-bottom: 1rem;
}

/* Daftar pengumuman */
.list-item {
    display: flex; gap: 1rem; align-items: flex-start;
    padding: 1rem 0; border-bottom: 1px dashed var(--border-color);
}
.list-item:last-child { border-bottom: 0; }
.list-item-icon {
    flex-shrink: 0; width: 44px; height: 44px; border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    background: var(--primary-soft); color: var(--primary-color);
}
.list-item-title { font-weight: 600; color: var(--text-color); display: block; margin-bottom: .15rem; }
.list-item-title:hover { color: var(--primary-color); }

/* Agenda */
.agenda-date {
    flex-shrink: 0; width: 64px; text-align: center;
    border-radius: 10px; overflow: hidden; border: 1px solid var(--border-color); background: #fff;
}
.agenda-date .day { display: block; font-size: 1.5rem; font-weight: 700; color: var(--primary-color); padding-top: .35rem; line-height: 1.1; }
.agenda-date .month { display: block; font-size: .75rem; font-weight: 600; text-transform: uppercase; padding: .15rem 0 .35rem; }

/* Dosen */
.dosen-card { text-align: center; padding: 1.5rem 1rem; }
.dosen-photo {
    width: 120px; height: 120px; border-radius: 50%; object-fit: cover;
    border: 4px solid var(--primary-soft); margin-bottom: 1rem;
}
.dosen-name { font-size: 1rem; font-weight: 600; margin-bottom: .25rem; }

/* Galeri */
.album-card { position: relative; display: block; border-radius: var(--radius); overflow: hidden; aspect-ratio: 4 / 3; }
.album-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.album-card:hover img { transform: scale(1.06); }
.album-card .album-caption {
    position: absolute; inset: auto 0 0 0; padding: 1rem;
    background: linear-gradient(transparent, rgba(0,0,0,.75)); color: #fff;
}
.album-caption h3 { font-size: 1rem; margin: 0; }
.album-caption small { opacity: .85; }

/* Link penting */
.quick-link {
    display: flex; align-items: center; gap: .85rem;
    padding: 1rem 1.25rem; border-radius: var(--radius);
    background: #fff; border: 1px solid var(--border-color); color: var(--text-color); font-weight: 500; height: 100%;
    transition: all var(--transition);
}
.quick-link i { font-size: 1.35rem; color: var(--primary-color); width: 28px; text-align: center; }
.quick-link:hover { border-color: var(--primary-color); color: var(--primary-color); box-shadow: var(--shadow-sm); }

/* Kontak */
.contact-item { display: flex; gap: 1rem; margin-bottom: 1.25rem; }
.contact-item i {
    flex-shrink: 0; width: 44px; height: 44px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: var(--primary-color); color: var(--primary-text);
}
.map-frame { width: 100%; min-height: 320px; height: 100%; border: 0; border-radius: var(--radius); }

.empty-state { text-align: center; color: var(--muted-color); padding: 2rem 1rem; }
.empty-state i { font-size: 2.5rem; margin-bottom: .75rem; opacity: .5; }

/* --------------------------------------------------------------------------
   8. HALAMAN DALAM
   -------------------------------------------------------------------------- */
.page-header {
    background:
        linear-gradient(135deg, color-mix(in srgb, var(--primary-color) 92%, transparent), var(--primary-dark));
    color: var(--primary-text);
    padding: 2.5rem 0 2.25rem;
}
.page-title { font-size: clamp(1.6rem, 3vw, 2.25rem); font-weight: 700; margin: .25rem 0 0; }
.page-subtitle { margin: .5rem 0 0; opacity: .85; }
.page-header .breadcrumb { margin: 0; font-size: .88rem; --bs-breadcrumb-divider-color: var(--primary-text); }
.page-header .breadcrumb a, .page-header .breadcrumb-item.active { color: var(--primary-text); opacity: .85; }
.page-header .breadcrumb a:hover { opacity: 1; }

/* Isi konten dari editor (halaman, berita) */
.content-body { font-size: 1.02rem; overflow-wrap: break-word; }
.content-body img { border-radius: 8px; margin: .5rem 0; }
.content-body table { width: 100%; margin-bottom: 1rem; border-collapse: collapse; }
.content-body table td, .content-body table th { border: 1px solid var(--border-color); padding: .5rem .75rem; }
.content-body blockquote { border-left: 4px solid var(--secondary-color); padding-left: 1rem; color: var(--muted-color); }
.content-body a { text-decoration: underline; }
.content-body .text-justify { text-align: justify; }
.content-body h2, .content-body h3, .content-body h4 { margin-top: 1.75rem; margin-bottom: .75rem; }
.content-body::after { content: ''; display: table; clear: both; }
.content-body > :first-child { margin-top: 0; }

.page-image { width: 100%; max-height: 520px; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.page-portrait {
    float: right; width: 240px; max-width: 45%; margin: 0 0 1rem 1.5rem;
    border-radius: var(--radius); box-shadow: var(--shadow-md);
}
@media (max-width: 575.98px) {
    .page-portrait { float: none; display: block; margin: 0 auto 1.25rem; max-width: 70%; }
}

/* Sidebar halaman dalam */
.sidebar-box { border: 1px solid var(--border-color); border-radius: var(--radius); padding: 1.25rem; background: #fff; }
.sidebar-title { font-size: 1.05rem; font-weight: 700; margin-bottom: 1rem; padding-bottom: .6rem; border-bottom: 3px solid var(--secondary-color); display: inline-block; }
.sidebar-nav { list-style: none; padding: 0; margin: 0; }
.sidebar-nav a {
    display: flex; align-items: center; gap: .6rem;
    padding: .55rem .75rem; border-radius: 8px; color: var(--text-color); font-size: .95rem;
}
.sidebar-nav a i { font-size: .65rem; opacity: .5; }
.sidebar-nav a:hover { background: var(--primary-soft); color: var(--primary-color); }
.sidebar-nav a.active { background: var(--primary-color); color: var(--primary-text); font-weight: 600; }
.sidebar-nav a.active i { opacity: 1; }

.attachment-link {
    display: flex; align-items: center; gap: .9rem; padding: .85rem 1rem;
    border: 1px dashed var(--border-color); border-radius: 10px; color: var(--text-color);
}
.attachment-link i { font-size: 1.75rem; color: var(--primary-color); }
/* Grid foto album (lab, RS, pengabdian, galeri) */
.photo-item { position: relative; display: block; aspect-ratio: 4 / 3; border-radius: 10px; overflow: hidden; background: var(--surface-alt); }
.photo-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.photo-item:hover img { transform: scale(1.05); }
.photo-caption { font-size: .82rem; color: var(--muted-color); padding: .35rem .15rem 0; line-height: 1.4; }
.lightbox-modal { --bs-modal-bg: transparent; background: rgba(0, 0, 0, .88); }
.lightbox-modal img { max-height: 80vh; }
.lightbox-nav {
    position: absolute; top: 50%; transform: translateY(-50%);
    width: 44px; height: 44px; border-radius: 50%; border: 0;
    background: rgba(0, 0, 0, .55); color: #fff;
}
.lightbox-nav:hover { background: var(--primary-color); color: var(--primary-text); }
.lightbox-nav.prev { left: .5rem; }
.lightbox-nav.next { right: .5rem; }
.photo-item .play-icon {
    position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
    font-size: 3rem; color: #fff; background: rgba(0, 0, 0, .25); text-shadow: 0 2px 8px rgba(0, 0, 0, .4);
}

/* Pencarian */
.search-result { padding: .9rem 0; border-bottom: 1px dashed var(--border-color); }
.search-title { font-weight: 600; font-size: 1.05rem; }
.search-url { font-size: .8rem; color: #198754; margin-bottom: .25rem; word-break: break-all; }

/* Agenda */
.agenda-row { display: flex; gap: 1.25rem; padding: 1.25rem 0; border-bottom: 1px solid var(--border-color); }
.agenda-row:first-child { padding-top: 0; }
.agenda-row.is-past .agenda-date { filter: grayscale(1); opacity: .7; }
.agenda-row h2 a:hover { color: var(--primary-color) !important; }
.agenda-date-sm { width: 52px; }
.agenda-date-sm .day { font-size: 1.15rem; }
.agenda-date-sm .month { font-size: .65rem; }

/* Download */
.download-item { display: flex; align-items: center; gap: 1rem; padding: 1rem 0; border-bottom: 1px solid var(--border-color); }
.download-item:first-child { padding-top: 0; }
.download-icon { font-size: 2rem; color: var(--primary-color); width: 40px; text-align: center; flex-shrink: 0; }

/* FAQ */
.faq-accordion .accordion-button { font-weight: 600; }
.faq-accordion .accordion-button:not(.collapsed) { background: var(--primary-soft); color: var(--primary-color); box-shadow: none; }
.faq-accordion .accordion-button:focus { box-shadow: 0 0 0 .2rem color-mix(in srgb, var(--primary-color) 20%, transparent); }

/* Honeypot form kontak: disembunyikan dari pengunjung, tetap ada untuk bot */
.hp-field { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* Penelitian & publikasi */
.research-item { padding: 1.25rem 0; border-bottom: 1px solid var(--border-color); }
.research-item:first-child { padding-top: 0; }
.research-item h2 a:hover { color: var(--primary-color) !important; }
.publication-list { padding-left: 1.5rem; }
.publication-list li { padding: .6rem 0 .6rem .25rem; border-bottom: 1px dashed var(--border-color); line-height: 1.6; }
.pub-authors { font-weight: 600; }
.pub-title { color: var(--text-color); }
.pub-links { display: inline-flex; gap: .85rem; margin-left: .5rem; font-size: .88rem; }
.journal-card { display: flex; flex-direction: row; }
.journal-cover { width: 140px; flex-shrink: 0; object-fit: cover; background: var(--surface-alt); }
@media (max-width: 575.98px) {
    .journal-card { flex-direction: column; }
    .journal-cover { width: 100%; height: 220px; }
}

/* Dosen */
.filter-bar { background: var(--surface-alt); border: 1px solid var(--border-color); border-radius: var(--radius); padding: 1rem; }
.profile-photo { width: 200px; height: 250px; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow-md); max-width: 100%; }
.timeline { list-style: none; padding: 0 0 0 1.25rem; margin: 0; border-left: 3px solid var(--primary-soft); }
.timeline li { position: relative; padding: 0 0 1rem .75rem; }
.timeline li::before {
    content: ''; position: absolute; left: -1.72rem; top: .45rem;
    width: 12px; height: 12px; border-radius: 50%; background: var(--primary-color); border: 3px solid #fff;
}
.timeline li:last-child { padding-bottom: 0; }
@media (min-width: 992px) {
    .profile-card { position: sticky; top: 110px; }
}

/* Program studi */
.prodi-tabs { gap: .5rem; flex-wrap: wrap; }
.prodi-tabs .nav-link { border: 1px solid var(--border-color); color: var(--text-color); border-radius: 50px; padding: .45rem 1rem; font-size: .92rem; }
.prodi-tabs .nav-link:hover { border-color: var(--primary-color); color: var(--primary-color); }
.prodi-tabs .nav-link.active { background: var(--primary-color); border-color: var(--primary-color); color: var(--primary-text); }
.visi-box { font-size: 1.1rem; font-style: italic; background: var(--primary-soft); padding: 1rem 1.25rem; border-radius: 0 10px 10px 0; color: var(--text-color) !important; }
.info-list dt { font-size: .8rem; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; color: var(--muted-color); }
.info-list dd { margin-bottom: .85rem; }
.info-list dd:last-child { margin-bottom: 0; }

/* Berita */
.post-meta { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1.25rem; font-size: .9rem; color: var(--muted-color); }
.post-meta i { margin-right: .35rem; }

.share-box { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; padding-top: 1.25rem; border-top: 1px solid var(--border-color); }
.share-btn {
    width: 38px; height: 38px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--primary-soft); color: var(--primary-color);
}
.share-btn:hover { background: var(--primary-color); color: var(--primary-text); }

.popular-item { display: flex; gap: .75rem; padding: .65rem 0; border-bottom: 1px dashed var(--border-color); color: var(--text-color); }
.popular-item:last-child { border-bottom: 0; }
.popular-item img { width: 72px; height: 54px; object-fit: cover; border-radius: 8px; flex-shrink: 0; }
.popular-title { font-weight: 600; font-size: .9rem; line-height: 1.4; }
.popular-item:hover .popular-title { color: var(--primary-color); }

.attachment-link:hover { border-color: var(--primary-color); background: var(--primary-soft); color: var(--text-color); }

.error-page { max-width: 560px; margin: 0 auto; }
.error-code {
    font-size: clamp(5rem, 15vw, 8rem); font-weight: 800; line-height: 1;
    color: var(--primary-color); opacity: .15; margin-bottom: 1rem;
}
.error-search { max-width: 420px; margin: 0 auto; }

/* --------------------------------------------------------------------------
   9. FOOTER
   -------------------------------------------------------------------------- */
.site-footer {
    background: var(--footer-bg);
    color: var(--footer-text);
    padding-top: 4rem;
    font-size: .93rem;
}
.site-footer a { color: var(--footer-text); opacity: .85; }
.site-footer a:hover { opacity: 1; color: var(--footer-text); }

.footer-brand { display: flex; align-items: center; gap: .75rem; margin-bottom: 1rem; font-weight: 600; font-size: 1.05rem; opacity: 1 !important; }
.footer-brand img { height: 56px; width: auto; }
.footer-tagline {
    font-style: italic; margin-bottom: .75rem; padding-left: .75rem;
    border-left: 3px solid var(--secondary-color);
}
.footer-text { opacity: .8; }

.footer-title {
    font-size: 1.05rem; font-weight: 600; margin-bottom: 1.25rem; padding-bottom: .6rem; position: relative;
}
.footer-title::after {
    content: ''; position: absolute; left: 0; bottom: 0; width: 40px; height: 3px;
    background: var(--secondary-color); border-radius: 3px;
}
.footer-links, .footer-contact { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: .6rem; }
.footer-links i { font-size: .7rem; margin-right: .5rem; opacity: .7; }
.footer-contact li { display: flex; gap: .75rem; margin-bottom: .85rem; }
.footer-contact i { margin-top: .3rem; width: 16px; text-align: center; color: var(--secondary-color); }

.footer-social { display: flex; gap: .5rem; margin-top: 1rem; }
.footer-social a {
    width: 38px; height: 38px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    background: color-mix(in srgb, var(--footer-text) 12%, transparent);
    transition: background var(--transition);
}
.footer-social a:hover { background: var(--secondary-color); color: var(--secondary-text); }

.footer-bottom {
    margin-top: 3rem; padding: 1.25rem 0;
    border-top: 1px solid color-mix(in srgb, var(--footer-text) 15%, transparent);
    font-size: .85rem; opacity: .85;
}

/* --------------------------------------------------------------------------
   10. TOMBOL KEMBALI KE ATAS
   -------------------------------------------------------------------------- */
.back-to-top {
    position: fixed; right: 20px; bottom: 20px; z-index: 1040;
    width: 44px; height: 44px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: var(--primary-color); color: var(--primary-text);
    box-shadow: var(--shadow-md);
    opacity: 0; visibility: hidden; transform: translateY(10px);
    transition: all var(--transition);
}
.back-to-top.show { opacity: 1; visibility: visible; transform: none; }
.back-to-top:hover { color: var(--primary-text); background: var(--primary-dark); }

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
