
    :root{
      --text:#111827; --muted:#6b7280; --panel:#f8fafc; --surface:#ffffff; --border:rgba(0,0,0,.08);
      --safe-top: env(safe-area-inset-top, 0px);
      --safe-bottom: env(safe-area-inset-bottom, 0px);
      --safe-bottom-legacy: constant(safe-area-inset-bottom, 0px);
      /* The visible mobile header includes the status-bar safe area. */
      --mobile-header-h: calc(56px + env(safe-area-inset-top, 0px));
      --tabbar-lift: 20px; /* lift bottom bar a bit */
    }


    body{ color:var(--text); background:#f4f6fb; }
    [data-theme="dark"]{
      --text:#e5e7eb; --muted:#9ca3af; --panel:#0b1220; --surface:#0f172a; --border:rgba(255,255,255,.12);
      background:#0b1020;
    }

    /* Topbar */
    .topbar, .topbar__inner{ background:transparent !important; border:0 !important; box-shadow:none !important; }
     header.topbar {
  position: sticky;
  top: env(safe-area-inset-top);
  padding-top: env(safe-area-inset-top);
}


    .searchbar-wrap{
      display:flex; align-items:center; gap:10px;
      background:#fff; border:1px solid var(--border);
      border-radius:999px; padding:10px 14px;
      box-shadow:0 6px 20px rgba(0,0,0,.06);
      min-width:0;
    }
    body[data-theme="dark"] .searchbar-wrap{
      background:rgba(255,255,255,.06); border-color:var(--border); backdrop-filter:saturate(120%) blur(6px);
    }
    .searchbar i.bi-search{font-size:18px; opacity:.7}
    .searchbar input{ border:0; outline:0; background:transparent; color:inherit; font-size:16px; }
    .searchbar .field{ flex:1; min-width:0; display:flex; align-items:center; gap:10px; }
    .searchbar .field input{ min-width:0; width:100%; }
    .searchbar .sep{ width:1px; height:24px; background:var(--border); }
    .searchbar .k{ opacity:.55; font-size:.9rem; white-space:nowrap }

    /* City suggestions panel */
    .city-suggest{
      position:absolute; inset-inline:14px; top: calc(100% + 8px);
      background: var(--surface); color: var(--text);
      border: 1px solid var(--border); border-radius:14px;
      box-shadow: 0 14px 36px rgba(0,0,0,.18); z-index:2200; overflow:hidden;
      display:none; max-height:320px; overflow:auto;
    }
    .city-suggest .row{ padding:10px 12px; cursor:pointer; display:flex; gap:8px; align-items:baseline; }
    .city-suggest .row:hover{ background: color-mix(in oklab, var(--text) 8%, transparent); }
    .city-suggest .sub{ opacity:.6; font-size:.85em }

    /* Your typeahead (accounts/items) */
    .typeahead{
      position:absolute; inset-inline:0; top: calc(100% + .25rem);
      background: var(--surface); color: var(--text);
      border: 1px solid var(--border); border-radius:.75rem;
      box-shadow: 0 14px 36px rgba(0,0,0,.18); z-index:2000; overflow:hidden;
    }
    .typeahead.d-none{ display:none; }
    .typeahead-group{ padding:.45rem .75rem; font-size:.85rem; opacity:.7; border-bottom:1px solid var(--border) }
    .typeahead-item{ padding:.65rem .8rem; display:flex; gap:.6rem; align-items:center; cursor:pointer; }
    .typeahead-item:hover, .typeahead-item.active{ background: rgba(124,92,255,.12); }
    .typeahead-item .k{ opacity:.65; font-size:.85em }

    /* Bell */
    #notifOpen{ position: relative; }
    #notifOpen .notif-count{
      position:absolute; top:-6px; inset-inline-end:-6px; background:#d43aff; color:#fff;
      font-size:12px; line-height:18px; min-width:18px; height:18px; padding:0 4px; border-radius:10px; text-align:center;
    }
    #notifOpen .notif-ping{
      position:absolute; top:-2px; inset-inline-end:-2px; width:8px; height:8px; background:#d43aff; border-radius:50%;
      box-shadow:0 0 0 6px rgba(212,58,255,.18);
    }

    .sidebar{ width:268px; flex:0 0 268px; border-inline-end:1px solid var(--border); background:var(--surface); }
    .sidebar[data-collapsed="true"]{ width:84px; flex-basis:84px; }
    @media (max-width:991.98px){ .sidebar{ display:none !important; } }

    /* Global bottom space (to keep content above the tab bar) */
    .has-tabbar{ padding-bottom: calc(92px + max(var(--safe-bottom), var(--safe-bottom-legacy))); }


    /* Side notifications panel */
    .notif-panel{
      position: fixed; top:0; inset-inline-end:-420px; width:360px; max-width:88vw; height:100vh;
      background: var(--surface); color: var(--text);
      border-inline-start:1px solid var(--border);
      box-shadow: -14px 0 36px rgba(0,0,0,.25);
      z-index:2300; display:flex; flex-direction:column; transition:.25s ease;
    }
    .notif-panel.is-open{ inset-inline-end:0; }
    .notif-panel__header{ padding:12px 14px; border-bottom:1px solid var(--border); }
    .notif-panel__body{ padding:10px 14px; overflow:auto; }
    .notif-row{ display:block; padding:10px 8px; text-decoration:none; color:inherit; border-bottom:1px solid var(--border); border-radius:8px; }
    .notif-row:hover{ background: color-mix(in oklab, var(--surface) 92%, transparent); }
    .scrim{ position:fixed; inset:0; background:rgba(0,0,0,.35); z-index:2200; opacity:0; pointer-events:none; transition:.2s; }

    /* Top tabs (mobile only) — centered + purple bottom bar */
    .m-top-tabs{
      display:none !important;
      justify-content:center; align-items:flex-end; gap:28px;
      padding:0 14px; margin-top:0;
      border-bottom:1px solid var(--border); background:transparent;
    }
    .m-top-tabs .m-tab{
      position:relative; display:inline-flex; align-items:center;
      background:transparent !important; border:0 !important; box-shadow:none !important; border-radius:0 !important;
      padding:12px 2px 14px; font-weight:800; font-size:15px; color:var(--muted); text-decoration:none; transition:color .15s ease;
    }
    .m-top-tabs .m-tab:hover{ color:color-mix(in oklab, var(--text) 60%, transparent); }
    .m-top-tabs .m-tab.is-active{ color:var(--text); }
    .m-top-tabs .m-tab::after{
      content:""; position:absolute; left:0; right:0; bottom:-1px; height:3px; background:#6C63FF; border-radius:3px;
      opacity:0; transform:scaleX(.25); transform-origin:center; transition:transform .18s ease, opacity .12s ease;
    }
    .m-top-tabs .m-tab.is-active::after{ opacity:1; transform:scaleX(1); }
    [data-theme="dark"] .m-top-tabs{ border-bottom:1px solid var(--border); }
    [data-theme="dark"] .m-top-tabs .m-tab{ color:#9ca3af; }
    [data-theme="dark"] .m-top-tabs .m-tab.is-active{ color:#e5e7eb; }

    @media (max-width:768px){
      .m-top-tabs{ display:flex !important; }
      .notif-panel{ height:100dvh; }
      .notif-panel__header{
        padding:calc(12px + env(safe-area-inset-top,0px)) 14px 12px;
      }
      .notif-panel__body{
        padding-bottom:calc(10px + env(safe-area-inset-bottom,0px));
      }
    }
  
    .dropdown-toggle::after,
    .btn.dropdown-toggle::after,
    button.dropdown-toggle::after {
      display: none !important;
      content: "" !important;
      border: 0 !important;
      margin: 0 !important;
    }
  
    @media (max-width: 768px){
      .sheet-scrim{
        position:fixed; inset:0; background:rgba(0,0,0,.35);
        z-index:2147483646; opacity:0; pointer-events:none; transition:.2s ease;
      }
      .sheet{
        position:fixed; left:0; right:0; bottom:0;
        height:min(78vh, 660px);
        background:#fff; color:var(--text);
        border-radius:18px 18px 0 0;
        box-shadow:0 -18px 40px rgba(0,0,0,.28);
        z-index:2147483647;
        transform:translateY(100%);
        transition:transform .24s ease;
        display:flex; flex-direction:column;
        padding-bottom:calc(8px + max(env(safe-area-inset-bottom,0px), var(--safe-bottom,0px)));
      }
      .sheet.is-open{ transform:translateY(0); }
      .sheet.is-navigating{ pointer-events:none; }
      .sheet-scrim.is-open{ opacity:1; pointer-events:auto; }

      .sheet__drag{ width:46px; height:5px; border-radius:10px; background:#d1d5db; margin:8px auto 6px; }
      .sheet__header{ padding:6px 16px 10px; display:flex; align-items:center; justify-content:space-between; }
      .sheet__profile{ display:flex; align-items:center; gap:10px; }
      .sheet__avatar{ width:56px; height:56px; border-radius:50%; display:flex; align-items:center; justify-content:center; background: #f2f3f7; font-weight:800; }
      .sheet__name{ font-weight:800; line-height:1.1; }
      .sheet__handle{ font-size:.9rem; opacity:.7; }
      .sheet__share{ background:#6C63FF; color:#fff; border:0; padding:.4rem .7rem; border-radius:999px; font-weight:700 }

      .sheet__body{ padding:4px 10px 10px; overflow:auto; }
      .sheet__list{ list-style:none; margin:0; padding:0; }
      .sheet__item{
        display:flex; align-items:center; justify-content:space-between;
        padding:14px 10px; border-bottom:1px solid var(--border);
        text-decoration:none; color:inherit;
      }
      .sheet__item i{ font-size:18px; opacity:.8; margin-inline-start:6px; }
    }
    @media (min-width: 769px){
      #profileSheet, #profileScrim{ display:none !important; }
    }
    @media (prefers-reduced-motion: reduce){
      .sheet, .sheet-scrim{ transition:none !important; }
    }
  
    :root{ --ic: 28px; }
    .ic{
      width:var(--ic); height:var(--ic);
      display:inline-block; position:relative;
      border-radius:50%; overflow:hidden; vertical-align:-3px; flex:0 0 var(--ic);
    }
    .ic::after{
      content:""; position:absolute; inset:0;
      background-position:center; background-repeat:no-repeat; background-size:88%; image-rendering:auto;
    }
    [data-theme="dark"] .ic{ box-shadow:0 0 0 1px rgba(255,255,255,.08) inset; }

    .ic--support  { --img: url('/static/iconblossom/sfer.png'); }
    .ic--profile  { --img: url('/static/iconblossom/vert.png'); }
    .ic--fav      { --img: url('/static/iconblossom/mov.png'); }
    .ic--settings { --img: url('/static/iconblossom/ramdi.png'); }
    .ic--logout   { --img: url('/static/iconblossom/roge.png'); }
    .ic--cc       { --img: url('/static/iconblossom/cc.png'); }
    .ic--about { --img: url('/static/iconblossom/org.png'); }
    .ic--customer-requests { --img: url('/static/iconblossom/customer-requests.svg'); }

    .ic::after{ background-image: var(--img); }

    /* Desktop tweaks */
    .ic--support  { --ic: 34px; }
    .ic--profile  { --ic: 30px; }
    .ic--fav      { --ic: 28px; }
    .ic--settings { --ic: 28px; }
    .ic--logout   { --ic: 32px; }
    .ic--cc       { --ic: 36px; }
    .ic--about { --ic: 36px; }   /* عدّل الرقم كما تحب */
    .ic--customer-requests { --ic: 34px; }

    /* Mobile */
    @media (max-width:768px){
      .ic--support  { --ic: 38px; }
      .ic--profile  { --ic: 34px; }
      .ic--fav      { --ic: 38px; }
      .ic--settings { --ic: 42px; }
      .ic--logout   { --ic: 36px; }
      .ic--cc       { --ic: 40px; }
      .ic--about { --ic: 36px; }   /* عدّل الرقم كما تحب */
      .ic--customer-requests { --ic: 38px; }

    }
  
    @media (max-width: 768px){
      body[data-auth="0"] #menuBtn,
      body[data-auth="0"] #quickMenu,
      body[data-auth="0"] .searchbar,
      body[data-auth="0"] .m-top-tabs,
      body[data-auth="0"] #notifOpen,
      body[data-auth="0"] .stripe-callout,
      body[data-auth="0"] .fab,
      body[data-auth="0"] .sheet,
      body[data-auth="0"] .sheet-scrim { display: none !important; }

      /* In actions leave only Login/Register */
      body[data-auth="0"] .actions > *:not(a[href="/login"]):not(a[href="/register"]){
        display: none !important;
      }

      /* Force hide bottom tabbar when guest */
body[data-auth="0"] .mobile-tabbar {
    display: none !important;
}

      /* Proper bottom space without + button */
      body[data-auth="0"] .page{
        padding-bottom: calc(76px + max(var(--safe-bottom), var(--safe-bottom-legacy))) !important;
      }
    }
  
    body[data-auth="0"] .actions{
      display:flex !important; align-items:center !important; gap:8px !important;
      margin-inline-start:auto !important;
    }
    body[data-auth="0"] .actions a[href="/login"],
    body[data-auth="0"] .actions a[href="/register"]{
      display:inline-flex !important;
    }

    .actions{ gap:8px; }
    .btn-chip{
      display:inline-flex; align-items:center; justify-content:center;
      padding:8px 14px; border-radius:999px; font-weight:800;
      line-height:1; font-size:.95rem; text-decoration:none;
      border:1px solid transparent; transition:.15s ease;
      box-shadow:0 4px 14px rgba(0,0,0,.06);
    }
    .btn-chip--ghost{ background:#fff; color:#6C63FF; border-color:#e5e7eb; }
    .btn-chip--ghost:hover{ background:#f8f8ff; border-color:#d9d9ff; }
    .btn-chip--primary{ background:#6C63FF; color:#fff; border-color:#6C63FF; }
    .btn-chip--primary:hover{ filter:brightness(.98); }
    [data-theme="dark"] .btn-chip--ghost{ background:rgba(255,255,255,.06); border-color:rgba(255,255,255,.18); }

    /* Keep search visible for guest */
    body[data-auth="0"] .searchbar{ display:block !important; }

    /* Don’t hide guest login/register within actions */
    body[data-auth="0"] .actions > *{ display:none !important; }
    body[data-auth="0"] .actions a[href="/login"],
    body[data-auth="0"] .actions a[href="/register"]{
      display:inline-flex !important;
    }
  
    /* Dialogs must remain above mobile navigation and the sticky header. */
    .modal, .offcanvas { z-index: 7000 !important; }
    .modal-backdrop, .offcanvas-backdrop { z-index: 6900 !important; }
    body.modal-open #typeaheadPanel,
    body.modal-open #citySuggest,
    body.modal-open .notif-panel,
    body.modal-open #profileSheet,
    body.modal-open #profileScrim,
    body.modal-open .sheet,
    body.modal-open .sheet-scrim { display: none !important; }
    .modal-backdrop + .modal-backdrop { display: none !important; }
    body::after { z-index: 1000 !important; }
    .modal.fade .modal-dialog { transition: none !important; }
    body.modal-open { padding-right: 0 !important; }
    @media (max-width:768px){
      .modal-dialog{
        width:calc(100% - 24px);
        max-height:calc(100dvh - 24px - env(safe-area-inset-top,0px) - env(safe-area-inset-bottom,0px));
        margin:max(12px, env(safe-area-inset-top,0px)) auto max(12px, env(safe-area-inset-bottom,0px));
      }
      .modal-dialog .modal-content{ max-height:inherit; }
      .modal-dialog .modal-body{ overflow-y:auto; }
    }
  
  @media (max-width:768px){

    header.topbar{
      position: sticky !important;
      top: 0 !important;
      z-index: 5000 !important;
      box-sizing:border-box;
      height:var(--mobile-header-h) !important;
      min-height:var(--mobile-header-h) !important;
      padding-top: env(safe-area-inset-top, 0px) !important;
      padding-bottom: 0 !important;
      margin-bottom: 0 !important;
      background: rgba(255,255,255,.98) !important;
      border: 0 !important;
      box-shadow: none !important;
    }

    header.topbar::before{
      content: "";
      position: absolute;
      left: 0;
      right: 0;
      top: 0;
      height: env(safe-area-inset-top, 0px);
      background: #fff;
      pointer-events: none;
    }

    header.topbar .topbar__inner{
      box-sizing:border-box;
      height:56px;
      min-height:56px !important;
      min-width:0;
      background: transparent !important;
      padding-bottom: 0 !important;
      margin-bottom: 0 !important;
    }

    .m-top-tabs{
      position: relative !important;
      top: auto !important;
      z-index: 4999 !important;
      margin-top: 34px !important;
      padding-top: 0 !important;
      padding-bottom: 8px !important;
      background: rgba(255,255,255,.98) !important;
      border-bottom: 0 !important;
    }

    .m-top-tabs::after{
      display: none !important;
    }
  }
  

    /* =========================
   GLASS UI – Mobile Tabbar
   (style only, no HTML change)
   ========================= */
@media (max-width: 768px){
  :root{
    --glass-blur: 16px;
    --glass-sat: 199%;
    --glass-bg: rgba(56, 56, 56, .35);              /* dark glass base */
    --glass-grad1: rgba(108, 99, 255, .18);         /* purple */
    --glass-grad2: rgba(0, 212, 255, .12);          /* cyan */
    --glass-stroke: rgba(255,255,255,.125);         /* glass edge */
    --glass-inner: rgba(255,255,255,.06);           /* inner gloss */
    --tabbar-h: 64px;
    --tabbar-radius: 22px;
  }

  .mobile-tabbar{
    position: fixed !important;
    left: 10px !important; right: 10px !important;
    bottom: calc(10px + max(env(safe-area-inset-bottom,0px), var(--safe-bottom,0px))) !important;
    height: var(--tabbar-h) !important;
    display: grid !important; grid-template-columns: repeat(5, 1fr) !important;
    align-items: center !important; padding: 8px 12px !important; border-top: none !important;
    z-index: 1030 !important; border-radius: var(--tabbar-radius) !important;

    /* Glass: Blur + Saturate + bg + gradient */
    background:
      linear-gradient(135deg, var(--glass-grad1), var(--glass-grad2)),
      var(--glass-bg) !important;
    backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-sat)) !important;
    -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-sat)) !important;

    /* edges & subtle highlight like the mock */
    box-shadow:
      0 14px 30px rgba(0,0,0,.35),
      0 0 0 1px var(--glass-stroke) inset,
      0 2px 0 0 var(--glass-inner) inset !important;

    transform: translateY(calc(-1 * var(--tabbar-lift)));
    transition: transform .25s ease;
  }

  /* Text & icons inside tabs */
  .mobile-tabbar a{
    position: relative !important;
    height: 100% !important;
    border-radius: 16px !important;
    display: flex !important; flex-direction: column !important;
    align-items: center !important; justify-content: center !important;
    gap: 4px !important; text-decoration: none !important;
    color: #f2f2f7 !important; font-size: 12px !important; font-weight: 700 !important;
    transition: transform .18s ease, color .18s ease;
  }
  .mobile-tabbar .tab-img{
    width: 24px !important; height: 24px !important; object-fit: contain !important;
    opacity: .95 !important; filter: drop-shadow(0 1px 0 rgba(0,0,0,.25));
    transition: transform .15s ease, opacity .15s ease !important;
  }

  /* Active “pill” feel */
.mobile-tabbar a.is-active{
  background: transparent !important;
  box-shadow: none !important;
  color: #ffffff !important;
}
.mobile-tabbar a.is-active::after{
  content:none !important;
  display:none !important;
}
.mobile-tabbar a.is-active .tab-img{
    opacity: 1 !important; transform: scale(1.06) !important;
  }

  /* Badge dot */
  .mobile-tabbar .badge-dot{
    position: absolute !important; top: 6px !important; transform: translateX(12px);
    min-width: 20px; height: 20px; line-height: 20px; font-size: 11px;
    border-radius: 999px; background: #22c55e; color: #0b1020;
    box-shadow: 0 2px 6px rgba(34,197,94,.35);
    text-align: center;
  }

}

/* Direct-message unread count.  This deliberately remains separate from
   .badge-dot, which belongs to the notifications bell.  Keep it outside the
   phone-only block because the shared tabbar is also used on iPad widths. */
.mobile-tabbar a[href="/messages"] .messages-nav-unread{
  position:absolute;
  z-index:2;
  top:4px;
  left:calc(50% + 9px);
  display:grid;
  place-items:center;
  box-sizing:border-box;
  min-width:19px;
  height:19px;
  max-width:34px;
  padding:0 5px;
  overflow:hidden;
  color:#fff;
  background:linear-gradient(135deg, var(--primary, #7C4DFF), #4F6FFF, #28B8F5);
  border:1.5px solid rgba(255,255,255,.94);
  border-radius:999px;
  box-shadow:0 4px 10px rgba(79,111,255,.28);
  font-size:.62rem;
  font-weight:800;
  font-variant-numeric:tabular-nums;
  line-height:1;
  white-space:nowrap;
  pointer-events:none;
}
.mobile-tabbar a[href="/messages"] .messages-nav-unread[hidden]{ display:none !important; }

/* Dark mode tune */
[data-theme="dark"] .mobile-tabbar{
  background:
    linear-gradient(135deg, rgba(108,99,255,.16), rgba(0,212,255,.10)),
    rgba(28,28,30,.66) !important;
  box-shadow:
    0 14px 30px rgba(0,0,0,.45),
    0 0 0 1px rgba(255,255,255,.08) inset,
    0 2px 0 0 rgba(255,255,255,.05) inset !important;
}

  /* ===== Profile Bottom Sheet — Glass Style (match mobile tabbar) ===== */
@media (max-width: 768px){
  /* Glassy header */
  #profileSheet{
    background:
      linear-gradient(135deg, var(--glass-grad1), var(--glass-grad2)),
      var(--glass-bg) !important;
    backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-sat)) !important;
    -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-sat)) !important;
    box-shadow:
      0 -18px 40px rgba(0,0,0,.35),
      0 0 0 1px var(--glass-stroke) inset,
      0 2px 0 0 var(--glass-inner) inset !important;
    color:#fff;  /* light text over glass */
  }
  /* Body contrast */
  #profileSheet .sheet__body{
    background: rgba(255,255,255,.08);
    border-radius: 14px 14px 0 0;
    margin: 6px 8px 8px;
    padding: 4px 0 8px;
    box-shadow:
      0 1px 0 rgba(255,255,255,.06) inset,
      0 -1px 0 rgba(0,0,0,.05) inset;
  }

  /* Profile card atop sheet */
  #profileSheet .sheet__avatar{
    background: rgba(255,255,255,.14) !important;
    color:#fff; font-weight:800;
    box-shadow: 0 0 0 1px rgba(255,255,255,.18) inset;
  }
  #profileSheet .sheet__name{ color:#fff; }
  #profileSheet .sheet__handle{ color: rgba(255,255,255,.8); }

  /* Share button */
  #profileSheet .sheet__share{
    background:#6C63FF !important; color:#fff !important; border:0 !important;
    box-shadow: 0 8px 18px rgba(108,99,255,.35);
  }

  /* List items: height, chevron right, icon left */
  #profileSheet .sheet__item{
    background: transparent;
    position: relative;
    padding: 14px 14px;
    border-bottom: 1px solid rgba(255,255,255,.12);
    color:#f2f2f7;
  }
  #profileSheet .sheet__item:hover{
    background: rgba(255,255,255,.10);
  }
  /* chevron */
  #profileSheet .sheet__item .chev{
    color:#fff; opacity:.85;
  }
  /* label */
  #profileSheet .sheet__item .label{
    font-weight:800; letter-spacing:.1px;
  }

  /* circular icons — same pack */
  #profileSheet .ic{
    box-shadow: 0 0 0 1px rgba(255,255,255,.10) inset;
  }

  /* Logout item in red */
  #profileSheet .sheet__item.text-danger{
    color:#ff6b6b !important;
  }
  #profileSheet .sheet__item.text-danger:hover{
    background: rgba(255,107,107,.12) !important;
  }
}

