:root {
    --primary: #0f4c81;
    --primary-dark: #0b3961;
    --accent: #1f9d8f;
    --danger: #c0392b;
    --bg-dark: #061524;
    --card: rgba(255, 255, 255, 0.96);
    --glass: rgba(255, 255, 255, 0.10);
    --glass-border: rgba(255, 255, 255, 0.18);
    --text: #1d2733;
    --muted: #64748b;
    --border: #d9e2ec;
    --shadow: 0 14px 40px rgba(0, 0, 0, 0.18);
    --radius: 16px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    height: 100%;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    color: #e6eef8;
    line-height: 1.55;
    background-color: #04101c;
    background-image:
        radial-gradient(circle at top left, rgba(31, 157, 143, 0.22), transparent 30%),
        radial-gradient(circle at top right, rgba(15, 76, 129, 0.35), transparent 35%),
        linear-gradient(180deg, #081b2e 0%, #061524 45%, #04101c 100%);
    background-attachment: fixed;
    background-repeat: no-repeat;
    min-height: 100vh;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
}

a {
    color: var(--primary);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.container {
    width: min(1200px, 92%);
    margin: 0 auto;
}

#particleCanvas {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

.site-header,
main.container,
.site-footer,
.container > .alert,
.home-layout,
.paper-back {
    position: relative;
    z-index: 1;
}

/* =========================================================
HEADER / NAVBAR
========================================================= */
.site-header {
    background: rgba(8, 27, 46, 0.88);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    color: #fff;
    padding: 12px 0;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
    flex: 0 0 auto;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #fff;
    font-weight: bold;
    text-decoration: none;
}

.brand:hover {
    text-decoration: none;
}

.brand-logo {
    height: 42px;
    width: auto;
    object-fit: contain;
    background: transparent !important;
    padding: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}

.brand-logo.monochrome-white {
    filter: invert(1);
    mix-blend-mode: screen;
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.brand-text small {
    font-size: 0.78rem;
    font-weight: normal;
    opacity: 0.85;
}

.main-nav {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

.main-nav a {
    color: #fff;
    font-size: 0.95rem;
    opacity: 0.92;
}

.main-nav a:hover {
    opacity: 1;
    text-decoration: underline;
}

main.container {
    flex: 1 0 auto;
    width: min(1200px, 92%);
    margin: 0 auto;
    padding: 24px 0 48px;
}

/* =========================================================
ALERT
========================================================= */
.alert {
    padding: 12px 14px;
    border-radius: 12px;
    margin: 16px 0;
    backdrop-filter: blur(10px);
}

.alert.success {
    background: rgba(210, 255, 233, 0.95);
    color: #145a32;
    border: 1px solid rgba(169, 223, 191, 0.9);
}

.alert.error {
    background: rgba(255, 226, 221, 0.95);
    color: #922b21;
    border: 1px solid rgba(245, 183, 177, 0.9);
}

.alert ul {
    margin: 0;
    padding-left: 18px;
}

/* =========================================================
HERO / HALAMAN DEPAN
========================================================= */
.hero {
    position: relative;
    z-index: 1;
    background: linear-gradient(
        180deg,
        rgba(8, 27, 46, 0.42) 0%,
        rgba(6, 21, 36, 0.28) 100%
    );
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 22px;
    padding: 30px 26px;
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.18);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    margin-bottom: 22px;
    text-align: center;
    color: #fff;
}

.hero h1 {
    margin: 0 0 10px;
    color: #fff;
    font-size: clamp(1.5rem, 3vw, 2.2rem);
    letter-spacing: 0.2px;
}

.hero p {
    max-width: 780px;
    margin: 0 auto;
    color: rgba(255, 255, 255, 0.82);
    font-size: 1rem;
}

.section-title {
    position: relative;
    z-index: 1;
    margin: 4px 0 16px;
    color: #fff;
    font-size: 1.25rem;
}

.search-form {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 20px;
}

.search-form input[type="search"] {
    flex: 1;
    min-width: 260px;
    max-width: 620px;
    padding: 13px 15px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 12px;
    font-size: 1rem;
    background: rgba(255, 255, 255, 0.96);
    color: #111;
    outline: none;
}

.search-form input[type="search"]::placeholder {
    color: #6b7280;
}

.search-result-info {
    margin-top: 14px;
    color: rgba(255, 255, 255, 0.78);
}

/* =========================================================
BUTTON
========================================================= */
.search-form button,
.btn {
    display: inline-block;
    padding: 12px 18px;
    border: 1px solid var(--primary);
    background: var(--primary);
    color: #fff;
    border-radius: 12px;
    cursor: pointer;
    font-size: 0.95rem;
    transition: 0.2s ease;
}

.search-form button:hover,
.btn:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    text-decoration: none;
    transform: translateY(-1px);
}

.btn.small {
    padding: 7px 10px;
    font-size: 0.82rem;
}

.btn.light {
    background: #fff;
    color: var(--primary);
    border-color: #fff;
}

.btn.light:hover {
    background: #eef6ff;
    border-color: #eef6ff;
}

.btn.primary {
    background: var(--accent);
    border-color: var(--accent);
}

.btn.primary:hover {
    background: #17867a;
    border-color: #17867a;
}

.btn.danger {
    background: var(--danger);
    border-color: var(--danger);
}

.btn.danger:hover {
    background: #a93226;
    border-color: #a93226;
}

/* =========================================================
LAYOUT HOME: KIRI PAPER, KANAN JURUSAN
========================================================= */
.home-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 24px;
    align-items: start;
    margin-bottom: 0;
}

.home-main {
    min-width: 0;
    padding-bottom: 20px;
}

/* =========================================================
PAGE INFO
========================================================= */
.page-info {
    position: relative;
    z-index: 1;
    margin: 0 0 16px;
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.92rem;
}

.page-info strong {
    color: #fff;
}

/* =========================================================
PAPER CARD + HOVER PREVIEW
========================================================= */
.paper-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(238px, 1fr));
    gap: 18px;
    margin-bottom: 40px;
}

