:root {
    --mc-header-bg: #2f6b3f;
    --mc-header-surface: #f1e4bd;
    --mc-header-line: #173c27;
    --mc-header-text: #fffdf3;
    --mc-header-muted: #d2dec9;
    --mc-header-accent: #f4c451;
    --mc-header-grass: #69b84a;
    --mc-header-oak: #d8ad67;
    --mc-header-stone: #cbd0c4;
}

.mc-site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
    min-height: 84px;
    color: var(--mc-header-text);
    background: var(--mc-header-bg);
    border-bottom: 3px solid var(--mc-header-line);
    box-shadow: 0 5px 0 #8a633e;
}

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

@media screen and (max-width: 782px) {
    body.admin-bar .mc-site-header {
        top: 46px;
    }
}

.mc-site-header::before {
    position: absolute;
    inset: 0 0 auto;
    height: 8px;
    content: "";
    background:
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.07) 0 6px, transparent 6px 12px),
        linear-gradient(180deg, #91dc64 0, var(--mc-header-grass) 54%, #568c36 55%, #3f6d2d 100%);
    border-bottom: 2px solid #37682a;
}

.mc-header-inner {
    width: min(1440px, calc(100% - 48px));
    min-height: 84px;
    margin: 0 auto;
    padding-top: 8px;
    display: grid;
    grid-template-columns: minmax(250px, auto) 1fr auto;
    align-items: center;
    gap: clamp(18px, 2.2vw, 34px);
}

.mc-brand,
.mc-brand:hover,
.mc-brand:focus {
    display: inline-flex;
    align-items: center;
    gap: 13px;
    width: max-content;
    color: var(--mc-header-text);
    text-decoration: none;
}

.mc-brand-mark {
    position: relative;
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    background: #69b84a;
    border: 2px solid #173c27;
    border-radius: 3px;
    box-shadow: 3px 3px 0 #765438;
}

.mc-brand-mark::before {
    position: absolute;
    top: 4px;
    left: 3px;
    width: 3px;
    height: 3px;
    content: "";
    background: #173c27;
    box-shadow: 7px 0 #173c27;
}

.mc-brand-mark::after {
    position: absolute;
    right: 4px;
    bottom: 3px;
    left: 4px;
    height: 3px;
    content: "";
    background: #173c27;
}

.mc-brand-copy {
    display: flex;
    flex-direction: column;
}

.mc-brand-name,
.mc-brand-tagline {
    font-family: "Press Start 2P", monospace;
}

.mc-brand-name {
    font-size: clamp(13px, 1.15vw, 17px);
    line-height: 1.12;
    letter-spacing: -0.025em;
}

.mc-brand-tagline {
    margin-top: 4px;
    color: var(--mc-header-muted);
    font-size: 8px;
    line-height: 1.1;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.mc-primary-nav {
    justify-self: center;
}

.mc-menu {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(12px, 1.45vw, 22px);
    margin: 0;
    padding: 0;
    list-style: none;
}

.mc-menu li {
    margin: 0;
}

.mc-menu a {
    position: relative;
    display: block;
    padding: 31px 0 27px;
    color: #e2eadb;
    font-family: "Manrope", sans-serif;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.035em;
    text-transform: uppercase;
    text-decoration: none;
    white-space: nowrap;
    transition: color 160ms ease;
}

.mc-menu a::after {
    position: absolute;
    right: 0;
    bottom: 19px;
    left: 0;
    height: 2px;
    content: "";
    background: var(--mc-header-accent);
    transform: scaleX(0);
    transform-origin: center;
    transition: transform 160ms ease;
}

.mc-menu a:hover,
.mc-menu a:focus-visible,
.mc-menu .current-menu-item > a,
.mc-menu .current_page_item > a {
    color: #fff;
}

.mc-menu a:hover::after,
.mc-menu a:focus-visible::after,
.mc-menu .current-menu-item > a::after,
.mc-menu .current_page_item > a::after {
    transform: scaleX(1);
}

.mc-header-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
}

.mc-icon-button,
.mc-menu-toggle {
    border: 2px solid var(--mc-header-line);
    border-radius: 6px;
    background: #4b8255;
    box-shadow: 0 3px 0 var(--mc-header-line);
    transition: border-color 160ms ease, transform 160ms ease, background-color 160ms ease;
}

.mc-icon-button,
.mc-menu-toggle {
    position: relative;
    width: 46px;
    height: 46px;
    padding: 0;
    display: inline-grid;
    place-items: center;
    color: #fffdf3;
    background: #4b8255;
}

.mc-icon-button svg {
    width: 21px;
    height: 21px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
}

.mc-icon-button:hover,
.mc-menu-toggle:hover {
    color: #fff;
    border-color: var(--mc-header-accent);
    transform: translateY(-1px);
}

.mc-cart-count {
    position: absolute;
    top: -7px;
    right: -4px;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    display: grid;
    place-items: center;
    color: #2d351d;
    background: var(--mc-header-accent);
    border: 2px solid var(--mc-header-line);
    border-radius: 999px;
    font: 800 11px/1 "Manrope", sans-serif;
}