/* Light mode tweaks */
@media (max-width: 768px){
  [data-theme="light"] #profileSheet{
    color:#111;
  }
  [data-theme="light"] #profileSheet .sheet__body{
    background: rgba(255,255,255,.6);
  }
  [data-theme="light"] #profileSheet .sheet__item{
    border-bottom: 1px solid rgba(0,0,0,.06);
    color:#111;
  }
  [data-theme="light"] #profileSheet .sheet__item:hover{
    background: rgba(0,0,0,.04);
  }
}
  


  
  .sv-locked{
    opacity: .55 !important;
    cursor: not-allowed !important;
    filter: grayscale(.25);
  }
  .sv-locked *{ pointer-events:none; }

  /* Align sheet row items */
  #profileSheet .sheet__item{ display:flex; align-items:center; }
  #profileSheet .sheet__item .left{ display:flex; align-items:center; gap:10px; }

  /* Vertically center text next to icon */
  #profileSheet .sheet__item .label{
    display:flex; align-items:center;
    line-height:1; margin:0; padding:0;
  }

  /* Cancel vertical offset of icon in sheet only */
  #profileSheet .ic{ vertical-align:0; }

  /* 1px nudge for iOS (optional) */
  @supports (-webkit-touch-callout: none){
    #profileSheet .sheet__item .label{ position:relative; top:-1px; }
  }

  .immersive-back{
    position: fixed;
    inset-inline-start: 12px;
    inset-block-start: calc(var(--safe-top, 0px) + 12px);
    z-index: 2147483647;
    display: inline-flex; align-items: center; justify-content: center;
    width: 38px; height: 38px; border-radius: 999px;
    background: rgba(15,17,26,.65);
    backdrop-filter: blur(10px) saturate(160%);
    -webkit-backdrop-filter: blur(10px) saturate(160%);
    color: #fff; text-decoration: none;
    box-shadow: 0 6px 16px rgba(0,0,0,.25), 0 0 0 1px rgba(255,255,255,.12) inset;
  }
  [data-theme="light"] .immersive-back{
    background: rgba(255,255,255,.7);
    color:#111;
    box-shadow: 0 6px 16px rgba(0,0,0,.15), 0 0 0 1px rgba(0,0,0,.08) inset;
  }

  /* === Minimal Luxury Typography ===
     - العناوين: Cormorant Garamond (فخم/مجلات)
     - النص: Work Sans (حديث وواضح)
  */
  :root{
    --font-head: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
    --font-body: 'Work Sans', -apple-system, BlinkMacSystemFont, "Segoe UI",
                 Roboto, Helvetica, Arial, sans-serif;
    /* لو تستخدم Bootstrap: */
    --bs-body-font-family: var(--font-body);
  }

  html, body, input, button, textarea, select {
    font-family: var(--font-body) !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    line-height: 1.6;
    letter-spacing: 0.1px; /* لمسة خفيفة */
    color: #111827;
  }

  /* العناوين الفخمة */
  h1, h2, h3 {
    font-family: var(--font-head);
    font-weight: 600;      /* 600 يعطي حضور بدون مبالغة */
    letter-spacing: 0.2px;
    color: #0f172a;
  }
  h4, h5, h6 {
    font-family: var(--font-body);
    font-weight: 700;
    letter-spacing: 0.1px;
  }
  strong, b, button { font-weight: 600; }

  /* أحجام (معقولة) + تدرّج للهاتف */
  h1 { font-size: clamp(1.9rem, 2.5vw + 1.2rem, 2.7rem); line-height: 1.18; }
  h2 { font-size: clamp(1.6rem, 1.8vw + 1.0rem, 2.1rem); line-height: 1.22; }
  h3 { font-size: clamp(1.25rem, 1.2vw + .9rem, 1.5rem); line-height: 1.28; }

  /* أرقام ثابتة العرض للأسعار والنِّسب */
  .num, .price, .percent { font-variant-numeric: tabular-nums; }

  /* نص الفقرات */
  p { color:#374151; }

  /* تحسين بسيط للوضع الداكن إن كنت تفعّله */
  [data-theme="dark"] html,
  [data-theme="dark"] body { color: #e5e7eb; }
  [data-theme="dark"] h1, [data-theme="dark"] h2, [data-theme="dark"] h3 { color:#eef2ff; }
  [data-theme="dark"] p { color:#cbd5e1; }

  /* متغيّرات افتراضية */
  :root{
    --sv-tabbar: 64px;            /* يتحدث تلقائياً عبر JS أدناه */
    --sv-lift: 20px;              /* مقدار رفع التاب بار لديك */
    --sv-fab-gap: 24px;           /* 14px visible gap above the lifted tab bar */
    --glass-blur: 16px;
    --glass-sat: 199%;
    --glass-bg: rgba(56,56,56,.35);
    --glass-g1: rgba(108,99,255,.18);  /* purple */
    --glass-g2: rgba(0,212,255,.12);   /* cyan */
    --glass-stroke: rgba(255,255,255,.125);
    --glass-inner: rgba(255,255,255,.06);
  }

  /* شكل الزر الزجاجي */
  #fabAdd{
    position: fixed;
    right: 16px;
    bottom: 16px;                 /* يتبدل على الموبايل أدناه */
    width: 58px; height: 58px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    text-decoration: none;
    color: #fff !important;
    z-index: 1040 !important;  /* Above the tab bar, below dialogs and sheets. */
    border: 0 !important;

    /* زجاج مطابق للتاب بار */
    background:
      linear-gradient(135deg, var(--glass-g1), var(--glass-g2)),
      var(--glass-bg) !important;
    backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-sat)) !important;
    -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-sat)) !important;
    box-shadow:
      0 14px 30px rgba(0,0,0,.35),
      0 0 0 1px var(--glass-stroke) inset,
      0 2px 0 0 var(--glass-inner) inset !important;
  }
  #fabAdd i{ font-size: 24px; filter: drop-shadow(0 1px 0 rgba(0,0,0,.25)); }
  #fabAdd:active{ transform: scale(.96); }

  /* ارفع الزر فوق التاب بار على الموبايل */
  @media (max-width: 768px){
    #fabAdd{
      bottom: calc(var(--sv-tabbar) + var(--sv-lift)
                   + max(env(safe-area-inset-bottom,0px), var(--safe-bottom,0px))
                   + var(--sv-fab-gap)) !important;
    }
  }

  /* دارك مود مطابق */
  [data-theme="dark"] #fabAdd{
    background:
      linear-gradient(135deg, rgba(108,99,255,.16), rgba(0,212,255,.10)),
      rgba(28,28,30,.66) !important;
    box-shadow:
      0 14px 30px rgba(0,0,0,.45),
      0 0 0 1px rgba(255,255,255,.08) inset,
      0 2px 0 0 rgba(255,255,255,.05) inset !important;
  }

