/* =========================
   Footer Full Professional Style
========================= */

.store-footer {
  background: linear-gradient(180deg, #0f172a 0%, #111827 100%) !important;
  color: #e5e7eb !important;
  padding: 0 !important;
  border: 0 !important;
  text-align: center !important;
}

/* Main footer columns */
.store-footer__inner {
  width: min(100%, 1180px) !important;
  margin: 0 auto !important;
  padding: 44px 20px 28px !important;
  display: grid !important;
  grid-template-columns: 1.25fr 1fr 1fr !important;
  gap: 22px !important;
  border: 0 !important;
  align-items: stretch !important;
}

/* Footer cards */
.store-footer__inner > div {
  background: rgba(255, 255, 255, 0.045) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 14px !important;
  padding: 24px 20px !important;
  box-shadow: none !important;
  backdrop-filter: blur(8px);

  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
  min-width: 0 !important;
}

/* First card: logo + store name */
.store-footer__inner > div:first-child {
  justify-content: flex-start !important;
  gap: 10px !important;
}

.store-footer__inner > div:first-child a {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 10px !important;
  text-align: center !important;
  position: static !important;
  transform: none !important;
}

.store-footer__inner > div:first-child img {
  display: block !important;
  width: auto !important;
  height: auto !important;
  max-width: 88px !important;
  max-height: 88px !important;
  margin: 0 auto 8px !important;
  object-fit: contain !important;
  position: static !important;
  transform: none !important;
}

/* Titles */
.store-footer h2,
.store-footer h3,
.store-footer .footer-title,
.store-footer .store-footer__title {
  color: #ffffff !important;
  font-size: 20px !important;
  font-weight: 700 !important;
  line-height: 1.45 !important;
  margin: 0 0 14px !important;
  text-align: center !important;
  position: static !important;
  transform: none !important;
}

/* Text and links */
.store-footer p,
.store-footer a,
.store-footer li,
.store-footer span {
  color: #cbd5e1 !important;
  font-size: 14px !important;
  line-height: 1.9 !important;
  text-align: center !important;
}

.store-footer p {
  margin-top: 8px !important;
}

.store-footer ul {
  padding: 0 !important;
  margin: 0 !important;
  list-style: none !important;
}

.store-footer a {
  display: inline-block !important;
  text-decoration: none !important;
  transition: 0.2s ease !important;
}

.store-footer a:hover {
  color: #22c55e !important;
  transform: translateY(-2px) !important;
}

/* Social icons */
.store-footer .social-link,
.store-footer .s-social-link {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #ffffff !important;
  border-radius: 50% !important;
  width: 38px !important;
  height: 38px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  margin: 4px !important;
  transition: 0.2s ease !important;
}

.store-footer .social-link:hover,
.store-footer .s-social-link:hover {
  background: #22c55e !important;
  color: #0f172a !important;
}

/* =========================
   Bottom footer + payments
========================= */

/* Bottom area after footer cards */
.store-footer > div:last-of-type {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  padding: 16px 16px 30px !important;
  margin: 0 auto !important;
}

/* Bottom inner wrapper */
.store-footer > div:last-of-type > div {
  max-width: 1180px !important;
  margin: 0 auto !important;
  padding: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 16px !important;
  text-align: center !important;
}

/* Copyright */
.store-footer .copyright,
.store-footer__copyright,
.store-footer > div:last-of-type p,
.store-footer > div:last-of-type span,
.store-footer > div:last-of-type div {
  color: #94a3b8 !important;
  font-size: 13px !important;
  text-align: center !important;
}

/* Exact Salla payment component */
.store-footer salla-payments.s-payments-list-wrap {
  display: block !important;
  width: 100% !important;
  max-width: 100% !important;
  margin: 4px auto 0 !important;
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

.store-footer salla-payments.s-payments-list-wrap::before {
  content: "طرق الدفع المتاحة";
  display: block !important;
  color: #e5e7eb !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1.5 !important;
  text-align: center !important;
  margin: 0 0 10px !important;
}

/* Payment icons list */
.store-footer ul.s-payments-list {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-wrap: wrap !important;
  gap: 8px !important;

  width: fit-content !important;
  max-width: 92% !important;
  min-height: 0 !important;
  margin: 0 auto !important;
  padding: 12px 14px !important;

  background: rgba(255, 255, 255, 0.075) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  border-radius: 14px !important;
  box-shadow: none !important;
  list-style: none !important;
}

/* Payment list items */
.store-footer ul.s-payments-list li {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;

  width: auto !important;
  height: auto !important;
  min-width: 0 !important;
  min-height: 0 !important;
  max-width: none !important;

  margin: 0 !important;
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  border-radius: 0 !important;
}

/* Payment icons */
.store-footer ul.s-payments-list img,
.store-footer ul.s-payments-list svg {
  display: block !important;
  height: 28px !important;
  width: auto !important;
  max-width: 64px !important;
  object-fit: contain !important;

  background: #ffffff !important;
  border-radius: 8px !important;
  padding: 5px 8px !important;
  opacity: 1 !important;
  filter: none !important;
  box-shadow: none !important;
}

/* Remove old empty boxes if any */
.store-footer ul.s-payments-list:empty,
.store-footer salla-payments.s-payments-list-wrap:empty {
  display: none !important;
}

/* =========================
   Responsive
========================= */

@media (min-width: 769px) and (max-width: 1024px) {
  .store-footer__inner {
    max-width: 900px !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .store-footer__inner > div:first-child {
    grid-column: 1 / -1 !important;
  }
}

@media (max-width: 768px) {
  .store-footer__inner {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
    padding: 28px 16px 22px !important;
  }

  .store-footer__inner > div {
    padding: 22px 18px !important;
  }

  .store-footer h2,
  .store-footer h3,
  .store-footer .footer-title,
  .store-footer .store-footer__title {
    font-size: 19px !important;
  }

  .store-footer p,
  .store-footer a,
  .store-footer li,
  .store-footer span {
    font-size: 14px !important;
  }

  .store-footer__inner > div:first-child img {
    max-width: 82px !important;
  }

  .store-footer > div:last-of-type {
    padding: 14px 14px 26px !important;
  }

  .store-footer ul.s-payments-list {
    max-width: 90% !important;
    padding: 10px !important;
    gap: 7px !important;
  }

  .store-footer ul.s-payments-list img,
  .store-footer ul.s-payments-list svg {
    height: 24px !important;
    max-width: 56px !important;
    padding: 4px 7px !important;
  }
}
/* خيارات الدفع بعرض الفوتر كامل */
.store-footer salla-payments.s-payments-list-wrap {
  display: block !important;
  width: 100% !important;
  max-width: 100% !important;
  margin: 24px 0 0 !important;
  padding: 0 16px !important;
  background: transparent !important;
  border: 0 !important;
}

.store-footer salla-payments.s-payments-list-wrap::before {
  content: "موثق بالمركز السعودي للاعمال";
  display: block !important;
  width: 100% !important;
  text-align: center !important;
  color: #e5e7eb !important;
  font-size: 15px !important;
  font-weight: 700 !important;
  margin-bottom: 12px !important;
}

.store-footer ul.s-payments-list {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-wrap: wrap !important;
  gap: 10px !important;

  width: 100% !important;
  max-width: 100% !important;
  min-height: 0 !important;
  margin: 0 auto !important;
  padding: 16px 18px !important;

  background: rgba(255, 255, 255, 0.07) !important;
  border-top: 1px solid rgba(255, 255, 255, 0.12) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12) !important;
  border-left: 0 !important;
  border-right: 0 !important;
  border-radius: 0 !important;
  list-style: none !important;
}

.store-footer ul.s-payments-list li {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  margin: 0 !important;
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

.store-footer ul.s-payments-list img,
.store-footer ul.s-payments-list svg {
  display: block !important;
  height: 30px !important;
  width: auto !important;
  max-width: 70px !important;
  padding: 6px 9px !important;
  background: #ffffff !important;
  border-radius: 8px !important;
  object-fit: contain !important;
}

/* للجوال */
@media (max-width: 768px) {
  .store-footer salla-payments.s-payments-list-wrap {
    padding: 0 !important;
  }

  .store-footer ul.s-payments-list {
    width: 100vw !important;
    max-width: 100vw !important;
    margin-right: 50% !important;
    transform: translateX(50%) !important;
    padding: 14px 12px !important;
    gap: 8px !important;
  }

  .store-footer ul.s-payments-list img,
  .store-footer ul.s-payments-list svg {
    height: 26px !important;
    max-width: 60px !important;
  }
}
/* تكبير أيقونات الدفع */
.store-footer ul.s-payments-list img,
.store-footer ul.s-payments-list svg {
  height: 42px !important;
  max-width: 96px !important;
  padding: 8px 12px !important;
  border-radius: 10px !important;
}

/* مساحة أكبر بين الأيقونات */
.store-footer ul.s-payments-list {
  gap: 14px !important;
  padding-top: 20px !important;
  padding-bottom: 20px !important;
}

/* الجوال */
@media (max-width: 768px) {
  .store-footer ul.s-payments-list img,
  .store-footer ul.s-payments-list svg {
    height: 34px !important;
    max-width: 82px !important;
    padding: 7px 10px !important;
  }

  .store-footer ul.s-payments-list {
    gap: 10px !important;
    padding-top: 16px !important;
    padding-bottom: 16px !important;
  }
}
/* =========================
   Contact footer clean style
========================= */

/* كرت تواصل معنا */
.store-footer__inner > div:has(a[href*="tel"]),
.store-footer__inner > div:has(a[href*="mailto"]),
.store-footer__inner > div:has(a[href*="wa.me"]),
.store-footer__inner > div:has(a[href*="whatsapp"]) {
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
}

/* عنوان تواصل معنا */
.store-footer__inner > div:has(a[href*="tel"]) h3,
.store-footer__inner > div:has(a[href*="mailto"]) h3,
.store-footer__inner > div:has(a[href*="wa.me"]) h3,
.store-footer__inner > div:has(a[href*="whatsapp"]) h3 {
  margin-bottom: 20px !important;
}

/* ترتيب عناصر التواصل */
.store-footer__inner > div:has(a[href*="tel"]) ul,
.store-footer__inner > div:has(a[href*="mailto"]) ul,
.store-footer__inner > div:has(a[href*="wa.me"]) ul,
.store-footer__inner > div:has(a[href*="whatsapp"]) ul {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  gap: 18px !important;
  width: 100% !important;
  padding: 0 !important;
  margin: 0 !important;
}

/* كل عنصر تواصل */
.store-footer__inner > div:has(a[href*="tel"]) li,
.store-footer__inner > div:has(a[href*="mailto"]) li,
.store-footer__inner > div:has(a[href*="wa.me"]) li,
.store-footer__inner > div:has(a[href*="whatsapp"]) li {
  width: 100% !important;
  display: flex !important;
  justify-content: center !important;
}

/* الرابط نفسه */
.store-footer__inner > div:has(a[href*="tel"]) a,
.store-footer__inner > div:has(a[href*="mailto"]) a,
.store-footer__inner > div:has(a[href*="wa.me"]) a,
.store-footer__inner > div:has(a[href*="whatsapp"]) a {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;

  width: 100% !important;
  max-width: 260px !important;
  padding: 10px 12px !important;
  border-radius: 14px !important;

  color: #cbd5e1 !important;
  background: rgba(255, 255, 255, 0.035) !important;
  border: 1px solid rgba(148, 163, 184, 0.14) !important;

  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease !important;
}

/* الأيقونة */
.store-footer__inner > div:has(a[href*="tel"]) a i,
.store-footer__inner > div:has(a[href*="mailto"]) a i,
.store-footer__inner > div:has(a[href*="wa.me"]) a i,
.store-footer__inner > div:has(a[href*="whatsapp"]) a i,
.store-footer__inner > div:has(a[href*="tel"]) a svg,
.store-footer__inner > div:has(a[href*="mailto"]) a svg,
.store-footer__inner > div:has(a[href*="wa.me"]) a svg,
.store-footer__inner > div:has(a[href*="whatsapp"]) a svg {
  width: 42px !important;
  height: 42px !important;
  min-width: 42px !important;

  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;

  color: #bfdbfe !important;
  border: 2px solid rgba(147, 197, 253, 0.85) !important;
  border-radius: 12px !important;
  padding: 9px !important;

  background: rgba(59, 130, 246, 0.08) !important;
  box-shadow: 0 0 0 rgba(59, 130, 246, 0) !important;
  animation: contactPulse 2.4s ease-in-out infinite !important;
}

/* Hover */
.store-footer__inner > div:has(a[href*="tel"]) a:hover,
.store-footer__inner > div:has(a[href*="mailto"]) a:hover,
.store-footer__inner > div:has(a[href*="wa.me"]) a:hover,
.store-footer__inner > div:has(a[href*="whatsapp"]) a:hover {
  transform: translateY(-3px) !important;
  background: rgba(34, 197, 94, 0.07) !important;
  border-color: rgba(34, 197, 94, 0.35) !important;
  color: #ffffff !important;
}

/* نبضة الأيقونات */
@keyframes contactPulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(147, 197, 253, 0.28);
    transform: scale(1);
  }

  50% {
    box-shadow: 0 0 0 8px rgba(147, 197, 253, 0);
    transform: scale(1.04);
  }
}

/* تقليل الحركة لمن يفضل بدون حركة */
@media (prefers-reduced-motion: reduce) {
  .store-footer__inner > div:has(a[href*="tel"]) a i,
  .store-footer__inner > div:has(a[href*="mailto"]) a i,
  .store-footer__inner > div:has(a[href*="wa.me"]) a i,
  .store-footer__inner > div:has(a[href*="whatsapp"]) a i,
  .store-footer__inner > div:has(a[href*="tel"]) a svg,
  .store-footer__inner > div:has(a[href*="mailto"]) a svg,
  .store-footer__inner > div:has(a[href*="wa.me"]) a svg,
  .store-footer__inner > div:has(a[href*="whatsapp"]) a svg {
    animation: none !important;
  }
}
/* حل نهائي لحقول خيارات المنتج في الوضع الداكن */
html.dark .s-product-options-option input.s-form-control,
body.dark .s-product-options-option input.s-form-control,
.dark .s-product-options-option input.s-form-control,
.dark .s-product-options-text input.s-form-control,
.dark input[id^="option-"].s-form-control {
  background-color: #0f172a !important;
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
  caret-color: #ffffff !important;

  border: 1px solid rgba(147, 197, 253, 0.75) !important;
  border-radius: 12px !important;
  box-shadow: none !important;

  height: 46px !important;
  min-height: 46px !important;
  padding: 10px 14px !important;

  font-size: 16px !important;
  font-weight: 500 !important;
  text-align: right !important;
  direction: rtl !important;
  opacity: 1 !important;
}

/* عند الضغط على الحقل */
html.dark .s-product-options-option input.s-form-control:focus,
body.dark .s-product-options-option input.s-form-control:focus,
.dark .s-product-options-option input.s-form-control:focus,
.dark .s-product-options-text input.s-form-control:focus,
.dark input[id^="option-"].s-form-control:focus {
  background-color: #111827 !important;
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
  border-color: #60a5fa !important;
  box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.28) !important;
  outline: none !important;
}

