/* Yaran Market shared shell — v3.1 */
:root{--ymc-shell-red:#ef3b2d;--ymc-shell-dark:#17191d;--ymc-shell-line:#e8eaed;--ymc-shell-muted:#777b82;--ymc-shell-bg:#f5f6f7}

/* Hide the theme's old footer only on Yaran Market pages. */
body.ymc-shell-page #site-footer,
body.ymc-shell-page footer.elementor-location-footer,
body.ymc-shell-page .site-footer:not(.ymc-site-footer){display:none!important}

/* Search — fixed geometry, no inherited pink Elementor/WordPress button styles. */
body.ymc-shell-page .ymc-app-search,
body.ymc-shell-page .ymc-smart-search{direction:rtl!important}
body.ymc-shell-page .ymc-app-search>button,
body.ymc-shell-page .ymc-search-submit{
    appearance:none!important;-webkit-appearance:none!important;
    border:0!important;outline:0!important;box-shadow:none!important;
    font-family:inherit!important;cursor:pointer!important;
    display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:7px!important;
    background:var(--ymc-shell-dark)!important;color:#fff!important;
}
body.ymc-shell-page .ymc-app-search>button svg,
body.ymc-shell-page .ymc-search-submit svg{display:block!important;transform:none!important;flex:0 0 auto!important}
body.ymc-shell-page .ymc-app-search{
    display:grid!important;grid-template-columns:minmax(0,1fr) 48px!important;gap:0!important;align-items:center!important;
}
body.ymc-shell-page .ymc-app-search>input{
    grid-column:1!important;grid-row:1!important;height:48px!important;
    border:1px solid #e1e4e8!important;border-left:0!important;
    border-radius:0 15px 15px 0!important;background:#f8f8f9!important;
}
body.ymc-shell-page .ymc-app-search>button{
    grid-column:2!important;grid-row:1!important;width:48px!important;height:48px!important;
    border-radius:15px 0 0 15px!important;
}
body.ymc-shell-page .ymc-app-search>.ymc-search-results{grid-column:1/-1!important}

body.ymc-shell-page .ymc-home-search-v3 .ymc-smart-search{
    display:grid!important;grid-template-columns:minmax(0,1fr) 104px!important;gap:8px!important;align-items:center!important;
    width:100%!important;margin:0!important;
}
body.ymc-shell-page .ymc-home-search-v3 .ymc-smart-search>input{
    grid-column:1!important;grid-row:1!important;min-width:0!important;height:62px!important;margin:0!important;
    border:1px solid #e1e4e8!important;border-radius:18px!important;background:#fff!important;
    padding:0 18px!important;box-shadow:0 10px 30px rgba(15,23,42,.06)!important;
}
body.ymc-shell-page .ymc-home-search-v3 .ymc-smart-search>.ymc-search-submit{
    grid-column:2!important;grid-row:1!important;width:104px!important;height:62px!important;margin:0!important;
    border-radius:18px!important;font-size:13px!important;font-weight:900!important;
}
body.ymc-shell-page .ymc-home-search-v3 .ymc-smart-search>.ymc-search-results{grid-column:1/-1!important;top:calc(100% + 7px)!important}

/* Address button in app header. */
body.ymc-shell-page .ymc-app-address{
    appearance:none!important;border:0!important;border-right:1px solid #eee!important;background:transparent!important;
    display:flex!important;flex-direction:column!important;align-items:flex-start!important;justify-content:center!important;
    min-width:130px!important;padding:7px 12px!important;color:#333!important;font-family:inherit!important;text-align:right!important;cursor:pointer!important;
}
body.ymc-shell-page .ymc-app-address small{font-size:10px!important;color:#999!important}
body.ymc-shell-page .ymc-app-address strong{font-size:12px!important;max-width:150px!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;color:#222!important}

/* Remove inherited pink button appearance from WooCommerce/theme buttons on the custom store shell. */
body.ymc-shell-page .woocommerce a.button,
body.ymc-shell-page .woocommerce button.button,
body.ymc-shell-page .woocommerce input.button,
body.ymc-shell-page .woocommerce #respond input#submit{
    border:0!important;border-radius:12px!important;background:var(--ymc-shell-dark)!important;color:#fff!important;
    box-shadow:none!important;text-shadow:none!important;font-family:inherit!important;font-weight:800!important;
}
body.ymc-shell-page .woocommerce a.button:hover,
body.ymc-shell-page .woocommerce button.button:hover,
body.ymc-shell-page .woocommerce input.button:hover{background:#292c31!important;color:#fff!important}
body.ymc-shell-page .woocommerce .single_add_to_cart_button,
body.ymc-shell-page .woocommerce #place_order,
body.ymc-shell-page .woocommerce .checkout-button{
    background:var(--ymc-shell-red)!important;color:#fff!important;border:0!important;
}
body.ymc-shell-page .woocommerce-message .button,
body.ymc-shell-page .woocommerce-info .button{background:var(--ymc-shell-dark)!important;color:#fff!important;border:0!important}

/* Real footer */
.ymc-site-footer{direction:rtl;background:#17191d;color:#fff;margin:42px 0 0;padding:0 18px;position:relative;z-index:2}
.ymc-site-footer-inner{width:min(1240px,100%);margin:0 auto;display:grid;grid-template-columns:minmax(260px,1.5fr) repeat(3,minmax(140px,.65fr));gap:34px;padding:42px 0 34px}
.ymc-footer-brand strong{display:block;font-size:20px;font-weight:950;margin-bottom:10px}.ymc-footer-brand p{max-width:430px;margin:0 0 13px;color:#b8bdc5;font-size:12px;line-height:2}.ymc-footer-brand>a{color:#fff!important;text-decoration:none!important;font-weight:800}
.ymc-footer-col{display:flex;flex-direction:column;align-items:flex-start;gap:9px}.ymc-footer-col>b{font-size:13px;margin-bottom:5px}.ymc-footer-col>a,.ymc-footer-col>button{appearance:none;border:0;background:transparent;padding:0;color:#b8bdc5!important;text-decoration:none!important;font-family:inherit;font-size:11px;cursor:pointer;text-align:right}.ymc-footer-col>a:hover,.ymc-footer-col>button:hover{color:#fff!important}
.ymc-site-footer-bottom{width:min(1240px,100%);margin:0 auto;border-top:1px solid rgba(255,255,255,.09);padding:16px 0 20px;display:flex;align-items:center;justify-content:space-between;gap:12px;color:#858b95;font-size:10px}

/* Location permission popup */
.ymc-location-overlay{position:fixed;inset:0;display:none;align-items:center;justify-content:center;padding:18px;background:rgba(9,12,17,.52);backdrop-filter:blur(5px);z-index:9999999;direction:rtl}
.ymc-location-overlay.is-active{display:flex}.ymc-location-modal{width:min(420px,100%);position:relative;background:#fff;border-radius:26px;padding:26px;box-shadow:0 28px 90px rgba(0,0,0,.24);text-align:center}.ymc-location-close{position:absolute;left:15px;top:12px;width:36px;height:36px;border:0;border-radius:50%;background:#f3f4f6;color:#555;font-size:24px;line-height:1;cursor:pointer}.ymc-location-pin{width:66px;height:66px;margin:0 auto 13px;border-radius:22px;display:grid;place-items:center;background:#fff0ee;color:var(--ymc-shell-red)}.ymc-location-modal h3{margin:0 0 8px!important;color:#17191d!important;font-size:20px!important;font-weight:950!important}.ymc-location-modal>p{margin:0 auto 18px!important;max-width:340px;color:#6e737b!important;font-size:13px!important;line-height:2!important}.ymc-location-primary,.ymc-location-secondary{width:100%;height:48px;border:0!important;border-radius:14px!important;font-family:inherit!important;font-weight:900!important;cursor:pointer!important}.ymc-location-primary{background:var(--ymc-shell-red)!important;color:#fff!important;margin-bottom:9px}.ymc-location-secondary{background:#f2f4f6!important;color:#4e535b!important}.ymc-location-current{margin:0 0 14px;padding:11px 12px;background:#f8f9fa;border:1px solid #eceef1;border-radius:14px;text-align:right}.ymc-location-current small,.ymc-location-current strong{display:block}.ymc-location-current small{color:#999;font-size:10px;margin-bottom:3px}.ymc-location-current strong{color:#222;font-size:12px;line-height:1.8}.ymc-location-message{margin-top:11px;font-size:11px;line-height:1.8}.ymc-location-message.is-error{padding:9px;border-radius:10px;background:#fff1ef;color:#b42318}.ymc-location-message.is-success{padding:9px;border-radius:10px;background:#ecfdf3;color:#067647}

/* Mobile nav must never appear as a desktop footer. */
.ymc-mobile-nav{display:none!important}

@media(max-width:900px){
    body.ymc-shell-page .ymc-app-address{display:none!important}
    .ymc-mobile-nav{display:grid!important}
    .ymc-site-footer{margin-top:28px;padding-bottom:80px}.ymc-site-footer-inner{grid-template-columns:1fr 1fr;gap:24px;padding:30px 0 26px}.ymc-footer-brand{grid-column:1/-1}.ymc-site-footer-bottom{padding-bottom:14px}
}
@media(max-width:650px){
    body.ymc-shell-page .ymc-home-search-v3 .ymc-smart-search{grid-template-columns:minmax(0,1fr) 54px!important;gap:7px!important}
    body.ymc-shell-page .ymc-home-search-v3 .ymc-smart-search>input{height:54px!important;border-radius:15px!important;font-size:12px!important}
    body.ymc-shell-page .ymc-home-search-v3 .ymc-smart-search>.ymc-search-submit{width:54px!important;height:54px!important;border-radius:15px!important}
    body.ymc-shell-page .ymc-home-search-v3 .ymc-search-submit span{display:none!important}
    .ymc-site-footer-inner{grid-template-columns:1fr 1fr;gap:20px}.ymc-site-footer-bottom{align-items:flex-start;flex-direction:column}
}
body.ymc-shell-page .ymc-home-address-v3{appearance:none!important;cursor:pointer!important;font-family:inherit!important;text-align:right!important}.ymc-home-address-v3{border:1px solid #eceef1!important;background:#fff!important;color:#777!important}.ymc-home-address-v3 strong{color:#24262a!important}

/* =========================================================
   YMC v3.2 — mobile-first persistent bottom navigation
   ========================================================= */
@media(max-width:900px){
    body.ymc-shell-page{padding-bottom:92px!important}
    .ymc-site-footer{display:none!important}
    .ymc-mobile-nav.ymc-mobile-nav-v320{
        display:grid!important;
        position:fixed!important;
        right:10px!important;left:10px!important;bottom:max(10px,env(safe-area-inset-bottom))!important;
        z-index:999999!important;
        grid-template-columns:repeat(5,minmax(0,1fr))!important;
        align-items:end!important;
        min-height:68px!important;
        padding:7px 7px 6px!important;
        border:1px solid rgba(224,226,230,.96)!important;
        border-radius:23px!important;
        background:rgba(255,255,255,.96)!important;
        backdrop-filter:blur(20px)!important;-webkit-backdrop-filter:blur(20px)!important;
        box-shadow:0 18px 52px rgba(18,22,29,.17)!important;
        direction:rtl!important;
    }
    .ymc-mobile-nav-v320>a{
        position:relative!important;
        min-width:0!important;height:54px!important;
        display:flex!important;flex-direction:column!important;align-items:center!important;justify-content:center!important;gap:4px!important;
        border:0!important;border-radius:16px!important;background:transparent!important;color:#71757c!important;
        text-decoration:none!important;font-family:inherit!important;
        transition:transform .18s ease,color .18s ease,background .18s ease!important;
    }
    .ymc-mobile-nav-v320>a svg{width:22px!important;height:22px!important;fill:none!important;stroke:currentColor!important;stroke-width:1.8!important;stroke-linecap:round!important;stroke-linejoin:round!important;display:block!important}
    .ymc-mobile-nav-v320>a b{font-size:9px!important;line-height:1!important;font-weight:850!important;white-space:nowrap!important}
    .ymc-mobile-nav-v320>a.is-active{background:#fff1ef!important;color:#ef3b2d!important}
    .ymc-mobile-nav-v320>a:active{transform:scale(.95)!important}
    .ymc-mobile-nav-v320 .ymc-mobile-cart{
        width:64px!important;height:64px!important;justify-self:center!important;
        margin-top:-18px!important;border-radius:21px!important;
        background:#ef3b2d!important;color:#fff!important;
        box-shadow:0 11px 28px rgba(239,59,45,.34)!important;
    }
    .ymc-mobile-nav-v320 .ymc-mobile-cart.is-active{background:#d92d20!important;color:#fff!important}
    .ymc-mobile-nav-v320 .ymc-mobile-cart svg{width:25px!important;height:25px!important}
    .ymc-mobile-nav-v320 .ymc-mobile-cart i{
        position:absolute!important;top:3px!important;right:4px!important;
        min-width:18px!important;height:18px!important;padding:0 5px!important;
        display:grid!important;place-items:center!important;
        border:2px solid #fff!important;border-radius:999px!important;background:#17191d!important;color:#fff!important;
        font-size:9px!important;font-style:normal!important;font-weight:900!important;line-height:1!important;
    }
}
@media(min-width:901px){.ymc-mobile-nav-v320{display:none!important}}

/* =========================================================
   YMC v3.2.1 — iOS/mobile horizontal overflow hardening
   Location labels must never expand the page width.
   ========================================================= */
@media(max-width:900px){
    html,body{max-width:100%!important;overflow-x:hidden!important}
    body.ymc-shell-page,
    body.ymc-shell-page .ymc-store-front-page,
    body.ymc-shell-page .ymc-store-catalog-page,
    body.ymc-shell-page .ymc-system-page,
    body.ymc-shell-page .ymc-pdp-page,
    body.ymc-shell-page .ymc-store-home,
    body.ymc-shell-page .ymc-app-header,
    body.ymc-shell-page .ymc-home-hero-v3,
    body.ymc-shell-page .ymc-home-hero-copy-v3,
    body.ymc-shell-page .ymc-home-search-v3,
    body.ymc-shell-page .ymc-home-promo-strip,
    body.ymc-shell-page .ymc-store-section{
        min-width:0!important;
        max-width:100%!important;
        box-sizing:border-box!important;
    }

    body.ymc-shell-page .ymc-home-hero-copy-v3{width:100%!important}
    body.ymc-shell-page .ymc-home-address-v3{
        display:flex!important;
        width:100%!important;
        max-width:100%!important;
        min-width:0!important;
        overflow:hidden!important;
        align-items:center!important;
        flex-wrap:nowrap!important;
        box-sizing:border-box!important;
    }
    body.ymc-shell-page .ymc-home-address-v3 strong{
        display:block!important;
        flex:1 1 auto!important;
        min-width:0!important;
        max-width:100%!important;
        overflow:hidden!important;
        text-overflow:ellipsis!important;
        white-space:nowrap!important;
    }
    body.ymc-shell-page [data-ymc-location-label]{min-width:0!important;max-width:100%!important}
    body.ymc-shell-page .ymc-location-current{max-width:100%!important;overflow:hidden!important}
    body.ymc-shell-page .ymc-location-current strong{
        max-width:100%!important;
        overflow-wrap:anywhere!important;
        word-break:break-word!important;
    }

    /* Do not let sticky header/search create an intrinsic-width overflow on Safari. */
    body.ymc-shell-page .ymc-app-header>*{min-width:0!important}
    body.ymc-shell-page .ymc-app-search,
    body.ymc-shell-page .ymc-app-search>input,
    body.ymc-shell-page .ymc-home-search-v3 .ymc-smart-search,
    body.ymc-shell-page .ymc-home-search-v3 .ymc-smart-search>input{min-width:0!important;max-width:100%!important}
}
