/* v3.2 critical shell reset: prevents the legacy .single-product class from turning the BODY into a grid */
body.single-product{display:block!important;grid-template-columns:none!important;gap:0!important;padding:0!important;margin:0!important;min-height:100vh!important;}
body.single-product>.site-header{display:block!important;position:sticky!important;top:0!important;left:0!important;right:0!important;width:100%!important;height:auto!important;min-height:0!important;max-height:none!important;margin:0!important;padding:0!important;z-index:9999!important;background:#fff!important;}
body.single-product>.site-header .head{height:86px!important;min-height:86px!important;max-height:86px!important;width:min(1420px,94vw)!important;margin:0 auto!important;padding:0!important;}
body.single-product>.site-header .brand-logo{width:170px!important;height:76px!important;flex:0 0 170px!important;}
body.single-product>.site-header .brand-logo img{width:164px!important;height:72px!important;object-fit:contain!important;}
body.single-product>main{display:block!important;position:relative!important;width:100%!important;min-height:0!important;clear:both!important;}
body.single-product>.site-footer{display:block!important;width:100%!important;clear:both!important;}
@media(max-width:900px){body.single-product>.site-header .head{height:74px!important;min-height:74px!important;max-height:74px!important;width:calc(100% - 28px)!important}body.single-product>.site-header .brand-logo{width:132px!important;height:66px!important;flex-basis:132px!important}body.single-product>.site-header .brand-logo img{width:128px!important;height:62px!important}}

/* Product page v3 - intentionally isolated from WooCommerce legacy rules */
body.single-product main{display:block!important;width:100%!important;max-width:none!important;margin:0!important;padding:0!important;overflow:visible!important}
body.single-product .v3-product-page{display:block!important;width:100%!important;max-width:none!important;margin:0!important;padding:44px 0 0!important;background:#fff!important;float:none!important;clear:both!important}
body.single-product .v3-product-container{display:block!important;width:calc(100% - 64px)!important;max-width:1500px!important;margin:0 auto!important;padding:0!important;float:none!important}
body.single-product .v3-product-hero{display:grid!important;grid-template-columns:minmax(0,1.35fr) minmax(340px,.65fr)!important;gap:64px!important;align-items:center!important;width:100%!important}
body.single-product .v3-gallery,body.single-product .v3-info{width:100%!important;min-width:0!important;float:none!important;margin:0!important}
body.single-product .v3-main-image{height:650px!important;max-height:72vh!important;min-height:520px!important;display:flex!important;align-items:center!important;justify-content:center!important;background:#fff!important;overflow:hidden!important}
body.single-product .v3-main-image img{display:block!important;width:100%!important;height:100%!important;max-width:none!important;max-height:none!important;object-fit:contain!important;object-position:center!important;margin:0!important}
body.single-product .v3-thumbs{display:flex!important;gap:10px!important;overflow:auto!important;margin-top:14px!important;padding-bottom:4px!important}
body.single-product .v3-thumb{width:76px!important;height:76px!important;flex:0 0 76px!important;border:1px solid #e4ebf5!important;border-radius:12px!important;background:#fff!important;padding:5px!important;cursor:pointer!important}.v3-thumb.active{border:2px solid #0868df!important}.v3-thumb img{width:100%!important;height:100%!important;object-fit:contain!important}
body.single-product .v3-info{max-width:540px!important}.v3-kicker{font-size:12px!important;font-weight:800!important;letter-spacing:.12em!important;color:#0868df!important;margin-bottom:12px!important}.v3-info h1{font-size:clamp(36px,3vw,52px)!important;line-height:1.12!important;color:#082b68!important;margin:0 0 15px!important}.v3-code{font-size:15px!important;color:#66758f!important;margin:0 0 22px!important}.v3-code strong{color:#082b68!important}.v3-short{font-size:16px!important;line-height:1.9!important;color:#40516d!important}.v3-cats{display:flex!important;gap:9px!important;align-items:center!important;flex-wrap:wrap!important;border-top:1px solid #e4ebf5!important;padding-top:20px!important;margin-top:22px!important}.v3-cats a{background:#eef6ff!important;color:#0868df!important;padding:7px 12px!important;border-radius:999px!important;font-size:13px!important;font-weight:700!important}
body.single-product .v3-description{display:block!important;width:100%!important;max-width:none!important;border-top:1px solid #e4ebf5!important;margin:50px 0 0!important;padding:36px 0 8px!important;float:none!important;clear:both!important}.v3-description h2,.v3-related h2{font-size:34px!important;color:#082b68!important;margin:0 0 16px!important}.v3-description-copy{max-width:1180px!important;font-size:16px!important;line-height:1.95!important;color:#40516d!important}
body.single-product .v3-related{display:block!important;width:100%!important;max-width:none!important;border-top:1px solid #e4ebf5!important;margin:42px 0 0!important;padding:36px 0 12px!important;float:none!important;clear:both!important;overflow:hidden!important}.v3-related-heading{display:flex!important;justify-content:space-between!important;align-items:flex-end!important;gap:20px!important;margin-bottom:22px!important}.v3-related-heading h2{margin-bottom:5px!important}.v3-related-heading p{margin:0!important;color:#66758f!important}.v3-controls{display:flex!important;gap:8px!important;direction:ltr!important}.v3-controls button{width:44px!important;height:44px!important;border:1px solid #e4ebf5!important;border-radius:50%!important;background:#fff!important;color:#082b68!important;font-size:25px!important;cursor:pointer!important}.v3-controls button:hover{background:#0868df!important;color:#fff!important}.v3-carousel{display:block!important;width:100%!important;overflow:hidden!important}.v3-track{display:flex!important;flex-wrap:nowrap!important;gap:20px!important;width:auto!important;transition:transform .35s ease!important;will-change:transform!important;direction:ltr!important}.v3-card{display:block!important;flex:0 0 calc((100% - 60px)/4)!important;min-width:0!important;width:auto!important;border:1px solid #e4ebf5!important;border-radius:18px!important;background:#fff!important;padding:12px!important;color:#0b1d3a!important}.v3-card-image{display:flex!important;align-items:center!important;justify-content:center!important;aspect-ratio:1/1!important;width:100%!important;border-radius:14px!important;background:#fff!important;overflow:hidden!important;padding:10px!important}.v3-card-image img{display:block!important;width:100%!important;height:100%!important;max-width:none!important;object-fit:contain!important;margin:0!important}.v3-card h3{font-size:15px!important;line-height:1.45!important;margin:12px 2px 6px!important}.v3-card span{font-size:12px!important;color:#66758f!important}
body.single-product.site-ar .v3-info,body.single-product.site-ar .v3-description,body.single-product.site-ar .v3-related{text-align:right!important}
body.single-product .price,body.single-product form.cart,body.single-product .single_add_to_cart_button{display:none!important}body.single-product .site-footer{display:block!important;clear:both!important;width:100%!important;margin-top:48px!important;position:relative!important}
@media(max-width:980px){body.single-product .v3-product-container{width:calc(100% - 36px)!important;max-width:820px!important}.v3-product-hero{grid-template-columns:1fr!important;gap:28px!important}.v3-main-image{height:auto!important;min-height:0!important;max-height:none!important;aspect-ratio:1/1!important}.v3-info{max-width:none!important}.v3-card{flex-basis:calc((100% - 20px)/2)!important}}
@media(max-width:640px){body.single-product .v3-product-page{padding-top:22px!important}body.single-product .v3-product-container{width:calc(100% - 24px)!important}.v3-product-hero{gap:20px!important}.v3-main-image{aspect-ratio:1/1!important}.v3-info h1{font-size:30px!important}.v3-description{margin-top:34px!important;padding-top:28px!important}.v3-description h2,.v3-related h2{font-size:27px!important}.v3-related{margin-top:32px!important;padding-top:28px!important}.v3-related-heading{align-items:center!important}.v3-related-heading p{font-size:13px!important}.v3-controls button{width:38px!important;height:38px!important}.v3-card{flex-basis:82%!important}.v3-card-image{padding:7px!important}}

/* v3.1 hard isolation: product layout must never inherit generic theme wrappers */
body.single-product .v3-product-page,
body.single-product .v3-product-page *{box-sizing:border-box}
body.single-product .v3-product-page.section{padding:44px 0 0!important}
body.single-product .v3-product-container.wrap{max-width:1500px!important;width:calc(100% - 64px)!important}
body.single-product .v3-product-hero{direction:ltr!important}
body.single-product.site-ar .v3-info{direction:rtl!important}
body.single-product:not(.site-ar) .v3-info{direction:ltr!important}
body.single-product .v3-related .v3-track{justify-content:flex-start!important;align-items:stretch!important}
body.single-product .v3-related .v3-card{max-width:none!important;margin:0!important;float:none!important}
@media(max-width:980px){body.single-product .v3-product-container.wrap{width:calc(100% - 36px)!important}}
@media(max-width:640px){body.single-product .v3-product-container.wrap{width:calc(100% - 24px)!important}}

/* v3.9 — related carousel follows active language direction. */
body.single-product.site-en .v3-track{direction:ltr!important}
body.single-product.site-ar .v3-track{direction:rtl!important}
body.single-product.site-en .v3-info,body.single-product.site-en .v3-description,body.single-product.site-en .v3-related{text-align:left!important}
body.single-product.site-ar .v3-info,body.single-product.site-ar .v3-description,body.single-product.site-ar .v3-related{text-align:right!important}


/* ===== v3.9.4: single product presentation on phones =====
   These rules deliberately match the existing high-specificity desktop rules,
   which otherwise force a 650px-high image and two columns on narrow screens.
*/
@media (max-width: 640px) {
  body.single-product .v3-product-page {
    padding-top: 18px !important;
  }
  body.single-product .v3-product-container,
  body.single-product .v3-product-container.wrap {
    width: calc(100% - 28px) !important;
    max-width: 540px !important;
    margin-inline: auto !important;
  }
  body.single-product .v3-product-hero {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 12px !important;
    align-items: start !important;
    direction: inherit !important;
  }
  body.single-product .v3-gallery {
    grid-column: 1 !important;
    grid-row: 1 !important;
    width: 100% !important;
    min-width: 0 !important;
    margin: 0 auto !important;
  }
  body.single-product .v3-main-image {
    width: 100% !important;
    height: clamp(285px, 82vw, 430px) !important;
    max-height: none !important;
    min-height: 0 !important;
    padding: 12px !important;
    aspect-ratio: auto !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    overflow: hidden !important;
  }
  body.single-product .v3-main-image img {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    object-fit: contain !important;
    object-position: center center !important;
    margin: auto !important;
  }
  body.single-product .v3-thumbs {justify-content: center !important;}
  body.single-product .v3-info {
    grid-column: 1 !important;
    grid-row: 2 !important;
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    margin: 0 !important;
    padding: 8px 6px 8px !important;
    text-align: center !important;
  }
  body.single-product.site-ar .v3-info,
  body.single-product.site-en .v3-info { text-align: center !important; }
  body.single-product .v3-kicker {
    font-size: 11px !important;
    letter-spacing: .05em !important;
    margin-bottom: 10px !important;
  }
  body.single-product .v3-info h1 {
    font-size: clamp(23px, 6vw, 30px) !important;
    line-height: 1.32 !important;
    margin: 0 0 12px !important;
    max-width: 100% !important;
    overflow-wrap: anywhere !important;
  }
  body.single-product .v3-code {
    font-size: 14px !important;
    margin: 0 0 6px !important;
    line-height: 1.5 !important;
  }
  body.single-product .v3-cats {
    justify-content: center !important;
    gap: 8px !important;
    width: 100% !important;
    margin-top: 12px !important;
    padding-top: 15px !important;
    line-height: 1.7 !important;
  }
  body.single-product .v3-description {margin-top: 30px !important;}
}


/* v3.9.5: reliable single-product stack on mobile and small tablets.
   Also included in style.css to survive a stale/missing product-specific stylesheet.
   Desktop product, header, footer and catalog layout are unaffected. */
@media screen and (max-width: 980px) {
  body.single-product main .v3-product-page .v3-product-container {
    width: calc(100% - 28px) !important;
    max-width: 740px !important;
    margin-inline: auto !important;
    padding: 0 !important;
  }
  body.single-product main .v3-product-page .v3-product-hero {
    display: flex !important;
    flex-flow: column nowrap !important;
    grid-template-columns: none !important;
    grid-template-rows: none !important;
    align-items: stretch !important;
    justify-content: flex-start !important;
    width: 100% !important;
    max-width: 100% !important;
    gap: 18px !important;
    direction: inherit !important;
  }
  body.single-product main .v3-product-page .v3-gallery,
  body.single-product main .v3-product-page .v3-info {
    position: static !important;
    inset: auto !important;
    float: none !important;
    clear: both !important;
    transform: none !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    flex: 0 0 auto !important;
    grid-area: auto !important;
    margin: 0 !important;
    box-sizing: border-box !important;
  }
  body.single-product main .v3-product-page .v3-gallery {order: 0 !important;}
  body.single-product main .v3-product-page .v3-info {
    order: 1 !important;
    display: flex !important;
    flex-flow: column nowrap !important;
    align-items: center !important;
    gap: 0 !important;
    padding: 8px 8px 20px !important;
    text-align: center !important;
  }
  body.single-product main .v3-product-page .v3-main-image {
    position: relative !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: clamp(280px, 74vw, 530px) !important;
    max-height: none !important;
    min-height: 0 !important;
    aspect-ratio: auto !important;
    padding: 14px !important;
    margin: 0 !important;
    overflow: hidden !important;
    background: white !important;
  }
  body.single-product main .v3-product-page .v3-main-image img {
    display: block !important;
    position: static !important;
    width: 100% !important;
    max-width: 100% !important;
    height: 100% !important;
    max-height: 100% !important;
    object-fit: contain !important;
    object-position: center !important;
    margin: auto !important;
    transform: none !important;
  }
  body.single-product main .v3-product-page .v3-info h1,
  body.single-product main .v3-product-page .v3-kicker,
  body.single-product main .v3-product-page .v3-code {
    position: static !important;
    width: auto !important;
    max-width: 100% !important;
    text-align: center !important;
    float: none !important;
    clear: both !important;
    transform: none !important;
    overflow-wrap: anywhere !important;
  }
  body.single-product main .v3-product-page .v3-info h1 {
    font-size: clamp(23px, 5.2vw, 34px) !important;
    line-height: 1.35 !important;
    margin: 0 0 12px !important;
  }
  body.single-product main .v3-product-page .v3-kicker {margin: 0 0 10px !important;}
  body.single-product main .v3-product-page .v3-code {margin: 0 0 8px !important;}
  body.single-product main .v3-product-page .v3-cats {
    position: static !important;
    display: flex !important;
    width: 100% !important;
    max-width: 100% !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 10px 0 0 !important;
    padding: 15px 0 0 !important;
    text-align: center !important;
    flex-wrap: wrap !important;
  }
  body.single-product.site-ar main .v3-product-page .v3-info,
  body.single-product.site-en main .v3-product-page .v3-info {text-align: center !important;}
}
@media screen and (max-width: 640px) {
  body.single-product main .v3-product-page {padding-top: 14px !important;}
  body.single-product main .v3-product-page .v3-product-container {width: calc(100% - 24px) !important;}
  body.single-product main .v3-product-page .v3-main-image {height: clamp(260px, 82vw, 410px) !important;padding: 8px !important;}
  body.single-product main .v3-product-page .v3-product-hero {gap: 12px !important;}
  body.single-product main .v3-product-page .v3-info h1 {font-size: clamp(22px, 5.8vw, 29px) !important;}
}


/* v3.9.11: real horizontal swiping in Related Products (touch + mouse).
   Cards, arrows, and the rest of the product page keep their existing layout. */
body.single-product .v3-related .v3-carousel {
  display: block !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  scroll-snap-type: none;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  cursor: grab;
  touch-action: auto;
}
body.single-product .v3-related .v3-carousel::-webkit-scrollbar {display: none;}
body.single-product.site-en .v3-related .v3-carousel {direction: ltr !important;}
body.single-product.site-ar .v3-related .v3-carousel {direction: rtl !important;}
body.single-product .v3-related .v3-track {
  transform: none !important;
  transition: none !important;
  will-change: auto !important;
}
body.single-product .v3-related .v3-track > .v3-card {
  scroll-snap-align: start;
  -webkit-user-drag: none;
}
body.single-product .v3-related .v3-card img {user-select:none;-webkit-user-drag:none;}
body.single-product .v3-related .v3-carousel.is-dragging {
  cursor: grabbing !important;
  scroll-snap-type: none !important;
}
body.single-product .v3-related .v3-carousel.is-dragging * {user-select:none !important;}
