/* هوية سلندر اكسبرس: رمادي المحرك، ذهبي الزيت، خلفية عاجية */
:root {
  --engine: #333333;
  --gold: #E9B53F;
  --gold-deep: #C9952A;
  --ivory: #F6F3EC;
  --gold-soft: #FDF6E3;
  --ink: #1F1F1F;
  --shadow: 0 1px 2px rgba(31, 31, 31, .05), 0 8px 28px rgba(31, 31, 31, .07);
  --shadow-hi: 0 2px 6px rgba(31, 31, 31, .06), 0 18px 40px rgba(31, 31, 31, .12);
  --card: #FFFFFF;
  /* سطح البطاقات، والنص فوق الأزرار الداكنة، وخلفية صور المنتجات (تبقى بيضاء في الوضع الداكن) */
  --surface: #FFFFFF;
  --on-engine: #FFFFFF;
  --photo-bg: #FFFFFF;
  --page: #FFFFFF;
  --metal: #9B988F;
  --line: #E7E2D7;
  --text: #2A2A2A;
  --muted: #6B675F;
  --ok: #3C7558;
  --warn: #9A5B26;
  --bad: #AE4037;
  /* حدود الخانات: 3 إلى 1 على الأبيض حتى تُرى الخانة */
  --line-strong: #8C877D;
  --radius: 16px;
  /* سلّم أحجام الخط: خمسة أدوار بدل 29 قيمة متقاربة */
  --t-meta: .8125rem;
  --t-small: .875rem;
  --t-body: 1rem;
  --t-lead: 1.125rem;
  --t-title: 1.375rem;
  /* ذهبي للنص: الذهبي العادي لا يُقرأ على الأبيض والعاجي */
  --gold-text: #8A6416;
  --font: 'Alexandria', 'Sora', system-ui, sans-serif;
}
html[lang="en"] { --font: 'Sora', 'Alexandria', system-ui, sans-serif; }

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: var(--font);
  background: var(--ivory);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  font-variant-numeric: tabular-nums;
  caret-color: var(--gold-deep);
  display: flex;
  flex-direction: column;
}
main { flex: 1; width: 100%; max-width: 640px; margin: 0 auto; padding: 20px 16px 40px; outline: none; }
a { color: inherit; }
button { font: inherit; }

.top {
  background: var(--engine);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  gap: 12px;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; font-weight: 700; font-size: var(--t-body); }
.brand img { width: 40px; height: 40px; object-fit: contain; background: var(--photo-bg); border-radius: 10px; padding: 4px; }
.top nav { display: flex; align-items: center; gap: 8px; }
.brand span, .navlink { white-space: nowrap; }
/* نص لقارئ الشاشة فقط */
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.navlink { text-decoration: none; padding: 8px 12px; border-radius: 8px; }
.navlink.logout { background: none; border: 0; color: inherit; cursor: pointer; font: inherit; }
.navlink:hover { background: rgba(255, 255, 255, .1); }
.lang {
  background: transparent; color: var(--gold); border: 1px solid var(--gold);
  border-radius: 999px; padding: 4px 16px; cursor: pointer; font-size: var(--t-small);
}
.foot { text-align: center; color: var(--muted); font-size: var(--t-small); padding: 16px; border-top: 1px solid var(--line); }
.foot-links { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-top: 8px; }
.foot-links a { text-decoration: underline; text-underline-offset: 3px; padding: 12px 0; }