.paper-grid > * {
    min-width: 0;
}

.paper-card {
    position: relative;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    background: var(--card);
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.16);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    outline: none;
}

/* Cahaya glow mengelilingi card saat hover */
.paper-card:hover,
.paper-card.active,
.paper-card:focus-within {
    transform: translateY(-6px);
    border-color: rgba(125, 211, 252, 0.55);
    box-shadow:
        0 0 0 1px rgba(125, 211, 252, 0.40),
        0 0 14px rgba(125, 211, 252, 0.35),
        0 0 30px rgba(31, 157, 143, 0.25),
        0 18px 38px rgba(0, 0, 0, 0.26);
}

.cover-link {
    display: block;
    position: relative;
    z-index: 1;
    width: 100%;
}

.paper-card img {
    width: 100%;
    height: 166px;
    object-fit: cover;
    display: block;
    background: #dbe7f3;
}

.paper-body {
    position: relative;
    z-index: 1;
    padding: 14px;
    min-width: 0;
    overflow: hidden;
}

/* Konten body di atas watermark */
.paper-body > * {
    position: relative;
    z-index: 1;
}

/* =========================================================
WATERMARK SAMAR SESUAI JENIS PAPER
========================================================= */
.paper-body::before {
    content: "";
    position: absolute;
    right: 10px;
    bottom: 8px;
    font-size: 76px;
    line-height: 1;
    opacity: 0.16;
    pointer-events: none;
    z-index: 0;
}

.paper-body.wm-jurnal::before {
    content: "📰";
}

.paper-body.wm-tugas-akhir::before {
    content: "🎓";
}

.paper-body.wm-prosiding::before {
    content: "🎤";
}

.paper-body.wm-bahan-ajar::before {
    content: "📚";
}

.paper-body.wm-paten::before {
    content: "💡";
}

.paper-body.wm-institusional::before {
    content: "🏛️";
}

.paper-body.wm-none::before {
    content: "📄";
}

/* Baris tag jenis di dalam body (tidak menimpa cover) */
.paper-tag-row {
    display: flex;
    justify-content: flex-start;
    margin: 0 0 6px;
}

.paper-body h2 {
    margin: 0 0 7px;
    font-size: 0.92rem;
    line-height: 1.32;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.paper-body h2 a {
    color: var(--text);
    text-decoration: none;
}

.paper-body h2 a:hover {
    text-decoration: underline;
}

.meta {
    color: var(--muted);
    font-size: 0.82rem;
    margin: 0 0 10px;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.paper-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0 0 12px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--muted);
}

.paper-stats span {
    white-space: nowrap;
}

.download-counter {
    margin: 0 0 12px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--muted);
}