.mc-cart-count.is-empty {
    display: none;
}

body.mc-cart-open {
    overflow: hidden;
}

.mc-cart-overlay {
    position: fixed;
    inset: 0;
    z-index: 1001;
    width: 100%;
    height: 100%;
    padding: 0;
    visibility: hidden;
    opacity: 0;
    background: rgba(20, 35, 23, 0.68);
    border: 0;
    transition: opacity 240ms ease, visibility 240ms ease;
    cursor: pointer;
}

.mc-cart-overlay:hover,
.mc-cart-overlay:focus,
.mc-cart-overlay:focus-visible,
.mc-cart-overlay:active {
    background: rgba(20, 35, 23, 0.68);
    border: 0;
    outline: 0;
    box-shadow: none;
}

.mc-cart-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 1002;
    width: min(430px, calc(100vw - 24px));
    padding: 0;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    color: #263c2c;
    background: #eadfbd;
    border-left: 4px solid var(--mc-header-line);
    box-shadow: -8px 0 0 #8a633e;
    visibility: hidden;
    transform: translateX(105%);
    transition: transform 280ms cubic-bezier(0.22, 1, 0.36, 1), visibility 280ms ease;
}

.mc-site-header.is-cart-open .mc-cart-overlay {
    visibility: visible;
    opacity: 1;
}

.mc-site-header.is-cart-open .mc-cart-drawer {
    visibility: visible;
    transform: translateX(0);
}

.mc-cart-drawer::before {
    position: absolute;
    inset: 0 auto 0 0;
    width: 4px;
    content: "";
    background: var(--mc-header-accent);
}

.mc-cart-drawer-head {
    min-height: 90px;
    padding: 25px 24px 19px 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    background: var(--mc-header-bg);
    border-bottom: 3px solid var(--mc-header-line);
}

.mc-cart-eyebrow {
    display: block;
    margin-bottom: 8px;
    color: #ffe08a;
    font: 700 10px/1 "Manrope", sans-serif;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.mc-cart-drawer h2 {
    margin: 0;
    color: #fff;
    font: 400 18px/1.2 "Press Start 2P", monospace;
    text-transform: uppercase;
}

.mc-cart-close {
    width: 42px;
    height: 42px;
    flex: 0 0 auto;
    padding: 0;
    display: grid;
    place-items: center;
    color: #eaf2fb;
    background: #4b8255;
    border: 2px solid var(--mc-header-line);
    border-radius: 6px;
    cursor: pointer;
}

.mc-cart-close:hover,
.mc-cart-close:focus-visible {
    color: #fff;
    border-color: var(--mc-header-accent);
}

.mc-cart-close svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-width: 1.8;
}