/* Placeholder */
html.dark .s-product-options-option input.s-form-control::placeholder,
body.dark .s-product-options-option input.s-form-control::placeholder,
.dark .s-product-options-option input.s-form-control::placeholder,
.dark .s-product-options-text input.s-form-control::placeholder,
.dark input[id^="option-"].s-form-control::placeholder {
  color: #cbd5e1 !important;
  -webkit-text-fill-color: #cbd5e1 !important;
  opacity: 1 !important;
}

/* تحسين عنوان الحقل */
.dark .s-product-options-option-label,
.dark .s-product-options-option label {
  color: #ffffff !important;
  font-weight: 700 !important;
}
/* إظهار السلة في هيدر الجوال */
@media (max-width: 768px) {
  salla-cart-summary,
  #desktop-cart,
  .s-cart-summary-wrapper,
  .s-cart-summary-icon,
  .s-cart-summary-count {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
  }

  salla-cart-summary {
    position: relative !important;
    z-index: 9999 !important;
    align-items: center !important;
    justify-content: center !important;
  }

  salla-cart-summary a,
  .s-cart-summary-wrapper {
    width: 42px !important;
    height: 42px !important;
    min-width: 42px !important;

    display: flex !important;
    align-items: center !important;
    justify-content: center !important;

    border-radius: 50% !important;
    background: rgba(96, 165, 250, 0.12) !important;
    border: 1px solid rgba(147, 197, 253, 0.35) !important;
  }

  .s-cart-summary-icon svg,
  .s-cart-summary-wrapper svg,
  salla-cart-summary svg {
    width: 23px !important;
    height: 23px !important;
    fill: #93c5fd !important;
    color: #93c5fd !important;
  }

  .s-cart-summary-count {
    position: absolute !important;
    top: -4px !important;
    right: -4px !important;

    min-width: 18px !important;
    height: 18px !important;
    padding: 0 5px !important;

    display: flex !important;
    align-items: center !important;
    justify-content: center !important;

    background: #60a5fa !important;
    color: #ffffff !important;
    border-radius: 999px !important;
    font-size: 11px !important;
    font-weight: 800 !important;
  }
}