:root {
  --primary: #259bea;
  --primary-dark: #1a7abf;
  --dark: #000;
  --text: #4a4a4a;
  --text-light: #8e8e8e;
  --bg-gray: #f7f8f8;
  --border: #efefef;
  --gold: #ffc108;
  --white: #fff;
  --primary-light: #e8f5fd;
  --topbar-bg: #000;
  --topbar-text: #ffdf86;
  --shadow: 0 1px 11px rgba(0,0,0,0.1);
  --radius: 8px;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Cairo', sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(--text);
  background: var(--white);
  direction: rtl;
  unicode-bidi: embed;
  overflow-x: hidden;
}
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; }
input, select, textarea, button { font-family: 'Cairo', sans-serif; }
textarea { resize: vertical; }
.container { max-width: 1130px; margin: 0 auto; padding: 0 15px; }


.top-bar {
  background: var(--topbar-bg);
  color: var(--topbar-text);
  text-align: center;
  font-weight: 700;
  font-size: 15px;
  overflow: hidden;
}
.top-bar-slider { display: flex; }
.top-bar-slide { min-width: 100%; padding: 10px 15px; line-height: 1.4; }

body { padding-top: 111px; }
@media (max-width: 991px) {
  body { padding-top: 101px; }
}


.header {
  background: var(--white);
  box-shadow: var(--shadow);
}

.sticky-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--white);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
  position: relative;
}
.logo { font-size: 28px; font-weight: 900; color: var(--dark); z-index: 10; }
.logo span { color: var(--primary); }
.logo img { height: 65px; width: auto; }


.nav-menu { display: flex; gap: 5px; }
.nav-menu a {
  padding: 8px 14px;
  font-weight: 700;
  font-size: 15px;
  color: var(--text);
  border-radius: 4px;
  transition: 0.2s;
}
.nav-menu a:hover, .nav-menu a.active { color: var(--primary); }


.header-icons { display: flex; align-items: center; gap: 8px; z-index: 10; }
.icon-btn {
  width: 50px; height: 50px;
  background: var(--bg-gray);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #4c4c4c;
  font-size: 26px;
  cursor: pointer;
  border: none;
  transition: 0.2s;
  position: relative;
}
.icon-btn:hover { background: #e8e8e8; }
.cart-count {
  position: absolute;
  top: -4px;
  left: -4px;
  background: red;
  color: #fff;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  border: 2px solid #fff;
}


.search-wrap { display: none; padding: 10px 0 18px; background: var(--white); }
.search-wrap.open { display: block; }
.search-form {
  display: flex;
  align-items: center;
  height: 44px;
  background: var(--bg-gray);
  border-radius: 50px;
  max-width: 600px;
  margin: 0 auto;
}
.search-form input {
  flex: 1;
  height: 100%;
  border: none;
  background: transparent;
  padding: 0 20px;
  font-family: 'Cairo', sans-serif;
  font-size: 14px;
  outline: none;
}
.search-form button {
  width: 44px; height: 44px;
  border: none;
  background: transparent;
  color: #4c4c4c;
  font-size: 15px;
  cursor: pointer;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}


  .mobile-trigger { display: none; }
  .header-search-btn { display: flex; }
#mobile-menu {
  position: fixed;
  top: 0;
  right: -320px;
  width: 320px;
  height: 100%;
  background: var(--white);
  z-index: 9999;
  transition: 0.3s ease;
  overflow-y: auto;
  padding: 60px 20px 20px;
  box-shadow: -5px 0 20px rgba(0,0,0,0.1);
}
#mobile-menu.open { right: 0; }
.mobile-close {
  position: absolute;
  top: 15px;
  left: 15px;
  width: 28px; height: 28px;
  background: #acacac;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 14px;
}
.mobile-menu-list li a {
  display: block;
  padding: 12px 15px;
  border-bottom: 1px solid #eee;
  font-weight: 600;
  color: #444;
  font-size: 15px;
}
.mobile-menu-list li a:hover { color: var(--primary); }
.mobile-search-input {
  width: 100%; padding: 10px 14px; border: 2px solid var(--border); border-radius: 10px;
  font-family: 'Cairo', sans-serif; font-size: 14px; outline: none; margin-top: 6px;
  background: #f5f7fa; direction: rtl;
}
.mobile-search-input:focus { border-color: var(--primary); background: #fff; }
#mobileSearchResults { display: none; margin-top: 4px; max-height: 300px; overflow-y: auto; }
.mobile-search-empty { padding: 12px; text-align: center; color: var(--text-light); font-size: 13px; }
.mobile-search-item { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; text-decoration: none; color: var(--text); transition: background 0.2s; }
.mobile-search-item:hover { background: #f0f4f8; }
.mobile-search-item img { width: 40px; height: 40px; border-radius: 6px; object-fit: cover; background: var(--bg); flex-shrink: 0; }
.mobile-search-title { font-size: 13px; font-weight: 600; line-height: 1.3; }
.mobile-search-price { font-size: 12px; color: var(--primary); font-weight: 700; }
.fly-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.5);
  z-index: 9998;
  opacity: 0;
  pointer-events: none;
  transition: 0.3s;
}
.fly-overlay.open { opacity: 1; pointer-events: auto; }


