/* Pieces WordPress plugins used to draw (photo viewer), kept in the theme's look. */
.up-lightbox { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 56px 16px; background: rgba(11, 18, 32, .92); }
.up-lightbox img { max-width: min(100%, 1000px); max-height: 100%; object-fit: contain; border-radius: 12px; background: #fff; }
.up-lightbox button { position: absolute; display: grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .14); color: #fff; font-size: 28px; line-height: 1; cursor: pointer; }
.up-lightbox button:hover { background: rgba(255, 255, 255, .26); }
.up-lightbox button:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; }
.up-lb-close { top: 12px; inset-inline-end: 12px; }
.up-lb-prev { top: 50%; inset-inline-start: 12px; transform: translateY(-50%); }
.up-lb-next { top: 50%; inset-inline-end: 12px; transform: translateY(-50%); }
.up-lb-count { position: absolute; bottom: 16px; color: #c9d6ea; font-size: 14px; }
.woocommerce div.product div.images .woocommerce-product-gallery__image img.wp-post-image { width: 100%; }
/* add-to-cart form and the WhatsApp/compare box below it read as one card */
.up-buy { display: grid; }
.woocommerce div.product .up-buy form.cart { margin: 0; }
.up-page { display: contents; }

/* payment methods (checkout) and the "complete payment" box (thank-you page) */
.ck-pay #payment ul.payment_methods li { display: grid; grid-template-columns: auto 1fr auto; align-items: center; column-gap: 4px; }
.ck-pay #payment ul.payment_methods li > .payment_box { grid-column: 2 / -1; }
.pay-badges { display: inline-flex; flex-wrap: wrap; gap: 4px; justify-content: flex-end; }
.pay-icon { display: grid; place-items: center; width: 34px; height: 26px; border-radius: 6px; background: #e8f6ee; font-size: 16px; }
.pay-badge { padding: 3px 8px; border-radius: 5px; color: #fff; font: italic 800 11px/1.4 var(--f-body); white-space: nowrap; direction: ltr; }
.pay-instapay { background: #5b2a86; }
.pay-vodafone { background: #e60000; }
.pay-eand { background: #d71920; }
.pay-orange { background: #ff7900; color: #1a1200; }
.pay-we { background: #5c2d91; }
.pay-box { display: grid; gap: 12px; margin-block: 20px; padding: 22px; border: 1.5px solid var(--blue); border-radius: 18px; background: var(--blue-soft); }
.pay-box-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.pay-box h2 { font-size: 20px; }
.pay-amount b { font: 800 24px var(--f-display); }
.pay-box hr { width: 100%; margin: 4px 0; border: 0; border-top: 1px solid #c4d8f6; }
.pay-instapay-btn { justify-self: start; background: #5b2a86; color: #fff; border-radius: 999px; padding-inline: 26px; }
.pay-instapay-btn:hover { background: #48206b; }
.pay-box .btn-wa { justify-self: start; border-radius: 999px; }
.pay-number { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.pay-number b { font-size: 22px; letter-spacing: .04em; }
.ftr-pay { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 8px; }

/* tap-to-call: header button, floating button above WhatsApp, phone bottom bar */
.up-call svg { width: 18px; height: 18px; flex: none; }
.up-call .mono { font-size: .95em; }
.hdr-call { display: inline-flex; align-items: center; width: auto; gap: 6px; text-decoration: none; padding: 0 12px; color: var(--blue); border-color: #c4d8f6; background: var(--blue-soft); font-weight: 600; }
.hdr-call svg { width: 20px; height: 20px; }
.hdr-call:hover { background: var(--blue); border-color: var(--blue); color: #fff; }
.call-float { position: fixed; z-index: 24; bottom: calc(84px + env(safe-area-inset-bottom, 0px)); left: calc(18px + env(safe-area-inset-left, 0px)); width: 56px; height: 56px; border-radius: 50%; background: var(--blue); color: #fff; display: grid; place-items: center; box-shadow: 0 6px 20px rgba(0, 0, 0, .2); }
.call-float svg { width: 26px; height: 26px; }
.call-float:hover { background: #165dc0; }
.call-float:focus-visible, .wa-float:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; }
body:has(.sticky-buy) .call-float, body:has(.cmpbar) .call-float { bottom: calc(156px + env(safe-area-inset-bottom, 0px)); }
@media (max-width: 960px) { .hdr-call .mono { display: none; } .hdr-call { width: 44px; padding: 0; gap: 0; justify-content: center; } .hdr-call svg { flex: none; } }
@media (max-width: 760px) {
  .mob-nav { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .mob-nav .mob-call { color: var(--blue); }
  .call-float { bottom: calc(138px + env(safe-area-inset-bottom, 0px)); width: 50px; height: 50px; }
  body:has(.sticky-buy) .call-float, body:has(.cmpbar) .call-float { bottom: calc(206px + env(safe-area-inset-bottom, 0px)); }
}
.sticky-actions { display: flex; gap: 8px; align-items: center; }
.sticky-call { width: 44px; padding: 0; color: var(--blue); }
.sum-call { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 12px; border: 1px dashed #c4d8f6; border-radius: 12px; background: var(--blue-soft); color: var(--blue); font-size: 14px; font-weight: 600; text-decoration: none; }
.sum-call:hover { border-style: solid; }
.sum-call b { font-size: 15px; }
.biz-call { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); font-weight: 600; }
/* cart coupon row: let the code field shrink on narrow phones */
.cart-actions, .cart-actions .coupon { min-width: 0; }
.coupon-row input { min-width: 0; width: 100%; }
.woocommerce .coupon-row .btn-coupon { flex: none; }
/* phones: 16px fields so iOS does not zoom the page when a field is tapped */
@media (max-width: 760px) { input:not([type=checkbox]):not([type=radio]), select, textarea { font-size: 16px !important; } }

/* header: one-line strip, and the «المنتجات» dropdown in the main menu (components/client/Chrome.js) */
.strip .wrap { justify-content: center; text-align: center; }
.nav-drop { position: relative; }
.nav-drop-top { display: inline-flex; align-items: center; gap: 6px; }
.nav-caret { font-size: 11px; opacity: .7; }
.nav-drop-menu { display: none; }
@media (min-width: 961px) {
  .nav { gap: 2px; }
  .nav-drop-menu { position: absolute; top: 100%; inset-inline-start: 0; z-index: 30; min-width: 230px; padding: 6px; display: none; flex-direction: column; gap: 2px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 14px 34px rgba(11, 37, 69, .14); }
  .nav-drop:hover .nav-drop-menu, .nav-drop:focus-within .nav-drop-menu { display: flex; }
  .nav-drop-menu a { padding: 9px 12px; border-radius: 8px; white-space: nowrap; }
  .nav-drop-menu a:last-child { border-top: 1px solid var(--line); border-radius: 0 0 8px 8px; margin-top: 2px; color: var(--blue); }
}
@media (max-width: 960px) {
  .nav-drop { display: flex; flex-direction: column; }
  .nav-caret { display: none; }
  .nav-drop-menu { display: flex; flex-direction: column; padding-inline-start: 14px; border-inline-start: 2px solid var(--line); margin-inline-start: 12px; }
  .nav-drop-menu a { padding: 10px 12px; font-size: 15px; }
  .nav-drop-menu a:last-child { display: none; }
}
@media (max-width: 600px) { .strip-more { display: none; } }

/* product page on phones: smaller photo, title and boxes so the name, price and buy button fit on the first screen */
@media (max-width: 600px) {
  .single-product .woo-main { padding-block: 4px 24px; gap: 12px; }
  .single-product .crumbs { font-size: 12px; padding-block: 6px 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .single-product div.product { gap: 12px; }
  .woocommerce.single-product div.product div.images .woocommerce-product-gallery__image img.wp-post-image { height: 220px; object-fit: contain; }
  .woocommerce.single-product div.product div.images { margin-bottom: 0; }
  .woocommerce.single-product div.product div.images .flex-control-thumbs { display: flex; gap: 6px; margin-top: 6px; padding: 0; }
  .woocommerce.single-product div.product div.images .flex-control-thumbs li { width: 48px !important; flex: none; margin: 0 !important; }
  .woocommerce.single-product div.product div.images .flex-control-thumbs li img { height: 48px; object-fit: contain; border-radius: 6px; }
  .single-product div.product .product_title { font-size: 19px; line-height: 1.45; margin-top: 0; }
  .single-product div.product .summary { gap: 8px; }
  .single-product .up-subtitle { display: none; }
  .single-product div.product p.price { font-size: 22px; }
  .single-product .stock-note { font-size: 13px; }
  .single-product .woocommerce-product-details__short-description p { font-size: 14px; line-height: 1.7; }
  .single-product form.cart { padding: 10px; gap: 8px; }
  .single-product form.cart .quantity .qty { width: 60px; min-height: 42px; }
  .single-product form.cart .single_add_to_cart_button { min-height: 42px; }
  .up-buy-extra { padding: 0 10px 10px; gap: 8px; }
  .up-buy-extra .btn { min-height: 40px; padding: 6px 12px; font-size: 14px; }
  .up-fit h3 { font-size: 15px; }
  .up-fit .fit { grid-template-columns: 1fr 1fr; gap: 6px; }
  .up-fit .fit div { padding: 8px 10px; font-size: 12.5px; line-height: 1.6; }
  .up-fit .fit b { font-size: 13.5px; }
  .ship-info { padding: 10px 12px 0; }
  .ship-info h3 { font-size: 15px; margin-bottom: 0; }
  .ship-row { padding: 10px 0; gap: 10px; }
  .ship-2, .ship-3 { grid-template-columns: 1fr 1fr; }
  .ship-row li { gap: 6px; }
  .ship-ic { width: 24px; height: 24px; }
  .ship-row b, .ship-row li > span:last-child span { font-size: 12.5px; line-height: 1.5; }
}
/* the sticky buy bar has its own call button, so the floating call and WhatsApp buttons step aside */
@media (max-width: 820px) {
  body:has(.sticky-buy) .call-float, body:has(.sticky-buy) .wa-float { display: none; }
}

/* product card names: clamp the link itself to whole lines (clamping the h3 let half of the next line show) */
.woocommerce ul.products li.product h3.woocommerce-loop-product__title { display: block; overflow: visible; -webkit-line-clamp: unset; }
.woocommerce ul.products li.product h3.woocommerce-loop-product__title a { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; line-height: 1.45; }

/* footer: brand + contact buttons, then three short link columns (components/Frame.js) */
.ftr .wrap { grid-template-columns: 1.5fr repeat(3, 1fr); gap: 24px 28px; padding-block: 36px 20px; }
.ftr-brand p { margin-top: 10px; font-size: 14px; line-height: 1.8; max-width: 26em; }
.ftr-contact { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.ftr .ftr-contact a { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border: 1px solid rgba(255, 255, 255, .18); border-radius: 999px; font-size: 13px; color: #fff; }
.ftr .ftr-contact a:hover { background: rgba(255, 255, 255, .1); }
.ftr-contact svg { width: 16px; height: 16px; }
.ftr h4 { font-size: 14px; margin-bottom: 6px; }
.ftr .wrap > div:not(.ftr-brand):not(.copy) a { font-size: 14px; padding-block: 4px; }
.ftr .copy { align-items: center; }
@media (max-width: 820px) {
  .ftr { margin-top: 24px; }
  .ftr .wrap { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px 12px; padding-block: 24px 16px; }
  .ftr-brand { grid-column: 1 / -1; }
  .ftr-brand p { font-size: 13px; margin-top: 6px; }
  .ftr h4 { font-size: 13px; }
  .ftr .wrap > div:not(.ftr-brand):not(.copy) a { font-size: 12.5px; padding-block: 3px; line-height: 1.5; }
  .ftr .copy { flex-direction: column; align-items: flex-start; font-size: 12px; padding-top: 12px; }
  .ftr .copy .pay-badge { font-size: 10px; padding: 2px 6px; } .ftr .copy .pay-icon { width: 28px; height: 22px; font-size: 13px; }
}

/* sticky buy bar on phones: model name on one small line, price under it, buttons on one line */
@media (max-width: 820px) {
  .sticky-buy { gap: 10px; padding-block: 8px; }
  .sticky-buy > div:first-child { flex: 1; min-width: 0; display: grid; gap: 0; }
  .sticky-buy > div:first-child .mono { display: block; font-size: 12px; font-weight: 600; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .sticky-buy > div:first-child .price { font-size: 17px !important; line-height: 1.35; white-space: nowrap; }
  .sticky-actions { display: flex; gap: 8px; flex: none; align-items: center; }
  .sticky-actions .btn { min-height: 44px; padding: 8px 16px; font-size: 15px; white-space: nowrap; }
  .sticky-actions .sticky-call { width: 44px; padding: 0; }
}

/* product cards: key specs as one quiet line (components/Product.js) */
.card .specs-line { text-align: right; margin: 0; padding: 6px 16px 0; font: 500 12.5px/1.5 var(--f-mono); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card .specs-line[dir="rtl"], .card .specs-line:not([dir]) { font-family: var(--f-body); }
@media (max-width: 760px) { .card .specs-line { display: none; } }
