/* =====================================================================
   کافه سلامت ساوا — استایل‌های سفارشی منوی آنلاین
===================================================================== */
:root {
  --cream: #FEFAF3;
  --cream-2: #FDF3E4;
  --rose: #FFCED8;
  --rose-deep: #F2A0B2;
  --rose-ink: #8A4B57;
  --leaf: #B8CFB3;
  --leaf-deep: #7C9B76;
  --leaf-ink: #3E5A39;
  --honey: #F6E3C3;
  --honey-ink: #8A6A35;
  --lav: #DCD6F5;
  --lav-ink: #5B5090;
  --ink: #35322C;
  --ink-soft: #7A756A;
  --line: #EFE7D9;
}

html { scroll-behavior: smooth; }
body { background: var(--cream); color: var(--ink); }

/* ---------- هاله‌های پاستیلی پس‌زمینه ---------- */
.blob {
  position: fixed; border-radius: 9999px; filter: blur(70px);
  opacity: .5; pointer-events: none; z-index: 0;
}
.blob-pink { background: var(--rose); width: 420px; height: 420px; top: -160px; left: -120px; }
.blob-green { background: var(--leaf); width: 380px; height: 380px; bottom: -140px; right: -120px; opacity: .4; }

/* ---------- اسکرول‌بار و اسکرول افقی ---------- */
.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #DCD2C2; border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: #C9BBA6; }

/* ---------- هایلایت ماژیکی تیترها ---------- */
.text-marker { background: linear-gradient(transparent 62%, var(--rose) 62%); }
.text-marker-green { background: linear-gradient(transparent 62%, var(--leaf) 62%); }