.hover-preview {
    position: absolute;
    inset: 0;
    z-index: 3;
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    box-sizing: border-box;
    background: linear-gradient(
        180deg,
        rgba(6, 21, 36, 0.94) 0%,
        rgba(15, 76, 129, 0.96) 100%
    );
    color: #fff;
    padding: 16px 18px;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(8px);
    transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s ease;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 10px;
    overflow: hidden;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.hover-preview h3 {
    flex: 0 0 auto;
    margin: 0;
    font-size: 0.92rem;
    line-height: 1.32;
    color: #fff;
    overflow-wrap: anywhere;
    word-break: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.hover-preview p {
    flex: 1 1 auto;
    min-height: 0;
    margin: 0;
    font-size: 0.86rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.90);
    overflow-wrap: anywhere;
    word-break: break-word;
    overflow: auto;
    padding-right: 6px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.35) transparent;
}

.hover-preview p::-webkit-scrollbar {
    width: 6px;
}

.hover-preview p::-webkit-scrollbar-track {
    background: transparent;
}

.hover-preview p::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.28);
    border-radius: 999px;
}

.hover-preview a {
    flex: 0 0 auto;
    margin-top: auto;
    align-self: flex-start;
    color: #fff;
    white-space: nowrap;
}

.paper-card:hover .hover-preview,
.paper-card.active .hover-preview,
.paper-card:focus-within .hover-preview {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
}

.empty-state {
    position: relative;
    z-index: 1;
    background: var(--card);
    border: 1px dashed rgba(255, 255, 255, 0.28);
    border-radius: var(--radius);
    padding: 34px;
    text-align: center;
    color: var(--muted);
    box-shadow: var(--shadow);
    margin-bottom: 32px;
}

/* =========================================================
PANEL JURUSAN
========================================================= */
.jurusan-stats {
    position: sticky;
    top: 90px;
    background: linear-gradient(
        180deg,
        rgba(8, 27, 46, 0.42) 0%,
        rgba(6, 21, 36, 0.28) 100%
    );
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.18);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    color: #fff;
    margin-bottom: 24px;
}

.jurusan-stats h3 {
    margin: 0 0 16px;
    font-size: 1.05rem;
    color: #fff;
}

.jurusan-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 10px;
}

.jurusan-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #fff;
    text-decoration: none;
    transition: 0.2s ease;
}

.jurusan-item:hover {
    background: rgba(255, 255, 255, 0.16);
    border-color: rgba(255, 255, 255, 0.22);
    text-decoration: none;
    transform: translateY(-1px);
}

.jurusan-item.active {
    background: rgba(31, 157, 143, 0.28);
    border-color: rgba(31, 157, 143, 0.55);
}

.jurusan-name {
    font-size: 0.92rem;
    line-height: 1.35;
}

.jurusan-count {
    min-width: 42px;
    text-align: center;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    font-weight: bold;
    font-size: 0.9rem;
}

.jurusan-total {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.16);
    color: rgba(255, 255, 255, 0.86);
    font-size: 0.95rem;
}

.jurusan-total strong {
    color: #fff;
}

/* =========================================================
TOMBOL KEMBALI DI HALAMAN PAPER
========================================================= */
.paper-back {
    margin: 0 0 16px;
}

.paper-back .btn {
    background: rgba(15, 76, 129, 0.08);
    color: var(--primary);
    border-color: rgba(15, 76, 129, 0.18);
    font-weight: 600;
}

.paper-back .btn:hover {
    background: rgba(15, 76, 129, 0.14);
    color: var(--primary-dark);
    border-color: rgba(15, 76, 129, 0.28);
}

/* =========================================================
HALAMAN DETAIL PAPER
========================================================= */
.paper-detail,
.admin-dashboard,
.admin-form-page,
.admin-logs,
.auth-box {
    position: relative;
    z-index: 1;
    background: var(--card);
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: var(--radius);
    padding: 26px;
    box-shadow: var(--shadow);
    color: var(--text);
}

.paper-detail h1 {
    margin-top: 0;
    color: var(--primary);
}

.paper-meta p {
    margin: 6px 0;
}

.paper-meta strong {
    color: #111;
}

.abstract,
.cover-preview,
.download-section {
    margin-top: 24px;
}

.cover-preview img {
    display: block;
    width: auto;
    max-width: 190px;
    max-height: 270px;
    object-fit: contain;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.07);
}

.download-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 12px;
}

.success-text {
    color: #145a32;
    background: rgba(210, 255, 233, 0.95);
    border: 1px solid rgba(169, 223, 191, 0.9);
    padding: 10px 12px;
    border-radius: 10px;
    margin-bottom: 12px;
}

.download-form,
.admin-form,
.auth-form {
    margin-top: 16px;
}

/* =========================================================
FORM
========================================================= */
.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: bold;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 12px;
    font-size: 1rem;
    background: #fff;
    color: #111;
    outline: none;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(31, 157, 143, 0.12);
}

