/* ================================================================
   IJSPS LIVE STYLESHEET - CSS ONLY
   Uploaded through Settings > Website > Appearance > Advanced.
   No template, font file or server change is needed for anything here.
   NOT included (these need server access): self-hosted fonts,
   Back / Main Page buttons, Share buttons, PDF view count (eye).
   ================================================================ */

/* ================================================================
   GLOBAL / BODY
   ================================================================ */
body {
    background: #f2f1e9;
}
.container-page p {
    text-align: justify;
}
.container-page {
    padding-bottom: 20px;
}
@media (min-width: 992px) {
    .container-page,
    .container-footer,
    .header {
        padding-left: 50px;
        padding-right: 50px;
    }
}

/* ================================================================
   HEADER
   ================================================================ */
.header {
    background-color: #f6f2e8;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
}
.logo-wrapper .home-link {
    display: inline-block;
    margin-left: 0;
}

/* Register/Login buttons */
.pkp_navigation_user a[href$="/login"],
.pkp_navigation_user a[href*="register"],
#user-dashboard-link {
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    padding: 8px 16px;
    margin-left: 6px;
}
.pkp_navigation_user a[href*="register"] {
    border: 1.5px solid #BA8223;
    color: #7a5f16;
}
.pkp_navigation_user a[href$="/login"],
#user-dashboard-link {
    background: #1a1610;
    color: #f6f2e8;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    padding: 8px 16px;
    margin-left: 6px;
    border-radius: 0;
}
.btn-primary {
    background-color: #BA8223;
}

/* ================================================================
   NAV BAR (dark strip: ISM / Current / Archives / About / Search)
   ================================================================ */
.nav-tabs .nav-link {
    color: white;
}
.nav-tabs .nav-link:hover {
    color: #cc9c00;
    font-weight: 600;
}
.lower-header {
    background-color: #1a1610;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    width: 100vw;
    padding-left: calc(50vw - 50% + 50px);
    padding-right: calc(50vw - 50% + 50px);
    border-bottom: 3px solid #b8912f;
}
.lower-header.is-fixed {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1030;
    background: #1a1610;
    box-shadow: 0 2px 8px rgba(0,0,0,.15);
    padding-left: calc(50vw - 50% + 50px);
    padding-right: calc(50vw - 50% + 50px);
    border-bottom: 3px solid #b8912f;
}
@media (min-width: 992px) {
    #navigationPrimary {
        border: 0;
        justify-content: flex-start;
        padding-bottom: 0;
    }
    #navigationPrimary .nav-link {
        color: #d8d0c0;
        font-weight: 600;
        font-size: 13px;
        letter-spacing: .1em;
        padding: 14px 22px;
    }
    #navigationPrimary li:first-child .nav-link {
        color: #e8c877;
        font-weight: 700;
        letter-spacing: .12em;
        padding-left: 0;
    }
}

/* NAV BAR hover: light weight -> heavy weight + gold */
@media (min-width: 992px) {
    #navigationPrimary li .nav-link,
    #navigationPrimary li:first-child .nav-link {
        font-weight: 400;
    }
    #navigationPrimary li .nav-link:hover,
    #navigationPrimary li .nav-link:focus-visible {
        color: #cc9c00;
        font-weight: 700;
    }
}

/* Dropdown menu (e.g. "About" submenu) */
.dropdown-item:hover,
.dropdown-item:focus,
.dropdown-item:active {
    background-color: #BA8223;
    color: #fff;
}

/* ================================================================
   HOMEPAGE BANNER
   ================================================================ */
.homepage_image {
    aspect-ratio: 3580 / 560;
    min-height: 0;
}

/* ================================================================
   ISSUE TOC: cover image + articles side-by-side (classic theme)
   ================================================================ */
@media (min-width: 992px) {
    .description_cover {
        float: left;
        margin: 0 40px 20px 0;
    }
    .issue_cover_block,
    .issue_cover_block.align-left {
        width: auto;
        text-align: left;
    }
    .description_cover .cover_image {
        max-width: 200px;
        width: auto;
        height: auto;
        display: block;
    }
    .galleys,
    .sections,
    .sections .section {
        overflow: hidden;
        padding-top: 0;
    }
    .current_issue::after {
        content: "";
        display: table;
        clear: both;
    }
    .current_issue header {
        margin-bottom: 36px;
    }
    .section_title {
        padding-top: 0;
        padding-bottom: 8px;
        border-bottom: 2px solid #1a1610;
        margin-bottom: 24px;
    }
    .article_summary {
        margin-bottom: 34px;
    }
    .read_more {
        margin-left: 240px;
    }
}

.section_title {
    font-weight: 700;
}
.summary_title {
    font-weight: 700;
}