/* ===== One lightweight moving selection indicator ===== */
.mobile-tabbar {
  position: relative;
}

.mobile-tabbar .tab-indicator {
  position:absolute;
  top:8px;
  bottom:8px;
  left:0;
  z-index:0;
  width:0;
  border:1px solid rgba(255,255,255,.22);
  border-radius:16px;
  pointer-events:none;
  opacity:0;
  background:rgba(255,255,255,.14);
  box-shadow:
    0 0 0 1px rgba(255,255,255,.08) inset,
    0 6px 16px rgba(0,0,0,.20);
  transform:translate3d(0,0,0);
  will-change:transform, width;
  transition:none;
}

.mobile-tabbar .tab-indicator.is-ready{
  opacity:1;
  transition:
    transform .2s cubic-bezier(.22,.8,.3,1),
    width .2s cubic-bezier(.22,.8,.3,1),
    opacity .12s ease;
}

@media (min-width: 992px) {
  .mobile-tabbar { display: none; }
}


.mobile-tabbar a {
  position: relative;
  z-index: 1;
}

/* The shared marker is the only active-state surface at phone and tablet
   breakpoints; suppress the legacy static underline from style.css. */
.mobile-tabbar a.is-active::after{
  content:none !important;
  display:none !important;
}

[data-theme="dark"] .mobile-tabbar .tab-indicator{
  border-color:rgba(255,255,255,.18);
  background:rgba(255,255,255,.11);
  box-shadow:0 0 0 1px rgba(255,255,255,.05) inset, 0 6px 16px rgba(0,0,0,.28);
}

