/*
Theme Name: JIYE Kadence Child
Template: kadence
Version: 1.0
*/

:root {
    --jiye-ink: #171A18;
    --jiye-green: #1F4D3A;
    --jiye-green-dark: #17392B;
    --jiye-soft: #F5F7F5;
    --jiye-line: #DDE2DF;
    --jiye-copy: #4D5350;
}

html {
    scroll-behavior: smooth;
}

body {
    color: var(--jiye-copy);
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

/* Branded global header and footer. */
.jiye-skip-link {
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 10000;
    padding: 10px 14px;
    background: #FFFFFF;
    color: var(--jiye-green-dark);
    font-weight: 700;
    text-decoration: none;
    transform: translateY(-160%);
}

.jiye-skip-link:focus {
    transform: translateY(0);
}

.jiye-site-header,
.jiye-site-header * {
    box-sizing: border-box;
}

.jiye-site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(221, 226, 223, .9);
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 1px 0 rgba(17, 21, 19, .02);
    backdrop-filter: blur(16px);
}

.jiye-site-content {
    min-height: 40vh;
}

.admin-bar .jiye-site-header {
    top: 32px;
}

.jiye-site-header-inner {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) auto minmax(180px, 1fr);
    align-items: center;
    width: min(1280px, calc(100% - 48px));
    min-height: 78px;
    margin-inline: auto;
}

.jiye-site-brand {
    justify-self: start;
}

.jiye-site-brand .custom-logo-link,
.jiye-site-wordmark {
    display: inline-flex;
    align-items: center;
    color: var(--jiye-ink) !important;
    text-decoration: none !important;
}

.jiye-site-brand .custom-logo {
    display: block;
    width: auto;
    max-width: 176px;
    max-height: 46px;
}

.jiye-site-wordmark {
    gap: 12px;
}

.jiye-site-wordmark-main {
    color: var(--jiye-green-dark);
    font-size: 27px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -.04em;
}

.jiye-site-wordmark-sub {
    max-width: 72px;
    padding-left: 12px;
    border-left: 1px solid var(--jiye-line);
    color: #66706A;
    font-size: 9px;
    font-weight: 700;
    line-height: 1.25;
    letter-spacing: .11em;
}

.jiye-primary-navigation ul {
    display: flex;
    align-items: center;
    gap: 4px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.jiye-primary-navigation a {
    position: relative;
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 10px 15px;
    color: #303632 !important;
    font-size: 14px;
    font-weight: 650;
    text-decoration: none !important;
    transition: color .18s ease;
}

.jiye-primary-navigation a::after {
    position: absolute;
    right: 15px;
    bottom: 5px;
    left: 15px;
    height: 2px;
    background: var(--jiye-green);
    content: "";
    opacity: 0;
    transform: scaleX(.35);
    transition: opacity .18s ease, transform .18s ease;
}

.jiye-primary-navigation a:hover,
.jiye-primary-navigation a.is-current {
    color: var(--jiye-green) !important;
}

.jiye-primary-navigation a:hover::after,
.jiye-primary-navigation a.is-current::after {
    opacity: 1;
    transform: scaleX(1);
}

.jiye-header-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    justify-self: end;
    gap: 10px;
    min-height: 46px;
    padding: 11px 18px;
    border: 1px solid var(--jiye-green-dark);
    border-radius: 3px;
    background: var(--jiye-green-dark);
    color: #FFFFFF !important;
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
    text-decoration: none !important;
    transition: background .18s ease, transform .18s ease;
}

.jiye-header-cta:hover {
    background: var(--jiye-green);
    transform: translateY(-1px);
}

.jiye-menu-toggle {
    display: none;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 3px solid rgba(31, 77, 58, .28);
    outline-offset: 3px;
}

.jiye-site-footer,
.jiye-site-footer * {
    box-sizing: border-box;
}

.jiye-site-footer {
    border-top: 1px solid #2D3732;
    background: #101713;
    color: #B8C2BC;
}

