/* ══════════════════════════════════════════════════════════════════════════
   חיפושית — מעקב משלוחים ואיסוף · גיליון-סגנון · 31/08/2026

   חמש ההחלטות שמייצרות את התחושה, במקום אפקטים:
   1. טיפוגרפיה עושה את העבודה — Heebo בשלושה משקלים בלבד (400/700/900),
      וארבעה גדלים. לא שבעה.
   2. מסגרת במקום צל. משטח לבן על רקע חמים, קו 1px נקי. צל רק על הכרטיס
      שמחזיק את הפעולה הבאה.
   3. צבע = משמעות בלבד. ענבר דורש טיפול · כחול בתהליך · סגול בדרך ·
      ירוק הושלם. הסטטוס הוא גלולה קטנה, לא צביעה של הכרטיס כולו.
   4. רשת של 4px. 8/12/16/24 בלבד. העקביות הזו היא מה שגורם למסך-ניהול
      להרגיש יקר.
   5. שינוי-מצב הוא האירוע הוויזואלי היחיד: הכפתור ננעל, הכרטיס מחליק
      למקומו החדש. בלי קונפטי, בלי מודאל.
   ══════════════════════════════════════════════════════════════════════════ */

.ff-wrap {
  max-width: 780px; margin: 0 auto;
  /* מספרים מיושרים — מחירים, טלפונים ותאריכים חייבים ליפול על אותו ציר */
  font-variant-numeric: tabular-nums;
}

/* ══ רצועת-הלשוניות במובייל ══
   🔴 עם 8 לשוניות היא נשברת ל-4 שורות ותופסת כמעט חצי מסך — והיא sticky,
   כלומר החצי הזה אבוד לתמיד. הפתרון: במובייל היא **נגללת החוצה** ככל
   רכיב אחר, ובמקומה שורת-הסיכום היא זו שנשארת דבוקה. כך התוכן מקבל את
   כל המסך, ומה שנשאר לנגד העיניים הוא מה שבאמת צריך להיות שם.
   (נגללת-אופקית נשקלה ונפסלה: הלשונית הפעילה נופלת מחוץ למסך.)

   🪤 בלוק ה-<style> של admin.html מגיע **אחרי** הגיליון הזה, ולכן חוק
   באותה ספציפיות מפסיד בסדר-המקור. הכפלת המחלקה מעלה ספציפיות בלי
   להיתלות במבנה ה-DOM. */
@media (max-width: 700px) {
  .adm-tabs.adm-tabs { position: static; }
}
/* טלפון שכוב: רחב מ-700 אבל נמוך — רצועה דביקה אוכלת את אותו חצי-מסך.
   הבעיה היא בעיית-גובה, ולכן הכלל השני נקבע לפי גובה. */
@media (max-height: 500px) {
  .adm-tabs.adm-tabs { position: static; }
}

/* ── שורת-הסיכום: מה קורה עכשיו, בלי לגלול ──
   🪤 גובה רצועת-הלשוניות משתנה לפי רוחב-המסך ומספר הלשוניות, ולכן
   offset קבוע היה מחביא את הסיכום מאחוריה. הערך נמדד בזמן-ריצה
   ונכתב ל---ff-top על ידי admin-ff.js. */