@media (prefers-reduced-motion:reduce){
  .mobile-tabbar .tab-indicator.is-ready{ transition:none; }
}
  

  .sv-enter {
    opacity: 0;
    transform: translateX(20px);
  }
  .sv-enter-active {
    opacity: 1;
    transform: translateX(0);
    transition: opacity .25s ease, transform .25s ease;
  }

  .sv-exit {
    opacity: 1;
    transform: translateX(0);
  }
  .sv-exit-active {
    opacity: 0;
    transform: translateX(-20px);
    transition: opacity .25s ease, transform .25s ease;
  }

/* FIX iOS rounded seam between search + city inputs */
header.topbar .searchbar input.form-control{
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  border-radius: 0 !important;
}



/* === SEARCH + TOP TABS STICK TOGETHER === */

header.topbar .topbar__inner{
  min-height: 64px;
  align-items: center;
}

header.topbar form.searchbar{
  display: flex;
  align-items: center;
  margin: 0;
}

header.topbar .searchbar-wrap{
  display: flex;
  align-items: center;
  height: 44px;
}

@media (max-width: 768px){

  /* لا تترك فراغ تحت search */
  header.topbar{
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
  }

  header.topbar .topbar__inner{
    min-height: 56px;
    align-items: center;
    padding-bottom: 0 !important;
    margin-bottom: 0 !important;
  }

  header.topbar form.searchbar{
    margin-bottom: 0 !important;
  }

  header.topbar .searchbar-wrap{
    margin-bottom: 0 !important;
  }

  /* الصق tabs مباشرة تحت search */
  .m-top-tabs{
    margin-top: 0px !important;
    padding-top: 0 !important;
    padding-bottom: 10px !important;
    border-top: 0 !important;
  }

  /* احذف أي ظل/فراغ إضافي بينهما */
  .m-top-tabs::after{
    display: none !important;
  }

  .page{
    padding-top: 10px !important;
  }
}