.jiye-site-footer-inner {
    width: min(1280px, calc(100% - 48px));
    margin-inline: auto;
}

.jiye-footer-main {
    display: grid;
    grid-template-columns: 1.35fr .72fr .9fr 1.35fr;
    gap: 54px;
    padding: 78px 0 68px;
}

.jiye-footer-wordmark {
    display: inline-block;
    color: #FFFFFF !important;
    font-size: 34px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -.045em;
    text-decoration: none !important;
}

.jiye-footer-company-name {
    display: block;
    max-width: 320px;
    margin-top: 16px;
    color: #FFFFFF;
    font-size: 13px;
    font-weight: 650;
    line-height: 1.55;
}

.jiye-footer-brand p {
    max-width: 320px;
    margin: 22px 0 24px;
    color: #B8C2BC;
    font-size: 14px;
    line-height: 1.75;
}

.jiye-footer-brand > span,
.jiye-footer-links > p,
.jiye-footer-cta > p {
    color: #83928A;
    font-size: 10px;
    font-weight: 700;
    line-height: 1.4;
    letter-spacing: .14em;
    text-transform: uppercase;
}

.jiye-footer-links {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 13px;
}

.jiye-footer-links > p,
.jiye-footer-cta > p {
    margin: 4px 0 12px;
}

.jiye-footer-links a {
    color: #E8ECE9 !important;
    font-size: 14px;
    line-height: 1.5;
    text-decoration: none !important;
    transition: color .18s ease, transform .18s ease;
}

.jiye-footer-links a:hover {
    color: #FFFFFF !important;
    transform: translateX(3px);
}

.jiye-footer-contact > span {
    color: #D6DDD9;
    font-size: 14px;
    line-height: 1.55;
}

.jiye-footer-contact .jiye-footer-contact-label {
    margin-bottom: -8px;
    color: #83928A;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.jiye-footer-contact a[href^="https://wa.me/"] {
    margin-top: 8px;
    color: #FFFFFF !important;
    font-weight: 700;
}

.jiye-footer-cta {
    padding-left: 36px;
    border-left: 1px solid #303A35;
}

.jiye-footer-cta h2 {
    max-width: 360px;
    margin: 0;
    color: #FFFFFF;
    font-size: clamp(24px, 2.2vw, 32px);
    line-height: 1.18;
    letter-spacing: -.025em;
}

.jiye-footer-cta a {
    display: inline-flex;
    align-items: center;
    gap: 28px;
    margin-top: 28px;
    padding-bottom: 8px;
    border-bottom: 1px solid #718078;
    color: #FFFFFF !important;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none !important;
}

.jiye-footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    padding: 24px 0 28px;
    border-top: 1px solid #303A35;
    color: #83928A;
    font-size: 12px;
    line-height: 1.6;
}

.jiye-footer-bottom p {
    margin: 0;
}

.jiye-footer-bottom > div {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 12px 24px;
}

.jiye-footer-bottom a {
    color: #B8C2BC !important;
    text-decoration: none !important;
}

@media (max-width: 1080px) {
    .jiye-site-header-inner {
        grid-template-columns: minmax(160px, 1fr) auto minmax(150px, 1fr);
    }

    .jiye-primary-navigation a {
        padding-inline: 10px;
    }

    .jiye-footer-main {
        grid-template-columns: 1.25fr .75fr .9fr;
    }

    .jiye-footer-cta {
        grid-column: 1 / -1;
        padding: 34px 0 0;
        border-top: 1px solid #303A35;
        border-left: 0;
    }
}