.hero {
  background: linear-gradient(135deg, rgba(26,26,46,0.45) 0%, rgba(22,33,62,0.45) 100%), url('https://i.ibb.co/KxLjc8vb/dddddddd.jpg') center/cover no-repeat fixed;
  color: #fff;
  padding: 80px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(37,155,234,0.15) 0%, transparent 60%);
  animation: heroGlow 6s ease-in-out infinite alternate;
}
@keyframes heroGlow {
  0% { transform: translate(0, 0); }
  100% { transform: translate(-30px, -30px); }
}
.hero-content { position: relative; z-index: 1; }
.hero h1 { font-size: 36px; font-weight: 900; margin-bottom: 10px; }
.hero p { font-size: 18px; opacity: 0.9; margin-bottom: 25px; }
.hero-btn {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  padding: 14px 40px;
  border-radius: 50px;
  font-weight: 700;
  font-size: 16px;
  transition: 0.3s;
  margin-bottom: 20px;
}
.hero-btn:hover { background: var(--primary-dark); transform: translateY(-2px); }


.hero-features {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 25px;
  flex-wrap: wrap;
}
.hero-feat {
  display: flex;
  align-items: center;
  gap: 8px;
  color: rgba(255,255,255,0.9);
  font-size: 14px;
  font-weight: 600;
}
.hero-feat i { font-size: 16px; color: var(--primary); }


.section { padding: 60px 0; }
.section-heading { text-align: center; margin-bottom: 35px; }
.section-title {
  display: inline-block;
  font-size: 26px;
  font-weight: 700;
  color: var(--dark);
  position: relative;
  margin-bottom: 8px;
}
.section-title::after {
  content: '';
  display: block;
  width: 100%;
  height: 6px;
  background: var(--primary);
  opacity: 0.6;
  position: absolute;
  bottom: -2px;
  left: 0;
  z-index: -1;
}
.section-subtitle { color: var(--text-light); font-size: 15px; }


.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
}
.product-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--white);
  transition: 0.3s;
  position: relative;
  display: flex;
  flex-direction: column;
}
.product-card:hover { box-shadow: 0 8px 25px rgba(0,0,0,0.12); transform: translateY(-3px); }
.product-img-wrap {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1/1;
  background: var(--bg-gray);
  cursor: pointer;
}
.product-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: 0.4s;
}
.product-card:hover .product-img-wrap img { transform: scale(1.05); }

