/* store-calm v5: طبقة تهدئة لتصميم صفحات المتجر (بتتحمّل آخر حاجة).
   خط Cairo بأوزانه، والعناوين والأسعار 700 بدل 800، لون واحد للشراء (برتقالي بنص كحلي)،
   حواف وظلال موحّدة، الفوتر تحت في الصفحات القصيرة، سكيلتون للصور، والهيدر المصغر على الموبايل كحلي. بيتضاف للصفحات بـ tools/patch-store-calm.js */
/* ===== store-calm: tokens ===== */
:root{
  --sc-bg:#FFFFFF;
  --sc-soft:#F6F6F4;
  --sc-soft-2:#EEEEEB;
  --sc-line:rgba(27,35,44,.09);
  --sc-line-2:rgba(27,35,44,.16);
  --sc-text:#1B232C;
  --sc-text-2:#4A535E;
  --sc-muted:#5F6873;
  --sc-navy:#123B5E;
  --sc-navy-ink:#0C2942;
  --sc-orange:#F5821F;
  --sc-orange-hover:#E7761A;
  --sc-sale:#B42318;
  --sc-r-ctl:10px;
  --sc-r-card:12px;
  --sc-ease:cubic-bezier(.2,.7,.2,1);
  /* old tokens, pointed at the calm ramp */
  --accent:#123B5E;
  --accent-dark:#0C2942;
  --text:#1B232C;
  --text-muted:#5F6873;
  --border:#E6E6E2;
  --bg-soft:#F6F6F4;
  --shadow:none;
  --shadow-card:none;
}

/* ===== type: Cairo with its own weights; only the loudest 800s come down to 700 ===== */
html body,
html body button,
html body input,
html body select,
html body textarea{letter-spacing:0 !important}
html body .price,
html body .old-price,
html body [class*="price"],
html body .badge{font-variant-numeric:tabular-nums}

/* ===== header ===== */
html body header.main-header{box-shadow:none !important;border-bottom:1px solid rgba(255,255,255,.06)}
html body header.main-header .search-form{border-radius:var(--sc-r-ctl) !important;border:0 !important;box-shadow:none !important}
html body header.main-header .search-form input{color:var(--sc-text) !important;font-size:15px !important;min-width:0 !important;width:auto}
html body header.main-header .search-form button{flex-shrink:0 !important}
html body header.main-header .search-form button{border-radius:8px !important}
html body header.main-header .header-action{}
html body header.main-header .header-action .badge{box-shadow:none !important}

/* category strip: plain links instead of navy pills */
html body nav.cat-nav{border-bottom:1px solid var(--sc-line) !important;box-shadow:none !important}
html body nav.cat-nav a,
html body nav.cat-nav a.all-cats{
  background:transparent !important;color:var(--sc-text-2) !important;
  border-radius:8px !important;padding:6px 12px !important;
  box-shadow:none !important;border:0 !important;
  transition:background-color .15s var(--sc-ease),color .15s var(--sc-ease)}
html body nav.cat-nav a:hover{background:var(--sc-soft) !important;color:var(--sc-text) !important}
html body nav.cat-nav a.all-cats{color:var(--sc-navy) !important;}

/* ===== hero banners ===== */
html body .hero{background:var(--sc-bg) !important}
html body .gbn-card{border-radius:var(--sc-r-card) !important;box-shadow:none !important}
html body .gbn-arrow{box-shadow:none !important;border:1px solid var(--sc-line) !important}

/* ===== trust bar ===== */
html body .trust-bar{border-top:1px solid var(--sc-line);border-bottom:1px solid var(--sc-line);box-shadow:none !important}
html body .trust-item svg{color:var(--sc-muted) !important;width:22px !important;height:22px !important;stroke-width:1.5}
html body .trust-item h4{color:var(--sc-text) !important}
html body .trust-item p{color:var(--sc-muted) !important}

/* ===== sections ===== */
html body .section-head h3,
html body .section-head h2{color:var(--sc-text) !important;font-size:20px !important;padding-inline-start:0 !important}
html body .section-head h3::before,html body .section-head h3::after,
html body .section-head h2::before,html body .section-head h2::after{display:none !important}
html body .section-head a{color:var(--sc-navy) !important;}
html body .section-head a:hover{text-decoration:underline;text-underline-offset:4px}

/* categories */
html body .cat-card{
  border:1px solid var(--sc-line) !important;box-shadow:none !important;border-radius:var(--sc-r-card) !important;
  animation:none !important;opacity:1 !important;transform:none !important;
  transition:border-color .15s var(--sc-ease)}