@media (max-width: 960px) {
    body.jiye-menu-open {
        overflow: hidden;
    }

    .jiye-site-header-inner {
        position: relative;
        display: flex;
        justify-content: space-between;
        min-height: 70px;
    }

    .jiye-menu-toggle {
        display: inline-flex;
        align-items: center;
        gap: 10px;
        min-width: 44px;
        min-height: 44px;
        padding: 8px 0 8px 12px;
        border: 0;
        background: transparent;
        color: var(--jiye-ink);
        font: inherit;
        cursor: pointer;
    }

    .jiye-menu-toggle-label {
        font-size: 11px;
        font-weight: 700;
        letter-spacing: .1em;
        text-transform: uppercase;
    }

    .jiye-menu-toggle-icon {
        position: relative;
        display: block;
        width: 24px;
        height: 16px;
    }

    .jiye-menu-toggle-icon span {
        position: absolute;
        right: 0;
        width: 24px;
        height: 2px;
        background: currentColor;
        transition: top .2s ease, transform .2s ease;
    }

    .jiye-menu-toggle-icon span:first-child {
        top: 3px;
    }

    .jiye-menu-toggle-icon span:last-child {
        top: 11px;
    }

    .jiye-site-header.is-menu-open .jiye-menu-toggle-icon span:first-child {
        top: 7px;
        transform: rotate(45deg);
    }

    .jiye-site-header.is-menu-open .jiye-menu-toggle-icon span:last-child {
        top: 7px;
        transform: rotate(-45deg);
    }

    .jiye-primary-navigation {
        position: absolute;
        top: 100%;
        right: -24px;
        left: -24px;
        max-height: calc(100vh - 70px);
        overflow: auto;
        padding: 18px 24px 28px;
        border-top: 1px solid var(--jiye-line);
        border-bottom: 1px solid var(--jiye-line);
        background: #FFFFFF;
        box-shadow: 0 24px 40px rgba(17, 21, 19, .12);
        opacity: 0;
        pointer-events: none;
        transform: translateY(-10px);
        transition: opacity .18s ease, transform .18s ease;
    }

    .jiye-site-header.is-menu-open .jiye-primary-navigation {
        opacity: 1;
        pointer-events: auto;
        transform: translateY(0);
    }

    .jiye-primary-navigation ul {
        display: grid;
        gap: 0;
    }

    .jiye-primary-navigation a {
        display: flex;
        min-height: 54px;
        padding: 12px 4px;
        border-bottom: 1px solid #E9ECEA;
        font-size: 18px;
    }

    .jiye-primary-navigation a::after {
        display: none;
    }

    .jiye-header-cta {
        display: none;
    }
}

@media (max-width: 720px) {
    .admin-bar .jiye-site-header {
        top: 46px;
    }

    .jiye-site-header-inner,
    .jiye-site-footer-inner {
        width: min(100% - 40px, 1280px);
    }

    .jiye-site-wordmark-sub {
        display: none;
    }

    .jiye-site-wordmark-main {
        font-size: 25px;
    }

    .jiye-footer-main {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 42px 30px;
        padding: 58px 0 48px;
    }

    .jiye-footer-brand,
    .jiye-footer-cta {
        grid-column: 1 / -1;
    }

    .jiye-footer-cta {
        padding-top: 30px;
    }

    .jiye-footer-bottom {
        align-items: flex-start;
        flex-direction: column;
    }

    .jiye-footer-bottom > div {
        justify-content: flex-start;
    }
}

@media (max-width: 420px) {
    .jiye-menu-toggle-label {
        display: none;
    }

    .jiye-footer-main {
        grid-template-columns: 1fr;
    }

    .jiye-footer-brand,
    .jiye-footer-cta {
        grid-column: auto;
    }
}

/* ==========================================================
   JIYE PRODUCTS ARCHIVE
   Used by archive-jiye_product.php
========================================================== */

.jiye-products-page {
    background: #FFFFFF;
    color: #171A18;
}

.jiye-products-page *,
.jiye-products-page *::before,
.jiye-products-page *::after {
    box-sizing: border-box;
}

.jiye-products-container {
    width: min(1200px, calc(100% - 48px));
    margin: 0 auto;
}


/* ==========================================================
   HERO
========================================================== */

.jiye-products-hero {
    padding: 84px 0 78px;
    border-bottom: 1px solid #E4E8E5;
    background:
        linear-gradient(
            110deg,
            #F5F7F5 0%,
            #F5F7F5 68%,
            #EEF2EF 100%
        );
}

