/***********************************************************
 * 1. GLOBAL SETTINGS, FONTS & VARIABLES
 ***********************************************************/
@import url('https://fonts.googleapis.com/css?family=Titillium+Web&display=swap');
@import url('https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz&display=swap');
@import url("https://fonts.googleapis.com/css2?family=Afacad:ital,wght@0,400..700;1,400..700&family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap");

:root {
    /* Color Palette */
    --primary-blue: #0B3C5D;       /* Navigasi Utama */
    --primary-red: #831d1d;        /* Border & Text Button */
    --accent-red: #871e1e;         /* Top Border Block */
    --accent-orange: #fafafa;      /* Background HTML (Off-white sesuai file lo) */
    --brand-orange: #FFA552;       /* NEW: Orange Logo untuk Aksen Sidebar */
    --accent-blue-bright: #0b2ece; /* Underline Title */
    --accent-green: #1FB141;       /* Credits Button */
    
    /* Neutrals */
    --white: #ffffff;
    --grey-text: #797979;
    --grey-dark: #696969;
    --border-light: #ececec;
    
    /* Effects */
    --shadow-soft: 0 4px 15px rgba(0, 0, 0, 0.08); /* Update shadow biar lebih halus */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box; /* Tambahan penting biar padding gak ngerusak layout */
}

/***********************************************************
 * 2. BASE STYLES
 ***********************************************************/
html {
    background-image: url(/**/);
    background-color: var(--accent-orange);
    background-size: cover;
    background-attachment: fixed;
}

body {
    background: transparent;
    font-family: 'Montserrat', sans-serif;
}

article .main_entry,
.page,
.obj_article_summary {
    text-align: justify;
}

/***********************************************************
 * 3. COMPONENT: BUTTONS & ACTIONS
 ***********************************************************/
.cmp_manuscript_button,
.block_make_submission a,
.obj_galley_link {
    background: var(--white);
    color: #841d1d;
    border: solid 1px var(--primary-red);
}

/***********************************************************
 * 4. HEADER & NAV STRUCTURE
 ***********************************************************/
.has_site_logo .pkp_head_wrapper {
    padding-right: 0px;
}

.pkp_site_nav_toggle {
    width: 3.857rem;
    height: 3.4rem;
}

.pkp_site_name_wrapper {
    padding-left: 0;
    padding-right: 0;
}

/* HEADER FIX FOR OJS 3.3 */
.pkp_structure_head,
.pkp_structure_head[style] {
    background-size: contain !important;
    background-repeat: no-repeat !important;
    background-position: top center !important;
    min-height: 250px !important;
    height: auto !important;
    padding-top: 20px !important;
    padding-bottom: 10px !important;
    margin-bottom: 10px !important;
}

/* LOGO FIX */
.pkp_site_name .is_img img {
    max-height: 85px !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
    display: block;
}

.pkp_site_name_wrapper,
.pkp_site_name_wrapper .pkp_site_name {
    height: auto !important;
    padding: 10px 0 !important;
    display: none;
    margin: 0 !important;
}

.pkp_head_wrapper .pkp_site_name_wrapper .pkp_site_name .is_img {
    margin-bottom: 0 !important;
}

/* NAVIGATION (PRIMARY MENU) */
.pkp_navigation_primary_wrapper,
.pkp_site_nav_menu {
    background: var(--primary-blue) !important;
    margin-top: 120px !important;
}

#navigationPrimary ul li ul {
    background-color: var(--white) !important; 
    box-shadow: 0 4px 15px rgba(0,0,0,0.15); /* Kasih bayangan biar kelihatan 'ngambang' */
    padding: 10px 0;
    border-radius: 0 0 5px 5px;
}