.form-group textarea {
    resize: vertical;
}

.form-group small {
    display: block;
    margin-top: 6px;
    color: var(--muted);
}

/* =========================================================
ADMIN DASHBOARD
========================================================= */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.stat-card {
    background: #f8fbff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px;
}

.stat-number {
    font-size: 2rem;
    font-weight: bold;
    color: var(--primary);
    margin: 8px 0 0;
}

.table-responsive {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 12px;
    background: #fff;
}

.data-table th,
.data-table td {
    border: 1px solid var(--border);
    padding: 10px 12px;
    text-align: left;
    vertical-align: top;
}

.data-table th {
    background: #eef4fb;
    color: var(--primary-dark);
}

.action-links {
    white-space: nowrap;
}

.inline-form {
    display: inline-block;
    margin-left: 6px;
}

/* =========================================================
LOGIN / AUTH
========================================================= */
.auth-box {
    max-width: 500px;
    margin: 36px auto;
    text-align: center;
}

.auth-logo {
    display: block;
    max-width: 150px;
    width: 100%;
    height: auto;
    margin: 0 auto 16px;
    object-fit: contain;
}

.auth-box h1 {
    margin: 0 0 6px;
    color: var(--primary);
}

.auth-subtitle {
    margin: 0 0 18px;
    color: var(--muted);
    font-size: 0.95rem;
}

.auth-form {
    text-align: left;
}

.small-note {
    margin-top: 16px;
    color: var(--muted);
    font-size: 0.9rem;
}

/* =========================================================
FOOTER TIPIS
========================================================= */
.site-footer {
    position: relative;
    z-index: 5;
    flex: 0 0 auto;
    width: 100%;
    margin-top: auto;
    padding: 18px 0 22px;
    color: rgba(255, 255, 255, 0.68);
    text-align: center;
    font-size: 0.82rem;
    line-height: 1.35;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    clear: both;
}

.site-footer::before,
.site-footer::after {
    display: none !important;
}

.footer-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    width: min(1200px, 92%);
    margin: 0 auto;
}

.site-footer p {
    margin: 0;
}

/* =========================================================
PAGINATION
========================================================= */
.pagination {
    position: relative;
    z-index: 1;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin: 32px 0 20px;
    padding: 0;
    list-style: none;
}

.pagination a,
.pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.14);
    color: #fff;
    text-decoration: none;
    font-size: 0.9rem;
    transition: 0.2s ease;
}

.pagination a:hover {
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.24);
    text-decoration: none;
    transform: translateY(-1px);
}

.pagination .active {
    background: var(--accent);
    border-color: var(--accent);
    font-weight: bold;
    color: #fff;
}

.pagination .disabled {
    opacity: 0.45;
    pointer-events: none;
}

.pagination .ellipsis {
    min-width: auto;
    padding: 0 4px;
    border: 0;
    background: transparent;
    color: rgba(255, 255, 255, 0.65);
}

/* =========================================================
WARNA ANGKA DATA PADA INFO PAGINATION ADMIN & USER
========================================================= */
.admin-dashboard .page-info,
.admin-form-page .page-info,
.admin-logs .page-info,
.verification-info,
.user-panel-info {
    color: #64748b !important;
}

.admin-dashboard .page-info strong,
.admin-form-page .page-info strong,
.admin-logs .page-info strong,
.verification-info strong,
.user-panel-info strong {
    color: #c0392b !important;
}