/* "View All Issues" button */
.sections .section {
    padding-bottom: 0;
}
.read_more {
    display: inline-block;
    margin-top: 6px;
    padding: 11px 22px;
    background: #1a1610;
    color: #f6f2e8 !important;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    border: none;
}
.read_more:hover {
    background: #BA8223;
}

/* PDF download button */
.galley-link.pdf {
    border-color: #1a1610;
    color: #1a1610;
}
.galley-link.pdf:hover {
    background-color: #BA8223;
    border-color: #BA8223;
    color: #fff;
}

/* Article summary title clamp (homepage article grid) */
.article_summary .summary_title_wrapper .summary_title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ================================================================
   "ABOUT IJSPS" SECTION (homepage, below issue listing)
   ================================================================ */
@media (min-width: 992px) {
    .additional_content {
        margin-top: 24px;
        padding-top: 20px;
        border-top: 2px solid #cfc8ba;
    }
}
.additional_content p:first-child strong {
    font-family: 'Montserrat', sans-serif;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: .1em;
    color: #7a5f16;
    text-transform: uppercase;
}
.additional_content p:first-child {
    margin-bottom: 8px;
}

/* ================================================================
   ARTICLE PAGE: PDF button above "+ More Info"
   (scoped to the row containing the article's own title so this
   never touches similar row/col markup used elsewhere, e.g.
   "Most Read" / related-articles sidebar entries)
   ================================================================ */
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) {
    display: flex;
    flex-wrap: wrap;
}
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) > .col-md-8 {
    order: 1;
}
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) > .col-md-12 {
    display: contents;
}
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) .authors_info {
    order: 2;
    flex: 0 0 100%;
    max-width: 100%;
}
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) > .col-md-4 {
    order: 3;
    margin-top: 12px;
    flex: 0 0 100%;
    max-width: 100%;
    text-align: left !important;
}
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) .item.galleys {
    float: none !important;
    display: block !important;
    justify-content: flex-start !important;
    margin-left: 0 !important;
    margin-right: auto !important;
    text-align: left !important;
}
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) .item.galleys .btn {
    margin-left: 0 !important;
}
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) .additional-authors-info {
    order: 4;
    flex: 0 0 100%;
    max-width: 100%;
    margin-top: 8px;
}
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) .authors_info,
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) .additional-authors-info {
    padding-left: 15px;
    padding-right: 15px;
}
.more-authors-info-button {
    text-decoration: none;
}

/* More Info button: sits to the right of the authors, details open below the PDF button */
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) > .col-md-8 {
    flex: 0 0 100%;
    max-width: 100%;
}
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) .authors_info {
    flex: 0 1 auto;
    max-width: 100%;
    padding-right: 0;
}
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) .additional-authors-info {
    display: contents;
}
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) .more-authors-info-button {
    order: 2;
    align-self: center;
    margin-left: 18px;
}
.row:has(> .col-md-8 .article-full-title):has(> .col-md-4 > .item.galleys) #authorInfoCollapse {
    order: 4;
    flex: 0 0 100%;
    max-width: 100%;
    margin-top: 8px;
    padding-left: 15px;
    padding-right: 15px;
}

/* ================================================================
   ARTICLE PAGE: How to Cite box
   ================================================================ */
#citationOutput,
#citationOutput * {
    font-family: 'Cardo', serif !important;
    font-size: 16px !important;
}
#citationOutput .csl-entry {
    text-align: justify;
}

/* More Citation Formats button */
#dropdownMenuButton {
    background: #1a1610;
    border: 1.5px solid #1a1610;
    border-radius: 0;
    color: #f6f2e8;
    font-family: 'Montserrat', sans-serif;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    padding: 11px 18px;
}
#dropdownMenuButton::after {
    content: "";
    display: inline-block;
    margin-left: 10px;
    vertical-align: middle;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid currentColor;
}
#dropdownMenuButton:hover,
#dropdownMenuButton:focus,
#dropdownMenuButton[aria-expanded="true"] {
    background: #BA8223;
    border-color: #BA8223;
    color: #fff;
}

/* ================================================================
   CONTACT PAGE: hide Principal / Support contact (CSS only, no template edit)
   ================================================================ */
.page_contact .contact.primary,
.page_contact .contact.support {
    display: none;
}

/* ================================================================
   FOOTER
   ================================================================ */
.site-footer {
    background-color: #f6f2e8;
    border-top: 3px solid #b8912f;
    padding-top: 2px;
    padding-bottom: 2px;
}
.additional-footer-info p {
    font-size: 12.5px;
    color: #6a5f42;
}
.sidebar_wrapper + .additional-footer-info {
    border-top: 2px solid #ded4b8;
    padding-top: 18px;
    margin-top: 24px;
}

.pkp_block h2.pkp_screen_reader {
    display: none;
}
.pkp_block .title {
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .1em;
    color: #7a5f16;
    text-transform: uppercase;
}
.pkp_block .content a {
    color: #8a1414;
    text-decoration: none;
    font-size: 14px;
    line-height: 1.9;
}
.pkp_block .content a:hover {
    color: #BA8223;
}

