/* ==========================================================
   متجر سند للهدايا — نظام التصميم
   هادئ. أنيق. أبدي.
   ========================================================== */
:root {
  --bg: #FAF6F1;
  --surface: #FFFFFF;
  --ink: #3F342E;
  --muted: #8B7B6E;
  --rose: #C98A96;
  --rose-deep: #A85D68;
  --rose-soft: #F6E7E9;
  --sage: #8FA98F;
  --sage-deep: #5F7F63;
  --sage-soft: #EAF0E6;
  --gold: #C6A15B;
  --gold-deep: #A88640;
  --gold-soft: #F3E9D4;
  --line: #EEE4D8;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 10px 30px rgba(96, 62, 52, 0.09);
  --shadow-sm: 0 4px 14px rgba(96, 62, 52, 0.07);
  --font-head: 'El Messiri', 'Tajawal', sans-serif;
  --font-body: 'Tajawal', 'Segoe UI', sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
main { flex: 1; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; font-size: 1rem; }

.container { width: min(1200px, 92%); margin-inline: auto; }
h1, h2, h3, h4 { font-family: var(--font-head); font-weight: 700; line-height: 1.4; }

/* ---------- الأزرار ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 26px; border-radius: 999px; border: none;
  font-size: 1rem; font-weight: 700; transition: all .25s ease;
}
.btn-primary { background: var(--rose-deep); color: #fff; box-shadow: 0 8px 20px rgba(168, 93, 104, .3); }
.btn-primary:hover { background: #944A55; transform: translateY(-2px); }
.btn-ghost { background: transparent; color: var(--rose-deep); border: 1.5px solid var(--rose-deep); }
.btn-ghost:hover { background: var(--rose-soft); }
.btn-gold { background: var(--gold); color: #fff; }
.btn-gold:hover { background: var(--gold-deep); transform: translateY(-2px); }
.btn-sm { padding: 8px 18px; font-size: .9rem; }
.btn-block { width: 100%; }
.btn:disabled { opacity: .6; cursor: not-allowed; transform: none; }

/* ---------- الهيدر ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250, 246, 241, 0.88);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow .3s;
}
.site-header.scrolled { box-shadow: var(--shadow-sm); }

/* شريط الإعلان العلوي */
.announce-bar {
  background: linear-gradient(90deg, var(--gold), var(--rose) 35%, var(--rose-deep) 50%, var(--rose) 65%, var(--gold));
  background-size: 200% 100%;
  color: #fff; text-align: center;
  font-size: .76rem; font-weight: 700; padding: 6px 10px;
  letter-spacing: .3px;
  animation: announceShift 7s linear infinite;
}
@keyframes announceShift { 0% { background-position: 0 0; } 100% { background-position: 200% 0; } }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 0; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand-emblem { width: 46px; height: 46px; flex-shrink: 0; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-name { font-family: var(--font-head); font-size: 1.55rem; font-weight: 700; color: var(--ink); }
.brand-sub { font-size: .78rem; color: var(--rose-deep); letter-spacing: .5px; font-weight: 500; }
.main-nav { display: flex; gap: 6px; }
.main-nav a {
  padding: 8px 16px; border-radius: 999px; font-weight: 500; color: var(--ink);
  transition: all .2s;
}
.main-nav a:hover, .main-nav a.active { background: var(--rose-soft); color: var(--rose-deep); }
.header-actions { display: flex; align-items: center; gap: 10px; }
.cart-btn {
  position: relative; display: inline-flex; align-items: center; gap: 8px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 999px;
  padding: 9px 16px; font-weight: 700; color: var(--ink); transition: all .2s;
}
.cart-btn:hover { border-color: var(--rose); color: var(--rose-deep); }
.cart-badge {
  background: var(--rose-deep); color: #fff; border-radius: 999px;
  min-width: 22px; height: 22px; display: inline-flex; align-items: center; justify-content: center;
  font-size: .75rem; padding: 0 6px;
}
.cart-total-mini { font-size: .8rem; color: var(--muted); font-weight: 500; }
.hamburger { display: none; background: none; border: none; width: 42px; height: 42px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); }
.hamburger svg { margin: auto; }

/* قائمة الموبايل الجانبية */
.mobile-nav {
  position: fixed; inset: 0; z-index: 90; pointer-events: none;
}
.mobile-nav .overlay { position: absolute; inset: 0; background: rgba(63, 52, 46, .4); opacity: 0; transition: opacity .3s; }
.mobile-nav .panel {
  position: absolute; top: 0; right: 0; bottom: 0; width: min(300px, 82%);
  background: var(--bg); padding: 24px; transform: translateX(100%); transition: transform .3s ease;
  display: flex; flex-direction: column; gap: 6px;
}
.mobile-nav.open { pointer-events: auto; }
.mobile-nav.open .overlay { opacity: 1; }
.mobile-nav.open .panel { transform: none; }
.mobile-nav .panel a { padding: 13px 16px; border-radius: var(--radius-sm); font-weight: 700; font-size: 1.05rem; }
.mobile-nav .panel a:hover { background: var(--rose-soft); }
.mobile-nav .panel .close-btn { align-self: flex-start; margin-bottom: 12px; }

/* شريط الموبايل السفلي */
.mobile-bar {
  display: none; position: fixed; bottom: 0; right: 0; left: 0; z-index: 60;
  background: rgba(255, 255, 255, .95); backdrop-filter: blur(10px);
  border-top: 1px solid var(--line);
}
.mobile-bar a {
  flex: 1; text-align: center; padding: 9px 0 10px; font-size: .72rem; color: var(--muted); font-weight: 500;
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  position: relative;
}
.mobile-bar a.active { color: var(--rose-deep); }
.mobile-bar a svg { width: 22px; height: 22px; }
.mobile-bar .bar-badge {
  position: absolute; top: 3px; inset-inline-end: calc(50% - 22px);
  background: var(--rose-deep); color: #fff; border-radius: 999px;
  font-size: .6rem; font-weight: 800; min-width: 16px; height: 16px;
  display: flex; align-items: center; justify-content: center; padding: 0 4px;
}
.mobile-bar .bar-badge[hidden] { display: none; }

/* ---------- الهيرو ---------- */
.hero { padding: 46px 0 30px; overflow: hidden; }
.hero-inner { display: grid; grid-template-columns: 1.05fr 1fr; gap: 40px; align-items: center; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--gold-soft); color: var(--gold-deep);
  border-radius: 999px; padding: 6px 16px; font-size: .85rem; font-weight: 700; margin-bottom: 18px;
}
.hero h1 { font-size: clamp(1.9rem, 4.2vw, 3.1rem); margin-bottom: 14px; }
.hero h1 .accent { color: var(--rose-deep); }
.hero .subtitle { font-size: 1.1rem; color: var(--muted); margin-bottom: 10px; font-weight: 500; }
.hero .tagline { color: var(--gold-deep); font-family: var(--font-head); font-size: 1.05rem; margin-bottom: 26px; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-visual { position: relative; }
.hero-visual > img { width: 100%; border-radius: 32px; box-shadow: var(--shadow); background: #fff; aspect-ratio: 16/9; object-fit: cover; }
.float-chip {
  position: absolute; background: rgba(255,255,255,.92); backdrop-filter: blur(6px);
  border: 1px solid var(--line); border-radius: 999px; padding: 8px 16px;
  font-size: .85rem; font-weight: 700; box-shadow: var(--shadow-sm);
  display: flex; align-items: center; gap: 7px;
  animation: floaty 4s ease-in-out infinite;
}
.float-chip.c1 { top: 10%; inset-inline-start: -4%; animation-delay: 0s; }
.float-chip.c2 { bottom: 22%; inset-inline-end: -3%; animation-delay: 1.2s; }
.float-chip.c3 { bottom: -3%; inset-inline-start: 12%; animation-delay: 2.2s; }
@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }

/* ---------- شريط المزايا ---------- */
.features { padding: 22px 0 8px; }
.features-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.feature-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 20px; display: flex; align-items: center; gap: 13px; box-shadow: var(--shadow-sm);
}
.feature-card .fi { font-size: 1.6rem; }
.feature-card b { display: block; font-size: .98rem; }