/* ---------- گرادیان‌های نرم ---------- */
.grad-leaf { background: linear-gradient(135deg, #C7DDBF 0%, #B8CFB3 55%, #9DBE96 100%); }
.grad-rose { background: linear-gradient(135deg, #FFDCE3 0%, #FFCED8 55%, #F7B4C2 100%); }
.grad-cream { background: linear-gradient(135deg, #FFFDF9 0%, #FDF3E4 100%); }
.ring-soft { box-shadow: 0 20px 50px -22px rgba(60, 84, 56, .28); }

/* ---------- کارت محصول ---------- */
.menu-card { transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease; }
.menu-card:hover { transform: translateY(-5px); box-shadow: 0 24px 45px -20px rgba(62, 90, 57, .25); border-color: var(--leaf-deep); }
.menu-card:hover .card-img { transform: scale(1.06); }
.card-img { transition: transform .5s cubic-bezier(.2, .7, .2, 1); }

/* ---------- مودال‌ها ---------- */
.modal-overlay { animation: fadeIn .22s ease both; }
.modal-panel { animation: popIn .28s cubic-bezier(.2, .9, .3, 1.15) both; }
@media (max-width: 639.98px) {
  .modal-bottom .modal-panel { animation: slideUp .32s cubic-bezier(.2, .8, .25, 1) both; border-radius: 1.9rem 1.9rem 0 0; }
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes popIn { from { opacity: 0; transform: translateY(16px) scale(.965); } to { opacity: 1; transform: none; } }
@keyframes slideUp { from { transform: translateY(100%); } to { transform: none; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.stagger > * { animation: fadeUp .45s ease both; }
.stagger > *:nth-child(1) { animation-delay: .02s; }
.stagger > *:nth-child(2) { animation-delay: .06s; }
.stagger > *:nth-child(3) { animation-delay: .10s; }
.stagger > *:nth-child(4) { animation-delay: .14s; }
.stagger > *:nth-child(5) { animation-delay: .18s; }
.stagger > *:nth-child(6) { animation-delay: .22s; }
.stagger > *:nth-child(7) { animation-delay: .26s; }
.stagger > *:nth-child(8) { animation-delay: .30s; }

/* ---------- اسلایدر گرم ---------- */
.gram-slider {
  -webkit-appearance: none; appearance: none;
  width: 100%; height: 8px; border-radius: 99px; outline: none; cursor: pointer;
  background: linear-gradient(to left, var(--leaf-deep) var(--val, 0%), #EDE6D8 var(--val, 0%));
}
.gram-slider::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 20px; height: 20px; border-radius: 50%;
  background: #fff; border: 3.5px solid var(--leaf-deep);
  box-shadow: 0 2px 8px rgba(62, 90, 57, .3); cursor: grab;
}
.gram-slider::-moz-range-thumb {
  width: 20px; height: 20px; border-radius: 50%;
  background: #fff; border: 3.5px solid var(--leaf-deep);
  box-shadow: 0 2px 8px rgba(62, 90, 57, .3); cursor: grab;
}
.gram-slider:disabled { opacity: .45; cursor: not-allowed; }
.gram-slider:disabled::-webkit-slider-thumb { cursor: not-allowed; border-color: #B9B2A4; }

/* ---------- سوییچ ---------- */
.switch { position: relative; display: inline-block; width: 44px; height: 24px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .track {
  position: absolute; inset: 0; border-radius: 99px; cursor: pointer;
  background: #D9D0C0; transition: background .2s ease;
}
.switch .track::before {
  content: ""; position: absolute; width: 18px; height: 18px; border-radius: 50%;
  background: #fff; top: 3px; right: 3px; transition: transform .2s ease;
  box-shadow: 0 1px 4px rgba(0, 0, 0, .2);
}
.switch input:checked + .track { background: var(--leaf-deep); }
.switch input:checked + .track::before { transform: translateX(-20px); }

/* ---------- نوار پیشرفت ---------- */
.progress { height: 9px; border-radius: 99px; background: #EFE9DC; overflow: hidden; }
.progress > span { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--leaf-deep), var(--leaf)); transition: width .5s ease; }

/* ---------- چرخ دنده ورود تعداد ---------- */
.qty-btn { transition: transform .12s ease; }
.qty-btn:active { transform: scale(.88); }

/* ---------- توست ---------- */
#toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(20px);
  background: #3B382F; color: #FEFAF3; padding: 10px 18px; border-radius: 99px;
  font-size: 12.5px; font-weight: 700; z-index: 90; opacity: 0; pointer-events: none;
  transition: opacity .25s ease, transform .25s ease; display: flex; align-items: center; gap: 8px;
  box-shadow: 0 12px 30px -10px rgba(0, 0, 0, .4);
}
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- فرم‌ها ---------- */
.field {
  width: 100%; background: #fff; border: 1.5px solid var(--line); border-radius: 14px;
  padding: 10px 14px; font-size: 13px; font-weight: 600; color: var(--ink); outline: none;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.field:focus { border-color: var(--leaf-deep); box-shadow: 0 0 0 4px rgba(184, 207, 179, .35); }
.field::placeholder { color: #B8B0A0; font-weight: 500; }

/* ---------- سلکت‌ها — استایل یکدست ساوا در همهٔ صفحات (بدون استایل پیش‌فرض مرورگر) ---------- */
select.field,
.combo select {
  appearance: none; -webkit-appearance: none; -moz-appearance: none;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%237A756A' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: left 12px center;
  background-size: 13px;
  padding-left: 34px;
}
select.field::-ms-expand { display: none; }
select.field option { background: #fff; color: var(--ink); font-weight: 600; }

/* ---------- مودال‌ها روی موبایل: متن خوانا + بدون زوم خودکار iOS ---------- */
@media (max-width: 639.98px) {
  .modal-panel .field,
  .modal-panel input,
  .modal-panel select,
  .modal-panel textarea {
    font-size: 15px;
  }
  .modal-panel .field { padding: 11px 14px; }
}
@supports (-webkit-touch-callout: none) {
  /* آیفون/آیپد — جلوگیری از زوم خودکار هنگام فوکوس روی ورودی‌ها */
  input.field, select.field, textarea.field { font-size: 16px; }
}

/* ---------- ترکان خوردن کالری در کارت ---------- */
.cal-chip { backdrop-filter: blur(6px); }

/* ---------- تقویم شمسی (موبایل: شیت پایین صفحه) ---------- */
.jdate-backdrop {
  position: fixed; inset: 0; z-index: 70;
  background: rgba(53, 50, 44, .45); backdrop-filter: blur(2px);
}
@media (max-width: 639.98px) {
  .jdate-cal.jdate-mobile {
    position: fixed; left: 0; right: 0; bottom: 0; top: auto;
    width: 100%; max-width: none; margin: 0 !important;
    border-radius: 1.9rem 1.9rem 0 0; border-bottom: 0;
    padding: 1rem 1rem calc(1rem + env(safe-area-inset-bottom));
    z-index: 80; animation: slideUp .3s cubic-bezier(.2, .8, .25, 1) both;
  }
  .jdate-cal.jdate-mobile .jdate-day { height: 2.6rem; font-size: 13px; border-radius: 14px; }
}

/* ---------- سگمنت (تب دوتایی) ---------- */
.segment { background: #F1EAE0; border-radius: 14px; padding: 4px; display: flex; gap: 4px; }
.segment > button {
  flex: 1; border-radius: 10px; padding: 7px 10px; font-size: 12px; font-weight: 800;
  color: var(--ink-soft); transition: all .2s ease; white-space: nowrap;
}
.segment > button.on { background: #fff; color: var(--leaf-ink); box-shadow: 0 2px 8px rgba(62, 90, 57, .15); }
.segment > button.on.rose { color: var(--rose-ink); }
body.modal-open { overflow: hidden; }