/* 2. Tulisannya (Ganti warna putih samar jadi Biru Tua tegas) */
#navigationPrimary ul li ul li a {
    display: block !important;        /* Wajib! Biar link menuhin satu kotak full */
    background-color: #FFFFFF !important; /* Paksa background Putih bersih */
    color: #0B3C5D !important;        /* Tulisan Biru Tua (Adniguna) */
    padding: 12px 20px !important;    /* Jarak nafas yang pas */
    transition: none !important;      /* Hapus animasi biar gak 'lag' ganti warnanya */
}

/* 2. Tampilan pas di-HOVER (Kursor Nempel) */
/* Kita targetin Link-nya langsung */
#navigationPrimary ul li ul li a:hover {
    background-color: #FFA552 !important; /* Background langsung jadi ORANGE */
    color: #FFFFFF !important;            /* Tulisan jadi PUTIH */
}

/***********************************************************
 * 5. SIDEBAR BLOCKS (MODERN CARD STYLE - REVISED)
 ***********************************************************/
/* Wrapper Block Card */
.pkp_block {
    background-color: var(--white);
    box-shadow: var(--shadow-soft);
    margin: 0 0 25px 0; /* Jarak antar blok */
    padding: 0;
    border-radius: 8px; /* Sudut tumpul modern */
    border: 1px solid #e0e0e0; /* Border tipis halus */
    overflow: hidden; /* Pastikan isi tidak keluar dari border radius */
}

/* Header Judul Block (Language, Info, dll) */
.pkp_structure_sidebar .pkp_block .title {
    display: block;
    background-color: var(--primary-blue); /* Latar Biru Adniguna */
    color: var(--white) !important;
    padding: 12px 18px;
    font-size: 15px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 4px solid var(--brand-orange); /* Aksen Oranye di bawah judul */
    width: 100%;
    margin: 0;
}

/* Konten dalam Block */
.pkp_block .content {
    background: var(--white);
    border-top: none; /* Hapus border merah lama */
    padding: 15px 18px;
}

/* Khusus Keyword Cloud */
.block_Keywordcloud {
    background: var(--white);
    border-top: none;
    padding: 0;
}

.pkp_structure_sidebar .block_Keywordcloud .title {
    /* Samakan style dengan judul lain */
    border-bottom: 4px solid var(--brand-orange);
    background-color: var(--primary-blue);
    color: var(--white);
    padding: 12px 18px;
    font-size: 15px;
}

/***********************************************************
 * 6. CUSTOM SIDEBAR MENU (LEFT NAV)
 ***********************************************************/
.container-block {
    width: 100%;
    padding: 0;
    margin: 0;
}

.container-block .sidebar-block {
    position: relative;
    width: 100%;
}

