/* =====================================================================
   Fufuu Mood Drop — نسخة تجريبية لأعلى الصفحة الرئيسية (صفحة /mood فقط)
   ===================================================================== */
@property --m1 { syntax: '<color>'; inherits: true; initial-value: #F4A7C5; }

/* الهيدر شفاف فوق الخلفية في البداية */
.page-mood .site-header:not(.scrolled) { background: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; box-shadow: none; }
.page-mood .site-header:not(.scrolled)::after { opacity: 0; }
.page-mood .site-header::after { transition: opacity .3s; }
.page-mood .site-header { transition: background .3s, box-shadow .3s; }
/* زر الصوت ثانوي وصغير (والصوت لا يعمل تلقائيًا) */
.page-mood .sound-btn { width: 30px; height: 30px; background: transparent; opacity: .6; }
.page-mood .sound-btn svg { width: 16px; height: 16px; }
.page-mood .cart-btn { box-shadow: 0 4px 14px rgba(125,101,160,.25); }

/* ---------- الإطار ---------- */
.mood-hero {
  --m1: #F4A7C5;
  position: relative; overflow: hidden; isolation: isolate;
  margin-top: -64px; padding: calc(64px + 10px) 16px 58px;
  min-height: min(calc(100svh - 76px - env(safe-area-inset-bottom)), 780px);
  display: flex; flex-direction: column; justify-content: center;
}
@media (min-width: 721px) { .mood-hero { margin-top: -72px; padding-top: calc(72px + 20px); min-height: min(92svh, 820px); } }

/* خلفية pastel mesh تتلون حسب المنتج */
.mh-bg { position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60% 45% at 18% 28%, color-mix(in srgb, var(--m1) 70%, #fff) 0%, transparent 70%),
    radial-gradient(55% 40% at 86% 22%, rgba(195,163,226,.55) 0%, transparent 70%),
    radial-gradient(70% 45% at 50% 96%, color-mix(in srgb, var(--m1) 45%, #C3A3E2) 0%, transparent 72%),
    radial-gradient(40% 30% at 90% 70%, rgba(152,210,235,.45) 0%, transparent 70%),
    #FCE2E6;
  transition: --m1 .7s ease; }
.mh-jelly { position: absolute; border-radius: 42% 58% 63% 37% / 45% 40% 60% 55%; filter: blur(22px); opacity: .5; will-change: transform; }
.mh-jelly.j1 { width: 70vw; height: 55vw; max-width: 520px; max-height: 420px; top: -8%; inset-inline-start: -18%; background: radial-gradient(circle at 40% 40%, #fff 0, color-mix(in srgb, var(--m1) 80%, #fff) 60%); animation: jellyA 16s ease-in-out infinite alternate; }
.mh-jelly.j2 { width: 60vw; height: 60vw; max-width: 460px; max-height: 460px; bottom: -14%; inset-inline-end: -20%; background: radial-gradient(circle at 60% 40%, #fff 0, #C3A3E2 70%); animation: jellyB 19s ease-in-out infinite alternate; }
.mh-jelly.j3 { width: 38vw; height: 30vw; max-width: 300px; max-height: 240px; top: 40%; inset-inline-start: 58%; background: radial-gradient(circle at 50% 50%, #fff 0, #A2EAC6 75%); opacity: .35; animation: jellyA 22s ease-in-out infinite alternate-reverse; }
@keyframes jellyA { to { transform: translate(6%, 4%) rotate(14deg) scale(1.08); } }
@keyframes jellyB { to { transform: translate(-5%, -6%) rotate(-12deg) scale(1.1); } }
/* كلمة كبيرة شفافة تتحرك ببطء مع السحب والتمرير */
.mh-word { position: absolute; top: 34%; left: 50%; direction: ltr; white-space: nowrap; font-weight: 800; letter-spacing: -.02em;
  font-size: clamp(120px, 38vw, 360px); line-height: 1; color: rgba(125,101,160,.075); transform: translateX(-50%); will-change: transform; }
/* ملمس خفيف جدًا */
.mh-grain { position: absolute; inset: 0; opacity: .07; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }

.mh-inner { position: relative; width: 100%; max-width: 760px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; text-align: center; }

/* ---------- العنوان: ظهور بقناع ناعم ---------- */
.mh-title { margin: 0 0 6px; font-size: clamp(1.9rem, 8.4vw, 3.2rem); line-height: 1.22; color: var(--ink); font-weight: 800; }
.mh-line { display: inline-block; overflow: hidden; padding-bottom: .12em; vertical-align: bottom; }
.mh-line > span { display: inline-block; }
.motion .mh-line > span { transform: translateY(105%); opacity: 0; animation: maskUp .48s cubic-bezier(.2,.8,.2,1) forwards; }
.motion .mh-line:nth-of-type(2) > span { animation-delay: .09s; }
@keyframes maskUp { to { transform: none; opacity: 1; } }
/* «مودج» بمعالجة سائلة خفيفة (تبقى واضحة) */
.mh-mood { font-style: normal; position: relative; display: inline-block;
  background: linear-gradient(90deg, #7D65A0, #C4508A, #5B86C0, #7D65A0) 0 0 / 300% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent; animation: liquidInk 7s linear infinite; }
.mh-mood::after { content: ''; position: absolute; inset-inline: 0; bottom: -.02em; height: .22em; background: color-mix(in srgb, var(--m1) 70%, #7D65A0);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 8'%3E%3Cpath d='M0 5Q5 1 10 5T20 5T30 5T40 5' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round'/%3E%3C/svg%3E") repeat-x 0 50% / 26px 100%;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 8'%3E%3Cpath d='M0 5Q5 1 10 5T20 5T30 5T40 5' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round'/%3E%3C/svg%3E") repeat-x 0 50% / 26px 100%;
  animation: waveSlide 2.4s linear infinite; }
@keyframes liquidInk { to { background-position: 300% 0; } }
@keyframes waveSlide { to { -webkit-mask-position: 26px 50%; mask-position: 26px 50%; } }

/* ---------- عرض المنتجات ---------- */
.mh-stage { position: relative; width: 100vw; height: clamp(210px, 35svh, 340px); margin: 4px 0 0; touch-action: pan-y; cursor: grab; outline: none; user-select: none; -webkit-user-select: none; }
.mh-stage:active { cursor: grabbing; }
.mh-track { position: absolute; inset: 0; }
.mh-slide { position: absolute; top: 0; left: 50%; height: 88%; aspect-ratio: 1; will-change: transform, opacity; }
.mh-float { width: 100%; height: 100%; }
.mh-slide.active .mh-float { animation: mhFloat 3.6s ease-in-out infinite; }
@keyframes mhFloat { 50% { transform: translateY(-5px); } }
/* الصور ليست مفرّغة: نعرضها داخل شكل عضوي نظيف */
.mh-shape { width: 100%; height: 100%; display: grid; place-items: center; overflow: hidden;
  border-radius: 58% 42% 55% 45% / 48% 56% 44% 52%; background: radial-gradient(circle at 35% 30%, #fff 0, #fff 55%, color-mix(in srgb, var(--pc, #F4A7C5) 25%, #fff) 100%);
  box-shadow: 0 22px 40px -18px color-mix(in srgb, var(--pc, #7D65A0) 70%, #4A3B63), inset 0 -8px 0 rgba(0,0,0,.04); }
.mh-shape img { width: 82%; height: 82%; object-fit: contain; pointer-events: none; -webkit-user-drag: none; }
.mh-slide.cutout .mh-shape { background: none; box-shadow: none; overflow: visible; border-radius: 0; }
.mh-slide.cutout .mh-shape img { width: 100%; height: 100%; filter: drop-shadow(0 18px 18px rgba(74,59,99,.25)); }
/* بطاقة الاسم والسعر مرتبطة بالمنتج */
.mh-chip { position: absolute; left: 50%; bottom: 2px; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 10px; white-space: nowrap;
  background: rgba(255,255,255,.92); border-radius: 999px; padding: 6px 16px; box-shadow: 0 8px 22px rgba(125,101,160,.2); font-weight: 700; font-size: .95rem; z-index: 3;
  transition: opacity .2s; }
.mh-chip b { color: var(--purple); }
.mh-chip.pop { animation: chipPop .4s cubic-bezier(.3,1.6,.5,1); }
@keyframes chipPop { from { transform: translateX(-50%) scale(.85); } }
.mh-dots { display: flex; gap: 7px; margin: 12px 0 10px; }
.mh-dots button { width: 8px; height: 8px; border-radius: 99px; border: 0; padding: 0; background: rgba(125,101,160,.28); transition: width .3s, background .3s; }
.mh-dots button[aria-selected="true"] { width: 22px; background: var(--purple); }
.mh-actions { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.mh-add { min-width: 220px; font-size: 1.1rem; padding: 13px 28px; }
.mh-add:disabled { opacity: .5; }
.mh-all { font-weight: 700; color: var(--purple); font-size: .95rem; padding: 4px 8px; text-decoration: underline; text-decoration-color: rgba(125,101,160,.35); text-underline-offset: 5px; }

/* ---------- نهاية الـ Hero: موجة جيلي تدخل قسم التصنيفات ---------- */
.mh-wave { position: absolute; left: 0; right: 0; bottom: -1px; width: 100%; height: 44px; fill: var(--blush); }

@media (prefers-reduced-motion: reduce) {
  .mh-jelly, .mh-mood, .mh-mood::after, .mh-slide.active .mh-float { animation: none !important; }
  .motion .mh-line > span { animation: none; transform: none; opacity: 1; }
}

/* فقاعة فوفو في المساحة الفارغة تحت الرابط وفوق شريط التنقل */
.page-mood .companion .comp-bubble { top: auto; bottom: 10px; }

/* دائرة غير منتظمة بقناع (mask) بدل الزوايا المدوّرة: لا تنكسر في Safari أثناء الحركة */
.mh-shape { border-radius: 0; overflow: visible; box-shadow: none;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Cpath d='M101 7C145 5 186 32 192 80C198 130 168 184 114 192C60 200 12 168 8 114C4 60 48 9 101 7Z'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Cpath d='M101 7C145 5 186 32 192 80C198 130 168 184 114 192C60 200 12 168 8 114C4 60 48 9 101 7Z'/%3E%3C/svg%3E") center / 100% 100% no-repeat; }
.mh-float { filter: drop-shadow(0 16px 18px color-mix(in srgb, var(--pc, #7D65A0) 45%, rgba(74,59,99,.35))); }
.mh-slide.cutout .mh-shape { -webkit-mask: none; mask: none; }
.mh-slide.cutout .mh-float { filter: none; }

/* الشريط المائل تحت موجة القسم الأعلى (أنحف قليلًا) */
.page-mood .marquee { margin: -4px -6px 8px; position: relative; z-index: 2; padding: 6px 0; font-size: .95rem; }
/* الشريط المتحرك أكثر ميلانًا */
.page-mood .marquee { transform: rotate(-3.2deg); margin: 6px -14px 22px; }

.page-mood .fufu-toggle { width: 30px; height: 30px; }
.page-mood .fufu-toggle img { width: 21px; }