/* أزرار */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 12px 20px; border-radius: 12px; border: 1px solid transparent;
  text-decoration: none; cursor: pointer; font-weight: 600; font-size: var(--t-body);
}
.btn.primary { background: var(--gold); color: var(--engine); }
.btn.primary:hover { background: var(--gold-deep); }
.btn.primary:disabled { opacity: .45; cursor: not-allowed; }
/* «غير جاهز»: باهت لكنه يعمل، حتى يوافق العميل على شروط الإلغاء */
.btn.primary.notyet { opacity: .55; }
.btn.ghost { background: transparent; border-color: var(--line); color: var(--text); }
.btn.big { min-height: 56px; font-size: var(--t-lead); padding-inline: 28px; }
.btn.google { background: var(--photo-bg); border-color: #DADCE0; color: #3C4043; width: 100%; }
/* أزرار الدخول (Google وواتساب): أبيض بإطار رمادي كما في إرشادات Google، والشعار بألوانه الأصلية في بداية الزر والنص في الوسط */
.btn.social { position: relative; width: 100%; background: var(--photo-bg); border: 1px solid #747775; color: #1F1F1F; font-weight: 600;
  padding-inline: 56px; box-shadow: 0 1px 2px rgba(31, 31, 31, .06); transition: background-color .15s, box-shadow .15s, border-color .15s; }
.btn.social:hover { background: #F7F7F7; box-shadow: 0 2px 6px rgba(31, 31, 31, .1); }
.btn.social:active { background: #EFEFEF; }
.btn.social .brand-logo { position: absolute; inset-inline-start: 16px; top: 50%; width: 24px; height: 24px; transform: translateY(-50%); flex: none; }
.btn.social.whatsapp:hover { border-color: #25D366; }
.link { background: none; border: 0; color: var(--muted); text-decoration: underline; cursor: pointer; padding: 8px 0; display: inline-block; }
:focus-visible { outline: 3px solid var(--engine); outline-offset: 2px; } /* لون المحرك لا الذهبي: الذهبي يعني «مختار» */
main:focus, main:focus-visible { outline: none; }

/* الرئيسية */
.hero { text-align: center; padding-top: 24px; }
.hero h1 { font-size: clamp(1.6rem, 6vw, 2.2rem); margin: 0 0 8px; color: var(--engine); }
.lead { color: var(--muted); margin: 0 0 20px; }
.how { list-style: none; padding: 0; margin: 32px 0 20px; display: grid; gap: 12px; text-align: start; }
.how li { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; display: flex; align-items: center; gap: 12px; }
.num { width: 30px; height: 30px; border-radius: 50%; background: var(--engine); color: var(--gold); display: inline-grid; place-items: center; font-weight: 700; font-family: 'Sora', sans-serif; flex: none; }

/* خطوات الحجز */
.flow h2 { margin: 12px 0 16px; font-size: var(--t-title); color: var(--engine); }
.progress { height: 6px; background: var(--line); border-radius: 999px; overflow: hidden; }
.progress span { display: block; height: 100%; background: var(--gold); transition: inline-size .2s; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.chip { background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; font-size: var(--t-small); cursor: pointer; color: var(--muted); }

.options { display: grid; gap: 12px; }
.option {
  background: var(--card); border: 2px solid var(--line); border-radius: var(--radius);
  padding: 16px 16px; text-align: start; cursor: pointer; display: grid; gap: 2px; color: var(--text);
}
.option:hover, .day:hover, .time:hover { border-color: var(--gold); }
.option.on, .day.on, .time.on { border-color: var(--gold); background: #FFF8E6; }
.option strong { font-size: var(--t-body); }
.option span { color: var(--muted); font-size: var(--t-small); }
.option .price { color: var(--engine); font-weight: 700; font-family: 'Sora', var(--font); }

.days { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.day { background: var(--card); border: 2px solid var(--line); border-radius: var(--radius); padding: 12px; cursor: pointer; display: grid; gap: 2px; text-align: start; color: var(--text); }
.day em { font-style: normal; color: var(--gold-text); font-weight: 700; font-size: var(--t-small); }
.day span { color: var(--muted); font-size: var(--t-meta); }
.times { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 8px; }
.time { background: var(--card); border: 2px solid var(--line); border-radius: 12px; min-height: 48px; cursor: pointer; font-weight: 600; color: var(--text); }

.actions { display: flex; gap: 12px; margin-top: 20px; flex-wrap: wrap; }
.actions .btn.primary { flex: 1; }
.muted { color: var(--muted); }

/* النموذج */
.form { display: grid; gap: 16px; }
.field label { display: block; font-weight: 600; margin-bottom: 8px; }
.field input, .field select {
  width: 100%; min-height: 48px; border: 1px solid var(--line); border-radius: 12px; padding: 12px 12px;
  font: inherit; background: var(--card); color: var(--text);
}
.field input[aria-invalid="true"] { border-color: var(--bad); }
.field-err { color: var(--bad); font-size: var(--t-small); line-height: 1.5; margin: 0; }
.field-err:not(:empty) { margin-top: 4px; }
/* خانة الجوال قطعة واحدة تُقرأ «+966 5xxxxxxxx» في العربي والإنجليزي: المفتاح يسارًا بعرض محتواه (العلم و+966) فلا يُقص،
   والرقم ملاصق له يمينه بحد مشترك ويأخذ باقي السطر. السطر dir=ltr دائمًا */
.phone { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 0; direction: ltr; }
.phone select { direction: ltr; text-align: left; min-width: 0; white-space: nowrap; }
.field .phone select { padding-inline: 12px 8px; border-radius: 12px 0 0 12px; }
.field .phone input { direction: ltr; text-align: left; min-width: 0; margin-left: -1px; border-radius: 0 12px 12px 0; font-family: 'Sora', var(--font); letter-spacing: .5px; }
/* الحد المشترك يأخذ لون الخانة النشطة أو الخاطئة */
.field .phone select:focus, .field .phone input:focus, .field .phone input[aria-invalid="true"] { position: relative; z-index: 1; }
.signin { background: var(--card); border: 1px dashed var(--gold); border-radius: var(--radius); padding: 16px; margin-bottom: 16px; display: grid; gap: 8px; }
.signin p { margin: 0; font-weight: 600; }

/* اللوحة السعودية بشكل أبشر (مزاد اللوحات): أرض رمادية فاتحة وإطار رمادي غامق بزوايا مدورة،
   الأرقام يسارًا والحروف يمينًا، العربي فوق والإنجليزي تحت، وعلى اليمين شريط ضيق فيه الشعار وKSA والنقطة.
   لون الشريط حسب نوع اللوحة: أبيض للخصوصي، أزرق للنقل الخاص، أصفر للأجرة.
   كل المقاسات بالنسبة لعرض اللوحة (cqi) فتبقى النسب نفسها في أي حجم. */
.plate-wrap:empty { display: none; }
.plate {
  --kp-ink: #1d1d1d; --kp-line: #4b4b4b;
  container-type: inline-size;
  width: 13rem; max-width: 100%; aspect-ratio: 3 / 1; box-sizing: border-box;
  margin-top: 8px; display: grid; grid-template-columns: 1fr 1fr 9.5%;
  /* وحدة cqi في إطار اللوحة نفسها تُحسب من عرض الشاشة لا من عرض اللوحة، فكان الإطار سميكًا والزوايا دائرية في الكمبيوتر.
     الإطار يُرسم في ::after (ابن اللوحة) فيُحسب من عرض اللوحة، والزوايا بالنسبة المئوية لعرضها وارتفاعها */
  position: relative; border: 0; border-radius: 3.2% / 9.6%; overflow: hidden;
  background: #ededed; color: var(--kp-ink);
  box-shadow: 0 3px 6px rgba(0, 0, 0, .14);
  font-family: 'Alexandria', 'Sora', system-ui, sans-serif; font-weight: 700; line-height: 1;
}
.plate::after { content: ''; position: absolute; inset: 0; border: max(1.5px, .9cqi) solid var(--kp-line); border-radius: inherit; pointer-events: none; }
dd .plate { margin-top: 0; }
.plate .kp-half {
  display: grid; grid-template-rows: 1fr 1fr; min-width: 0; min-height: 0; margin: 0; padding: 0;
  border: 0; border-radius: 0; background: none; color: inherit; font: inherit; cursor: default;
}
.plate .kp-digits { border-inline-end: max(1px, .6cqi) solid var(--kp-line); }
.plate .kp-row { display: flex; align-items: center; justify-content: center; gap: 2.6cqi; min-width: 0; padding-inline: 1.5cqi; }
.plate .kp-letters .kp-row { justify-content: space-evenly; padding-inline: 3cqi; }
.plate .kp-row + .kp-row { border-top: max(1px, .6cqi) solid var(--kp-line); }
.plate .kp-g { display: block; min-width: 0; text-align: center; color: var(--kp-ink); }
.plate .kp-row[lang="ar"] .kp-g { font-size: 10.5cqi; line-height: 1.1; }
/* الإنجليزي بخط عريض مضغوط مثل خط اللوحة الحقيقي */
.plate .kp-row[lang="en"] .kp-g { font: 700 11cqi/1 'DIN Condensed', 'DIN Alternate', 'Roboto Condensed', 'Arial Narrow', 'Sora', sans-serif; font-stretch: condensed; }
/* خط Alexandria يرسم الأرقام العربية بشكل الإنجليزية، فنأخذها من خط الجهاز العربي */
.plate .kp-digits .kp-row[lang="ar"] .kp-g { font-family: 'SF Arabic', 'Geeza Pro', 'Noto Sans Arabic', 'Noto Naskh Arabic', 'Segoe UI', Tahoma, sans-serif; font-weight: 700; font-size: 11cqi; }
.plate .kp-strip {
  display: grid; grid-template-rows: auto 1fr auto; justify-items: center; align-items: center;
  padding: 1.6cqi 0 1.8cqi; border-inline-start: max(1px, .6cqi) solid var(--kp-line);
  background: var(--photo-bg); line-height: 1; text-align: center; color: var(--kp-ink);
}
.plate .kp-emblem { display: block; width: auto; height: 6cqi; filter: brightness(0); opacity: .85; }
.plate .kp-strip b { display: none; }
.plate .kp-ksa { font: 700 3.2cqi/1.05 'DIN Condensed', 'Roboto Condensed', 'Arial Narrow', 'Sora', sans-serif; }
.plate .kp-strip i { width: 3cqi; height: 3cqi; border-radius: 50%; background: currentColor; }
.plate[data-kind="private_transport"] .kp-strip { background: #2f7fd2; color: #fff; }
.plate[data-kind="public_transport"] .kp-strip { background: #f3cf3f; }
.plate[data-kind="private_transport"] .kp-emblem { filter: brightness(0) invert(1); opacity: 1; }
/* النقل: خط أبيض فوق مثلث بدل النقطة */
.plate[data-kind="private_transport"] .kp-strip i, .plate[data-kind="public_transport"] .kp-strip i {
  width: 5cqi; height: 4.2cqi; border-radius: 0; background: linear-gradient(currentColor 0 0) top / 100% 30% no-repeat, linear-gradient(#1d1d1d 0 0);
  clip-path: polygon(0 0, 100% 0, 100% 30%, 100% 45%, 50% 100%, 0 45%);
}
.plate[data-kind="public_transport"] .kp-strip i { background: linear-gradient(#fff 0 0) top / 100% 30% no-repeat, linear-gradient(#1d1d1d 0 0); }
/* قيمة ليست لوحة سعودية صحيحة تُعرض كما كُتبت، بلا رسم لوحة */
.plate-text { direction: ltr; unicode-bidi: isolate; font-weight: 700; letter-spacing: 1px; }

/* المراجعة */
.review { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 8px 16px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin: 0; }
.review dt { color: var(--muted); }
.review dd { margin: 0; font-weight: 600; min-width: 0; overflow-wrap: anywhere; }
.review .price { font-family: 'Sora', var(--font); display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.ltr { direction: ltr; unicode-bidi: isolate; text-align: start; font-family: 'Sora', var(--font); }
.pays { display: grid; gap: 12px; margin-top: 16px; }
.pay { display: flex; gap: 12px; align-items: center; background: var(--card); border: 2px solid var(--line); border-radius: var(--radius); padding: 12px 16px; cursor: pointer; }
.pay.on { border-color: var(--gold); background: #FFF8E6; }
.pay input { accent-color: var(--engine); width: 20px; height: 20px; }
.pay span { display: grid; }
.pay small { color: var(--muted); }
.pay input { flex: none; }
.pay.off { opacity: .65; cursor: not-allowed; }
.pay.off small { color: var(--ink, #333333); }
.taddr { border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; margin: 12px 0 0; display: grid; gap: 12px; min-width: 0; }
.taddr legend { font-weight: 700; padding: 0 8px; }

.alert { background: #FBEDEB; color: var(--bad); border: 1px solid #F0C9C4; border-radius: 12px; padding: 12px 16px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; display: grid; gap: 12px; }

/* الحالة */
.badge { display: inline-block; border-radius: 999px; padding: 2px 12px; font-size: var(--t-meta); font-weight: 600; background: var(--line); color: var(--engine); }
.s-awaiting_payment { background: #FBEBD9; color: var(--warn); }
.s-needs_refund { background: #FBEBD9; color: var(--warn); }
.s-requested { background: #FFF3D1; color: #7A5A12; }
.s-confirmed, .s-completed { background: #E2F0E8; color: var(--ok); }
.s-cancelled, .s-expired, .s-no_show { background: #F1E3E1; color: var(--bad); }
.ticket h2 { margin-top: 8px; }
.list { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.list a { display: grid; gap: 2px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; text-decoration: none; }
.list a span:not(.badge) { color: var(--muted); font-size: var(--t-small); }
.list .badge { justify-self: start; }
.badge.shop { background: #f6ecd2; color: #6b4e0e; font-weight: 500; margin-block-start: 4px; justify-self: start; }
.carpick-name .badge.shop { display: table; }

@media (min-width: 560px) {
  .options { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 400px) {
  .brand { font-size: var(--t-body); }
  .navlink { padding-inline: 8px; font-size: var(--t-small); }
}

/* اختيار السيارة من سيارات الحساب */
.cars { border: 0; padding: 0; margin: 0; display: grid; gap: 12px; }
.cars legend { font-weight: 600; margin-bottom: 8px; padding: 0; }
.carpick { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; background: var(--card); border: 2px solid var(--line); border-radius: var(--radius); padding: 12px 16px; cursor: pointer; }
.carpick.on { border-color: var(--gold); background: #FFF8E6; }
.carpick input { accent-color: var(--engine); width: 20px; height: 20px; }
.carpick-name { font-weight: 600; flex: 1; min-width: 0; }
.carpick .plate { margin-top: 0; font-size: var(--t-small); }
.check { display: flex; gap: 12px; align-items: center; cursor: pointer; }
.check input { width: 20px; height: 20px; accent-color: var(--engine); }
.carrow { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 12px; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; }
.carrow > div { display: grid; min-width: 0; }
.carrow > div span { color: var(--muted); font-size: var(--t-small); }
.carrow .plate { grid-column: 1; justify-self: start; margin-top: 0; font-size: var(--t-small); }
.carrow .row-actions { grid-column: 2; grid-row: 1 / span 2; display: grid; gap: 8px; }
.carrow.editing { display: block; }
.btn.small { min-height: 44px; padding: 8px 16px; font-size: var(--t-small); }
.btn.danger { border-color: var(--bad); color: var(--bad); }
/* زر الحذف أو الإلغاء النهائي: أبيض على أحمر (الأحمر على الذهبي تباينه 3 إلى 1 فقط) */
.btn.danger.fill, .btn.primary.danger { background: var(--bad); border-color: var(--bad); color: #fff; }
.btn.danger.fill:hover, .btn.primary.danger:hover { background: #9E3831; }
.flow h3 { margin: 24px 0 8px; color: var(--engine); }

/* الدخول */
.login { padding-top: 16px; }
.login h1 { margin: 0 0 8px; color: var(--engine); font-size: clamp(1.5rem, 5.5vw, 2rem); }
.login .card { gap: 16px; }
.or { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: var(--t-small); }
.or::before, .or::after { content: ''; flex: 1; border-top: 1px solid var(--line); }
.small { font-size: var(--t-small); margin: 0; }
.field input.code { font-family: 'Sora', var(--font); font-size: var(--t-title); letter-spacing: .5em; text-align: center; }
.trial-bar { background: #7A1F1F; color: #fff; text-align: center; padding: 8px 16px; font-weight: 700; font-size: var(--t-small); }
.devcode { background: #FFF3D1; color: #7A5A12; border-radius: 10px; padding: 8px 12px; margin: 0; font-weight: 600; }
.row-links { display: flex; gap: 16px; flex-wrap: wrap; }
.login bdi { white-space: nowrap; display: inline-block; }
@media (max-width: 440px) {
  .brand span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .top nav { gap: 4px; }
  .lang { padding-inline: 12px; }
}

/* خانات البحث في قائمة السيارات */
.combo { position: relative; }
.combo-list {
  position: absolute; inset-inline: 0; top: calc(100% + 4px); z-index: 20; margin: 0; padding: 4px; list-style: none;
  background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 8px 24px rgba(0, 0, 0, .12);
  max-height: 300px; overflow-y: auto;
}
/* فوق الخانة حين لا يبقى تحتها مكان (الشريط السفلي الثابت) */
.combo-list.up { top: auto; bottom: calc(100% + 4px); box-shadow: 0 -8px 24px rgba(0, 0, 0, .12); }
.combo-opt { min-height: 44px; padding: 8px 12px; border-radius: 8px; cursor: pointer; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; }
.combo-opt span { color: var(--muted); font-size: var(--t-small); }
.combo-opt small { flex-basis: 100%; color: var(--muted); font-size: var(--t-meta); }
.combo-opt[aria-selected="true"], .combo-opt:hover { background: #FFF8E6; }
.combo-opt.free { border-top: 1px solid var(--line); border-radius: 0 0 8px 8px; }
.combo-opt.free strong { color: var(--gold-text); }
.combo-empty { padding: 12px 12px; color: var(--muted); font-size: var(--t-small); }
.field input:disabled { background: var(--ivory); color: var(--muted); }
.carpick-name small { display: block; color: var(--muted); font-weight: 400; font-size: var(--t-small); }
/* الكمية التقديرية لزيت المحرك: معلومة فقط، ليست سعراً ولا اختياراً */
.oil-est { display: block; margin: 8px 0 0; color: var(--text); font-size: var(--t-small); font-weight: 600; }
.oil-est[hidden] { display: none; }
.oil-est .oil-note { display: block; margin-top: 2px; color: var(--muted); font-weight: 400; font-size: var(--t-meta); }
.carrow > div .oil-est { color: var(--text); font-weight: 600; }
/* في اختيار السيارة: سطر كامل تحت الاسم واللوحة، يبدأ من محاذاة الاسم */
.carpick .carpick-oil { flex-basis: 100%; margin: 0; padding-inline-start: 32px; }

/* السعر شامل الضريبة، و«يتحدد في المحل» قبل الأسعار الشاملة */
.price .vat { font-size: var(--t-meta); font-weight: 500; color: var(--muted); }
.price.tbd { color: var(--muted); font-weight: 500; font-size: var(--t-small); }
/* زيت العميل والزيوت المتوفرة */
.muted.block, small.block, dd .block { display: block; }
/* اختيار الزيت: بطاقة بالصورة وسعر الوحدة، ثم الكمية */
fieldset.oils-pick { border: 0; padding: 0; margin: 0; display: grid; gap: 12px; }
fieldset.oils-pick legend { font-weight: 700; margin-bottom: 8px; }
.oilpick { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; }
.oilcard { position: relative; display: grid; gap: 4px; align-content: start; background: var(--card); border: 2px solid var(--line); border-radius: var(--radius); padding: 12px; cursor: pointer; text-align: center; }
.oilcard.on { border-color: var(--gold); box-shadow: 0 0 0 2px rgba(233, 181, 63, .25); }
.oilcard input { position: absolute; opacity: 0; pointer-events: none; }
.oilcard:has(input:focus-visible) { outline: 2px solid var(--engine); outline-offset: 2px; }
.oilcard img { width: 100%; height: 120px; object-fit: contain; }
.oilcard strong { font-size: var(--t-body); }
.oilcard-price { font-weight: 700; color: var(--engine); font-size: var(--t-small); }
.qty { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.qty-label { font-weight: 600; }
.qty output { min-width: 6em; text-align: center; font-weight: 700; }
.qty-amount { margin-inline-start: auto; }
details.oils { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; }
details.oils summary { cursor: pointer; font-weight: 600; min-height: 32px; }
details.oils ul { list-style: none; padding: 0; margin: 8px 0 0; display: grid; gap: 8px; }
details.oils li.out { color: var(--muted); }
details.oils li .badge { margin-inline-start: 8px; }
/* توثيق الجوال في خطوة البيانات */
.verify-box { border: 1px solid #e6dcc3; border-radius: 12px; padding: 12px 16px; display: grid; gap: 12px; background: #fffdf7; }
.verified { margin: 0; font-weight: 600; }
.policy { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; margin: 16px 0; }
.policy h3 { margin: 0 0 8px; font-size: var(--t-body); }
.policy p { margin: 0 0 12px; color: var(--muted); }
.notice { background: var(--card); border: 1px solid var(--gold); border-radius: var(--radius); padding: 12px 16px; }
/* رد المحل بسعر على طلب العميل: صندوق بارز في صفحة الحجز، وسطر في قائمة الحجوزات */
.quote { background: var(--gold-soft); border: 1px solid var(--gold); box-shadow: 0 0 0 1px var(--gold); border-radius: var(--radius); padding: 16px; display: grid; gap: 8px; }
.quote h3 { margin: 0; font-size: var(--t-lead); overflow-wrap: anywhere; }
.quote p { margin: 0; overflow-wrap: anywhere; }
.qbtns { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 4px; }
.qbtns .btn { flex: 1 1 140px; min-width: 0; }
.list li.quoted a { border-color: var(--gold); box-shadow: 0 0 0 1px var(--gold); }
.list a span.quote-tag { color: var(--gold-text); font-weight: 700; font-size: var(--t-small); }
.qsheet h3 { margin: 8px 0 4px; }
details.account { margin-top: 24px; border-top: 1px solid var(--line); padding-top: 12px; }
details.account summary { cursor: pointer; color: var(--muted); }

/* الحركات: مأخوذة من مكتبة transitions.dev (الحركات المجانية) ومعدّلة لاتجاه العربية ولألوان المحل.
   transitions.dev — page slide, error shake, success check, texts reveal */
:root {
  --ease-smooth-out: cubic-bezier(0.22, 1, 0.36, 1);
  --page-slide-dur: 450ms;
  --page-slide-distance: 28px;
  --page-blur: 4px;
  --shake-distance: 12px;
  --shake-overshoot: 7px;
  --stagger-dur: 750ms;
  --stagger-distance: 22px;
  --stagger-blur: 3px;
  --stagger-stagger: 120ms;
  --check-dur: 800ms;
  /* اتجاه السطر: في العربية بداية السطر يمين، فتنعكس جهة الانزلاق */
  --dir: 1;
}
html[dir="rtl"] { --dir: -1; }

/* دخول الصفحة: تلاشٍ مع ضباب خفيف، وانزلاق جانبي بين خطوات الحجز */
.t-enter { animation: t-page-in var(--page-slide-dur) var(--ease-smooth-out) both; }
.t-enter-fwd { --from-x: calc(var(--page-slide-distance) * var(--dir)); }
.t-enter-back { --from-x: calc(var(--page-slide-distance) * var(--dir) * -1); }
@keyframes t-page-in {
  from { opacity: 0; transform: translateX(var(--from-x, 0px)); filter: blur(var(--page-blur)); }
  to { opacity: 1; transform: none; filter: none; }
}

/* شريط التقدم يتحرك من الخطوة السابقة إلى الحالية */
.progress span { transition: inline-size 650ms var(--ease-smooth-out); }

/* هزّة الخانة عند الخطأ، وظهور رسالة الخطأ بنعومة */
.t-shake { animation: t-input-shake 420ms linear; }
@keyframes t-input-shake {
  0% { transform: translateX(0); animation-timing-function: var(--ease-smooth-out); }
  28.57% { transform: translateX(var(--shake-distance)); animation-timing-function: var(--ease-smooth-out); }
  57.14% { transform: translateX(calc(var(--shake-distance) * -1)); animation-timing-function: var(--ease-smooth-out); }
  78.57% { transform: translateX(var(--shake-overshoot)); animation-timing-function: var(--ease-smooth-out); }
  100% { transform: translateX(0); }
}
.field input, .field select { transition: border-color 150ms ease-out; }
.t-msg, .t-alert { animation: t-msg-in 350ms ease-out both; }
@keyframes t-msg-in { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }

/* ظهور العنوان ثم السطر الذي تحته */
.t-stagger .t-line { animation: t-line-in var(--stagger-dur) var(--ease-smooth-out) both; }
.t-stagger .t-line-2 { animation-delay: var(--stagger-stagger); }
@keyframes t-line-in {
  from { opacity: 0; transform: translateY(var(--stagger-distance)); filter: blur(var(--stagger-blur)); }
  to { opacity: 1; transform: none; filter: none; }
}

/* علامة الصح بعد تأكيد الحجز */
.t-check {
  width: 72px; height: 72px; border-radius: 50%; background: var(--engine); color: var(--gold);
  display: grid; place-items: center; margin-bottom: 4px;
  animation: t-check-in var(--check-dur) var(--ease-smooth-out) both;
}
.t-check svg { display: block; overflow: visible; }
.t-check path {
  fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round;
  stroke-dasharray: 20; stroke-dashoffset: 20;
  animation: t-check-draw var(--check-dur) var(--ease-smooth-out) 250ms forwards;
}
@keyframes t-check-in {
  from { opacity: 0; transform: translateY(40px) scale(.6) rotate(80deg); filter: blur(8px); }
  to { opacity: 1; transform: none; filter: none; }
}
@keyframes t-check-draw { to { stroke-dashoffset: 0; } }

/* عند من أطفأ الحركة في جهازه: لا حركة إطلاقاً */
@media (prefers-reduced-motion: reduce) {
  .t-enter, .t-shake, .t-msg, .t-alert, .t-stagger .t-line, .t-check { animation: none !important; }
  .t-check path { animation: none !important; stroke-dashoffset: 0; }
  .progress span, .field input, .field select { transition: none !important; }
}

/* ===== التصميم المعتمد (من نموذج الحجز الذي وافق عليه صاحب المحل): شريط أبيض ثابت، وبطاقات بظل خفيف ===== */
body { background: var(--page); color: var(--ink); -webkit-font-smoothing: antialiased; }
main { max-width: none; padding: 0 20px 48px; }
main > section.flow, main > section.login, main > section.card, main > .alert { max-width: 640px; margin-inline: auto; margin-top: 24px; }

/* الشريط العلوي: أبيض وثابت فوق الصفحة */
.top {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 30; display: block; padding: 0;
  background: var(--surface); color: var(--engine); border-bottom: 1px solid var(--line); box-shadow: 0 2px 10px rgba(31, 31, 31, .06);
}
.top-in { max-width: 1120px; margin: 0 auto; padding: 0 20px; height: 68px; display: flex; align-items: center; gap: 16px; }
.top .brand { color: var(--engine); }
.brand img { box-shadow: 0 0 0 1px var(--line); padding: 2px; }
.top nav { margin-inline-start: auto; gap: 4px; }
.navlink, .top .lang { color: var(--engine); background: none; border: 0; border-radius: 999px; padding: 8px 16px; font-size: var(--t-small); cursor: pointer; min-height: 44px; min-width: 44px; }
.navlink:hover, .top .lang:hover { background: var(--ivory); }
.top .btn.cta { min-height: 44px; padding: 8px 20px; font-size: var(--t-body); font-weight: 700; }
.trial-bar { position: relative; z-index: 31; }
@media (max-width: 560px) {
  .top-in { padding: 0 16px; gap: 8px; height: 62px; }
  .top .navlink.logout { display: none; }
  .navlink, .top .lang { padding: 8px 8px; font-size: var(--t-small); }
  .top .btn.cta { padding: 8px 12px; font-size: var(--t-small); min-height: 44px; }
}
@media (max-width: 440px) { .top #nav-bookings:not([hidden]) ~ .btn.cta { display: none; } }

/* الأزرار */
.btn { border-radius: 12px; font-weight: 700; transition: background .2s, transform .15s, box-shadow .2s; }
.btn:active { transform: scale(.98); }
.btn.ghost { background: var(--surface); border-color: var(--line); color: var(--engine); }
.btn.ghost:hover { background: var(--ivory); }
.btn.big { border-radius: 14px; }

/* الرئيسية */
.home { margin-inline: -20px; }
.home-hero { max-width: 1120px; margin: 0 auto; padding: 32px 20px 28px; display: grid; grid-template-columns: 1.05fr .95fr; gap: 40px; align-items: center; text-align: start; }
.home-hero .visual { order: 2; }
.eyebrow { display: block; color: var(--muted); font-size: var(--t-small); font-weight: 600; margin: 4px 0 24px; }
.eyebrow i { display: none; }
.home-hero h1 { font-size: clamp(1.9rem, 4.6vw, 3.2rem); line-height: 1.35; margin: 16px 0 12px; color: var(--engine); text-wrap: balance; }
.home-hero h1 em { font-style: normal; color: #A87A1C; } /* عنوان كبير: يكفيه تباين 3 إلى 1 */
.home-hero .lead { font-size: var(--t-body); margin: 0 0 24px; max-width: 34em; }
.search { background: var(--surface); border-radius: 20px; box-shadow: var(--shadow-hi); border: 1px solid var(--line); display: flex; align-items: stretch; padding: 8px; gap: 4px; }
.seg { flex: 1; border: 0; background: none; text-align: start; padding: 12px 16px; border-radius: 14px; cursor: pointer; min-width: 0; color: var(--engine); }
.seg:hover { background: var(--ivory); }
.seg small { display: block; font-size: var(--t-meta); color: var(--muted); }
.seg b { display: block; font-weight: 600; font-size: var(--t-body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.seg + .seg { border-inline-start: 1px solid var(--line); }
/* «الموعد» جملة ثابتة: مساحة أكبر، وتنزل سطرًا ثانيًا بدل أن تُقص */
.seg-when { flex: 1.5; }
.seg-when b { white-space: normal; overflow: visible; text-overflow: clip; line-height: 1.4; text-wrap: balance; }
.search .btn { border-radius: 14px; padding-inline: 28px; min-height: 0; }
.visual { position: relative; aspect-ratio: 1 / .92; border-radius: 32px; background: radial-gradient(90% 80% at 50% 100%, #F3E3B8 0%, #F8EFD8 38%, var(--ivory) 70%); overflow: hidden; }
.visual::before { content: ''; position: absolute; width: 78%; aspect-ratio: 1; border-radius: 50%; inset: auto 11% -26% 11%; background: var(--gold); opacity: .9; }
.visual::after { content: ''; position: absolute; left: 50%; bottom: 7%; width: 64%; height: 9%; transform: translateX(-50%); border-radius: 50%; background: radial-gradient(closest-side, rgba(255, 255, 255, .95), rgba(255, 255, 255, .55) 60%, rgba(255, 255, 255, 0)); z-index: 1; }
.trio { position: absolute; inset-inline: 0; bottom: 13%; height: 60%; display: flex; justify-content: center; align-items: flex-end; z-index: 2; direction: ltr; }
.trio .b { display: block; width: auto; max-width: 40%; object-fit: contain; filter: drop-shadow(0 14px 16px rgba(51, 51, 51, .22)); transition: transform .6s cubic-bezier(.2, .8, .2, 1); mix-blend-mode: multiply; }
.trio .b1 { height: 100%; order: 2; position: relative; z-index: 3; margin-inline: -2%; }
.trio .b2 { height: 78%; order: 1; }
.trio .b3 { height: 78%; order: 3; }
.visual:hover .trio .b1 { transform: translateY(-6px); }
.float { position: absolute; z-index: 3; top: 6%; inset-inline-end: 5%; background: var(--surface); border-radius: 14px; box-shadow: var(--shadow-hi); padding: 12px 16px; display: flex; gap: 12px; align-items: center; font-size: var(--t-meta); }
.float b { display: block; font-size: var(--t-small); color: var(--engine); }
.float span span { color: var(--muted); }
.fic, .svc-ic { width: 36px; height: 36px; border-radius: 10px; background: var(--gold-soft); color: var(--gold-text); display: grid; place-items: center; flex: none; }
.svc-ic.dark { background: var(--engine); color: var(--gold); }
.ico { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
@media (max-width: 900px) {
  .home-hero { grid-template-columns: 1fr; gap: 24px; padding-top: 20px; }
  .home-hero .visual { order: -1; aspect-ratio: 1 / .62; }
  .trio { height: 66%; bottom: 10%; }
  .float { inset-inline-end: auto; inset-inline-start: 50%; transform: translateX(50%); white-space: nowrap; padding: 8px 12px; }
  html[dir="ltr"] .float { transform: translateX(-50%); }
}
@media (max-width: 640px) {
  .search { flex-direction: column; padding: 12px; }
  .seg + .seg { border-inline-start: 0; border-top: 1px solid var(--line); border-radius: 0; }
  .search .btn { padding: 16px; margin-top: 8px; min-height: 52px; }
}

.home-s { max-width: 1120px; margin: 0 auto; padding: 40px 20px; }
.home-s.alt { max-width: none; background: var(--ivory); }
.home-s.alt > * { max-width: 1080px; margin-inline: auto; }
.sh { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.sh h2 { font-size: clamp(1.35rem, 3vw, 1.85rem); margin: 0; color: var(--engine); }
.sh p { margin: 2px 0 0; color: var(--muted); font-size: var(--t-small); }
.sh a { font-weight: 600; font-size: var(--t-small); white-space: nowrap; text-decoration: none; border-bottom: 2px solid var(--gold); }
/* «كل الأسعار»: مساحة لمس 44 بكسل على الأقل، والخط الذهبي يبقى تحت الكلمة */
.sh a[href="/prices"] { display: inline-flex; align-items: center; min-height: 44px; padding-inline: 8px; border-bottom: 0; text-decoration: underline 2px var(--gold); text-underline-offset: 6px; }

.svc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.svc { display: grid; justify-items: center; align-content: start; gap: 8px; text-align: center; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 20px 12px 16px; cursor: pointer; color: var(--engine); transition: transform .2s, box-shadow .2s, border-color .2s; }
.svc:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: transparent; }
.svc .svc-ic { width: 46px; height: 46px; border-radius: 14px; }
.svc .ico { width: 22px; height: 22px; }
.svc b { font-size: var(--t-body); line-height: 1.4; }
.svc small { color: var(--muted); font-size: var(--t-meta); }
.svc.main { background: var(--engine); color: var(--on-engine); border-color: var(--engine); }
.svc.main .svc-ic { background: var(--gold); color: var(--engine); }
.svc.main small { color: #D9D5CC; }
@media (max-width: 440px) { .svc-grid { grid-template-columns: repeat(3, 1fr); gap: 8px; } .svc { padding: 16px 8px 12px; border-radius: 16px; } .svc b { font-size: var(--t-small); } }

.rail { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(200px, 1fr); gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 2px 20px; scrollbar-width: none; }
.rail::-webkit-scrollbar { display: none; }
.rail > * { scroll-snap-align: start; }
@media (max-width: 560px) { .rail { grid-auto-columns: 46%; gap: 12px; } }
.ocard { display: flex; flex-direction: column; text-align: start; background: var(--surface); border: 0; border-radius: 18px; padding: 0; cursor: pointer; overflow: hidden; box-shadow: var(--shadow); color: var(--engine); transition: transform .25s, box-shadow .25s; }
.ocard:hover { transform: translateY(-3px); box-shadow: var(--shadow-hi); }
.ocard-pic { position: relative; display: grid; place-items: center; height: 170px; background: var(--photo-bg); border-bottom: 1px solid var(--line); }
.ocard-pic img { max-height: 140px; width: auto; max-width: 80%; object-fit: contain; mix-blend-mode: multiply; }
.grade { position: absolute; top: 10px; inset-inline-end: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 2px 12px; font-size: var(--t-meta); font-weight: 700; direction: ltr; }
.ocard-tx { display: grid; gap: 2px; padding: 12px 16px 16px; }
.ocard-tx b { font-size: var(--t-body); line-height: 1.4; }
.ocard-tx small { color: var(--muted); font-size: var(--t-meta); }
.ocard-price { margin-top: 8px; font-weight: 700; font-size: var(--t-small); }

.branch { display: flex; align-items: center; gap: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 16px 20px; box-shadow: var(--shadow); }
.branch + .branch { margin-top: 12px; }
.branch > div { flex: 1; min-width: 0; display: grid; }
.branch b { color: var(--engine); }
.branch span:not(.svc-ic) { color: var(--muted); font-size: var(--t-small); }
.branch .svc-ic { width: 44px; height: 44px; border-radius: 12px; }

/* التذييل */
.foot { background: #1F1F1F; color: #D9D5CC; border-top: 0; padding: 28px 20px; text-align: start; }
.foot-in { max-width: 1120px; margin: 0 auto; display: grid; gap: 12px; }
.foot .brand { color: #fff; }
.foot-legal { display: grid; gap: 8px; }
.foot-legal p { margin: 0; display: flex; flex-wrap: wrap; gap: 4px 16px; overflow-wrap: anywhere; }
.foot-legal p[dir="ltr"] { text-align: left; }
.foot-legal a { color: inherit; }
.foot-links { justify-content: flex-start; }
.foot-links a { color: #fff; }
.foot :focus-visible { outline-color: var(--gold); }

/* خطوات الحجز */
.stepper { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 16px; }
.step-of { color: var(--muted); font-size: var(--t-small); white-space: nowrap; }
.progress { height: 5px; background: var(--line); }
.flow h2 { font-size: clamp(1.4rem, 4.5vw, 1.8rem); margin: 20px 0 16px; }
.chip { background: var(--ivory); border-color: transparent; color: var(--engine); }
.option, .day, .time, .pay, .carpick { border: 1.5px solid var(--line); border-radius: 18px; background: var(--surface); transition: border-color .2s, box-shadow .2s, background .2s; }
.option:hover, .day:hover, .time:hover { border-color: var(--gold); box-shadow: var(--shadow); }
.option.on, .day.on, .time.on, .pay.on, .carpick.on { border-color: var(--gold); background: var(--gold-soft); box-shadow: 0 0 0 1px var(--gold); }
.option { display: flex; align-items: center; gap: 16px; padding: 16px; }
.option .opt-tx { flex: 1; min-width: 0; display: grid; gap: 2px; }
.option .opt-tx span { color: var(--muted); font-size: var(--t-small); }
.option > .price { font-size: var(--t-body); white-space: nowrap; display: grid; justify-items: end; line-height: 1.45; }
.option .svc-ic { width: 44px; height: 44px; border-radius: 12px; }
.option.on .svc-ic { background: var(--gold); color: var(--engine); }
.day { padding: 16px; border-radius: 16px; }
.time { border-radius: 14px; min-height: 52px; }
.actions { position: sticky; bottom: 0; z-index: 5; background: var(--surface); border-top: 1px solid var(--line); margin: 20px -20px 0; padding: 12px 20px calc(12px + env(safe-area-inset-bottom, 0px)); }
.field label { font-size: var(--t-small); }
.field input, .field select { min-height: 52px; border-radius: 14px; border-color: var(--line-strong); padding: 12px 16px; }
/* التركيز: حد غامق بعرض 2 مع هالة ذهبية خفيفة (الذهبي وحده لا يُرى على الأبيض) */
.field input:focus, .field select:focus { border-color: var(--engine); outline: 2px solid transparent; box-shadow: 0 0 0 1px var(--engine), 0 0 0 4px rgba(233, 181, 63, .35); }
.review { border-radius: 20px; padding: 20px 20px; box-shadow: var(--shadow); border-color: transparent; }
.review dt { font-size: var(--t-small); }
.policy, details.oils, .verify-box, .notice { border-radius: 18px; }
.oilpick { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.oilcard { border: 0; border-radius: 18px; padding: 0 0 12px; box-shadow: var(--shadow); overflow: hidden; text-align: start; gap: 2px; }
.oilcard::before { content: ''; position: absolute; inset: 0; border-radius: inherit; border: 2.5px solid transparent; pointer-events: none; transition: border-color .2s; z-index: 2; }
.oilcard.on { box-shadow: var(--shadow-hi); }
.oilcard.on::before { border-color: var(--gold); }
.oilcard img { height: 130px; padding: 12px; background: var(--photo-bg); border-bottom: 1px solid var(--line); margin-bottom: 8px; mix-blend-mode: multiply; }
.oilcard strong, .oilcard small, .oilcard .oilcard-price { padding-inline: 12px; }
.oilcard small { display: block; }
.qty { background: var(--ivory); border-radius: 16px; padding: 12px 12px; }
.qty .btn.small { width: 42px; padding: 0; font-size: var(--t-lead); background: var(--surface); }

/* الدخول */
.login .card { border-radius: 22px; box-shadow: var(--shadow-hi); border-color: transparent; padding: 24px; }
.btn.google, .btn.social { border-radius: 16px; min-height: 56px; }

/* حجوزاتي */
.list a { border-radius: 18px; padding: 16px 16px; transition: box-shadow .2s, border-color .2s; }
.list a:hover { box-shadow: var(--shadow); border-color: transparent; }
.list li.latest a { background: var(--gold-soft); border-color: var(--gold); }
.latest-tag { display: block; font-size: var(--t-meta); font-weight: 700; color: var(--gold-text); margin-bottom: 8px; }
.carrow { border-radius: 18px; }
.ticket .review { margin-top: 12px; }

@media (prefers-reduced-motion: reduce) {
  .svc, .ocard, .trio .b, .btn { transition: none !important; }
}
body:not(.on-home) .top .btn.cta { display: none; }
@media (max-width: 440px) {
  .top .brand span { position: static; width: auto; height: auto; overflow: visible; clip-path: none; font-size: var(--t-small); }
  .brand img { width: 36px; height: 36px; }
}
/* في الرئيسية يظهر زر «احجز» أيضًا، فاسم المتجر بجانب الشعار يدفعه إلى سطر ثانٍ حتى 440px: نخفي الاسم ويبقى الشعار */
@media (max-width: 440px) { body.on-home .top .brand span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); } }

/* السلة: خدمات أخرى وقطع تضاف إلى الطلب */
fieldset.extras { border: 0; padding: 0; margin: 8px 0 0; display: grid; gap: 12px; }
fieldset.extras legend { font-weight: 700; font-size: var(--t-lead); color: var(--engine); margin-bottom: 4px; padding: 0; }
.xgroup h4 { margin: 4px 0 8px; font-size: var(--t-body); color: var(--muted); font-weight: 600; }
.xsvc { display: grid; gap: 8px; }
.xs { display: flex; align-items: center; gap: 12px; background: var(--surface); border: 1.5px solid var(--line); border-radius: 16px; padding: 12px 12px; cursor: pointer; text-align: start; color: var(--engine); transition: border-color .2s, background .2s; }
.xs.on { border-color: var(--gold); background: var(--gold-soft); }
.xs-tx { flex: 1; min-width: 0; display: grid; }
.xs-tx small { color: var(--muted); }
.xs-btn { font-weight: 700; font-size: var(--t-small); padding: 8px 12px; border-radius: 999px; background: var(--ivory); white-space: nowrap; }
.xs.on .xs-btn { background: var(--gold); }
.xparts { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(150px, 46%); gap: 12px; overflow-x: auto; padding: 2px 2px 12px; scroll-snap-type: x mandatory; scrollbar-width: none; }
.xparts::-webkit-scrollbar { display: none; }
.xp { scroll-snap-align: start; position: relative; display: grid; gap: 4px; align-content: start; background: var(--surface); border-radius: 16px; box-shadow: var(--shadow); padding: 12px 12px 12px; }
.xp::before { content: ''; position: absolute; inset: 0; border-radius: inherit; border: 2px solid transparent; pointer-events: none; }
.xp.on::before { border-color: var(--gold); }
.xp img { width: 100%; height: 100px; object-fit: contain; mix-blend-mode: multiply; }
.xp b { font-size: var(--t-small); line-height: 1.5; }
.xp-price { font-weight: 700; font-size: var(--t-small); }
.xp .btn.small { min-height: 38px; }
.xp-qty { display: flex; align-items: center; justify-content: space-between; background: var(--ivory); border-radius: 12px; padding: 4px; }
.xp-qty button { width: 44px; height: 44px; border: 0; border-radius: 10px; background: var(--surface); font-size: var(--t-lead); cursor: pointer; color: var(--engine); }
.xp-qty button:disabled { opacity: .4; cursor: not-allowed; }
.xp-qty output { font-weight: 700; }
.xline { font-weight: 600; }

/* بين الخطوات: الصفحة تبهت ولا تقبل نقرة ثانية حتى تصل الخطوة التالية */
#view[aria-busy="true"] { opacity: .55; pointer-events: none; cursor: progress; transition: opacity .15s .1s; }

/* عرض الجوال: لا شيء أعرض من الشاشة.
   الخانة fieldset تأخذ في المتصفحات أصغر عرض لمحتواها، وسفاري يحسبه من مقاس صور الزيوت والقطع،
   فكانت الصفحة كلها تتسع لعشرة أعمدة وتصغر على الجوال. نجعل عرضها من عرض الصفحة لا من المحتوى */
fieldset { min-width: 0; min-inline-size: 0; max-width: 100%; }
.oilpick, .xparts, .rail, .xsvc, .options { max-width: 100%; contain: inline-size; }
.oilpick > *, .xparts > *, .rail > *, .xsvc > *, .options > *, .field, form > * { min-width: 0; }
.oilcard img, .xp img { max-width: 100%; }
html, body { overflow-x: clip; }

/* لا يكبّر الآيفون الخط من تلقاء نفسه: كان يكبّر نص بطاقات «خدمات أخرى» حتى تخرج عن الشاشة */
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
/* الأسماء الطويلة تنكسر إلى سطر جديد ولا تمد البطاقة */
body { overflow-wrap: break-word; }
.xs-tx b, .opt-tx strong, .svc b, .oilcard strong, .xp b, .ocard-tx b { overflow-wrap: anywhere; }
/* أعمدة لا تتسع لمحتواها: كل بطاقة بعرض القائمة بالضبط */
.xsvc, .options { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 560px) { .options { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.xs, .option { width: 100%; max-width: 100%; min-width: 0; }
@media (max-width: 440px) { .svc-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 370px) {
  .top .brand span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .navlink, .top .lang { padding: 8px 8px; }
}
/* الشريط العلوي لا يخرج عن الشاشة مع خط أكبر: تنزل الروابط سطرًا ثانيًا بدل أن تُقص */
.top-in { height: auto; min-height: 62px; }
.top-in > * { min-width: 0; }
.top nav { flex-wrap: wrap; justify-content: flex-end; row-gap: 0; }
.home-hero { grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); }
@media (max-width: 900px) { .home-hero { grid-template-columns: minmax(0, 1fr); } }
.home-hero > * { min-width: 0; }

/* ===== «طلبك»: البطاقات والصفحات المنبثقة والشريط السفلي (التصميم المعتمد 13 أكتوبر) ===== */
.flow .sub { color: var(--muted); margin: -8px 0 16px; }
.svc-ic.big { width: 48px; height: 48px; border-radius: 14px; }
.svc-ic.big .ico { width: 24px; height: 24px; }

/* بطاقات الأقسام */
.gtiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 8px 0 16px; }
@media (min-width: 560px) { .gtiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
/* عدد فردي من البطاقات في عمودين: الأخيرة تأخذ السطر كله بدل فراغ بجانبها */
@media (max-width: 559px) { .gtiles > .gt:last-child:nth-child(odd) { grid-column: 1 / -1; grid-template-columns: auto auto; justify-content: center; align-items: center; column-gap: 12px; text-align: start; } .gtiles > .gt:last-child:nth-child(odd) .gi { grid-row: span 2; } }
.gt { position: relative; display: grid; justify-items: center; align-content: start; gap: 8px; text-align: center; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 16px 12px 16px; cursor: pointer; color: var(--engine); min-width: 0; transition: border-color .2s, box-shadow .2s, transform .2s; }
.gt:hover { border-color: var(--gold); box-shadow: var(--shadow); }
.gt:active { transform: scale(.98); }
.gt .gi { width: 44px; height: 44px; border-radius: 14px; background: var(--gold-soft); color: var(--gold-text); display: grid; place-items: center; }
.gt b { font-size: var(--t-body); line-height: 1.5; overflow-wrap: anywhere; text-wrap: balance; }
.gt small { color: var(--muted); font-size: var(--t-meta); }
.gt.big { background: var(--engine); color: var(--on-engine); border-color: var(--engine); }
.gt.big .gi { background: var(--gold); color: var(--engine); }
.gt.big small { color: #D9D5CC; }
.gt.has { border-color: var(--gold); box-shadow: 0 0 0 1px var(--gold); }
.gt .gc { position: absolute; top: 8px; inset-inline-end: 8px; min-width: 22px; height: 22px; border-radius: 999px; background: var(--gold); color: var(--engine); font-weight: 700; font-size: var(--t-meta); display: grid; place-items: center; padding: 0 8px; }

/* السلة */
.cart { display: grid; gap: 12px; margin: 0 0 20px; }
.cline { display: grid; grid-template-columns: 44px minmax(6.5em, 1fr) auto; align-items: start; gap: 12px; background: var(--surface); border-radius: 16px; padding: 12px 12px; box-shadow: var(--shadow); }
.cline img { width: 44px; height: 44px; object-fit: contain; mix-blend-mode: multiply; }
.cline .svc-ic { width: 44px; height: 44px; border-radius: 12px; }
.cline .cn { display: grid; gap: 2px; min-width: 0; text-align: start; background: none; border: 0; padding: 0; font: inherit; color: inherit; cursor: inherit; }
button.cn { cursor: pointer; }
.cline .cn b { font-size: var(--t-small); line-height: 1.5; overflow-wrap: anywhere; text-wrap: balance; }
.cline .cn .edit-hint { color: var(--gold-text); font-weight: 600; font-size: var(--t-meta); text-decoration: underline; text-underline-offset: 3px; justify-self: start; }
.cline .cn small { color: var(--muted); font-size: var(--t-meta); overflow-wrap: anywhere; }
.cline .cp2 { font-weight: 700; font-size: var(--t-small); line-height: 1.5; text-align: end; }
.cline .cp2 small { color: var(--muted); font-weight: 500; }
.cline .cact { grid-column: 2 / -1; display: flex; gap: 8px; justify-content: flex-end; align-items: center; }
/* زر الحذف وحده: تحت السعر مباشرة، فلا يأخذ سطرًا فارغًا كاملًا */
.cline:has(> .cact):not(:has(.qs)) { grid-template-rows: auto 1fr; }
.cline > img, .cline > .svc-ic { grid-column: 1; grid-row: 1; }
.cline > .cn { grid-column: 2; }
.cline > .cp2 { grid-column: 3; grid-row: 1; }
.cline:has(> .cact):not(:has(.qs)) .cn { grid-row: 1 / span 2; }
.cline:not(:has(.qs)) .cact { grid-column: 3; grid-row: 2; align-self: end; }
.cline > img, .cline > .svc-ic { align-self: start; }
.cline.shop { background: var(--gold-soft); box-shadow: none; border: 1px dashed var(--gold); }
.crm { width: 44px; height: 44px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); cursor: pointer; display: grid; place-items: center; color: var(--engine); }
.crm .ico { width: 16px; height: 16px; }
.qs { display: flex; align-items: center; gap: 8px; background: var(--ivory); border-radius: 12px; padding: 4px; }
.qs button { width: 44px; height: 44px; border: 0; border-radius: 9px; background: var(--surface); font-size: var(--t-lead); cursor: pointer; color: var(--engine); }
.qs button:disabled { opacity: .4; }
.qs b { min-width: 20px; text-align: center; }
.cart.rev .cline { box-shadow: none; border: 1px solid var(--line); }
.addrow { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; align-items: center; gap: 12px; background: var(--surface); border: 1.5px dashed var(--line); border-radius: 16px; padding: 12px 12px; cursor: pointer; text-align: start; font: inherit; color: var(--engine); }
.addrow .cn { display: grid; } .addrow small { color: var(--muted); font-size: var(--t-meta); }
.addrow .plus { width: 30px; height: 30px; border-radius: 999px; background: var(--gold); display: grid; place-items: center; font-weight: 700; }
.pickf { display: flex; gap: 8px; align-items: center; justify-content: center; background: var(--gold-soft); border: 1.5px dashed var(--gold); color: var(--gold-text); border-radius: 14px; padding: 12px; font: inherit; font-weight: 700; cursor: pointer; }
.resp { display: flex; gap: 8px; align-items: center; color: var(--muted); font-size: var(--t-small); }
.resp .ico, .note .ico, .small .ico { width: 16px; height: 16px; flex: none; vertical-align: -3px; margin-inline-end: 4px; }
.note { display: flex; gap: 8px; align-items: flex-start; background: var(--gold-soft); border-radius: 14px; padding: 12px 12px; font-size: var(--t-small); }
.review .tt { font-weight: 700; color: var(--engine); }
.review dd.tt { font-size: var(--t-lead); }
/* «حجوزاتي» في صفحة الحساب: الزر في مكانه تحت القائمة، لا شريط ثابت فوق صفحة شبه فارغة */
.account-page .tabpanel > .actions { position: static; border: 0; background: none; margin: 20px 0 8px; padding: 0; }
.policy .field-err:not(:empty) { margin: 8px 0 0; }

/* آخر طلب */
.lastv { background: var(--surface); border: 1.5px solid var(--gold); border-radius: 18px; padding: 16px 16px; margin-bottom: 16px; }
.lvh { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; color: var(--muted); font-size: var(--t-small); }
.lvt { display: flex; gap: 8px; align-items: center; color: var(--gold-text); font-weight: 700; }
.lastv ul { margin: 8px 0; padding-inline-start: 20px; }
.lvf { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }

/* بحث وأزرار تصفية */
.srch { display: flex; align-items: center; gap: 8px; background: var(--surface); border: 1.5px solid var(--line-strong); border-radius: 14px; padding: 0 12px; margin-bottom: 12px; }
.srch:focus-within { border-color: var(--engine); box-shadow: 0 0 0 1px var(--engine), 0 0 0 4px rgba(233, 181, 63, .35); }
.srch .qx[hidden] { display: none; }
.srch .ico { color: var(--muted); flex: none; }
.srch input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font: inherit; padding: 12px 0; font-size: var(--t-body); }
.srch .qx { position: relative; border: 0; background: var(--ivory); border-radius: 999px; width: 36px; height: 36px; display: grid; place-items: center; cursor: pointer; }
.srch .qx::before { content: ''; position: absolute; inset: -4px; } /* مساحة لمس 44 */
.srch .qx .ico { width: 14px; height: 14px; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin: 0 -4px 16px; padding: 4px; }
.chips.scroll::-webkit-scrollbar { display: none; }
.chips.scroll .chip { flex: none; padding: 8px 16px; font-size: var(--t-small); white-space: nowrap; min-height: 44px; min-width: 44px; }
.chip.on { background: var(--engine); color: var(--on-engine); border-color: var(--engine); }
.empty { display: grid; gap: 4px; text-align: center; padding: 28px 12px; color: var(--muted); }
.empty b { color: var(--engine); }

/* «سأحضر زيتي معي» و«اترك الاختيار للفني» */
.own { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; align-items: center; gap: 12px; width: 100%; background: var(--surface); border: 1.5px solid var(--line); border-radius: 16px; padding: 12px; margin-bottom: 16px; cursor: pointer; text-align: start; font: inherit; color: var(--engine); }
.own.on { border-color: var(--gold); background: var(--gold-soft); }
.own .svc-ic { width: 44px; height: 44px; }
.own .ot { display: grid; gap: 2px; min-width: 0; } .own small { color: var(--muted); }
.own .op { font-weight: 700; white-space: nowrap; }

/* شبكة الصور (زيوت وقطع وفلاتر) */
.pgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 560px) { .pgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.pcard { position: relative; display: grid; grid-template-rows: auto 1fr; background: var(--surface); border: 0; border-radius: 18px; box-shadow: var(--shadow); padding: 0; cursor: pointer; text-align: start; font: inherit; color: var(--engine); overflow: hidden; min-width: 0; }
.pcard.on { box-shadow: 0 0 0 2px var(--gold), var(--shadow); }
.pcard .media { position: relative; display: block; background: linear-gradient(180deg, #fff, var(--ivory)); aspect-ratio: 1 / 1; overflow: hidden; }
.pcard .media img { position: absolute; inset: 12px; width: calc(100% - 20px); height: calc(100% - 20px); max-width: none; object-fit: contain; mix-blend-mode: multiply; }
.pcard .grade { position: absolute; top: 8px; inset-inline-end: 8px; background: var(--surface); border-radius: 999px; padding: 2px 8px; font-size: var(--t-meta); font-weight: 700; box-shadow: var(--shadow); z-index: 1; }
.pcard .tick { position: absolute; top: 8px; inset-inline-start: 8px; width: 24px; height: 24px; border-radius: 999px; background: var(--gold); display: grid; place-items: center; font-weight: 700; z-index: 1; }
.pcard .ob { display: grid; gap: 4px; padding: 12px 12px 12px; align-content: start; min-width: 0; }
.pcard .br { color: var(--gold-text); font-size: var(--t-meta); font-weight: 600; }
.pcard .nm { font-weight: 600; font-size: var(--t-body); line-height: 1.5; overflow-wrap: anywhere; text-wrap: balance; }
.pcard .row { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; flex-wrap: wrap; margin-top: auto; }
.pcard .sz { color: var(--muted); font-size: var(--t-meta); }
.pcard .pr { font-weight: 700; font-size: var(--t-body); }

/* قائمة «أخرى» بأقسامها */
.msec h3 { display: flex; gap: 8px; align-items: center; margin: 20px 0 12px; font-size: var(--t-body); }
.msec h3 .ico { color: var(--gold-text); }
.msub h4 { margin: 12px 0 8px; color: var(--muted); font-size: var(--t-small); font-weight: 600; }
.glist { display: grid; gap: 8px; }
.gitem { display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; align-items: start; gap: 12px; width: 100%; background: var(--surface); border: 1.5px solid var(--line); border-radius: 14px; padding: 12px; cursor: pointer; text-align: start; font: inherit; color: var(--engine); }
.gitem.on { border-color: var(--gold); background: var(--gold-soft); }
.gitem .rd { width: 26px; height: 26px; border-radius: 999px; background: var(--ivory); display: grid; place-items: center; font-weight: 700; }
.gitem.on .rd { background: var(--gold); }
.gitem .gn { display: grid; gap: 2px; min-width: 0; font-weight: 600; line-height: 1.5; overflow-wrap: anywhere; text-wrap: balance; }
.gitem .gn small { color: var(--muted); font-weight: 500; font-size: var(--t-meta); }
.gitem .gn small.incart { color: var(--gold-text); font-weight: 700; }
.gitem .gp { font-weight: 700; white-space: nowrap; display: grid; justify-items: end; font-size: var(--t-body); line-height: 1.5; }
.gitem .gp small { color: var(--muted); font-weight: 500; font-size: var(--t-meta); }

/* اليوم والوقت في صفحة واحدة */
.days.scroll { display: flex; overflow-x: auto; gap: 8px; padding: 4px 4px 8px; scrollbar-width: none; margin: 0 -4px 8px; }
.days.scroll::-webkit-scrollbar { display: none; }
.days.scroll .day { flex: none; width: 76px; justify-items: center; text-align: center; padding: 12px 8px; }
.days.scroll .day small { color: var(--muted); font-size: var(--t-meta); white-space: nowrap; }
.days.scroll .day b { font-size: var(--t-title); line-height: 1.2; }
.days.scroll .day span { font-size: var(--t-meta); }
.days.scroll .day.on { background: var(--engine); border-color: var(--engine); color: var(--on-engine); box-shadow: none; }
.days.scroll .day.on small, .days.scroll .day.on span { color: #D9D5CC; }
.tgroup { background: var(--surface); border-radius: 18px; padding: 16px; box-shadow: var(--shadow); margin-bottom: 12px; }
.tgroup h3 { display: flex; gap: 8px; align-items: center; margin: 0 0 12px !important; font-size: var(--t-body); }
.tgroup h3 .ico { color: var(--gold-text); }
.tgroup .times { grid-template-columns: repeat(auto-fill, minmax(5.5em, 1fr)); } /* بالـ em: مع الخط الأكبر تقل الأعمدة ولا ينكسر الوقت إلى سطرين */
.time.on { background: var(--engine); border-color: var(--engine); color: var(--on-engine); }

/* الشريط الثابت أسفل الصفحة */
#view:has(.mbar:not(.checkout-actions)) { padding-bottom: 40px; }
/* الشريط الثابت لا يغطي روابط الخصوصية والشروط في آخر الصفحة */
body:has(.mbar:not(.checkout-actions)) { padding-bottom: var(--mbar-h, calc(68px + env(safe-area-inset-bottom))); }
/* العنصر الذي عليه التركيز لا يختفي تحت الشريط العلوي أو السفلي */
html { scroll-padding-top: 76px; }
html:has(.mbar:not(.checkout-actions)) { scroll-padding-bottom: calc(var(--mbar-h, 68px) + 16px); }
.mbar { position: fixed; z-index: 40; inset-inline: 0; bottom: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 12px max(16px, calc((100vw - 640px) / 2 + 16px)) calc(12px + env(safe-area-inset-bottom)); background: rgba(255, 255, 255, .96); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-top: 1px solid var(--line); box-shadow: 0 -6px 24px rgba(31, 31, 31, .06); }
.mback { width: 44px; height: 44px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); cursor: pointer; display: grid; place-items: center; color: var(--engine); }
/* السهم مرسوم يشير إلى اليسار (الرجوع في الإنجليزية)، وفي العربية يُقلب ليشير إلى اليمين */
html[dir="rtl"] .mback .ico { transform: scaleX(-1); }
.mt { display: grid; gap: 0; min-width: 0; text-align: start; background: none; border: 0; padding: 0; font: inherit; color: var(--engine); cursor: pointer; }
.mt:disabled { cursor: default; }
.mt b { font-size: var(--t-body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mt span { color: var(--muted); font-size: var(--t-meta); line-height: 1.4; }
.mbar .mback { flex: none; }
.mbar .mt { flex: 999 1 7em; }
.mbar .btn.primary { flex: 1 0 auto; min-height: 48px; padding: 12px 20px; white-space: nowrap; }
.mbar .btn.primary:disabled { opacity: .45; cursor: not-allowed; }
body.sheet-open .mbar { visibility: hidden; }

/* الصفحة المنبثقة لكل بطاقة */
.sheet { position: fixed; inset: 0; z-index: 60; display: flex; align-items: flex-end; justify-content: center; }
.sheet-bg { position: absolute; inset: 0; background: rgba(31, 31, 31, .45); opacity: 0; transition: opacity .25s; }
.sheet.in .sheet-bg { opacity: 1; }
.sheet.closing { pointer-events: none; }
.sheet .panel { position: relative; width: 100%; max-width: 560px; max-height: 92vh; max-height: 92dvh; overflow-y: auto; overscroll-behavior: contain; background: var(--ivory); border-radius: 24px 24px 0 0; padding: 16px 16px 0; transform: translateY(100%); transition: transform .28s cubic-bezier(.2, .8, .2, 1); }
.sheet.in .panel { transform: none; }
.sheet .panel { scroll-padding-bottom: 110px; } /* الخانة المختارة لا تختفي تحت الشريط السفلي */
.sheet .panel:focus { outline: none; }
@media (min-width: 700px) { .sheet { align-items: center; } .sheet .panel { border-radius: 24px; max-height: 88vh; } }
@media (prefers-reduced-motion: reduce) { .sheet .panel, .sheet-bg { transition: none; } }
body.sheet-open { overflow: hidden; }
.pclose { position: sticky; top: 0; float: inline-end; z-index: 3; width: 44px; height: 44px; border-radius: 999px; border: 0; background: var(--surface); box-shadow: var(--shadow); cursor: pointer; display: grid; place-items: center; color: var(--engine); }
/* بطاقة التأكيد: عنوان قصير وسطر وزران جنبًا إلى جنب (يعمل بالعربية والإنجليزية من 320px) */
.csheet .ctitle { margin: 4px 0 8px; padding-inline-end: 48px; font-size: var(--t-title); line-height: 1.35; color: var(--engine); overflow-wrap: anywhere; }
.csheet .ctext { margin: 0 0 20px; color: var(--muted); }
.csheet .cbtns { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding-bottom: calc(16px + env(safe-area-inset-bottom)); }
.csheet .cbtns .btn { width: 100%; min-width: 0; padding-inline: 12px; text-align: center; line-height: 1.3; }
.ghead { display: flex; gap: 12px; align-items: center; margin: 4px 0 16px; padding-inline-end: 48px; }
.ghead h3 { margin: 0; font-size: var(--t-lead); line-height: 1.5; overflow-wrap: anywhere; text-wrap: balance; }
.ghead span:not(.svc-ic):not(.av) { color: var(--muted); font-size: var(--t-small); }
.pimg { position: relative; background: var(--photo-bg); border-radius: 20px; height: 220px; margin-bottom: 12px; overflow: hidden; }
.pimg img { position: absolute; inset: 16px; width: calc(100% - 28px); height: calc(100% - 28px); max-width: none; object-fit: contain; mix-blend-mode: multiply; }
/* عنوان البطاقة وسطرها فوق المحتوى: يتركان مكان زر الإغلاق، وما بعدهما بعرض البطاقة كله (أوقات «تغيير الموعد») */
.shead { padding-inline-end: 48px; margin: 4px 0 12px; }
.shead h3 { margin: 0 0 4px; font-size: var(--t-lead); line-height: 1.5; overflow-wrap: anywhere; text-wrap: balance; }
.shead p { margin: 0; }
.shead + .pbody { clear: both; }
.pbody { display: grid; gap: 8px; }
.pbody h3 { margin: 0; font-size: var(--t-lead); line-height: 1.5; overflow-wrap: anywhere; text-wrap: balance; }
.pbody .br { color: var(--gold-text); font-weight: 600; font-size: var(--t-small); }
.tags { display: flex; gap: 8px; flex-wrap: wrap; }
.tags span { background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; font-size: var(--t-meta); }
.tags .g { background: var(--engine); color: var(--on-engine); border-color: var(--engine); }
.qbox { background: var(--surface); border-radius: 18px; padding: 16px; display: grid; gap: 12px; }
.qbox h4 { margin: 0; }
.qhead { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.estc { display: inline-flex; gap: 4px; align-items: center; background: var(--gold-soft); color: var(--gold-text); border-radius: 999px; padding: 4px 12px; font-size: var(--t-meta); font-weight: 600; }
.estc .ico { width: 16px; height: 16px; }
.stepq { display: flex; align-items: center; justify-content: center; gap: 24px; }
.stepq button { width: 48px; height: 48px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: var(--t-title); cursor: pointer; color: var(--engine); }
.stepq button:disabled { opacity: .35; cursor: not-allowed; }
.stepq output { display: grid; justify-items: center; min-width: 60px; }
.stepq output b { font-size: 1.8rem; line-height: 1.1; }
.stepq output small { color: var(--muted); }
.calc { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; border-top: 1px solid var(--line); padding-top: 8px; }
.calc span { color: var(--muted); font-size: var(--t-small); }
.calc b { font-size: var(--t-lead); white-space: nowrap; }
.calc.s { border: 0; padding-top: 0; }
.carpick2 .cpl { font-weight: 700; margin: 0 0 8px; }
.cps { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.cp { display: grid; gap: 2px; text-align: start; background: var(--surface); border: 1.5px solid var(--line); border-radius: 14px; padding: 12px 12px; cursor: pointer; font: inherit; color: var(--engine); min-width: 0; }
.cp span { font-weight: 600; overflow-wrap: anywhere; }
.cp b { font-size: var(--t-small); color: var(--muted); font-weight: 600; }
.pfoot .btn.primary:disabled, .pfoot .btn.primary[aria-disabled="true"] { opacity: .45; cursor: not-allowed; }
.pfoot .btn.primary[aria-disabled="true"]:hover { background: var(--gold); }
.cp.on { border-color: var(--gold); background: var(--gold-soft); box-shadow: 0 0 0 1px var(--gold); }
.cp.on b { color: var(--engine); }
.cp.other { border-style: dashed; }
.otherbox { display: grid; gap: 8px; margin-top: 12px; background: var(--surface); border-radius: 14px; padding: 12px; }
.otherbox label { font-weight: 600; }
.otherbox input { font: inherit; font-size: max(16px, 1rem); min-height: 48px; padding: 12px; border: 1.5px solid var(--line-strong); border-radius: 12px; min-width: 0; }
.otherbox input:focus { outline: 2px solid transparent; border-color: var(--engine); box-shadow: 0 0 0 1px var(--engine), 0 0 0 4px rgba(233, 181, 63, .35); }
.otherbox p { margin: 0; color: var(--muted); display: flex; gap: 4px; align-items: flex-start; }
.pfoot { position: sticky; bottom: 0; z-index: 2; margin: 16px -16px 0; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 -6px 18px rgba(31, 31, 31, .05); }
.pfoot .pt { flex: 1 1 7em; display: grid; min-width: 0; }
.pfoot .pt b { font-size: var(--t-lead); text-wrap: balance; } /* «يبدأ من / 200 ر.س» لا «يبدأ من 200 / ر.س» */
.pfoot .pt span { color: var(--muted); font-size: var(--t-meta); }
.pfoot .btn.primary { min-height: 48px; padding: 12px 20px; }

/* «خدماتنا» في الرئيسية: للتصفح فقط */
.home-s .sh p { margin: 2px 0 0; color: var(--muted); }
.secs { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 12px; }
.secard { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 16px 16px; min-width: 0; }
.secard.main { background: var(--engine); color: var(--on-engine); border-color: var(--engine); }
.secard.main .svc-ic { background: var(--gold); color: var(--engine); }
.secard.main small { color: #D9D5CC !important; }
.sech { display: flex; gap: 12px; align-items: center; margin-bottom: 8px; }
.sech h3 { margin: 0; font-size: var(--t-body); }
.secard ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.secard li { display: flex; justify-content: space-between; gap: 12px; font-size: var(--t-small); border-top: 1px dashed var(--line); padding-top: 8px; }
.secard li:first-child { border-top: 0; padding-top: 0; }
.secard li span { min-width: 0; overflow-wrap: anywhere; }
.secard li small { color: var(--muted); white-space: nowrap; font-weight: 600; }

/* العلب تقفز عند اللمس */
.visual { cursor: pointer; }
@keyframes hop { 0%, 100% { transform: translateY(0); } 35% { transform: translateY(-18px); } 60% { transform: translateY(0); } 78% { transform: translateY(-6px); } }
.visual.hop .trio .b { animation: hop .9s cubic-bezier(.3, .7, .3, 1); }
.visual.hop .trio .b2 { animation-delay: .08s; }
.visual.hop .trio .b3 { animation-delay: .16s; }
@media (prefers-reduced-motion: reduce) { .visual.hop .trio .b { animation: none; } }

/* زر الحساب في الشريط العلوي */
.top .navlink.logout { display: none; }
.acct { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); background: var(--surface); color: var(--engine); border-radius: 999px; padding: 4px 12px 4px 4px; font: inherit; font-size: var(--t-small); cursor: pointer; min-height: 44px; min-width: 44px; }
html[dir="rtl"] .acct { padding: 4px 4px 4px 12px; }
.acct > .ico { margin-inline-start: 8px; }
.av { width: 32px; height: 32px; border-radius: 999px; background: var(--engine); color: var(--gold); display: grid; place-items: center; font-weight: 700; flex: none; }
.av.big { width: 48px; height: 48px; font-size: var(--t-title); }
.av .ico { width: 18px; height: 18px; }
@media (max-width: 560px) {
  .top #nav-bookings { display: none; }
  .acct-tx { display: none; }
  .acct, html[dir="rtl"] .acct { padding: 4px; }
  .acct > .ico { margin: 4px; }
}
.acct-links { display: grid; gap: 8px; margin: 16px 0 20px; }
.acct-links .btn { justify-content: center; width: 100%; }
.danger-t { color: var(--bad); }
/* المراجعة في الجوال الضيق: العنوان فوق قيمته، حتى لا تخرج اللوحة عن الشاشة */
@media (max-width: 400px) {
  .review { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .review dd { margin-bottom: 8px; }
  .review .plate { max-width: 100%; }
}

/* أسطح المتصفح من ألوان الهوية */
::selection { background: var(--gold); color: var(--engine); }

/* خانات الكتابة: 16px على الأقل في كل المقاسات، حتى لا يكبّر سفاري الآيفون الصفحة عند الضغط على الخانة
   (أي خانة داخل نص أصغر مثل .small أو بوحدة em ترجع 16px، والأكبر مثل خانة الرمز تبقى كما هي) */
:is(input:not([type="checkbox"], [type="radio"], [type="range"], [type="hidden"]), select, textarea) { font-size: max(16px, 1em); }

/* شاشة الدخول وشاشة رمز التحقق في الجوال: خط مريح للقراءة (لا يقل عن 14px) وأزرار وخانات 52px،
   والمساحة من الهوامش والفراغات لا من الخط، فتظهر البطاقة كاملة بلا تمرير في 375×667 و390×844 */
@media (max-width: 520px) {
  body:has(main > section.login) { min-height: 100vh; min-height: 100dvh; }
  /* التذييل الكبير مخفي هنا، وروابط الخصوصية والشروط تظهر سطرًا أسفل بطاقة الدخول (.login-legal) */
  body:has(main > section.login) .foot { display: none; }
  main:has(> section.login) { padding: 0 16px 12px; }
  main > section.login { margin-top: 12px; padding-top: 0; }
  /* العنوان 26px والمقدمة 16px */
  .login h1 { font-size: 1.625rem; font-weight: 700; line-height: 1.3; margin: 0 0 8px; }
  .login .lead { font-size: 1rem; line-height: 1.5; margin: 0 0 12px; }
  /* البطاقة: حشوة 16px وفراغات 10px */
  .login .card { padding: 16px; gap: 12px; border-radius: 18px; }
  .login .form { gap: 12px; }
  .login .form > p:not(.small) { margin: 0; font-size: 1rem; line-height: 1.5; }
  /* الخانات: عنوان 16px، وخانة 52px بخط 18px، وخانة الرمز تبقى أكبر */
  .login .field label { font-size: 1rem; line-height: 1.3; margin-bottom: 8px; }
  .login .field input, .login .field select { min-height: 52px; padding-block: 8px; font-size: 1.125rem; }
  .login .field input.code { font-size: var(--t-title); }
  .login .field-err { margin: 0; min-height: 0; font-size: var(--t-small); line-height: 1.4; }
  .login .field-err:not(:empty) { margin-top: 4px; }
  /* كل الأزرار (الأساسي وجوجل والثانوي) 52px بخط 17px */
  .login .btn, .login .btn.google, .login .btn.social { min-height: 52px; padding: 8px 16px; font-size: 1rem; line-height: 1.3; }
  /* «أو» والملاحظات والروابط 14px على الأقل */
  .login .or { font-size: var(--t-small); line-height: 1.3; }
  .login .small { font-size: var(--t-small); line-height: 1.5; }
  .login .row-links { gap: 4px 16px; }
  .login .row-links .link { min-height: 44px; padding-block: 0; font-size: 1rem; display: inline-flex; align-items: center; }
  .login .login-legal { display: flex; font-size: var(--t-small); line-height: 1.3; }
  .login .login-legal a { min-height: 44px; }
}

/* سطر «الخصوصية · الشروط» في شاشة الدخول: للجوال فقط (في الشاشات الأكبر التذييل ظاهر وفيه نفس الروابط) */
.login-legal { display: none; justify-content: center; align-items: center; gap: 8px; margin: 0; color: var(--muted); font-size: var(--t-meta); line-height: 1.2; }
.login-legal a { color: inherit; display: inline-flex; align-items: center; min-height: 44px; padding-inline: 4px; text-decoration: underline; text-underline-offset: 3px; }

/* حسابي: شريط اللسانات (حجوزاتي، سياراتي، بياناتي) ثلاثة أزرار متساوية، والفعّال بخط ذهبي تحته */
.tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 0 0 20px; border-bottom: 1px solid var(--line); }
.tabs [role="tab"] {
  background: none; border: 0; border-bottom: 3px solid transparent; margin-bottom: -1px; border-radius: 8px 8px 0 0;
  padding: 12px 0; min-height: 44px; font: inherit; font-size: min(var(--t-small), 5vw); font-weight: 600; color: var(--muted); cursor: pointer;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0;
}
.tabs [role="tab"]:hover { background: var(--gold-soft); color: var(--engine); }
.tabs [role="tab"][aria-selected="true"] { color: var(--gold-text); border-bottom-color: var(--gold); }
.tabs [role="tab"]:focus-visible { outline-offset: -3px; }
.account-page .tabpanel > .ghead { margin-top: 8px; }
.account-page .acct-links { margin-top: 20px; }
.account-page .acct-links .btn { width: auto; justify-self: start; }
.account-page .ghead { padding-inline-end: 0; }

/* بعد قاعدة أزرار الدخول في الجوال: مكان الشعار محفوظ فلا يركب النص عليه */
.login .btn.social { padding-inline: 48px; font-size: 1rem; }
.login .btn.social .brand-logo { inset-inline-start: 16px; }

/* شاشة رمز التحقق: ست خانات، والرقم مع «تغيير» في سطر واحد، ثم «لم يصلك الرمز؟» */
.otp-screen { text-align: center; }
.otp-screen .btn { width: 100%; }
.otp-badge { width: 56px; height: 56px; margin: 4px auto; border-radius: 50%; background: #E7F9EE; display: grid; place-items: center; }
.otp-badge .brand-logo { width: 28px; height: 28px; }
.otp-title { margin: 0; font-size: var(--t-title); line-height: 1.35; color: var(--engine); }
.otp-sent { margin: 0; color: var(--muted); line-height: 1.6; }
.otp-number { color: var(--text); font-weight: 600; font-family: 'Sora', var(--font); }
.otp-change { background: none; border: 0; padding: 8px 4px; min-height: 44px; color: var(--gold-text); font: inherit; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.otp-field { text-align: start; }
.otp-boxes { position: relative; display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; max-width: 360px; margin-inline: auto; cursor: text; }
.otp-cell { aspect-ratio: 1 / 1.15; min-height: 52px; display: grid; place-items: center; border: 1.5px solid var(--line-strong); border-radius: 12px; background: var(--surface);
  font: 600 1.5rem/1 'Sora', var(--font); color: var(--ink); transition: border-color .15s, box-shadow .15s; }
.otp-cell.filled { border-color: var(--engine); }
.otp-cell.active { border-color: var(--gold-deep); box-shadow: 0 0 0 3px rgba(233, 181, 63, .3); }
.otp-cell.active:empty::after { content: ''; width: 2px; height: 1.4rem; background: var(--engine); animation: otp-caret 1s steps(1) infinite; }
@keyframes otp-caret { 50% { opacity: 0; } }
.otp-boxes.bad .otp-cell { border-color: var(--bad); }
/* الحقل الحقيقي فوق الخانات وشفاف: يقبل اللصق وتعبئة الرمز التلقائية، و16px حتى لا يكبّر iPhone الصفحة */
.otp-input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; font-size: 16px; color: transparent; caret-color: transparent; border: 0; background: transparent; letter-spacing: 2.5em; }
.otp-screen .field-err { text-align: center; }
.resend-row { margin: 0; font-size: var(--t-small); line-height: 1.5; }
.resend-wait { color: var(--muted); font-variant-numeric: tabular-nums; }
.resend-btn { background: none; border: 0; padding: 8px 4px; min-height: 44px; color: var(--gold-text); font: inherit; font-weight: 700; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { .otp-cell.active:empty::after { animation: none; } }
@media (max-width: 380px) { .login .btn.social { font-size: .875rem; padding-inline: 40px; } .login .btn.social .brand-logo { inset-inline-start: 12px; width: 20px; height: 20px; } }

/* وسائل الدفع: الاسم والوصف ثم شعارات الوسيلة في خانات بيضاء صغيرة، مثل صفحات الدفع في المتاجر الكبيرة */
.pay { align-items: center; }
.pay .pay-text { flex: 1 1 auto; min-width: 0; }
.pay .pay-logos { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.pay .pay-logo, .foot-pay .pay-logo, .paid-via .pay-logo { display: inline-grid; place-items: center; width: 48px; height: 32px; padding: 4px 8px; background: var(--photo-bg); border: 1px solid #D9D5CC; border-radius: 8px; box-sizing: border-box; overflow: hidden; }
.pay-logo svg, .pay-logo img { display: block; width: 100%; height: 100%; object-fit: contain; }
.pay-logo.tamara { width: 72px; }
.pay-logo.applepay { padding: 4px; }
.pay-logo-text { font: 700 .75rem/1 'Sora', var(--font); color: var(--ink); white-space: nowrap; }
.pay.off .pay-logos { filter: grayscale(1); opacity: .7; }
@media (max-width: 360px) { .pay-logo { width: 44px; height: 28px; } .pay-logos { gap: 4px; } }

/* شعار شركة السيارة: خانة بيضاء صغيرة بحجم ثابت والشعار داخلها كما هو، مثل قوائم الشركات في تطبيقات السيارات */
.car-logo { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 28px; padding: 4px; box-sizing: border-box; background: var(--photo-bg); border: 1px solid #E6E3DC; border-radius: 8px; vertical-align: middle; }
.car-logo img { display: block; max-width: 100%; max-height: 100%; object-fit: contain; }
.car-logo.none { visibility: hidden; }
.car-line { display: flex; align-items: center; gap: 8px; min-width: 0; }
.combo-opt .car-logo { align-self: center; }
dd > .car-logo { margin-inline-end: 8px; }
/* الشركة المختارة: الشعار داخل الخانة في أولها */
.combo-logo { position: absolute; inset-inline-start: 8px; top: 0; height: 100%; display: flex; align-items: center; pointer-events: none; z-index: 1; }
.combo-logo:empty { display: none; }
.combo.has-logo > input { padding-inline-start: 56px; }
/* خرائط Google: شعار الدبوس بجانب رابط الموقع */
.maps-link { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; }
.maps-link img { width: 16px; height: 20px; }
/* وسائل الدفع في أسفل الصفحة */
.foot-pay { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-start; gap: 8px; margin: 8px 0 4px; }
.foot-pay .foot-pay-t { width: 100%; text-align: start; color: inherit; opacity: .8; font-size: var(--t-meta); }
.foot-pay .pay-logo { margin: 0; }
.paid-via { display: flex !important; align-items: center; gap: 8px; margin-top: 4px; }
.paid-via .pay-logo { width: 64px; height: 28px; }
/* ضغط واضح على روابط شاشة الرمز */
.otp-change:active, .resend-btn:active, .maps-link:active { opacity: .7; }
/* ── قواعد التصميم (ui-ux-pro-max): لمس 44px، فراغ 8px بين الأزرار، شبكة مسافات 4px، أصغر خط 13px ── */
/* المسافات في الملف كله صارت من مضاعفات 4 (4، 8، 12، 16، 20، 24…) بدل 6 و10 و14 و18 و22 */
/* اللمس: لا تأخير 300ms، والمؤشر يد فوق كل ما يُضغط */
a, button, summary, label, [role="button"], [role="tab"] { touch-action: manipulation; }
summary, label.check, label.pay { cursor: pointer; }
/* أصغر خط في الموقع 13px: «small» الافتراضي في المتصفح يصغّر إلى 11.7px */
small { font-size: max(var(--t-meta), .85em); }
/* الشريط العلوي: الشعار رابط بمساحة لمس 44px، و8px بين زر الحساب وزر اللغة */
.top .brand, .foot .brand { min-height: 44px; min-width: 44px; }
.top nav { gap: 8px; }
/* البحث في الرئيسية: 8px بين «الخدمة» و«الموعد» */
.search { gap: 8px; }
/* الروابط النصية والأسطر القابلة للضغط: 44px على الأقل */
.link { display: inline-flex; align-items: center; min-height: 44px; padding-block: 0; }
.check { min-height: 44px; }
.check input { width: 22px; height: 22px; flex: none; }
details > summary { min-height: 44px; padding-block: 10px; }
details.oils summary { min-height: 44px; }
/* التذييل: البريد والهاتف والروابط بارتفاع 44px */
.foot-legal a, .foot-links a { display: inline-flex; align-items: center; min-height: 44px; padding-block: 0; }
/* الشرائح (التصفية): 44px ارتفاعًا، و8px بينها */
.chip { min-height: 44px; display: inline-flex; align-items: center; }
/* ضغط الأزرار: إحساس فوري، ولا حركة لمن طلب تقليل الحركة */
.chip:active, .option:active, .day:active, .time:active { transform: scale(.98); }
.chip, .option, .day, .time { transition: border-color .15s, background-color .15s, transform .12s; }
@media (prefers-reduced-motion: reduce) {
  .btn:active, .gt:active, .chip:active, .option:active, .day:active, .time:active { transform: none; }
}
/* «بياناتي»: 16px بين بطاقة البريد وخانة الاسم */
.account-page .tabpanel > dl.review { margin-bottom: 16px; }

.flow .checkout-review { padding: 0; border: 0; background: transparent; box-shadow: none; }
.checkout-edits, .checkout-total { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; }
.checkout-edits button { min-height: 44px; }
.checkout-total { margin: 0; }

.checkout-actions { position: static; max-width: 640px; margin-inline: auto; padding: 16px 0; box-shadow: none; backdrop-filter: none; background: transparent; }
body:has(.checkout-review) .foot-pay { display: none; }
html[lang="ar"] .foot-legal [lang="en"], html[lang="en"] .foot-legal [lang="ar"] { display: none; }

.rv-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.rv-visit { display: grid; grid-template-columns: auto minmax(0,1fr) auto; align-items: center; gap: 16px; padding: 16px; border-radius: 18px; background: #292721; color: white; }
.rv-calendar { align-self: center; min-width: 66px; text-align: center; border-radius: 10px; overflow: hidden; background: #fffaf0; color: #292721; }
.rv-calendar span { display: block; background: var(--gold); padding: 4px 8px; font-size: var(--t-meta); font-weight: 600; }
.rv-calendar strong { display: block; font: 700 2.1rem/1.3 Sora, sans-serif; }
.rv-schedule, .rv-info { display: grid; gap: 3px; min-width: 0; overflow-wrap: anywhere; }
.rv-kicker { color: #eadbb8; font-size: var(--t-meta); }
.rv-schedule > strong { font-size: 1.25rem; }
.rv-schedule time, .rv-schedule small { display: flex; align-items: center; gap: 6px; }
.rv-schedule .ico { width: 16px; height: 16px; }
.rv-head, .rv-total { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.flow .rv-head h3 { font-size: 1rem; margin: 0; }
.rv-edit { background: transparent; color: #765006; border: 0; min-height: 44px; min-width: 44px; padding: 4px; cursor: pointer; text-decoration: underline; text-underline-offset: 4px; }
.rv-visit .rv-edit { color: #f6d27c; align-self: start; }
.rv-detail { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.rv-symbol { width: 38px; height: 38px; display: grid; place-items: center; background: #f7f4ed; border-radius: 12px; color: #72551b; }
.rv-info { flex: 1 1 90px; }
.rv-label { font-size: var(--t-meta); color: var(--muted); }
.rv-phone { width: fit-content; white-space: nowrap; color: #504b40; font-variant-numeric: tabular-nums; }
.rv-plate { max-width: 100%; }
.rv-total { flex-wrap: wrap; }
.rv-total small.block, .rv-total > small { width: 100%; }
.rv-layout .cart { margin-bottom: 0; }
.rv-plate .plate { margin: 0; font-size: .72rem; }

.rv-more { color: var(--ink); }
.rv-more summary { color: #765006; cursor: pointer; font-weight: 600; }
.rv-more .cline + .cline { margin-top: 6px; }
.ticket-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.ticket-head h2, .ticket-head p { margin: 0; }
.ticket-head h2 { font-size: clamp(1.1rem, 4vw, 1.45rem); }
.ticket-head p { font-size: .875rem; }
.ticket-head .t-check { flex: none; width: 40px; height: 40px; margin: 0; }
.ticket-head .t-check svg { width: 24px; height: 24px; }
.ticket-facts { display: grid; grid-template-columns: auto minmax(0,1fr); gap: 9px 16px; align-items: center; margin: 12px 0; }
.ticket-facts dt { color: var(--muted); font-size: .82rem; }
.ticket-facts dd { margin: 0; min-width: 0; overflow-wrap: anywhere; font-weight: 600; }
.ticket-ref { font-family: Sora, sans-serif; letter-spacing: .06em; }
.ticket-facts .maps-link { margin-inline-start: 8px; }
.ticket-facts .plate { font-size: .72rem; }
.ticket-total { border-top: 1px solid var(--line); padding-top: 10px; }
.ticket-total dd { display: flex; flex-wrap: wrap; align-items: center; gap: 5px 8px; }
.ticket .actions:empty { display: none; }
@media (max-width: 600px) {
  main > section.flow:has(.rv-layout), main > section.ticket { margin-top: 12px; }
  .flow:has(.rv-layout) > h2 { margin-block: 8px; }
  .rv-layout { gap: 8px; }
  .rv-visit { padding: 10px 12px; }
  .rv-detail { padding-block: 6px; }
  .rv-layout .cart { gap: 4px; }
  .rv-layout .rv-info { flex-basis: 160px; }
  .rv-layout .rv-plate { margin-inline-start: 48px; }
  .ticket .rv-visit { grid-template-columns: auto minmax(0,1fr); }
  .ticket .link[href="#/account/bookings"] { display: inline-flex; align-items: center; min-height: 44px; }
}

@media (min-width: 740px) and (max-height: 800px) {
  .rv-layout { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 20px; }
  .rv-layout > .rv-visit, .rv-layout > .rv-total { grid-column: 1 / -1; }
}
.rv-layout .cart { grid-template-columns: minmax(0, 1fr); }
.rv-layout .cline { grid-template-columns: 44px minmax(0, 1fr) auto; }
.rv-layout .rv-info { max-width: 100%; }
.rv-layout .rv-phone { max-width: 100%; white-space: normal; }

.pay-tamara .pay-text { gap: 6px; justify-items: start; }
.pay-tamara .tamara-checkout-logo { display: block; width: 112px; height: auto; }
.pay-google { text-align: start; font: inherit; color: inherit; }
.pay-google .pay-google-action { display: flex; align-items: flex-start; gap: 6px; font-size: .9rem; line-height: 1.55; font-weight: 600; color: var(--gold-text); }
.pay-google-action .brand-logo { width: 1.2em; height: 1.2em; margin-block-start: .175em; flex: none; }
.pay-google-action > span { display: block; text-decoration: underline; text-underline-offset: 3px; }
.pay-tamara.off { opacity: 1; background: #f6f6f6; border-color: #dadada; border-style: dashed; }
.pay-tamara.off .tamara-checkout-logo { filter: grayscale(1); }
.pay-tamara .pay-status { font-size: .83rem; color: var(--muted); }

.link > .brand-logo.whatsapp, #account-menu .brand-logo { width: 21px; height: 21px; flex: none; margin-inline-end: 6px; }
#account-menu { box-sizing: border-box; inset: 70px 0 auto; margin-block: 0; margin-inline: auto max(16px, calc((100vw - 1080px) / 2)); width: min(320px, 100%); max-height: 85dvh; padding: 0; color: var(--engine); background: var(--surface); border: 1px solid var(--line); border-radius: 16px; }
#account-menu::backdrop { background: rgb(0 0 0 / 30%); }
.account-menu-body { padding: 12px 20px; }
.account-menu-head { display: flex; justify-content: space-between; align-items: start; gap: 12px; border-bottom: 1px solid var(--line); padding-bottom: 8px; }
.account-identity { display: grid; gap: 4px; align-self: center; overflow-wrap: anywhere; }
.account-identity bdi { justify-self: start; color: var(--muted); }
#account-menu a, .account-signout { display: flex; align-items: center; min-height: 44px; color: inherit; text-decoration: none; }
.account-signout { font: inherit; color: var(--danger, #9c251f); padding: 0; border: 0; background: transparent; cursor: pointer; }
@media (max-width: 600px) {
  #account-menu { inset: auto 0 0; margin: 0; width: 100%; max-width: 100%; border-radius: 18px 18px 0 0; padding-bottom: env(safe-area-inset-bottom); }
}

.top .site-nav { display:flex; align-items:center; gap:4px; }
.site-nav [data-dest] { font:inherit; font-weight:650; color:var(--engine); text-decoration:none; background:transparent; border:0; border-radius:12px; cursor:pointer; padding:10px 16px; min-height:44px; display:grid; place-items:center; }
.site-nav [aria-current="page"] { background:#f7eed8; color:#705018; }
.booking-hero { max-width:1080px; margin:20px auto; padding:clamp(24px,5vw,65px); display:flex; justify-content:space-between; align-items:center; gap:16px; background:#242520; border-inline-start:6px solid #d7aa47; border-radius:20px; color:#fff; }
.booking-hero h1 { color:inherit; margin:0; font-size:clamp(1.8rem,5vw,3.6rem); line-height:1.2; }
.booking-hero p { color:#eee6d5; max-width:36ch; }
.booking-hero img { width:clamp(76px,19vw,210px); height:clamp(120px,23vw,260px); object-fit:contain; }
.catalog-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(220px,100%),1fr)); gap:12px; }
.catalog-card { display:grid; align-content:start; justify-items:start; gap:8px; padding:18px; color:var(--engine); text-decoration:none; border:1px solid var(--line); border-radius:16px; background: var(--surface); }
.catalog-card:hover,.catalog-card:focus-visible { border-color:#a87a1c; }
.catalog-detail { display:grid; justify-items:start; gap:16px; }
.catalog-detail :is(h1,p) { margin:0; }
.top .site-nav [data-dest] { display:flex; align-items:center; justify-content:center; gap:6px; }
.top .site-nav .ico { width:19px; height:19px; }
@media(max-width:740px) {
  :root { --site-nav-height:var(--measured-nav-height,calc(60px + env(safe-area-inset-bottom,0px))); }
  body { padding-bottom:var(--site-nav-height); }
  body:has(.mbar:not(.checkout-actions)) { padding-bottom:calc(var(--site-nav-height) + var(--mbar-h,68px)); }
  .mbar:not(.checkout-actions), .flow > .actions { bottom:var(--site-nav-height); }
  .top-in > .lang { margin-inline-start:auto; }
  .top .site-nav { position:fixed; inset:auto 0 0; min-height:calc(60px + env(safe-area-inset-bottom,0px)); container:booking-nav / inline-size; padding:4px 8px calc(4px + env(safe-area-inset-bottom,0px)); display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); background: var(--surface); border-top:1px solid var(--line); margin:0; }
  .top .site-nav [data-dest], .top .site-nav #nav-bookings { display:flex; flex-direction:column; gap:2px; font-size:var(--t-meta); padding:4px 2px; }
  body.on-home .top .brand span { position:static; width:auto; height:auto; clip-path:none; }
  .booking-hero { margin:14px 12px; padding:22px 16px; }
}

@container booking-nav (max-width:18.5rem) {
  .top .site-nav [data-dest], .top .site-nav #nav-bookings { grid-column:span 2; flex-direction:row; gap:6px; }
}
.directory .sh { flex-wrap:wrap; }

/* Order overview and the pickers that return to it after selection. */
.picker-back, .order-add-filter { display:inline-flex; align-items:center; gap:8px; min-height:44px; padding:4px 8px; margin-bottom:12px; background: var(--surface); border:1px solid var(--line); border-radius:8px; color:var(--engine); font:inherit; cursor:pointer; }
.picker-back .ico { width:18px; height:18px; }
html[dir="rtl"] .picker-back .ico { transform:rotate(180deg); }
.order-lines { gap:0; border-block:1px solid var(--line); }
.order-lines .cline { grid-template-columns:34px minmax(0,1fr) auto; gap:2px 10px; align-items:start; box-shadow:none; background:transparent; border:0; border-radius:0; padding:12px 0; }
.order-lines .cline + .cline { border-top:1px solid var(--line); }
.order-lines .cline > img, .order-lines .cline > .svc-ic { width:34px; height:34px; }
.order-lines .cn b, .order-lines .cp2 { font-size:1rem; }
.order-lines .cn small { color:#514b41; font-size:.875rem; }
.order-lines .cn .edit-hint { color:#704d10; }
.order-lines .crm { display:inline-flex; gap:4px; align-items:center; justify-content:center; background:transparent; font:inherit; font-size:.875rem; width:auto; min-width:44px; border:0; padding-inline:4px; }
.order-add-filter { justify-self:start; margin:0 0 8px; }
.order-options { grid-template-columns:repeat(auto-fit, minmax(min(100%, 8rem), 1fr)); }
.order-options .gt { min-height:8.75rem; }
.order-options .gi { width:56px; height:56px; }
.order-options .gi .ico { width:28px; height:28px; }
.order-options .gt .gi:has(img) { background: var(--photo-bg); }
.order-options .gi img { display:block; width:52px; height:52px; object-fit:contain; }
.order-options .gt b { font-size:1.0625rem; }
.order-options .gt small { font-size:.9375rem; line-height:1.5; }
@media (min-width:560px) { .order-options { grid-template-columns:repeat(3, minmax(0, 1fr)); } }
.order-total { cursor:default; }
@media (max-width:559px) { .order-options.gtiles > .gt:last-child:nth-child(odd) { min-height:5.5rem; align-content:center; } }
@media (max-width:740px) {
  html:has(.order-total) { scroll-padding-bottom:calc(var(--mbar-h,68px) + var(--site-nav-height) + 12px); }
  html:has(.picker-back) { scroll-padding-bottom:calc(var(--site-nav-height) + 12px); }
}

.directory .sh { align-items:center; }
.directory .sh h1 { margin-block:0; }
.directory .srch { margin-block:12px 20px; }
.directory .srch:focus-within { outline:2px solid var(--engine); outline-offset:2px; }
.directory .srch input { min-width:0; }
.directory-results { display:grid; }
.directory-row { display:flex; align-items:center; gap:12px; min-height:52px; padding:10px 4px; border-bottom:1px solid var(--line); text-decoration:none; color:var(--engine); }
.directory-row:hover { background:var(--ivory); }
.directory-row strong { flex:1; min-width:0; overflow-wrap:anywhere; }
.directory-row .svc-ic { flex:none; }
.directory-meta { color:#514b41; font-size:.9rem; max-width:40%; text-align:end; }
.catalog-back { display:inline-flex; align-items:center; justify-content:center; min-height:44px; min-width:44px; }

body:not(.on-home) > .foot { display:none; }
.company-links { max-width:640px; margin:16px auto 0; display:flex; align-items:baseline; flex-wrap:wrap; gap:0 16px; border-top:1px solid var(--line); color:var(--engine); font-size:.9rem; }
.company-links > a, .company-links summary, .product-group summary { padding-block:10px; min-height:44px; cursor:pointer; }
.company-links > a { color:inherit; text-underline-offset:3px; min-width:44px; text-align:center; }
.company-links details[open] { width:100%; }
.company-links .foot-legal { padding-block:8px; }
.product-group { border-bottom:1px solid var(--line); }
.product-group summary { font-weight:700; color:var(--engine); }
.product-group summary small { margin-inline-start:10px; color:#514b41; }
.product-group[open] > :last-child { margin-block:8px 16px; }

.catalog-identity { display:inline-flex; align-items:center; gap:8px; color:#514b41; }
.catalog-identity :is(img,.ico) { width:36px; height:36px; object-fit:contain; }
.pimg, .pcard .media { display:grid; place-items:center; }
.pimg > .ico, .pcard .media > .ico { width:52%; height:52%; color:var(--gold-text); }
.pcard .product-grade { justify-self:start; font-size:var(--t-small); }
.morelist { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,8rem),1fr)); gap:8px; align-items:start; }
.morelist > section, .morelist > .empty, .morelist > details[open] { grid-column:1 / -1; }
.morelist > details, .morelist > .gt { border:1px solid var(--line); border-radius:12px; background: var(--surface); }
.morelist summary, .morelist > .gt { min-height:60px; display:flex; align-items:center; gap:7px; padding:8px; text-align:start; font-weight:700; font-size:1rem; line-height:1.4; overflow-wrap:anywhere; }
.morelist summary { list-style:none; }
.morelist summary::-webkit-details-marker { display:none; }
.morelist summary::after { content:''; flex:none; width:6px; height:6px; margin-inline-start:auto; border:solid var(--muted); border-width:0 1.5px 1.5px 0; transform:rotate(45deg); }
.morelist details[open] > summary::after { transform:rotate(225deg); }
.morelist .gi { flex:none; width:28px; height:28px; border-radius:7px; display:grid; place-items:center; background:var(--gold-soft); color:var(--gold-text); }
.morelist .gi img { width:26px; height:26px; object-fit:contain; background: var(--surface); }
.morelist .gi .ico { width:20px; height:20px; }
.morelist .gt .gc { position:static; order:1; margin-inline-start:auto; }
.morelist .product-group[open] > :last-child { margin:0 8px 8px; }
.directory-row .svc-ic img { width:32px; height:32px; object-fit:contain; }

.morelist > details[open] {
  background:#faf6eb;
  border-color:#b59a61;
  box-shadow:0 3px 10px rgb(65 48 18 / 10%);
}
.morelist > details[open] > summary { color:#584014; border-bottom:1px solid #e1d5b9; }
.morelist > details[open] > :last-child {
  margin:10px; padding-inline-start:8px; border-inline-start:3px solid #bd913c;
}
.morelist > details[open] :is(.gitem,.pcard) { box-shadow:0 2px 4px rgb(65 48 18 / 10%); }

.time:disabled {
  background: #f3f4f4;
  border-color: #d4d7d7;
  color: #555b5b;
  box-shadow: none;
  cursor: default;
}
.time:disabled small { display: block; font-weight: normal; }

.plate-entry{display:grid;gap:.6rem;min-width:0}
.pe-fields{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:.5rem}
.plate-entry input{width:100%;min-width:0;box-sizing:border-box;text-align:center;font:inherit}
/* شكل اللوحة تحت الخانتين: أكبر من لوحة القوائم، وفي الوسط */
.plate.pe-board{width:min(100%,17rem);justify-self:center;margin-top:0}

.history-heading { display:flex; align-items:center; justify-content:space-between; gap:.5rem; flex-wrap:wrap; }
.history-heading h2 { margin:0; }
.history-heading .history-link { width:auto; min-height:36px; padding:.3rem .65rem; font-size:.8rem; line-height:1.4; margin-inline-start:auto; }

/* فحص 28 نوفمبر: زر «إغلاق» في قائمة الحساب بعرض 44 على الأقل */
.account-menu-head .link { min-width: 44px; min-height: 44px; }