.jiye-products-eyebrow {
    margin: 0 0 18px;
    color: #1F4D3A;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: .18em;
}

.jiye-products-hero h1 {
    max-width: 820px;
    margin: 0;
    color: #171A18;
    font-size: clamp(44px, 4.2vw, 64px);
    font-weight: 700;
    line-height: 1.04;
    letter-spacing: -.035em;
}

.jiye-products-lead {
    max-width: 760px;
    margin: 24px 0 0;
    color: #4D5350;
    font-size: 18px;
    line-height: 1.7;
}


/* ==========================================================
   FILTER TOOLBAR
========================================================== */

.jiye-products-toolbar {
    position: relative;
    z-index: 3;
    border-bottom: 1px solid #E1E5E2;
    background: #FFFFFF;
}

.jiye-pattern-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 20px 0;
}

.jiye-pattern-filters a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 10px 18px;
    border: 1px solid #E1E5E2;
    border-radius: 3px;
    background: #F5F7F5;
    color: #171A18 !important;
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    text-decoration: none !important;
    white-space: nowrap;
    transition:
        background .18s ease,
        color .18s ease,
        border-color .18s ease,
        transform .18s ease;
}

.jiye-pattern-filters a:hover {
    transform: translateY(-1px);
    border-color: #BFC9C3;
    background: #EEF2EF;
}

.jiye-pattern-filters a.is-active {
    border-color: #17392B;
    background: #17392B;
    color: #FFFFFF !important;
}


/* ==========================================================
   PRODUCT SECTION / GRID
========================================================== */

.jiye-products-section {
    padding: 54px 0 96px;
}

.jiye-products-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 30px 20px;
}


/* ==========================================================
   PRODUCT CARD
========================================================== */

.jiye-product-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    border: 1px solid #E1E5E2;
    border-radius: 4px;
    background: #FFFFFF;
    transition:
        transform .22s ease,
        box-shadow .22s ease,
        border-color .22s ease;
}

.jiye-product-card:hover {
    transform: translateY(-5px);
    border-color: #CDD4D0;
    box-shadow: 0 18px 42px rgba(17, 21, 19, .09);
}


/* IMAGE */

.jiye-product-media {
    position: relative;
    overflow: hidden;
    background: #F3F5F4;
}

.jiye-product-image {
    display: block;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    background: #F3F5F4;
    text-decoration: none !important;
}

.jiye-product-image img {
    display: block;
    width: 100%;
    height: 100%;
    margin: 0;
    object-fit: cover;
    transition: transform .4s ease;
}

.jiye-product-card:hover .jiye-product-image img {
    transform: scale(1.035);
}

.jiye-product-no-image {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    min-height: 220px;
    color: #747B77;
    font-size: 14px;
}


/* PATTERN BADGE */

.jiye-product-pattern {
    position: absolute;
    left: 14px;
    bottom: 14px;
    max-width: calc(100% - 28px);
    padding: 6px 10px;
    overflow: hidden;
    border-radius: 3px;
    background: rgba(255, 255, 255, .94);
    box-shadow: 0 2px 10px rgba(17, 21, 19, .08);
    color: #17392B;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.25;
    text-overflow: ellipsis;
    white-space: nowrap;
}


/* SAMPLE BADGE */

.jiye-product-sample {
    position: absolute;
    top: 14px;
    right: 14px;
    padding: 6px 9px;
    border-radius: 3px;
    background: #17392B;
    color: #FFFFFF;
    font-size: 10px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: .03em;
}


/* CONTENT */

.jiye-product-content {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 22px 22px 24px;
}

.jiye-product-code {
    margin: 0 0 6px;
    color: #747B77;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.4;
    letter-spacing: .09em;
    text-transform: uppercase;
}

.jiye-product-title {
    margin: 0 0 11px;
    color: #171A18;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.3;
}

.jiye-product-title a {
    color: #171A18 !important;
    text-decoration: none !important;
}

.jiye-product-title a:hover {
    color: #1F4D3A !important;
}