.product-info {
  padding: 14px;
  text-align: center;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.product-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 4px;
  line-height: 1.3;
  cursor: pointer;
}
.product-title:hover { color: var(--primary); }
.stars {
  color: var(--gold);
  font-size: 12px;
  margin-bottom: 6px;
  direction: ltr;
  unicode-bidi: bidi-override;
}
.price {
  font-size: 16px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 10px;
}
.price del {
  font-size: 14px;
  font-weight: 400;
  color: var(--text-light);
  opacity: 0.7;
  margin-left: 5px;
}
.price ins { text-decoration: none; }
.add-cart-btn {
  display: block;
  width: calc(100% - 28px);
  margin: auto 14px 14px;
  padding: 11px 0;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 4px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  font-family: 'Cairo', sans-serif;
  transition: 0.3s;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 30'%3E%3Cpath d='M0,15 C200,0 400,30 600,15 C800,0 1000,30 1200,15 L1200,30 L0,30 Z' fill='rgba(255,255,255,0.08)'/%3E%3C/svg%3E");
  background-repeat: repeat-x;
  background-position: bottom;
}
.add-cart-btn:hover { background-color: var(--primary-dark); }


.breadcrumb {
  padding: 15px 0;
  font-size: 14px;
  color: var(--text-light);
}
.breadcrumb a { color: var(--primary); }
.breadcrumb span { color: var(--text); }
.product-detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
.product-gallery {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.product-gallery .main-img {
  width: 100%;
  max-height: 500px;
  aspect-ratio: 1/1;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--bg-gray);
}
.product-gallery .thumbs {
  display: flex;
  gap: 10px;
}
.product-gallery .thumbs img {
  flex: 1;
  width: 100px;
  height: 100px;
  object-fit: cover;
  border-radius: 6px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: 0.3s;
  max-width: 120px;
}
.product-gallery .thumbs img:hover { opacity: 0.8; }
.product-gallery .thumbs img.active { border-color: var(--primary); }
.product-info-detail h1 {
  font-size: 28px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 8px;
}
.product-info-detail .stars { font-size: 16px; margin-bottom: 10px; text-align: right; direction: rtl; }
.product-info-detail .price { font-size: 24px; margin-bottom: 15px; }
.product-info-detail .price del { font-size: 18px; }
.product-desc {
  font-size: 15px;
  line-height: 1.8;
  color: var(--text);
  margin-bottom: 20px;
}

.order-form-wrap {
  background: var(--bg-gray);
  border-radius: var(--radius);
  padding: 30px;
  border: 1px solid var(--border);
}
.order-form-wrap h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 25px;
  text-align: center;
  color: var(--dark);
}
.form-group { margin-bottom: 15px; }
.form-group label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 5px;
  color: var(--text);
}
.form-group input, .form-group select, .form-group textarea {
  width: 100%;
  padding: 12px 15px;
  border: 2px solid #e1e5e5;
  border-radius: 4px;
  font-size: 14px;
  outline: none;
  transition: 0.2s;
  background: var(--white);
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  border-color: var(--primary);
}
.form-group textarea { height: 80px; }
.submit-order {
  display: block;
  width: fit-content;
  margin: 10px auto 0;
  padding: 14px 40px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 50px;
  font-weight: 700;
  font-size: 18px;
  cursor: pointer;
  font-family: 'Cairo', sans-serif;
  transition: 0.3s;
  box-shadow: 0 4px 15px rgba(37,155,234,0.3);
}
.submit-order:hover { background: var(--primary-dark); transform: translateY(-2px); box-shadow: 0 6px 20px rgba(37,155,234,0.4); }


