/* ============================================================
   main.css — الملف الموحّد لكل أنماط مكتب الناصع
   • styles.css : أنماط الموقع العام (عامة)
   • admin.css + fin.css : أنماط لوحة التحكم والمالية — مغلّفة تحت body.is-dash
     حتى لا تتسرّب إلى الموقع العام. أي إضافة جديدة تُكتب هنا.
   ============================================================ */

/* ====================== [1] الموقع العام (styles.css) ====================== */
/* ============================================================
   مكتب الناصع العقارية — نظام التصميم
   Navy + Gold + warm white · Tajawal · RTL
   ============================================================ */
:root {
  --navy: #16263f; --navy-800: #1e3450; --navy-700: #294462;
  --gold: #c5a25a; --gold-soft: #d8bd86; --gold-tint: #f3ebd8;
  --bg: #ffffff; --bg-warm: #faf8f4; --surface: #ffffff;
  --ink: #1a1c20; --muted: #6a7078; --muted-2: #9aa0a8;
  --line: #e7e3db; --line-soft: #f0ece4;
  --green: #2f7d5b; --green-tint: #e6f1ea; --danger: #b4452f;
  --radius: 16px; --radius-sm: 10px; --radius-lg: 24px;
  --shadow-sm: 0 1px 3px rgba(22,38,63,.07);
  --shadow: 0 4px 16px rgba(22,38,63,.08), 0 1px 4px rgba(22,38,63,.05);
  --shadow-lg: 0 18px 50px rgba(22,38,63,.16), 0 6px 18px rgba(22,38,63,.08);
  --font: "Tajawal", system-ui, sans-serif; --maxw: 1200px;
}
html[data-theme="dark"] {
  --navy: #e8edf5; --navy-800: #d4ddeb; --navy-700: #c2cee0;
  --gold: #d4b46a; --gold-soft: #e0c587; --gold-tint: #2a2d35;
  --bg: #14171c; --bg-warm: #181b21; --surface: #1e222a;
  --ink: #e7eaf0; --muted: #9aa2af; --muted-2: #757d8a;
  --line: #2c313b; --line-soft: #232830;
  --green: #4cae82; --green-tint: #1d2a25; --danger: #d4654f;
  --shadow-sm: 0 1px 3px rgba(0,0,0,.3);
  --shadow: 0 4px 16px rgba(0,0,0,.35), 0 1px 4px rgba(0,0,0,.3);
  --shadow-lg: 0 18px 50px rgba(0,0,0,.5), 0 6px 18px rgba(0,0,0,.4);
}
html[data-theme="dark"] body { background: var(--bg-warm); color: var(--ink); }
html[data-theme="dark"] .ph { background: repeating-linear-gradient(135deg, #20242c 0 14px, #262b34 14px 28px); }
html[data-theme="dark"] .ph-label { color: #aeb6c4; background: rgba(0,0,0,.4); }
html[data-theme="dark"] .site-header { background: rgba(24,27,33,.86); }
html[data-theme="dark"] .hero-bg img { filter: brightness(1.1); }
/* الوضع الليلي: نص الشعار أسود فيختفي — نبدّل لنسخة بيضاء (الشعار + النص) */
html[data-theme="dark"] .logo-img { content: url("../img/logo-dark.webp"); }
html[data-theme="dark"] .btn-navy { background: var(--surface); color: var(--ink); border-color: var(--line); }
html[data-theme="dark"] .btn-navy:hover { background: #262b34; }
html[data-theme="dark"] .btn-gold { color: #1a1207; }
html[data-theme="dark"] .icon-toggle, html[data-theme="dark"] .lang-pill { background: var(--surface); color: var(--ink); }
html[data-theme="dark"] .search-card, html[data-theme="dark"] .prop-card, html[data-theme="dark"] .ss-pop,
html[data-theme="dark"] .cat-tile, html[data-theme="dark"] .svc-card, html[data-theme="dark"] .tst-card,
html[data-theme="dark"] .step-card, html[data-theme="dark"] .panel, html[data-theme="dark"] .form-card,
html[data-theme="dark"] .stepper, html[data-theme="dark"] .inp, html[data-theme="dark"] .flt-select,
html[data-theme="dark"] .drawer, html[data-theme="dark"] .ss-trigger { background: var(--surface); }
html[data-theme="dark"] .hero::after { background: linear-gradient(100deg, rgba(10,12,16,.94) 32%, rgba(10,12,16,.5)); }
html[data-theme="dark"] .badge-status { background: rgba(40,45,54,.95); color: var(--ink); }
html[data-theme="dark"] .site-header .nav-links a { color: var(--ink); }
html[data-theme="dark"] .site-header .nav-links a:hover { color: var(--gold-soft); background: var(--gold-tint); }
html[data-theme="dark"] .site-header .nav-links a.active { color: var(--gold-soft); }
html[data-theme="dark"] .prop-price b, html[data-theme="dark"] .prop-price span { color: var(--ink); }
html[data-theme="dark"] .section-head h2, html[data-theme="dark"] .detail-title h1,
html[data-theme="dark"] .detail-price, html[data-theme="dark"] .fact b, html[data-theme="dark"] .cat-tile b { color: var(--ink); }
html[data-theme="dark"] .hero { background: #0e1218; }
html[data-theme="dark"] .band { background: #11151c; }
html[data-theme="dark"] .band h2, html[data-theme="dark"] .band h3 { color: #fff; }
html[data-theme="dark"] .svc-card.feature { background: #11151c; }
html[data-theme="dark"] .search-field, html[data-theme="dark"] .flt-pill,
html[data-theme="dark"] .otp-box { background: var(--surface); }
html[data-theme="dark"] .ss-ico, html[data-theme="dark"] .search-field .sf-ico { background: #11151c; }
html[data-theme="dark"] .float-call { background: var(--surface); }
html[data-theme="dark"] .cat-ico, html[data-theme="dark"] .svc-ico { background: var(--gold-tint); color: var(--gold-soft); }
html[data-theme="dark"] .logo-mark { background: var(--surface); }
html.theme-switching * { transition: none !important; }
/* أزرار الحالة النشطة: في الوضع الليلي --navy فاتح، فنستخدم الذهبي بنص داكن */
html[data-theme="dark"] .search-tab.active,
html[data-theme="dark"] .view-toggle button.on,
html[data-theme="dark"] .flt-pill.on,
html[data-theme="dark"] .ss-chip.on,
html[data-theme="dark"] .blog-cats .chip.on,
html[data-theme="dark"] .step-item.active .step-dot {
  background: var(--gold); color: #1a1207; border-color: var(--gold);
}
html[data-theme="dark"] .search-tab { color: var(--muted); }
html[data-theme="dark"] .agent-av { background: var(--gold-tint); color: var(--gold-soft); }
html[data-theme="dark"] .map-box, html[data-theme="dark"] .gallery { border-color: var(--line); }
html[data-theme="dark"] .legal-note { background: #2a2517; border-color: #4a3f1f; color: #d9c79a; }
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--bg-warm); color: var(--ink);
  font-family: var(--font); font-weight: 400; line-height: 1.6;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
body { direction: rtl; overflow-x: clip; }
html[dir="ltr"] body { direction: ltr; }
h1,h2,h3,h4 { margin: 0; line-height: 1.2; letter-spacing: -.01em; }
p { margin: 0; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
img { display: block; max-width: 100%; }
ul { margin: 0; padding: 0; list-style: none; }
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid transparent; border-radius: 999px; padding: 12px 22px; font-size: 15px;
  font-weight: 700; transition: transform .15s, box-shadow .2s, color .2s, border-color .2s; white-space: nowrap; }
.btn:active { transform: translateY(1px); }
.btn-gold { background: var(--gold); color: #2a2008; box-shadow: 0 6px 18px rgba(197,162,90,.35); }
.btn-gold:hover { background: var(--gold-soft); }
.btn-navy { background: var(--navy); color: #fff; }
.btn-navy:hover { background: var(--navy-700); }
.btn-ghost { background: transparent; color: var(--navy); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--navy); background: var(--surface); }
/* ghost button on dark backgrounds (bands/hero) — keep text visible on hover */
.btn-ghost-ondark { background: transparent; color: #fff; border-color: rgba(255,255,255,.3); }
.btn-ghost-ondark:hover { background: rgba(255,255,255,.14); border-color: rgba(255,255,255,.6); color: #fff; }
.btn-wa { background: #25d366; color: #04331a; box-shadow: 0 6px 18px rgba(37,211,102,.3); }
.btn-wa:hover { background: #20bd5b; }
.btn-lg { padding: 15px 30px; font-size: 16px; }
.btn-sm { padding: 9px 16px; font-size: 13.5px; }
.btn-block { width: 100%; }

/* header */
.site-header { position: sticky; top: 0; z-index: 60; background: rgba(255,255,255,.88);
  backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.header-row { display: flex; align-items: center; gap: 26px; height: 72px; }
.logo { display: flex; align-items: center; gap: 11px; cursor: pointer; flex-shrink: 0; }
.logo-mark { width: 42px; height: 42px; border-radius: 12px; background: var(--navy); color: var(--gold);
  display: grid; place-items: center; font-weight: 800; font-size: 20px; position: relative; overflow: hidden; }
.logo-mark::after { content:""; position:absolute; inset:0; background: linear-gradient(135deg, transparent 55%, rgba(197,162,90,.28)); }
.logo-text { display: flex; flex-direction: column; line-height: 1.15; }
.logo-text b { font-size: 17px; font-weight: 800; color: var(--navy); }
.logo-text span { font-size: 10.5px; color: var(--muted); font-weight: 500; letter-spacing: .05em; }
.logo-img { height: 48px; width: auto; display: block; }
.nav-links { display: flex; align-items: center; gap: 2px; margin-inline-start: 6px; }
.nav-links a { padding: 8px 13px; border-radius: 9px; font-size: 14.5px; font-weight: 500; color: var(--ink); transition: none; white-space: nowrap; cursor: pointer; }
.nav-links a:hover { background: var(--bg-warm); color: var(--navy); }
.lang-pill { display: inline-flex; align-items: center; gap: 7px; padding: 8px 15px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--navy); font-size: 13.5px; font-weight: 700; transition: all .15s; }
.lang-pill:hover { border-color: var(--navy); background: var(--bg-warm); }
.lang-pill svg { color: var(--gold); }
.icon-toggle { width: 42px; height: 42px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--navy); display: grid; place-items: center; transition: all .15s; flex-shrink: 0; }
.icon-toggle:hover { border-color: var(--navy); background: var(--bg-warm); }
.nav-links a.active { color: var(--navy); font-weight: 700; }
.header-actions { margin-inline-start: auto; display: flex; align-items: center; gap: 10px; }
.burger { display: none; width: 44px; height: 44px; border-radius: 11px; border: 1px solid var(--line); background:var(--surface); align-items:center; justify-content:center; color: var(--navy); }

/* drawer */
.drawer-backdrop { position: fixed; inset: 0; background: rgba(22,38,63,.45); z-index: 90; animation: fade .2s; }
.drawer { position: fixed; top: 0; inset-inline-start: 0; height: 100%; width: 84%; max-width: 340px; background: var(--surface);
  z-index: 91; padding: 20px; display: flex; flex-direction: column; gap: 4px; box-shadow: var(--shadow-lg); animation: slideIn .25s; overflow-y: auto; }
@keyframes slideIn { from { transform: translateX(-100%); } to { transform: translateX(0); } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.drawer-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.drawer-close { width: 40px; height: 40px; border-radius: 11px; border: 1px solid var(--line); background: var(--surface); display: grid; place-items: center; color: var(--navy); flex-shrink: 0; }
.drawer a { padding: 13px 14px; border-radius: 11px; font-size: 16px; font-weight: 600; color: var(--ink); cursor: pointer; }
.drawer a:hover, .drawer a.active { background: var(--bg-warm); color: var(--navy); }
.drawer-controls { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.drawer-controls .btn { width: 100%; justify-content: flex-start; gap: 10px; padding: 13px 16px; }
.drawer-controls .btn svg { color: var(--gold); }

/* ===== account chip + dropdown menu (public header) ===== */
.acct-wrap { position: relative; }
.acct-chip { display: inline-flex; align-items: center; gap: 9px; padding: 5px 12px 5px 6px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface); color: var(--navy); cursor: pointer; transition: border-color .15s, box-shadow .15s; }
.acct-chip:hover, .acct-chip.open { border-color: var(--navy); box-shadow: var(--shadow-sm); }
.acct-chip-name { font-size: 14px; font-weight: 700; max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acct-chip-caret { color: var(--muted-2); transition: transform .18s; }
.acct-chip.open .acct-chip-caret { transform: rotate(180deg); }
.acct-av { display: inline-grid; place-items: center; border-radius: 50%; overflow: hidden; flex-shrink: 0; }
.acct-av-init { background: linear-gradient(135deg, var(--navy), var(--navy-700)); color: #fff; font-weight: 800; letter-spacing: .5px; }
.acct-menu { position: absolute; inset-inline-end: 0; top: calc(100% + 10px); width: 268px; background: var(--surface);
  border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow-lg); z-index: 95; overflow: hidden; animation: acctPop .16s ease; transform-origin: top; }
@keyframes acctPop { from { opacity: 0; transform: translateY(-6px) scale(.98); } to { opacity: 1; transform: none; } }
.acct-menu-head { display: flex; align-items: center; gap: 12px; padding: 16px; background: var(--bg-warm); border-bottom: 1px solid var(--line); }
.acct-menu-id { min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.acct-menu-id b { font-size: 15px; color: var(--navy); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.acct-menu-role { font-size: 12px; color: var(--gold-700, #a9883f); font-weight: 700; }
.acct-menu-phone { font-size: 12px; color: var(--muted); }
.acct-menu-list { padding: 6px; }
.acct-menu-item { width: 100%; display: flex; align-items: center; gap: 11px; padding: 11px 12px; border: none; background: none;
  border-radius: 10px; font-size: 14.5px; font-weight: 600; color: var(--ink); cursor: pointer; text-align: start; font-family: inherit; }
.acct-menu-item svg { color: var(--muted-2); flex-shrink: 0; }
.acct-menu-item:hover { background: var(--bg-warm); color: var(--navy); }
.acct-menu-item:hover svg { color: var(--gold); }
.acct-menu-logout { margin: 0 6px 6px; width: calc(100% - 12px); border-top: 1px solid var(--line); border-radius: 0 0 10px 10px; color: #c0492f; padding-top: 13px; padding-bottom: 13px; }
.acct-menu-logout svg { color: #c0492f; }
.acct-menu-logout:hover { background: #fbecea; color: #a83a22; }
.acct-menu-logout:hover svg { color: #a83a22; }
/* mobile drawer account block */
.drawer-acct { margin-top: 10px; padding-top: 12px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 2px; }
.drawer-acct-head { display: flex; align-items: center; gap: 12px; padding: 6px 4px 12px; }
.drawer-acct-head b { display: block; font-size: 16px; color: var(--navy); }
.drawer-acct-head span { font-size: 13px; color: var(--gold-700, #a9883f); font-weight: 600; }

/* ===== profile modal ===== */
.profile-modal { position: fixed; top: 50%; inset-inline-start: 50%; transform: translate(-50%, -50%); width: 92%; max-width: 440px;
  max-height: 90vh; overflow-y: auto; background: var(--surface); border-radius: 20px; box-shadow: var(--shadow-lg); z-index: 95;
  padding: 22px 24px 24px; animation: acctPop .18s ease; }
html[dir="rtl"] .profile-modal { transform: translate(50%, -50%); }
.profile-modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.profile-modal-head h2 { font-size: 21px; color: var(--navy); }
.profile-avatar-row { display: flex; align-items: center; gap: 16px; padding: 16px; background: var(--bg-warm); border-radius: 14px; margin-bottom: 18px; }
.profile-hint { font-size: 12px; color: var(--muted); margin-top: 8px; }
.profile-field { margin-bottom: 14px; }
.profile-field > label { display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; color: var(--navy); margin-bottom: 6px; }
.profile-field > label svg { color: var(--gold); }
.profile-pass { position: relative; display: flex; align-items: center; }
.profile-pass .inp { flex: 1; padding-inline-start: 44px; }
.profile-pass .pass-toggle { position: absolute; inset-inline-start: 8px; width: 32px; height: 32px; border: none; background: none; color: var(--muted-2); display: grid; place-items: center; cursor: pointer; }
.profile-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 22px; }
.profile-actions .btn.is-saved { background: var(--green); color: #fff; }

/* ===== Nafath verification widget ===== */
.nafath-card { border: 1px solid var(--line); border-radius: 16px; padding: 20px; background: var(--bg-warm); text-align: center; }
.nafath-brand { display: flex; flex-direction: column; align-items: center; gap: 6px; margin-bottom: 16px; }
.nafath-logo { font-size: 22px; font-weight: 900; color: #0a8f80; letter-spacing: 1px; padding: 6px 18px; border-radius: 10px; background: #e6f5f2; border: 1px solid #bfe6df; }
.nafath-brand-sub { font-size: 12.5px; color: var(--muted); }
.nafath-card .field { text-align: start; }
.nafath-instruct { font-size: 15px; color: var(--navy); font-weight: 600; margin-bottom: 12px; }
.nafath-match { font-size: 56px; font-weight: 900; color: #0a8f80; letter-spacing: 4px; line-height: 1; margin: 8px 0 10px; }
.nafath-timer { font-size: 13px; color: var(--muted); margin-bottom: 16px; }
.nafath-cancel { display: block; margin: 12px auto 0; background: none; border: none; color: var(--navy); font-size: 13px; font-weight: 700; cursor: pointer; font-family: inherit; }
.nafath-hint { font-size: 12px; color: var(--muted); margin-top: 12px; display: flex; align-items: center; gap: 6px; justify-content: center; }
.nafath-err { display: flex; align-items: center; gap: 7px; color: #c0492f; font-size: 13.5px; font-weight: 600; margin-bottom: 12px; }
.nafath-ok { display: flex; align-items: center; gap: 14px; text-align: start; background: #ecf7f0; border-color: #bfe3cc; }
.nafath-ok-ico { width: 46px; height: 46px; border-radius: 12px; background: #d6efdf; color: var(--green); display: grid; place-items: center; flex-shrink: 0; }
.nafath-ok-name { font-size: 16px; font-weight: 800; color: var(--navy); }
.nafath-ok-sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.verified-badge { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 800; color: var(--green); background: #d6efdf; border: 1px solid #bfe3cc; padding: 5px 11px; border-radius: 999px; white-space: nowrap; }

/* حقل مقفول (قيمة موثّقة لا تُعدّل — مثل الاسم من نفاذ) */
.locked-inp { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 46px; padding: 0 14px; border: 1px solid #bfe3cc; background: #f3faf5; border-radius: 12px; }
.locked-inp-val { font-weight: 700; color: var(--navy); }
.locked-inp-badge { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 800; color: var(--green); white-space: nowrap; }

/* ===== broker mode banner (وضع الوسيط في إضافة عقار) ===== */
.broker-banner { display: flex; align-items: center; gap: 14px; background: linear-gradient(180deg, #f3f6fb, #eef2f9); border: 1px solid #d4ddec; border-radius: var(--radius); padding: 16px 18px; margin-bottom: 20px; }
.broker-banner.blocked { background: linear-gradient(180deg, #fdf3ef, #faece6); border-color: #efcdbf; }
.broker-banner-ic { width: 44px; height: 44px; flex-shrink: 0; border-radius: 12px; background: rgba(20,42,82,.1); color: var(--navy); display: grid; place-items: center; }
.broker-banner.blocked .broker-banner-ic { background: rgba(176,69,47,.12); color: #b0452f; }
.broker-banner-txt { flex: 1; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.broker-banner-txt b { font-size: 15px; color: var(--navy); }
.broker-banner-txt span { font-size: 13px; color: var(--muted); }

/* ===== ad-license verify widget (تحقّق ترخيص الإعلان) ===== */
.adlic { display: flex; flex-direction: column; gap: 10px; }
.adlic-row { display: flex; gap: 10px; }
.adlic-row .inp { flex: 1; }
.adlic-row .btn { flex-shrink: 0; }
.adlic-res { border-radius: 12px; padding: 14px 16px; font-size: 13.5px; }
.adlic-res.ok { background: #ecf7f0; border: 1px solid #bfe3cc; }
.adlic-res.bad { display: flex; align-items: center; gap: 8px; background: #fdf0ec; border: 1px solid #f0cbbd; color: #b0452f; font-weight: 600; }
.adlic-res-top { display: flex; align-items: center; gap: 8px; font-weight: 800; color: var(--green); margin-bottom: 10px; }
.adlic-res-grid { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; }
.adlic-res-grid span { color: var(--muted); }
.adlic-res-grid b { color: var(--navy); font-weight: 700; }
.adlic-hint { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.adlic-hint svg { flex-shrink: 0; color: var(--gold); }

/* ===== join plans ===== */
.join-cycle { display: flex; gap: 8px; margin-bottom: 16px; }
.join-plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.join-plan { text-align: start; border: 1.5px solid var(--line); border-radius: 14px; padding: 16px; background: var(--surface); cursor: pointer; transition: border-color .15s, box-shadow .15s; font-family: inherit; }
.join-plan:hover { border-color: var(--gold); }
.join-plan.on { border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-tint); }
.join-plan-name { font-size: 15px; font-weight: 800; color: var(--navy); }
.join-plan-price { font-size: 20px; font-weight: 900; color: var(--navy); margin: 6px 0; }
.join-plan-price span { font-size: 12px; font-weight: 600; color: var(--muted); }
.join-plan-feat { font-size: 12.5px; color: var(--muted); }
@media (max-width: 640px) { .join-plans { grid-template-columns: 1fr; } }

/* ملاحظة الحساب أعلى صفحة الانضمام */
.join-acct-note { display: inline-flex; align-items: center; gap: 8px; margin-top: 16px; padding: 9px 14px; background: var(--gold-tint); border: 1px solid var(--gold-200, #e6d6ad); border-radius: 12px; font-size: 13.5px; color: var(--navy); }
.join-acct-note b { font-weight: 800; }

/* خياري التفعيل: تجربة مجانية / اشتراك مدفوع */
.join-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 20px; }
.join-action { display: flex; flex-direction: column; gap: 6px; text-align: start; border: 1.5px solid var(--line); border-radius: 16px; padding: 18px 20px; background: var(--surface); cursor: pointer; font-family: inherit; transition: border-color .15s, box-shadow .15s, transform .15s, background .15s; }
.join-action:hover:not(:disabled) { transform: translateY(-2px); }
.join-action:disabled { opacity: .45; cursor: not-allowed; }
.join-action-top { display: flex; align-items: center; gap: 9px; font-size: 16px; font-weight: 800; color: var(--navy); }
.join-action-sub { font-size: 12.5px; color: var(--muted); padding-inline-start: 27px; }
.join-action.trial:hover:not(:disabled) { border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-tint); }
.join-action.pay { background: var(--navy); border-color: var(--navy); }
.join-action.pay .join-action-top { color: #fff; }
.join-action.pay .join-action-sub { color: rgba(255,255,255,.72); }
.join-action.pay:hover:not(:disabled) { box-shadow: 0 14px 34px rgba(20,33,61,.28); }
@media (max-width: 640px) { .join-actions { grid-template-columns: 1fr; } }

/* ===== public self-serve payment (شاشة الدفع) ===== */
.ppay-overlay { position: fixed; inset: 0; z-index: 1200; display: grid; place-items: center; padding: 20px; }
.ppay-backdrop { position: absolute; inset: 0; background: rgba(12,18,30,.55); backdrop-filter: blur(2px); }
.ppay-modal { position: relative; width: 100%; max-width: 440px; max-height: calc(100vh - 40px); overflow-y: auto; background: var(--surface); border-radius: 20px; padding: 26px; box-shadow: 0 30px 80px rgba(0,0,0,.4); }
.ppay-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.ppay-head h2 { font-size: 20px; color: var(--navy); }
.ppay-sub { font-size: 13px; color: var(--muted); margin-top: 3px; }
.ppay-close { background: none; border: none; color: var(--muted); cursor: pointer; padding: 4px; border-radius: 8px; display: grid; place-items: center; }
.ppay-close:hover { background: var(--line); color: var(--navy); }
.ppay-amount { text-align: center; background: var(--gold-tint); border: 1px solid var(--gold-200, #e6d6ad); border-radius: 16px; padding: 18px; margin-bottom: 18px; }
.ppay-amount > span { font-size: 13px; color: var(--muted); }
.ppay-amount b { display: block; font-size: 30px; font-weight: 900; color: var(--navy); margin: 4px 0; }
.ppay-amount b small { font-size: 14px; font-weight: 600; color: var(--muted); }
.ppay-plan-tag { font-size: 12.5px; color: var(--navy); font-weight: 700; }
.ppay-methods { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
.ppay-method { display: flex; align-items: center; justify-content: center; gap: 8px; border: 1.5px solid var(--line); border-radius: 12px; padding: 12px; background: var(--surface); cursor: pointer; font-family: inherit; font-size: 13.5px; font-weight: 700; color: var(--navy); transition: border-color .15s, box-shadow .15s; }
.ppay-method.on { border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-tint); }
.ppay-card { display: flex; flex-direction: column; gap: 12px; }
.ppay-applepay { text-align: center; }
.ppay-applepay-btn { width: 100%; background: #000; color: #fff; border: none; border-radius: 12px; padding: 15px; font-size: 16px; font-weight: 700; cursor: pointer; font-family: inherit; }
.ppay-applepay-btn:disabled { opacity: .6; cursor: default; }
.ppay-hint { font-size: 12px; color: var(--muted); margin-top: 10px; display: flex; align-items: center; gap: 6px; justify-content: center; }
.ppay-secure { display: flex; align-items: center; gap: 7px; justify-content: center; font-size: 12px; color: var(--muted); margin-top: 16px; }
.ppay-receipt { text-align: center; }
.ppay-ok-ico { width: 76px; height: 76px; border-radius: 50%; background: #ecf7f0; color: var(--green); display: grid; place-items: center; margin: 0 auto 14px; }
.ppay-receipt h2 { font-size: 22px; color: var(--navy); }
.ppay-receipt-sub { font-size: 13.5px; color: var(--muted); margin: 6px 0 18px; }
.ppay-receipt-box { text-align: start; background: var(--bg, #f7f7f4); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; margin-bottom: 18px; display: flex; flex-direction: column; gap: 9px; }
.ppay-receipt-box > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: 13.5px; }
.ppay-receipt-box span { color: var(--muted); }
.ppay-receipt-box b { color: var(--navy); font-weight: 800; }

/* ===== public pricing page (#3) ===== */
.pricing-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; align-items: stretch; }
.pricing-card { position: relative; display: flex; flex-direction: column; gap: 14px; background: var(--surface); border: 1.5px solid var(--line); border-radius: 18px; padding: 28px 24px; transition: transform .18s, box-shadow .18s, border-color .18s; }
.pricing-card:hover { transform: translateY(-3px); box-shadow: 0 16px 40px rgba(20,33,61,.10); }
.pricing-card.featured { border-color: var(--gold); box-shadow: 0 18px 48px rgba(176,138,62,.18); }
.pricing-flag { position: absolute; top: -13px; inset-inline-start: 50%; transform: translateX(50%); background: var(--gold); color: #fff; font-size: 12px; font-weight: 800; padding: 5px 14px; border-radius: 999px; letter-spacing: .2px; box-shadow: 0 6px 16px rgba(176,138,62,.35); }
.pricing-name { font-size: 19px; font-weight: 800; color: var(--navy); }
.pricing-price { display: flex; align-items: baseline; gap: 8px; }
.pricing-price b { font-size: 36px; font-weight: 800; color: var(--ink); line-height: 1; }
.pricing-price span { font-size: 13px; font-weight: 600; color: var(--muted); }
.pricing-save { display: inline-flex; align-self: flex-start; font-size: 12px; font-weight: 700; color: #2f7d5b; background: #eef6f1; border: 1px solid #d6e8dd; border-radius: 999px; padding: 3px 10px; }
.pricing-feats { list-style: none; margin: 4px 0 6px; padding: 0; display: flex; flex-direction: column; gap: 11px; }
.pricing-feats li { display: flex; align-items: flex-start; gap: 9px; font-size: 14px; color: var(--ink); line-height: 1.5; }
.pricing-feats li svg { color: var(--gold-soft, #b08a3e); flex-shrink: 0; margin-top: 2px; }
.pricing-card .btn { margin-top: auto; }
@media (max-width: 880px) { .pricing-grid { grid-template-columns: 1fr; max-width: 420px; margin-inline: auto; } }


/* hero */
.hero { position: relative; overflow: hidden; background: var(--navy); color: #fff; }
.hero-bg { position: absolute; inset: 0; }
.hero-bg .ph { height: 100%; opacity: .35; }
.hero-bg img { height: 100%; opacity: .6; }
.hero::after { content:""; position:absolute; inset:0;
  background: linear-gradient(100deg, rgba(18,28,46,.96) 32%, rgba(18,28,46,.45)); }
.hero-inner { position: relative; z-index: 2; padding-block: 84px 118px; }
.hero h1 { font-size: clamp(33px, 5vw, 58px); font-weight: 800; max-width: 17ch; letter-spacing: -.02em; }
.hero h1 .gold { color: var(--gold-soft); }
.hero .lead { margin-top: 18px; font-size: clamp(16px,2vw,20px); color: #cfd6e0; max-width: 50ch; }
.hero-eyebrow { display:inline-flex; align-items:center; gap:8px; font-size:13px; font-weight:600; letter-spacing:.06em;
  color: var(--gold-soft); background: rgba(197,162,90,.12); border:1px solid rgba(197,162,90,.32);
  padding:7px 14px; border-radius:999px; margin-bottom:24px; }
.hero-stats { display: flex; gap: 44px; margin-top: 42px; flex-wrap: wrap; }
.hero-stat b { display: block; font-size: 30px; font-weight: 800; color: #fff; }
.hero-stat span { font-size: 13px; color: #aeb8c6; font-weight: 500; }

/* search card */
.search-card { position: relative; z-index: 3; margin: -62px auto 0; max-width: var(--maxw);
  background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); padding: 12px; border: 1px solid var(--line); }
.search-tabs { display: flex; gap: 6px; padding: 4px 6px 10px; }
.search-tab { padding: 9px 20px; border-radius: 999px; font-weight: 700; font-size: 14.5px; color: var(--muted); background: transparent; border: none; }
.search-tab.active { background: var(--navy); color: #fff; }
/* ---------- smart search ---------- */
.smart-search { display: flex; flex-wrap: wrap; gap: 10px; align-items: stretch; padding: 6px; }
.smart-search .ss-field { flex: 1 1 200px; min-width: 0; }
.ss-field { position: relative; }
.ss-trigger { display: flex; align-items: center; gap: 11px; padding: 0 14px; min-height: 62px; border-radius: var(--radius-sm); background: var(--bg-warm); border: 1px solid transparent; cursor: pointer; transition: border-color .15s; height: 100%; }
.ss-field.active .ss-trigger { border-color: var(--gold); background: var(--surface); box-shadow: 0 0 0 3px rgba(197,162,90,.14); }
.ss-field.disabled .ss-trigger { opacity: .55; cursor: not-allowed; }
.ss-ico { flex: 0 0 auto; width: 38px; height: 38px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); color: var(--gold); display: grid; place-items: center; }
.ss-body { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: center; gap: 2px; }
.ss-label { font-size: 11.5px; color: var(--muted); font-weight: 700; }
.ss-value { font-size: 15.5px; font-weight: 700; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ss-value.ss-hint { color: #aab2bf; font-weight: 500; }
.ss-count { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px; margin-inline-start: 6px; background: var(--gold); color: #2a2008; border-radius: 999px; font-size: 11px; font-weight: 800; vertical-align: middle; }
.ss-caret { color: var(--muted); flex: 0 0 auto; transition: transform .15s; }
.ss-field.active .ss-caret { transform: rotate(180deg); }
.ss-go { align-self: stretch; min-height: 62px; padding-inline: 32px; flex: 0 0 auto; }

.ss-pop { position: absolute; top: calc(100% + 8px); inset-inline-start: 0; inset-inline-end: 0; min-width: 280px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-lg); z-index: 40; padding: 8px; animation: ssIn .16s ease; }
@keyframes ssIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: translateY(0); } }
.ss-search { display: flex; align-items: center; gap: 9px; padding: 9px 12px; background: var(--bg-warm); border-radius: var(--radius-sm); margin-bottom: 6px; color: var(--muted); }
.ss-search input { border: none; background: none; outline: none; font-size: 14.5px; width: 100%; color: var(--ink); font-family: inherit; }
.ss-scroll { max-height: 280px; overflow-y: auto; }
.ss-group-title { font-size: 12px; font-weight: 800; color: var(--navy); padding: 10px 12px 6px; }
.ss-row { display: flex; align-items: center; gap: 9px; padding: 10px 12px; border-radius: 9px; font-size: 14.5px; color: var(--ink); cursor: pointer; transition: none; }
.ss-row svg { color: var(--muted); flex-shrink: 0; }
.ss-row:hover { background: var(--bg-warm); }
.ss-row.sel { background: var(--gold-tint); color: var(--navy); font-weight: 700; }
.ss-row.sel svg { color: var(--gold); }
.ss-kingdom { font-weight: 800; color: var(--navy); border-bottom: 1px solid var(--line-soft); margin-bottom: 4px; }
.ss-kingdom svg { color: var(--gold); }
.ss-empty { padding: 16px 12px; color: var(--muted); font-size: 14px; text-align: center; }
.ss-chips { display: flex; flex-wrap: wrap; gap: 8px; padding: 4px 8px 10px; }
.ss-chip { padding: 9px 15px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 13.5px; font-weight: 600; color: var(--ink); cursor: pointer; transition: all .14s; display: inline-flex; align-items: center; gap: 5px; }
.ss-chip:hover { border-color: var(--gold-soft); background: var(--bg-warm); }
.ss-chip.on { background: var(--navy); color: #fff; border-color: var(--navy); display: inline-flex; align-items: center; gap: 5px; }
.ss-pop-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 12px 6px; }
.ss-clear { border: none; background: none; color: var(--gold-700, #a9883f); font-size: 12.5px; font-weight: 800; cursor: pointer; }
.ss-clear:hover { text-decoration: underline; }
.ss-row.ss-check { gap: 11px; }
.ss-box { width: 19px; height: 19px; border-radius: 5px; border: 2px solid var(--line); display: grid; place-items: center; color: #fff; flex-shrink: 0; }
.ss-row.ss-check.sel .ss-box { background: var(--navy); border-color: var(--navy); }
.ss-row.ss-check.sel { background: transparent; color: var(--navy); font-weight: 700; }
.ss-done { width: calc(100% - 16px); margin: 8px 8px 4px; padding: 11px; border: none; background: var(--navy); color: #fff; border-radius: 9px; font-size: 14px; font-weight: 800; cursor: pointer; }
.ss-done:hover { background: var(--navy-700); }
.ss-more { display: flex; align-items: center; justify-content: center; gap: 6px; width: calc(100% - 16px); margin: 2px 8px 6px; padding: 10px; border: none; background: var(--gold-tint); color: var(--gold-700, #a9883f); border-radius: 9px; font-size: 13.5px; font-weight: 800; cursor: pointer; }
.ss-more:hover { background: #ecdcb6; }

@media (max-width: 860px) {
  .smart-search { grid-template-columns: 1fr 1fr; }
  .ss-go { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .smart-search { grid-template-columns: 1fr; }
  .ss-pop { min-width: 0; }
}

/* keep legacy search-grid for any other use */
.search-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr auto; gap: 10px; align-items: stretch; padding: 6px; }
.search-field { display: flex; flex-direction: row; align-items: center; gap: 11px; padding: 0 14px; min-height: 60px; border-radius: var(--radius-sm); background: var(--bg-warm); border: 1px solid transparent; transition: border-color .15s; cursor: pointer; }
.search-field:focus-within { border-color: var(--gold); background:var(--surface); }
.search-field .sf-ico { flex: 0 0 auto; width: 38px; height: 38px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); color: var(--gold); display: grid; place-items: center; }
.search-field .sf-body { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: center; gap: 2px; }
.search-field .sf-label { font-size: 11.5px; color: var(--muted); font-weight: 700; }
.search-field select, .search-field input { border: none; background: transparent; font-size: 15.5px; font-weight: 700; color: var(--ink); outline: none; padding: 0; margin: 0; width: 100%; appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns=&#039;http://www.w3.org/2000/svg&#039; width=&#039;13&#039; height=&#039;13&#039; viewBox=&#039;0 0 24 24&#039; fill=&#039;none&#039; stroke=&#039;%2316263f&#039; stroke-width=&#039;2.6&#039; stroke-linecap=&#039;round&#039;%3E%3Cpolyline points=&#039;6 9 12 15 18 9&#039;/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: left center; padding-inline-end: 18px; }
.search-go { align-self: stretch; min-height: 60px; padding-inline: 30px; }

/* sections */
.section { padding: 74px 0; }
.section-sm { padding: 52px 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 36px; }
.section-head .eyebrow { color: var(--gold); font-weight: 700; font-size: 14px; letter-spacing: .05em; margin-bottom: 8px; }
.section-head h2 { font-size: clamp(26px, 3.4vw, 38px); font-weight: 800; color: var(--navy); }
.section-head p { color: var(--muted); margin-top: 8px; max-width: 56ch; }
.link-more { color: var(--navy); font-weight: 700; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; cursor: pointer; }
.link-more:hover { color: var(--gold); }

/* placeholder */
.ph { position: relative; width: 100%; height: 100%; display: grid; place-items: center; overflow: hidden;
  background: repeating-linear-gradient(135deg, #eef1f5 0 14px, #e6eaf0 14px 28px); }
.ph.dark { background: repeating-linear-gradient(135deg, #20355200 0 0), repeating-linear-gradient(135deg, #1d3251 0 14px, #243a57 14px 28px); }
.ph-label { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 11.5px; color: #8b95a6;
  background: rgba(255,255,255,.72); padding: 4px 10px; border-radius: 6px; letter-spacing: .02em; }
.ph.dark .ph-label { color: #aeb9cc; background: rgba(22,38,63,.55); }

/* property card */
.cards-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.prop-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  transition: transform .2s, box-shadow .2s, border-color .2s; cursor: pointer; display:flex; flex-direction:column; }
.prop-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--gold-soft); }
.prop-media { position: relative; aspect-ratio: 4/3; overflow: hidden; }
.prop-badges { position: absolute; top: 12px; inset-inline-start: 12px; display: flex; gap: 7px; z-index: 2; }
.badge { font-size: 12px; font-weight: 700; padding: 5px 11px; border-radius: 999px; }
.badge-sale { background: rgba(197,162,90,.96); color: #2a2008; }
.badge-rent { background: rgba(47,125,91,.96); color: #fff; }
.badge-feat { background: rgba(22,38,63,.92); color: var(--gold-soft); }
.badge-status { background: rgba(255,255,255,.94); color: var(--navy); }
.prop-fav { position: absolute; top: 12px; inset-inline-end: 12px; width: 38px; height: 38px; border-radius: 999px;
  background: rgba(255,255,255,.92); border:none; display: grid; place-items: center; z-index: 2; transition: transform .15s; color: var(--ink); }
.prop-fav:hover { transform: scale(1.08); }
.prop-fav.on svg { fill: #e0445b; stroke: #e0445b; }
.prop-body { padding: 16px 17px 17px; display: flex; flex-direction: column; gap: 11px; flex:1; }
.prop-price { font-size: 22px; font-weight: 800; color: var(--navy); display: flex; align-items: baseline; gap: 6px; }
.prop-price .unit { font-size: 13px; font-weight: 600; color: var(--muted); }
.prop-price .poa { font-size: 18px; color: var(--gold); }
.prop-title { font-size: 16.5px; font-weight: 700; color: var(--ink); }
.prop-loc { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 13.5px; }
.prop-verified { display: inline-flex; align-items: center; gap: 5px; align-self: flex-start; font-size: 12px; font-weight: 700; color: #2f7d5b; background: #eef6f1; border: 1px solid #d6e8dd; border-radius: 999px; padding: 3px 9px; }
.prop-verified svg { color: #2f7d5b; }
.prop-unverified { color: #97702a; background: #faf3e3; border-color: #ecdcb6; }
.prop-unverified svg { color: #97702a; }
.prop-specs { display: flex; gap: 16px; padding-top: 12px; border-top: 1px solid var(--line-soft); margin-top: auto; }
.spec { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 13.5px; font-weight: 600; }
.spec svg { color: var(--gold); flex-shrink: 0; }
.prop-foot { display: flex; gap: 8px; padding: 0 17px 16px; }

/* category tiles */
.cat-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.cat-tile { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 14px; text-align: center; cursor: pointer; transition: transform .16s, box-shadow .2s, border-color .2s; cursor: pointer; }
.cat-tile:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--gold-soft); }
.cat-ico { width: 54px; height: 54px; border-radius: 15px; margin: 0 auto 12px; display: grid; place-items: center; background: var(--gold-tint); color: var(--navy); }
.cat-tile b { display: block; font-size: 15px; color: var(--ink); }
.cat-tile span { font-size: 12.5px; color: var(--muted); }

/* steps */
.steps-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.step-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 22px; position: relative; }
.step-num { font-size: 14px; font-weight: 800; color: var(--gold); background: var(--gold-tint); width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; margin-bottom: 14px; }
.step-card h3 { font-size: 17px; color: var(--navy); margin-bottom: 7px; }
.step-card p { font-size: 14px; color: var(--muted); }

/* why-us band */
.band { background: var(--navy); color: #fff; border-radius: var(--radius-lg); padding: 54px; position: relative; overflow: hidden; }
.band::after { content:""; position:absolute; inset:0; background: radial-gradient(640px 280px at 88% 120%, rgba(197,162,90,.18), transparent 60%); }
.band-grid { position: relative; display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px 36px; margin-top: 30px; }
.why-item { display: flex; gap: 14px; }
.why-ico { flex: 0 0 auto; width: 48px; height: 48px; border-radius: 14px; background: rgba(197,162,90,.16); color: var(--gold-soft); display: grid; place-items: center; }
.why-item h3 { font-size: 17px; margin-bottom: 5px; }
.why-item p { font-size: 14px; color: #b6bfcc; }

/* services */
.svc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.svc-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; transition: box-shadow .2s, transform .16s, border-color .2s; }
.svc-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); border-color: var(--gold-soft); }
.svc-card.feature { background: var(--navy); color: #fff; border-color: var(--navy-700); }
.svc-ico { width: 52px; height: 52px; border-radius: 15px; background: var(--gold-tint); color: var(--navy); display: grid; place-items: center; margin-bottom: 16px; }
.svc-card.feature .svc-ico { background: rgba(197,162,90,.18); color: var(--gold-soft); }
.svc-card h3 { font-size: 18.5px; color: var(--navy); margin-bottom: 8px; }
.svc-card.feature h3 { color: #fff; }
.svc-card p { font-size: 14px; color: var(--muted); }
.svc-card.feature p { color: #b6bfcc; }
.svc-tags { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 16px; }
.svc-tag { font-size: 12px; font-weight: 600; background: rgba(255,255,255,.1); color: #e3e8ef; padding: 4px 10px; border-radius: 999px; }

/* testimonials */
.tst-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.tst-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.tst-stars { color: var(--gold); display: flex; gap: 2px; margin-bottom: 12px; }
.tst-card p { font-size: 15px; color: var(--ink); line-height: 1.75; }
.tst-who { display: flex; align-items: center; gap: 12px; margin-top: 18px; }
.tst-av { width: 46px; height: 46px; border-radius: 50%; background: var(--gold-tint); color: var(--navy); display: grid; place-items: center; font-weight: 800; }
.tst-who b { display: block; font-size: 14.5px; }
.tst-who span { font-size: 12.5px; color: var(--muted); }

/* CTA strip */
.cta-strip { background: linear-gradient(135deg, var(--gold) 0%, #b08c3f 100%); color: #2a2008;
  border-radius: var(--radius-lg); padding: 46px 50px; display: flex; align-items: center; justify-content: space-between; gap: 30px; flex-wrap: wrap; }
.cta-strip h2 { font-size: clamp(22px,2.6vw,30px); color: #2a2008; }
.cta-strip p { margin-top: 8px; font-size: 15.5px; color: #4a3a14; }

/* footer */
.site-footer { background: #0f1d31; color: #b6bfcc; padding: 58px 0 26px; }
.footer-grid { display: grid; grid-template-columns: 1.7fr 1fr 1fr 1fr 1.1fr; gap: 32px; }
.footer-col h4 { color: #fff; font-size: 15px; margin-bottom: 16px; font-weight: 700; }
.footer-col a { display: block; padding: 6px 0; font-size: 14px; color: #9aa6b6; transition: color .15s; cursor: pointer; }
.footer-col a:hover { color: var(--gold-soft); }
.footer-about p { font-size: 14px; color: #9aa6b6; margin-top: 14px; max-width: 38ch; }
.footer-social { display: flex; gap: 10px; margin-top: 18px; }
.footer-social a { width: 40px; height: 40px; border-radius: 11px; background: rgba(255,255,255,.07); display: grid; place-items: center; color: #cdd5df; cursor: pointer; }
.footer-social a:hover { background: var(--gold); color: #2a2008; }
.footer-bottom { margin-top: 40px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.1); display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; font-size: 13px; color: #7e8b9c; }
/* روابط الصفحات القانونية (الخصوصية/الشروط) في الشريط السفلي — كانت عموداً سادساً
   يكسر شبكة التذييل ذات الخمسة أعمدة. تظهر على صفحات الخادم (العقار/الأرشيف/المقال). */
.footer-legal { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; }
.footer-legal a { color: #7e8b9c; transition: color .15s; }
.footer-legal a:hover { color: var(--gold-soft); }
/* FAL (فال) license credential — card */
.fal-cred { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.fal-card-link { display: block; border-radius: 10px; overflow: hidden; box-shadow: 0 6px 16px rgba(0,0,0,.24); line-height: 0; width: 230px; max-width: 100%; }
.fal-card-link img { width: 100%; height: auto; display: block; }
.fal-cred-cap { color: #9aa6b6; font-size: 11.5px; font-weight: 600; }


/* floating contact buttons */
.float-contact { position: fixed; bottom: 22px; inset-inline-start: 22px; z-index: 70; display: flex; flex-direction: column; gap: 12px; }
.float-btn { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; border: none; box-shadow: var(--shadow-lg); transition: transform .15s; position: relative; }
.float-btn:hover { transform: scale(1.07); }
.float-wa { background: #25d366; color: #fff; }
.float-call { background: var(--navy); color: #fff; }
.float-btn .tip { position: absolute; inset-inline-start: 68px; top: 50%; transform: translateY(-50%); background: var(--navy); color: #fff;
  font-size: 13px; font-weight: 600; padding: 7px 12px; border-radius: 9px; white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity .15s; }
.float-btn:hover .tip { opacity: 1; }
/* hide floating contact buttons while the mobile filter sheet (or nav drawer) is open — they otherwise overlay the sheet from the root stacking context */
body:has(.filter-sheet) .float-contact,
body:has(.drawer-backdrop) .float-contact,
body:has(.map-sheet) .float-contact { display: none; }
body:has(.map-sheet) .app-scroll { animation: none !important; transform: none !important; }

/* utilities */
.fade-up { animation: fadeUp .28s ease-out both; }
@keyframes fadeUp { from { opacity: 0; } to { opacity: 1; } }
.divider { height: 1px; background: var(--line); border: none; margin: 0; }

/* ---------- blog ---------- */
.blog-cats { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 28px; }
.blog-cats .chip { padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 13.5px; font-weight: 600; color: var(--muted); cursor: pointer; transition: all .15s; }
.blog-cats .chip:hover { border-color: var(--gold-soft); }
.blog-cats .chip.on { background: var(--navy); color: #fff; border-color: var(--navy); }
.blog-cat { display: inline-block; font-size: 12px; font-weight: 700; color: var(--gold-700, #a9883f); background: var(--gold-tint); padding: 4px 11px; border-radius: 999px; }
.blog-cat.float { position: absolute; top: 12px; inset-inline-start: 12px; background: rgba(255,255,255,.94); color: var(--navy); }
.blog-feature { display: grid; grid-template-columns: 1.2fr 1fr; gap: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; cursor: pointer; transition: box-shadow .2s, border-color .2s; margin-bottom: 30px; }
.blog-feature:hover { box-shadow: var(--shadow-lg); border-color: var(--gold-soft); }
.blog-feature-media { position: relative; min-height: 280px; }
.blog-feature-body { padding: 34px; display: flex; flex-direction: column; gap: 12px; justify-content: center; }
.blog-feature-body h2 { font-size: 26px; color: var(--navy); line-height: 1.3; }
.blog-feature-body p { color: var(--ink-2, #41506a); font-size: 15px; }
.blog-meta { display: flex; align-items: center; gap: 16px; font-size: 13px; color: var(--muted); }
.blog-meta span { display: inline-flex; align-items: center; gap: 6px; }
.blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.blog-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; cursor: pointer; transition: transform .2s, box-shadow .2s, border-color .2s; display: flex; flex-direction: column; }
.blog-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--gold-soft); }
.blog-card-media { position: relative; aspect-ratio: 16/10; }
.blog-card-body { padding: 18px; display: flex; flex-direction: column; gap: 9px; flex: 1; }
.blog-card-body h3 { font-size: 17px; color: var(--navy); line-height: 1.4; }
.blog-card-body p { font-size: 13.5px; color: var(--muted); flex: 1; }
.blog-card-body .blog-meta { padding-top: 10px; border-top: 1px solid var(--line-soft); margin-top: 4px; justify-content: space-between; }
/* post */
.post-page { padding-top: 30px; }
.post-narrow { max-width: 820px; }
.post-title { font-size: clamp(26px, 4vw, 40px); color: var(--navy); line-height: 1.25; margin-top: 10px; }
.post-cover { aspect-ratio: 16/8; border-radius: var(--radius-lg); overflow: hidden; margin: 24px 0 30px; border: 1px solid var(--line); }
.post-body { font-size: 17px; line-height: 1.95; color: var(--ink); }
.post-body p { margin-bottom: 20px; }
.post-cta { display: flex; align-items: center; justify-content: space-between; gap: 20px; background: var(--gold-tint); border: 1px solid #e8d6a8; border-radius: var(--radius-lg); padding: 26px 30px; margin-top: 36px; flex-wrap: wrap; }
.post-cta h3 { color: var(--navy); font-size: 20px; }
.post-cta p { color: #6b5320; margin-top: 6px; }

/* ---------- listings page ---------- */
.listings-head { background: var(--surface); border-bottom: 1px solid var(--line); padding: 30px 0; }
.listings-layout { display: grid; grid-template-columns: 290px 1fr; gap: 28px; padding-top: 32px; padding-bottom: 60px; align-items: start; }
.filters-side { position: sticky; top: 92px; }
.filters-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.filters-card-head { display: flex; align-items: center; justify-content: space-between; font-weight: 800; color: var(--navy); font-size: 16px; margin-bottom: 18px; }
.filters-card-head span { display: inline-flex; align-items: center; gap: 8px; }
.flt-count { background: var(--gold); color: #2a2008; font-size: 12px; font-weight: 800; min-width: 20px; height: 20px; border-radius: 999px; display: inline-grid; place-items: center; padding: 0 6px; }
.flt-group { margin-bottom: 20px; }
.flt-label { display: block; font-size: 13px; font-weight: 700; color: var(--ink); margin-bottom: 10px; }
.flt-select { width: 100%; border: 1px solid var(--line); background: var(--bg-warm); border-radius: var(--radius-sm); padding: 10px 12px; font-size: 14px; font-weight: 600; color: var(--ink); outline: none; appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns=&#039;http://www.w3.org/2000/svg&#039; width=&#039;13&#039; height=&#039;13&#039; viewBox=&#039;0 0 24 24&#039; fill=&#039;none&#039; stroke=&#039;%236a7078&#039; stroke-width=&#039;2.5&#039;%3E%3Cpolyline points=&#039;6 9 12 15 18 9&#039;/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: left 12px center; padding-inline-start: 32px; }
.flt-select:focus { border-color: var(--gold); background-color: #fff; }
.flt-pills { display: flex; flex-wrap: wrap; gap: 7px; }
.flt-pill { padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 13.5px; font-weight: 600; color: var(--muted); }
.flt-pill:hover { border-color: var(--gold-soft); }
.flt-pill.on { background: var(--navy); color: #fff; border-color: var(--navy); }
.listings-toolbar { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.toolbar-sort { display: flex; align-items: center; gap: 10px; }
.toolbar-sort label { font-size: 13.5px; color: var(--muted); font-weight: 600; white-space: nowrap; }
.toolbar-sort .flt-select { width: auto; min-width: 170px; }
.view-toggle { margin-inline-start: auto; display: flex; gap: 4px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 3px; }
.view-toggle button { border: none; background: transparent; padding: 7px 10px; border-radius: 7px; color: var(--muted); display: grid; place-items: center; }
.view-toggle button.on { background: var(--navy); color: #fff; }
.view-toggle .vt-labeled { width: auto; gap: 6px; padding-inline: 12px; font-size: 13.5px; font-weight: 700; }
/* ---- بطاقة «عرض على الخريطة» في عمود الفلاتر ---- */
.map-promo { display: block; width: 100%; margin-bottom: 16px; padding: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface); cursor: pointer; box-shadow: var(--shadow-sm); transition: box-shadow .15s ease; }
.map-promo:hover { box-shadow: var(--shadow-md); }
.map-promo-thumb { position: relative; height: 168px; overflow: hidden; background: #eef0ec; }
/* مسطّح مائي (نهر/بحر) */
.map-promo-thumb .mp-water { position: absolute; inset: 0; background: linear-gradient(122deg, #aecbdc 0 26%, transparent 26% 100%); }
/* حديقة/مساحة خضراء */
.map-promo-thumb .mp-park { position: absolute; right: 14%; bottom: 12%; width: 38%; height: 42%; background: #cfe0c3; border-radius: 18px 30px 22px 26px; }
/* الطرق: قصب أبيض بحاشية رمادية */
.map-promo-thumb .mp-road { position: absolute; background: #fff; box-shadow: 0 0 0 1.5px #d9dde0; }
.map-promo-thumb .mp-road-1 { top: -10%; left: 30%; width: 13px; height: 130%; transform: rotate(16deg); }
.map-promo-thumb .mp-road-2 { top: 40%; left: -10%; width: 130%; height: 11px; transform: rotate(-7deg); }
.map-promo-thumb .mp-road-3 { top: -10%; left: 66%; width: 8px; height: 130%; transform: rotate(16deg); background: #f7f8f9; }
.map-promo-pin { position: absolute; top: 30%; left: 50%; transform: translate(-50%, -50%); color: var(--gold); filter: drop-shadow(0 3px 4px rgba(0,0,0,.3)); z-index: 2; }
.map-promo-btn { position: absolute; left: 50%; top: 58%; transform: translate(-50%, -50%); display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; background: var(--navy); color: #fff; font-weight: 700; font-size: 13.5px; padding: 10px 18px; border-radius: 24px; box-shadow: 0 3px 12px rgba(0,0,0,.22); transition: filter .15s ease; }
.map-promo:hover .map-promo-btn { filter: brightness(1.1); }
.listings-map-banner { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); z-index: 500; display: flex; align-items: center; gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 24px; padding: 8px 8px 8px 16px; box-shadow: var(--shadow-md); font-size: 13.5px; font-weight: 600; color: var(--ink); max-width: calc(100% - 32px); }
.listings-map-banner span { display: inline-flex; align-items: center; gap: 7px; }
.filters-toggle { display: none; }
.listings-grid { grid-template-columns: repeat(3, 1fr); }
.list-rows { display: flex; flex-direction: column; gap: 16px; }
.list-row { display: grid; grid-template-columns: 280px 1fr; gap: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; cursor: pointer; transition: box-shadow .2s, border-color .2s; }
.list-row:hover { box-shadow: var(--shadow); border-color: var(--gold-soft); }
.list-media { position: relative; aspect-ratio: 4/3; }
.list-info { padding: 18px; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
/* امنع قصّ/تجاوز محتوى بطاقة القائمة (overflow:hidden كان يقصّ العنوان الطويل من جهة اليمين) */
.list-info > * { min-width: 0; }
.list-info .prop-title { min-width: 0; overflow-wrap: anywhere; text-wrap: pretty; }
.list-info .prop-loc { flex-wrap: wrap; }
.list-info .prop-loc, .list-info p { overflow-wrap: anywhere; }
.empty-state { text-align: center; padding: 70px 20px; background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); }
.empty-ico { width: 70px; height: 70px; border-radius: 50%; background: var(--bg-warm); color: var(--muted); display: grid; place-items: center; margin: 0 auto 18px; }
.empty-state h3 { color: var(--navy); font-size: 20px; margin-bottom: 8px; }
.empty-state p { color: var(--muted); margin-bottom: 18px; }
/* ---- تصفّح العقارات على الخريطة (دبابيس الأسعار) ---- */
.listings-map-wrap { position: relative; }
.listings-map { height: 72vh; min-height: 460px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow-sm); z-index: 0; }
.listings-map-hint { display: flex; align-items: center; gap: 6px; justify-content: center; margin-top: 12px; font-size: 13px; color: var(--muted); }
.listings-map-empty { min-height: 360px; display: grid; place-content: center; justify-items: center; gap: 12px; text-align: center; color: var(--muted); background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); padding: 40px; }
.price-pin-ico { background: none !important; border: none !important; }
.price-pin { display: flex; width: 100%; height: 100%; align-items: center; justify-content: center; box-sizing: border-box; padding: 6px 12px; white-space: nowrap; text-align: center; background: var(--navy); color: #fff; font-weight: 700; font-size: 12.5px; line-height: 1; border-radius: 16px; border: 2px solid #fff; box-shadow: 0 2px 8px rgba(0,0,0,.28); cursor: pointer; transition: transform .12s ease, filter .12s ease; }
.price-pin:hover { filter: brightness(1.08); transform: scale(1.08); z-index: 5; }
/* تحصين: يبطل قاعدة الجوال العامة * { max-width:100% } التي تنهي الدبوس إلى صفر */
.price-pin-ico, .price-pin { max-width: none !important; }
/* زر تبديل طبقة الخريطة (أقمار صناعية) */
.map-layer-toggle { margin: 10px; background: #fff; border: 1px solid var(--line); border-radius: 9px; padding: 8px 13px; font-family: inherit; font-size: 13px; font-weight: 700; color: var(--navy); cursor: pointer; box-shadow: 0 1px 5px rgba(0,0,0,.22); }
.map-layer-toggle:hover { background: var(--bg-warm); }
.map-layer-toggle.on { background: var(--navy); color: #fff; border-color: var(--navy); }
/* أدوات الخريطة: «حولي» + «إعادة التوسيط» — أزرار أنيقة أسفل بداية الخريطة */
.map-tools { position: absolute; inset-block-end: 16px; inset-inline-start: auto; inset-inline-end: 16px; z-index: 500; display: flex; flex-direction: column; gap: 9px; }
.map-tool { width: 46px; height: 46px; border-radius: 13px; border: 1px solid var(--line); background: rgba(255,255,255,.94); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); color: var(--navy); display: grid; place-items: center; cursor: pointer; box-shadow: 0 4px 14px rgba(20,33,61,.2); transition: background .14s ease, transform .12s ease, color .14s ease; }
.map-tool:hover { background: var(--navy); color: #fff; }
.map-tool:active { transform: scale(.94); }
.map-tool.busy { pointer-events: none; }
.map-tool-spin { width: 18px; height: 18px; border-radius: 50%; border: 2.5px solid var(--line); border-top-color: var(--navy); animation: mapToolSpin .7s linear infinite; }
@keyframes mapToolSpin { to { transform: rotate(360deg); } }
/* دبّوس «أنت هنا» */
.user-loc-ico { background: none !important; border: none !important; }
.user-loc-dot { position: relative; display: block; box-sizing: border-box; flex: 0 0 auto; width: 18px; height: 18px; border-radius: 50%; background: #2a6fdb; border: 3px solid #fff; box-shadow: 0 0 0 4px rgba(42,111,219,.3), 0 1px 6px rgba(0,0,0,.3); }
.user-loc-dot::after { content: ""; position: absolute; inset: -9px; border-radius: 50%; border: 2px solid rgba(42,111,219,.45); animation: userLocPulse 1.8s ease-out infinite; }
@keyframes userLocPulse { 0% { transform: scale(.6); opacity: .9; } 100% { transform: scale(1.5); opacity: 0; } }
/* سطر المسافة في بطاقة/فقاعة المعاينة */
.pin-pop-dist, .map-sheet .pin-pop-dist { display: inline-flex; align-items: center; gap: 5px; margin-top: 4px; font-size: 12.5px; font-weight: 700; color: var(--gold, #b4914e); }
/* زر العودة للخريطة على صفحة العقار */
/* زر العودة للخريطة — بارز أعلى صفحة العقار (تدفّق عادي، لا يطفو أسفل الصفحة) */
.back-to-map { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 16px; background: var(--navy); color: #fff; border: none; border-radius: 999px; padding: 11px 22px; font-family: inherit; font-size: 14.5px; font-weight: 700; box-shadow: var(--shadow-sm); cursor: pointer; }
.back-to-map:hover { background: var(--navy-700); }
.back-to-map svg { color: var(--gold-soft); }
/* الجوال: زر ثابت أنيق بخلفية زجاجية شفّافة يبقى ظاهراً أثناء التمرير (تحت الهيدر مباشرة) */
@media (max-width: 768px) {
  .back-to-map {
    position: static; transform: none;
    z-index: auto; width: 100%; margin: 2px 0 14px; padding: 12px 20px; justify-content: center;
    background: rgba(20, 33, 61, .8);
    -webkit-backdrop-filter: blur(12px) saturate(150%); backdrop-filter: blur(12px) saturate(150%);
    border: 1px solid rgba(255, 255, 255, .16);
    box-shadow: 0 8px 24px rgba(20, 33, 61, .3);
  }
  .back-to-map:active { transform: scale(.97); }
  .detail-wrap:has(.back-to-map) { padding-top: 0; }
}
.price-pin.rent { background: var(--gold, #b4914e); color: #fff; }
.price-pin.feat { background: var(--gold, #b4914e); color: #fff; box-shadow: 0 2px 10px rgba(180,145,78,.55), 0 0 0 1px rgba(255,255,255,.4); z-index: 4; }
.price-pin.feat::before { content: "\2605"; margin-inline-end: 4px; font-size: 11px; }

/* ---- فقاعة العنقود (تجميع العقارات المتجاورة) ---- */
.price-cluster-ico { background: none !important; border: none !important; }
.price-cluster { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; border-radius: 50%; color: #fff; font-weight: 800; line-height: 1; background: var(--navy); border: 3px solid #fff; box-shadow: 0 3px 12px rgba(20,33,61,.4); transition: transform .12s ease, filter .12s ease; }
.price-cluster.c-s { font-size: 13px; box-shadow: 0 3px 10px rgba(20,33,61,.36); }
.price-cluster.c-m { font-size: 15px; background: linear-gradient(145deg, var(--navy), #20396b); }
.price-cluster.c-l { font-size: 17px; background: linear-gradient(145deg, #20396b, var(--navy)); box-shadow: 0 4px 16px rgba(20,33,61,.5); }
.price-cluster-ico:hover .price-cluster { transform: scale(1.07); filter: brightness(1.06); }

/* ---- بطاقة المعاينة السريعة على الخريطة ---- */
.pin-pop-wrap .leaflet-popup-content-wrapper { padding: 0; overflow: hidden; border-radius: 14px; box-shadow: 0 12px 34px rgba(20,33,61,.28); }
.pin-pop-wrap .leaflet-popup-content { margin: 0; width: 210px !important; }
.pin-pop-wrap .leaflet-popup-tip { box-shadow: 0 6px 14px rgba(20,33,61,.18); }
.pin-pop { display: flex; flex-direction: column; font-family: inherit; }
.pin-pop-media { position: relative; height: 112px; background: var(--surface-2, #eef1f5); }
.pin-pop-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pin-pop-ph { display: block; width: 100%; height: 100%; background: repeating-linear-gradient(135deg, #e4e8ee 0 10px, #eef1f5 10px 20px); }
.pin-pop-tag { position: absolute; inset-block-start: 8px; inset-inline-start: 8px; background: rgba(20,33,61,.92); color: #fff; font-size: 11px; font-weight: 700; padding: 3px 9px; border-radius: 20px; }
.pin-pop-feat { position: absolute; inset-block-start: 8px; inset-inline-end: 8px; background: var(--gold, #b4914e); color: #fff; font-size: 11px; font-weight: 700; padding: 3px 9px; border-radius: 20px; }
.pin-pop-body { display: flex; flex-direction: column; gap: 3px; padding: 11px 13px 13px; }
.pin-pop-price { font-size: 16px; font-weight: 800; color: var(--navy); }
.pin-pop-title { font-size: 13px; font-weight: 700; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pin-pop-loc { font-size: 12px; color: var(--muted); }
.pin-pop-btn { margin-top: 8px; width: 100%; padding: 8px; border: none; border-radius: 9px; background: var(--navy); color: #fff; font-family: inherit; font-size: 13px; font-weight: 700; cursor: pointer; transition: filter .15s; }
.pin-pop-btn:hover { filter: brightness(1.1); }

/* ---- بطاقة سفلية على الخريطة (UX الجوال — لا تُقصّ أبداً) ---- */
.listings-map-wrap { position: relative; }
/* بطاقة المعاينة على الجوال — مثبّتة بأسفل نافذة العرض (تظهر دائماً مهما كان موضع التمرير، لا تُقصّ عند حافة الخريطة) */
.map-sheet { position: fixed; inset-inline: 10px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); z-index: 1200; display: flex; background: #fff; border-radius: 14px; overflow: hidden; box-shadow: 0 14px 38px rgba(20,33,61,.4); animation: mapSheetUp .22s ease; }
@keyframes mapSheetUp { from { transform: translateY(16px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.map-sheet-media { position: relative; width: 116px; flex: 0 0 auto; background: var(--surface-2, #eef1f5); }
.map-sheet-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.map-sheet-body { display: flex; flex-direction: column; gap: 3px; padding: 12px 14px; flex: 1 1 auto; min-width: 0; }
.map-sheet-close { position: absolute; top: 7px; inset-inline-end: 7px; z-index: 3; width: 28px; height: 28px; border-radius: 50%; border: none; background: rgba(20,33,61,.85); color: #fff; font-size: 18px; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.map-sheet .pin-pop-price { font-size: 16px; font-weight: 800; color: var(--navy); }
.map-sheet .pin-pop-title { font-size: 13.5px; font-weight: 700; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.map-sheet .pin-pop-loc { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.map-sheet .pin-pop-btn { margin-top: 9px; width: 100%; padding: 9px; border: none; border-radius: 9px; background: var(--navy); color: #fff; font-family: inherit; font-size: 13.5px; font-weight: 700; cursor: pointer; }
.map-sheet .pin-pop-ph { display: block; width: 100%; height: 100%; min-height: 116px; background: repeating-linear-gradient(135deg, #e4e8ee 0 10px, #eef1f5 10px 20px); }
.filter-sheet { position: fixed; inset: 0 0 0 auto; width: 88%; max-width: 360px; background: var(--surface); z-index: 95; padding: 22px; overflow-y: auto; box-shadow: var(--shadow-lg); animation: slideInSheet .25s; }
@keyframes slideInSheet { from { transform: translateX(100%); } to { transform: translateX(0); } }

/* ---------- detail page ---------- */
.detail-wrap { padding-bottom: 70px; }
.breadcrumb { display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--muted); padding: 18px 0; flex-wrap: wrap; }
.breadcrumb a:hover { color: var(--navy); }
.breadcrumb .sep { color: var(--muted-2); }
.gallery { display: grid; grid-template-columns: 2fr 1fr; grid-template-rows: 1fr; gap: 12px; height: 440px; border-radius: var(--radius); overflow: hidden; }
.gallery.gallery-solo { grid-template-columns: 1fr; }
.gallery-main { position: relative; }
.gallery-side { display: grid; grid-template-columns: 1fr; grid-auto-rows: 1fr; gap: 12px; }
.gallery-side.grid4 { grid-template-columns: 1fr 1fr; }
.gallery-thumb { position: relative; cursor: pointer; overflow: hidden; border-radius: var(--radius-sm); }
.gallery-thumb:hover img, .gallery-main:hover img { filter: brightness(.92); }
.lightbox { position: fixed; inset: 0; z-index: 100000; background: rgba(8,12,20,.94); display: grid; place-items: center; padding: 40px; }
.lb-img { max-width: 92vw; max-height: 80vh; object-fit: contain; border-radius: 8px; box-shadow: 0 24px 70px rgba(0,0,0,.55); }
.lb-close { position: absolute; top: 18px; inset-inline-start: 18px; width: 46px; height: 46px; border-radius: 50%; background: rgba(255,255,255,.12); color: #fff; border: none; cursor: pointer; display: grid; place-items: center; }
.lb-close:hover { background: rgba(255,255,255,.24); }
.lb-counter { position: absolute; top: 24px; inset-inline-end: 24px; color: #fff; font-weight: 600; font-size: 15px; background: rgba(0,0,0,.4); padding: 6px 14px; border-radius: 20px; direction: ltr; white-space: nowrap; }
.lb-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 52px; height: 52px; border-radius: 50%; background: rgba(255,255,255,.12); color: #fff; border: none; cursor: pointer; display: grid; place-items: center; }
.lb-nav:hover { background: rgba(255,255,255,.26); }
.lb-prev { inset-inline-end: 22px; }
.lb-next { inset-inline-start: 22px; }
.lb-strip { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); display: flex; gap: 8px; max-width: 92vw; overflow-x: auto; padding: 8px; }
.lb-thumb { width: 66px; height: 48px; border-radius: 6px; overflow: hidden; border: 2px solid transparent; padding: 0; cursor: pointer; flex: 0 0 auto; background: none; }
.lb-thumb.on { border-color: var(--gold, #c5a25a); }
.lb-thumb img { width: 100%; height: 100%; object-fit: cover; }
.gallery-more { position: absolute; inset: 0; background: rgba(22,38,63,.6); display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 15px; gap: 6px; }
.detail-layout { display: grid; grid-template-columns: 1fr 360px; gap: 32px; margin-top: 30px; align-items: start; }
.detail-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; flex-wrap: wrap; }
.detail-title h1 { font-size: 28px; color: var(--navy); max-width: 22ch; }
.detail-loc { display: flex; align-items: center; gap: 7px; color: var(--muted); margin-top: 10px; font-size: 15px; }
.listing-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 12px; margin-top: 12px; }
.listing-meta .lm-item { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); }
.listing-meta .lm-item svg { color: var(--gold); flex-shrink: 0; }
.listing-meta .lm-ref { color: var(--ink); }
.listing-meta .lm-ref b { font-variant-numeric: tabular-nums; letter-spacing: .02em; }
.listing-meta .lm-sep { width: 1px; height: 13px; background: var(--line); }
.listing-gone { text-align: center; padding: 48px 0 16px; }
.listing-gone .lg-icon { width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; margin: 0 auto 22px; background: color-mix(in srgb, var(--navy) 7%, var(--surface)); color: var(--muted); border: 1px solid var(--line); }
.listing-gone h1 { font-size: 27px; color: var(--navy); margin-bottom: 12px; }
.listing-gone > p { max-width: 56ch; margin: 0 auto 24px; color: var(--muted); font-size: 15.5px; line-height: 1.9; }
.listing-gone .lg-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-bottom: 8px; }
.listing-gone .lg-similar { margin-top: 52px; text-align: right; }
.listing-gone .lg-similar h2 { font-size: 21px; color: var(--navy); margin-bottom: 20px; }
@media (max-width: 560px) { .listing-meta .lm-sep { display: none; } .listing-meta { gap: 6px 14px; } }
.detail-actions { display: flex; gap: 8px; }
.icon-btn { width: 44px; height: 44px; border-radius: 11px; border: 1px solid var(--line); background: var(--surface); display: grid; place-items: center; color: var(--ink); transition: all .15s; }
.icon-btn:hover { border-color: var(--navy); color: var(--navy); }
.icon-btn.on { color: #e0445b; border-color: #f3c4cc; }
.detail-price { font-size: 30px; font-weight: 800; color: var(--navy); margin-top: 18px; }
.detail-price .unit { font-size: 16px; font-weight: 600; color: var(--muted); }
.fact-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: 24px; }
.fact { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 16px; text-align: center; }
.fact-ico { color: var(--gold); margin-bottom: 8px; display: flex; justify-content: center; }
.fact b { display: block; font-size: 18px; color: var(--navy); }
.fact span { font-size: 12.5px; color: var(--muted); }
.detail-block { margin-top: 34px; }
.detail-block h2 { font-size: 21px; color: var(--navy); margin-bottom: 14px; }
.detail-block p { color: var(--ink); line-height: 1.85; }
.feat-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.feat-item { display: flex; align-items: center; gap: 10px; font-size: 14.5px; color: var(--ink); font-weight: 500; }
.feat-item .feat-check { color: var(--green); display: grid; place-items: center; flex-shrink: 0; }
.map-box { height: 280px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); position: relative; }

/* بطاقة الإعلان العقاري — إفصاح الهيئة العامة للعقار (REGA) */
.rega-card { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.rega-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; background: color-mix(in srgb, var(--navy) 5%, var(--surface)); border-bottom: 1px solid var(--line); }
.rega-brand { display: inline-flex; align-items: center; gap: 8px; font-weight: 800; font-size: 14px; color: var(--navy); }
.rega-brand svg { color: var(--gold); }
.rega-chip { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 700; border-radius: 999px; padding: 5px 12px; }
.rega-chip.ok { color: #2f7d5b; background: #e6f1ea; }
.rega-chip.bad { color: #b4452f; background: #f6e3de; }
.rega-kv { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 22px; padding: 18px; }
.rega-item { display: flex; flex-direction: column; gap: 3px; }
.rega-item.full { grid-column: 1 / -1; }
.rega-item .k { font-size: 12px; color: var(--muted); font-weight: 600; }
.rega-item .v { font-size: 14.5px; color: var(--ink); font-weight: 700; display: inline-flex; align-items: center; gap: 6px; }
.rega-item .v.mono { font-variant-numeric: tabular-nums; letter-spacing: .01em; direction: ltr; text-align: right; }
.rega-item .rega-cap { font-style: normal; font-weight: 600; color: var(--muted); }
.rega-tick { color: #2f7d5b; }
.rega-discl { padding: 0 18px 16px; }
.rega-discl-h { display: block; font-size: 12px; color: var(--muted); font-weight: 700; margin-bottom: 9px; }
.rega-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.rega-tag { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; border-radius: 8px; padding: 6px 11px; border: 1px solid var(--line); }
.rega-tag.ok { color: #2f7d5b; background: #f1f7f3; border-color: #d6e8dd; }
.rega-tag.warn { color: #9a6a16; background: #fbf3e2; border-color: #ecdcb6; }
.rega-note { display: flex; align-items: flex-start; gap: 7px; padding: 12px 18px; margin: 0; border-top: 1px solid var(--line); font-size: 12px; line-height: 1.7; color: var(--muted); background: color-mix(in srgb, var(--navy) 3%, var(--surface)); }
.rega-note svg { flex-shrink: 0; margin-top: 2px; }
@media (max-width: 560px) { .rega-kv { grid-template-columns: 1fr; } }

.map-pin { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -100%); color: var(--gold); filter: drop-shadow(0 4px 8px rgba(0,0,0,.25)); }

/* ---- خريطة Leaflet (OpenStreetMap) ---- */
.lmap-wrap { position: relative; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: var(--surface); }
.lmap { width: 100%; height: 100%; z-index: 0; }
.lmap-pick .lmap { cursor: crosshair; }
.lmap-fallback { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); font-size: 14px; background: var(--surface); }
.lmap-wrap .leaflet-container { font-family: inherit; background: #e9eef2; }
.map-actions { display: flex; align-items: center; gap: 14px; margin-top: 12px; flex-wrap: wrap; }
.map-approx { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; color: var(--muted); }
.map-hint { margin-top: 10px; font-size: 13.5px; color: var(--muted); }
.map-hint .map-pinned { display: inline-flex; align-items: center; gap: 6px; color: var(--green); font-weight: 600; direction: ltr; }
.map-hint span { display: inline-flex; align-items: center; gap: 6px; }
.btn-sm { padding: 8px 14px; font-size: 14px; }
html[data-theme="dark"] .lmap-wrap .leaflet-container { background: #1a1d22; }
html[data-theme="dark"] .leaflet-tile { filter: brightness(.85) contrast(1.05); }
.detail-aside { position: sticky; top: 92px; display: flex; flex-direction: column; gap: 16px; }
.agent-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.agent-row { display: flex; align-items: center; gap: 13px; margin-bottom: 18px; }
.agent-av { width: 54px; height: 54px; border-radius: 14px; background: var(--navy); color: var(--gold); display: grid; place-items: center; }
.agent-row b { display: block; font-size: 16px; color: var(--navy); }
.agent-row span { font-size: 13px; color: var(--muted); }
.agent-actions { display: flex; flex-direction: column; gap: 9px; }
.contact-mini { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.contact-mini h3 { font-size: 17px; color: var(--navy); margin-bottom: 14px; }
.field { margin-bottom: 13px; }
.field label { display: block; font-size: 13px; font-weight: 700; color: var(--ink); margin-bottom: 6px; }
.field .req { color: var(--danger); }
.inp { width: 100%; border: 1px solid var(--line); background: var(--bg-warm); border-radius: var(--radius-sm); padding: 11px 13px; font-size: 16px; color: var(--ink); outline: none; transition: border-color .15s; min-height: 44px; }
.inp:focus { border-color: var(--gold); background: var(--surface); box-shadow: 0 0 0 3px rgba(197,162,90,.14); }
textarea.inp { resize: vertical; min-height: 88px; }
/* تحقّق الحقول — حالة الخطأ */
.field-err .inp, .inp.inp-err { border: 1px solid #b4452f; background: #fdf3f2; box-shadow: inset 0 0 0 1px #b4452f; }
.field-err .inp:focus, .inp.inp-err:focus { box-shadow: 0 0 0 3px rgba(180,69,47,.16); border-color: #b4452f; }
.field-err-msg { display: flex; align-items: center; gap: 5px; margin-top: 6px; font-size: 12.5px; font-weight: 600; color: var(--danger); line-height: 1.45; }
.field-err-msg svg { flex-shrink: 0; }
.field-hint { display: block; margin-top: 5px; font-size: 12px; font-weight: 500; color: var(--muted); }
.form-err-banner { display: flex; align-items: center; gap: 9px; margin-bottom: 22px; padding: 12px 15px; border-radius: var(--radius-sm); background: #fdeeee; border: 1px solid #f0c4c4; color: var(--danger); font-size: 13.5px; font-weight: 600; }
.form-err-banner svg { flex-shrink: 0; }
/* dual-date (Hijri / Gregorian) */
.dd-both { display: flex; flex-direction: column; gap: 8px; }
.dd-line { display: flex; align-items: center; gap: 10px; }
.dd-cal { flex-shrink: 0; width: 52px; font-size: 12px; font-weight: 800; color: var(--muted); }
.dd-hijri { display: grid; grid-template-columns: 0.9fr 1.5fr 1.1fr; gap: 8px; flex: 1; }
.dd-greg { flex: 1; }
.dd-sel { padding-inline: 10px; cursor: pointer; }
.dd-sel:disabled { opacity: .55; cursor: not-allowed; }
input[type=date].dd-greg { cursor: pointer; }
.dd-greg::-webkit-calendar-picker-indicator { cursor: pointer; opacity: .7; }
.dd-greg::-webkit-calendar-picker-indicator:hover { opacity: 1; }
@media (max-width: 560px) {
  .dd-line { flex-direction: column; align-items: stretch; gap: 5px; }
  .dd-cal { width: auto; }
  /* قوائم التاريخ الهجري: مساحة أوضح للأيام/الأشهر/السنوات على الجوال */
  .dd-hijri { grid-template-columns: 1fr 1.4fr 1.2fr; gap: 6px; }
  .dd-sel { padding-inline: 6px; font-size: 14px; }
  /* أزرار التنقل في النموذج: صف كامل وأهداف لمس مريحة */
  .form-nav { gap: 10px; }
  .form-nav .btn { flex: 1 1 0; min-height: 48px; justify-content: center; }
}
/* ---------- تقويم منبثق (ميلادي / أم القرى) ---------- */
.dpk-wrap { position: relative; }
.dpk-trigger { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 46px; padding: 8px 13px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); cursor: pointer; transition: border-color .15s, box-shadow .15s; }
.dpk-trigger:hover { border-color: var(--gold-soft); }
.dpk-trigger.open { border-color: var(--green); box-shadow: 0 0 0 3px rgba(47,125,91,.12); }
.dpk-trigger.ro { background: var(--bg-warm); cursor: not-allowed; opacity: .9; }
.dpk-cal-ico { display: grid; place-items: center; color: var(--green); flex-shrink: 0; }
.dpk-val { display: flex; flex-direction: column; line-height: 1.25; flex: 1; min-width: 0; }
.dpk-val b { font-size: 14.5px; font-weight: 700; color: var(--navy); }
.dpk-val small { font-size: 12px; color: var(--muted); direction: ltr; text-align: start; }
.dpk-ph { flex: 1; font-size: 14.5px; color: var(--muted); }
.dpk-chev { color: var(--muted); flex-shrink: 0; }
.dpk-overlay { position: fixed; inset: 0; z-index: 70; background: transparent; }
.dpk-pop { position: absolute; z-index: 71; top: calc(100% + 6px); inset-inline-start: 0; width: min(340px, 90vw); background: var(--surface); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 20px 56px rgba(20,38,63,.22); padding: 14px; }
.dpk-seg { display: flex; gap: 4px; background: var(--bg-warm); border: 1px solid var(--line); border-radius: 11px; padding: 4px; margin-bottom: 13px; }
.dpk-seg button { flex: 1; padding: 9px 8px; border: none; border-radius: 8px; background: none; font-family: inherit; font-size: 13.5px; font-weight: 700; color: var(--muted); cursor: pointer; transition: .15s; }
.dpk-seg button.on { background: var(--green); color: #fff; box-shadow: 0 2px 8px rgba(47,125,91,.3); }
.dpk-nav { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.dpk-arrow { width: 36px; height: 36px; flex-shrink: 0; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); color: var(--navy); cursor: pointer; transition: .15s; }
.dpk-arrow:hover { background: var(--bg-warm); border-color: var(--gold-soft); }
.dpk-msel, .dpk-ysel { flex: 1; min-width: 0; height: 36px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); font-family: inherit; font-size: 14px; font-weight: 600; color: var(--navy); padding: 0 8px; cursor: pointer; appearance: none; text-align: center; text-align-last: center; }
.dpk-ysel { flex: 0 0 92px; }
.dpk-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.dpk-dow { text-align: center; font-size: 11px; font-weight: 700; color: var(--muted); padding: 4px 0 8px; }
.dpk-day { aspect-ratio: 1; display: grid; place-items: center; border: none; background: none; border-radius: 9px; font-family: inherit; font-size: 13.5px; font-weight: 600; color: var(--navy); cursor: pointer; transition: .12s; }
.dpk-day:hover { background: var(--bg-warm); }
.dpk-day.today { box-shadow: inset 0 0 0 1.5px var(--green); color: var(--green); }
.dpk-day.sel { background: var(--green); color: #fff; font-weight: 800; box-shadow: 0 3px 9px rgba(47,125,91,.32); }
.dpk-day.empty { visibility: hidden; pointer-events: none; }
.dpk-foot { display: flex; justify-content: center; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line-soft); }
.dpk-today { border: none; background: none; font-family: inherit; font-size: 13px; font-weight: 700; color: var(--green); cursor: pointer; padding: 4px 12px; border-radius: 8px; }
.dpk-today:hover { background: var(--green-tint); }
.legal-note { display: flex; gap: 10px; background: var(--gold-tint); border: 1px solid #e8d6a8; border-radius: var(--radius-sm); padding: 14px 16px; font-size: 13px; color: #6b5320; line-height: 1.6; }
.legal-note svg { flex-shrink: 0; color: #a9883f; margin-top: 2px; }

/* ---------- support: public requests & complaints (الدعم) ---------- */
.psup-tabs { display: flex; gap: 8px; margin-bottom: 18px; }
.psup-tab { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 16px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); color: var(--muted); font-family: inherit; font-size: 14.5px; font-weight: 700; cursor: pointer; transition: .18s; }
.psup-tab:hover { border-color: var(--gold-soft); color: var(--navy); }
.psup-tab.on { border-color: var(--navy); background: var(--navy); color: #fff; }
.psup-track-row { display: flex; gap: 12px; align-items: flex-end; }
.psup-track-row .field { margin: 0; }
.psup-cards { display: flex; flex-direction: column; gap: 12px; margin-top: 16px; }
.psup-card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.psup-card-head { width: 100%; display: flex; align-items: center; gap: 14px; padding: 16px 18px; background: none; border: none; cursor: pointer; text-align: start; font-family: inherit; }
.psup-card-head:hover { background: var(--bg-warm); }
.psup-card-main { flex: 1; min-width: 0; }
.psup-card-subj { font-size: 15.5px; font-weight: 800; color: var(--navy); margin-bottom: 6px; }
.psup-card-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.psup-ref { font-size: 12.5px; font-weight: 800; color: var(--navy); background: var(--gold-tint); padding: 2px 9px; border-radius: 7px; }
.psup-cat { font-size: 12px; font-weight: 700; color: var(--muted); background: var(--bg-warm); border: 1px solid var(--line); padding: 2px 9px; border-radius: 7px; }
.psup-date { font-size: 12px; color: var(--muted-2, var(--muted)); }
.psup-card-right { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.psup-chev { color: var(--muted); transition: transform .2s; }
.psup-chev.up { transform: rotate(180deg); }
.psup-badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 700; padding: 5px 11px; border-radius: 999px; white-space: nowrap; }
.psup-badge .d { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.psup-badge.new { color: #2c6fdb; background: #e7eefc; }
.psup-badge.view { color: #a9712a; background: #faf0df; }
.psup-badge.contact { color: #b4452f; background: #f7e7e2; }
.psup-badge.done { color: #2f7d5b; background: #e6f3ec; }
.psup-card-body { padding: 4px 18px 18px; border-top: 1px solid var(--line-soft); }
.psup-stages { display: flex; gap: 8px; margin: 16px 0; }
.psup-stage { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; color: var(--muted); text-align: center; }
.psup-stage-dot { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 800; background: var(--bg-warm); border: 1px solid var(--line); color: var(--muted); }
.psup-stage.done { color: var(--green); }
.psup-stage.done .psup-stage-dot { background: var(--green); border-color: var(--green); color: #fff; }
.psup-stage.current { color: var(--navy); }
.psup-stage.current .psup-stage-dot { background: var(--gold); border-color: var(--gold); color: #fff; }
.psup-followup { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: #6b5320; background: var(--gold-tint); border: 1px solid #e8d6a8; border-radius: var(--radius-sm); padding: 10px 13px; margin-bottom: 14px; }
.psup-thread { display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; }
.psup-thread-empty { font-size: 13px; color: var(--muted); text-align: center; padding: 14px; background: var(--bg-warm); border-radius: var(--radius-sm); }
.psup-msg { padding: 10px 13px; border-radius: 12px; max-width: 88%; }
.psup-msg.from-office { background: var(--navy); color: #fff; align-self: flex-start; border-bottom-right-radius: 4px; }
.psup-msg.from-me { background: var(--bg-warm); border: 1px solid var(--line); align-self: flex-end; border-bottom-left-radius: 4px; }
.psup-msg-meta { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: 11px; margin-bottom: 4px; opacity: .85; }
.psup-msg-meta b { font-weight: 800; }
.psup-msg.from-office .psup-msg-meta b { color: #fff; }
.psup-msg-text { font-size: 13.5px; line-height: 1.6; white-space: pre-wrap; }
.psup-reply { display: flex; gap: 8px; }
.psup-reply .inp { flex: 1; }
.psup-closed { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--green); background: var(--green-tint); border-radius: var(--radius-sm); padding: 11px 14px; }
.psup-empty { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 44px 20px; margin-top: 16px; color: var(--muted); background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); }
.psup-empty svg { color: var(--muted-2, var(--muted)); }
.psup-acct-note { display: flex; align-items: center; gap: 11px; background: var(--gold-tint); border: 1px solid #e8d6a8; border-radius: var(--radius-sm); padding: 11px 14px; margin-bottom: 16px; font-size: 13.5px; color: #6b5320; line-height: 1.5; }
.psup-acct-note b { color: var(--navy); }
.psup-acct-banner { display: flex; align-items: center; gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; margin-bottom: 14px; }
.psup-acct-banner > div { flex: 1; min-width: 0; line-height: 1.4; }
.psup-acct-banner b { display: block; font-size: 15px; color: var(--navy); font-weight: 800; }
.psup-acct-banner span { font-size: 12.5px; color: var(--muted); }
.psup-summary { display: flex; gap: 8px; margin-bottom: 14px; flex-wrap: wrap; }
.psup-sumchip { flex: 1; min-width: 78px; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 11px 8px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); cursor: pointer; font-family: inherit; transition: .16s; }
.psup-sumchip:hover { border-color: var(--gold-soft); }
.psup-sumchip.on { border-color: var(--navy); box-shadow: 0 0 0 1.5px var(--navy) inset; }
.psup-sumchip b { font-size: 20px; font-weight: 800; color: var(--navy); line-height: 1; }
.psup-sumchip span { font-size: 12px; color: var(--muted); }
.psup-signin-hint { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); margin: 12px 0 0; }
.psup-signin-hint a { color: var(--navy); font-weight: 800; text-decoration: underline; cursor: pointer; }
.psup-signin-hint svg { flex-shrink: 0; color: var(--muted-2, var(--muted)); }
/* email OTP verify gate */
.psup-verify-head { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 18px; }
.psup-verify-ico { flex-shrink: 0; width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--navy); color: #fff; }
.psup-verify-head h3 { font-size: 17px; font-weight: 800; color: var(--navy); margin: 2px 0 5px; }
.psup-verify-head p { font-size: 13.5px; color: var(--muted); line-height: 1.6; margin: 0; }
.psup-mock-mail { background: var(--bg-warm); border: 1px dashed var(--gold-soft); border-radius: var(--radius-sm); padding: 16px; margin: 4px 0 16px; text-align: center; }
.psup-mock-tag { display: inline-block; font-size: 11px; font-weight: 800; color: #6b5320; background: var(--gold-tint); border: 1px solid #e8d6a8; padding: 3px 10px; border-radius: 999px; margin-bottom: 10px; }
.psup-mock-mail p { font-size: 13px; color: var(--muted); margin: 0 0 8px; }
.psup-mock-mail b { color: var(--navy); }
.psup-mock-code { font-size: 32px; font-weight: 800; letter-spacing: 10px; color: var(--navy); font-family: var(--font-mono, ui-monospace, monospace); padding-inline-start: 10px; }
.psup-mock-mail span { display: block; font-size: 11.5px; color: var(--muted-2, var(--muted)); margin-top: 8px; }
.psup-err { display: flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 600; color: var(--red, #c0392b); margin: 12px 0 0; }
.psup-err svg { flex-shrink: 0; }
@media (max-width: 600px) {
  .psup-track-row { flex-direction: column; align-items: stretch; }
  .psup-card-head { flex-wrap: wrap; }
}

/* ---------- ejar / add form (multi-step) ---------- */
.form-page { padding: 36px 0 70px; }
.form-shell { display: grid; grid-template-columns: 250px 1fr; gap: 30px; align-items: start; }
.stepper { position: sticky; top: 92px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.stepper h3 { font-size: 16px; color: var(--navy); margin-bottom: 6px; }
.stepper > p { font-size: 13px; color: var(--muted); margin-bottom: 18px; }
.step-list { display: flex; flex-direction: column; gap: 2px; }
.step-item { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 11px; cursor: pointer; transition: none; }
.step-item:hover { background: var(--bg-warm); }
.step-item.active { background: var(--gold-tint); }
.step-item.done .step-dot { background: var(--green); color: #fff; border-color: var(--green); }
.step-item.active .step-dot { background: var(--navy); color: #fff; border-color: var(--navy); }
.step-dot { width: 30px; height: 30px; border-radius: 50%; border: 1.5px solid var(--line); display: grid; place-items: center; font-size: 13px; font-weight: 800; color: var(--muted); flex-shrink: 0; background: var(--surface); transition: all .2s; }
.step-item b { font-size: 14px; color: var(--ink); font-weight: 600; }
.step-item.active b { color: var(--navy); font-weight: 800; }
.form-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 30px 32px; }
.form-progress { height: 6px; background: var(--line-soft); border-radius: 999px; overflow: hidden; margin-bottom: 26px; }
.form-progress span { display: block; height: 100%; background: var(--gold); border-radius: 999px; transition: width .3s; }
.form-step-head { margin-bottom: 24px; }
.form-step-head .eyebrow { color: var(--gold); font-weight: 700; font-size: 13px; }
.form-step-head h2 { font-size: 24px; color: var(--navy); margin-top: 4px; }
.form-step-head p { color: var(--muted); margin-top: 6px; font-size: 14.5px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 18px; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px 18px; }
.col-span { grid-column: 1 / -1; }
.choice-grid { display: grid; gap: 10px; }
.choice-grid.cols-2 { grid-template-columns: 1fr 1fr; }
.choice-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.choice { display: flex; align-items: center; gap: 11px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); padding: 14px 16px; cursor: pointer; transition: all .15s; background: var(--surface); }
.choice:hover { border-color: var(--gold-soft); }
.choice.on { border-color: var(--gold); background: var(--gold-tint); }
.choice-radio { width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--line); box-sizing: border-box; flex-shrink: 0; display: grid; place-items: center; transition: all .15s; }
.choice.on .choice-radio { border-color: var(--gold); background: var(--gold); box-shadow: inset 0 0 0 1px var(--gold); }
.choice b { font-size: 15px; color: var(--ink); }
.choice span { font-size: 12.5px; color: var(--muted); display: block; }
.upload-box { border: 1.5px dashed var(--line); border-radius: var(--radius-sm); padding: 22px; text-align: center; cursor: pointer; transition: all .15s; }
.upload-box:hover { border-color: var(--gold); background: var(--gold-tint); }
.upload-box .up-ico { color: var(--gold); margin-bottom: 8px; display: flex; justify-content: center; }
.upload-box b { display: block; font-size: 14px; color: var(--navy); }
.upload-box span { font-size: 12.5px; color: var(--muted); }
.upload-box.filled { border-style: solid; padding: 12px; text-align: right; }
.upload-box.filled:hover { background: var(--surface); border-color: var(--gold-soft); }
.up-done { display: flex; align-items: center; gap: 12px; }
.up-thumb { width: 52px; height: 52px; border-radius: 9px; object-fit: cover; flex-shrink: 0; border: 1px solid var(--line); }
.up-fileico { width: 52px; height: 52px; border-radius: 9px; background: var(--gold-tint); color: var(--navy); display: grid; place-items: center; flex-shrink: 0; }
.up-info { flex: 1; min-width: 0; text-align: right; }
.up-info b { display: block; font-size: 13.5px; color: var(--navy); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 700; }
.up-size { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.up-size strong { color: var(--ink); }
.up-saved { color: #2f7d5b; background: #e6f1ea; font-style: normal; font-weight: 800; padding: 1px 6px; border-radius: 6px; margin-inline-start: 6px; font-size: 11px; }
.up-remove { width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); color: var(--muted); display: grid; place-items: center; flex-shrink: 0; }
.up-remove:hover { border-color: var(--danger); color: var(--danger); }
.check-row { display: flex; align-items: flex-start; gap: 11px; padding: 11px 0; cursor: pointer; }
.checkbox { width: 22px; height: 22px; border-radius: 6px; border: 2px solid var(--line); flex-shrink: 0; display: grid; place-items: center; color: #fff; transition: all .15s; margin-top: 1px; }
.check-row.on .checkbox { background: var(--green); border-color: var(--green); }
.check-row label { font-size: 14px; color: var(--ink); cursor: pointer; line-height: 1.55; }
.calc-box { background: var(--navy); color: #fff; border-radius: var(--radius); padding: 22px 24px; margin-top: 8px; }
.calc-row { display: flex; justify-content: space-between; align-items: baseline; gap: 6px 16px; flex-wrap: wrap; padding: 9px 0; font-size: 14.5px; color: #cfd6e0; }
.calc-row > span:first-child { min-width: 0; flex: 1 1 60%; }
.calc-row > span:last-child, .calc-row > b { flex-shrink: 0; text-align: end; white-space: nowrap; }
.calc-row.total { border-top: 1px solid rgba(255,255,255,.15); margin-top: 8px; padding-top: 16px; font-size: 17px; }
.calc-row.total b { color: var(--gold-soft); font-size: 24px; font-weight: 800; }
.form-nav { display: flex; justify-content: space-between; gap: 12px; margin-top: 30px; padding-top: 24px; border-top: 1px solid var(--line); flex-wrap: wrap; }
.form-success { text-align: center; padding: 40px 20px; }
.success-ico { width: 84px; height: 84px; border-radius: 50%; background: var(--green-tint); color: var(--green); display: grid; place-items: center; margin: 0 auto 22px; }
.success-ref { display: inline-flex; align-items: center; gap: 8px; background: var(--bg-warm); border: 1px solid var(--line); border-radius: 999px; padding: 9px 18px; font-weight: 700; color: var(--navy); margin: 16px 0 26px; }
.sub-block { background: var(--bg-warm); border: 1px solid var(--line-soft); border-radius: var(--radius-sm); padding: 18px 20px; margin-bottom: 18px; }
.sub-block > .sub-title { font-size: 13px; font-weight: 800; color: var(--gold); letter-spacing: .03em; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; }

/* ---------- generic page ---------- */
.simple-page { padding: 54px 0 70px; }
.page-hero { background: var(--navy); color: #fff; padding: 56px 0; text-align: center; }
.page-hero h1 { font-size: clamp(28px, 4vw, 42px); }
.page-hero p { color: #cfd6e0; margin-top: 12px; max-width: 56ch; margin-inline: auto; }

/* responsive */
@media (max-width: 980px) {
  .listings-layout { grid-template-columns: 1fr; }
  .filters-side { display: none; }
  .filters-toggle { display: inline-flex; }
  /* toolbar: wrap so nothing is pushed off-screen; filter button + view toggle on row 1, sort full-width on row 2 */
  .listings-toolbar { flex-wrap: wrap; gap: 10px; }
  .filters-toggle { order: 0; min-height: 44px; padding-inline: 16px; }
  .view-toggle { order: 1; margin-inline-start: auto; }
  .toolbar-sort { order: 2; flex: 1 1 100%; }
  .toolbar-sort .flt-select { min-width: 0; width: auto; flex: 1; }
  .listings-grid { grid-template-columns: repeat(2, 1fr); }
  .blog-grid { grid-template-columns: repeat(2, 1fr); }
  .detail-layout { grid-template-columns: 1fr; }
  .detail-aside { position: static; }
  .gallery { height: 340px; }
  .form-shell { grid-template-columns: 1fr; }
  /* السماح لعناصر الشبكة بالانكماش حتى يعمل التمرير الأفقي للخطوات ولا يتمدد العمود (إصلاح تجاوز الجوال) */
  .form-shell > .stepper, .form-shell > .form-card { min-width: 0; }
  .stepper .step-list { min-width: 0; }
  .stepper { position: static; }
  .stepper > p { margin-bottom: 12px; }
  .stepper .step-list { flex-direction: row; overflow-x: auto; gap: 6px; padding-bottom: 4px; -webkit-overflow-scrolling: touch; }
  .stepper .step-item { flex-direction: column; gap: 6px; min-width: 76px; text-align: center; padding: 10px 8px; flex-shrink: 0; }
  .stepper .step-item b { font-size: 11.5px; line-height: 1.25; }
  .fact-grid { grid-template-columns: repeat(2, 1fr); }
  .cards-grid, .svc-grid, .tst-grid, .band-grid, .steps-grid { grid-template-columns: repeat(2, 1fr); }
  .cat-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .search-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  /* هيدر جوال نظيف: شعار + زر قائمة فقط. اللغة والوضع الليلي داخل القائمة المنسدلة */
  .nav-links, .header-actions .btn, .header-actions .lang-pill, .header-actions .icon-toggle, .header-actions .acct-wrap { display: none; }
  .burger { display: inline-flex; }
  .header-row { gap: 12px; height: 64px; }
  .header-actions { margin-inline-start: auto; gap: 8px; }
  .logo-img { height: 40px; }
  .hero-inner { padding-block: 60px 96px; }
  .cards-grid, .svc-grid, .tst-grid, .steps-grid, .band-grid { grid-template-columns: 1fr; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .search-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 26px; }
  .band, .cta-strip { padding: 32px 24px; }
  .cta-strip { text-align: center; justify-content: center; }
  .section { padding: 52px 0; }
  .listings-grid { grid-template-columns: 1fr; }
  .list-row { grid-template-columns: 1fr; }
  .list-media { aspect-ratio: 16/9; }
  .list-info { padding: 18px 20px; }
  .gallery { grid-template-columns: 1fr; height: 260px; }
  .gallery-side { display: none; }
  .grid-2, .grid-3, .choice-grid.cols-2, .choice-grid.cols-3, .feat-grid { grid-template-columns: 1fr; }
  .fact-grid { grid-template-columns: repeat(2, 1fr); }
  .band[style] { grid-template-columns: 1fr !important; }
  .detail-title h1 { font-size: 23px; }
  .form-card { padding: 22px 18px; }
  .blog-feature { grid-template-columns: 1fr; }
  .blog-feature-media { min-height: 200px; aspect-ratio: 16/9; }
  .blog-feature-body { padding: 24px; }
  .blog-grid { grid-template-columns: 1fr; }
  .post-cta { flex-direction: column; align-items: flex-start; }
  /* أهداف لمس مريحة على الجوال (44px على الأقل) */
  .prop-foot .btn { min-height: 44px; }
  .agent-actions .btn-sm { min-height: 44px; }
}


/* ====== كاروسيل بطاقات العقار (قسم «أحدث العروض» بالرئيسية) ====== */
.carousel { position: relative; }
.carousel-track {
  display: flex; gap: 24px; overflow-x: auto; scroll-snap-type: x mandatory;
  scroll-behavior: smooth; -webkit-overflow-scrolling: touch;
  padding-block: 4px 8px; scrollbar-width: none; overscroll-behavior-x: contain;
}
.carousel-track::-webkit-scrollbar { display: none; }
.carousel-slide { flex: 0 0 32%; scroll-snap-align: start; } /* ~3 بطاقات + إطلالة على التالية */
.carousel-slide > .prop-card { height: 100%; }
.carousel-arrow {
  position: absolute; top: 40%; transform: translateY(-50%); z-index: 6;
  width: 46px; height: 46px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-lg);
  display: grid; place-items: center; cursor: pointer; color: var(--ink);
  transition: transform .15s, background .15s, color .15s, border-color .15s;
}
.carousel-arrow:hover { background: var(--navy); color: #fff; border-color: var(--navy); transform: translateY(-50%) scale(1.09); }
.carousel-arrow.prev { inset-inline-start: -10px; }
.carousel-arrow.next { inset-inline-end: -10px; }
@media (max-width: 1024px) { .carousel-slide { flex-basis: 46%; } } /* ~بطاقتان + إطلالة */
@media (max-width: 720px) {
  .carousel-arrow { display: none; } /* الجوال بالسحب */
  .carousel-slide { flex-basis: 82%; } /* بطاقة + إطلالة */
  .carousel-track { gap: 16px; }
}

/* ---- بطاقة بنر ترويجي (شريط «عروضنا» تحت مربّع البحث) ---- */
.banners-section { padding-block: 8px 0; }
.carousel-slide.banner-slide { flex-basis: 62%; } /* بنر عريض + إطلالة على التالي */
.banner-card {
  position: relative; overflow: hidden; border-radius: var(--radius);
  min-height: 210px; display: flex; align-items: flex-end;
  background: var(--navy); border: 1px solid var(--line);
  transition: transform .2s, box-shadow .2s;
}
.banner-card.is-link { cursor: pointer; }
.banner-card.is-link:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.banner-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.banner-overlay { position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(90deg, rgba(11,18,32,.86) 0%, rgba(11,18,32,.55) 55%, rgba(11,18,32,.18) 100%); }
.banner-body { position: relative; z-index: 2; padding: 24px 26px; color: #fff; max-width: 78%; }
.banner-title { font-size: clamp(19px, 2.4vw, 26px); font-weight: 800; color: #fff; letter-spacing: -.01em; }
.banner-sub { margin-top: 8px; font-size: 14.5px; line-height: 1.6; color: #dfe5ee; max-width: 42ch; }
.banner-body .btn { margin-top: 16px; }
@media (max-width: 1024px) { .carousel-slide.banner-slide { flex-basis: 86%; } }
@media (max-width: 720px) {
  .carousel-slide.banner-slide { flex-basis: 90%; }
  .banner-card { min-height: 180px; }
  .banner-body { padding: 20px; max-width: 88%; }
}

/* ===== شريط التواصل السريع الثابت (وضع البانرات «ثابتة») ===== */
/* شبكة ذكية: ٣ بطاقات تملأ العرض، وتتمدّد بطاقتان لملئه عند إقفال إحداها،
   وتنزل عموداً على الجوال (الأريح للإصبع). auto-fit يتكيّف مع العدد تلقائياً. */
.quick-contact { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.qc-tile {
  display: flex; align-items: center; gap: 15px; text-align: start;
  padding: 17px 20px; border-radius: var(--radius, 16px); min-width: 0; width: 100%; font: inherit;
  background: var(--surface, #fff); border: 1px solid var(--line, #e8e2d4);
  color: var(--ink, #16233d); cursor: pointer; text-decoration: none; position: relative; overflow: hidden;
  transition: transform .16s, box-shadow .16s, border-color .16s;
}
.qc-tile::after { content: ""; position: absolute; inset-inline-start: 0; top: 0; bottom: 0; width: 4px; background: var(--qc); opacity: .9; }
.qc-tile:hover { transform: translateY(-3px); box-shadow: 0 10px 30px rgba(13,22,38,.12); border-color: var(--qc); }
.qc-ic { flex: 0 0 auto; width: 52px; height: 52px; border-radius: 15px; display: grid; place-items: center; background: var(--qc-bg); color: var(--qc); }
.qc-ic svg { width: 26px; height: 26px; }
.qc-txt { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; min-width: 0; flex: 1; }
.qc-txt b { font-size: 16.5px; font-weight: 800; letter-spacing: -.01em; white-space: nowrap; color: var(--ink, #16233d); }
.qc-txt span { font-size: 14.5px; color: var(--muted, #7e8b9c); font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; text-align: start; }
.qc-call .qc-txt span { color: var(--ink, #16233d); opacity: .82; letter-spacing: .02em; }
.qc-arrow { margin-inline-start: auto; color: var(--muted, #7e8b9c); flex: 0 0 auto; opacity: .5; display: flex; transition: transform .16s, opacity .16s; }
.qc-tile:hover .qc-arrow { opacity: 1; transform: translateX(-4px); }
.qc-call { --qc: #4774ec; --qc-bg: rgba(71,116,236,.12); }
.qc-wa   { --qc: #1faa53; --qc-bg: rgba(37,211,102,.13); }
.qc-ejar { --qc: var(--gold, #c5a25a); --qc-bg: rgba(197,162,90,.15); }
@media (max-width: 560px) {
  .quick-contact { grid-template-columns: 1fr; gap: 12px; }
}


/* ====================== [2] لوحة التحكم (admin.css — مغلّفة .is-dash) ====================== */
/* ============================================================
   لوحة التحكم — مكتب الناصع
   تعتمد على متغيرات styles.css (navy/gold/...)
   ============================================================ */
:root {
  --side-w: 264px; --topbar-h: 68px;
  /* status palette (global so it works outside .dash too, e.g. client portal) */
  --s-new: #2c6fdb; --s-new-bg: #e7eefc;
  --s-contact: #8a6db5; --s-contact-bg: #f0eaf7;
  --s-view: #b07d2a; --s-view-bg: #f7eed8;
  --s-deal: #2f9e6b; --s-deal-bg: #e4f3ec;
  --s-done: #2f7d5b; --s-done-bg: #e6f1ea;
  --s-cancel: #b4452f; --s-cancel-bg: #f7e7e2;
  --s-wait: #6a7078; --s-wait-bg: #eef0f2;
}

/* status palette */
.is-dash .dash {
  --s-new: #2c6fdb; --s-new-bg: #e7eefc;
  --s-contact: #8a6db5; --s-contact-bg: #f0eaf7;
  --s-view: #b07d2a; --s-view-bg: #f7eed8;
  --s-deal: #2f9e6b; --s-deal-bg: #e4f3ec;
  --s-done: #2f7d5b; --s-done-bg: #e6f1ea;
  --s-cancel: #b4452f; --s-cancel-bg: #f7e7e2;
  --s-wait: #6a7078; --s-wait-bg: #eef0f2;
}

.is-dash .dash { display: grid; grid-template-columns: var(--side-w) 1fr; min-height: 100vh; background: var(--bg-warm); }

/* ---------- sidebar ---------- */
.is-dash .side { background: var(--navy); color: #cdd5df; display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; }
.is-dash .side-logo { display: flex; align-items: center; gap: 11px; padding: 20px 22px; border-bottom: 1px solid rgba(255,255,255,.08); cursor: pointer; }
.is-dash .side-logo .logo-mark { width: 40px; height: 40px; }
.is-dash .side-logo b { color: #fff; font-size: 16px; font-weight: 800; display: block; }
.is-dash .side-logo span { color: #8794a6; font-size: 10.5px; }
.is-dash .side-nav { padding: 16px 12px; display: flex; flex-direction: column; gap: 3px; flex: 1; overflow-y: auto; }
.is-dash .side-group { font-size: 11px; font-weight: 700; color: #6b7787; letter-spacing: .06em; padding: 14px 12px 6px; }
.is-dash .side-link { display: flex; align-items: center; gap: 12px; padding: 11px 13px; border-radius: 11px; font-size: 14.5px; font-weight: 600; color: #b9c2cf; cursor: pointer; transition: color .15s; border: none; background: none; width: 100%; text-align: right; }
.is-dash .side-link:hover { background: rgba(255,255,255,.06); color: #fff; }
.is-dash .side-link.active { background: var(--gold); color: #2a2008; }
.is-dash .side-link .badge-num { margin-inline-start: auto; background: rgba(255,255,255,.14); color: #fff; font-size: 11.5px; font-weight: 700; min-width: 22px; height: 22px; border-radius: 999px; display: grid; place-items: center; padding: 0 6px; }
.is-dash .side-link.active .badge-num { background: rgba(42,32,8,.18); color: #2a2008; }
.is-dash .side-foot { padding: 14px; border-top: 1px solid rgba(255,255,255,.08); }
.is-dash .side-user { display: flex; align-items: center; gap: 11px; padding: 8px; border-radius: 11px; }
.is-dash .side-user .av { width: 38px; height: 38px; border-radius: 11px; background: rgba(197,162,90,.18); color: var(--gold-soft); display: grid; place-items: center; flex-shrink: 0; }
.is-dash .side-user b { color: #fff; font-size: 13.5px; display: block; }
.is-dash .side-user span { color: #8794a6; font-size: 11.5px; }

/* ---------- main ---------- */
.is-dash .dash-main { display: flex; flex-direction: column; min-width: 0; }
.is-dash .topbar { height: var(--topbar-h); background: rgba(255,255,255,.9); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 16px; padding: 0 26px; position: sticky; top: 0; z-index: 40; }
.is-dash .topbar h1 { font-size: 20px; color: var(--navy); font-weight: 800; }
.is-dash .topbar-title { min-width: 0; flex: 1 1 auto; }
.is-dash .topbar-title h1 { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.is-dash .topbar .crumb { font-size: 12.5px; color: var(--muted); }
.is-dash .verified-pill { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 800; color: var(--green); background: #e6f1ea; border: 1px solid #c5e3d1; padding: 2px 8px; border-radius: 999px; margin-inline-start: 8px; vertical-align: middle; }
.is-dash .usage-block { display: inline-block; font-size: 10.5px; font-weight: 800; color: var(--danger); margin-top: 3px; }
/* trial control bar */
.is-dash .trial-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 14px 16px; margin-bottom: 16px; background: var(--gold-tint); border: 1px solid #e8d6a8; border-radius: var(--radius-sm); transition: opacity .15s; }
.is-dash .trial-bar.off { opacity: .7; }
.is-dash .trial-bar-main { display: flex; align-items: center; gap: 12px; }
.is-dash .trial-ico { width: 38px; height: 38px; border-radius: 11px; background: #fff; color: var(--gold-700,#a9883f); display: grid; place-items: center; flex-shrink: 0; }
.is-dash .trial-bar-main b { font-size: 14.5px; color: var(--navy); }
.is-dash .trial-bar-ctrls { display: flex; align-items: center; gap: 14px; }
.is-dash .trial-num { display: flex; flex-direction: column; gap: 4px; font-size: 12px; font-weight: 700; color: var(--navy); }
.is-dash .trial-num input { width: 88px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 9px; background: #fff; font-family: inherit; font-size: 14px; text-align: center; color: var(--ink); }
.is-dash .trial-num input:disabled { opacity: .5; }
/* plans editor (أسعار الباقات وحدودها) */
.is-dash .plans-editor { border: 1px solid var(--line); border-radius: 14px; margin-bottom: 16px; overflow: hidden; background: var(--surface); }
.is-dash .plans-editor-head { display: flex; align-items: center; gap: 12px; width: 100%; padding: 14px 16px; background: none; border: none; cursor: pointer; text-align: start; font-family: inherit; }
.is-dash .plans-editor-head > div { flex: 1; }
.is-dash .plans-editor-head b { font-size: 14.5px; color: var(--navy); }
.is-dash .plans-editor-chev { color: var(--muted); transition: transform .18s; }
.is-dash .plans-editor.open .plans-editor-chev { transform: rotate(180deg); }
.is-dash .plans-editor-body { padding: 4px 16px 16px; border-top: 1px solid var(--line); }
.is-dash .pe-grid { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.is-dash .pe-row { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 10px; align-items: center; }
.is-dash .pe-row.pe-head { font-size: 12px; font-weight: 700; color: var(--muted); padding-inline: 2px; }
.is-dash .pe-inp { width: 100%; padding: 9px 11px; border: 1px solid var(--line); border-radius: 9px; background: #fff; font-family: inherit; font-size: 14px; text-align: center; color: var(--navy); font-weight: 700; }
.is-dash .pe-inp.pe-name { text-align: start; font-weight: 800; }
.is-dash .pe-inp:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-tint); }
.is-dash .pe-unlim { text-align: center; font-size: 12.5px; font-weight: 800; color: var(--gold-700, #a9883f); }
.is-dash .pe-foot { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--line); }
.is-dash .pe-discount { display: flex; align-items: center; gap: 10px; font-size: 13.5px; font-weight: 700; color: var(--navy); }
.is-dash .pe-discount-inp { display: inline-flex; align-items: center; gap: 5px; font-weight: 800; }
.is-dash .pe-discount-inp .pe-inp { width: 72px; }
@media (max-width: 720px) { .is-dash .pe-row { grid-template-columns: 1fr; gap: 5px; } .is-dash .pe-row.pe-head { display: none; } }
/* payment modal */
.is-dash .pay-modal { position: fixed; top: 50%; inset-inline-start: 50%; transform: translate(-50%, -50%); width: 92%; max-width: 420px; max-height: 92vh; overflow-y: auto; background: var(--surface); border-radius: 20px; box-shadow: var(--shadow-lg); z-index: 95; padding: 22px 24px 24px; animation: acctPop .18s ease; }
html[dir="rtl"] .is-dash .pay-modal { transform: translate(50%, -50%); }
/* credit modal (#2) */
.is-dash .credit-modal { max-width: 560px; }
.is-dash .credit-cell { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; font-weight: 800; color: var(--gold-700,#a9883f); background: var(--gold-tint,#f7eed8); border: 1px solid #ecdcb6; border-radius: 999px; padding: 3px 11px; cursor: pointer; }
.is-dash .credit-cell:hover { background: #f1e3c4; }
.is-dash .credit-balance { display: flex; align-items: center; gap: 14px; background: var(--gold-tint,#f7eed8); border: 1px solid #ecdcb6; border-radius: 14px; padding: 16px 18px; margin-bottom: 14px; }
.is-dash .credit-balance-ic { width: 48px; height: 48px; border-radius: 12px; background: #fff; color: var(--gold-700,#a9883f); display: grid; place-items: center; }
.is-dash .credit-balance > div:nth-child(2) span { display: block; font-size: 12.5px; color: var(--muted); }
.is-dash .credit-balance > div:nth-child(2) b { font-size: 28px; color: var(--navy); font-weight: 800; }
.is-dash .credit-balance > div:nth-child(2) b small { font-size: 13px; font-weight: 600; color: var(--muted); }
.is-dash .credit-balance-cost { margin-inline-start: auto; font-size: 12px; font-weight: 700; color: var(--gold-700,#a9883f); text-align: end; }
.is-dash .credit-flash { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--navy); background: #eef4fb; border: 1px solid #d3e2f5; border-radius: 10px; padding: 9px 13px; margin-bottom: 12px; }
.is-dash .credit-tabs { margin-bottom: 14px; }
.is-dash .credit-body { max-height: 46vh; overflow-y: auto; }
.is-dash .credit-pkgs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.is-dash .credit-pkg { border: 1.5px solid var(--line); border-radius: 14px; padding: 16px 14px; text-align: center; }
.is-dash .credit-pkg-n { font-size: 26px; font-weight: 800; color: var(--navy); }
.is-dash .credit-pkg-n span { font-size: 12px; font-weight: 600; color: var(--muted); }
.is-dash .credit-pkg-p { font-size: 14px; font-weight: 700; color: var(--gold-700,#a9883f); margin: 4px 0 12px; }
.is-dash .credit-list { display: flex; flex-direction: column; gap: 8px; }
.is-dash .credit-row { display: flex; align-items: center; gap: 12px; border: 1px solid var(--line-soft); border-radius: 12px; padding: 11px 14px; }
.is-dash .credit-row-main { flex: 1; min-width: 0; }
.is-dash .credit-delta { font-size: 16px; font-weight: 800; }
.is-dash .credit-delta.up { color: var(--green,#2f7d5b); }
.is-dash .credit-delta.down { color: var(--danger,#b4452f); }
@media (max-width: 560px) { .is-dash .credit-pkgs { grid-template-columns: 1fr; } }
.is-dash .pay-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.is-dash .pay-head h2 { font-size: 20px; color: var(--navy); }
.is-dash .pay-sub { font-size: 13px; color: var(--muted); margin-top: 2px; }
.is-dash .pay-amount { text-align: center; background: var(--bg-warm); border: 1px solid var(--line); border-radius: 14px; padding: 18px; margin-bottom: 16px; }
.is-dash .pay-amount > span { font-size: 13px; color: var(--muted); display: block; }
.is-dash .pay-amount > b { font-size: 34px; font-weight: 900; color: var(--navy); display: block; margin: 4px 0 8px; }
.is-dash .pay-amount > b small { font-size: 15px; font-weight: 600; color: var(--muted); }
.is-dash .pay-plan-tag { display: inline-block; font-size: 12.5px; font-weight: 700; color: var(--gold-700,#a9883f); background: var(--gold-tint); padding: 4px 12px; border-radius: 999px; }
.is-dash .pay-methods { display: flex; gap: 8px; margin-bottom: 14px; }
.is-dash .pay-method { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 11px; border-radius: 11px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); font-size: 13px; font-weight: 700; cursor: pointer; font-family: inherit; }
.is-dash .pay-method.on { border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-tint); color: var(--navy); }
.is-dash .pay-card .field { margin-bottom: 12px; }
.is-dash .applepay-btn { width: 100%; padding: 15px; border: none; border-radius: 12px; background: #000; color: #fff; font-size: 17px; font-weight: 600; cursor: pointer; font-family: inherit; display: flex; align-items: center; justify-content: center; gap: 4px; }
.is-dash .applepay-btn:disabled { opacity: .6; }
.is-dash .pay-hint, .is-dash .pay-secure { display: flex; align-items: center; justify-content: center; gap: 6px; font-size: 12px; color: var(--muted); margin-top: 12px; }
.is-dash .pay-secure { margin-top: 16px; color: var(--green); }
.is-dash .pay-receipt { text-align: center; }
.is-dash .pay-ok-ico { width: 72px; height: 72px; border-radius: 50%; background: #e6f1ea; color: var(--green); display: grid; place-items: center; margin: 4px auto 14px; }
.is-dash .pay-receipt h2 { font-size: 22px; color: var(--navy); }
.is-dash .pay-receipt-sub { font-size: 13.5px; color: var(--muted); margin: 6px 0 18px; }
.is-dash .pay-receipt-box { text-align: start; background: var(--bg-warm); border: 1px solid var(--line); border-radius: 14px; padding: 8px 16px; margin-bottom: 18px; }
.is-dash .pay-receipt-box > div { display: flex; justify-content: space-between; align-items: center; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.is-dash .pay-receipt-box > div:last-child { border-bottom: none; }
.is-dash .pay-receipt-box span { color: var(--muted); }
.is-dash .pay-receipt-box b { color: var(--navy); }
.is-dash .top-search { margin-inline-start: auto; display: flex; align-items: center; gap: 9px; background: var(--bg-warm); border: 1px solid var(--line); border-radius: 999px; padding: 9px 16px; flex: 0 1 260px; min-width: 150px; color: var(--muted); }
.is-dash .top-search input { border: none; background: none; outline: none; font-size: 14px; width: 100%; color: var(--ink); }
.is-dash .top-icon { width: 42px; height: 42px; border-radius: 11px; border: 1px solid var(--line); background: var(--surface); display: grid; place-items: center; color: var(--ink); position: relative; }
.is-dash .top-icon .pip { position: absolute; top: 8px; inset-inline-end: 9px; width: 8px; height: 8px; border-radius: 50%; background: var(--gold); border: 2px solid #fff; }
.is-dash .dash-burger { display: none; }
.is-dash .dash-content { padding: 26px; flex: 1; }

/* ---------- stat cards ---------- */
.is-dash .stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.is-dash .stat-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.is-dash .stat-top { display: flex; align-items: center; justify-content: space-between; }
.is-dash .stat-ico { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; }
.is-dash .stat-card b { display: block; font-size: 30px; font-weight: 800; color: var(--navy); margin-top: 14px; line-height: 1; }
.is-dash .stat-card .lbl { font-size: 13.5px; color: var(--muted); margin-top: 6px; }
.is-dash .stat-delta { font-size: 12.5px; font-weight: 700; display: inline-flex; align-items: center; gap: 3px; padding: 3px 8px; border-radius: 999px; }
.is-dash .stat-delta.up { color: var(--s-done); background: var(--s-done-bg); }
.is-dash .stat-delta.down { color: var(--s-cancel); background: var(--s-cancel-bg); }

/* ---------- panels ---------- */
.is-dash .panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); min-width: 0; }
.is-dash .panel-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 18px 22px; border-bottom: 1px solid var(--line-soft); }
.is-dash .panel-head h2 { font-size: 17px; color: var(--navy); font-weight: 800; }
.is-dash .panel-head .sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.is-dash .panel-body { padding: 22px; }
.is-dash .two-col { display: grid; grid-template-columns: 1.6fr 1fr; gap: 18px; }
.is-dash .two-col > * { min-width: 0; }

/* ---------- chart (CSS bars) ---------- */
.is-dash .bars { display: flex; align-items: flex-end; gap: 12px; height: 200px; padding-top: 10px; }
.is-dash .bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 8px; height: 100%; justify-content: flex-end; }
.is-dash .bar { width: 100%; max-width: 38px; border-radius: 7px 7px 0 0; background: linear-gradient(var(--navy-700), var(--navy)); transition: height .5s ease; position: relative; }
.is-dash .bar.gold { background: linear-gradient(var(--gold-soft), var(--gold)); }
.is-dash .bar-col .v { font-size: 12px; font-weight: 700; color: var(--navy); }
.is-dash .bar-col .x { font-size: 12px; color: var(--muted); }

/* donut */
.is-dash .donut-wrap { display: flex; align-items: center; gap: 22px; }
.is-dash .donut { width: 140px; height: 140px; border-radius: 50%; flex-shrink: 0; position: relative; }
.is-dash .donut::after { content: ""; position: absolute; inset: 26px; background: var(--surface); border-radius: 50%; }
.is-dash .donut-center { position: absolute; inset: 0; display: grid; place-items: center; z-index: 1; text-align: center; }
.is-dash .donut-center b { font-size: 26px; font-weight: 800; color: var(--navy); }
.is-dash .donut-center span { font-size: 11.5px; color: var(--muted); display: block; }
.is-dash .legend { display: flex; flex-direction: column; gap: 11px; flex: 1; }
.is-dash .legend-row { display: flex; align-items: center; gap: 9px; font-size: 13.5px; }
.is-dash .legend-row .sw { width: 12px; height: 12px; border-radius: 4px; }
.is-dash .legend-row .val { margin-inline-start: auto; font-weight: 700; color: var(--navy); }

/* ---------- tables ---------- */
.is-dash .tbl-wrap, .is-dash .table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.is-dash .tbl, .is-dash .d-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.is-dash .d-table { min-width: 640px; }
.is-dash .d-table th { text-align: right; font-size: 12px; font-weight: 700; color: var(--muted); padding: 13px 16px; border-bottom: 1px solid var(--line); white-space: nowrap; background: var(--bg-warm); }
.is-dash .d-table td { padding: 14px 16px; border-bottom: 1px solid var(--line-soft); color: var(--ink); vertical-align: middle; }
.is-dash .d-table tbody tr:hover { background: var(--bg-warm); }
.is-dash .tbl th { text-align: right; font-size: 12px; font-weight: 700; color: var(--muted); padding: 13px 16px; border-bottom: 1px solid var(--line); white-space: nowrap; background: var(--bg-warm); }
.is-dash .tbl td { padding: 14px 16px; border-bottom: 1px solid var(--line-soft); color: var(--ink); vertical-align: middle; white-space: nowrap; }
.is-dash .tbl tr:last-child td { border-bottom: none; }
.is-dash .tbl tbody tr { transition: none; cursor: pointer; }
.is-dash .tbl tbody tr:hover { background: var(--bg-warm); }
.is-dash .tbl .muted { color: var(--muted); font-size: 13px; }
.is-dash .cell-main { font-weight: 700; color: var(--navy); }
.is-dash .cell-sub { font-size: 12.5px; color: var(--muted); }
.is-dash .cell-id { font-family: ui-monospace, monospace; font-size: 12.5px; color: var(--muted); }
.is-dash .cell-thumb { width: 52px; height: 40px; border-radius: 8px; overflow: hidden; flex-shrink: 0; }
.is-dash .views-cell { display: flex; flex-direction: column; gap: 2px; }
.is-dash .views-cell b { color: var(--navy); font-weight: 700; font-variant-numeric: tabular-nums; }
.is-dash .views-cell .v7 { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; color: var(--muted); }
.is-dash .views-cell .v7 svg { color: var(--gold); }
.is-dash .cell-upd { font-size: 12.5px; white-space: nowrap; }
.is-dash .ads-usage { min-width: 76px; }
.is-dash .ads-usage b { color: var(--navy); font-variant-numeric: tabular-nums; }
.is-dash .ads-usage b.over { color: var(--danger); }
.is-dash .usage-bar { height: 5px; border-radius: 3px; background: var(--line); margin-top: 5px; overflow: hidden; }
.is-dash .usage-bar span { display: block; height: 100%; border-radius: 3px; }
.is-dash .cell-flex { display: flex; align-items: center; gap: 11px; }

/* employees & permissions */
.is-dash .set-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 13px 15px; border: 1px solid var(--line); border-radius: var(--radius-sm); transition: opacity .2s; }
.is-dash .set-row.off { opacity: .62; background: var(--bg-warm); }
.is-dash .set-row b { font-size: 14.5px; color: var(--ink); font-weight: 700; }
.is-dash .set-req { display: inline-block; font-size: 11px; font-weight: 700; color: var(--muted); background: var(--bg-warm); padding: 2px 8px; border-radius: 999px; margin-inline-start: 8px; }
.is-dash .set-sub { display: block; font-size: 12.5px; color: var(--muted); margin-top: 2px; }
/* ترتيب روابط القائمة العلوية */
.is-dash .nav-order-main { display: flex; align-items: center; gap: 12px; }
.is-dash .nav-order-idx { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--navy); color: #fff; font-size: 12.5px; font-weight: 700; }
.is-dash .nav-order-btns { display: flex; gap: 6px; }
.is-dash .nav-order-btns .mini-btn:disabled { opacity: .35; cursor: not-allowed; }
/* radio-style selector (e.g. date calendar mode) — selected gets a filled dark dot */
.is-dash .set-radio { width: 22px; height: 22px; flex-shrink: 0; border: 2px solid var(--line); border-radius: 50%; display: grid; place-items: center; background: var(--surface); transition: border-color .15s ease, background .15s ease; }
.is-dash .set-row:not(.off) .set-radio { border-color: var(--navy); background: #fff; }
.is-dash .set-radio-dot { width: 11px; height: 11px; border-radius: 50%; background: var(--navy); }
.is-dash .fees-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.is-dash .fee-edit label { display: block; font-size: 13.5px; font-weight: 700; color: var(--ink); margin-bottom: 7px; }
.is-dash .fee-input { position: relative; display: flex; align-items: center; }
.is-dash .fee-input span { position: absolute; inset-inline-start: 12px; color: var(--muted); font-size: 13px; font-weight: 600; pointer-events: none; }
.is-dash .fee-input .inp { padding-inline-start: 44px; font-weight: 700; }
.is-dash .role-note { display: flex; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-inline-start: 4px solid var(--gold); border-radius: var(--radius); padding: 16px 20px; }
.is-dash .role-note-ic { width: 40px; height: 40px; border-radius: 11px; background: var(--gold-tint); color: var(--gold-700, #a9883f); display: grid; place-items: center; flex-shrink: 0; }
.is-dash .role-note b { color: var(--navy); font-size: 15px; }
.is-dash .role-note p { color: var(--muted); font-size: 13.5px; margin-top: 3px; line-height: 1.6; }
.is-dash .role-note p b { color: var(--ink); }
.is-dash .fee-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.is-dash .fee-row .k { font-size: 12px; color: var(--muted); }
.is-dash .fee-amount { font-size: 24px; font-weight: 800; color: var(--navy); margin-top: 2px; }
.is-dash .fee-amount span { font-size: 14px; font-weight: 600; color: var(--muted); }
.is-dash .emp-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; background: var(--surface); }
.is-dash .emp-top { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.is-dash .emp-av { width: 46px; height: 46px; border-radius: 13px; background: var(--navy); color: var(--gold); display: grid; place-items: center; font-weight: 800; font-size: 16px; flex-shrink: 0; }
.is-dash .emp-perms { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line-soft); }
.is-dash .emp-perms-label { font-size: 13px; font-weight: 700; color: var(--muted); }
.is-dash .perm-chip { display: inline-flex; align-items: center; gap: 6px; padding: 7px 13px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 13px; font-weight: 600; color: var(--muted); transition: all .14s; }
.is-dash .perm-chip:hover:not(:disabled) { border-color: var(--gold-soft); }
.is-dash .perm-chip.on { background: var(--gold-tint); border-color: var(--gold); color: var(--gold-700, #a9883f); }
.is-dash .toggle { width: 46px; height: 26px; border-radius: 999px; background: var(--line); border: none; position: relative; transition: none; flex-shrink: 0; }
.is-dash .toggle.on { background: var(--green); }
.is-dash .toggle-knob { position: absolute; top: 3px; inset-inline-start: 3px; width: 20px; height: 20px; border-radius: 50%; background: var(--surface); transition: transform .2s; box-shadow: var(--shadow-sm); }
.is-dash .toggle.on .toggle-knob { transform: translateX(-20px); }
.is-dash .spill { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 700; padding: 5px 11px; border-radius: 999px; white-space: nowrap; }
.is-dash .spill .d { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.is-dash .spill.new { color: var(--s-new); background: var(--s-new-bg); }
.is-dash .spill.contact { color: var(--s-contact); background: var(--s-contact-bg); }
.is-dash .spill.view { color: var(--s-view); background: var(--s-view-bg); }
.is-dash .spill.deal { color: var(--s-deal); background: var(--s-deal-bg); }
.is-dash .spill.done { color: var(--s-done); background: var(--s-done-bg); }
.is-dash .spill.cancel { color: var(--s-cancel); background: var(--s-cancel-bg); }
.is-dash .spill.wait { color: var(--s-wait); background: var(--s-wait-bg); }
.is-dash .spill.paid { color: var(--s-done); background: var(--s-done-bg); }
.is-dash .spill.partial { color: var(--s-view); background: var(--s-view-bg); }
.is-dash .spill.unpaid { color: var(--s-cancel); background: var(--s-cancel-bg); }

/* type tag */
.is-dash .ttag { font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 7px; background: var(--bg-warm); color: var(--ink-2, #41506a); border: 1px solid var(--line); }

/* row actions */
.is-dash .row-actions { display: flex; gap: 6px; }
.is-dash .mini-btn { width: 34px; height: 34px; border-radius: 9px; border: 1px solid var(--line); background: var(--surface); display: grid; place-items: center; color: var(--muted); transition: all .15s; }
.is-dash .mini-btn:hover { border-color: var(--navy); color: var(--navy); }
.is-dash .mini-btn.ok:hover { border-color: var(--s-done); color: var(--s-done); background: var(--s-done-bg); }
.is-dash .mini-btn.no:hover { border-color: var(--s-cancel); color: var(--s-cancel); background: var(--s-cancel-bg); }
.is-dash .mini-btn.star:hover, .is-dash .mini-btn.star.on { border-color: var(--gold); color: var(--gold); background: var(--gold-tint); }

/* filter chips bar */
.is-dash .chips-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 16px 22px; border-bottom: 1px solid var(--line-soft); }
.is-dash .chip { padding: 8px 15px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 13.5px; font-weight: 600; color: var(--muted); cursor: pointer; transition: all .15s; display: inline-flex; align-items: center; gap: 7px; }
.is-dash .chip:hover { border-color: var(--gold-soft); }
.is-dash .chip.on { background: var(--navy); color: #fff; border-color: var(--navy); }
.is-dash .chip .c { background: rgba(0,0,0,.12); font-size: 11px; padding: 1px 7px; border-radius: 999px; }
.is-dash .chip.on .c { background: rgba(255,255,255,.2); }

/* ===== الدعم والتذاكر ===== */
.is-dash .sup-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; padding: 18px 22px 4px; }
.is-dash .sup-kpi { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); cursor: pointer; text-align: start; transition: border-color .15s, box-shadow .15s; font-family: inherit; }
.is-dash .sup-kpi:hover { border-color: var(--gold-soft); }
.is-dash .sup-kpi.on { border-color: var(--navy); box-shadow: 0 0 0 2px var(--navy) inset; }
.is-dash .sup-kpi-ico { width: 42px; height: 42px; border-radius: 11px; display: grid; place-items: center; flex-shrink: 0; }
.is-dash .sup-kpi b { font-size: 22px; color: var(--navy); display: block; line-height: 1; }
.is-dash .sup-kpi span { font-size: 12.5px; color: var(--muted); }
.is-dash .chan-badge { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 700; padding: 3px 9px; border-radius: 999px; white-space: nowrap; }
.is-dash .chan-badge.phone { color: #a9712a; background: #faf0df; }
.is-dash .chan-badge.web { color: #2c6fdb; background: #e7eefc; }
.is-dash .cat-tag { font-size: 12px; font-weight: 700; color: var(--muted); background: var(--bg-warm); border: 1px solid var(--line); padding: 3px 10px; border-radius: 8px; white-space: nowrap; }
.is-dash .link-sub { font-size: 12.5px; font-weight: 800; color: var(--navy); background: var(--gold-tint); padding: 3px 9px; border-radius: 7px; }
.is-dash .unassigned-tag { font-size: 12px; font-weight: 700; color: #b4452f; }
.is-dash .prio-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #d4452f; margin-inline-start: 7px; vertical-align: middle; }
.is-dash .kv-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px dashed var(--line-soft); font-size: 13.5px; }
.is-dash .kv-row:last-child { border-bottom: none; }
.is-dash .kv-row > span { color: var(--muted); }
.is-dash .kv-row > b { color: var(--ink); font-weight: 700; }
/* stages */
.is-dash .stage-track { display: flex; flex-direction: column; gap: 8px; }
.is-dash .stage-step { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); font-size: 13.5px; font-weight: 600; color: var(--muted); cursor: pointer; font-family: inherit; text-align: start; }
.is-dash .stage-step .stage-dot { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-size: 11.5px; font-weight: 800; background: var(--bg-warm); color: var(--muted-2); border: 1px solid var(--line); flex-shrink: 0; }
.is-dash .stage-step.done { color: var(--navy); border-color: #c5e3d1; background: #f0f8f3; }
.is-dash .stage-step.done .stage-dot { background: var(--green); color: #fff; border-color: var(--green); }
.is-dash .stage-step.current { color: var(--navy); border-color: var(--gold); box-shadow: 0 0 0 2px var(--gold-tint); }
.is-dash .stage-step.current .stage-dot { background: var(--gold); color: #fff; border-color: var(--gold); }
/* thread */
.is-dash .thread { display: flex; flex-direction: column; gap: 10px; max-height: 360px; overflow-y: auto; padding: 2px; }
.is-dash .thread-item { padding: 10px 13px; border-radius: 12px; max-width: 90%; }
.is-dash .thread-item.from-emp { background: var(--navy); color: #fff; align-self: flex-start; border-bottom-right-radius: 4px; }
.is-dash .thread-item.from-cust { background: var(--bg-warm); border: 1px solid var(--line); align-self: flex-end; border-bottom-left-radius: 4px; }
.is-dash .thread-item.note { background: #fff8e6; border: 1px dashed #e3c977; align-self: stretch; max-width: 100%; }
.is-dash .thread-meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 11px; margin-bottom: 4px; opacity: .85; }
.is-dash .thread-item.from-emp .thread-meta b { color: #fff; }
.is-dash .thread-meta b { font-weight: 800; }
.is-dash .note-tag { display: inline-flex; align-items: center; gap: 4px; font-weight: 800; color: #a9712a; }
.is-dash .thread-text { font-size: 13.5px; line-height: 1.6; white-space: pre-wrap; }
/* reply row */
.is-dash .sup-foot { flex-direction: column; align-items: stretch; }
.is-dash .reply-row { display: flex; align-items: flex-end; gap: 8px; }
.is-dash .reply-row textarea.reply-text { min-height: 92px; resize: vertical; line-height: 1.6; padding: 10px 12px; }
.is-dash .reply-row .inp { flex: 1; }
.is-dash .reply-mode { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; padding: 9px 13px; border-radius: 10px; border: 1px solid var(--navy); background: var(--navy); color: #fff; font-size: 12.5px; font-weight: 700; cursor: pointer; font-family: inherit; }
.is-dash .reply-mode.note { background: #fff8e6; border-color: #e3c977; color: #a9712a; }
.is-dash .sup-drawer .drawer-body { display: flex; flex-direction: column; gap: 14px; }
.is-dash .sup-modal { max-width: 560px; }
.is-dash .sup-modal textarea.inp { resize: vertical; font-family: inherit; }
.is-dash .table-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 40px; color: var(--muted-2); }
@media (max-width: 700px) { .is-dash .sup-kpis { grid-template-columns: repeat(2, 1fr); } }

/* ---------- drawer (detail) ---------- */
.is-dash .dash-drawer-bg { position: fixed; inset: 0; background: rgba(14,26,43,.45); z-index: 90; animation: fade .2s; }
.is-dash .dash-drawer { position: fixed; top: 0; inset-inline-start: 0; height: 100%; width: 560px; max-width: 94vw; background: var(--bg-warm); z-index: 91; box-shadow: var(--shadow-lg); animation: slideIn .28s; display: flex; flex-direction: column; }
.is-dash .drawer-head { background: var(--surface); border-bottom: 1px solid var(--line); padding: 20px 24px; display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; position: sticky; top: 0; }
.is-dash .drawer-head h2 { font-size: 19px; color: var(--navy); }
.is-dash .drawer-scroll { overflow-y: auto; padding: 22px 24px; flex: 1; }
.is-dash .drawer-foot { background: var(--surface); border-top: 1px solid var(--line); padding: 16px 24px; display: flex; gap: 10px; }

/* detail blocks in drawer */
.is-dash .d-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; margin-bottom: 16px; }
.is-dash .d-card h3 { font-size: 14px; color: var(--gold); font-weight: 800; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; letter-spacing: .02em; }
.is-dash .kv { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 18px; }
.is-dash .kv-item .k { font-size: 12px; color: var(--muted); margin-bottom: 2px; }
.is-dash .kv-item .v { font-size: 14.5px; color: var(--ink); font-weight: 600; }
.is-dash .kv-item.full { grid-column: 1 / -1; }

/* ---- إضافة عقار: تحقّق وسحب من الهيئة (REGA) ---- */
.is-dash .verify-row { display: flex; gap: 8px; align-items: stretch; }
.is-dash .verify-row .inp { flex: 1; }
.is-dash .verify-btn { flex-shrink: 0; white-space: nowrap; align-self: stretch; }
.is-dash .field-hint { font-weight: 500; color: var(--muted); font-size: 12px; }
.is-dash .vstat { display: flex; align-items: center; gap: 7px; margin-top: 8px; font-size: 13px; font-weight: 600; line-height: 1.5; }
.is-dash .vstat.ok { color: #2f7d5b; }
.is-dash .vstat.bad { color: #b4452f; }
.is-dash .vstat em { font-style: normal; color: var(--muted); font-weight: 500; }
.is-dash .vstat svg { flex-shrink: 0; }
.is-dash .kv-item.pulled .v { display: flex; align-items: center; gap: 6px; color: var(--navy); }
.is-dash .kv-item.pulled .v svg { color: #2f7d5b; opacity: .8; }
.is-dash .kv-item.pulled { background: #f1f7f3; border: 1px solid #d6e8dd; border-radius: 9px; padding: 9px 12px; }
.is-dash .lock-tag { margin-inline-start: auto; font-size: 11px; font-weight: 700; color: #2f7d5b; background: #e6f1ea; border-radius: 999px; padding: 3px 10px; letter-spacing: 0; }
.is-dash .d-card h3 .lock-tag { text-transform: none; }
.is-dash .btn[disabled] { opacity: .45; pointer-events: none; }

/* بطاقة الممارس المسجّل */
.is-dash .d-card.practitioner { border: 1px solid #d6e8dd; background: linear-gradient(180deg,#f4faf6,#fff); }
.is-dash .d-card.practitioner.bad { border-color: #e8d2cc; background: linear-gradient(180deg,#fdf4f2,#fff); }
.is-dash .prac-head { display: flex; align-items: center; gap: 12px; }
.is-dash .prac-ico { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; background: #e6f1ea; color: #2f7d5b; flex-shrink: 0; }
.is-dash .d-card.practitioner.bad .prac-ico { background: #f6e3de; color: #b4452f; }
.is-dash .prac-name { font-weight: 800; color: var(--navy); font-size: 15px; }
.is-dash .prac-sub { font-size: 12px; color: var(--muted); margin-top: 2px; }
.is-dash .verified-chip { margin-inline-start: auto; display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 700; color: #2f7d5b; background: #e6f1ea; border-radius: 999px; padding: 5px 11px; white-space: nowrap; }
.is-dash .verified-chip.bad { color: #b4452f; background: #f6e3de; }

/* status pipeline (timeline) */
.is-dash .pipeline { display: flex; flex-direction: column; gap: 0; }
.is-dash .pl-step { display: flex; gap: 13px; position: relative; padding-bottom: 18px; }
.is-dash .pl-step:last-child { padding-bottom: 0; }
.is-dash .pl-step::before { content: ""; position: absolute; inset-inline-start: 13px; top: 28px; bottom: 0; width: 2px; background: var(--line); }
.is-dash .pl-step:last-child::before { display: none; }
.is-dash .pl-dot { width: 28px; height: 28px; border-radius: 50%; border: 2px solid var(--line); background: var(--surface); display: grid; place-items: center; flex-shrink: 0; z-index: 1; color: var(--muted); }
.is-dash .pl-step.done .pl-dot { background: var(--s-done); border-color: var(--s-done); color: #fff; }
.is-dash .pl-step.done::before { background: var(--s-done); }
.is-dash .pl-step.current .pl-dot { background: var(--navy); border-color: var(--navy); color: #fff; box-shadow: 0 0 0 4px rgba(22,38,63,.12); }
.is-dash .pl-step b { font-size: 14px; color: var(--ink); display: block; }
.is-dash .pl-step.pending b { color: var(--muted); }
.is-dash .pl-step span { font-size: 12px; color: var(--muted); }

/* status select control */
.is-dash .status-select { display: flex; flex-wrap: wrap; gap: 7px; }

/* segmented control for status change */
.is-dash .seg-status { display: flex; flex-wrap: wrap; gap: 6px; }

/* ---------- login (OTP) ---------- */
.is-dash .login-page { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.is-dash .login-aside { background: var(--navy); color: #fff; position: relative; overflow: hidden; padding: 56px; display: flex; flex-direction: column; justify-content: space-between; }
.is-dash .login-aside::after { content: ""; position: absolute; inset: 0; background: radial-gradient(600px 300px at 80% 90%, rgba(197,162,90,.2), transparent 60%); }
.is-dash .login-aside .la-top, .is-dash .login-aside .la-bot { position: relative; z-index: 1; }
.is-dash .login-aside h2 { font-size: 34px; font-weight: 800; max-width: 14ch; margin-top: 30px; }
.is-dash .login-aside p { color: #b6bfcc; margin-top: 14px; max-width: 40ch; }
.is-dash .la-feats { display: flex; flex-direction: column; gap: 14px; margin-top: 32px; }
.is-dash .la-feat { display: flex; align-items: center; gap: 12px; color: #e3e8ef; font-size: 15px; font-weight: 500; }
.is-dash .la-feat .ic { width: 38px; height: 38px; border-radius: 11px; background: rgba(197,162,90,.16); color: var(--gold-soft); display: grid; place-items: center; }
.is-dash .login-form-wrap { display: grid; place-items: center; padding: 40px; background: var(--bg-warm); }
.is-dash .login-card { width: 100%; max-width: 400px; }
.is-dash .login-card h1 { font-size: 26px; color: var(--navy); }
.is-dash .login-card > p { color: var(--muted); margin-top: 8px; margin-bottom: 28px; }
.is-dash .otp-inputs { display: flex; gap: 10px; direction: ltr; justify-content: center; margin: 8px 0 20px; }
.is-dash .otp-box { width: 54px; height: 62px; border: 1.5px solid var(--line); border-radius: 13px; text-align: center; font-size: 26px; font-weight: 800; color: var(--navy); background: var(--surface); outline: none; transition: all .15s; }
.is-dash .otp-box:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(197,162,90,.18); }
.is-dash .otp-box.filled { border-color: var(--navy); }
.is-dash .login-role { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 20px; }
.is-dash .role-pick { border: 1.5px solid var(--line); border-radius: 13px; padding: 14px; cursor: pointer; transition: all .15s; text-align: center; background: var(--surface); }
.is-dash .role-pick:hover { border-color: var(--gold-soft); }
.is-dash .role-pick.on { border-color: var(--gold); background: var(--gold-tint); }
.is-dash .role-pick .ic { color: var(--navy); margin-bottom: 6px; display: flex; justify-content: center; }
.is-dash .role-pick b { font-size: 14px; color: var(--ink); display: block; }
.is-dash .role-pick span { font-size: 11.5px; color: var(--muted); }
.is-dash .resend { text-align: center; font-size: 13.5px; color: var(--muted); margin-top: 16px; }
.is-dash .resend a { color: var(--navy); font-weight: 700; cursor: pointer; }

/* phone + password fields */
.is-dash .phone-input { position: relative; display: flex; align-items: center; }
.is-dash .phone-flag { position: absolute; inset-inline-start: 12px; display: flex; align-items: center; gap: 5px; font-size: 14px; color: var(--ink); font-weight: 700; pointer-events: none; }
.is-dash .phone-flag b { color: var(--muted); font-weight: 700; }
.is-dash .phone-field { padding-inline-start: 78px; direction: ltr; text-align: left; letter-spacing: .04em; }
.is-dash .phone-ok { position: absolute; inset-inline-end: 12px; color: var(--green); display: grid; place-items: center; }
.is-dash .phone-bad { position: absolute; inset-inline-end: 12px; color: var(--danger); display: grid; place-items: center; }
.is-dash .pass-toggle { position: absolute; inset-inline-end: 10px; background: none; border: none; color: var(--muted); display: grid; place-items: center; padding: 6px; border-radius: 8px; }
.is-dash .pass-toggle:hover { color: var(--navy); background: var(--bg-warm); }
.is-dash .login-err { display: flex; align-items: center; gap: 8px; background: var(--s-cancel-bg); color: var(--s-cancel); border: 1px solid #e9c4ba; border-radius: 11px; padding: 11px 14px; font-size: 13.5px; font-weight: 600; margin-bottom: 14px; }

/* demo accounts */
.is-dash .demo-box { margin-top: 22px; background: var(--bg-warm); border: 1px dashed var(--line); border-radius: 14px; padding: 14px; }
.is-dash .demo-title { font-size: 12px; font-weight: 700; color: var(--muted); display: flex; align-items: center; gap: 6px; margin-bottom: 10px; }
.is-dash .demo-row { display: flex; align-items: center; justify-content: space-between; width: 100%; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 9px 13px; font-size: 13.5px; font-weight: 700; color: var(--navy); margin-bottom: 7px; transition: all .14s; }
.is-dash .demo-row:last-child { margin-bottom: 0; }
.is-dash .demo-row:hover { border-color: var(--gold); background: var(--gold-tint); }
.is-dash .demo-row .demo-role { font-size: 12px; font-weight: 600; color: var(--muted); }

/* my-requests portal */
.is-dash .portal-head { background: var(--navy); color: #fff; padding: 34px 0; }
.is-dash .req-list { display: flex; flex-direction: column; gap: 14px; }
.is-dash .req-item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; display: grid; grid-template-columns: auto 1fr auto; gap: 16px; align-items: center; cursor: pointer; transition: box-shadow .2s, border-color .2s; }
.is-dash .req-item:hover { box-shadow: var(--shadow); border-color: var(--gold-soft); }
.is-dash .req-ico { width: 48px; height: 48px; border-radius: 13px; background: var(--gold-tint); color: var(--navy); display: grid; place-items: center; }

/* ---------- broker subscription status card (بطاقة اشتراك الوسيط) ---------- */
.is-dash .broker-sub { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; margin-bottom: 22px; box-shadow: var(--shadow-sm, 0 1px 2px rgba(20,42,82,.05)); position: relative; overflow: hidden; }
.is-dash .broker-sub::before { content: ""; position: absolute; inset-block: 0; inset-inline-start: 0; width: 4px; background: var(--gold); }
.is-dash .broker-sub.alert::before { background: #d98a3a; }
.is-dash .broker-sub-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.is-dash .broker-sub-id { display: flex; align-items: center; gap: 13px; min-width: 0; }
.is-dash .broker-sub-ic { width: 46px; height: 46px; flex-shrink: 0; border-radius: 13px; background: var(--gold-tint); color: var(--gold); display: grid; place-items: center; }
.is-dash .broker-sub-plan { font-size: 17px; font-weight: 800; color: var(--navy); }
.is-dash .broker-sub-office { font-size: 13px; color: var(--muted); margin-top: 2px; }
.is-dash .broker-sub-meter { background: var(--bg-warm); border: 1px solid var(--line-soft); border-radius: var(--radius-sm); padding: 15px 16px; margin-bottom: 16px; }
.is-dash .broker-sub-meter-top { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 9px; }
.is-dash .broker-sub-meter-top span { font-size: 13.5px; color: var(--muted); font-weight: 600; }
.is-dash .broker-sub-meter-top b { font-size: 20px; font-weight: 800; color: var(--navy); }
.is-dash .broker-sub-meter-top b small { font-size: 13px; font-weight: 600; color: var(--muted); }
.is-dash .broker-sub-bar { height: 9px; border-radius: 999px; background: var(--line); overflow: hidden; }
.is-dash .broker-sub-bar > span { display: block; height: 100%; border-radius: 999px; background: var(--green); transition: width .4s ease; }
.is-dash .broker-sub-bar > span.warn { background: #d98a3a; }
.is-dash .broker-sub-bar > span.danger { background: var(--s-cancel); }
.is-dash .broker-sub-meter-foot { margin-top: 9px; font-size: 13px; color: var(--muted); }
.is-dash .broker-sub-meter-foot b { color: var(--navy); font-weight: 800; }
.is-dash .broker-sub-meter-foot .ok { color: var(--green); font-weight: 700; display: inline-flex; align-items: center; gap: 5px; }
.is-dash .broker-sub-meter-foot .warn { color: #c47a2c; font-weight: 700; }
.is-dash .broker-sub-meter-foot .danger { color: var(--s-cancel); font-weight: 700; display: inline-flex; align-items: center; gap: 5px; }
.is-dash .broker-sub-facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 18px; }
.is-dash .broker-sub-fact { background: var(--bg-warm); border: 1px solid var(--line-soft); border-radius: var(--radius-sm); padding: 12px 14px; }
.is-dash .broker-sub-fact span { display: block; font-size: 12px; color: var(--muted); margin-bottom: 4px; }
.is-dash .broker-sub-fact b { font-size: 15px; font-weight: 800; color: var(--navy); }
.is-dash .broker-sub-fact b.on { color: var(--green); }
.is-dash .broker-sub-fact b.off { color: var(--s-cancel); }
.is-dash .broker-sub-actions { display: flex; flex-wrap: wrap; gap: 10px; }
@media (max-width: 560px) { .is-dash .broker-sub-facts { grid-template-columns: 1fr; } }

/* empty / utility */
.is-dash .dash-empty { text-align: center; padding: 60px 20px; color: var(--muted); }
.is-dash .dash-empty .ic { width: 64px; height: 64px; border-radius: 50%; background: var(--bg-warm); display: grid; place-items: center; margin: 0 auto 16px; }

/* ---------- responsive ---------- */
@keyframes sideIn { from { transform: translateX(100%); } to { transform: translateX(0); } }
@media (max-width: 1080px) { .is-dash .two-col { grid-template-columns: 1fr; } .is-dash .stat-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 860px) {
  .is-dash .dash { grid-template-columns: 1fr; }
  .is-dash .side { display: none; }
  .is-dash .dash.side-open .side { display: flex; position: fixed; top: 0; right: 0; left: auto; bottom: 0; width: min(284px, 85vw); height: 100%; z-index: 95; box-shadow: var(--shadow-lg); animation: sideIn .24s ease; }
  .is-dash .dash.side-open .side-scrim { position: fixed; inset: 0; background: rgba(14,26,43,.5); z-index: 94; animation: fade .2s; }
  .is-dash .dash-burger { display: grid; }
  .is-dash .top-search { display: none; }
  .is-dash .topbar-title { flex: 1; }
  .is-dash .login-page { grid-template-columns: 1fr; }
  .is-dash .login-aside { display: none; }
  /* content reflow */
  .is-dash .view-head { flex-direction: column; align-items: stretch; gap: 12px; }
  .is-dash .rep-tools { flex-wrap: wrap; }
  .is-dash .rep-tools .btn { flex: 1; }
  .is-dash .reports-layout { grid-template-columns: 1fr; }
  .is-dash .rep-builder { position: static; }
  .is-dash .filters-toolbar { gap: 8px; }
  .is-dash .filters-toolbar .flt-select { flex: 1; min-width: 0; width: auto !important; }
  .is-dash .period-tag { width: 100%; margin: 0; }
  .is-dash .perf-grid { grid-template-columns: repeat(2, 1fr); }
  .is-dash .panel-head { flex-wrap: wrap; }
}
@media (max-width: 620px) {
  .is-dash .stat-grid { grid-template-columns: 1fr 1fr; }
  .is-dash .perf-grid { grid-template-columns: 1fr; }
  .is-dash .brk-row { grid-template-columns: 100px 1fr auto; }
  .is-dash .mini-kv { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .is-dash .stat-grid { grid-template-columns: 1fr; }
  .is-dash .dash-content { padding: 16px; }
  .is-dash .otp-box { width: 44px; height: 54px; font-size: 22px; }
  .is-dash .dash-drawer { width: 100%; }
  .is-dash .login-role { grid-template-columns: 1fr; }
  .is-dash .fees-grid { grid-template-columns: 1fr; }
  .is-dash .emp-top { align-items: flex-start; }
  .is-dash .kv { grid-template-columns: 1fr; }
  .is-dash .donut-wrap { flex-direction: column; align-items: flex-start; }
  .is-dash .topbar { padding: 0 14px; gap: 8px; }
  .is-dash .topbar h1 { font-size: 16px; }
  .is-dash .panel-head { padding: 14px 16px; flex-wrap: wrap; gap: 10px; }
  .is-dash .panel-body { padding: 16px; }
  .is-dash .chips-bar { padding: 14px 16px; gap: 6px; }
  .is-dash .chip { padding: 7px 12px; font-size: 12.5px; }
  .is-dash .role-note { flex-direction: row; }
  .is-dash .login-card h1 { font-size: 22px; }
  /* tighter tables — let them scroll, smaller padding */
  .is-dash .tbl th, .is-dash .tbl td { padding: 11px 12px; font-size: 13px; }
  .is-dash .seg { width: 100%; overflow-x: auto; }
  .is-dash .seg-btn { flex: 1; white-space: nowrap; padding: 8px 12px; }
  .is-dash .filters-toolbar { flex-direction: column; align-items: stretch; }
  .is-dash .filters-toolbar .flt-select { width: 100% !important; }
  .is-dash .rep-paper-head { flex-direction: column; align-items: flex-start; gap: 12px; }
  .is-dash .rep-paper-head > div[style] { text-align: right !important; }
  .is-dash .mini-kv { grid-template-columns: 1fr; }
  .is-dash .brk-row { grid-template-columns: 84px 1fr auto; gap: 8px; }
  .is-dash .brk-label { font-size: 12px; }
  .is-dash .notif-row { align-items: flex-start; }
  .is-dash .notif-status { display: none; }
  .is-dash .view-title { font-size: 19px; }
  .is-dash .bm-card { grid-template-columns: 72px 1fr; }
  .is-dash .bm-actions { flex-direction: row; grid-column: 1 / -1; justify-content: flex-end; }
  .is-dash .perf-stats { gap: 4px; }
  .is-dash .ps b { font-size: 17px; }
}
@media (max-width: 760px) {
  .is-dash .fees-grid { grid-template-columns: 1fr 1fr; }
  .is-dash .two-col { grid-template-columns: 1fr; }
}

/* ============================================================
   لوحة موسّعة — مالية · أداء · إشعارات · تقارير
   ============================================================ */
.is-dash .view-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.is-dash .view-title { font-size: 21px; color: var(--navy); font-weight: 800; }
.is-dash .view-sub { color: var(--muted); font-size: 13.5px; margin-top: 3px; }
.is-dash .rep-tools { display: flex; gap: 8px; flex-wrap: wrap; }

/* info dot (شرح للمستخدم) */
.is-dash .infodot-wrap { position: relative; display: inline-flex; vertical-align: middle; margin-inline-start: 6px; }
.is-dash .infodot { width: 22px; height: 22px; border-radius: 50%; border: 1px solid var(--line); background: var(--bg-warm); color: var(--muted); display: grid; place-items: center; padding: 0; transition: all .15s; }
.is-dash .infodot:hover { border-color: var(--gold); color: var(--gold); background: var(--gold-tint); }
.is-dash .infodot-pop { position: absolute; top: calc(100% + 8px); inset-inline-end: -6px; z-index: 50; width: 260px; background: var(--navy); color: #fff; border-radius: 12px; padding: 13px 15px; box-shadow: var(--shadow-lg); font-size: 12.5px; line-height: 1.65; font-weight: 400; animation: fadeUp .15s ease; }
.is-dash .infodot-pop b { display: block; color: var(--gold-soft); font-size: 13px; margin-bottom: 5px; font-weight: 800; }
.is-dash .infodot-pop::before { content: ""; position: absolute; bottom: 100%; inset-inline-end: 14px; border: 7px solid transparent; border-bottom-color: var(--navy); }

/* alert bars */
.is-dash .alert-bar { display: flex; align-items: center; gap: 11px; background: #f7e7e2; border: 1px solid #e6c4b8; color: #8a3a26; border-radius: var(--radius); padding: 13px 18px; font-size: 14px; margin-bottom: 18px; }
.is-dash .alert-bar b { color: #7a2e1c; }
.is-dash .alert-bar svg { flex-shrink: 0; }
.is-dash .sms-note { display: flex; align-items: center; gap: 10px; background: var(--gold-tint); border: 1px solid #e8d6a8; color: #6b5320; border-radius: var(--radius-sm); padding: 12px 16px; font-size: 13.5px; margin-bottom: 6px; }
.is-dash .sms-note svg { flex-shrink: 0; color: #a9883f; }

/* cashflow chart */
.is-dash .cf-chart { padding-top: 6px; }
.is-dash .cf-legend { display: flex; align-items: center; gap: 18px; margin-top: 14px; font-size: 13px; color: var(--ink); }
.is-dash .cf-legend span { display: inline-flex; align-items: center; gap: 7px; }
.is-dash .cf-legend i { width: 12px; height: 12px; border-radius: 4px; display: inline-block; }

/* breakdown bars */
.is-dash .brk-list { display: flex; flex-direction: column; gap: 14px; }
.is-dash .brk-row { display: grid; grid-template-columns: 130px 1fr auto; align-items: center; gap: 12px; }
.is-dash .brk-label { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink); font-weight: 600; }
.is-dash .brk-label i { width: 10px; height: 10px; border-radius: 3px; flex-shrink: 0; }
.is-dash .brk-bar { height: 9px; background: var(--bg-warm); border-radius: 999px; overflow: hidden; }
.is-dash .brk-bar span { display: block; height: 100%; border-radius: 999px; transition: width .5s; }
.is-dash .brk-val { font-size: 14px; font-weight: 800; color: var(--navy); white-space: nowrap; }

/* mini key-values */
.is-dash .mini-kv { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.is-dash .mkv { background: var(--bg-warm); border-radius: var(--radius-sm); padding: 16px; }
.is-dash .mkv span { font-size: 12.5px; color: var(--muted); display: block; margin-bottom: 5px; }
.is-dash .mkv b { font-size: 22px; color: var(--navy); font-weight: 800; }

/* filters toolbar + segmented */
.is-dash .filters-toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.is-dash .seg { display: inline-flex; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.is-dash .seg-btn { border: none; background: transparent; padding: 8px 16px; border-radius: 999px; font-size: 13.5px; font-weight: 700; color: var(--muted); transition: all .15s; }
.is-dash .seg-btn.on { background: var(--navy); color: #fff; }
.is-dash .period-tag { margin-inline-start: auto; font-size: 13px; color: var(--muted); font-weight: 600; }

/* performance cards */
.is-dash .perf-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 18px; }
.is-dash .perf-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.is-dash .perf-top { display: flex; align-items: center; gap: 11px; margin-bottom: 14px; }
.is-dash .perf-av { width: 44px; height: 44px; border-radius: 12px; background: var(--navy); color: var(--gold-soft); display: grid; place-items: center; font-weight: 800; font-size: 18px; flex-shrink: 0; }
.is-dash .perf-av.sm { width: 34px; height: 34px; font-size: 14px; border-radius: 9px; }
.is-dash .perf-top b { display: block; font-size: 15px; color: var(--navy); }
.is-dash .perf-top span { font-size: 12px; color: var(--muted); }
.is-dash .perf-rate { font-size: 18px; font-weight: 800; padding: 4px 11px; border-radius: 999px; }
.is-dash .perf-rate.good { color: var(--green); background: var(--green-tint); }
.is-dash .perf-rate.mid { color: #b07d2a; background: #f7eed8; }
.is-dash .perf-rate.low { color: var(--danger); background: #f7e7e2; }
.is-dash .perf-prog { height: 7px; background: var(--bg-warm); border-radius: 999px; overflow: hidden; margin-bottom: 16px; }
.is-dash .perf-prog span { display: block; height: 100%; background: var(--gold); border-radius: 999px; transition: width .5s; }
.is-dash .perf-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; padding-bottom: 14px; border-bottom: 1px solid var(--line-soft); }
.is-dash .ps { text-align: center; }
.is-dash .ps b { display: block; font-size: 19px; font-weight: 800; }
.is-dash .ps span { font-size: 11px; color: var(--muted); }
.is-dash .perf-foot { display: flex; gap: 16px; margin-top: 12px; }
.is-dash .perf-foot span { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--ink); font-weight: 600; }
.is-dash .perf-foot svg { color: var(--gold); }

/* table progress + totals */
.is-dash .tbl-prog { width: 64px; height: 7px; background: var(--bg-warm); border-radius: 999px; overflow: hidden; display: inline-block; vertical-align: middle; }
.is-dash .tbl-prog span { display: block; height: 100%; border-radius: 999px; }
.is-dash .tbl-prog-val { font-size: 12.5px; font-weight: 700; color: var(--navy); margin-inline-start: 8px; }
.is-dash .tbl-total td { background: var(--bg-warm); border-top: 2px solid var(--line); }

/* notifications */
.is-dash .notif-feed { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; }
.is-dash .notif-row { display: flex; align-items: center; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 15px 18px; cursor: pointer; transition: box-shadow .15s, border-color .15s; }
.is-dash .notif-row:hover { box-shadow: var(--shadow); }
.is-dash .notif-row.unread { border-inline-start: 3px solid var(--gold); background: #fffdf8; }
.is-dash .notif-ic { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; }
.is-dash .notif-ic.new { background: var(--s-new-bg); color: var(--s-new); }
.is-dash .notif-ic.contact { background: var(--s-contact-bg); color: var(--s-contact); }
.is-dash .notif-ic.view { background: var(--s-view-bg); color: var(--s-view); }
.is-dash .notif-ic.deal { background: var(--s-deal-bg); color: var(--s-deal); }
.is-dash .notif-body { flex: 1; min-width: 0; }
.is-dash .notif-title { font-size: 14.5px; font-weight: 700; color: var(--ink); display: flex; align-items: center; gap: 8px; }
.is-dash .notif-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--gold); flex-shrink: 0; }
.is-dash .notif-meta { display: flex; align-items: center; gap: 14px; margin-top: 5px; flex-wrap: wrap; }
.is-dash .notif-meta span { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--muted); }
.is-dash .notif-status { font-size: 12px; color: var(--green); font-weight: 700; white-space: nowrap; }

/* reports */
.is-dash .reports-layout { display: grid; grid-template-columns: 320px 1fr; gap: 20px; align-items: start; margin-top: 8px; }
.is-dash .rep-builder { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; position: sticky; top: 86px; }
.is-dash .rep-builder h3 { font-size: 14px; color: var(--navy); font-weight: 800; margin-bottom: 12px; }
.is-dash .rep-types { display: flex; flex-direction: column; gap: 8px; }
.is-dash .rep-type { display: flex; align-items: center; gap: 11px; border: 1.5px solid var(--line); background: var(--surface); border-radius: var(--radius-sm); padding: 11px 13px; cursor: pointer; transition: all .15s; text-align: right; }
.is-dash .rep-type:hover { border-color: var(--gold-soft); }
.is-dash .rep-type.on { border-color: var(--gold); background: var(--gold-tint); }
.is-dash .rt-ic { width: 36px; height: 36px; border-radius: 10px; background: var(--bg-warm); color: var(--navy); display: grid; place-items: center; flex-shrink: 0; }
.is-dash .rep-type.on .rt-ic { background: var(--surface); color: var(--gold-700, #a9883f); }
.is-dash .rep-type b { display: block; font-size: 13.5px; color: var(--ink); }
.is-dash .rep-type span { font-size: 11.5px; color: var(--muted); }
.is-dash .rep-fields { display: flex; flex-direction: column; gap: 11px; }
.is-dash .rep-field { display: flex; flex-direction: column; gap: 5px; }
.is-dash .rep-field span { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.is-dash .rep-preview { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 28px; }
.is-dash .rep-paper-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding-bottom: 18px; border-bottom: 2px solid var(--navy); }
.is-dash .rep-table th { background: var(--navy); color: #fff; }
.is-dash .rep-table th:first-child { border-radius: 0 8px 0 0; }
.is-dash .rep-table th:last-child { border-radius: 8px 0 0 0; }
.is-dash .rep-foot { margin-top: 22px; padding-top: 16px; border-top: 1px dashed var(--line); font-size: 12px; color: var(--muted); text-align: center; }
.is-dash .rep-hint { font-size: 12px; color: var(--muted-2); margin-bottom: 12px; margin-top: -4px; }
.is-dash .rep-field-off { font-size: 12.5px; color: var(--muted); background: var(--bg-warm); border: 1px dashed var(--line); border-radius: var(--radius-sm); padding: 12px 14px; text-align: center; }
.is-dash .rep-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 16px 0; }
.is-dash .rep-count { font-size: 13px; font-weight: 800; color: var(--navy); background: var(--gold-tint); padding: 5px 12px; border-radius: 999px; }
.is-dash .rep-chip { font-size: 12.5px; font-weight: 600; color: var(--ink); background: var(--bg-warm); border: 1px solid var(--line); padding: 5px 12px; border-radius: 999px; }
.is-dash .rep-chip.muted-chip { color: var(--muted); }

/* content editor */
.is-dash .badge-mode { font-size: 12px; font-weight: 700; color: var(--navy); background: var(--gold-tint); border: 1px solid #e8d6a8; padding: 5px 12px; border-radius: 999px; }
.is-dash .content-edit { border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; background: var(--bg-warm); }
.is-dash .ce-head { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 800; color: var(--gold-700, #a9883f); margin-bottom: 14px; }
.is-dash .ce-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 14px; }
.is-dash .ce-stat { display: flex; flex-direction: column; gap: 6px; }
.is-dash .ce-stat .inp { padding: 9px 11px; font-size: 13.5px; }
.is-dash .ce-stat .inp:first-child { font-weight: 800; color: var(--navy); }
@media (max-width: 760px) { .is-dash .ce-stats { grid-template-columns: 1fr 1fr; } }

/* blog manager */
.is-dash .blog-mgr-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.is-dash .bm-card { display: grid; grid-template-columns: 96px 1fr auto; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; align-items: center; }
.is-dash .bm-card.off { opacity: .62; }
.is-dash .bm-thumb { width: 96px; height: 72px; border-radius: 10px; overflow: hidden; flex-shrink: 0; }
.is-dash .bm-thumb img, .is-dash .bm-thumb .ph { width: 100%; height: 100%; object-fit: cover; }
.is-dash .bm-info b { font-size: 14.5px; color: var(--navy); display: block; }
.is-dash .bm-info .bm-meta { font-size: 12px; color: var(--muted); margin-top: 4px; display: flex; gap: 10px; flex-wrap: wrap; }
.is-dash .bm-actions { display: flex; flex-direction: column; gap: 7px; align-items: flex-end; }
.is-dash .bm-editor { display: flex; flex-direction: column; gap: 14px; }
.is-dash .bm-cover { aspect-ratio: 16/7; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); position: relative; background: var(--bg-warm); }
.is-dash .bm-cover img { width: 100%; height: 100%; object-fit: cover; }
.is-dash .bm-cover-empty { width: 100%; height: 100%; display: grid; place-items: center; color: var(--muted); gap: 8px; }
@media (max-width: 860px) { .is-dash .blog-mgr-grid { grid-template-columns: 1fr; } }

@media (max-width: 1080px) {
  .is-dash .perf-grid { grid-template-columns: repeat(2, 1fr); }
  .is-dash .reports-layout { grid-template-columns: 1fr; }
  .is-dash .rep-builder { position: static; }
}
@media (max-width: 620px) {
  .is-dash .perf-grid { grid-template-columns: 1fr; }
  .is-dash .brk-row { grid-template-columns: 110px 1fr auto; }
  .is-dash .mini-kv { grid-template-columns: 1fr; }
}

/* ============================================================
   الطباعة — يظهر #print-area فقط
   ============================================================ */
@media print {
  .is-dash .side, .is-dash .topbar, .is-dash .no-print, .is-dash .float-contact, .is-dash .dash-drawer, .is-dash .dash-drawer-bg { display: none !important; }
  .is-dash .dash { display: block !important; }
  .is-dash .dash-content { padding: 0 !important; }
  .is-dash .panel, .is-dash .stat-card, .is-dash .perf-card, .is-dash .rep-preview { box-shadow: none !important; border-color: #ccc !important; break-inside: avoid; }
  body.is-dash, .is-dash .dash { background: var(--surface) !important; }
  .is-dash .reports-layout { grid-template-columns: 1fr !important; }
  @page { margin: 14mm; }
}


/* ====================== [3] الوحدة المالية (fin.css — مغلّفة .is-dash) ====================== */
/* ============================================================
   وحدة الإدارة المالية (ERP) — أنماط
   ============================================================ */
.is-dash .fin-sub-nav { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 8px; }
.is-dash .fin-sub-btn { display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 10px; border: none; background: transparent; color: var(--ink-2, #41506a); font-size: 14px; font-weight: 700; cursor: pointer; transition: all .15s; }
.is-dash .fin-sub-btn:hover { background: var(--bg-warm); }
.is-dash .fin-sub-btn.on { background: var(--navy); color: #fff; }
.is-dash .fin-sub-btn .c { background: rgba(0,0,0,.1); font-size: 11px; padding: 1px 7px; border-radius: 999px; }
.is-dash .fin-sub-btn.on .c { background: rgba(255,255,255,.2); }

/* KPI hero cards */
.is-dash .kpi-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 18px; }
.is-dash .kpi-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; position: relative; overflow: hidden; }
.is-dash .kpi-card.accent { background: linear-gradient(135deg, var(--navy), var(--navy-700)); border-color: var(--navy-700); }
.is-dash .kpi-card.accent .kpi-val, .is-dash .kpi-card.accent .kpi-lbl { color: #fff; }
.is-dash .kpi-card.accent .kpi-lbl { color: #b6bfcc; }
.is-dash .kpi-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.is-dash .kpi-ico { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; }
.is-dash .kpi-val { font-size: 26px; font-weight: 800; color: var(--navy); line-height: 1; }
.is-dash .kpi-val .cur { font-size: 14px; font-weight: 600; color: var(--muted); }
.is-dash .kpi-lbl { font-size: 13px; color: var(--muted); margin-top: 6px; }
.is-dash .kpi-delta { font-size: 12px; font-weight: 700; padding: 3px 8px; border-radius: 999px; }
.is-dash .kpi-delta.up { color: #2f9e6b; background: #e4f3ec; }
.is-dash .kpi-delta.down { color: #b4452f; background: #f7e7e2; }
.is-dash .kpi-card.accent .kpi-delta.up { background: rgba(255,255,255,.16); color: #8ee0b4; }

/* toolbar (filters + actions) */
.is-dash .fin-toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }
.is-dash .fin-toolbar .grow { flex: 1; }
.is-dash .fin-search { display: flex; align-items: center; gap: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 9px 14px; color: var(--muted); min-width: 200px; }
.is-dash .fin-search input { border: none; background: none; outline: none; font-size: 14px; width: 100%; color: var(--ink); font-family: inherit; }
.is-dash .fin-seg { display: flex; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 3px; gap: 2px; }
.is-dash .fin-seg button { border: none; background: none; padding: 8px 14px; border-radius: 8px; font-size: 13px; font-weight: 700; color: var(--muted); cursor: pointer; white-space: nowrap; }
.is-dash .fin-seg button.on { background: var(--navy); color: #fff; }

/* amount cells */
.is-dash .amt { font-weight: 800; font-variant-numeric: tabular-nums; }
.is-dash .amt.in { color: #2f7d5b; }
.is-dash .amt.out { color: #b4452f; }
.is-dash .cur-sm { font-size: 11px; color: var(--muted); font-weight: 600; margin-inline-start: 3px; }

/* type dot */
.is-dash .type-dot { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; }
.is-dash .type-dot .d { width: 9px; height: 9px; border-radius: 3px; flex-shrink: 0; }

/* mini summary row above tables */
.is-dash .fin-summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 18px; }
.is-dash .fin-sum-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; display: flex; align-items: center; gap: 13px; }
.is-dash .fin-sum-card .ic { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; flex-shrink: 0; }
.is-dash .fin-sum-card b { display: block; font-size: 20px; color: var(--navy); font-weight: 800; }
.is-dash .fin-sum-card span { font-size: 12.5px; color: var(--muted); }

/* revenue type manager */
.is-dash .rt-list { display: flex; flex-direction: column; gap: 10px; }
.is-dash .rt-row { display: flex; align-items: center; gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.is-dash .rt-swatch { width: 26px; height: 26px; border-radius: 8px; flex-shrink: 0; border: 1px solid rgba(0,0,0,.08); }
.is-dash .rt-row input.rt-name { flex: 1; border: 1px solid transparent; background: transparent; font-size: 14.5px; font-weight: 700; color: var(--ink); padding: 6px 8px; border-radius: 8px; font-family: inherit; }
.is-dash .rt-row input.rt-name:focus { border-color: var(--gold); background: var(--bg-warm); outline: none; }
.is-dash .rt-colors { display: flex; gap: 5px; }
.is-dash .rt-color-opt { width: 20px; height: 20px; border-radius: 6px; cursor: pointer; border: 2px solid transparent; }
.is-dash .rt-color-opt.on { border-color: var(--navy); }

/* chart: monthly bars (income vs expense) */
.is-dash .fin-chart { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; margin-bottom: 18px; }
.is-dash .fin-chart-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.is-dash .fin-chart-head h3 { font-size: 16px; color: var(--navy); }
.is-dash .fin-legend { display: flex; gap: 16px; }
.is-dash .fin-legend span { font-size: 12.5px; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; }
.is-dash .fin-legend .sw { width: 11px; height: 11px; border-radius: 3px; }
.is-dash .bars2 { display: flex; align-items: flex-end; gap: 16px; height: 220px; }
.is-dash .bar2-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 8px; height: 100%; justify-content: flex-end; }
.is-dash .bar2-pair { display: flex; align-items: flex-end; gap: 4px; width: 100%; height: 100%; justify-content: center; }
.is-dash .bar2 { width: 26px; border-radius: 6px 6px 0 0; transition: height .5s ease; }
.is-dash .bar2.inc { background: linear-gradient(var(--green, #2f9e6b), #25855a); }
.is-dash .bar2.exp { background: linear-gradient(#cf6a52, #b4452f); }
.is-dash .bar2-x { font-size: 12px; color: var(--muted); font-weight: 600; }

/* donut for revenue breakdown */
.is-dash .fin-donut-wrap { display: flex; align-items: center; gap: 26px; flex-wrap: wrap; }
.is-dash .fin-donut { width: 150px; height: 150px; border-radius: 50%; flex-shrink: 0; position: relative; }
.is-dash .fin-donut::after { content: ""; position: absolute; inset: 28px; background: var(--surface); border-radius: 50%; }
.is-dash .fin-donut-c { position: absolute; inset: 0; display: grid; place-items: center; z-index: 1; text-align: center; }
.is-dash .fin-donut-c b { font-size: 22px; color: var(--navy); font-weight: 800; }
.is-dash .fin-donut-c span { font-size: 11px; color: var(--muted); display: block; }
.is-dash .fin-legend2 { display: flex; flex-direction: column; gap: 10px; flex: 1; min-width: 200px; }
.is-dash .fin-leg-row { display: flex; align-items: center; gap: 9px; font-size: 13.5px; }
.is-dash .fin-leg-row .sw { width: 12px; height: 12px; border-radius: 4px; flex-shrink: 0; }
.is-dash .fin-leg-row .v { margin-inline-start: auto; font-weight: 800; color: var(--navy); }

/* account cards */
.is-dash .acc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 18px; }
.is-dash .fin-linknote { display: flex; align-items: flex-start; gap: 10px; background: #eef4fb; border: 1px solid #cfe0f5; color: #2a5a93; border-radius: var(--radius); padding: 13px 16px; font-size: 13px; line-height: 1.6; margin-bottom: 16px; }
.is-dash .fin-linknote svg { flex-shrink: 0; margin-top: 1px; }
.is-dash .link-ref { display: inline-flex; align-items: center; gap: 5px; font-family: ui-monospace, monospace; font-size: 12.5px; color: #2c6fdb; background: #eef4fb; border: 1px solid #d6e4f7; padding: 3px 9px; border-radius: 7px; font-weight: 700; cursor: default; }
.is-dash .acc-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; }
.is-dash .acc-card .ic { width: 40px; height: 40px; border-radius: 11px; background: var(--gold-tint); color: var(--navy); display: grid; place-items: center; margin-bottom: 12px; }
.is-dash .acc-card .bal { font-size: 24px; font-weight: 800; color: var(--navy); }
.is-dash .acc-card .nm { font-size: 13px; color: var(--muted); margin-top: 2px; }

@media (max-width: 1080px) { .is-dash .kpi-grid { grid-template-columns: repeat(2, 1fr); } .is-dash .acc-grid, .is-dash .fin-summary { grid-template-columns: 1fr; } }
@media (max-width: 620px) { .is-dash .kpi-grid { grid-template-columns: 1fr; } .is-dash .bars2 { gap: 8px; } .is-dash .bar2 { width: 18px; } }

/* ============================================================
   الفاتورة الضريبية المبسّطة — النافذة والمستند القابل للطباعة
   ============================================================ */
.is-dash .inv-overlay { position: fixed; inset: 0; background: rgba(14,26,43,.55); z-index: 120; display: flex; align-items: flex-start; justify-content: center; padding: 30px 18px; overflow-y: auto; animation: fade .2s; backdrop-filter: blur(2px); }
.is-dash .inv-sheet-wrap { width: 100%; max-width: 780px; margin: auto 0; animation: invPop .24s cubic-bezier(.3,.7,.4,1); }
@keyframes invPop { from { opacity: 0; transform: translateY(14px) scale(.985); } to { opacity: 1; transform: none; } }
.is-dash .inv-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; background: var(--navy); color: #fff; border-radius: var(--radius) var(--radius) 0 0; font-weight: 700; font-size: 14px; }
.is-dash .inv-bar .mini-btn { background: rgba(255,255,255,.12); border: none; color: #fff; }
.is-dash .inv-bar .mini-btn:hover { background: rgba(255,255,255,.22); }

/* المستند نفسه */
.is-dash .tax-inv { background: #fff; color: #1c2430; border-radius: 0 0 var(--radius) var(--radius); padding: 38px 40px 30px; font-size: 13.5px; line-height: 1.55; box-shadow: var(--shadow-lg); }
.is-dash .ti-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; padding-bottom: 20px; border-bottom: 2px solid var(--navy); }
.is-dash .ti-brand { display: flex; align-items: center; gap: 14px; }
.is-dash .ti-logo { width: 52px; height: 52px; border-radius: 13px; background: var(--navy); color: var(--gold); display: grid; place-items: center; font-weight: 900; font-size: 18px; letter-spacing: -.01em; flex-shrink: 0; }
.is-dash .ti-brand h1 { font-size: 20px; font-weight: 800; color: var(--navy); line-height: 1.2; }
.is-dash .ti-brand span { font-size: 12px; color: #6b7585; }
.is-dash .ti-title { text-align: left; }
.is-dash .ti-title b { display: block; font-size: 17px; color: var(--navy); font-weight: 800; }
.is-dash .ti-title span { font-size: 11px; color: #8a94a3; letter-spacing: .04em; text-transform: uppercase; }

.is-dash .ti-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 26px; padding: 18px 0; border-bottom: 1px solid #e7eaef; }
.is-dash .ti-meta-col { display: flex; flex-direction: column; gap: 8px; }
.is-dash .ti-kv { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.is-dash .ti-kv span { font-size: 12px; color: #6b7585; }
.is-dash .ti-kv b { font-size: 13.5px; color: #1c2430; font-weight: 700; font-variant-numeric: tabular-nums; }

.is-dash .ti-party { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; padding: 18px 0; border-bottom: 1px solid #e7eaef; }
.is-dash .ti-party > div { display: flex; flex-direction: column; gap: 3px; }
.is-dash .ti-party span { font-size: 11.5px; color: #8a94a3; }
.is-dash .ti-party b { font-size: 14px; color: #1c2430; font-weight: 700; }

.is-dash .ti-table { width: 100%; border-collapse: collapse; margin: 20px 0 4px; }
.is-dash .ti-table th { background: var(--gold-tint); color: var(--navy); font-size: 11.5px; font-weight: 700; padding: 11px 12px; text-align: center; border: 1px solid #ecdfc0; line-height: 1.3; }
.is-dash .ti-table th:nth-child(2) { text-align: right; }
.is-dash .ti-table td { padding: 12px; border: 1px solid #eceef2; font-size: 13px; text-align: center; font-variant-numeric: tabular-nums; }
.is-dash .ti-table td.ti-desc { text-align: right; font-weight: 600; color: #1c2430; }
.is-dash .ti-table tbody tr:nth-child(even) td { background: #faf8f3; }

.is-dash .ti-foot { display: flex; align-items: stretch; justify-content: space-between; gap: 22px; margin-top: 22px; }
.is-dash .ti-qr { display: flex; flex-direction: column; align-items: center; gap: 9px; width: 150px; flex-shrink: 0; text-align: center; }
.is-dash .ti-qr img { border: 1px solid #e7eaef; border-radius: 8px; padding: 6px; background: #fff; }
.is-dash .ti-qr-fallback { width: 128px; height: 128px; border: 2px dashed #cfd5de; border-radius: 8px; display: grid; place-items: center; color: #aab2bd; font-weight: 800; letter-spacing: .1em; }
.is-dash .ti-qr span { font-size: 10.5px; color: #8a94a3; line-height: 1.5; }
.is-dash .ti-totals { flex: 1; align-self: flex-end; display: flex; flex-direction: column; gap: 0; max-width: 360px; margin-inline-start: auto; }
.is-dash .ti-trow { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 11px 14px; font-size: 13px; color: #41506a; border-bottom: 1px solid #eceef2; }
.is-dash .ti-trow b { font-weight: 700; color: #1c2430; font-variant-numeric: tabular-nums; }
.is-dash .ti-trow.grand { background: var(--navy); color: #fff; border-radius: 10px; margin-top: 8px; border: none; padding: 14px 16px; }
.is-dash .ti-trow.grand span { font-weight: 700; }
.is-dash .ti-trow.grand b { color: var(--gold-soft); font-size: 16px; }
.is-dash .ti-trow.grand b i { font-style: normal; font-size: 12px; font-weight: 600; }

.is-dash .ti-note { margin-top: 24px; padding-top: 16px; border-top: 1px dashed #d8dde4; font-size: 11.5px; color: #8a94a3; line-height: 1.7; text-align: center; }

@media (max-width: 600px) {
  .is-dash .tax-inv { padding: 26px 20px 22px; }
  .is-dash .ti-head { flex-direction: column; gap: 14px; }
  .is-dash .ti-title { text-align: right; }
  .is-dash .ti-meta, .is-dash .ti-party { grid-template-columns: 1fr; }
  .is-dash .ti-foot { flex-direction: column-reverse; align-items: center; }
  .is-dash .ti-totals { max-width: none; width: 100%; }
}

/* الطباعة — يظهر مستند الفاتورة فقط (النافذة مُسقطة على body عبر Portal) */
@media print {
  body.is-dash.inv-open > #root { display: none !important; }
  body.is-dash.inv-open .inv-overlay { position: static; inset: auto; padding: 0; background: none; overflow: visible; display: block; backdrop-filter: none; }
  body.is-dash.inv-open .inv-sheet-wrap { max-width: none; margin: 0; animation: none; }
  body.is-dash.inv-open .inv-bar { display: none !important; }
  body.is-dash.inv-open .tax-inv { box-shadow: none; border-radius: 0; padding: 0; }
  body.is-dash.inv-open .ti-trow.grand, body.is-dash.inv-open .ti-table th { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* ============================================================
   نموذج عقد الإيجار — رسوم الخدمات التفصيلية + جدول السداد + المرافقون (الموقع العام)
   ============================================================ */
.util-card { border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px 4px; margin-bottom: 12px; background: var(--bg-warm); }
.util-head { display: flex; align-items: center; gap: 7px; font-size: 14px; font-weight: 700; color: var(--navy); margin-bottom: 10px; }
.util-head svg { color: var(--gold); }
.util-note { margin: 0 0 12px; font-size: 12.5px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.util-note::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--gold-soft); flex-shrink: 0; }

.pay-sched { margin-top: 16px; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.pay-sched-head { display: flex; align-items: center; gap: 7px; font-size: 14px; font-weight: 700; color: var(--navy); padding: 12px 14px; background: var(--bg-warm); border-bottom: 1px solid var(--line); }
.pay-sched-head svg { color: var(--gold); }
.pay-sched-wrap { overflow-x: auto; }
.pay-tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.pay-tbl th { text-align: start; font-weight: 700; color: var(--muted); padding: 10px 14px; border-bottom: 1px solid var(--line); background: var(--surface); white-space: nowrap; }
.pay-tbl td { padding: 11px 14px; border-bottom: 1px solid var(--line-soft); color: var(--ink); white-space: nowrap; }
.pay-tbl tr:last-child td { border-bottom: none; }
.pay-tbl td.muted { color: var(--muted-2); }
.pay-tbl tbody tr:hover { background: var(--bg-warm); }
.pay-sched-note { font-size: 12px; color: var(--muted); padding: 10px 14px; margin: 0; background: var(--bg-warm); border-top: 1px solid var(--line); line-height: 1.6; }

.dep-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 12px; }
.dep-row { display: flex; align-items: flex-end; gap: 10px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg-warm); }
.dep-fields { flex: 1; display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.dep-fields .field { margin: 0; }
.dep-del { flex-shrink: 0; width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--danger); display: grid; place-items: center; cursor: pointer; transition: background .15s, border-color .15s; }
.dep-del:hover { background: #fbecea; border-color: var(--danger); }
.dep-add { margin-top: 2px; }
@media (max-width: 760px) { .dep-fields { grid-template-columns: 1fr 1fr; } }
@media (max-width: 460px) { .dep-fields { grid-template-columns: 1fr; } }

/* مرافق الوحدة — شبكة اختيارات (الموقع العام) */
.amen-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 18px; }
.amen-item { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--bg-warm); cursor: pointer; transition: border-color .15s, background .15s; user-select: none; }
.amen-item:hover { border-color: var(--gold-soft); }
.amen-item.on { border-color: var(--green); background: var(--green-tint); }
.amen-check { flex-shrink: 0; width: 22px; height: 22px; border-radius: 7px; border: 1.5px solid var(--line); background: var(--surface); display: grid; place-items: center; color: #fff; transition: background .15s, border-color .15s; }
.amen-item.on .amen-check { background: var(--green); border-color: var(--green); }
.amen-item b { flex: 1; font-size: 14px; font-weight: 600; color: var(--navy); }
.amen-count { width: auto; min-width: 76px; padding: 7px 26px 7px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); font-family: inherit; font-size: 14px; font-weight: 700; text-align: center; cursor: pointer; -webkit-appearance: none; -moz-appearance: none; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns=&#039;http://www.w3.org/2000/svg&#039; width=&#039;12&#039; height=&#039;12&#039; viewBox=&#039;0 0 24 24&#039; fill=&#039;none&#039; stroke=&#039;%2391998f&#039; stroke-width=&#039;2.5&#039; stroke-linecap=&#039;round&#039; stroke-linejoin=&#039;round&#039;%3E%3Cpolyline points=&#039;6 9 12 15 18 9&#039;/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: left 9px center; }
.amen-count:has(option[value=""]:checked) { color: var(--muted); font-weight: 500; }
.amen-count::-webkit-outer-spin-button, .amen-count::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
@media (max-width: 520px) { .amen-grid { grid-template-columns: 1fr; } }

/* مرافق الوحدة — شرائح العرض في لوحة التحكم */
.is-dash .ld-amen { display: flex; flex-wrap: wrap; gap: 7px; }
.is-dash .ld-amchip { display: inline-flex; align-items: center; gap: 4px; padding: 5px 11px; border-radius: 999px; background: var(--green-tint); color: var(--green); border: 1px solid color-mix(in srgb, var(--green) 25%, transparent); font-size: 12.5px; font-weight: 600; }

/* ============================================================
   لوحة التحكم — تفاصيل طلب عقد الإيجار القابلة للفتح
   ============================================================ */
.is-dash .lease-row.open { background: var(--bg-warm); }
.is-dash .lease-detail-row td { padding: 0; background: var(--bg-warm); border-bottom: 1px solid var(--line); }
.is-dash .lease-detail { padding: 16px 18px 18px; }
.is-dash .lease-detail.empty { display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--muted); }
.is-dash .lease-detail.empty svg { color: var(--muted-2); }
.is-dash .ld-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; }
.is-dash .ld-card { border: 1px solid var(--line); border-radius: 12px; padding: 13px 15px; background: var(--surface); min-width: 0; overflow-wrap: anywhere; }
.is-dash .ld-h { display: flex; align-items: center; gap: 7px; font-size: 13.5px; font-weight: 800; color: var(--navy); margin-bottom: 10px; padding-bottom: 8px; border-bottom: 1px solid var(--line-soft); }
.is-dash .ld-h svg { color: var(--gold); }
.is-dash .ld-kv { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 4px 0; font-size: 13px; flex-wrap: wrap; }
.is-dash .ld-kv span { color: var(--muted); flex-shrink: 0; }
.is-dash .ld-kv b { color: var(--ink); font-weight: 600; text-align: end; min-width: 0; overflow-wrap: anywhere; word-break: break-word; }
.is-dash .ld-deps { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; }
.is-dash .ld-dep { padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg-warm); }
.is-dash .ld-dep b { display: block; font-size: 13.5px; color: var(--navy); }
.is-dash .ld-dep span { font-size: 12px; color: var(--muted); }
.is-dash .ld-sched-wrap { overflow-x: auto; }
.is-dash .ld-sched { width: 100%; border-collapse: collapse; font-size: 13px; }
.is-dash .ld-sched th { text-align: start; font-weight: 700; color: var(--muted); padding: 8px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.is-dash .ld-sched td { padding: 9px 12px; border-bottom: 1px solid var(--line-soft); white-space: nowrap; }
.is-dash .ld-sched td.muted { color: var(--muted-2); }
.is-dash .ld-sched tr:last-child td { border-bottom: none; }

/* شريط البحث في عقود الإيجار */
.is-dash .lease-search { display: flex; align-items: center; gap: 9px; margin: 0 0 14px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg-warm); }
.is-dash .lease-search > svg { color: var(--muted); flex-shrink: 0; }
.is-dash .lease-search input { flex: 1; min-width: 0; border: 0; background: transparent; font: inherit; font-size: 14px; color: var(--ink); outline: none; }
.is-dash .lease-search input::placeholder { color: var(--muted-2); }
.is-dash .lease-search-clear { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; border: 1px solid var(--line); background: var(--surface); color: var(--muted); cursor: pointer; flex-shrink: 0; }
.is-dash .lease-search-clear:hover { color: var(--navy); border-color: var(--gold-soft); }
.is-dash .lease-search-count { flex-shrink: 0; font-size: 12.5px; font-weight: 700; color: var(--gold-700, #a9883f); background: var(--gold-tint); border-radius: 8px; padding: 5px 10px; }
.is-dash td.lease-empty { text-align: center; color: var(--muted); padding: 30px 16px; font-size: 14px; }

/* المستندات المرفقة في تفاصيل الطلب */
.is-dash .ld-docs { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }
.is-dash .ld-doc { display: flex; align-items: center; gap: 11px; padding: 9px 11px; border: 1px solid var(--line); border-radius: 11px; background: var(--bg-warm); }
.is-dash .ld-doc-type { display: inline-block; font-size: 9.5px; font-weight: 800; letter-spacing: .4px; color: var(--gold-700, #a9883f); background: var(--gold-tint); border-radius: 5px; padding: 2px 7px; margin-bottom: 4px; }
.is-dash .ld-doc-thumb { flex-shrink: 0; width: 46px; height: 46px; border-radius: 9px; overflow: hidden; border: 1px solid var(--line); display: block; }
.is-dash .ld-doc-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.is-dash .ld-doc-file { flex-shrink: 0; width: 46px; height: 46px; border-radius: 9px; display: grid; place-items: center; background: var(--surface); border: 1px solid var(--line); color: var(--gold-700, #a9883f); }
.is-dash .ld-doc-info { flex: 1; min-width: 0; }
.is-dash .ld-doc-info b { display: block; font-size: 13px; font-weight: 700; color: var(--navy); line-height: 1.35; }
.is-dash .ld-doc-info span { display: block; font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.is-dash .ld-doc-act { flex-shrink: 0; width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; color: var(--muted); border: 1px solid var(--line); background: var(--surface); transition: .15s; }
.is-dash .ld-doc-act:hover { color: var(--navy); border-color: var(--gold-soft); }
.is-dash a.ld-doc-file { cursor: pointer; transition: .15s; }
.is-dash a.ld-doc-file:hover { border-color: var(--gold-soft); color: var(--gold-700, #a9883f); }
.is-dash .ld-doc-act-pdf { width: auto; padding: 0 11px; font-size: 11px; font-weight: 800; letter-spacing: .3px; color: var(--gold-700, #a9883f); background: var(--gold-tint); border-color: color-mix(in srgb, var(--gold-soft) 55%, transparent); text-decoration: none; cursor: pointer; }
.is-dash .ld-doc-act-pdf:hover { color: #fff; background: var(--gold-700, #a9883f); border-color: var(--gold-700, #a9883f); }
.is-dash .ld-doc-badge { flex-shrink: 0; font-size: 10.5px; font-weight: 800; color: var(--gold-700, #a9883f); background: var(--gold-tint); border-radius: 6px; padding: 3px 7px; }
.is-dash .ld-toolbar { display: flex; justify-content: flex-start; margin-bottom: 14px; }
.is-dash .ld-pdf-btn { display: inline-flex; align-items: center; gap: 8px; font: inherit; font-size: 13.5px; font-weight: 700; cursor: pointer; color: #fff; background: var(--navy); border: 0; border-radius: 10px; padding: 10px 18px; transition: .15s; }
.is-dash .ld-pdf-btn:hover { background: var(--gold-700, #a9883f); }
.is-dash .ld-pdf-btn svg { color: var(--gold-soft); }
.is-dash .ld-pdf-btn:hover svg { color: #fff; }

/* أزرار المستندات أصبحت <button> — تصفير المظهر الافتراضي */
.is-dash button.ld-doc-thumb, .is-dash button.ld-doc-file, .is-dash button.ld-doc-act { font: inherit; cursor: pointer; padding: 0; -webkit-appearance: none; appearance: none; transition: .15s; }
.is-dash button.ld-doc-file { cursor: pointer; }
.is-dash button.ld-doc-file:not(:disabled):hover { border-color: var(--gold-soft); color: var(--gold-700, #a9883f); }
.is-dash button.ld-doc-thumb:hover { border-color: var(--gold-soft); }
.is-dash button.ld-doc-file:disabled { cursor: default; opacity: .5; }
/* إضافة/حذف المرفقات من اللوحة */
.is-dash .ld-doc-add-btn { display: inline-flex; align-items: center; gap: 5px; font: inherit; font-size: 12px; font-weight: 800; color: var(--gold-700, #a9883f); background: var(--gold-tint); border: 1px solid color-mix(in srgb, var(--gold-700, #a9883f) 25%, transparent); border-radius: 8px; padding: 5px 11px; cursor: pointer; transition: .15s; }
.is-dash .ld-doc-add-btn:hover { color: #fff; background: var(--gold-700, #a9883f); border-color: var(--gold-700, #a9883f); }
.is-dash .ld-doc-actions { flex-shrink: 0; display: flex; align-items: center; gap: 6px; }
.is-dash .ld-doc-act.del { color: var(--muted); }
.is-dash .ld-doc-act.del:hover { color: #fff; background: #c0392b; border-color: #c0392b; }
.is-dash .ld-docs-empty { font-size: 12.5px; color: var(--muted); padding: 10px 2px; }
/* شريط حالة حفظ الإعدادات */
.is-dash .set-savebar { position: sticky; top: 8px; z-index: 30; display: flex; justify-content: flex-end; pointer-events: none; }
.is-dash .set-savepill { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 800; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); box-shadow: 0 6px 18px rgba(16,20,28,.12); }
.is-dash .set-savepill.ok { color: #fff; background: var(--green, #1f8a5b); border-color: var(--green, #1f8a5b); }
.is-dash .set-savepill.saving { color: var(--navy); background: var(--gold-tint); border-color: var(--gold-soft); }
.is-dash .set-savepill.err { color: #fff; background: #c0392b; border-color: #c0392b; }
.is-dash .set-savepill.idle { color: var(--muted); }

/* معاين المستندات داخل اللوحة */
.is-dash .docv-overlay { position: fixed; inset: 0; z-index: 4000; background: rgba(16,20,28,.62); backdrop-filter: blur(3px); display: flex; align-items: center; justify-content: center; padding: 20px; animation: docvFade .18s ease; }
@keyframes docvFade { from { opacity: 0; } to { opacity: 1; } }
.is-dash .docv-modal { background: var(--surface); border-radius: 16px; width: min(880px, 100%); max-height: 92vh; display: flex; flex-direction: column; overflow: hidden; box-shadow: 0 24px 70px rgba(0,0,0,.4); border: 1px solid var(--line); }
.is-dash .docv-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 16px; border-bottom: 1px solid var(--line); background: var(--bg-warm); }
.is-dash .docv-title { display: flex; align-items: center; gap: 9px; min-width: 0; color: var(--navy); }
.is-dash .docv-title b { font-size: 15px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.is-dash .docv-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.is-dash .docv-dl { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; text-decoration: none; color: var(--gold-700, #a9883f); background: var(--gold-tint); border: 1px solid color-mix(in srgb, var(--gold-700, #a9883f) 22%, transparent); border-radius: 9px; padding: 7px 12px; }
.is-dash .docv-dl:hover { color: #fff; background: var(--gold-700, #a9883f); }
.is-dash .docv-close { width: 36px; height: 36px; border-radius: 9px; display: grid; place-items: center; border: 1px solid var(--line); background: var(--surface); color: var(--muted); cursor: pointer; }
.is-dash .docv-close:hover { color: var(--navy); border-color: var(--gold-soft); }
.is-dash .docv-body { flex: 1; min-height: 0; overflow: auto; background: #1f242c; display: flex; align-items: center; justify-content: center; }
.is-dash .docv-img { max-width: 100%; max-height: 86vh; display: block; object-fit: contain; }
.is-dash .docv-frame { width: 100%; height: 80vh; border: 0; background: #fff; }
.is-dash .docv-empty { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 56px 28px; color: #cdd3dc; text-align: center; }
.is-dash .docv-empty p { margin: 0; font-size: 14.5px; line-height: 1.7; max-width: 42ch; }


/* ===== صور العقار: منتقي متعدد الصور (PropertyPhotos) — موقع + لوحة ===== */
.prop-photos { display: flex; flex-direction: column; gap: 9px; }
.pp-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(106px, 1fr)); gap: 10px; }
.pp-cell { position: relative; aspect-ratio: 4 / 3; border-radius: 12px; overflow: hidden; border: 1px solid var(--line, #e6e3dd); background: #f4f2ee; }
.pp-cell img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pp-cell.cover { border-color: var(--gold, #b9893f); box-shadow: 0 0 0 2px var(--gold, #b9893f); }
.pp-badge { position: absolute; inset-inline-start: 6px; inset-block-start: 6px; background: var(--gold, #b9893f); color: #fff; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px; }
.pp-acts { position: absolute; inset-inline-end: 6px; inset-block-start: 6px; display: flex; gap: 5px; opacity: 0; transition: opacity .15s; }
.pp-cell:hover .pp-acts, .pp-cell:focus-within .pp-acts { opacity: 1; }
.pp-acts button { width: 26px; height: 26px; border: 0; border-radius: 8px; background: rgba(17,17,17,.6); color: #fff; display: grid; place-items: center; cursor: pointer; }
.pp-acts button:hover { background: rgba(17,17,17,.85); }
.pp-acts button.del:hover { background: #c0392b; }
.pp-add { aspect-ratio: 4 / 3; border: 1.5px dashed var(--line, #d8d4cc); border-radius: 12px; background: transparent; color: var(--muted, #6a7078); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; cursor: pointer; font: inherit; font-size: 13px; font-weight: 600; transition: border-color .15s, color .15s, background .15s; }
.pp-add:hover { border-color: var(--gold, #b9893f); color: var(--gold, #b9893f); background: rgba(185,137,63,.05); }
.pp-add:disabled { cursor: default; opacity: .7; }
.pp-hint { margin: 0; font-size: 12px; color: var(--muted, #6a7078); }


/* ===== نافذة عامة (modal-bg / modal-box) — «إضافة إيراد يدوي» وغيرها =====
   كانت هذه الأصناف بلا تنسيق فتظهر النافذة ضيّقة ومنحازة؛ هذا يوسّطها
   ويوسّع حقولها ويعطيها مظهر بطاقة مرتّبة. additive فقط. */
/* النوافذ تُنقل عبر ReactDOM.createPortal إلى <body> مباشرةً (خارج غلاف
   .fade-up الذي يترك transform دائماً فيكسر position:fixed) — لذلك التوسيط
   المرن يعمل الآن بثقة: البطاقة موسّطة، لا تتجاوز الشاشة، والرأس والذيل
   ثابتان والجسم يتمرّر داخلياً عند الحاجة. */
.modal-bg { position: fixed; inset: 0; background: rgba(20,25,40,.5); display: flex; align-items: center; justify-content: center; padding: 20px 16px; z-index: 130; overflow-y: auto; }
.modal-box { background: var(--surface, #fff); border: 1px solid var(--line, #e5e1d8); border-radius: 18px; width: 100%; max-width: 560px; margin: auto; box-shadow: 0 30px 80px rgba(0,0,0,.35); overflow: hidden; animation: acctPop .18s ease; display: flex; flex-direction: column; max-height: calc(100vh - 40px); }
.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 20px; border-bottom: 1px solid var(--line, #e5e1d8); flex: 0 0 auto; }
.modal-head h2 { margin: 0; font-size: 18px; color: var(--navy, #1f2a44); }
.modal-body { padding: 16px 20px; flex: 1 1 auto; overflow-y: auto; min-height: 0; }
.modal-foot { display: flex; align-items: center; justify-content: flex-end; gap: 10px; padding: 12px 20px 16px; border-top: 1px solid var(--line, #e5e1d8); flex: 0 0 auto; }
.modal-box label { display: block; }
.modal-box .form-label { margin-bottom: 6px; font-size: 13px; font-weight: 600; color: var(--muted, #6a7078); }
.modal-box .form-input { width: 100%; padding: 10px 12px; border: 1px solid var(--line, #d8d4cc); border-radius: 10px; background: var(--surface, #fff); color: inherit; font: inherit; font-size: 14px; box-sizing: border-box; transition: border-color .15s, box-shadow .15s; }
.modal-box .form-input:focus { outline: none; border-color: var(--gold, #b9893f); box-shadow: 0 0 0 3px rgba(185,137,63,.15); }
@media (max-width: 560px) {
  .modal-body { grid-template-columns: 1fr !important; }
  .modal-bg { padding: 24px 12px; }
}

/* Placeholder لطيف أثناء تحميل صور معرض العقار (خاصةً المصغّرات lazy على الجوال):
   صندوق متدرّج خفيف بدل الفراغ الأبيض، يتكيّف مع الوضع الليلي عبر متغيّرات القالب.
   الصورة غير الشفّافة (object-fit:cover) تغطّيه فور اكتمال تحميلها — بلا أي حِمل. */
.gallery-main, .gallery-thumb {
  background: linear-gradient(135deg, var(--bg-warm, #eef1f5), var(--line, #e3e8ef));
}
.gallery-main img, .gallery-thumb img {
  position: relative;
}

/* ===== حقيبة مشاركة العقار (بروشر Canvas + رسالة واتساب) — لوحة التحكم ===== */
.share-modal {
  position: fixed; z-index: 1001; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: min(880px, 94vw); max-height: 92vh; display: flex; flex-direction: column;
  background: var(--surface, #fff); color: var(--ink, #1a1c20);
  border: 1px solid var(--line, #e7e3db); border-radius: 18px; overflow: hidden;
  box-shadow: 0 24px 70px rgba(0,0,0,.34);
}
.share-head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 12px;
  padding: 16px 20px; border-bottom: 1px solid var(--line, #e7e3db); flex: 0 0 auto;
}
.share-head h2 { margin: 0; font-size: 18px; font-weight: 800; color: var(--navy, #16263f); }
.share-sub { font-size: 13px; color: var(--muted, #6a7078); margin-top: 3px; max-width: 60ch;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.share-body {
  display: grid; grid-template-columns: 300px 1fr; gap: 22px;
  padding: 20px; overflow-y: auto; min-height: 0; flex: 1 1 auto;
}
.share-preview { position: relative; align-self: start; }
.share-canvas {
  width: 100%; height: auto; display: block; border-radius: 12px;
  border: 1px solid var(--line, #e7e3db); background: #fff;
  box-shadow: 0 10px 30px rgba(0,0,0,.14);
}
.share-loading {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,.72); color: var(--navy, #16263f); font-weight: 700;
  font-size: 14px; border-radius: 12px;
}
html[data-theme="dark"] .share-loading { background: rgba(20,23,28,.72); color: var(--ink); }
.share-controls { display: flex; flex-direction: column; gap: 12px; }
.share-toggle { display: flex; align-items: center; gap: 10px; font-weight: 700;
  font-size: 15px; color: var(--ink); cursor: pointer; }
.share-toggle input { width: 18px; height: 18px; accent-color: var(--gold, #c5a25a); cursor: pointer; }
.share-hint { font-size: 12.5px; color: var(--muted, #6a7078); margin-top: -4px; line-height: 1.5; }
.share-btns { display: flex; flex-direction: column; gap: 10px; }
.share-btns .btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.share-divider {
  margin-top: 8px; padding-top: 12px; border-top: 1px solid var(--line, #e7e3db);
  font-size: 13px; font-weight: 700; color: var(--muted, #6a7078);
}
.share-msg {
  width: 100%; box-sizing: border-box; resize: vertical; min-height: 190px;
  padding: 12px 14px; border: 1px solid var(--line, #d8d4cc); border-radius: 12px;
  background: var(--bg-warm, #faf8f4); color: var(--ink); font: inherit; font-size: 13.5px;
  line-height: 1.7; direction: rtl;
}
.share-msg:focus { outline: none; border-color: var(--gold, #c5a25a);
  box-shadow: 0 0 0 3px rgba(197,162,90,.18); }
@media (max-width: 640px) {
  .share-body { grid-template-columns: 1fr; }
  .share-preview { max-width: 260px; margin: 0 auto; }
}