html body .cat-card:hover{border-color:var(--sc-line-2) !important;transform:none !important;box-shadow:none !important}
html body .cat-card img{border-radius:8px !important;background:var(--sc-soft) !important}
html body .cat-card span{color:var(--sc-text) !important;}

/* ===== product card ===== */
html body .product-card{
  border:1px solid var(--sc-line) !important;box-shadow:none !important;border-radius:var(--sc-r-card) !important;
  animation:none !important;opacity:1 !important;
  transition:border-color .15s var(--sc-ease)}
html body .product-card:hover{border-color:var(--sc-line-2) !important;box-shadow:none !important;transform:none !important}
html body .product-card:hover img,
html body .product-thumb:hover img{transform:none !important}
html body .product-thumb{background:var(--sc-soft) !important}
html body .discount-badge{
  background:rgba(255,255,255,.94) !important;color:var(--sc-sale) !important;
  font-size:12px !important;border-radius:6px !important;
  padding:2px 8px !important;box-shadow:0 0 0 1px var(--sc-line) !important}
html body .wishlist-btn{box-shadow:0 0 0 1px var(--sc-line) !important;color:var(--sc-muted) !important}
html body .wishlist-btn.active,html body .wishlist-btn.active svg{color:var(--sc-sale) !important}
html body .gb-plus{
  background:#FFFFFF !important;color:var(--sc-navy) !important;
  box-shadow:0 0 0 1px var(--sc-line-2) !important;transition:background-color .15s var(--sc-ease)}