.m-top-tabs{
  margin-top: 0;
}

/* ========================================================================
   Desktop header refresh
   ------------------------------------------------------------------------
   The desktop top bar contains several existing navigation actions.  Keep
   their markup and behaviour intact, but give the whole group one calm,
   legible surface so the search and actions read as a single control area.
   This is deliberately limited to the same lg breakpoint used by the
   desktop controls in base.html; phone and tablet header rules stay intact.
   ======================================================================== */
@media (min-width: 992px){
  html:not(.is-ipad) header.topbar{
    top:0;
    z-index:2000;
    height:auto !important;
    min-height:83px;
    box-sizing:border-box;
    padding:10px clamp(16px, 2.15vw, 38px) 9px !important;
    background:linear-gradient(180deg, rgba(247,249,255,.94), rgba(247,249,255,.76)) !important;
    border-bottom:1px solid rgba(76,92,155,.10) !important;
    box-shadow:0 7px 22px rgba(39,48,91,.045) !important;
    backdrop-filter:saturate(150%) blur(16px);
    -webkit-backdrop-filter:saturate(150%) blur(16px);
  }

  html:not(.is-ipad) header.topbar .topbar__inner{
    width:100%;
    max-width:1540px;
    min-height:62px;
    margin-inline:auto;
    padding:8px 10px 8px 12px;
    gap:10px !important;
    border:1px solid rgba(101,91,218,.13) !important;
    border-radius:21px;
    background:rgba(255,255,255,.88) !important;
    box-shadow:
      0 12px 30px rgba(44,55,105,.08),
      0 1px 0 rgba(255,255,255,.9) inset !important;
    backdrop-filter:saturate(145%) blur(13px);
    -webkit-backdrop-filter:saturate(145%) blur(13px);
  }

  html:not(.is-ipad) header.topbar .brand{
    flex:0 0 auto;
    margin-inline-end:1px !important;
    padding:2px;
    border-radius:14px;
    transition:background-color .16s ease, transform .16s ease;
  }

  html:not(.is-ipad) header.topbar .brand:hover{
    background:rgba(104,91,255,.075);
    transform:translateY(-1px);
  }

  html:not(.is-ipad) header.topbar .brand-logo{
    display:block;
    width:auto;
    height:42px !important;
  }

  html:not(.is-ipad) header.topbar #menuBtn{
    width:42px;
    height:42px;
    flex:0 0 42px;
    padding:0;
    color:#273252;
    border:1px solid rgba(75,88,143,.14);
    border-radius:13px;
    background:linear-gradient(145deg, #fff, #f4f6ff);
    box-shadow:0 4px 12px rgba(43,56,108,.06);
    transition:transform .16s ease, border-color .16s ease, box-shadow .16s ease, background-color .16s ease;
  }

  html:not(.is-ipad) header.topbar #menuBtn:hover{
    color:#5947d7;
    border-color:rgba(93,72,221,.29);
    background:#fff;
    box-shadow:0 8px 18px rgba(89,71,215,.12);
    transform:translateY(-1px);
  }

  html:not(.is-ipad) header.topbar form.searchbar{
    flex:1 1 510px;
    min-width:230px;
    max-width:790px;
    margin:0 4px !important;
  }

  html:not(.is-ipad) header.topbar .searchbar-wrap{
    width:100%;
    height:46px;
    padding:7px 13px;
    gap:9px;
    border:1px solid rgba(75,88,143,.13) !important;
    border-radius:15px;
    background:#f7f8fe !important;
    box-shadow:inset 0 1px 0 rgba(255,255,255,.9) !important;
    transition:border-color .16s ease, box-shadow .16s ease, background-color .16s ease;
  }

  html:not(.is-ipad) header.topbar .searchbar-wrap:focus-within{
    border-color:rgba(89,71,215,.42) !important;
    background:#fff !important;
    box-shadow:0 0 0 4px rgba(89,71,215,.12), inset 0 1px 0 rgba(255,255,255,.9) !important;
  }

  html:not(.is-ipad) header.topbar .searchbar i.bi-search{
    color:#6554e8;
    opacity:1;
    font-size:17px;
  }

  html:not(.is-ipad) header.topbar .searchbar .field:first-of-type{
    flex:1.25 1 0;
  }

  html:not(.is-ipad) header.topbar .searchbar .field:last-of-type{
    flex:.9 1 0;
  }

  html:not(.is-ipad) header.topbar .searchbar .sep{
    height:22px;
    background:rgba(75,88,143,.16);
  }

  html:not(.is-ipad) header.topbar .searchbar input.form-control{
    min-width:0;
    color:#202942 !important;
    font-size:.92rem;
    font-weight:600;
  }

  html:not(.is-ipad) header.topbar .searchbar input.form-control::placeholder{
    color:#8891aa;
    font-weight:500;
    opacity:1;
  }

  html:not(.is-ipad) header.topbar .searchbar .k{
    color:#69738f;
    font-size:.77rem;
    font-weight:800;
    letter-spacing:.035em;
    opacity:1;
    text-transform:uppercase;
  }

  html:not(.is-ipad) header.topbar .actions{
    flex:0 0 auto;
    gap:5px !important;
    margin-inline-start:auto !important;
    padding-inline-start:10px;
    border-inline-start:1px solid rgba(75,88,143,.12);
  }

  html:not(.is-ipad) header.topbar .actions > .btn,
  html:not(.is-ipad) header.topbar .actions > a.btn,
  html:not(.is-ipad) header.topbar .actions > .dropdown > .btn{
    min-height:40px;
    border-radius:12px;
  }

  html:not(.is-ipad) header.topbar .actions > .btn-ghost,
  html:not(.is-ipad) header.topbar .actions > a.btn-ghost,
  html:not(.is-ipad) header.topbar .actions > .dropdown > .btn-ghost,
  html:not(.is-ipad) header.topbar .actions > .btn-outline-secondary{
    min-width:40px;
    padding:7px 9px;
    color:#3d4969;
    border:1px solid transparent !important;
    background:transparent !important;
    box-shadow:none !important;
    transition:transform .16s ease, color .16s ease, background-color .16s ease, border-color .16s ease, box-shadow .16s ease;
  }

  html:not(.is-ipad) header.topbar .actions > .btn-ghost:hover,
  html:not(.is-ipad) header.topbar .actions > a.btn-ghost:hover,
  html:not(.is-ipad) header.topbar .actions > .dropdown > .btn-ghost:hover,
  html:not(.is-ipad) header.topbar .actions > .btn-outline-secondary:hover{
    color:#5845d8;
    border-color:rgba(89,71,215,.15) !important;
    background:rgba(100,82,231,.075) !important;
    box-shadow:0 5px 13px rgba(82,72,178,.08) !important;
    transform:translateY(-1px);
  }

  html:not(.is-ipad) header.topbar .actions > .dropdown > .btn.btn-primary{
    min-width:92px;
    padding:8px 13px;
    border:0 !important;
    color:#fff;
    background:linear-gradient(135deg, #7055ed 0%, #4b7ff2 52%, #16afd3 100%) !important;
    box-shadow:0 8px 18px rgba(79,91,222,.24) !important;
    transition:transform .16s ease, filter .16s ease, box-shadow .16s ease;
  }

  html:not(.is-ipad) header.topbar .actions > .dropdown > .btn.btn-primary:hover{
    filter:saturate(1.08) brightness(1.025);
    box-shadow:0 11px 22px rgba(79,91,222,.30) !important;
    transform:translateY(-1px);
  }

  html:not(.is-ipad) header.topbar .actions .btn-chip{
    min-height:40px;
    padding:9px 14px;
    border-radius:12px;
    box-shadow:none;
  }

  html:not(.is-ipad) header.topbar .actions .btn-chip--ghost{
    border-color:rgba(91,78,206,.18);
    background:#fff;
    color:#5c4bdb;
  }

  html:not(.is-ipad) header.topbar .actions .btn-chip--primary{
    border:0;
    background:linear-gradient(135deg, #7055ed, #1caed3);
    box-shadow:0 8px 18px rgba(79,91,222,.22);
  }

  html:not(.is-ipad) header.topbar .actions .home-account-avatar{
    min-width:42px;
    min-height:42px;
    padding:0;
    overflow:hidden;
    border-color:rgba(89,71,215,.16) !important;
    background:#f7f8ff !important;
  }

  html:not(.is-ipad) header.topbar .actions .home-account-avatar__image{
    width:38px;
    height:38px;
    margin:1px;
  }

  html:not(.is-ipad) header.topbar .actions .home-account-avatar__fallback{
    width:34px;
    height:34px;
  }

  html:not(.is-ipad) header.topbar .actions .fw-bold{
    max-width:122px;
    overflow:hidden;
    text-overflow:ellipsis;
    white-space:nowrap;
  }

  html:not(.is-ipad) header.topbar :is(button, a, input):focus-visible{
    outline:3px solid rgba(78,107,242,.30);
    outline-offset:2px;
  }

  html:not(.is-ipad) body[data-theme="dark"] header.topbar{
    background:linear-gradient(180deg, rgba(12,18,36,.94), rgba(12,18,36,.80)) !important;
    border-bottom-color:rgba(255,255,255,.08) !important;
    box-shadow:0 7px 22px rgba(0,0,0,.20) !important;
  }

  html:not(.is-ipad) body[data-theme="dark"] header.topbar .topbar__inner{
    border-color:rgba(157,148,255,.18) !important;
    background:rgba(21,29,52,.90) !important;
    box-shadow:0 12px 30px rgba(0,0,0,.22), 0 1px 0 rgba(255,255,255,.045) inset !important;
  }

  html:not(.is-ipad) body[data-theme="dark"] header.topbar .searchbar-wrap{
    border-color:rgba(255,255,255,.10) !important;
    background:rgba(255,255,255,.065) !important;
    box-shadow:inset 0 1px 0 rgba(255,255,255,.035) !important;
  }

  html:not(.is-ipad) body[data-theme="dark"] header.topbar .searchbar-wrap:focus-within{
    border-color:rgba(146,132,255,.55) !important;
    background:rgba(255,255,255,.09) !important;
  }

  html:not(.is-ipad) body[data-theme="dark"] header.topbar .searchbar input.form-control,
  html:not(.is-ipad) body[data-theme="dark"] header.topbar .actions > .btn-ghost,
  html:not(.is-ipad) body[data-theme="dark"] header.topbar .actions > a.btn-ghost,
  html:not(.is-ipad) body[data-theme="dark"] header.topbar .actions > .dropdown > .btn-ghost,
  html:not(.is-ipad) body[data-theme="dark"] header.topbar .actions > .btn-outline-secondary{
    color:#e6eaff !important;
  }

  html:not(.is-ipad) body[data-theme="dark"] header.topbar #menuBtn{
    color:#e7ebff;
    border-color:rgba(255,255,255,.12);
    background:rgba(255,255,255,.07);
    box-shadow:none;
  }

  html:not(.is-ipad) body[data-theme="dark"] header.topbar .actions .btn-chip--ghost{
    border-color:rgba(255,255,255,.14);
    background:rgba(255,255,255,.06);
    color:#c9c4ff;
  }
}

@media (min-width: 992px) and (max-width: 1199.98px){
  html:not(.is-ipad) header.topbar{
    padding-inline:12px !important;
  }

  html:not(.is-ipad) header.topbar .topbar__inner{
    gap:7px !important;
    padding-inline:8px;
    border-radius:18px;
  }

  html:not(.is-ipad) header.topbar form.searchbar{
    flex-basis:300px;
    margin-inline:1px !important;
  }

  html:not(.is-ipad) header.topbar .searchbar-wrap{
    padding-inline:10px;
    gap:7px;
  }

  html:not(.is-ipad) header.topbar .actions{
    gap:2px !important;
    padding-inline-start:7px;
  }

  html:not(.is-ipad) header.topbar .actions .fw-bold{
    max-width:76px;
  }

  html:not(.is-ipad) header.topbar .actions > .dropdown > .btn.btn-primary{
    min-width:40px;
    padding-inline:11px;
  }
}

@media (prefers-reduced-motion: reduce){
  @media (min-width: 992px){
    html:not(.is-ipad) header.topbar *,
    html:not(.is-ipad) header.topbar *::before,
    html:not(.is-ipad) header.topbar *::after{
      transition:none !important;
    }
  }
}