/* ---------- عناوين الأقسام ---------- */
.section { padding: 46px 0 10px; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 14px; margin-bottom: 24px; }
.section-head h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); position: relative; padding-inline-start: 16px; }
.section-head h2::before {
  content: ''; position: absolute; inset-inline-start: 0; top: 8px; bottom: 8px;
  width: 5px; border-radius: 999px; background: linear-gradient(var(--rose), var(--gold));
}
.section-head .more-link { color: var(--rose-deep); font-weight: 700; font-size: .95rem; white-space: nowrap; }
.section-head .more-link:hover { text-decoration: underline; }

/* ---------- بطاقات الأقسام ---------- */
.cats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.cat-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow-sm); transition: all .3s ease; display: flex; flex-direction: column;
}
.cat-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.cat-card img { height: 160px; width: 100%; object-fit: cover; }
.cat-card .cc-body { padding: 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.cat-card h3 { font-size: 1.12rem; }
.cat-card p { font-size: .85rem; color: var(--muted); flex: 1; }
.cat-card .browse { color: var(--rose-deep); font-weight: 700; font-size: .9rem; display: inline-flex; align-items: center; gap: 6px; }

/* ---------- شبكة المنتجات ---------- */
.products-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.product-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow-sm); transition: all .3s ease;
  display: flex; flex-direction: column; position: relative;
}
.product-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.pc-img-wrap { position: relative; aspect-ratio: 1/1; overflow: hidden; background: #F3ECE4; }
.pc-img-wrap img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.product-card:hover .pc-img-wrap img { transform: scale(1.05); }

.pc-flag.out { color: #9AA0A6; }
.pc-body { padding: 14px 15px 16px; display: flex; flex-direction: column; gap: 7px; flex: 1; }
.pc-cat { font-size: .72rem; color: var(--gold-deep); font-weight: 700; }
.pc-name { font-size: .98rem; font-weight: 700; line-height: 1.5; display: block; color: var(--ink); }
.pc-name:hover { color: var(--rose-deep); }
.pc-price { font-weight: 800; color: var(--rose-deep); font-size: 1.02rem; }
.pc-price small { color: var(--muted); font-weight: 500; font-size: .78rem; }
.pc-stock { font-size: .78rem; font-weight: 700; color: var(--sage-deep); }
.pc-stock.out { color: #B0553F; }
.pc-add { margin-top: auto; }

/* ---------- صفحة المتجر ---------- */
.page-title { text-align: center; padding: 34px 0 6px; }
.page-title h1 { font-size: clamp(1.7rem, 3.5vw, 2.4rem); }
.page-title p { color: var(--muted); font-size: .95rem; }
.shop-tools { display: flex; gap: 10px; align-items: center; margin: 18px 0 8px; flex-wrap: wrap; }
.search-box { flex: 1; min-width: 220px; position: relative; }
.search-box input {
  width: 100%; padding: 11px 42px 11px 16px; border-radius: 999px; border: 1.5px solid var(--line);
  background: var(--surface); outline: none; transition: border .2s;
}
.search-box input:focus { border-color: var(--rose); }
.search-box svg { position: absolute; inset-inline-end: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.sort-select {
  padding: 11px 16px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--surface);
  outline: none; font-weight: 500; cursor: pointer;
}
.chips { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0 22px; }
.chip {
  padding: 8px 18px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--surface);
  font-size: .88rem; font-weight: 700; color: var(--ink); transition: all .2s;
}
.chip:hover { border-color: var(--rose); color: var(--rose-deep); }
.chip.active { background: var(--rose-deep); border-color: var(--rose-deep); color: #fff; }
.load-more-wrap { text-align: center; padding: 26px 0 40px; }
.empty-state { text-align: center; padding: 60px 0; color: var(--muted); }
.empty-state .big { font-size: 3rem; margin-bottom: 10px; }

/* ---------- صفحة المنتج ---------- */
.product-page { display: grid; grid-template-columns: 1fr 1fr; gap: 36px; padding: 34px 0; align-items: start; }
.gallery .main-img { border-radius: var(--radius); overflow: hidden; background: #F3ECE4; border: 1px solid var(--line); aspect-ratio: 1/1; }
.gallery .main-img img { width: 100%; height: 100%; object-fit: cover; }
.thumbs { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.thumbs img { width: 72px; height: 72px; object-fit: cover; border-radius: var(--radius-sm); border: 2px solid transparent; cursor: pointer; background: #F3ECE4; }
.thumbs img.active { border-color: var(--rose-deep); }
.pp-info h1 { font-size: clamp(1.4rem, 2.6vw, 2rem); margin-bottom: 8px; }
.pp-cat-link { color: var(--gold-deep); font-weight: 700; font-size: .88rem; }
.pp-price { font-size: 1.7rem; font-weight: 800; color: var(--rose-deep); margin: 12px 0 4px; }
.pp-price small { font-size: .95rem; color: var(--muted); font-weight: 500; }
.pp-desc { color: var(--muted); margin: 12px 0 18px; }
.stock-badge { display: inline-flex; align-items: center; gap: 7px; font-size: .85rem; font-weight: 700; margin-bottom: 16px; }
.stock-badge .dot { width: 9px; height: 9px; border-radius: 50%; }
.stock-badge.in { color: var(--sage-deep); } .stock-badge.in .dot { background: var(--sage-deep); }
.stock-badge.out { color: #B0553F; } .stock-badge.out .dot { background: #B0553F; }
.variant-group { margin-bottom: 16px; }
.variant-group .vg-label { font-weight: 700; font-size: .92rem; margin-bottom: 8px; }
.variant-options { display: flex; gap: 8px; flex-wrap: wrap; }
.vopt {
  padding: 9px 18px; border-radius: var(--radius-sm); border: 1.5px solid var(--line); background: var(--surface);
  font-weight: 700; font-size: .9rem; transition: all .2s;
}
.vopt:hover { border-color: var(--rose); }
.vopt.active { background: var(--rose-deep); border-color: var(--rose-deep); color: #fff; }
.vopt .vprice { display: block; font-size: .72rem; color: var(--gold-deep); }
.vopt.active .vprice { color: #FBE9C8; }
.pp-actions { display: flex; gap: 12px; margin: 20px 0 8px; flex-wrap: wrap; }
.qty-stepper {
  display: inline-flex; align-items: center; border: 1.5px solid var(--line); border-radius: 999px; background: var(--surface); overflow: hidden;
}
.qty-stepper button { width: 42px; height: 46px; border: none; background: none; font-size: 1.25rem; color: var(--rose-deep); font-weight: 800; }
.qty-stepper button:hover { background: var(--rose-soft); }
.qty-stepper input { width: 44px; text-align: center; border: none; font-weight: 800; outline: none; background: none; }
.pp-meta { font-size: .83rem; color: var(--muted); margin-top: 10px; }

/* ---------- السلة (الدرج) ---------- */
.cart-drawer { position: fixed; inset: 0; z-index: 95; pointer-events: none; }
.cart-drawer .overlay { position: absolute; inset: 0; background: rgba(63,52,46,.45); opacity: 0; transition: opacity .3s; }
.cart-drawer .panel {
  position: absolute; top: 0; left: 0; bottom: 0; width: min(400px, 92%);
  background: var(--bg); display: flex; flex-direction: column;
  transform: translateX(-105%); transition: transform .32s ease;
  box-shadow: var(--shadow);
}
[dir="rtl"] .cart-drawer .panel { left: auto; right: 0; transform: translateX(105%); }
.cart-drawer.open { pointer-events: auto; }
.cart-drawer.open .overlay { opacity: 1; }
.cart-drawer.open .panel { transform: none; }
.cd-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px; border-bottom: 1px solid var(--line); }
.cd-head h3 { font-size: 1.15rem; }
.cd-items { flex: 1; overflow-y: auto; padding: 16px 20px; display: flex; flex-direction: column; gap: 14px; }
.cd-item { display: flex; gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px; }
.cd-item img { width: 64px; height: 64px; border-radius: 10px; object-fit: cover; flex-shrink: 0; }
.cd-item .info { flex: 1; min-width: 0; }
.cd-item .nm { font-size: .88rem; font-weight: 700; line-height: 1.4; }
.cd-item .vr { font-size: .75rem; color: var(--muted); }
.cd-item .pr { font-size: .85rem; font-weight: 800; color: var(--rose-deep); }
.cd-item .qty-mini { display: inline-flex; align-items: center; gap: 2px; margin-top: 6px; }
.cd-item .qty-mini button { width: 26px; height: 26px; border-radius: 8px; border: 1px solid var(--line); background: #fff; font-weight: 800; color: var(--rose-deep); }
.cd-item .rm { background: none; border: none; color: #C4A69B; font-size: 1.1rem; align-self: flex-start; }
.cd-foot { border-top: 1px solid var(--line); padding: 16px 20px; background: var(--surface); }
.cd-total { display: flex; justify-content: space-between; font-weight: 800; margin-bottom: 12px; }
.cd-empty { text-align: center; color: var(--muted); padding: 46px 10px; }

/* ---------- صفحة السلة والطلب ---------- */
.cart-layout { display: grid; grid-template-columns: 1.6fr 1fr; gap: 24px; padding: 10px 0 50px; align-items: start; }
.cart-list { display: flex; flex-direction: column; gap: 12px; }
.cart-row {
  display: flex; gap: 14px; align-items: center; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius); padding: 14px;
}
.cart-row img { width: 84px; height: 84px; border-radius: var(--radius-sm); object-fit: cover; }
.cart-row .cr-info { flex: 1; min-width: 0; }
.cart-row .cr-name { font-weight: 700; }
.cart-row .cr-variant { font-size: .8rem; color: var(--muted); }
.cart-row .cr-price { color: var(--rose-deep); font-weight: 800; margin-top: 4px; }
.summary-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; box-shadow: var(--shadow-sm); position: sticky; top: 90px;
}
.summary-card h3 { margin-bottom: 14px; font-size: 1.15rem; }
.sum-row { display: flex; justify-content: space-between; padding: 7px 0; font-size: .95rem; color: var(--muted); }
.sum-row.total { border-top: 1px dashed var(--line); margin-top: 8px; padding-top: 14px; color: var(--ink); font-weight: 800; font-size: 1.1rem; }

/* النماذج */
.form-grid { display: grid; gap: 14px; }
.form-group label { display: block; font-weight: 700; font-size: .9rem; margin-bottom: 6px; }
.form-group label .req { color: var(--rose-deep); }
.form-group input, .form-group select, .form-group textarea {
  width: 100%; padding: 12px 14px; border-radius: var(--radius-sm); border: 1.5px solid var(--line);
  background: var(--surface); outline: none; transition: border .2s;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { border-color: var(--rose); }
.form-group textarea { min-height: 88px; resize: vertical; }
.form-error { color: #B0553F; font-size: .85rem; margin-top: 4px; display: none; }
.form-group.invalid input, .form-group.invalid select, .form-group.invalid textarea { border-color: #D98A73; }
.form-group.invalid .form-error { display: block; }
.hp-field { position: absolute; inset-inline-start: -9999px; opacity: 0; height: 0; overflow: hidden; }

/* ---------- شكراً ---------- */
.thanks-wrap { text-align: center; padding: 60px 0 80px; }
.thanks-check {
  width: 92px; height: 92px; margin: 0 auto 22px; border-radius: 50%;
  background: var(--sage-soft); display: flex; align-items: center; justify-content: center;
  animation: pop .5s cubic-bezier(.2, 1.6, .5, 1);
}
.thanks-check svg { width: 46px; height: 46px; color: var(--sage-deep); }
@keyframes pop { 0% { transform: scale(.4); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
.order-no-box {
  display: inline-block; background: var(--surface); border: 2px dashed var(--gold);
  border-radius: var(--radius); padding: 12px 30px; font-weight: 800; font-size: 1.25rem;
  letter-spacing: 1px; color: var(--gold-deep); margin: 14px 0 10px;
}

/* ---------- صفحات عن المتجر / تواصل ---------- */
.prose-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 34px; box-shadow: var(--shadow-sm); max-width: 860px; margin: 0 auto; }
.prose-card p { margin-bottom: 12px; color: #5C4F45; }
.contact-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 16px; max-width: 900px; margin: 26px auto; }
.contact-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; text-align: center; box-shadow: var(--shadow-sm); }
.contact-card .ci { font-size: 2rem; margin-bottom: 10px; }
.contact-card b { display: block; margin-bottom: 4px; }
.contact-card a { color: var(--rose-deep); font-weight: 700; direction: ltr; unicode-bidi: embed; }

/* ---------- الفوتر ---------- */
.site-footer { background: #F3EBE1; border-top: 1px solid var(--line); margin-top: 50px; padding: 46px 0 0; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1.3fr; gap: 30px; padding-bottom: 34px; }
.footer-grid h4 { margin-bottom: 14px; font-size: 1.05rem; }
.footer-grid p, .footer-grid a { color: #6E5F53; font-size: .92rem; }
.footer-grid ul { list-style: none; display: flex; flex-direction: column; gap: 9px; }
.footer-grid a:hover { color: var(--rose-deep); }
.socials { display: flex; gap: 10px; margin-top: 8px; }
.socials a {
  width: 40px; height: 40px; border-radius: 50%; background: var(--surface);
  display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--line);
  transition: all .25s;
}
.socials a:hover { background: var(--rose-deep); border-color: var(--rose-deep); color: #fff; transform: translateY(-3px); }
.socials svg { width: 18px; height: 18px; }
.copyright { border-top: 1px solid #E5D9C9; text-align: center; padding: 16px 0; font-size: .83rem; color: #94846F; }
.copyright b { color: var(--gold-deep); }

/* ---------- توست ---------- */
.toast-wrap { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); z-index: 120; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast {
  background: var(--ink); color: #fff; border-radius: 999px; padding: 11px 24px;
  font-size: .9rem; font-weight: 500; box-shadow: var(--shadow); animation: toastIn .3s ease;
  max-width: 90vw; text-align: center;
}
.toast.success { background: var(--sage-deep); }
.toast.error { background: #B0553F; }
@keyframes toastIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

/* ---------- حركات دخول ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s ease; }
.reveal.visible { opacity: 1; transform: none; }
@keyframes riseIn { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.hero-copy { animation: riseIn .7s ease both; }
.hero-visual { animation: riseIn .85s .12s ease both; }

/* ---------- ريسبونسف ---------- */
@media (max-width: 1024px) {
  .cats-grid, .products-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 820px) {
  .main-nav, .cart-total-mini { display: none; }
  .hamburger { display: block; }
  .hero-inner { grid-template-columns: 1fr; gap: 26px; }
  .hero-copy { text-align: center; }
  .hero-cta { justify-content: center; }
  .hero-visual { max-width: 520px; margin: 0 auto; }
  .features-grid { grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .feature-card { flex-direction: column; text-align: center; gap: 4px; padding: 12px 6px; }
  .feature-card .fi { font-size: 1.15rem; }
  .feature-card b { font-size: .68rem; line-height: 1.4; }
  .product-page { grid-template-columns: 1fr; gap: 24px; padding-bottom: 150px; }
  /* شريط الشراء الثابت أسفل صفحة المنتج */
  .pp-actions {
    position: fixed; bottom: 62px; right: 0; left: 0; z-index: 55;
    background: rgba(250, 246, 241, .96); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
    border-top: 1px solid var(--line);
    padding: 10px 4% calc(12px + env(safe-area-inset-bottom, 0px));
    margin: 0; flex-wrap: nowrap;
  }
  .pp-actions .btn { flex: 1; padding-inline: 8px; font-size: .95rem; }
  .pp-actions .qty-stepper button { width: 36px; }
  .pp-actions .qty-stepper input { width: 34px; }
  .pp-meta { display: none; }
  .cart-layout { grid-template-columns: 1fr; }
  .summary-card { position: static; }
  .mobile-bar { display: flex; }
  body { padding-bottom: 62px; }
  .site-footer { margin-top: 30px; }
}
@media (max-width: 640px) {
  .cats-grid, .products-grid { grid-template-columns: repeat(2, 1fr); gap: 11px; }
  /* 3 منتجات بكل سطر على الموبايل */
  .products-grid { grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .products-grid .pc-body { padding: 9px 8px 10px; gap: 4px; }
  .products-grid .pc-name { font-size: .8rem; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .products-grid .pc-price { font-size: .82rem; }
  .products-grid .pc-stock { font-size: .68rem; }
  .products-grid .pc-add { font-size: .74rem; padding: 7px 6px; }
  .products-grid .pc-cat { display: none; }
  .cat-card img { height: 120px; }
  /* الأقسام بتمرير أفقي أنيق على الموبايل */
  .cats-grid {
    display: flex; overflow-x: auto; scroll-snap-type: x mandatory;
    gap: 12px; padding-bottom: 10px;
    margin-inline: -4%; padding-inline: 4%;
    scrollbar-width: none;
  }
  .cats-grid::-webkit-scrollbar { display: none; }
  .cats-grid .cat-card { flex: 0 0 41%; scroll-snap-align: start; }
  .cats-grid .cat-card img { height: 96px; }
  .cats-grid .cc-body { padding: 10px 11px 12px; gap: 4px; }
  .cats-grid .cat-card h3 { font-size: .92rem; }
  .cats-grid .cat-card p { font-size: .72rem; }
  .cats-grid .browse { font-size: .78rem; }
  .product-card:active { transform: scale(.98); }
  .float-chip { font-size: .74rem; padding: 6px 12px; }
  .brand-name { font-size: 1.3rem; }
  .brand-emblem { width: 40px; height: 40px; }
  .cart-btn { padding: 8px 12px; }
  .footer-grid { grid-template-columns: 1fr; gap: 20px; }
  .prose-card { padding: 22px; }
  .section { padding: 34px 0 8px; }
  .page-title { padding-top: 24px; }
  .features-grid { gap: 6px; }

  .feature-card { padding: 10px 4px; }
  .feature-card b { font-size: .62rem; }
  .feature-card .fi { font-size: 1rem; }
  .btn { padding: 9px 18px; font-size: .88rem; }
  .btn-sm { padding: 7px 13px; font-size: .8rem; }
  .pc-add { padding: 8px 6px !important; font-size: .74rem !important; }
  .pp-actions .btn { font-size: .88rem; padding: 11px 8px; }
  .qty-stepper button { width: 34px; height: 40px; }
  .qty-stepper input { width: 32px; }
  .hero { padding: 24px 0 18px; }
}

/* ---------- عناصر الترقية الكبرى ---------- */
.pc-price .old, .pp-price .old { color: var(--muted); text-decoration: line-through; font-weight: 500; font-size: .55em; vertical-align: middle; margin-inline-end: 6px; }
.pc-wish {
  position: absolute; top: 4px; inset-inline-end: 6px; z-index: 3;
  width: 30px; height: 30px; border: none; background: transparent;
  color: #fff; font-size: 1.25rem; line-height: 1;
  text-shadow: 0 1px 6px rgba(0,0,0,.55); transition: all .2s;
}
.pc-wish:hover { transform: scale(1.18); }
.pc-wish.active { color: #FF4D6D; text-shadow: 0 1px 6px rgba(0,0,0,.45); }
.pc-wish.active { color: var(--rose-deep); background: var(--rose-soft); }
.wa-float {
  position: fixed; bottom: 76px; inset-inline-start: 16px; z-index: 58;
  width: 52px; height: 52px; border-radius: 50%;
  background: #25D366; color: #fff; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 22px rgba(37, 211, 102, .4);
  animation: floaty 4s ease-in-out infinite;
}
.wa-float svg { width: 27px; height: 27px; }
.wa-float:hover { transform: scale(1.08); }
.coupon-row { display: flex; gap: 8px; margin: 10px 0; }
.coupon-row input { flex: 1; padding: 11px 14px; border-radius: var(--radius-sm); border: 1.5px solid var(--line); background: var(--surface); outline: none; text-transform: uppercase; }
.coupon-ok { color: var(--sage-deep); font-weight: 700; font-size: .88rem; }
.summary-card .free-del { color: var(--sage-deep); font-weight: 800; }
.track-card { max-width: 560px; margin: 0 auto; }
.track-steps { display: flex; flex-direction: column; gap: 0; margin: 18px 0; }
.track-step { display: flex; gap: 14px; align-items: flex-start; }
.track-step .dot {
  width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  background: #EDE4D8; color: #B7A897; flex-shrink: 0; font-size: 1rem;
}
.track-step.done .dot { background: var(--sage-soft); color: var(--sage-deep); }
.track-step.current .dot { background: var(--rose-deep); color: #fff; box-shadow: 0 0 0 5px var(--rose-soft); }
.track-step .line { width: 3px; height: 26px; background: #EDE4D8; margin-inline: 15.5px; }
.views-chip {
  display: inline-flex; align-items: center; gap: 6px; font-size: .8rem; color: var(--muted);
  background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; margin-bottom: 10px;
}
@media (max-width: 820px) { .wa-float { bottom: 140px; } }

/* تصنيفات المنتج: المنتهي شفاف مع ✕ */
.vopt.soldout {
  position: relative;
  opacity: .55;
  pointer-events: auto;
  background: #F5EFE8;
  color: var(--muted);
}
.vopt.soldout::after {
  content: '✕';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #C0392B;
  font-size: 1.25rem;
  font-weight: 800;
  background: rgba(255,255,255,.35);
  border-radius: inherit;
}
.vopt.soldout:disabled { cursor: not-allowed; }
.variant-stock-line {
  background: var(--sage-soft, #EAF0E6);
  color: var(--sage-deep, #5F7F63);
  font-size: .88rem;
  font-weight: 700;
  border-radius: 10px;
  padding: 8px 14px;
  display: inline-block;
  margin-top: 4px;
}

/* معرض المنتج: أسهم ونقاط وانتقال ناعم */
.main-img { position: relative; }
.main-img img { transition: opacity .35s ease; }
.gnav {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 4;
  width: 38px; height: 38px; border-radius: 50%; border: none;
  background: rgba(255,255,255,.85); color: var(--rose-deep);
  font-size: 1.5rem; line-height: 1; font-weight: 800;
  box-shadow: 0 3px 12px rgba(0,0,0,.18); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all .2s;
}
.gnav:hover { background: #fff; transform: translateY(-50%) scale(1.1); }
.gprev { right: 10px; }
.gnext { left: 10px; }
.gdots {
  position: absolute; bottom: 10px; left: 0; right: 0; z-index: 4;
  display: flex; justify-content: center; gap: 6px;
}
.gdot {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(255,255,255,.65); box-shadow: 0 1px 3px rgba(0,0,0,.25);
  cursor: pointer; transition: all .25s;
}
.gdot.active { background: #fff; width: 20px; }

/* هيرو بانر: مستطيل عريض بصورة منتجات حقيقية والنص فوقها */
.hero-banner {
  position: relative;
  width: 100%;
  min-height: clamp(430px, 52vw, 600px);
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hb-bg {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  transition: opacity .45s ease;
}
.hb-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(250,246,241,.10) 0%, rgba(250,246,241,.16) 60%, rgba(250,246,241,.34) 100%);
}
.hb-content {
  position: relative; z-index: 2; text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  background: rgba(250, 246, 241, .58);
  backdrop-filter: blur(12px) saturate(1.05);
  -webkit-backdrop-filter: blur(12px) saturate(1.05);
  border-radius: 26px;
  border: 1px solid rgba(255, 255, 255, .65);
  box-shadow: 0 14px 44px rgba(96, 62, 52, .16);
  padding: 30px 34px;
  max-width: 620px;
}
.hb-content .hero-badge { background: rgba(255,255,255,.8); color: var(--gold-deep); border: 1px solid rgba(198,161,91,.35); }
.hb-content h1 { color: #5C3E33; }
.hb-content .subtitle { color: #71544A; font-weight: 700; }
.hb-content .tagline { color: var(--gold-deep); font-weight: 700; }
.hb-content .hero-cta { justify-content: center; }
.btn-light {
  background: rgba(255,255,255,.88); color: var(--rose-deep);
  border: 1px solid rgba(168,93,104,.35);
}
.btn-light:hover { background: #fff; transform: translateY(-2px); }
@media (max-width: 640px) {
  .hero-banner { min-height: 118vw; max-height: 560px; }
  .hb-content { padding: 22px 18px; border-radius: 20px; }
  .hb-content h1 { font-size: 1.75rem; }
  .hb-content .subtitle { font-size: .95rem; }
  .hb-content .hero-badge { font-size: .78rem; }
  .btn-light { background: rgba(255,255,255,.92); }
}

/* خيارات التصنيفات المصورة */
.vopt-img {
  position: relative;
  width: 84px;
  border: 1.5px solid var(--line);
  border-radius: 14px;
  background: #fff;
  padding: 0 0 6px;
  text-align: center;
  cursor: pointer;
  transition: all .2s;
  overflow: hidden;
}
.vopt-img img.vthumb { width: 100%; aspect-ratio: 1/1; object-fit: cover; display: block; }
.vopt-img .vlbl { font-size: .78rem; font-weight: 700; padding: 5px 4px 2px; display: block; line-height: 1.3; }
.vopt-img:hover { border-color: var(--rose); transform: translateY(-2px); }
.vopt-img.active { border-color: var(--rose-deep); box-shadow: 0 0 0 2px var(--rose-deep); }
.vopt-img.soldout { opacity: .55; }
.vopt-img.soldout::after {
  content: '✕';
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  color: #C0392B; font-size: 2rem; font-weight: 800;
  background: rgba(255,255,255,.45);
}
.vo-thumb { border-color: var(--rose) !important; }
@media (max-width: 640px) {
  .vopt-img { width: 74px; }
}

/* هيكل تحميل (Skeleton) */
@keyframes sk { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.sk {
  background: linear-gradient(90deg, #EFE7DC 25%, #F8F3EB 50%, #EFE7DC 75%);
  background-size: 200% 100%;
  animation: sk 1.3s infinite;
  border-radius: 10px;
}
.sk-card {
  background: #fff; border: 1px solid var(--line); border-radius: 18px;
  overflow: hidden; padding-bottom: 12px;
}
.sk-img { aspect-ratio: 1/1; border-radius: 0; }
.sk-line { height: 12px; margin: 10px 12px 0; }
.sk-line.w80 { width: 80%; } .sk-line.w55 { width: 55%; }
.sk-btn { height: 30px; margin: 10px 12px 0; border-radius: 999px; }

/* خط زمن التتبع: شارك بأيقونات — ✓ مكتمل / نابض للحالي */
.timeline { margin: 14px 0 6px; }
.tl-row { display: flex; gap: 14px; align-items: flex-start; }
.tl-rail { display: flex; flex-direction: column; align-items: center; width: 44px; flex-shrink: 0; }
.tl-dot {
  width: 42px; height: 42px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.05rem; background: #F1EAE0; border: 2px solid #E5DACC;
}
.tl-row.done .tl-dot { background: var(--sage-soft); border-color: var(--sage-deep); }
.tl-row.current .tl-dot {
  background: var(--rose-deep); border-color: var(--rose-deep); color: #fff;
  animation: tlPulse 1.6s infinite;
}
@keyframes tlPulse {
  0% { box-shadow: 0 0 0 0 rgba(168,93,104,.45); }
  70% { box-shadow: 0 0 0 12px rgba(168,93,104,0); }
  100% { box-shadow: 0 0 0 0 rgba(168,93,104,0); }
}
.tl-seg { width: 4px; height: 30px; border-radius: 4px; background: #E5DACC; }
.tl-seg.done { background: var(--sage-deep); }
.tl-txt { padding-top: 8px; padding-bottom: 4px; }
.tl-txt b { font-size: .95rem; }
.tl-row.future .tl-txt b { color: var(--muted); font-weight: 600; }
.tl-now {
  display: inline-block; margin-top: 4px;
  background: var(--rose-soft); color: var(--rose-deep);
  font-size: .75rem; font-weight: 800;
  padding: 3px 12px; border-radius: 999px;
}

/* شارات المنتج — عمود واحد أنيق أعلى يمين الصورة تحت القلب */
.pc-flag.out { top: 10px; right: auto; left: 10px; background: rgba(255,255,255,.92); color: #9AA0A6; }
@media (max-width: 640px) {
  .pc-flag.out { top: 8px; right: auto; left: 8px; }
}

/* شارات أكبر قليلاً على شاشات الكمبيوتر فقط */
@media (min-width: 641px) {
  .pc-flag { font-size: 12px !important; padding: 4px 12px !important; }
}

/* نبض خفيف أثناء تحميل صور المنتجات */
.pc-img-wrap::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(100deg, transparent 30%, rgba(255,255,255,.5) 50%, transparent 70%);
  background-size: 200% 100%;
  animation: imgShimmer 1.4s infinite;
  pointer-events: none;
}
.pc-img-wrap img { position: relative; z-index: 1; }
.pc-wish, .pc-flag { z-index: 4; }
@keyframes imgShimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* ===== البحث الفوري المصوّر (اقتراحات تحت مربع البحث) ===== */
.search-sug {
  position: absolute; top: calc(100% + 8px); right: 0; left: 0;
  background: #fff; border: 1px solid #F0E2DE; border-radius: 16px;
  box-shadow: 0 18px 45px rgba(92,64,69,.18); z-index: 60; overflow: hidden;
  animation: sugIn .18s ease;
}
@keyframes sugIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
.ss-item {
  display: flex; align-items: center; gap: 11px; padding: 9px 13px;
  text-decoration: none; color: inherit; border-bottom: 1px solid #F7EFEA;
  transition: background .12s;
}
.ss-item:last-of-type { border-bottom: none; }
.ss-item:hover { background: #FBF5F1; }
.ss-item img { width: 48px; height: 48px; border-radius: 11px; object-fit: cover; flex: none; background: #F4EBE6; }
.ss-info { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.ss-name { font-size: .87rem; font-weight: 700; color: #4A3A3D; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ss-price { font-size: .8rem; font-weight: 800; color: #A85D68; }
.ss-price s { color: #B9A6A9; font-weight: 500; margin-inline-end: 4px; }
.ss-arrow { color: #C9AFA6; font-weight: 800; flex: none; }
.ss-none, .ss-more { padding: 12px 15px; font-size: .84rem; color: #9A8488; }
.ss-more { border-top: 1px dashed #EFD9D2; background: #FDF9F6; }

/* ===== زر مشاركة المنتج عبر واتساب ===== */
.wa-share-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  margin-top: 12px; width: 100%; max-width: 320px;
  padding: 11px 20px; border-radius: 14px;
  background: linear-gradient(135deg, #25D366, #128C7E);
  color: #fff; font-weight: 800; font-size: .95rem;
  text-decoration: none; box-shadow: 0 8px 22px rgba(18,140,126,.28);
  transition: transform .15s, box-shadow .15s;
}
.wa-share-btn:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(18,140,126,.36); }
.wa-share-btn svg { flex: none; }
