/* YSAN_DIRECT_V24_CSS */
:root {
    --ysan-teal: #07545c;
    --ysan-gold: #d6a85a;
}

.pkp_structure_head {
    min-height: 0 !important;
    background: #fff !important;
    border-bottom: 3px solid var(--ysan-gold) !important;
}

.pkp_site_name_wrapper,
.pkp_site_name {
    min-height: 0 !important;
    padding-top: 4px !important;
    padding-bottom: 4px !important;
}

.pkp_site_name img {
    max-height: 60px !important;
    width: auto !important;
}

/* Independent navigation outside the clipped OJS header */
.ysan-direct-nav {
    position: relative;
    z-index: 500;
    background: #064850;
    color: #fff;
    box-shadow: 0 5px 16px #102c3630;
}

.ysan-direct-nav-inner {
    max-width: 1200px;
    margin: auto;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 11px 17px;
}

.ysan-direct-brand {
    color: #fff !important;
    font-weight: 700;
    white-space: nowrap;
    text-decoration: none !important;
}

.ysan-direct-links {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 5px;
    margin-left: auto;
}

.ysan-direct-links a,
.ysan-direct-search {
    color: #fff !important;
    text-decoration: none !important;
    padding: 9px 10px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
}

.ysan-direct-links a:hover,
.ysan-direct-links a:focus-visible,
.ysan-direct-search:hover {
    background: #ffffff24;
}

.ysan-direct-search {
    white-space: nowrap;
    margin-left: auto;
}

.ysan-direct-toggle {
    display: none;
    align-items: center;
    gap: 8px;
    padding: 10px 15px;
    border: 1px solid #ffffff80;
    border-radius: 6px;
    background: transparent;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.ysan-direct-toggle:focus-visible,
.ysan-direct-nav a:focus-visible {
    outline: 3px solid var(--ysan-gold);
    outline-offset: 2px;
}

/* Adire-inspired footer */
.ysan-direct-footer {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    background: linear-gradient(110deg,#072e39,#08616a);
    color: #fff;
    padding: 35px 18px;
}

.ysan-direct-footer::before {
    content: "";
    position: absolute;
    inset: -40px;
    z-index: -1;
    pointer-events: none;
    opacity: .23;
    background-image:
        repeating-linear-gradient(
            45deg,
            transparent 0 31px,
            #dfbd7e 32px 33px,
            transparent 34px 65px
        ),
        repeating-linear-gradient(
            135deg,
            transparent 0 39px,
            #bce2e0 40px 41px,
            transparent 42px 79px
        );
    transform: translate(
        var(--adire-x,0px),
        var(--adire-y,0px)
    );
    transition: transform .32s ease-out;
}

.ysan-direct-footer-content {
    position: relative;
    max-width: 1120px;
    margin: auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 28px;
}

.ysan-direct-footer h2,
.ysan-direct-footer h3 {
    color: #fff !important;
    margin: 0 0 10px;
}

.ysan-direct-footer a {
    color: #fff !important;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.ysan-direct-footer p {
    color: #ecf5f5;
    line-height: 1.7;
}

.ysan-direct-band {
    position: relative;
    overflow: hidden;
    margin: 28px 0;
    padding: 24px;
    background: linear-gradient(110deg,#07515a,#137c86);
    border-left: 5px solid var(--ysan-gold);
    color: #fff;
}

.ysan-direct-band::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: .17;
    background: repeating-linear-gradient(
        45deg,
        transparent 0 24px,
        #fff 25px 26px,
        transparent 27px 49px
    );
}

.ysan-direct-band a {
    color: #ffe4b1 !important;
}

/* Mobile and tablet */
@media (max-width:900px) {
    .pkp_structure_head {
        overflow: visible !important;
    }

    .pkp_site_name_wrapper {
        height: auto !important;
        min-height: 68px !important;
        padding: 8px 12px !important;
    }

    .pkp_site_name img {
        max-height: 48px !important;
    }

    .ysan-direct-nav-inner {
        flex-wrap: wrap;
        gap: 8px;
        padding: 9px 12px;
    }

    .ysan-direct-toggle {
        display: inline-flex;
    }

    .ysan-direct-search {
        margin-left: auto;
    }

    .ysan-direct-brand {
        display: none;
    }

    .ysan-direct-links {
        display: none;
        flex: 0 0 100%;
        width: 100%;
        margin: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 4px 0 7px;
    }

    .ysan-direct-nav[open] .ysan-direct-links {
        display: flex;
    }

    .ysan-direct-links a {
        padding: 13px 10px;
        border-top: 1px solid #ffffff30;
    }

    .ysan-direct-footer-content {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .ysan-direct-footer {
        padding: 28px 16px;
    }
}

@media (prefers-reduced-motion:reduce) {
    .ysan-direct-footer::before {
        transition: none;
        transform: none !important;
    }
}

/* YSAN_EDITORIAL_MASTHEAD_V25 */

/* Institutional masthead */
.pkp_structure_head {
    position: relative !important;
    min-height: 164px !important;
    background:
        linear-gradient(
            90deg,
            #ffffff 0%,
            #ffffff 43%,
            rgba(241,249,248,.92) 68%,
            rgba(219,239,235,.80) 100%
        ) !important;
    border-top: 4px solid #00636b !important;
    border-bottom: 0 !important;
    overflow: hidden;
}

.pkp_structure_head::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 38%;
    height: 100%;
    background:
        linear-gradient(
            90deg,
            rgba(255,255,255,1),
            rgba(255,255,255,.2)
        ),
        url("/public/ysan-brand/journal-masthead.jpg")
        center / cover no-repeat;
    opacity: .27;
    pointer-events: none;
}

.pkp_structure_head .pkp_site_name_wrapper {
    position: relative;
    z-index: 1;
    min-height: 154px !important;
    max-width: 1160px;
    margin: 0 auto;
    padding: 22px 20px !important;
    display: flex;
    align-items: center;
    box-sizing: border-box;
}

.pkp_structure_head .pkp_site_name {
    margin: 0 !important;
    padding: 0 !important;
}

.pkp_structure_head .pkp_site_name img {
    max-height: 75px !important;
    width: auto !important;
}

.pkp_structure_head .pkp_site_name_wrapper::after {
    content: "LANGUAGE  ·  CULTURE  ·  SCHOLARSHIP";
    margin-left: auto;
    max-width: 340px;
    padding-left: 24px;
    border-left: 3px solid #cba05b;
    font-weight: 700;
    letter-spacing: .15em;
    font-size: 12px;
    line-height: 1.7;
    color: #12616a;
    text-align: right;
}

/* One footer, with the existing OJS footer content */
.pkp_structure_footer_wrapper {
    background:
        linear-gradient(120deg,#082d39,#07545c) !important;
    border-top: 4px solid #d1a459;
}

@media (max-width: 900px) {
    .pkp_structure_head {
        min-height: 76px !important;
    }

    .pkp_structure_head .pkp_site_name_wrapper {
        min-height: 76px !important;
        height: auto !important;
        padding: 10px 14px !important;
    }

    .pkp_structure_head .pkp_site_name img {
        max-height: 52px !important;
    }

    .pkp_structure_head .pkp_site_name_wrapper::after {
        display: none !important;
    }
}

@media (max-width: 480px) {
    .pkp_structure_head {
        min-height: 68px !important;
    }

    .pkp_structure_head .pkp_site_name_wrapper {
        min-height: 68px !important;
    }

    .pkp_structure_head::before {
        opacity: .12;
    }
}
