/* MIRKA SHOP CUSTOM HEADER V1.0 */
body.mirka-shop-custom-header-active {
    background: #f4efe4;
}

body.mirka-shop-custom-header-active #wpadminbar + .mirka-shop-announcement {
    margin-top: 0;
}

.mirka-shop-announcement {
    width: 100%;
    min-height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #3f4930;
    color: #f8f4ea;
    font-size: 11px;
    letter-spacing: .02em;
    text-align: center;
    position: relative;
    z-index: 100;
}

.mirka-shop-brand-header {
    width: min(1540px, calc(100% - 32px));
    margin: 0 auto;
    background: #f7f2e8;
    border-bottom: 1px solid rgba(67,72,50,.12);
    position: relative;
    z-index: 99;
}

.mirka-shop-brand-header__inner {
    min-height: 92px;
    display: grid;
    grid-template-columns: 280px 1fr 280px;
    align-items: center;
    gap: 20px;
    padding: 8px 20px;
    direction: rtl;
}

.mirka-shop-brand {
    justify-self: start;
    display: inline-flex;
    align-items: center;
    gap: 11px;
    color: #313628;
    text-decoration: none;
}

.mirka-shop-brand__circle {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    overflow: hidden;
    border: 1px solid rgba(163,137,87,.48);
    background: #e9dfcc;
    box-shadow: 0 5px 20px rgba(61,59,48,.08);
    flex: 0 0 68px;
}

.mirka-shop-brand__circle img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 50% 18%;
    transform: scale(1.06);
    display: block;
}

.mirka-shop-brand__text {
    direction: ltr;
    text-align: center;
    line-height: 1;
}

.mirka-shop-brand__text strong {
    display: block;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 18px;
    font-weight: 400;
    letter-spacing: .24em;
}

.mirka-shop-brand__text small {
    display: block;
    margin-top: 7px;
    font-size: 9px;
    letter-spacing: .34em;
}

.mirka-shop-nav {
    justify-self: center;
    display: flex;
    align-items: center;
    gap: clamp(18px, 2vw, 34px);
    direction: rtl;
}

.mirka-shop-nav a {
    position: relative;
    color: #4d4d44;
    text-decoration: none;
    font-size: 13px;
    white-space: nowrap;
    transition: color .2s ease;
}

.mirka-shop-nav a:hover,
.mirka-shop-nav a.is-active {
    color: #394328;
}

.mirka-shop-nav a.is-active::after {
    content: "";
    position: absolute;
    right: 0;
    left: 0;
    bottom: -9px;
    height: 1px;
    background: #a99368;
}

.mirka-shop-actions {
    justify-self: end;
    direction: ltr;
    display: flex;
    align-items: center;
    gap: 10px;
}