.mc-cart-scroll {
    min-height: 0;
    padding: 22px 24px 28px 28px;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.mc-cart-drawer .woocommerce-mini-cart {
    margin: 0;
    padding: 0;
    display: grid;
    gap: 12px;
    list-style: none;
}

.mc-cart-drawer .woocommerce-mini-cart-item {
    position: relative;
    min-height: 82px;
    margin: 0;
    padding: 13px 38px 13px 84px;
    color: #263c2c;
    background: #fff8df;
    border: 2px solid #765438;
    border-radius: 6px;
    font: 700 14px/1.35 "Manrope", sans-serif;
}

.mc-cart-drawer .woocommerce-mini-cart-item > a:not(.remove) {
    color: #263c2c;
    text-decoration: none;
}

.mc-cart-drawer .woocommerce-mini-cart-item img {
    position: absolute;
    top: 12px;
    left: 12px;
    width: 56px;
    height: 56px;
    margin: 0;
    object-fit: cover;
    border: 2px solid #765438;
    border-radius: 4px;
}

.mc-cart-drawer .woocommerce-mini-cart-item .remove {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 24px;
    height: 24px;
    display: grid;
    place-items: center;
    color: #765438 !important;
    background: #f1e4bd !important;
    border: 2px solid #765438;
    border-radius: 3px;
    font: 18px/1 sans-serif;
    text-decoration: none;
}

.mc-cart-drawer .woocommerce-mini-cart-item .remove:hover {
    color: #fff !important;
    border-color: #d76565;
}

.mc-cart-drawer .quantity {
    display: block;
    margin-top: 8px;
    color: #66715e;
    font-weight: 600;
}

.mc-cart-drawer .woocommerce-mini-cart__total {
    margin: 20px 0 12px;
    padding: 16px 0 0;
    display: flex;
    justify-content: space-between;
    gap: 16px;
    color: #263c2c;
    border-top: 2px solid #765438;
    font: 700 15px/1.4 "Manrope", sans-serif;
}

.mc-cart-drawer .woocommerce-mini-cart__buttons {
    margin: 0;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.mc-cart-drawer .woocommerce-mini-cart__buttons .button {
    min-height: 46px;
    padding: 0 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #f2f7fc;
    background: #87613f;
    border: 2px solid #513922;
    border-radius: 5px;
    box-shadow: 0 3px 0 #513922;
    font: 800 11px/1.2 "Manrope", sans-serif;
    letter-spacing: 0.04em;
    text-align: center;
    text-decoration: none;
    text-transform: uppercase;
}

.mc-cart-drawer .woocommerce-mini-cart__buttons .checkout {
    color: #26351f;
    background: var(--mc-header-accent);
    border-color: #9a6f1e;
    box-shadow: 0 3px 0 #9a6f1e;
}

.mc-cart-drawer .woocommerce-mini-cart__empty-message {
    margin: 0;
    padding: 42px 24px;
    color: #52634f;
    background: #fff8df;
    border: 2px dashed #765438;
    border-radius: 6px;
    font: 600 14px/1.6 "Manrope", sans-serif;
    text-align: center;
}

.mc-menu-toggle {
    display: none;
    grid-template-rows: repeat(3, 2px);
    align-content: center;
    gap: 5px;
    cursor: pointer;
}

.mc-menu-toggle span {
    width: 19px;
    height: 2px;
    background: currentColor;
    transition: transform 160ms ease, opacity 160ms ease;
}

.mc-menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.mc-menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.mc-menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mc-brand:focus-visible,
.mc-menu a:focus-visible,
.mc-icon-button:focus-visible,
.mc-menu-toggle:focus-visible {
    outline: 2px solid var(--mc-header-accent);
    outline-offset: 3px;
}

@media (max-width: 1180px) {
    .mc-header-inner {
        grid-template-columns: minmax(225px, auto) 1fr auto;
        gap: 18px;
    }

    .mc-menu { gap: 12px; }
    .mc-menu a { font-size: 11px; }
    .mc-account { display: none; }
}

@media (max-width: 960px) {
    .mc-site-header,
    .mc-header-inner {
        min-height: 76px;
    }

    .mc-header-inner {
        width: min(100% - 32px, 1440px);
        grid-template-columns: minmax(0, 1fr) auto;
    }

    .mc-menu-toggle { display: inline-grid; }
    .mc-account { display: inline-grid; }

    .mc-primary-nav {
        position: absolute;
        top: 100%;
        right: 16px;
        left: 16px;
        display: none;
        padding: 10px;
        background: #eadfbd;
        border: 2px solid var(--mc-header-line);
        border-top: 4px solid var(--mc-header-accent);
        border-radius: 0 0 6px 6px;
        box-shadow: 6px 6px 0 #8a633e;
    }

    .mc-primary-nav.is-open { display: block; }

    .mc-menu {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 4px;
    }

    .mc-menu a {
        padding: 15px 14px;
        color: #263c2c;
        border: 1px solid transparent;
        border-radius: 3px;
        font-size: 12px;
    }

    .mc-menu a::after { display: none; }
    .mc-menu a:hover,
    .mc-menu a:focus-visible,
    .mc-menu .current-menu-item > a {
        color: #263c2c;
        border-color: #9a6f1e;
        background: #f8cd62;
    }
}

@media (max-width: 560px) {
    .mc-header-inner { width: calc(100% - 24px); }
    .mc-brand { gap: 10px; }
    .mc-brand-name { font-size: 11px; }
    .mc-brand-tagline { font-size: 7px; }
    .mc-header-actions { gap: 8px; }
    .mc-icon-button, .mc-menu-toggle { width: 42px; height: 42px; }
    .mc-primary-nav { right: 12px; left: 12px; }
    .mc-cart-drawer { width: calc(100vw - 12px); }
    .mc-cart-drawer-head { padding-right: 18px; padding-left: 22px; }
    .mc-cart-scroll { padding-right: 18px; padding-left: 22px; }
}

@media (max-width: 400px) {
    .mc-site-header,
    .mc-header-inner {
        min-height: 72px;
    }

    .mc-header-inner {
        width: calc(100% - 20px);
        gap: 8px;
    }

    .mc-brand {
        gap: 8px;
    }

    .mc-brand-mark {
        width: 16px;
        height: 16px;
        box-shadow: 2px 2px 0 #765438;
    }

    .mc-brand-mark::before {
        top: 3px;
        left: 2px;
        box-shadow: 7px 0 #173c27;
    }

    .mc-brand-name { font-size: 10px; }
    .mc-brand-tagline { font-size: 6px; }
    .mc-header-actions { gap: 5px; }

    .mc-icon-button,
    .mc-menu-toggle {
        width: 36px;
        height: 36px;
        box-shadow: 0 2px 0 var(--mc-header-line);
    }

    .mc-icon-button svg {
        width: 18px;
        height: 18px;
    }

    .mc-menu-toggle span {
        width: 17px;
    }

    .mc-cart-count {
        top: -6px;
        right: -5px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .mc-site-header *,
    .mc-site-header *::before,
    .mc-site-header *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}