.block_make_submission_link {
    display: inline-block;
    background: #8a1414;
    color: #f6f2e8 !important;
    padding: 10px 22px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .05em;
    text-decoration: none;
}
.block_make_submission_link:hover {
    background: #BA8223;
}

/* Footer sidebar: 3-column layout (logo+submission button stacked) */
@media (min-width: 992px) {
    .sidebar_wrapper {
        display: grid;
        grid-template-columns: 1.4fr 1fr 1fr;
        column-gap: 40px;
        row-gap: 2px;
        align-items: start;
        width: 100%;
        box-sizing: border-box;
    }
    #customblock-footer-logo {
        grid-column: 1;
        grid-row: 1;
        padding-bottom: 0;
    }
    .block_make_submission {
        grid-column: 1;
        grid-row: 2;
        margin-top: 8px;
        padding-top: 0;
        padding-bottom: 0;
    }
    .block_information {
        grid-column: 2;
        grid-row: 1 / span 2;
    }
    .block_language {
        grid-column: 3;
        grid-row: 1 / span 2;
    }
}

/* ================================================================
   MOBILE / TABLET (desktop styles above stay untouched)
   ================================================================ */
@media (max-width: 991.98px) {
    /* dark nav strip: 50px side padding is too wide on small screens */
    .lower-header,
    .lower-header.is-fixed {
        padding-left: calc(50vw - 50% + 15px);
        padding-right: calc(50vw - 50% + 15px);
    }
    /* Register / Login: two compact buttons side by side */
    .upper-header .logo-wrapper,
    #user-nav-wraper {
        flex: 0 0 100%;
        width: 100%;
        max-width: 100%;
    }
    #user-nav-wraper {
        padding-left: 15px;
        padding-right: 15px;
        margin-top: 8px;
        margin-bottom: 12px;
    }
    #navigationUser {
        display: flex;
        flex-wrap: nowrap;
        justify-content: flex-start;
        width: 100%;
        gap: 8px;
        border: 0;
        margin: 0;
        padding: 0;
    }
    #navigationUser > li {
        flex: 0 0 auto;
        margin: 0;
    }
    #user-nav-wraper #navigationUser > li > a,
    #user-nav-wraper #navigationUser > li > a#user-dashboard-link {
        display: block !important;
        width: auto !important;
        min-width: 96px !important;
        box-sizing: border-box !important;
        margin: 0 !important;
        height: 32px !important;
        padding: 0 18px !important;
        line-height: 30px !important;
        text-align: center !important;
        white-space: nowrap !important;
        font-size: 13px !important;
        font-weight: 600 !important;
        letter-spacing: .02em !important;
        border-radius: 0 !important;
    }
    #user-nav-wraper #navigationUser > li > a[href*="register"] {
        background: #f6f2e8 !important;
        border: 1px solid #BA8223 !important;
        color: #7a5f16 !important;
    }
    #user-nav-wraper #navigationUser > li > a[href$="/login"],
    #user-nav-wraper #navigationUser > li > a#user-dashboard-link {
        background: #1a1610 !important;
        border: 1px solid #1a1610 !important;
        color: #f6f2e8 !important;
    }
    /* header logo: must shrink to fit the screen instead of overflowing */
    .header .logo-wrapper,
    .header .logo-wrapper .home-link {
        display: block;
        max-width: 100%;
    }
    .header .logo-wrapper img,
    .header .logo-wrapper .home-link img {
        max-width: 100%;
        height: auto;
    }
    /* burger menu stays reachable while scrolling; long menu scrolls inside itself */
    .lower-header.is-fixed {
        position: fixed;
        top: 0;
        z-index: 1030;
    }
    /* opened menu: dark full-width panel (same dark/gold look as the desktop nav) */
    #modal-on-small.nav-modal {
        position: fixed;
        top: 0;
        left: 0;
        right: auto;
        bottom: auto;
        width: 100%;
        max-width: none;
        height: 100%;
        overflow-y: auto;
        background: #1a1610;
        box-shadow: none;
    }
    #modal-on-small #primary-nav-wraper {
        background: #1a1610;
        padding: 0;
    }
    /* top row: hamburger + MENU on the left, close X on the right */
    #close-small-modal {
        display: flex;
        align-items: center;
        gap: 12px;
        float: none;
        position: static;
        width: 100%;
        box-sizing: border-box;
        padding: 16px 11px;
        background: #1a1610;
        border-bottom: 1px solid #3a3426;
        cursor: pointer;
        font-family: 'Montserrat', Arial, sans-serif;
    }
    #close-small-modal::before {
        content: "";
        order: 1;
        width: 20px;
        height: 14px;
        background: linear-gradient(#e8c877 0 2px, transparent 2px 6px, #e8c877 6px 8px, transparent 8px 12px, #e8c877 12px 14px);
    }
    #close-small-modal::after {
        content: "MENU";
        order: 2;
        color: #fff;
        font-size: 16px;
        font-weight: 700;
        letter-spacing: .12em;
    }
    #close-small-modal ion-icon {
        order: 3;
        margin-left: auto;
        font-size: 22px;
        color: #e8c877;
    }
    /* About submenu: opens inline inside the panel */
    #modal-on-small .nav-item.dropdown {
        position: static !important;
        height: auto !important;
        overflow: visible !important;
    }
    #modal-on-small .nav-item.dropdown > .dropdown-menu {
        position: static !important;
        inset: auto !important;
        top: auto !important;
        left: auto !important;
        right: auto !important;
        bottom: auto !important;
        transform: none !important;
        float: none !important;
        display: none;
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;
        height: auto !important;
        margin: 0 !important;
        padding: 0 !important;
        border: 0 !important;
        border-radius: 0 !important;
        box-shadow: none !important;
        background: #231e15;
    }
    #modal-on-small .nav-item.dropdown > .dropdown-menu.show {
        display: block;
    }
    /* menu rows: uppercase, bold, letter-spaced, cream; first row gold */
    #modal-on-small .nav-link,
    #modal-on-small .dropdown-item {
        display: block;
        font-family: 'Montserrat', Arial, sans-serif;
        font-size: 14px;
        font-weight: 700;
        line-height: 1.5;
        letter-spacing: .1em;
        text-transform: uppercase;
        text-align: left;
        color: #d8d0c0;
        padding: 17px 11px;
        white-space: normal;
        background: transparent;
        border: 0;
    }
    #modal-on-small .nav-item {
        border-bottom: 1px solid #3a3426;
    }
    #modal-on-small .nav-item:first-child .nav-link {
        color: #e8c877;
    }
    /* arrow next to About: points down, flips up when the submenu is open */
    #modal-on-small .nav-link.dropdown-toggle::after {
        display: inline-block;
        margin-left: 10px;
        vertical-align: middle;
        content: "";
        border: 0;
        width: 7px;
        height: 7px;
        border-right: 2px solid #e8c877;
        border-bottom: 2px solid #e8c877;
        transform: translateY(-3px) rotate(45deg);
        transition: transform .2s;
    }
    #modal-on-small .nav-link.dropdown-toggle[aria-expanded="true"]::after,
    #modal-on-small .nav-link.dropdown-toggle.show::after {
        transform: translateY(1px) rotate(-135deg);
    }
    #modal-on-small .nav-link.dropdown-toggle {
        cursor: pointer;
    }
    #modal-on-small .dropdown-item {
        padding-left: 28px;
        border-top: 1px solid #3a3426;
    }
    #modal-on-small .nav-link:hover,
    #modal-on-small .dropdown-item:hover,
    #modal-on-small .dropdown-item:focus {
        background: transparent;
        color: #cc9c00;
    }
    /* footer: logo lockup, submit button and Information all start at the same left edge */
    .site-footer .container-footer {
        padding-left: 15px;
        padding-right: 15px;
    }
    .sidebar_wrapper .pkp_block,
    .sidebar_wrapper .pkp_block .content {
        text-align: left;
        padding-left: 0;
        padding-right: 0;
        margin-left: 0;
        margin-right: 0;
    }
    #customblock-footer-logo,
    #customblock-footer-logo p {
        margin: 0;
        padding: 0;
        text-align: left;
    }
    #customblock-footer-logo img {
        display: block;
        max-width: 100%;
        width: auto;
        height: auto;
        margin: 0;
    }
    .block_make_submission {
        margin-top: 18px;
        padding: 0;
    }
    .block_information {
        margin-top: 30px;
        padding: 0;
    }
    .block_information .content a {
        display: block;
        font-size: 15px;
        line-height: 1.5;
        padding: 6px 0;
    }
}
@media (max-width: 767.98px) {
    /* homepage banner: the wide/thin desktop shape becomes a tiny strip on phones */
    .homepage_image {
        aspect-ratio: 3 / 1;
        background-size: cover;
        background-position: left center;
        overflow: hidden;
    }
    .homepage_image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: left center;
    }
    /* issue cover: smaller and centred */
    .description_cover {
        text-align: center;
        margin-bottom: 16px;
    }
    .description_cover .cover_image {
        max-width: 200px;
        margin: 0 auto;
    }
    /* tighter gap between articles in the list */
    .article_summary {
        margin-bottom: 16px;
    }
}
@media (max-width: 575.98px) {
    /* justified text leaves big gaps in narrow columns */
    .container-page p,
    #citationOutput .csl-entry {
        text-align: left;
    }
}