html body .gb-plus:hover{background:var(--sc-soft) !important;transform:none !important}
html body .gb-plus:active{transform:scale(.96) !important}
html body .product-info h4{color:var(--sc-text) !important}
html body .stars{color:#C98A1B !important}
html body .stars span{color:var(--sc-muted) !important}
html body .price{color:var(--sc-text) !important;}
html body .old-price{color:var(--sc-muted) !important}
html body .add-cart-btn{
  background:var(--sc-soft) !important;color:var(--sc-navy) !important;
  border-radius:var(--sc-r-ctl) !important;box-shadow:none !important;
  border:1px solid var(--sc-line) !important;
  transition:background-color .15s var(--sc-ease),border-color .15s var(--sc-ease)}
html body .add-cart-btn:hover{background:var(--sc-soft-2) !important;border-color:var(--sc-line-2) !important;transform:none !important}
html body .add-cart-btn:active{transform:scale(.98) !important}

/* ===== floating buttons ===== */
html body .chat-fab,html body .back-top{box-shadow:0 1px 4px rgba(27,35,44,.16) !important}
html body .chat-fab:hover{transform:none !important}


/* ===== primary actions: brand orange with dark ink (5.7:1), navy as the second action ===== */
html body .product-add-cart-btn,
html body .msa-cart-btn,
html body .checkout-btn,
html body .cd-btn.pri{
  background:var(--sc-orange) !important;color:var(--sc-navy-ink) !important;border-color:var(--sc-orange) !important;
  border-radius:var(--sc-r-ctl) !important;box-shadow:none !important;
  transition:background-color .15s var(--sc-ease)}
html body .product-add-cart-btn:hover,
html body .msa-cart-btn:hover,
html body .checkout-btn:hover,
html body .cd-btn.pri:hover{background:var(--sc-orange-hover) !important}
html body .product-buy-now-btn,
html body .msa-buy-btn,
html body .place-order-btn{
  border-radius:var(--sc-r-ctl) !important;box-shadow:none !important}
html body .product-add-cart-btn:disabled,
html body .product-buy-now-btn:disabled,
html body .msa-cart-btn:disabled,
html body .msa-buy-btn:disabled{background:var(--sc-soft-2) !important;color:var(--sc-muted) !important;border-color:var(--sc-soft-2) !important}
html body .product-add-cart-btn:active,html body .product-buy-now-btn:active,
html body .msa-cart-btn:active,html body .msa-buy-btn:active,
html body .checkout-btn:active,html body .place-order-btn:active{transform:scale(.98)}

/* ===== product page ===== */
html body .product-layout .buy-box > .pd-side,
html body .product-layout .pd-side{
  border:1px solid var(--sc-line) !important;border-top:1px solid var(--sc-line) !important;
  box-shadow:none !important;border-radius:var(--sc-r-card) !important}
html body .auth-form .place-order-btn,
html body .co-submit{
  background:var(--sc-orange) !important;color:var(--sc-navy-ink) !important;
  border-radius:var(--sc-r-ctl) !important;box-shadow:none !important}
html body .auth-form .place-order-btn:hover,html body .co-submit:hover{background:var(--sc-orange-hover) !important}

/* title bars and form accents */
html body .gbm-h::before,html body .ol-sec::before{display:none !important}
html body .gbm-h,html body .ol-sec{padding-inline-start:0 !important;}
html body input[type="radio"],html body input[type="checkbox"]{accent-color:var(--sc-navy)}
html body button:focus-visible,html body a:focus-visible{outline:2px solid var(--sc-navy);outline-offset:2px}

/* ===== checkout ===== */
html body .co-page{background:var(--sc-soft) !important}
html body .co-hero{background:var(--sc-navy) !important}
html body .co-hero::before,html body .co-hero::after{display:none !important}
html body .co-step{}
html body .co-step.cur i{color:var(--sc-navy-ink) !important}
html body .co-ship:not(.todo) .co-bar span{background:#1E8A5B !important}
html body .co-empty a{
  background:var(--sc-orange) !important;color:var(--sc-navy-ink) !important;
  border-radius:var(--sc-r-ctl) !important;box-shadow:none !important}
html body .co-page [class*="card"],html body .co-page .co-box{box-shadow:none !important}
html body .co-empty{box-shadow:none !important;border:1px solid var(--sc-line) !important}
html body .co-pay.selected{box-shadow:0 0 0 1px var(--sc-navy) !important;border-color:var(--sc-navy) !important}

/* ===== weights: 800 headings and prices come down to 700, everything else keeps style.css ===== */
html body .section-head h3,html body .section-head h2,html body .price{font-weight:700 !important}
html body nav.cat-nav a{font-weight:600 !important}
html body nav.cat-nav a.all-cats{font-weight:700 !important}

/* ===== short pages: keep the footer at the bottom of the screen ===== */
html body:has(> footer){min-height:100vh;min-height:100dvh;display:flex;flex-direction:column}
html body:has(> footer) > *{flex-shrink:0}
html body:has(> footer) > footer{margin-top:auto}

/* ===== image skeleton while a photo is loading =====
   product and category photos (.fade-img) show a moving shine until loaded,
   banners get the same shine behind the image, which covers it once it arrives */
@keyframes sc-shine{from{transform:translateX(100%)}to{transform:translateX(-100%)}}
@keyframes sc-shine-bg{from{background-position:150% 0}to{background-position:-50% 0}}
html body img.fade-img:not(.loaded){
  opacity:1 !important;
  background-color:var(--sc-soft-2) !important;
  background-image:linear-gradient(90deg,rgba(255,255,255,0) 0%,rgba(255,255,255,.65) 50%,rgba(255,255,255,0) 100%) !important;
  background-size:60% 100% !important;background-repeat:no-repeat !important;
  animation:sc-shine-bg 1.3s linear infinite}
html body .gbn-card:not(.gbn-sk){isolation:isolate}
html body .gbn-card:not(.gbn-sk)::before{
  content:"";position:absolute;inset:0;z-index:0;pointer-events:none;
  background:linear-gradient(90deg,rgba(255,255,255,0) 20%,rgba(255,255,255,.55) 50%,rgba(255,255,255,0) 80%);
  animation:sc-shine 1.3s linear infinite}
html body .gbn-card:not(.gbn-sk) > img{position:relative;z-index:1}
@media (prefers-reduced-motion:reduce){
  html body img.fade-img:not(.loaded),html body .gbn-card::before{animation:none !important}
}

/* ===== mobile compact header (shows on scroll): navy like the main header =====
   cart.js injects a white version; this wins over it */
@media (max-width:768px){
  html body .compact-mobile-header{background:var(--sc-navy) !important;box-shadow:0 1px 0 rgba(255,255,255,.06),0 4px 12px rgba(12,41,66,.18) !important}
  html body .compact-mobile-header .compact-menu-btn,
  html body .compact-mobile-header .compact-icon-btn{color:#fff !important;background:transparent !important}
  html body .compact-mobile-header .compact-menu-btn svg,
  html body .compact-mobile-header .compact-icon-btn svg{stroke:#fff}
  html body .compact-mobile-header .compact-logo img{filter:brightness(0) invert(1)}
  html body .compact-mobile-header .compact-search-form{background:#fff !important;border-radius:var(--sc-r-ctl) !important}
  html body .compact-mobile-header .compact-search-form input{color:var(--sc-text) !important}
  html body .compact-mobile-header .compact-search-form button{color:var(--sc-navy) !important}
  html body .compact-mobile-header .compact-badge{box-shadow:0 0 0 2px var(--sc-navy) !important}
}
