/* SEVENCARGO — design system */
:root {
  --navy-950: #06111c;
  --navy-900: #0a1a2a;
  --navy-800: #0f2438;
  --navy-700: #16324c;
  --navy-600: #1f4262;
  --cyan: #14dbdb;
  --cyan-soft: #7edfe2;
  --teal: #45a8bc;
  --gold: #bea686;
  --gold-soft: #dfd3b5;
  --silver: #d6f0e5;
  --ink: #0b1b2b;
  --text: #e8f3f5;
  --muted: #9bb3c2;
  --line: rgba(126, 223, 226, 0.16);
  --card: rgba(15, 36, 56, 0.72);
  --ok: #2ecc8f;
  --warn: #f2b84b;
  --danger: #ff6b6b;
  --info: #5aa9ff;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
  --grad: linear-gradient(135deg, var(--cyan) 0%, var(--teal) 55%, var(--gold) 100%);
  --font: 'Cairo', system-ui, -apple-system, 'Segoe UI', Tahoma, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; font-family: var(--font); color: var(--text); line-height: 1.6;
  background: radial-gradient(1200px 600px at 85% -10%, rgba(20, 219, 219, 0.12), transparent 60%),
              radial-gradient(900px 500px at -10% 20%, rgba(190, 166, 134, 0.10), transparent 60%),
              var(--navy-950);
  min-height: 100vh; -webkit-font-smoothing: antialiased;
}
a { color: var(--cyan-soft); text-decoration: none; }
a:hover { color: var(--cyan); }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { line-height: 1.25; margin: 0 0 .5em; }
p { margin: 0 0 1em; }
.container { width: min(1180px, 100% - 32px); margin-inline: auto; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.center { text-align: center; }
.hidden { display: none !important; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.spacer { flex: 1; }
.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 900px) { .g3, .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px) { .g2, .g3, .g4 { grid-template-columns: 1fr; } }
.ltr { direction: ltr; unicode-bidi: isolate; }
[dir=rtl] td.ltr, [dir=rtl] dd.ltr, [dir=rtl] div.ltr { text-align: right; }

/* ---------- header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; backdrop-filter: blur(14px); background: rgba(6, 17, 28, 0.78); border-bottom: 1px solid var(--line); }
.site-header .inner { display: flex; align-items: center; gap: 16px; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); font-weight: 800; letter-spacing: .5px; }
.brand img { width: 42px; height: 38px; object-fit: contain; }
.brand .name { font-size: 1.15rem; }
.brand .name b { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.nav { display: flex; gap: 4px; align-items: center; }
.nav a { color: var(--muted); padding: 8px 12px; border-radius: 10px; font-weight: 600; font-size: .95rem; }
.nav a:hover, .nav a.active { color: var(--text); background: rgba(126, 223, 226, 0.08); }
@media (max-width: 860px) { .nav .hide-sm { display: none; } }

/* ---------- buttons & inputs ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid transparent; cursor: pointer;
  font: inherit; font-weight: 700; font-size: .95rem; padding: 10px 18px; border-radius: 12px; transition: transform .15s, box-shadow .2s, background .2s, opacity .2s; white-space: nowrap; color: var(--text); background: transparent; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-primary { background: var(--grad); color: var(--ink); box-shadow: 0 8px 22px rgba(20, 219, 219, 0.25); }
.btn-primary:hover { box-shadow: 0 10px 28px rgba(20, 219, 219, 0.4); color: var(--ink); }
.btn-ghost { border-color: var(--line); background: rgba(255, 255, 255, 0.03); }
.btn-ghost:hover { border-color: rgba(126, 223, 226, 0.4); color: var(--text); }
.btn-danger { background: rgba(255, 107, 107, 0.14); border-color: rgba(255, 107, 107, 0.4); color: #ffb3b3; }
.btn-ok { background: rgba(46, 204, 143, 0.16); border-color: rgba(46, 204, 143, 0.45); color: #9ff0cd; }
.btn-wa { background: #25d366; color: #06301a; }
.btn-sm { padding: 6px 12px; font-size: .85rem; border-radius: 10px; }
.btn-lg { padding: 14px 26px; font-size: 1.05rem; border-radius: 14px; }
.btn-block { width: 100%; }
.icon-btn { width: 40px; height: 40px; padding: 0; border-radius: 12px; }

label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 6px; color: var(--silver); }
.field { margin-bottom: 14px; }
input, select, textarea {
  width: 100%; font: inherit; color: var(--text); background: rgba(6, 17, 28, 0.6); border: 1px solid var(--line);
  border-radius: var(--radius-sm); padding: 11px 13px; outline: none; transition: border-color .2s, box-shadow .2s;
}
input:focus, select:focus, textarea:focus { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(20, 219, 219, 0.15); }
textarea { min-height: 90px; resize: vertical; }
select option { background: var(--navy-900); }
input[type=checkbox], input[type=radio] { width: auto; accent-color: var(--cyan); }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 500; color: var(--text); }
.check input { margin-top: 5px; }
.hint { font-size: .8rem; color: var(--muted); margin-top: 4px; }
.err { color: var(--danger); font-size: .85rem; margin-top: 6px; }

/* ---------- cards ---------- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.card h3 { font-size: 1.05rem; }
.card.flat { box-shadow: none; }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-size: .78rem; font-weight: 700; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.04); white-space: nowrap; }
.pill.s-awaiting_payment { color: var(--warn); border-color: rgba(242, 184, 75, .4); }
.pill.s-pending { color: var(--gold-soft); border-color: rgba(190, 166, 134, .45); }
.pill.s-assigned { color: var(--info); border-color: rgba(90, 169, 255, .45); }
.pill.s-accepted { color: var(--cyan-soft); border-color: rgba(126, 223, 226, .45); }
.pill.s-picked_up { color: var(--cyan); border-color: rgba(20, 219, 219, .5); }
.pill.s-delivered, .pill.ok { color: var(--ok); border-color: rgba(46, 204, 143, .5); }
.pill.s-failed, .pill.s-cancelled, .pill.bad { color: var(--danger); border-color: rgba(255, 107, 107, .45); }
.pill.warn { color: var(--warn); border-color: rgba(242, 184, 75, .45); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; display: inline-block; }

/* ---------- hero ---------- */
.hero { padding: 72px 0 40px; position: relative; overflow: hidden; }
.hero .inner { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.hero h1 { font-size: clamp(2rem, 4.6vw, 3.4rem); font-weight: 900; }
.hero h1 .grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p.lead { font-size: 1.15rem; color: var(--muted); max-width: 560px; }
.hero .logo-wrap { position: relative; display: grid; place-items: center; }
.hero .logo-wrap img { width: min(340px, 80%); filter: drop-shadow(0 30px 60px rgba(20, 219, 219, 0.25)); animation: float 6s ease-in-out infinite; }
.hero .glow { position: absolute; inset: 10% 15%; background: radial-gradient(circle, rgba(20, 219, 219, .25), transparent 65%); filter: blur(20px); }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }
@media (max-width: 860px) { .hero .inner { grid-template-columns: 1fr; } .hero .logo-wrap { order: -1; } .hero .logo-wrap img { width: 200px; } .hero { padding-top: 36px; } }

.track-box { display: flex; gap: 8px; margin-top: 22px; max-width: 520px; background: rgba(6,17,28,.6); border: 1px solid var(--line); padding: 6px; border-radius: 14px; }
.track-box input { border: 0; background: transparent; box-shadow: none; }
.track-box input:focus { box-shadow: none; }

.section { padding: 56px 0; }
.section-title { text-align: center; margin-bottom: 32px; }
.section-title h2 { font-size: clamp(1.5rem, 3vw, 2.2rem); font-weight: 800; }
.section-title p { color: var(--muted); }
.feature { padding: 22px; }
.feature .ic { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: rgba(20, 219, 219, .1); color: var(--cyan); margin-bottom: 12px; }
.feature .ic svg { width: 24px; height: 24px; }
.steps { counter-reset: step; }
.step { position: relative; padding-top: 44px; }
.step::before { counter-increment: step; content: counter(step); position: absolute; top: 14px; inset-inline-start: 20px; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; background: var(--grad); color: var(--ink); }
.step h3 { margin-top: 8px; }
.prohibited-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.prohibited-list li { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; background: rgba(255, 107, 107, .06); border: 1px solid rgba(255, 107, 107, .2); border-radius: 12px; }
.prohibited-list li::before { content: '⛔'; }
@media (max-width: 620px) { .prohibited-list { grid-template-columns: 1fr; } }

.site-footer { border-top: 1px solid var(--line); padding: 28px 0 90px; margin-top: 40px; color: var(--muted); font-size: .9rem; }
.site-footer .inner { display: flex; gap: 16px; flex-wrap: wrap; align-items: center; justify-content: space-between; }
.site-footer nav { display: flex; gap: 16px; flex-wrap: wrap; }

.wa-float { position: fixed; bottom: 20px; inset-inline-end: 20px; z-index: 60; width: 56px; height: 56px; border-radius: 50%; background: #25d366; display: grid; place-items: center; box-shadow: 0 10px 25px rgba(37, 211, 102, .4); }
.wa-float svg { width: 30px; height: 30px; fill: #fff; }

/* ---------- dropdown ---------- */
.dropdown { position: relative; }
.dropdown-menu { position: absolute; top: calc(100% + 8px); inset-inline-end: 0; min-width: 220px; background: var(--navy-800); border: 1px solid var(--line); border-radius: 14px; padding: 6px; box-shadow: var(--shadow); display: none; z-index: 70; }
.dropdown.open .dropdown-menu { display: block; animation: fadeIn .15s ease; }
.dropdown-menu a { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 10px; color: var(--text); font-weight: 600; }
.dropdown-menu a:hover { background: rgba(126, 223, 226, 0.08); }
.dropdown-menu a small { display: block; color: var(--muted); font-weight: 400; }

/* ---------- animations ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } .hero .logo-wrap img { animation: none; } }

/* ---------- toast & modal ---------- */
.toasts { position: fixed; top: 80px; inset-inline-end: 16px; z-index: 200; display: flex; flex-direction: column; gap: 8px; max-width: min(380px, calc(100% - 32px)); }
.toast { background: var(--navy-800); border: 1px solid var(--line); border-inline-start: 4px solid var(--cyan); border-radius: 12px; padding: 12px 14px; box-shadow: var(--shadow); animation: fadeIn .2s ease; font-size: .92rem; }
.toast.error { border-inline-start-color: var(--danger); }
.toast.ok { border-inline-start-color: var(--ok); }
.toast b { display: block; }
.modal-back { position: fixed; inset: 0; background: rgba(3, 9, 15, .72); z-index: 150; display: grid; place-items: center; padding: 16px; animation: fadeIn .15s ease; }
.modal { width: min(560px, 100%); max-height: calc(100vh - 32px); overflow: auto; background: var(--navy-900); border: 1px solid var(--line); border-radius: 18px; padding: 22px; box-shadow: var(--shadow); }
.modal.wide { width: min(980px, 100%); }
.modal-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.modal-head h3 { margin: 0; flex: 1; }

/* ---------- map ---------- */
.map { height: 340px; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); background: var(--navy-800); z-index: 1; }
.map.tall { height: 520px; }
.leaflet-container { font-family: var(--font); }
.leaflet-popup-content-wrapper, .leaflet-popup-tip { background: var(--navy-800); color: var(--text); }
.pin { width: 30px; height: 30px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); display: grid; place-items: center; border: 2px solid #fff; box-shadow: 0 4px 10px rgba(0,0,0,.4); }
.pin span { transform: rotate(45deg); font-weight: 800; font-size: 12px; color: var(--ink); }
.pin.a { background: var(--cyan); }
.pin.b { background: var(--gold); }
.car-pin { width: 34px; height: 34px; border-radius: 50%; background: var(--navy-900); border: 3px solid var(--cyan); display: grid; place-items: center; font-size: 17px; box-shadow: 0 0 0 6px rgba(20,219,219,.2); }
.car-pin.off { border-color: var(--muted); box-shadow: none; opacity: .7; }

/* ---------- stepper (order) ---------- */
.stepper { display: flex; gap: 8px; margin-bottom: 20px; }
.stepper .st { flex: 1; height: 6px; border-radius: 6px; background: rgba(255,255,255,.08); overflow: hidden; }
.stepper .st.on { background: var(--grad); }
.price-box { background: rgba(6, 17, 28, .6); border: 1px dashed rgba(126, 223, 226, .35); border-radius: 14px; padding: 14px 16px; }
.price-row { display: flex; justify-content: space-between; padding: 4px 0; font-size: .95rem; }
.price-row.total { border-top: 1px solid var(--line); margin-top: 6px; padding-top: 10px; font-weight: 800; font-size: 1.2rem; color: var(--cyan); }
.pay-opts { display: grid; gap: 10px; }
.pay-opt { display: flex; gap: 12px; align-items: center; border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; cursor: pointer; transition: border-color .2s, background .2s; }
.pay-opt:has(input:checked) { border-color: var(--cyan); background: rgba(20, 219, 219, .07); }
.pay-opt.disabled { opacity: .5; cursor: not-allowed; }
.photo-drop { border: 1.5px dashed rgba(126, 223, 226, .4); border-radius: 14px; padding: 18px; text-align: center; cursor: pointer; background: rgba(6,17,28,.4); }
.photo-drop img { max-height: 180px; margin: 10px auto 0; border-radius: 10px; }
.success-box { text-align: center; padding: 28px 18px; }
.success-box .big { font-size: 2rem; font-weight: 900; letter-spacing: 2px; direction: ltr; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.code-box { display: inline-block; font-size: 1.8rem; font-weight: 900; letter-spacing: 8px; padding: 6px 16px; border-radius: 12px; border: 1px dashed var(--gold); color: var(--gold-soft); direction: ltr; }

/* ---------- timeline ---------- */
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline li { position: relative; padding: 0 0 18px; padding-inline-start: 30px; }
.timeline li::before { content: ''; position: absolute; inset-inline-start: 8px; top: 8px; bottom: -8px; width: 2px; background: var(--line); }
.timeline li:last-child::before { display: none; }
.timeline li::after { content: ''; position: absolute; inset-inline-start: 2px; top: 5px; width: 14px; height: 14px; border-radius: 50%; background: var(--navy-700); border: 2px solid var(--teal); }
.timeline li.done::after { background: var(--cyan); border-color: var(--cyan); }
.timeline li.bad::after { background: var(--danger); border-color: var(--danger); }
.timeline .t { font-weight: 700; }
.timeline .d { font-size: .8rem; color: var(--muted); }

/* ---------- chat ---------- */
.chat { display: flex; flex-direction: column; height: 380px; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: rgba(6,17,28,.5); }
.chat .msgs { flex: 1; overflow-y: auto; padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.chat .msg { max-width: 80%; padding: 8px 12px; border-radius: 14px; background: var(--navy-700); font-size: .93rem; word-wrap: break-word; white-space: pre-wrap; }
.chat .msg.me { align-self: flex-end; background: rgba(20, 219, 219, .18); border: 1px solid rgba(20,219,219,.3); }
.chat .msg .who { display: block; font-size: .72rem; color: var(--muted); font-weight: 700; margin-bottom: 2px; }
.chat .msg.admin .who { color: var(--gold-soft); }
.chat .msg.driver .who { color: var(--cyan-soft); }
.chat form { display: flex; gap: 8px; padding: 8px; border-top: 1px solid var(--line); background: rgba(6,17,28,.6); }
.chat form input { flex: 1; }

/* ---------- tables ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; }
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { padding: 10px 12px; text-align: start; border-bottom: 1px solid var(--line); white-space: nowrap; }
th { color: var(--muted); font-weight: 700; font-size: .8rem; background: rgba(6,17,28,.5); position: sticky; top: 0; }
tr:last-child td { border-bottom: 0; }
tbody tr { cursor: default; }
tbody tr.click { cursor: pointer; }
tbody tr.click:hover { background: rgba(126, 223, 226, .05); }
td.wrap { white-space: normal; min-width: 200px; }

/* ---------- dashboard (admin / driver) ---------- */
.app { display: grid; grid-template-columns: 260px 1fr; min-height: 100vh; }
.sidebar { background: rgba(6, 17, 28, .9); border-inline-end: 1px solid var(--line); padding: 18px 12px; position: sticky; top: 0; height: 100vh; overflow-y: auto; display: flex; flex-direction: column; }
.sidebar .brand { padding: 4px 8px 18px; }
.side-nav { display: flex; flex-direction: column; gap: 2px; }
.side-nav a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; color: var(--muted); font-weight: 600; }
.side-nav a svg { width: 20px; height: 20px; flex: none; }
.side-nav a:hover { background: rgba(126,223,226,.06); color: var(--text); }
.side-nav a.active { background: rgba(20, 219, 219, .12); color: var(--cyan); }
.side-nav .badge { margin-inline-start: auto; background: var(--danger); color: #fff; font-size: .72rem; border-radius: 999px; padding: 0 7px; min-width: 20px; text-align: center; }
.main { padding: 22px; min-width: 0; }
.topbar { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; flex-wrap: wrap; }
.topbar h1 { font-size: 1.4rem; margin: 0; flex: 1; }
.stat { padding: 16px 18px; }
.stat .v { font-size: 1.8rem; font-weight: 900; }
.stat .l { color: var(--muted); font-size: .85rem; }
.stat.accent .v { color: var(--cyan); }
.stat.gold .v { color: var(--gold-soft); }
.stat.danger .v { color: var(--danger); }
.menu-toggle { display: none; }
@media (max-width: 960px) {
  .app { grid-template-columns: 1fr; }
  .sidebar { position: fixed; inset-block: 0; inset-inline-start: 0; width: 270px; z-index: 120; transform: translateX(-110%); transition: transform .25s; }
  [dir=rtl] .sidebar { transform: translateX(110%); }
  .sidebar.open { transform: none !important; }
  .menu-toggle { display: inline-flex; }
  .main { padding: 14px; }
}
.side-back { display: none; }
@media (max-width: 960px) { .side-back.open { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 110; } }

.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.filters input, .filters select { width: auto; min-width: 160px; flex: 1; }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.tabs button { background: transparent; border: 1px solid var(--line); color: var(--muted); padding: 7px 14px; border-radius: 999px; font: inherit; font-weight: 700; font-size: .85rem; cursor: pointer; }
.tabs button.active { background: rgba(20,219,219,.12); color: var(--cyan); border-color: rgba(20,219,219,.4); }
.kv { display: grid; grid-template-columns: 140px 1fr; gap: 6px 12px; font-size: .92rem; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; word-break: break-word; }
.photo-thumb { width: 100%; max-height: 220px; object-fit: cover; border-radius: 12px; border: 1px solid var(--line); cursor: zoom-in; }
.empty { text-align: center; padding: 40px 16px; color: var(--muted); }
.notif-list { max-height: 420px; overflow-y: auto; }
.notif { padding: 10px 12px; border-bottom: 1px solid var(--line); font-size: .9rem; cursor: pointer; }
.notif.unread { background: rgba(20,219,219,.06); }
.notif .d { color: var(--muted); font-size: .75rem; }
.bell { position: relative; }
.bell .count { position: absolute; top: -4px; inset-inline-end: -4px; background: var(--danger); color: #fff; font-size: .7rem; border-radius: 999px; min-width: 18px; height: 18px; display: grid; place-items: center; padding: 0 4px; }

/* ---------- login screen ---------- */
.login-wrap { min-height: 100vh; display: grid; place-items: center; padding: 16px; }
.login-card { width: min(420px, 100%); }
.login-card .brand { justify-content: center; margin-bottom: 8px; }
.login-card .brand img { width: 70px; height: 62px; }

/* ---------- driver mobile ---------- */
.driver-shell { max-width: 720px; margin: 0 auto; padding: 0 0 86px; }
.driver-top { position: sticky; top: 0; z-index: 40; background: rgba(6,17,28,.92); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); padding: 10px 14px; display: flex; align-items: center; gap: 10px; }
.duty-card { margin: 14px; display: flex; align-items: center; gap: 12px; }
.duty-card .state { font-weight: 800; }
.bottom-nav { position: fixed; bottom: 0; inset-inline: 0; z-index: 40; background: rgba(6,17,28,.96); border-top: 1px solid var(--line); display: flex; justify-content: space-around; padding: 6px 4px calc(6px + env(safe-area-inset-bottom)); }
.bottom-nav button { background: none; border: 0; color: var(--muted); font: inherit; font-size: .75rem; font-weight: 700; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 10px; border-radius: 10px; cursor: pointer; position: relative; }
.bottom-nav button svg { width: 22px; height: 22px; }
.bottom-nav button.active { color: var(--cyan); }
.bottom-nav .badge { position: absolute; top: 0; inset-inline-end: 4px; background: var(--danger); color: #fff; border-radius: 999px; font-size: .65rem; min-width: 16px; padding: 0 4px; }
.order-card { margin: 12px 14px; }
.order-card .route { display: grid; gap: 8px; margin: 10px 0; }
.order-card .pt { display: flex; gap: 10px; align-items: flex-start; font-size: .92rem; }
.order-card .pt .tag { flex: none; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: .75rem; font-weight: 800; color: var(--ink); }
.order-card .pt .tag.a { background: var(--cyan); }
.order-card .pt .tag.b { background: var(--gold); }
.order-card .actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.order-card .actions .btn { flex: 1; }
.cash-banner { background: rgba(242, 184, 75, .1); border: 1px solid rgba(242,184,75,.4); color: var(--warn); border-radius: 12px; padding: 8px 12px; font-weight: 700; font-size: .9rem; }

/* legal pages */
.legal { max-width: 860px; margin: 40px auto; }
.legal h1 { font-size: 2rem; }
.legal h2 { font-size: 1.2rem; margin-top: 1.6em; color: var(--cyan-soft); }
.legal li { margin-bottom: 6px; }
.lang-block[data-lang] { display: none; }
html[lang=ar] .lang-block[data-lang=ar], html[lang=en] .lang-block[data-lang=en] { display: block; }
.hp { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); opacity: 0; pointer-events: none; }
.site-header .inner { min-width: 0; }
@media (max-width: 480px) {
  .site-header .inner { gap: 8px; }
  .brand .name { font-size: 1rem; }
  .site-header .btn-sm { padding: 6px 10px; }
}
@media (max-width: 400px) { .site-header .brand { gap: 6px; } .site-header .brand img { width: 32px; height: 29px; } .site-header .brand .name { font-size: .92rem; } .site-header .inner { gap: 6px; } }
@media (max-width: 340px) { .site-header .brand .name { display: none; } }
.driver-top #d-sub, .driver-top #d-name { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 620px) { .kv { grid-template-columns: 88px 1fr; } }
@media (max-width: 620px) { .grid.g4.stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } .stat .v { font-size: 1.35rem; } .stat { padding: 12px 14px; } }

/* ---------- order page: sender / receiver side by side ---------- */
.order-page { max-width: 1180px; }
.parties { display: grid; grid-template-columns: minmax(0, 1fr) 36px minmax(0, 1fr); gap: 12px; align-items: stretch; margin: 18px 0; }
.party { --c: var(--cyan); --c-bg: rgba(20, 219, 219, .07); border-radius: var(--radius); padding: 0 18px 16px; background: var(--c-bg); border: 1.5px solid color-mix(in srgb, var(--c) 45%, transparent); border-top: 6px solid var(--c); min-width: 0; }
.party.receiver { --c: #ff9f43; --c-bg: rgba(255, 159, 67, .08); }
.party-head { display: flex; gap: 12px; align-items: center; margin: 0 -18px 14px; padding: 14px 18px; background: color-mix(in srgb, var(--c) 16%, transparent); }
.party-head h2 { margin: 0; font-size: 1.2rem; color: var(--c); }
.party-head p { margin: 2px 0 0; font-size: .88rem; color: var(--text); opacity: .85; }
.party-no { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 900; font-size: 1.2rem; background: var(--c); color: var(--ink); }
.party .field input, .party .field select, .party .field textarea { border-color: color-mix(in srgb, var(--c) 30%, transparent); }
.party .field input:focus, .party .field select:focus, .party .field textarea:focus { border-color: var(--c); box-shadow: 0 0 0 3px color-mix(in srgb, var(--c) 22%, transparent); }
.party-note { margin: 10px 0 0; padding: 10px 12px; border-radius: 10px; font-size: .88rem; background: rgba(6, 17, 28, .45); border-inline-start: 3px solid var(--c); }
.party-arrow { display: grid; place-items: center; font-size: 1.6rem; color: var(--muted); }
[dir="rtl"] .party-arrow { transform: scaleX(-1); }
.req { color: var(--danger); }
.exact-loc { margin-top: 6px; border: 1px dashed color-mix(in srgb, var(--c) 40%, transparent); border-radius: 12px; padding: 10px 12px; }
.exact-loc summary, .parcel-box summary, .pro-details summary { cursor: pointer; font-weight: 700; }
.parcel-box { margin-bottom: 16px; }
.parcel-box summary { display: flex; justify-content: space-between; gap: 10px; align-items: center; }
.pro-details { margin-top: 14px; font-size: .92rem; }
.pro-details summary { color: var(--danger); }
.info-box { text-align: start; margin: 18px auto 0; max-width: 560px; padding: 14px 16px; border-radius: 14px; background: rgba(255, 159, 67, .1); border: 1px solid rgba(255, 159, 67, .4); }
@media (max-width: 860px) {
  .parties { grid-template-columns: 1fr; gap: 8px; }
  .party-arrow { transform: rotate(90deg); font-size: 1.3rem; pointer-events: none; width: 2rem; height: 2rem; margin: 0 auto; }
  [dir="rtl"] .party-arrow { transform: rotate(90deg); }
}
.info-box .btn-wa, .info-box .btn-wa:hover { color: #06301a; }

/* زر «انضم إلينا كمندوب» في الهيدر */
.btn-join { background: rgba(190, 166, 134, 0.14); color: var(--gold-soft); border: 1px solid rgba(190, 166, 134, 0.45); font-weight: 800; }
.btn-join:hover, .btn-join.active { background: rgba(190, 166, 134, 0.26); color: #fff; }
@media (max-width: 560px) { .btn-join span[data-i18n] { display: none; } }

/* ---------- مشهد الشعار المتحرك (public/js/hero-fx.js) ---------- */
.hero .logo-wrap.fx-on { min-height: 360px; padding-bottom: 70px; }
.hero .logo-wrap.fx-on img { animation: none; will-change: transform; transition: filter .3s; position: relative; z-index: 2; }
.fx-scene { position: absolute; inset: 0; pointer-events: none; z-index: 3; }
.fx-road { position: absolute; left: 0; right: 0; bottom: 8px; width: 100%; height: 56px; }
.fx-dash { animation: fx-dash 1.4s linear infinite; }
@keyframes fx-dash { to { stroke-dashoffset: -44; } }
.fx-van { position: absolute; bottom: 22px; left: 15%; width: 26%; max-width: 128px; transform: translateX(-50%); filter: drop-shadow(0 10px 16px rgba(0,0,0,.45)); }
.fx-van svg { width: 100%; display: block; overflow: visible; }
.fx-van.moving .fx-body { animation: fx-bump .28s ease-in-out infinite alternate; }
@keyframes fx-bump { to { transform: translateY(-1.5px); } }
.fx-puff { position: absolute; left: -6px; bottom: 10px; width: 10px; height: 10px; border-radius: 50%; background: rgba(214,240,229,.35); opacity: 0; }
.fx-van.moving .fx-puff { animation: fx-puff 0.9s ease-out infinite; }
.fx-van.moving .fx-puff.p2 { animation-delay: .45s; }
@keyframes fx-puff { 0% { opacity: .7; transform: translate(0,0) scale(.6); } 100% { opacity: 0; transform: translate(-22px,-10px) scale(1.8); } }
.fx-courier { position: absolute; left: 0; bottom: 26px; width: 27%; max-width: 128px; }
[dir=ltr] .fx-courier { left: auto; right: 0; }
.fx-courier svg { width: 100%; display: block; overflow: visible; filter: drop-shadow(0 12px 18px rgba(0,0,0,.4)); }
.fx-head, .fx-eyes, .fx-arm { transition: transform .18s ease-out; transform-box: fill-box; }
.fx-head { transform-origin: 50% 90%; }
.fx-arm { transform-box: view-box !important; transform-origin: 78px 76px; }
.fx-vtext { transform-box: fill-box; transform-origin: 50% 50%; }
.fx-courier { z-index: 2; }
.fx-box { transition: transform .35s cubic-bezier(.3,1.6,.5,1); transform-box: fill-box; transform-origin: 50% 50%; }
.fx-courier.give .fx-box { transform: translate(10px,-6px) scale(1.12) rotate(-6deg); }
.fx-courier.give .fx-mouth { d: path("M52 54q8 8 16 0"); }
.fx-bubble { position: absolute; bottom: 100%; left: 50%; transform: translate(-50%, 6px) scale(.9); white-space: nowrap; background: var(--navy-800); color: var(--text); border: 1px solid var(--cyan); border-radius: 12px; padding: 4px 10px; font-size: .78rem; font-weight: 800; opacity: 0; transition: opacity .25s, transform .25s; box-shadow: 0 8px 20px rgba(0,0,0,.35); }
.fx-bubble.on { opacity: 1; transform: translate(-50%, -4px) scale(1); }
.fx-static .fx-van { left: 70%; }
@media (max-width: 860px) { .hero .logo-wrap.fx-on { min-height: 270px; padding-bottom: 56px; } .fx-van { width: 24%; } .fx-courier { width: 24%; } }
@media (prefers-reduced-motion: reduce) { .fx-dash, .fx-puff { animation: none !important; } }

/* ---------- رسالة الترحيب ---------- */
.welcome-toast { position: fixed; z-index: 90; top: 84px; left: 50%; transform: translate(-50%, -20px); opacity: 0; display: flex; gap: 12px; align-items: center;
  background: rgba(10,26,42,.96); border: 1px solid var(--cyan); border-radius: 16px; padding: 12px 16px 12px 12px; box-shadow: 0 20px 50px rgba(0,0,0,.45); max-width: min(92vw, 520px); transition: opacity .4s, transform .4s; backdrop-filter: blur(8px); }
.welcome-toast.on { opacity: 1; transform: translate(-50%, 0); }
.welcome-toast img { width: 42px; height: 38px; object-fit: contain; }
.welcome-toast b { display: block; font-size: 1rem; } .welcome-toast span { color: var(--muted); font-size: .86rem; }
.welcome-toast button { background: none; border: 0; color: var(--muted); font-size: 18px; cursor: pointer; padding: 0 0 0 4px; margin-inline-start: 6px; }
@media (max-width: 560px) {
  .site-header .inner { gap: 6px; }
  .site-header .brand .name { display: none; }
  .site-header .btn-sm { padding-inline: 10px; }
}
@media (max-width: 380px) { .site-header .nav { display: none; } }
@media (max-width: 560px) { .welcome-toast { left: 16px; right: 16px; max-width: none; transform: translateY(-20px); top: 72px; } .welcome-toast.on { transform: none; } }

/* إدارة الموظفين */
.chip { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 999px; font-size: .8rem; font-weight: 700; background: rgba(255,255,255,.06); border: 1px solid var(--line, rgba(255,255,255,.12)); vertical-align: middle; }
.chip-green { background: rgba(34,197,94,.12); border-color: rgba(34,197,94,.45); color: #4ade80; }
.chip-red { background: rgba(239,68,68,.12); border-color: rgba(239,68,68,.45); color: #f87171; }
.sf-list { display: flex; flex-direction: column; gap: 10px; }
.sf-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding: 12px 14px; border: 1px solid var(--line, rgba(255,255,255,.1)); border-radius: 14px; background: rgba(255,255,255,.02); }
.sf-row.sf-off { opacity: .75; border-color: rgba(239,68,68,.35); }
.sf-info { min-width: 220px; flex: 1; }
.sf-act { display: flex; flex-wrap: wrap; gap: 6px; }
.sf-act .btn[disabled] { opacity: .4; pointer-events: none; }
@media (max-width: 760px) { .sf-act { width: 100%; } }

.btn-sos { background: rgba(20,219,219,.10); border: 1px solid rgba(20,219,219,.45); color: #7edfe2; font-weight: 800; white-space: nowrap; }
@media (max-width: 560px) { .btn-sos span { display: none; } }