.container-block .sidebar-block ul {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.container-block .sidebar-block ul .menus {
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    background-color: #e2d5cc;
    padding: 10px;
    margin: 2px;
    border-radius: 2px;
    list-style: none;
    font-size: 20px;
    align-items: center;
    position: relative;
}

.container-block .sidebar-block ul .menus:before {
    transition: 0.2s;
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    border-radius: 2px 0 0 2px;
    width: 10px;
    height: 100%;
    background: #7d4548;
    z-index: 0;
}

.container-block .sidebar-block ul .menus p {
    transition: 0.2s;
    font-size: 14px;
    z-index: 2;
    padding-left: 6px;
}

.container-block .sidebar-block ul .menus:hover:before {
    width: 80%;
}

.container-block .sidebar-block ul .menus:hover p {
    color: #fefefe;
    transform: translateX(5px);
}

/* SIDEBAR CREDITS */
.container-block .sidebar-block .credits {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 10vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.container-block .sidebar-block .credits p {
    cursor: pointer;
    font-family: 'Afacad', sans-serif;
    font-size: 18px;
    opacity: 0.7;
    transition: .2s;
}

.container-block .sidebar-block .credits p a {
    text-decoration: none;
    background-color: var(--accent-green);
    padding: 5px;
    color: #FEFEFE;
    border-radius: 5px;
}

.container-block .sidebar-block .credits p:hover {
    opacity: 1;
}

/***********************************************************
 * 7. SIDEBAR RIGHT (MENU ITEMS - MODERN LIST)
 ***********************************************************/
/* Reset list style */
.sidebar-menu, 
.pkp_block .content ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

/* Style per item list */
.pkp_block .content li,
.pkp_block .content .sidebar-menu li {
    margin-bottom: 0;
    padding: 8px 0;
    border: none;
    border-bottom: 1px dashed #e0e0e0; /* Garis putus-putus halus */
}

/* Hapus garis di item terakhir */
.pkp_block .content li:last-child {
    border-bottom: none;
}

/* Style Link Sidebar */
.pkp_block .content a,
.sidebar-menu a {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    padding: 0; /* Padding dihandle li */
    border-radius: 0;
    font-size: 14px;
    font-weight: 500;
    color: var(--grey-dark);
    transition: all 0.2s ease;
    background: transparent; /* Reset gradient merah lama */
}

/* Hover Effect: Text jadi biru & geser dikit */
.pkp_block .content a:hover,
.sidebar-menu a:hover {
    color: var(--primary-blue);
    transform: translateX(5px); 
    background: transparent;
}

/* Hapus efek gradient background lama yg bikin kotak-kotak */
.sidebar-menu a::before {
    display: none; 
}

/* Icon (kalau ada) */
.sidebar-menu a i {
    color: var(--primary-red);
    font-size: 14px;
    opacity: 0.8;
}

.sidebar-menu a:hover i {
    transform: none;
    opacity: 1;
}

/***********************************************************
 * 8. CONTENT AREA
 ***********************************************************/
body .pkp_structure_page {
    background: var(--white);
    box-shadow: none;
}

.pkp_structure_content .pkp_structure_main {
    box-shadow: var(--shadow-soft);
    background: var(--white);
    margin-top: 10px;
    padding-top: 0px !important;
    border-top: none;
}

.homeJournal {
    border: solid 1px #ebebeb;
    border-radius: 3px;
    padding: 1.5rem;
    box-shadow: 5px 5px 5px #dadada;
}

.journal-sidebar {
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
    padding: 20px;
    color: var(--grey-text);
}

/***********************************************************
 * 9. FOOTER
 ***********************************************************/
.pkp_brand_footer {
    display: none;
}

.pkp_structure_page .pkp_structure_footer_wrapper {
    background: #fff;
    margin-top: 15px;
    border-radius: 5px;
    border-bottom: none;
    box-shadow: var(--shadow-soft);
}

/***********************************************************
 * 10. RESPONSIVE QUERIES
 ***********************************************************/

/* TABLET (≥768px) */
@media (min-width: 768px) {
    .pkp_page_index .cmp_announcements > .obj_announcement_summary:before,
    .pkp_page_index .cmp_announcements .more:before {
        border-left: none;
    }
}

/* DESKTOP (≥992px) */
@media (min-width: 992px) {
    .pkp_navigation_user_wrapper {
        top: 10px;
        width: initial;
        transform: translateX(0%);
    }

    .pkp_site_name_wrapper .pkp_site_name {
        left: 0;
    }

    .pkp_head_wrapper .pkp_site_name_wrapper .pkp_site_name .is_img img {
        max-height: 100%;
    }

    .pkp_head_wrapper .pkp_site_name_wrapper .pkp_site_name {
        padding-top: 0.071rem;
        padding-bottom: 0.071rem;
    }

    .pkp_page_index .homepage_about {
        padding-top: 0;
        padding-bottom: 0;
    }

    .pkp_structure_sidebar:before {
        border-left: none;
    }

    .pkp_site_name {
        padding-top: 0;
        padding-bottom: 0;
    }

    .pkp_block {
        margin: 15px 0 0 15px;
        padding: 0;
    }
}

/* MOBILE (≤991.98px) - FIXED OVERLAP */
@media (max-width: 991.98px) {
    .pkp_site_name_wrapper {
        height: 3.4rem;
    }

    .pkp_site_name_wrapper .pkp_site_name {
        left: 3.2rem;
        height: 54px;
        padding-top: 0;
        padding-bottom: 0;
    }

    .pkp_page_index .homepage_about {
        padding-top: 2.143rem;
        padding-bottom: 2.143rem;
    }

    .pkp_site_nav_menu {
        background: var(--white);
        box-shadow: 0px 6px 25px 0px black;
    }
}
/***********************************************************
 * 11. FIX FINAL: USER NAV (ANTI MELAR & PRESISI)
 ***********************************************************/

/* 1. WRAPPER UTAMA */
.pkp_structure_head .pkp_navigation_user_wrapper {
    position: absolute !important;
    top: 20px !important;
    right: 20px !important;       /* Jarak dari kanan */
    
    /* KUNCI SUPAYA GAK MELAR: */
    left: auto !important;        /* Reset tarikan kiri */
    width: fit-content !important; /* Lebar SESUAI ISI KONTEN aja */
    display: inline-flex !important; /* Bungkus rapet isinya */
    white-space: nowrap !important;  /* Teks dilarang turun baris */
    
    /* Tampilan Kosmetik */
    background-color: var(--white);
    padding: 8px 25px;
    border-radius: 50px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
    z-index: 9999;
}

/* 2. MENU ITEM (Login & Register) */
.pkp_navigation_user {
    display: flex !important;
    align-items: center;
    justify-content: center;
    margin: 0 !important;
    padding: 0 !important;
    width: auto !important; /* Pastikan list-nya juga gak melar */
    gap: 15px;
}

/* 3. TEKS LINK */
.pkp_navigation_user li a {
    color: var(--primary-blue) !important;
    font-weight: 700;
    font-size: 13px;
    text-transform: uppercase;
    text-decoration: none;
    font-family: 'Montserrat', sans-serif;
    line-height: 1; /* Biar vertikalnya pas tengah */
}

.pkp_navigation_user li a:hover {
    color: var(--brand-orange) !important;
}

/* 4. DROPDOWN (Dashboard, Logout) - Posisi diperbaiki */
.pkp_navigation_user li ul {
    position: absolute;
    top: 130%;
    right: 0;
    left: auto !important;
    width: 160px; /* Kasih lebar fix buat dropdown aja */
    background-color: #ffffff !important;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
    padding: 10px 0;
    display: none;
    text-align: left;
}

.pkp_navigation_user li:hover ul {
    display: block;
}

.pkp_navigation_user li ul li {
    display: block;
    margin: 0;
}

.pkp_navigation_user li ul li a {
    display: block;
    padding: 10px 20px;
    color: var(--grey-dark) !important;
    text-transform: capitalize;
    font-weight: 500;
    border-bottom: 1px dashed #eee;
}

.pkp_navigation_user li ul li a:hover {
    background-color: #f9f9f9;
    color: var(--brand-orange) !important;
}

/* 5. FIX MOBILE (HP) */
@media (max-width: 991px) {
    .pkp_structure_head .pkp_navigation_user_wrapper {
        position: relative !important;
        top: 0 !important;
        right: 0 !important;
        width: 100% !important; /* Kalau di HP baru boleh full width */
        display: block !important;
        background: #f5f5f5;
        border-radius: 0;
        box-shadow: none;
        text-align: center;
        margin-bottom: 10px;
    }
    
    .pkp_navigation_user {
        justify-content: center;
    }
}
/***********************************************************
 * 12. FIX NAVIGASI UTAMA (HOME, CURRENT, ARCHIVES)
 * Agar Kontras, Tebal & Mudah Dibaca
 ***********************************************************/

/* 1. Pastikan Background Menu Full Biru Tua */
.pkp_navigation_primary_wrapper {
    background: var(--primary-blue) !important; /* Warna #0B3C5D */
    border-bottom: 4px solid var(--brand-orange); /* Pemanis garis orange di bawah navbar */
}

/* 2. Styling Teks Link Utama */
.pkp_navigation_primary > li > a {
    color: var(--white) !important;         /* WAJIB PUTIH: Biar kontras dengan background biru */
    font-family: 'Montserrat', sans-serif;  /* Pakai font Montserrat biar modern */
    font-weight: 700 !important;            /* BOLD: Biar teks tebal & jelas terbaca */
    text-transform: uppercase;              /* HURUF BESAR SEMUA: Standar jurnal profesional */
    font-size: 15px !important;             /* Ukuran dinaikkan sedikit */
    padding: 18px 25px !important;          /* Ruang klik diperluas biar user gampang ngeklik */
    letter-spacing: 0.5px;                  /* Jarak antar huruf biar lega */
    transition: all 0.3s ease-in-out;       /* Animasi halus */
    opacity: 1 !important;
}

/* 3. Efek Hover (Pas Kursor Nempel) & Menu Aktif */
/* Saat disentuh, background jadi Orange, Teks Putih */
.pkp_navigation_primary > li > a:hover,
.pkp_navigation_primary > li:hover > a,
.pkp_navigation_primary > li.focus > a,
.pkp_navigation_primary > li[aria-expanded="true"] > a {
    background-color: var(--brand-orange) !important; /* Warna #FFA552 */
    color: var(--white) !important;
    text-decoration: none;
}
/* =======================================================
   FIX FINAL: POSISI TOMBOL (KIRI & TURUN)
   Style tombol tetap sama, hanya geser koordinat.
   ======================================================= */

@media (max-width: 991px) {

    /* 1. HEADER CONTAINER */
    .pkp_structure_head {
        position: relative !important;
        background-color: #ffffff !important;
        border-bottom: 3px solid #FFA552;
        min-height: 100px !important; /* Tinggi header aman */
        padding-top: 15px !important;
        z-index: 500 !important;
    }

    /* 2. POSISI TOMBOL MENU (YANG DIUBAH DISINI) */
    .pkp_site_nav_toggle {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        
        position: absolute !important;
        
        /* --- ATUR POSISI DI SINI --- */
        left: -60px !important;    /* Paling Kiri (Jarak dari pinggir layar) */
        top: 40px !important;     /* Turun ke Bawah (Jarak dari atas header) */
        /* --------------------------- */
        
        width: 45px !important;
        height: 40px !important;
        
        /* Style Kotak Biru (JANGAN DIUBAH) */
        background-color: #0B3C5D !important; 
        border: 2px solid #ffffff !important;
        border-radius: 5px !important;
        box-shadow: 0 2px 5px rgba(0,0,0,0.3) !important;
        z-index: 999999 !important;
        cursor: pointer !important;
    }

    /* 3. GAMBAR IKON GARIS TIGA (TETAP) */
    .pkp_site_nav_toggle:before {
        content: "" !important;
        position: absolute;
        left: 10px;
        top: 10px;
        width: 21px;
        height: 3px;
        background-color: white;
        box-shadow: 
            0 7px 0 0 white,
            0 14px 0 0 white;
    }

    /* 4. POSISI LOGO (Padding Kiri Biar Gak Nabrak Tombol) */
    .pkp_head_wrapper,
    .pkp_site_name_wrapper {
        display: block !important;
        width: 100% !important;
        text-align: center !important;
        margin: 0 !important;
        padding: 0 !important;
        
        /* Beri jarak aman di kiri supaya logo geser ke kanan */
        padding-left: 70px !important; 
        padding-right: 15px !important;
    }

    .pkp_site_name_wrapper .pkp_site_name .is_img img {
        display: inline-block !important;
        max-height: 55px !important;
        max-width: 100% !important;
        width: auto !important;
        height: auto !important;
        margin-top: 5px !important;
    }

    /* Sembunyikan elemen pengganggu */
    .pkp_site_nav_toggle span, .pkp_site_nav_toggle i, 
    .pkp_structure_head .pkp_navigation_user_wrapper {
        display: none !important;
    }
}