.mirka-shop-icon {
    width: 38px;
    height: 38px;
    padding: 0;
    border-radius: 50%;
    border: 1px solid rgba(178,151,99,.42);
    background: rgba(255,255,255,.35);
    display: inline-flex;
    justify-content: center;
    align-items: center;
    color: #484b3d;
    text-decoration: none;
    cursor: pointer;
    position: relative;
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.mirka-shop-icon:hover {
    transform: translateY(-2px);
    background: #fffaf1;
    box-shadow: 0 5px 15px rgba(65,63,52,.1);
}

.mirka-shop-icon svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.55;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.mirka-shop-cart__count {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 17px;
    height: 17px;
    border-radius: 20px;
    padding: 0 4px;
    background: #465032;
    color: #fff;
    border: 2px solid #f7f2e8;
    font-size: 9px;
    line-height: 13px;
    text-align: center;
}

.mirka-shop-mobile-toggle {
    display: none;
}

.mirka-shop-mobile-nav {
    border-top: 1px solid rgba(67,72,50,.1);
    padding: 10px 16px 14px;
    text-align: right;
}

.mirka-shop-mobile-nav a {
    display: block;
    padding: 9px 4px;
    color: #44483a;
    text-decoration: none;
    border-bottom: 1px solid rgba(67,72,50,.08);
}

.mirka-shop-search-panel {
    width: min(1540px, calc(100% - 32px));
    margin: 0 auto;
    background: #f7f2e8;
    border-bottom: 1px solid rgba(67,72,50,.12);
    position: relative;
    z-index: 98;
    padding: 14px 20px;
}

.mirka-shop-search-panel[hidden],
.mirka-shop-mobile-nav[hidden] {
    display: none !important;
}

.mirka-shop-search-panel form {
    display: flex;
    align-items: center;
    gap: 8px;
    max-width: 720px;
    margin: 0 auto;
    direction: rtl;
}

.mirka-shop-search-panel input {
    flex: 1;
    height: 43px;
    border: 1px solid rgba(67,72,50,.18);
    background: #fffaf2;
    padding: 0 14px;
    outline: none;
    font: inherit;
}

.mirka-shop-search-panel button[type="submit"] {
    height: 43px;
    border: 0;
    background: #414b30;
    color: #fff;
    padding: 0 20px;
    cursor: pointer;
}

.mirka-shop-search-close {
    width: 43px;
    height: 43px;
    border: 0;
    background: transparent;
    font-size: 26px;
    color: #555;
    cursor: pointer;
}

/* Kill any legacy Ahura shop header/menu remnants if another hook prints them. */
body.mirka-shop-custom-header-active > .mgsiteside > .cats-list,
body.mirka-shop-custom-header-active .top-menu,
body.mirka-shop-custom-header-active .header-mode-1,
body.mirka-shop-custom-header-active .header-mode-2,
body.mirka-shop-custom-header-active .header-mode-3,
body.mirka-shop-custom-header-active .ahura-main-header {
    display: none !important;
}

/* Hero should start immediately below our header. */
body.mirka-shop-custom-header-active .mirka-shop-page {
    margin-top: 0 !important;
}

@media (max-width: 960px) {
    .mirka-shop-brand-header__inner {
        grid-template-columns: 1fr auto;
        min-height: 78px;
        padding: 7px 12px;
    }

    .mirka-shop-nav {
        display: none;
    }

    .mirka-shop-actions {
        grid-column: 2;
        grid-row: 1;
    }

    .mirka-shop-brand {
        grid-column: 1;
        grid-row: 1;
    }

    .mirka-shop-mobile-toggle {
        display: inline-flex;
    }

    .mirka-shop-brand__circle {
        width: 56px;
        height: 56px;
        flex-basis: 56px;
    }

    .mirka-shop-brand__text strong { font-size: 15px; }
    .mirka-shop-brand__text small { font-size: 8px; }
}

@media (max-width: 600px) {
    .mirka-shop-brand-header,
    .mirka-shop-search-panel {
        width: 100%;
    }

    .mirka-shop-announcement {
        min-height: 24px;
        font-size: 9px;
    }

    .mirka-shop-brand-header__inner {
        min-height: 70px;
        padding: 6px 9px;
        gap: 8px;
    }

    .mirka-shop-brand__circle {
        width: 48px;
        height: 48px;
        flex-basis: 48px;
    }

    .mirka-shop-brand__text {
        display: none;
    }

    .mirka-shop-actions {
        gap: 6px;
    }

    .mirka-shop-icon {
        width: 34px;
        height: 34px;
    }

    .mirka-shop-icon svg {
        width: 16px;
        height: 16px;
    }
}

/* =========================================================
   MIRKA MOBILE HEADER ICON ORDER FIX
   Home / Shop / Cart visual standard
   Hamburger must be the outer-left icon
   ========================================================= */
@media (max-width: 768px) {

    .mirka-shop-actions {
        direction: ltr !important;
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: flex-start !important;
        gap: 8px !important;
    }

    .mirka-shop-search-toggle {
        order: 4 !important;
    }

    .mirka-shop-actions .mirka-account-trigger,
    .mirka-shop-actions > a:not(.mirka-shop-cart) {
        order: 3 !important;
    }

    .mirka-shop-cart {
        order: 2 !important;
    }

    .mirka-shop-mobile-toggle {
        order: 1 !important;
    }

}