.ff-head {
  position: sticky; top: var(--ff-top, 118px); z-index: 20;
  display: flex; align-items: center; gap: 12px;
  /* 🪤 backdrop-filter נוסה כאן ונפסל: הוא יוצר שכבת-קומפוזיציה שמעכבת
     את הצביעה ומשאירה את האזור ריק לרגע. רקע אטום עושה את אותה עבודה. */
  background: #FDFBF7; box-shadow: 0 6px 14px -12px rgba(35,30,31,.5);
  border-bottom: 1px solid var(--line);
  padding: 14px 4px 12px; margin-bottom: 4px;
}
.ff-sum { flex: 1; font-size: 16px; font-weight: 400; color: var(--ink-soft); line-height: 1.5; }
.ff-sum b { font-weight: 900; color: var(--ink); font-size: 19px; }
.ff-sdim { color: #CFC6C2; margin: 0 2px; }
.ff-brline { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.ff-refresh {
  width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--line);
  background: #fff; font-size: 18px; color: var(--ink-soft); flex-shrink: 0;
  transition: transform .2s, color .2s;
}
.ff-refresh:hover { color: var(--red); transform: rotate(90deg); }

.ff-alert {
  background: #FFF6E8; border: 1px solid #F0DDBC; color: #8A4B00;
  border-radius: 12px; padding: 11px 14px; font-size: 14px; font-weight: 700;
  margin-bottom: 12px;
}

.ff-list { display: flex; flex-direction: column; gap: 12px; }
.ff-list-done { margin-top: 12px; opacity: .78; }

/* ══ הכרטיס ══ */
.ff-card {
  background: #fff; border: 1px solid var(--line); border-radius: 16px;
  padding: 16px; position: relative; overflow: hidden;
  animation: ffIn .22s ease both;
}
@keyframes ffIn { from { opacity: 0; transform: translateY(6px); } }
/* פס-מצב דק בקצה — נותן סריקה מהירה בלי לצבוע את כל הכרטיס */
.ff-card::before {
  content: ''; position: absolute; inset-inline-start: 0; top: 0; bottom: 0; width: 4px;
}
.ff-card.ff-packing::before { background: #E09F3E; }
.ff-card.ff-ready::before   { background: #2C6FB0; }
.ff-card.ff-out::before     { background: #7A52C4; }
.ff-card.ff-done::before    { background: #CFE3D6; }
.ff-card.ff-packing { box-shadow: 0 2px 14px rgba(224,159,62,.13); }

.ff-top { display: flex; align-items: flex-start; gap: 12px; }
.ff-who { flex: 1; min-width: 0; }
.ff-name { font-size: 18px; font-weight: 900; line-height: 1.3; unicode-bidi: plaintext; }
.ff-meta { font-size: 12.5px; color: #8B8082; margin-top: 3px; }

.ff-pill {
  display: inline-flex; align-items: center; gap: 6px; flex-shrink: 0;
  border-radius: 20px; padding: 5px 12px; font-size: 13px; font-weight: 800; white-space: nowrap;
}
.ff-pill i { width: 7px; height: 7px; border-radius: 50%; display: block; }

.ff-facts {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  margin-top: 12px; font-size: 14px; color: var(--ink-soft);
}
.ff-fact b { font-weight: 900; color: var(--ink); font-size: 16px; }
.ff-sep { width: 3px; height: 3px; border-radius: 50%; background: #D8D0CC; }
.ff-addr { unicode-bidi: plaintext; }
.ff-branch {
  border-radius: 8px; padding: 3px 9px; font-size: 12.5px; font-weight: 800;
  white-space: nowrap;
}

.ff-flags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.ff-flag {
  font-size: 12.5px; font-weight: 700; border-radius: 8px; padding: 4px 10px;
  background: #F5F1EE; color: #6B5E60;
}
.ff-flag.hot { background: #FDEBED; color: var(--red); }

.ff-note {
  margin-top: 10px; background: #FAF8F5; border-inline-start: 3px solid #E0D8D3;
  border-radius: 8px; padding: 8px 11px; font-size: 13px; color: var(--ink-soft);
  unicode-bidi: plaintext; white-space: pre-line; overflow-wrap: break-word;
}
.ff-inferred { background: #FBF7EF; border-inline-start-color: #E0C89A; color: #7A6640; font-size: 12.5px; }
.ff-wapill {
  display: inline-block; margin-top: 10px;
  background: var(--red); color: #fff;
  border-radius: 9px; padding: 5px 12px;
  font-size: 13px; font-weight: 900; letter-spacing: .2px;
}
.ff-wared { color: var(--red); font-weight: 800; }

/* כשל-טעינה — נראה ככשל, לא כיום רגוע */
.ff-fail-mark { background: #FDEBED; color: var(--red); }
.ff-fail .ff-go { max-width: 220px; margin-inline: auto; }

/* ── שורת-הפעולה ── */
.ff-actions { display: flex; align-items: center; gap: 10px; margin-top: 16px; }
.ff-go {
  flex: 1; min-height: 50px; border-radius: 13px; background: var(--ink); color: #fff;
  font-family: inherit; font-size: 16px; font-weight: 900; padding: 0 18px;
  transition: transform .1s, background .18s;
}
.ff-go:hover:not(:disabled) { background: #3A3234; }
.ff-go:active:not(:disabled) { transform: scale(.98); }
.ff-go:disabled { opacity: .55; cursor: wait; }
.ff-go-sm { flex: 0 0 auto; min-height: 44px; font-size: 14px; }
.ff-done-mark { flex: 1; font-size: 14px; font-weight: 800; color: var(--green-mid); }

.ff-side { display: flex; gap: 8px; flex-shrink: 0; }
/* 🔴 44px+ הוא הרצפה: הבעלים לוחץ ביד אחת בסניף, בזמן שהשנייה תפוסה. */
.ff-mini {
  width: 46px; height: 46px; border-radius: 13px; border: 1px solid var(--line);
  background: #fff; display: grid; place-items: center; font-size: 19px;
  color: var(--ink); transition: border-color .18s, background .18s;
}
.ff-mini:hover { border-color: var(--ink); background: #FAF8F5; }

/* ══ פירוט ══ */
.ff-detail { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); }

/* פס-ההתקדמות — הוויזואליזציה היחידה, ורק כאן בפנים */
.ff-rail { display: flex; align-items: center; margin-bottom: 18px; }
.ff-step { display: flex; flex-direction: column; align-items: center; gap: 5px; flex-shrink: 0; }
.ff-dot {
  width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  background: #F2EEEC; color: #B9AFAB; font-size: 12px; font-weight: 900;
  border: 2px solid transparent;
}
.ff-step.on .ff-dot { background: var(--green-soft); color: var(--green); border-color: var(--green-mid); }
.ff-slbl { font-size: 11.5px; font-weight: 700; color: #9A908E; white-space: nowrap; }
.ff-step.on .ff-slbl { color: var(--ink); }
.ff-link { flex: 1; height: 2px; background: #EDE7E4; margin: 0 4px; margin-bottom: 20px; }

.ff-dgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.ff-dgrid h5 { font-size: 12px; font-weight: 900; color: #9A908E; margin-bottom: 7px; letter-spacing: .3px; }
.ff-items { list-style: none; display: flex; flex-direction: column; gap: 7px; }
.ff-items li { font-size: 13.5px; line-height: 1.5; }
.ff-items b { color: var(--ink-soft); font-weight: 700; }
.ff-engrave {
  margin-top: 4px; background: var(--green-soft); border-inline-start: 3px solid var(--green-mid);
  border-radius: 6px; padding: 5px 9px; color: var(--green); font-weight: 800; font-size: 12.5px;
}
.ff-kv { font-size: 13.5px; line-height: 1.8; color: var(--ink-soft); unicode-bidi: plaintext;
  white-space: pre-line; overflow-wrap: break-word; }
.ff-dim { color: #9A908E; }
.ff-hist { font-size: 12.5px; color: #8B8082; line-height: 1.7; }

.ff-noterow { display: flex; gap: 8px; }
.ff-input {
  flex: 1; min-width: 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px;
  font-family: inherit; font-size: 14px; background: #fff;
}
.ff-input:focus { border-color: var(--ink); outline: none; }
.ff-sec {
  border: 1px solid var(--line); border-radius: 10px; background: #fff; padding: 0 16px;
  font-family: inherit; font-weight: 800; font-size: 14px; min-height: 44px; white-space: nowrap;
}
.ff-sec:hover { border-color: var(--ink); }
.ff-undo {
  margin-top: 14px; background: none; border: none; color: #8B8082; font-family: inherit;
  font-size: 13px; font-weight: 700; text-decoration: underline; padding: 6px 0;
}
.ff-undo:hover { color: var(--red); }
.ff-detail-foot { display: flex; gap: 18px; flex-wrap: wrap; align-items: center; }
.ff-cancel { color: #A05A63; }
.ff-cancel:hover { color: var(--red); }
.ff-money b { color: var(--ink); }
.ff-more {
  text-align: center; font-size: 13px; color: #9A908E; padding: 12px;
  border: 1px dashed #E3DBD7; border-radius: 12px;
}

/* ── מקופל: הושלמו ── */
.ff-fold {
  width: 100%; margin-top: 20px; padding: 13px; border-radius: 12px;
  border: 1px dashed #DDD5D1; background: none; color: var(--ink-soft);
  font-family: inherit; font-size: 14px; font-weight: 800;
}
.ff-fold:hover { border-color: var(--ink-soft); color: var(--ink); }

/* ── יום ריק: מרגיש כמו הצלחה, לא כמו תקלה ── */
.ff-empty { text-align: center; padding: 60px 20px; }
.ff-empty-mark {
  width: 66px; height: 66px; border-radius: 50%; margin: 0 auto 18px;
  background: var(--green-soft); color: var(--green-mid);
  display: grid; place-items: center; font-size: 32px; font-weight: 900;
}
.ff-empty h3 { font-size: 21px; font-weight: 900; margin-bottom: 8px; }
.ff-empty p { font-size: 14.5px; color: var(--ink-soft); line-height: 1.7; }
.ff-empty p.ff-dim { font-size: 13px; margin-top: 4px; }

/* ── הצעת סגירת-היסטוריה ── */
.ff-bf {
  background: #fff; border: 1px solid #E5DBC8; border-inline-start: 4px solid var(--amber);
  border-radius: 14px; padding: 14px 16px; margin-bottom: 14px;
  font-size: 14px; line-height: 1.6;
  display: flex; gap: 14px; align-items: center; flex-wrap: wrap;
}
.ff-bf > div:first-child { flex: 1 1 260px; }
.ff-bf .ff-dim { display: block; font-size: 13px; margin-top: 3px; }
.ff-bf-btns { display: flex; gap: 8px; flex-shrink: 0; }
.ff-bf-names {
  flex-basis: 100%; font-size: 12.5px; color: #8B8082; padding-top: 10px;
  border-top: 1px solid var(--line); unicode-bidi: plaintext; line-height: 1.8;
}

.ff-skel { height: 132px; border-radius: 16px; background: #F2EEEC; margin-bottom: 12px; animation: ffPulse 1.3s infinite; }
@keyframes ffPulse { 50% { opacity: .55; } }

/* ══ מובייל — זו נקודת-המוצא, לא התאמה בדיעבד ══ */
@media (max-width: 700px) {
  .ff-head { font-size: 15px; }
  .ff-sum b { font-size: 17px; }
  .ff-card { padding: 14px; border-radius: 14px; }
  .ff-name { font-size: 17px; }
  /* הפעולה הראשית עוברת לשורה משלה וברוחב מלא — לא ארבעה אייקונים
     קטנטנים בשורה אחת שצריך לפגוע בהם. */
  .ff-actions { flex-direction: column-reverse; align-items: stretch; gap: 12px; }
  .ff-side { justify-content: flex-start; }
  .ff-mini { flex: 1; max-width: 88px; }
  .ff-go { width: 100%; min-height: 52px; }
  .ff-dgrid { grid-template-columns: 1fr; gap: 16px; }
  /* פס-ההתקדמות גולל אופקית בתוך עצמו במקום לרסק את הכרטיס */
  .ff-rail { overflow-x: auto; padding-bottom: 4px; }
  .ff-slbl { font-size: 10.5px; }
  .ff-bf-btns { width: 100%; }
  .ff-bf-btns button { flex: 1; }
}


/* ══ טאב אנשי-מקצוע ══ */
.pr-search { font-size: 15.5px; padding: 12px 16px; border-radius: 14px; }
.pr-chips { display: flex; gap: 8px; flex-wrap: wrap; margin: 4px 0 16px; }
.pr-chip {
  border: 1.5px solid var(--line); border-radius: 20px; background: #fff;
  padding: 8px 15px; font-family: inherit; font-size: 13.5px; font-weight: 800;
  color: var(--ink-soft); min-height: 40px;
}
.pr-chip.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.pr-chip:hover:not(.on) { border-color: var(--ink-soft); }
.pr-phone {
  flex-shrink: 0; font-size: 14px; font-weight: 800; color: var(--ink);
  background: var(--cream); border: 1px solid var(--line); border-radius: 11px;
  padding: 8px 13px; min-height: 40px; display: inline-flex; align-items: center; gap: 4px;
}
.pr-phone:hover { border-color: var(--green-mid); color: var(--green); }
.pr-form { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 14px; }
.pr-form label { font-size: 12.5px; font-weight: 800; color: var(--ink-soft); display: block; }
.pr-form label:first-child { grid-column: 1 / -1; }
.pr-form .ff-input { margin-top: 5px; width: 100%; }
.pr-form .ff-input:disabled { background: #F5F1EE; color: #9A908E; }
.pr-form-foot { display: flex; align-items: center; gap: 12px; margin-top: 14px; flex-wrap: wrap; }
.pr-foot { display: flex; align-items: center; gap: 12px; margin-top: 26px; flex-wrap: wrap; }
@media (max-width: 700px) {
  .pr-form { grid-template-columns: 1fr; }
  .pr-form-foot .ff-go-sm { width: 100%; }
}

/* כפתור-ההתנתקות בכותרת */
.adm-logout {
  background: none; border: 1px solid rgba(255,255,255,.35); border-radius: 20px;
  color: #C9BFC1; font-family: inherit; font-size: 13px; font-weight: 800;
  padding: 7px 14px; cursor: pointer; min-height: 36px;
}
.adm-logout:hover { color: #fff; border-color: #fff; }