.jiye-product-excerpt {
    display: -webkit-box;
    min-height: 46px;
    margin: 0 0 22px;
    overflow: hidden;
    color: #5D625F;
    font-size: 14px;
    line-height: 1.65;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.jiye-product-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: auto;
    padding-top: 17px;
    border-top: 1px solid #EDF0EE;
    color: #17392B !important;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.4;
    text-decoration: none !important;
}

.jiye-product-link span:last-child {
    font-size: 17px;
    transition: transform .2s ease;
}

.jiye-product-link:hover span:last-child {
    transform: translateX(5px);
}


/* ==========================================================
   PAGINATION
========================================================== */

.jiye-product-pagination {
    margin-top: 54px;
}

.jiye-product-pagination ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 7px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.jiye-product-pagination li {
    margin: 0;
}

.jiye-product-pagination a,
.jiye-product-pagination span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 11px;
    border: 1px solid #DDE2DF;
    border-radius: 3px;
    background: #FFFFFF;
    color: #171A18;
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
    text-decoration: none !important;
}

.jiye-product-pagination a:hover {
    border-color: #17392B;
    color: #17392B;
}

.jiye-product-pagination .current {
    border-color: #17392B;
    background: #17392B;
    color: #FFFFFF;
}


/* ==========================================================
   EMPTY STATE
========================================================== */

.jiye-products-empty {
    max-width: 620px;
    margin: 0 auto;
    padding: 72px 24px;
    text-align: center;
}


/* ==========================================================
   CLOSING CTA
========================================================== */

.jiye-products-support {
    padding: 72px 0;
    background: #17392B;
}

.jiye-products-support-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 64px;
    align-items: center;
}

.jiye-products-support h2 {
    max-width: 760px;
    margin: 0;
    color: #FFFFFF;
    font-size: clamp(30px, 3vw, 42px);
    line-height: 1.15;
    letter-spacing: -.025em;
}

.jiye-products-support p {
    max-width: 720px;
    margin: 16px 0 0;
    color: #DDE2DF;
    line-height: 1.7;
}

.jiye-products-support a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 50px;
    padding: 13px 24px;
    border: 1px solid #FFFFFF;
    border-radius: 3px;
    background: #FFFFFF;
    color: #17392B !important;
    font-weight: 700;
    text-decoration: none !important;
    white-space: nowrap;
    transition: background .2s ease, color .2s ease;
}

.jiye-products-support a:hover {
    background: transparent;
    color: #FFFFFF !important;
}

.jiye-products-empty h2 {
    margin: 0 0 10px;
    color: #171A18;
}

.jiye-products-empty p {
    margin: 0 0 18px;
    color: #747B77;
}

.jiye-products-reset {
    color: #17392B !important;
    font-weight: 700;
    text-decoration: none !important;
}


/* ==========================================================
   RESPONSIVE
========================================================== */

@media (max-width: 1100px) {

    .jiye-products-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

}

@media (max-width: 820px) {

    .jiye-products-hero {
        padding: 66px 0 62px;
    }

    .jiye-products-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .jiye-products-support-grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }

}

@media (max-width: 600px) {

    .jiye-products-container {
        width: min(100% - 40px, 1200px);
    }

    .jiye-products-hero {
        padding: 54px 0 50px;
    }

    .jiye-products-hero h1 {
        font-size: clamp(35px, 10vw, 40px);
    }

    .jiye-products-lead {
        margin-top: 20px;
        font-size: 16px;
    }

    .jiye-pattern-filters {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding: 16px 0 18px;
        scrollbar-width: none;
    }

    .jiye-pattern-filters::-webkit-scrollbar {
        display: none;
    }

    .jiye-pattern-filters a {
        flex: 0 0 auto;
    }

    .jiye-products-section {
        padding: 38px 0 72px;
    }

    .jiye-products-grid {
        grid-template-columns: 1fr;
        gap: 22px;
    }

    .jiye-products-support {
        padding: 58px 0;
    }

    .jiye-product-excerpt {
        min-height: 0;
    }

}
