/* חותם — עיצוב. מרווחים בשיטת 8 פיקסלים, אזורי לחיצה לפחות 48 פיקסלים.
   צבעים עם משמעות קבועה: ירוק = ממשיכים בלבד, כתום = לבדוק, אדום = עוברים הלאה, כחול-אפור = מידע ניטרלי. */
@font-face { font-family: 'Heebo'; font-style: normal; font-display: swap; font-weight: 100 900; src: url('/fonts/heebo-hebrew-wght-normal.woff2') format('woff2'); unicode-range: U+0307-0308, U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F; }
@font-face { font-family: 'Heebo'; font-style: normal; font-display: swap; font-weight: 100 900; src: url('/fonts/heebo-latin-wght-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  --bg: #f3f5f8; --card: #ffffff; --text: #0f172a; --muted: #475569; --line: #e2e8f0; --input: #ffffff;
  --head: #121d35; --head-ink: #ffffff;
  --primary: #1f3a68; --primary-ink: #ffffff;
  --go: #15803d; --go-bg: #dcfce7;
  --check: #b45309; --check-bg: #fef3c7;
  --pass: #b91c1c; --pass-bg: #fee2e2;
  --neutral: #334155; --neutral-bg: #e2e8f0;
  --t-user: #1d4ed8; --t-user-bg: #dbeafe;
  --t-ver: #166534; --t-ver-bg: #dcfce7;
  --t-est: #9a3412; --t-est-bg: #ffedd5;
  --t-ass: #475569; --t-ass-bg: #f1f5f9;
  --t-miss: #b91c1c; --t-miss-bg: #fee2e2;
  --pin-bg: #fef9c3; --pin-ink: #713f12;
  --init: #2b4566; --init-bg: #dfe7f1;
  --shadow: 0 1px 2px rgba(15, 23, 42, .06), 0 1px 8px rgba(15, 23, 42, .04);
  --r: 16px; --r-sm: 12px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --nav-h: 64px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b1220; --card: #131c2e; --text: #e5e7eb; --muted: #a3b1c6; --line: #243049; --input: #0f172a;
    --head: #0f1729; --head-ink: #f8fafc;
    --primary: #2563eb; --primary-ink: #ffffff;
    --go: #4ade80; --go-bg: #11311f;
    --check: #fbbf24; --check-bg: #34280b;
    --pass: #f87171; --pass-bg: #3b1616;
    --neutral: #cbd5e1; --neutral-bg: #26324a;
    --t-user: #93c5fd; --t-user-bg: #172554;
    --t-ver: #86efac; --t-ver-bg: #0f2e1c;
    --t-est: #fdba74; --t-est-bg: #3a1a08;
    --t-ass: #cbd5e1; --t-ass-bg: #1e293b;
    --t-miss: #fca5a5; --t-miss-bg: #3b1616;
    --pin-bg: #3a3006; --pin-ink: #fde68a;
    --init: #bcd0ea; --init-bg: #1b2a42;
    --shadow: none;
  }
}

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); }
body {
  font-family: 'Heebo', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
  font-size: 16px; line-height: 1.5;
  padding-bottom: calc(var(--nav-h) + var(--safe-b) + 8px);
  -webkit-tap-highlight-color: transparent;
}
a { color: var(--t-user); }
button, input, select, textarea { font: inherit; color: inherit; }
.num, td.num, .kval, .lcost, .lprofit { font-variant-numeric: tabular-nums; font-feature-settings: "tnum"; }
.ic { flex: none; vertical-align: middle; }
.spin { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- כותרת כללית ---------- */
.top {
  position: sticky; top: 0; z-index: 20; height: 52px;
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 0 8px 0 16px; padding-top: env(safe-area-inset-top, 0px);
  background: var(--head); color: var(--head-ink);
}
.brand { color: inherit; text-decoration: none; font-weight: 800; font-size: 20px; display: inline-flex; align-items: center; gap: 8px; }
.brand img { border-radius: 6px; }
body.pmode .top { display: none; }
.iconbtn { border: 0; background: transparent; color: inherit; min-width: 48px; min-height: 48px; display: inline-flex; align-items: center; justify-content: center; border-radius: 12px; cursor: pointer; padding: 0; }
.syncic.ok { color: #86efac; } .syncic.pend { color: #fde047; } .syncic.off { color: #fca5a5; }
.phead .syncic.ok { color: var(--go); } .phead .syncic.pend { color: var(--check); } .phead .syncic.off { color: var(--pass); }

main { padding: 16px; max-width: 760px; margin: 0 auto; }
main.pmain { padding: 0; }

/* ---------- תפריט תחתון ---------- */
.bottom {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 30;
  display: grid; grid-template-columns: repeat(5, 1fr);
  background: var(--card); border-top: 1px solid var(--line);
  padding-bottom: var(--safe-b); height: calc(var(--nav-h) + var(--safe-b));
}
.bottom a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font-size: 12px; color: var(--muted); text-decoration: none; min-height: 48px; }
.bottom a.active { color: var(--primary); font-weight: 700; }
@media (prefers-color-scheme: dark) { .bottom a.active { color: #93c5fd; } }

/* ---------- טיפוגרפיה ---------- */
h1 { font-size: 24px; font-weight: 800; margin: 8px 0 16px; }
h2 { font-size: 18px; font-weight: 700; margin: 24px 0 8px; display: flex; align-items: center; gap: 8px; }
h3 { font-size: 16px; font-weight: 700; margin: 0 0 8px; display: flex; align-items: center; gap: 8px; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.empty { text-align: center; color: var(--muted); padding: 40px 16px; font-size: 17px; }
.err { color: var(--pass); }

/* ---------- כפתורים ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 8px 16px; border-radius: var(--r-sm); border: 1px solid var(--line);
  background: var(--card); font-weight: 600; cursor: pointer; text-decoration: none; color: var(--text);
}
.btn.primary { background: var(--primary); color: var(--primary-ink); border-color: var(--primary); }
.btn.danger { color: var(--pass); border-color: var(--pass); background: transparent; }
.btn.block { width: 100%; }
.btn.small { min-height: 40px; padding: 4px 12px; font-size: 15px; }
.btn:disabled { opacity: .55; }
.linkbtn { border: 0; background: none; color: var(--t-user); padding: 8px 0; min-height: 40px; display: inline-flex; align-items: center; gap: 6px; cursor: pointer; font-size: 14px; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.row > .grow, .grow { flex: 1; min-width: 0; }
.fab {
  position: fixed; z-index: 25; left: 16px; right: 16px; bottom: calc(var(--nav-h) + var(--safe-b) + 8px);
  max-width: 728px; margin: 0 auto; min-height: 56px; font-size: 18px; border-radius: var(--r); box-shadow: 0 6px 16px rgba(15, 23, 42, .25);
}
.has-fab { padding-bottom: 88px; }

/* ---------- כרטיסים ---------- */
.card { background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); border: 1px solid var(--line); padding: 16px; margin-bottom: 8px; }

/* כרטיס מוצר ברשימה */
.pcard { display: flex; gap: 12px; align-items: center; text-decoration: none; color: inherit; min-height: 72px; }
.card:has(> .pcard) { padding: 12px; }
.pcard .thumb { width: 64px; height: 64px; border-radius: var(--r-sm); object-fit: cover; background: var(--neutral-bg); color: var(--muted); flex: none; display: flex; align-items: center; justify-content: center; }
.pcard .info { flex: 1; min-width: 0; }
.pcard .title { font-weight: 700; font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pcard .meta { font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pcard .nums { font-size: 14px; }
.lrow { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-top: 4px; }
.lnums { flex: none; text-align: left; min-width: 76px; }
.lcost { font-size: 17px; font-weight: 800; line-height: 1.2; }
.lprofit { font-size: 15px; font-weight: 700; line-height: 1.2; margin-top: 4px; }
.lprofit.low { color: var(--pass); }
.lsub { font-size: 11px; color: var(--muted); }
.pick { width: 24px; height: 24px; flex: none; }

/* ---------- חותמות ---------- */
.stamp { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 999px; font-weight: 700; font-size: 14px; white-space: nowrap; }
.stamp b { font-size: 16px; }
.stamp.go { color: var(--go); background: var(--go-bg); }
.stamp.check { color: var(--check); background: var(--check-bg); }
.stamp.pass { color: var(--pass); background: var(--pass-bg); }
.stamp.none { color: var(--neutral); background: var(--neutral-bg); }
/* הערכה ראשונית: כחול-אפור עם מסגרת מקווקוות — לא ירוק, לא כתום ולא אדום */
.stamp.initial { color: var(--init); background: var(--init-bg); box-shadow: none; outline: 1.5px dashed var(--init); outline-offset: -1.5px; }
.stamp.sm { padding: 2px 10px; font-size: 13px; }
.stamp.sm b { font-size: 14px; }
.stamp.big { padding: 8px 16px; font-size: 20px; }
.stamp.big b { font-size: 24px; }
.conf { display: inline-flex; align-items: center; gap: 4px; min-height: 36px; padding: 4px 12px; border-radius: 999px; border: 0; background: var(--neutral-bg); color: var(--neutral); font-weight: 600; font-size: 14px; cursor: pointer; }

/* ---------- תגיות מקור ---------- */
.src { display: inline-flex; align-items: center; gap: 3px; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 999px; vertical-align: middle; white-space: nowrap; text-decoration: none; line-height: 1.5; border: 0; }
.src-user { background: var(--t-user-bg); color: var(--t-user); }
.src-verified { background: var(--t-ver-bg); color: var(--t-ver); }
.src-estimate { background: var(--t-est-bg); color: var(--t-est); }
.src-assumption { background: var(--t-ass-bg); color: var(--t-ass); }
.src-missing { background: var(--t-miss-bg); color: var(--t-miss); }
.src-calcreal { background: transparent; color: var(--neutral); box-shadow: inset 0 0 0 1px var(--neutral); }
.srcbtn { cursor: pointer; min-height: 28px; font-family: inherit; }

/* ---------- טופס ---------- */
input[type=text], input[type=search], input[type=password], input[type=email], input[type=tel], input:not([type]), select, textarea {
  width: 100%; min-height: 48px; padding: 8px 12px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--input);
}
textarea { min-height: 96px; resize: vertical; line-height: 1.5; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--t-user); outline-offset: 0; border-color: transparent; }
label.f { display: block; margin-bottom: 12px; }
label.f > span, .flabel { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 14px; color: var(--muted); margin-bottom: 4px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
.grid3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 0 8px; }
.seg { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; }
.seg button { text-align: start; min-height: 48px; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--card); padding: 8px 12px; cursor: pointer; }
.seg button.on { border: 2px solid var(--primary); font-weight: 700; background: color-mix(in srgb, var(--primary) 10%, var(--card)); }
.checks label, label.chk { display: flex; gap: 12px; align-items: center; min-height: 48px; padding: 4px 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.checks input, label.chk input { width: 22px; height: 22px; flex: none; }
.careful { margin: -4px 0 12px; }
.carefulbtn { border-style: dashed; }
.chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; }
.chip { flex: none; border: 1px solid var(--line); background: var(--card); border-radius: 999px; padding: 8px 16px; font-size: 15px; min-height: 40px; cursor: pointer; }
.chip.on { background: var(--primary); color: var(--primary-ink); border-color: var(--primary); }

/* ---------- מסך מוצר: כותרת קומפקטית ---------- */
.phead { position: sticky; top: 0; z-index: 22; background: var(--card); border-bottom: 1px solid var(--line); padding: 2px 4px 4px 8px; padding-top: calc(2px + env(safe-area-inset-top, 0px)); }
.ph1 { display: flex; align-items: center; gap: 8px; min-height: 48px; }
.phthumb { width: 36px; height: 36px; border-radius: 10px; object-fit: cover; flex: none; }
.ph-empty { display: inline-flex; align-items: center; justify-content: center; background: var(--neutral-bg); color: var(--muted); }
.phtitles { flex: 1; min-width: 0; }
.phname { font-weight: 800; font-size: 17px; line-height: 1.25; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.phsub { font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; line-height: 1.3; }
.phmini { display: none; align-items: center; gap: 6px; font-size: 14px; white-space: nowrap; }
.ph2 { display: flex; align-items: center; gap: 16px; padding: 0 8px 0 4px; min-height: 24px; }
.phk { display: inline-flex; align-items: baseline; gap: 4px; }
.phk small { font-size: 12px; color: var(--muted); }
.phk b { font-size: 17px; font-weight: 800; }
.phead.mini { padding-bottom: 4px; }
.phead.mini .ph2, .phead.mini .phsub, .phead.mini .phthumb { display: none; }
.phead.mini .phmini { display: inline-flex; }
.ptabs { position: sticky; z-index: 21; top: calc(79px + env(safe-area-inset-top, 0px)); display: grid; grid-template-columns: repeat(4, 1fr); background: var(--card); border-bottom: 1px solid var(--line); }
body.pmode .phead.mini + .ptabs { top: calc(55px + env(safe-area-inset-top, 0px)); }
.ptabs button { min-height: 43px; border: 0; background: none; color: var(--muted); font-weight: 600; font-size: 14px; display: flex; align-items: center; justify-content: center; gap: 6px; border-bottom: 3px solid transparent; cursor: pointer; }
.ptabs button.on { color: var(--text); border-bottom-color: var(--primary); }
@media (prefers-color-scheme: dark) { .ptabs button.on { border-bottom-color: #93c5fd; } }
.tabpad { padding: 16px; max-width: 760px; margin: 0 auto; }

/* ---------- לשונית החלטה ---------- */
.pinned { display: flex; gap: 8px; align-items: flex-start; background: var(--pin-bg); color: var(--pin-ink); border-radius: var(--r-sm); padding: 12px; margin-bottom: 8px; font-weight: 600; }
.jobbar { display: flex; gap: 8px; align-items: center; padding: 12px; border-radius: var(--r-sm); background: var(--neutral-bg); color: var(--neutral); margin-bottom: 8px; font-size: 14px; }
.dcard .drow { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.dwhy { font-size: 16px; margin: 12px 0; }
.maxrow { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 17px; padding: 12px; border-radius: var(--r-sm); margin-bottom: 12px; }
.maxrow b { font-size: 19px; font-weight: 800; }
.maxrow.good { background: var(--go-bg); color: var(--go); }
.maxrow.bad { background: var(--pass-bg); color: var(--pass); }
.maxrow.est { background: var(--init-bg); color: var(--init); }
.maxrow > span { flex: 1; min-width: 180px; }
.partialbar { background: var(--check-bg); color: var(--check); font-weight: 700; font-size: 14px; padding: 8px 12px; border-radius: var(--r-sm); margin: 0 0 12px; }
.vsum { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media (min-width: 560px) { .vsum { grid-template-columns: 1fr 1fr; } }
.vlist { list-style: none; padding: 0; margin: 0; }
.vlist li { display: flex; gap: 8px; align-items: flex-start; padding: 6px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.vlist li:last-child { border-bottom: 0; }
.vlist li > span { flex: 1; min-width: 0; }
.vlist .ok { color: var(--t-ver); margin-top: 2px; } .vlist .bad { color: var(--t-miss); margin-top: 2px; } .vlist .mute { color: var(--muted); margin-top: 2px; }
.vlist .lnk { min-width: 40px; min-height: 40px; display: inline-flex; align-items: center; justify-content: center; margin: -8px 0; color: var(--t-user); }
.how { color: var(--muted); font-size: 12.5px; }
details.more > summary { list-style: none; display: flex; align-items: center; gap: 6px; min-height: 44px; color: var(--t-user); font-weight: 600; font-size: 14px; cursor: pointer; }
details.more > summary::-webkit-details-marker { display: none; }
.kgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 8px; }
.kcell { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 12px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 4px; }
.klabel { font-size: 13px; color: var(--muted); }
.kval { font-size: 22px; font-weight: 800; line-height: 1.2; }
.ksub { font-size: 12.5px; color: var(--muted); }
details.dsec, details.fgroup { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); margin-bottom: 8px; box-shadow: var(--shadow); }
details.dsec > summary, details.fgroup > summary { display: flex; align-items: center; gap: 8px; min-height: 52px; padding: 8px 16px; cursor: pointer; list-style: none; }
details.dsec > summary::-webkit-details-marker, details.fgroup > summary::-webkit-details-marker { display: none; }
.st { font-weight: 700; font-size: 16px; white-space: nowrap; }
.ss { flex: 1; min-width: 0; color: var(--muted); font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ss::before { content: '· '; }
.gmiss { flex: 1; }
.chev { transition: transform .15s; color: var(--muted); }
details[open] > summary .chev { transform: rotate(180deg); }
.dbody, .fbody { padding: 0 16px 16px; }
.foldgroup { margin-top: 16px; opacity: .95; }
.ins, .plain { list-style: none; padding: 0; margin: 0; }
.ins li { display: flex; gap: 8px; align-items: flex-start; padding: 8px 0; border-bottom: 1px solid var(--line); }
.ins li:last-child { border-bottom: 0; }
.ins li .ic { color: var(--check); margin-top: 3px; }
.plain li { padding: 6px 0; }
.plain .warn { color: var(--check); }
.rec { font-size: 14.5px; margin-top: 12px; }
.lnk { color: var(--t-user); text-decoration: none; display: inline-flex; align-items: center; gap: 4px; }
.legendline { text-align: center; margin: 16px 0 8px; }
.q { border-bottom: 1px dashed var(--line); padding: 12px 0; }
.q div { margin: 2px 0; }
.q .en { direction: ltr; text-align: left; color: var(--muted); font-size: 14px; }
.q .zh { direction: ltr; text-align: left; font-size: 17px; }
.qbtns { margin-top: 8px; }

/* ---------- לשונית נתונים ---------- */
.datatab { padding-bottom: 8px; }
.anaspacer { height: 72px; }
.anabar { position: fixed; z-index: 24; left: 0; right: 0; bottom: calc(var(--nav-h) + var(--safe-b)); padding: 8px 16px; background: linear-gradient(to top, var(--bg) 70%, transparent); }
.anabtn { width: 100%; max-width: 728px; margin: 0 auto; min-height: 52px; font-size: 17px; display: flex; }
.anabtn.busy { align-items: center; gap: 8px; justify-content: center; background: var(--neutral-bg); color: var(--neutral); border-radius: var(--r-sm); padding: 0 12px; font-weight: 600; font-size: 15px; }

/* ---------- לשונית תמונות ---------- */
.gallery { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.gitem { position: relative; }
.gitem img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: var(--r-sm); display: block; }
.gdel { position: absolute; top: 4px; left: 4px; background: rgba(0, 0, 0, .55); color: #fff; min-width: 40px; min-height: 40px; border-radius: 999px; }

/* ---------- כללי ---------- */
.progress { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: var(--r-sm); background: var(--neutral-bg); color: var(--neutral); margin: 8px 0; }
.spinner { width: 22px; height: 22px; border: 3px solid var(--line); border-top-color: var(--primary); border-radius: 50%; animation: spin 1s linear infinite; flex: none; }
.analysis { font-size: 15.5px; }
.analysis h3 { border-top: 1px solid var(--line); padding-top: 12px; }
.analysis ul, .analysis ol { padding-inline-start: 20px; margin: 4px 0; }
details.hist summary { padding: 8px 0; cursor: pointer; }
pre.raw { white-space: pre-wrap; word-break: break-word; font-size: 13px; background: var(--neutral-bg); padding: 8px; border-radius: 8px; max-height: 300px; overflow: auto; }
.task { display: flex; gap: 12px; align-items: center; min-height: 52px; border-bottom: 1px solid var(--line); }
.task input { width: 24px; height: 24px; flex: none; }
.table-wrap { overflow-x: auto; }
table.cmp { border-collapse: collapse; width: 100%; font-size: 14px; }
table.cmp th, table.cmp td { border-bottom: 1px solid var(--line); padding: 8px 6px; text-align: start; vertical-align: top; }
table.cmp th { color: var(--muted); font-weight: 600; white-space: nowrap; }
table.prices td { vertical-align: middle; }
table.prices .unitp { font-size: 16px; }
table.bd { width: 100%; border-collapse: collapse; font-size: 14px; }
table.bd td { border-bottom: 1px solid var(--line); padding: 8px 4px; vertical-align: top; }
table.bd td.num { white-space: nowrap; text-align: left; }
table.bd tr.tot td { font-weight: 700; }
.warnbar { background: var(--check-bg); color: var(--check); font-weight: 700; padding: 12px; border-radius: var(--r-sm); margin: 8px 0; }
.failbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; background: var(--pass-bg); color: var(--pass); font-weight: 700; padding: 12px; border-radius: var(--r-sm); margin-bottom: 8px; }
.jobtag { display: inline-block; font-size: 12.5px; font-weight: 700; padding: 2px 10px; border-radius: 999px; }
.jobtag.run { background: var(--neutral-bg); color: var(--neutral); }
.jobtag.ready { background: var(--primary); color: var(--primary-ink); }
.jobtag.fail { background: var(--pass-bg); color: var(--pass); }
.shipline, .rateline { font-size: 13px; color: var(--muted); margin-top: 4px; }
.moreitem { display: flex; align-items: center; gap: 12px; text-decoration: none; color: inherit; min-height: 64px; }

.modal { position: fixed; inset: 0; z-index: 50; background: rgba(2, 6, 23, .5); display: flex; align-items: flex-end; justify-content: center; padding: 16px; }
.modal[hidden] { display: none; }
.modal .box { background: var(--card); border-radius: 20px; padding: 16px; width: 100%; max-width: 520px; margin-bottom: var(--safe-b); max-height: 85vh; overflow-y: auto; }
.modal .box p { font-size: 17px; margin-top: 0; }
.infobox p { font-size: 15px !important; }
.whylist { list-style: none; padding: 0; margin: 8px 0 0; }
.whylist li { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.toast { position: fixed; z-index: 60; left: 16px; right: 16px; bottom: calc(var(--nav-h) + var(--safe-b) + 80px); margin: 0 auto; max-width: 520px; background: #0f172a; color: #fff; padding: 12px 16px; border-radius: var(--r-sm); text-align: center; }
.toast[hidden] { display: none; }
.login { max-width: 380px; margin: 40px auto; }
.fullq { position: fixed; inset: 0; z-index: 45; background: #fff; color: #111; display: flex; flex-direction: column; justify-content: center; padding: 24px; text-align: center; }
.fullq .zh-big { font-size: 34px; line-height: 1.45; font-weight: 700; direction: ltr; }
.fullq .en-big { font-size: 20px; margin-top: 16px; direction: ltr; color: #333; }
.fullq .he-small { font-size: 15px; margin-top: 16px; color: #555; }

/* ---------- הערכה ראשונית ---------- */
.basisline { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 48px; margin-top: 12px; padding: 8px 12px; border: 0; border-radius: var(--r-sm); background: var(--init-bg); color: var(--init); font: inherit; font-size: 14px; text-align: start; cursor: pointer; }
.basisline span { flex: 1; }
.anahint { font-size: 12px; font-weight: 600; color: var(--t-est); }
.anahint.cmp { color: var(--muted); font-weight: 500; }
.estnote { display: flex; gap: 6px; align-items: flex-start; flex-wrap: wrap; margin: -4px 0 12px; font-size: 13px; color: var(--muted); }
.estnote svg { flex: none; margin-top: 2px; color: var(--t-est); }
.estnote span { flex: 1; min-width: 60%; }
.flash { animation: flash 1.6s ease-out 2; border-radius: var(--r-sm); }
@keyframes flash { 0% { box-shadow: 0 0 0 3px var(--t-est); } 100% { box-shadow: 0 0 0 3px transparent; } }
@media (prefers-reduced-motion: reduce) { .flash { animation: none; box-shadow: 0 0 0 2px var(--t-est); } }
.initbar { display: flex; gap: 8px; align-items: flex-start; background: var(--init-bg); color: var(--init); font-size: 14px; padding: 8px 12px; border-radius: var(--r-sm); }
.initbar svg { flex: none; margin-top: 2px; }
.center { text-align: center; }
/* תמונות בראש לשונית "נתונים" */
.photos { margin-bottom: 16px; }
.bigcam { min-height: 96px; flex-direction: column; gap: 8px; font-size: 18px; }
.gstrip { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; scroll-snap-type: x mandatory; }
.gstrip .gitem { flex: none; width: 104px; scroll-snap-align: start; }
.gstrip .gitem img { width: 104px; height: 104px; }
.gstrip .gdel { min-width: 40px; min-height: 40px; top: 0; left: 0; }
.gadd { flex: none; width: 104px; height: 104px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; border: 1.5px dashed var(--line); border-radius: var(--r-sm); background: var(--card); color: var(--t-user); font: inherit; font-size: 14px; cursor: pointer; }

/* ---------- לשונית "שאלות" ---------- */
.qtop { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; font-size: 15px; }
.qcard { background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); border: 1px solid var(--line); margin-bottom: 12px; overflow: hidden; }
.qcard.done { opacity: .78; }
.qopen { display: flex; gap: 12px; align-items: flex-start; width: 100%; border: 0; background: none; color: inherit; font: inherit; text-align: start; padding: 16px 16px 8px; cursor: pointer; }
.qnum { flex: none; width: 32px; height: 32px; border-radius: 999px; background: var(--neutral-bg); color: var(--neutral); display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: 15px; font-variant-numeric: tabular-nums; }
.qcard.done .qnum { background: var(--go-bg); color: var(--go); }
.qtexts { flex: 1; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.qzh { font-size: 24px; line-height: 1.4; font-weight: 700; direction: ltr; text-align: left; font-family: "PingFang SC", "Noto Sans SC", "Microsoft YaHei", "Heiti SC", sans-serif; }
.qen { font-size: 15px; direction: ltr; text-align: left; color: var(--text); }
.qhe { font-size: 13px; color: var(--muted); }
.qmax { flex: none; color: var(--muted); margin-top: 6px; }
.qans { display: flex; gap: 8px; align-items: center; padding: 0 16px 8px; }
.qans input { flex: 1; min-height: 48px; }
.qmic.rec { background: var(--pass-bg); color: var(--pass); }
.qfill { padding: 0 16px 12px; display: flex; gap: 4px; align-items: center; flex-wrap: wrap; }
.qfill:empty { display: none; }
.qfill svg { color: var(--go); }
.qlink { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 56px; border: 1px solid var(--line); font: inherit; color: inherit; cursor: pointer; text-align: start; }
.qlink .st { font-weight: 700; }
.qlink .ss { flex: 1; color: var(--muted); font-size: 14px; }
/* מסך מלא לשאלות */
.fullq.qfull { justify-content: space-between; padding: 16px 16px calc(16px + env(safe-area-inset-bottom, 0px)); }
.qfhead { display: flex; align-items: center; gap: 12px; justify-content: space-between; color: #555; font-size: 16px; }
.qfhead .iconbtn { color: #111; min-width: 48px; min-height: 48px; }
.qfdone { color: #15803d; display: inline-flex; gap: 4px; align-items: center; font-weight: 600; }
.qfbody { flex: 1; display: flex; flex-direction: column; justify-content: center; overflow-y: auto; }
.qfull .zh-big { font-size: clamp(30px, 9vw, 46px); line-height: 1.4; font-family: "PingFang SC", "Noto Sans SC", "Microsoft YaHei", "Heiti SC", sans-serif; }
.qfull .en-big { font-size: clamp(20px, 5.5vw, 26px); line-height: 1.4; }
.qfnav { display: grid; grid-template-columns: 1fr auto 1fr; gap: 8px; }
.qfnav .btn { min-height: 56px; }
.qfarrow { gap: 6px; }
.qfarrow:disabled { opacity: .35; }

/* ---------- צפייה בתמונה בגודל מלא ---------- */
body.noscroll { overflow: hidden; }
/* מעל הסרגל התחתון, מתחת לחלון האישור (50) ולהודעות (60) */
.viewer { position: fixed; inset: 0; z-index: 45; background: #000; color: #fff; display: flex; flex-direction: column; }
.vtop { display: flex; align-items: center; justify-content: space-between; padding: calc(8px + env(safe-area-inset-top, 0px)) 8px 8px; font-size: 15px; }
.vbtn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-width: 48px; min-height: 48px; border: 0; border-radius: 999px; background: rgba(255, 255, 255, .12); color: #fff; font: inherit; font-size: 16px; cursor: pointer; }
.vbtn.wide { padding: 0 20px; }
.vcount { color: #ddd; padding: 0 8px; }
.vstage { flex: 1; display: flex; align-items: center; justify-content: center; overflow: hidden; touch-action: none; user-select: none; -webkit-user-select: none; }
.vimg { max-width: 100%; max-height: 100%; object-fit: contain; transform-origin: center center; will-change: transform; -webkit-user-drag: none; }
.vbottom { padding: 8px 16px calc(12px + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 8px; }
.vmeta { font-size: 14px; color: #ddd; text-align: center; }
.vactions { display: flex; gap: 12px; justify-content: center; }
.phthumbbtn, .gview, .pview, .cardimg { border: 0; padding: 0; background: none; cursor: zoom-in; display: block; }
.gview img { width: 104px; height: 104px; object-fit: cover; border-radius: var(--r-sm); display: block; }
/* כרטיס ביקור ותיק תמונות ספק */
.cardimgs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 8px; }
.cardimg { position: relative; }
.cardimg img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border-radius: var(--r-sm); background: var(--neutral-bg); display: block; }
.cardimg span { position: absolute; bottom: 6px; inset-inline-start: 6px; background: rgba(0, 0, 0, .6); color: #fff; font-size: 12px; padding: 2px 8px; border-radius: 999px; }
.bigcam2 { min-height: 64px; font-size: 17px; }
.pgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 12px; }
.pitem { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.pview img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: var(--r-sm); background: var(--neutral-bg); display: block; }
.pitem input { min-height: 40px; font-size: 13px; padding: 6px 8px; }
.pdate { font-size: 11px; color: var(--muted); }

/* תשובה בכרטיס השאלה + אישור לפני הכנסה ל"נתונים" */
.qanstxt { display: flex; gap: 4px; align-items: flex-start; margin-top: 6px; padding: 6px 10px; border-radius: var(--r-sm); background: var(--go-bg); color: var(--text); font-size: 14px; }
.qanstxt svg { flex: none; margin-top: 3px; color: var(--go); }
.fillask { background: var(--t-user-bg); border-radius: var(--r-sm); padding: 8px 12px; display: flex; flex-direction: column; gap: 8px; }
.fillq { display: flex; gap: 6px; align-items: flex-start; font-size: 15px; color: var(--text); }
.fillq svg { flex: none; margin-top: 3px; color: var(--t-user); }
.fillbtns { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.fillbtns .btn { min-height: 44px; }

/* ---------- ראש לשונית "החלטה": תמונה, שם, ספק וביתן ---------- */
.phero { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.pheroimg { flex: none; width: 96px; height: 96px; border: 0; padding: 0; border-radius: var(--r); overflow: hidden; background: var(--neutral-bg); color: var(--muted); display: flex; align-items: center; justify-content: center; cursor: zoom-in; }
.pheroimg img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pheroimg.empty { cursor: default; }
.pherotext { min-width: 0; }
.pherotext h2 { margin: 0 0 4px; font-size: 20px; line-height: 1.3; }
/* מצב "אין עדיין החלטה" */
.target { font-size: 20px; font-weight: 800; line-height: 1.4; margin: 12px 0 4px; color: var(--text); }
.targetsub { font-size: 14px; color: var(--muted); margin: 0 0 12px; }
.known h3, .known h4 { display: flex; gap: 6px; align-items: center; margin: 0 0 8px; }
.known h4 { margin-top: 16px; font-size: 15px; }
.estsec { background: var(--neutral-bg); }
.estsec .dbody, .estsec summary { color: var(--muted); }
.ltarget { font-size: 14px; font-weight: 700; color: var(--init); white-space: nowrap; }
/* רשימת מוצרים: מצב בחירה (לחיצה ארוכה) */
.pcard { -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; }
.selbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding: 8px 12px; background: var(--t-user-bg); border-radius: var(--r-sm); }
.selbar span { flex: 1; }
/* חלונות: משימה, בחירת ספק, שיוך מוצרים */
.taskbox h3 { display: flex; gap: 6px; align-items: center; margin: 0 0 4px; }
.tmchips { margin: 8px 0 12px; }
.suppick { display: flex; flex-direction: column; gap: 8px; max-height: 50vh; overflow-y: auto; }
.suppick .btn { justify-content: flex-start; text-align: start; }
.linklist { max-height: 55vh; overflow-y: auto; }
/* כרטיס ספק: כרטיס ביקור ווויצ'אט */
.cardrow { display: flex; gap: 8px; align-items: center; margin-bottom: 8px; }
.cardrow > span { flex: 1; }
.wechat { display: flex; gap: 12px; align-items: flex-start; }
.wqr { flex: none; width: 104px; height: 104px; border: 0; padding: 0; border-radius: var(--r-sm); overflow: hidden; background: #fff; cursor: zoom-in; }
.wqr img { width: 100%; height: 100%; object-fit: contain; display: block; }
.wqr.empty { background: var(--neutral-bg); color: var(--muted); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; cursor: default; }
/* משימות */
.tgroup { margin-bottom: 16px; }
.tgroup h2 { display: flex; gap: 6px; align-items: center; font-size: 17px; }
.tgroup h2 a { color: inherit; }
.task.done { opacity: .6; }
.task.done b, .task.done .grow > span:first-child { text-decoration: line-through; }
.tlink { color: inherit; text-decoration: none; }
.qremind { margin: 0 16px 8px; font-size: 14px; min-height: 36px; }