.pd2-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 15px;
}
.pd2-row .form-group { margin-bottom: 0; }
.phone-input { unicode-bidi: plaintext; text-align: right; }
.pd2-row .form-group input,
.pd2-row .form-group select {
  padding: 12px 15px;
  border: 2px solid #e1e5e5;
  border-radius: 8px;
  font-size: 14px;
  outline: none;
  transition: 0.2s;
  background: var(--white);
  width: 100%;
  direction: rtl;
}
.pd2-row .form-group input:focus,
.pd2-row .form-group select:focus {
  border-color: var(--primary);
}
.pd2-delivery-toggle {
  display: flex;
  gap: 10px;
  margin-bottom: 18px;
}
.pd2-del-btn {
  flex: 1;
  padding: 12px;
  text-align: center;
  border: 2px solid #e1e5e5;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  transition: 0.2s;
  background: var(--white);
  color: var(--text);
}
.pd2-del-btn:hover { border-color: var(--primary); }
.pd2-del-btn.active-pd2 {
  border-color: var(--primary);
  background: var(--primary);
  color: #fff;
}
.pd2-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
  align-items: center;
}
.pd2-btn-order {
  flex: 1;
  min-width: 140px;
  padding: 14px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  font-family: 'Cairo', sans-serif;
  transition: 0.3s;
}
.pd2-btn-order:hover { background: var(--primary-dark); }
.pd2-btn-cart {
  background: var(--white);
  color: var(--primary);
  border: 2px solid var(--primary);
}
.pd2-btn-cart:hover { background: var(--primary-light); color: var(--primary-dark); }
.pd2-qty-row {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 2px solid #e1e5e5;
  border-radius: 8px;
  padding: 4px;
  background: var(--white);
}
.pd2-qty-btn {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  cursor: pointer;
  font-size: 18px;
  font-weight: 700;
  background: var(--bg-gray);
  transition: 0.2s;
  user-select: none;
}
.pd2-qty-btn:hover { background: #ddd; }
.pd2-qty-num {
  min-width: 30px;
  text-align: center;
  font-size: 16px;
  font-weight: 700;
}
.pd2-summary {
  background: var(--white);
  border-radius: 8px;
  padding: 16px;
  border: 1px solid var(--border);
}
.pd2-summary-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 10px;
}
.pd2-summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  padding: 10px 0;
  color: var(--text);
}
.pd2-summary-total {
  border: 2px solid var(--primary);
  border-radius: 50px;
  margin-top: 10px;
  padding: 12px 20px;
  font-size: 18px;
  font-weight: 800;
  color: var(--dark);
  background: var(--primary-light);
}
.pd2-summary-total span:last-child { color: var(--primary); font-size: 20px; }