/* =========================================================
TAG JENIS PAPER / DOKUMEN (UKURAN KECIL)
========================================================= */
.jenis-tag {
    display: inline-block;
    padding: 2px 7px;
    border-radius: 999px;
    font-size: 0.6rem;
    font-weight: bold;
    letter-spacing: 0.1px;
    line-height: 1.25;
    color: #fff;
    background: #64748b;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    white-space: nowrap;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

.jenis-jurnal {
    background: #0f4c81;
}

.jenis-tugas-akhir {
    background: #1f9d8f;
}

.jenis-prosiding {
    background: #6f42c1;
}

.jenis-bahan-ajar {
    background: #e67e22;
}

.jenis-paten {
    background: #b7950b;
}

.jenis-institusional {
    background: #c0392b;
}

.jenis-none {
    background: #64748b;
}

/* Tag di halaman detail paper (sudut kanan atas kartu) */
.paper-detail-tag {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
}

.bidang-chips {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 6px;
    vertical-align: middle;
}

.bidang-chip {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 999px;
    background: #eef4fb;
    border: 1px solid #d9e2ec;
    color: #0b3961;
    font-size: 0.74rem;
    font-weight: 600;
}

/* =========================================================
MODAL PDF FULL 1 LAYAR
========================================================= */
.pdf-modal {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important;
    z-index: 2147483647 !important;
    display: flex !important;
    align-items: stretch !important;
    justify-content: stretch !important;
    padding: 0 !important;
    margin: 0 !important;
    background: rgba(2, 8, 15, 0.90) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.pdf-modal[hidden] {
    display: none !important;
}

.pdf-modal-dialog {
    width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important;
    max-width: none !important;
    max-height: none !important;
    border-radius: 0 !important;
    overflow: hidden !important;
    background: #ffffff !important;
    box-shadow: none !important;
    display: flex !important;
    flex-direction: column !important;
}

.pdf-modal-header {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 16px;
    background: var(--primary);
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.pdf-modal-header h3 {
    margin: 0;
    font-size: 0.98rem;
    line-height: 1.35;
    max-width: calc(100% - 46px);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #fff;
}

.pdf-modal-close {
    border: 0;
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
    width: 34px;
    height: 34px;
    border-radius: 999px;
    font-size: 1.35rem;
    line-height: 1;
    cursor: pointer;
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.pdf-modal-close:hover {
    background: rgba(255, 255, 255, 0.30);
}

.pdf-modal-body {
    flex: 1 1 auto;
    min-height: 0;
    position: relative;
    background: #eef2f7;
    overflow: hidden;
}

.pdf-modal-body iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;
    height: 100% !important;
    min-height: 100% !important;
    border: 0;
    display: block;
    background: #fff;
}

body.pdf-modal-open {
    overflow: hidden !important;
}

body.pdf-modal-open .site-footer {
    display: none !important;
}

/* =========================================================
ACCESS PROTECTION: RIGHT CLICK & PRINT
========================================================= */
body.access-protected,
body.access-protected .pdf-modal,
body.access-protected .pdf-modal-dialog,
body.access-protected .pdf-modal-body,
body.access-protected .pdf-modal-header,
body.access-protected iframe {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    -webkit-touch-callout: none;
}

@media print {
    body.access-protected,
    body.access-protected * {
        display: none !important;
    }

    body.access-protected {
        background: #fff !important;
    }

    body.access-protected::before {
        content: "Pencetakan dinonaktifkan.";
        display: block !important;
        width: 100%;
        padding: 40px 0;
        text-align: center;
        font: bold 16px Arial, Helvetica, sans-serif;
        color: #000;
        background: #fff;
    }
}

/* =========================================================
RESPONSIVE
========================================================= */
@media (max-width: 992px) {
    .home-layout {
        grid-template-columns: 1fr;
    }

    .jurusan-stats {
        position: static;
        order: -1;
    }
}

@media (max-width: 768px) {
    .site-header {
        padding: 10px 0;
    }

    .header-inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .main-nav {
        width: 100%;
    }

    .brand-logo {
        height: 38px;
    }

    .hero {
        padding: 24px 18px;
    }

    .search-form input[type="search"] {
        min-width: 100%;
    }

    .paper-grid {
        grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
        gap: 16px;
        margin-bottom: 28px;
    }

    .paper-card img {
        height: 180px;
    }

    .paper-body h2 {
        font-size: 0.96rem;
    }

    .meta {
        font-size: 0.84rem;
    }

    .paper-stats {
        font-size: 0.78rem;
        gap: 8px;
    }

    .hover-preview {
        padding: 16px;
    }

    .paper-body::before {
        font-size: 60px;
        right: 8px;
        bottom: 6px;
    }

    main.container {
        padding: 20px 0 40px;
    }

    .site-footer {
        padding: 12px 0 16px;
        font-size: 0.78rem;
    }

    .cover-preview img {
        max-width: 150px;
        max-height: 220px;
    }

    .pagination a,
    .pagination span {
        min-width: 36px;
        height: 36px;
        padding: 0 10px;
        font-size: 0.85rem;
    }

    .paper-detail-tag {
        position: static;
        display: inline-block;
        margin: 0 0 10px;
    }

    .pdf-modal,
    .pdf-modal-dialog {
        width: 100vw !important;
        height: 100vh !important;
        height: 100dvh !important;
        border-radius: 0 !important;
    }

    .pdf-modal-header {
        padding: 10px 12px;
    }

    .pdf-modal-header h3 {
        font-size: 0.92rem;
        max-width: calc(100% - 42px);
    }

    .pdf-modal-close {
        width: 32px;
        height: 32px;
        font-size: 1.25rem;
    }
}