.cart-panel {
  position: fixed;
  top: 0;
  left: -380px;
  width: 380px;
  height: 100%;
  background: var(--white);
  z-index: 9999;
  transition: 0.3s ease;
  box-shadow: 5px 0 20px rgba(0,0,0,0.1);
  display: flex;
  flex-direction: column;
}
.cart-panel.open { left: 0; }
.cart-header {
  padding: 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.cart-header h3 { font-size: 18px; font-weight: 700; }
.cart-close {
  width: 30px; height: 30px;
  background: #acacac;
  border-radius: 50%;
  border: none;
  color: #fff;
  cursor: pointer;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cart-items { flex: 1; overflow-y: auto; padding: 15px; }
.cart-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.cart-item-img {
  width: 60px; height: 60px;
  border-radius: 6px;
  object-fit: cover;
  background: var(--bg-gray);
}
.cart-item-info { flex: 1; }
.cart-item-title { font-size: 14px; font-weight: 600; margin-bottom: 3px; }
.cart-item-price { font-size: 14px; color: var(--primary); font-weight: 700; }
.cart-item-qty { display: flex; align-items: center; gap: 8px; margin-top: 4px; }
.qty-btn {
  width: 26px; height: 26px;
  border: 1px solid #ddd;
  border-radius: 50%;
  background: none;
  cursor: pointer;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cart-item-remove { color: #ccc; cursor: pointer; font-size: 14px; transition: 0.2s; }
.cart-item-remove:hover { color: red; }
.cart-empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-light);
}
.cart-empty i { font-size: 48px; margin-bottom: 15px; opacity: 0.3; }
.cart-footer { padding: 20px; border-top: 1px solid var(--border); }
.cart-total {
  display: flex;
  justify-content: space-between;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 15px;
}
.cart-total span:last-child { color: var(--primary); }
.checkout-btn {
  width: 100%;
  padding: 14px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 4px;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  font-family: 'Cairo', sans-serif;
  transition: 0.3s;
}
.checkout-btn:hover { background: var(--primary-dark); }


.toast {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: #333;
  color: #fff;
  padding: 14px 24px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  z-index: 99999;
  transform: translateY(100px);
  opacity: 0;
  transition: 0.4s;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}
.toast.show { transform: translateY(0); opacity: 1; }


.call-icon {
  position: fixed;
  bottom: 30px;
  left: 20px;
  width: 50px; height: 50px;
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  z-index: 999;
  box-shadow: -1px 4px 10px rgba(0,0,0,0.25);
  cursor: pointer;
  animation: telRotate 8s ease infinite;
}
@keyframes telRotate {
  0%,100% { transform: rotate(0); }
  10%,30%,50%,70%,90% { transform: rotate(-10deg); }
  20%,40%,60%,80% { transform: rotate(10deg); }
}


.footer {
  background: #0d1b2a;
  color: #e0e0e0;
  padding: 60px 0 0;
  margin-top: 60px;
}
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 30px;
  margin-bottom: 40px;
}
.footer-col h4 {
  color: #259bea;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 10px;
}
.footer-col h4::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 40px;
  height: 3px;
  background: var(--primary);
}
.footer-col p { font-size: 14px; line-height: 1.8; margin-bottom: 10px; color: #ccc; }
.footer-col ul li { margin-bottom: 8px; }
.footer-col ul li a { font-size: 14px; color: #ccc; transition: 0.2s; }
.footer-col ul li a:hover { color: #fff; padding-right: 4px; }
.footer-contact li { display: flex; align-items: center; gap: 10px; font-size: 14px; color: #ccc; }
.footer-contact li i { width: 20px; color: var(--primary); }
.social-links { display: flex; gap: 10px; margin-top: 15px; }
.social-links a {
  width: 40px; height: 40px;
  background: rgba(255,255,255,0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  transition: 0.3s;
}
.social-links a:hover { background: var(--primary); transform: translateY(-3px); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.15);
  padding: 20px 0;
  text-align: center;
  font-size: 14px;
  color: #aaa;
}
.footer-bottom span { color: var(--primary); }


.page-section { padding: 50px 0; }
.page-section h1 { font-size: 30px; font-weight: 700; color: var(--dark); margin-bottom: 30px; text-align: center; }
.page-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
  margin-bottom: 25px;
}
.page-card h2 {
  font-size: 20px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.page-card h2 i { color: var(--primary); font-size: 22px; }
.page-card p, .page-card li { font-size: 15px; line-height: 1.8; color: var(--text); margin-bottom: 10px; }
.page-card ul { padding-right: 20px; list-style: disc; }
.page-card ul li { margin-bottom: 6px; }
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
}
.contact-info-card {
  background: var(--bg-gray);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 25px;
  text-align: center;
  transition: 0.3s;
}
.contact-info-card:hover { transform: translateY(-3px); box-shadow: 0 5px 20px rgba(0,0,0,0.08); }
.contact-info-card i { font-size: 36px; color: var(--primary); margin-bottom: 12px; }
.contact-info-card h3 { font-size: 16px; font-weight: 700; margin-bottom: 5px; color: var(--dark); }
.contact-info-card p { font-size: 14px; color: var(--text); margin: 0; direction: ltr; }
@media (max-width: 767px) {
  .contact-grid { grid-template-columns: 1fr; }
  .page-section { padding: 30px 0; }
  .page-section h1 { font-size: 24px; }
  .page-card { padding: 20px; }
}


.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.6);
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-overlay.open { display: flex; }
.modal {
  background: var(--white);
  border-radius: var(--radius);
  padding: 30px;
  max-width: 520px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}
.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}
.modal-header h3 { font-size: 20px; font-weight: 700; color: var(--dark); }
.modal-close {
  width: 32px; height: 32px;
  background: var(--bg-gray);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  font-size: 14px;
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: 0.2s;
}
.modal-close:hover { background: #ddd; }
.modal > p { font-size: 14px; color: var(--text-light); margin-bottom: 20px; }
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}


.loading {
  text-align: center;
  padding: 60px;
  color: var(--text-light);
}
.loading i { font-size: 40px; opacity: 0.3; margin-bottom: 15px; display: block; }


.thanks-box {
  max-width: 500px;
  margin: 40px auto;
  background: var(--white);
  border-radius: 16px;
  padding: 35px;
  border: 1px solid var(--border);
  text-align: center;
  box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}
.thanks-box i { font-size: 64px; color: #4caf50; margin-bottom: 12px; }
.thanks-box h2 { font-size: 24px; color: var(--dark); margin-bottom: 8px; }
.thanks-box p { color: var(--text); margin-bottom: 6px; font-size: 15px; }
.thanks-box .order-info {
  text-align: right;
  margin: 20px 0;
  padding: 18px;
  background: var(--bg-gray);
  border-radius: 10px;
  border: 1px solid var(--border);
}
.thanks-box .order-info div {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 0;
  font-size: 15px;
  border-bottom: 1px dashed #e8e8e8;
}
.thanks-box .order-info div:last-child { border-bottom: none; }
.thanks-box .order-info div span:first-child { color: var(--text-light); font-weight: 600; min-width: 70px; }
.thanks-box .order-info div span:last-child { color: var(--dark); font-weight: 700; }
.thanks-back {
  display: inline-block;
  margin-top: 18px;
  padding: 14px 40px;
  background: var(--primary);
  color: #fff;
  border-radius: 50px;
  font-weight: 700;
  font-size: 16px;
  transition: 0.3s;
  box-shadow: 0 4px 15px rgba(37,155,234,0.3);
}
.thanks-back:hover { background: var(--primary-dark); transform: translateY(-2px); }


@media (max-width: 991px) {
  .nav-menu { display: none; }
  .mobile-trigger { display: flex; }
  .header-search-btn { display: none !important; }
  .logo { font-size: 22px; }
  .header-inner { height: 60px; }
  .product-grid { grid-template-columns: repeat(auto-fill, minmax(165px, 1fr)); gap: 12px; }
  .section { padding: 40px 0; }
  .hero h1 { font-size: 28px; }
  .product-detail { grid-template-columns: 1fr; gap: 25px; }
  .order-form-wrap { padding: 20px; }
}
@media (max-width: 767px) {
  html, body { overflow-x: hidden; }
  .product-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .section-title { font-size: 22px; }
  .cart-panel { width: 100%; left: -100%; }
  .hero { padding: 40px 0; }
  .hero h1 { font-size: 22px; }
  .hero p { font-size: 15px; }
  .hero-features { gap: 12px; font-size: 13px; }
  .footer-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
  .product-info-detail h1 { font-size: 22px; }
  .product-info-detail .price { font-size: 20px; }
  .product-gallery .thumbs { flex-wrap: wrap; }
  .product-gallery .thumbs img { max-width: 80px; }
  .logo img { height: 55px; }
}
@media (max-width: 600px) {
  .pd2-row { grid-template-columns: 1fr 1fr; gap: 6px; }
  .pd2-actions { flex-direction: row; flex-wrap: wrap; gap: 6px; }
  .pd2-btn-order { min-width: 0; font-size: 13px; padding: 10px 6px; }
  .pd2-qty-row { align-self: stretch; justify-content: center; }
  .pd2-delivery-toggle { flex-direction: row; gap: 6px; }
}
@media (max-width: 500px) {
  .icon-btn { width: 44px; height: 44px; font-size: 22px; }
  .header-icons { gap: 4px; }
  .product-grid { gap: 8px; }
  .product-info { padding: 10px; }
  .product-title { font-size: 14px; }
  .price { font-size: 14px; }
  .add-cart-btn { font-size: 13px; padding: 9px 0; }
  .call-icon { width: 42px; height: 42px; font-size: 18px; left: 12px; bottom: 20px; }
  .toast { right: 15px; left: 15px; bottom: 15px; }
  .footer-grid { grid-template-columns: 1fr; gap: 25px; }
  .product-gallery { grid-template-columns: 1fr 1fr; gap: 6px; }
  .logo img { height: 45px; }
}


.admin-header {
  text-align: center;
  margin-bottom: 35px;
}
.admin-header h1 {
  font-size: 28px;
  font-weight: 700;
  color: var(--dark);
}
.admin-header h1 i { color: var(--primary); }
.admin-header p { color: var(--text-light); font-size: 15px; }
.admin-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
  align-items: start;
}
.admin-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 25px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.04);
}
.admin-card h2 {
  font-size: 18px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.admin-card h2 i { color: var(--primary); }
.admin-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.upload-area {
  border: 2px dashed #ccc;
  border-radius: 8px;
  padding: 35px 20px;
  text-align: center;
  cursor: pointer;
  transition: 0.3s;
  background: var(--bg-gray);
  margin-bottom: 10px;
}
.upload-area:hover { border-color: var(--primary); background: var(--primary-light); }
.upload-area.dragover { border-color: var(--primary); background: var(--primary-light); }
.upload-area i { font-size: 42px; color: #bbb; margin-bottom: 8px; display: block; }
.upload-area p { font-size: 15px; font-weight: 600; color: var(--text); }
.upload-area span { font-size: 13px; color: var(--text-light); }
.admin-attach-btn {
  display: block;
  width: 100%;
  padding: 12px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  font-family: 'Cairo', sans-serif;
  transition: 0.3s;
}
.admin-attach-btn:hover { background: var(--primary-dark); }
.admin-attach-btn i { margin-left: 6px; }


.gallery-preview {
  margin: 15px 0;
}
.gallery-main {
  width: 100%;
  aspect-ratio: 1/1;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg-gray);
  margin-bottom: 8px;
}
.gallery-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.gallery-thumbs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.gallery-thumbs .thumb-item {
  width: 70px;
  height: 70px;
  border-radius: 6px;
  overflow: hidden;
  cursor: pointer;
  border: 2px solid transparent;
  transition: 0.2s;
  position: relative;
}
.gallery-thumbs .thumb-item:hover { opacity: 0.8; }
.gallery-thumbs .thumb-item.active { border-color: var(--primary); }
.gallery-thumbs .thumb-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.gallery-thumbs .thumb-item .remove-img {
  position: absolute;
  top: -6px;
  right: -6px;
  width: 20px;
  height: 20px;
  background: #e53935;
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 10px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 4px rgba(0,0,0,0.2);
}
#uploadStatus {
  font-size: 14px;
  margin: 10px 0;
  text-align: center;
}
.admin-submit {
  display: block;
  width: 100%;
  padding: 14px;
  background: #4caf50;
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: 17px;
  font-weight: 700;
  cursor: pointer;
  font-family: 'Cairo', sans-serif;
  transition: 0.3s;
}
.admin-submit:hover { background: #388e3c; }
.admin-submit:disabled { opacity: 0.6; cursor: not-allowed; }


.admin-product-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.admin-product-item:last-child { border-bottom: none; }
.admin-product-item img {
  width: 50px;
  height: 50px;
  border-radius: 6px;
  object-fit: cover;
  background: var(--bg-gray);
}
.admin-product-info { flex: 1; }
.admin-product-info .ap-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--dark);
}
.admin-product-info .ap-price {
  font-size: 13px;
  color: var(--primary);
  font-weight: 600;
}
.admin-product-info .ap-date {
  font-size: 12px;
  color: var(--text-light);
}
.admin-product-delete {
  width: 30px;
  height: 30px;
  background: #fff0f0;
  border: none;
  border-radius: 50%;
  color: #e53935;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: 0.2s;
}
.admin-product-delete:hover { background: #e53935; color: #fff; }
@media (max-width: 991px) {
  .admin-grid { grid-template-columns: 1fr; }
}
@media (max-width: 767px) {
  .admin-row { grid-template-columns: 1fr; }
  .admin-card { padding: 18px; }
  .admin-header h1 { font-size: 22px; }
}
