/* משימות שלנו · © אופיר ברנס (Ofir Baranes) 2026 - כל הזכויות שמורות */
@font-face { font-family: 'Heebo'; font-weight: 100 900; font-display: swap; src: url(fonts/heebo-hebrew.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-weight: 100 900; font-display: swap; src: url(fonts/heebo-latin.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: #F4F4F6;
  --card: #FFFFFF;
  --ink: #17171C;
  --ink-2: #4A4A55;
  --muted: #8C8C98;
  --line: #ECECF0;
  --orange: #FF8A00;
  --orange-soft: #FFF1E0;
  --green: #2EAD5B;
  --green-soft: #E3F6EA;
  --red: #EF4136;
  --red-soft: #FDE7E5;
  --blue: #2F7BEA;
  --blue-soft: #E4EFFE;
  --purple: #9B4FDB;
  --purple-soft: #F2E8FC;
  --efi: var(--orange);
  --daniel: var(--purple);
  --both: var(--blue);
  --radius: 26px;
  --shadow: 0 1px 2px rgba(20, 20, 40, .04), 0 8px 24px rgba(20, 20, 40, .06);
  --shadow-lg: 0 18px 50px rgba(20, 20, 40, .16);
  --spring: cubic-bezier(.34, 1.56, .64, 1);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; padding: 0; }
body {
  font-family: 'Heebo', -apple-system, 'SF Hebrew', 'Segoe UI', Arial, sans-serif;
  background: var(--bg); color: var(--ink);
  font-size: 16px; line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
  min-height: 100dvh;
}
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; }
:focus-visible { outline: 3px solid rgba(255, 138, 0, .55); outline-offset: 2px; border-radius: 12px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }
svg.i { width: 22px; height: 22px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* ---------- login ---------- */
.login {
  min-height: 100dvh; display: flex; flex-direction: column; justify-content: center;
  padding: calc(32px + var(--safe-t)) 24px calc(32px + var(--safe-b));
  background: radial-gradient(120% 60% at 100% 0%, #FFE7CC 0%, rgba(255,231,204,0) 60%), var(--bg);
}
.login-logo { width: 84px; height: 84px; border-radius: 26px; box-shadow: 0 12px 30px rgba(255, 138, 0, .35); margin-bottom: 22px; }
.login h1 { font-size: 34px; line-height: 1.15; font-weight: 800; margin: 0 0 8px; letter-spacing: -.5px; }
.login p.lead { color: var(--ink-2); margin: 0 0 28px; font-size: 17px; }
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); }
.login form { padding: 22px; display: grid; gap: 14px; }
.field { display: grid; gap: 6px; }
.field label { font-weight: 600; font-size: 14px; color: var(--ink-2); }
.input {
  width: 100%; border: 1.5px solid var(--line); background: #FAFAFB; border-radius: 16px;
  padding: 14px 16px; font-size: 17px; outline: none; transition: border-color .2s, background .2s;
  -webkit-appearance: none; appearance: none;
}
.input:focus { border-color: var(--orange); background: #fff; }
textarea.input { min-height: 84px; resize: vertical; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border-radius: 18px; padding: 15px 20px; font-weight: 700; font-size: 17px;
  transition: transform .15s, box-shadow .2s, background .2s; min-height: 52px;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--orange); color: #fff; box-shadow: 0 8px 20px rgba(255, 138, 0, .32); }
.btn-ghost { background: #F1F1F4; color: var(--ink); }
.btn-danger { background: var(--red-soft); color: var(--red); }
.btn-green { background: var(--green-soft); color: var(--green); }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .55; pointer-events: none; }
.form-error { color: var(--red); font-weight: 600; font-size: 14px; min-height: 20px; margin: 0; }
.copy { text-align: center; color: var(--muted); font-size: 12px; margin-top: 22px; }

/* ---------- app shell ---------- */
.app { min-height: 100dvh; padding-bottom: calc(96px + var(--safe-b)); }
.topbar {
  position: sticky; top: 0; z-index: 20; background: rgba(244, 244, 246, .88);
  backdrop-filter: saturate(1.6) blur(14px); -webkit-backdrop-filter: saturate(1.6) blur(14px);
  padding: calc(12px + var(--safe-t)) 20px 10px;
}
.topbar-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.hello { color: var(--muted); font-size: 14px; font-weight: 500; }
.page-title { font-size: 30px; font-weight: 800; letter-spacing: -.5px; margin: 0; line-height: 1.1; }
.icon-btn {
  width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center;
  background: var(--card); box-shadow: var(--shadow); color: var(--ink-2);
}
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: #C9C9D1; display: inline-block; margin-inline-start: 6px; vertical-align: middle; transition: background .3s; }
.live-dot.on { background: var(--green); box-shadow: 0 0 0 4px rgba(46, 173, 91, .15); }

main { padding: 6px 20px 20px; }

/* people row (like the reference avatars) */
.people { display: flex; gap: 14px; padding: 12px 0 4px; overflow-x: auto; scrollbar-width: none; }
.people::-webkit-scrollbar { display: none; }
.person { display: grid; justify-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--ink-2); min-width: 58px; }
.avatar {
  width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center;
  color: #fff; font-weight: 800; font-size: 22px; position: relative;
  border: 3px solid var(--bg); box-shadow: 0 0 0 2.5px transparent; transition: box-shadow .25s, transform .25s var(--spring);
}
.person[aria-pressed="true"] .avatar { box-shadow: 0 0 0 2.5px var(--ink); transform: scale(1.04); }
.person[aria-pressed="true"] { color: var(--ink); }
.av-all { background: #3A3A42; }
.av-efi { background: var(--efi); }
.av-daniel { background: var(--daniel); }
.av-both { background: var(--both); }
.avatar .count {
  position: absolute; top: -4px; inset-inline-start: -4px; background: var(--red); color: #fff;
  font-size: 11px; font-weight: 800; min-width: 20px; height: 20px; border-radius: 10px; display: grid; place-items: center;
  padding: 0 5px; border: 2px solid var(--bg);
}

/* tabs (underline like the reference) */
.tabs { display: flex; gap: 4px; border-bottom: 1.5px solid var(--line); margin: 10px 0 16px; }
.tab {
  flex: 1; padding: 12px 4px 11px; font-weight: 600; color: var(--muted); font-size: 15px;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; position: relative;
}
.tab .n { font-size: 12px; background: #E9E9EE; color: var(--ink-2); border-radius: 10px; padding: 1px 8px; font-weight: 700; }
.tab[aria-selected="true"] { color: var(--ink); }
.tab[aria-selected="true"]::after { content: ''; position: absolute; bottom: -1.5px; left: 10%; right: 10%; height: 3px; border-radius: 3px; background: var(--ink); }
.tab.t-overdue .n.has { background: var(--red); color: #fff; }

/* banners */
.banner { display: flex; gap: 12px; align-items: center; padding: 14px 16px; margin-bottom: 14px; border-radius: 20px; }
.banner .ic { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; flex: none; }
.banner b { display: block; font-size: 15px; }
.banner span { font-size: 13px; color: var(--ink-2); }
.banner .go { margin-inline-start: auto; color: var(--muted); }
.banner.orange { background: var(--orange-soft); } .banner.orange .ic { background: var(--orange); color: #fff; }
.banner.blue { background: var(--blue-soft); } .banner.blue .ic { background: var(--blue); color: #fff; }

/* groups + task cards */
.group-h { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 700; color: var(--muted); margin: 18px 4px 10px; }
.group-h.red { color: var(--red); }
.group-h:first-child { margin-top: 4px; }
.list { display: grid; gap: 12px; }
.task {
  display: flex; gap: 14px; align-items: flex-start; padding: 16px; background: var(--card);
  border-radius: 22px; box-shadow: var(--shadow); position: relative;
  transition: transform .35s var(--spring), opacity .3s;
  animation: pop .35s var(--spring) both;
}
@keyframes pop { from { opacity: 0; transform: translateY(8px) scale(.98); } to { opacity: 1; transform: none; } }
.task.overdue { box-shadow: inset 4px 0 0 var(--red), var(--shadow); }
.task.leaving { opacity: 0; transform: scale(.94); }
.check {
  width: 30px; height: 30px; border-radius: 50%; border: 2.2px solid #CFCFD8; display: grid; place-items: center;
  flex: none; margin-top: 1px; color: transparent; transition: background .2s, border-color .2s, transform .25s var(--spring);
}
.check svg.i { width: 18px; height: 18px; stroke-width: 3; }
.check:active { transform: scale(.85); }
.task.done .check, .check.on { background: var(--green); border-color: var(--green); color: #fff; }
.task-body { flex: 1; min-width: 0; text-align: start; }
.task-title { font-weight: 700; font-size: 17px; line-height: 1.3; word-break: break-word; }
.task.done .task-title { color: var(--muted); text-decoration: line-through; text-decoration-thickness: 1.5px; }
.task-note { color: var(--ink-2); font-size: 14px; margin-top: 3px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 9px; }
.tag { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; font-weight: 700; padding: 3px 10px; border-radius: 999px; }
.tag svg.i { width: 13px; height: 13px; stroke-width: 2.4; }
.tag-efi { background: var(--orange-soft); color: #C25E00; }
.tag-daniel { background: var(--purple-soft); color: #7A32B8; }
.tag-both { background: var(--blue-soft); color: #1D5FC2; }
.tag-due { background: #F1F1F4; color: var(--ink-2); }
.tag-due.today { background: var(--orange-soft); color: #C25E00; }
.tag-due.late { background: var(--red); color: #fff; }
.tag-done { background: var(--green-soft); color: #1E8445; }
.task-meta { font-size: 12.5px; color: var(--muted); margin-top: 8px; }

.empty { text-align: center; padding: 50px 20px 30px; color: var(--muted); }
.empty .ic { width: 84px; height: 84px; margin: 0 auto 14px; border-radius: 50%; display: grid; place-items: center; background: var(--green-soft); color: var(--green); }
.empty .ic svg.i { width: 40px; height: 40px; }
.empty b { display: block; color: var(--ink); font-size: 19px; margin-bottom: 4px; }

/* FAB */
.fab {
  position: fixed; z-index: 30; inset-inline-start: 20px; bottom: calc(98px + var(--safe-b));
  width: 62px; height: 62px; border-radius: 50%; background: var(--orange); color: #fff;
  display: grid; place-items: center; box-shadow: 0 12px 28px rgba(255, 138, 0, .45);
  transition: transform .25s var(--spring);
}
.fab svg.i { width: 30px; height: 30px; stroke-width: 2.6; }
.fab:active { transform: scale(.9); }

/* bottom nav (colored circles like the reference) */
.bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 25;
  background: rgba(255, 255, 255, .94); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-top-left-radius: 28px; border-top-right-radius: 28px; box-shadow: 0 -6px 30px rgba(20, 20, 40, .07);
  display: grid; grid-template-columns: repeat(4, 1fr); padding: 10px 8px calc(10px + var(--safe-b));
}
.nav-item { display: grid; justify-items: center; gap: 4px; font-size: 12.5px; font-weight: 700; color: var(--muted); padding: 2px 0; }
.nav-item .bub { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; transition: transform .25s var(--spring), background .2s; background: transparent; }
.nav-item .bub svg.i { width: 24px; height: 24px; }
.nav-item[aria-current="page"] { color: var(--ink); }
.nav-item[aria-current="page"] .bub { transform: translateY(-2px); }
.nav-item.n-tasks[aria-current="page"] .bub { background: var(--green-soft); color: var(--green); }
.nav-item.n-cal[aria-current="page"] .bub { background: var(--orange-soft); color: var(--orange); }
.nav-item.n-guide[aria-current="page"] .bub { background: var(--blue-soft); color: var(--blue); }
.nav-item.n-set[aria-current="page"] .bub { background: var(--purple-soft); color: var(--purple); }

/* ---------- calendar ---------- */
.cal { padding: 16px 10px 10px; overflow: hidden; }
.cal-head { display: flex; align-items: center; justify-content: space-between; padding: 0 6px 12px; }
.cal-title { font-size: 20px; font-weight: 800; }
.cal-nav { display: flex; gap: 6px; align-items: center; }
.cal-nav button { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; color: var(--ink-2); }
.cal-nav button:active { background: #F1F1F4; }
.today-box { width: 34px !important; height: 34px !important; border: 2.2px solid var(--ink) !important; border-radius: 9px !important; font-weight: 800; font-size: 15px; color: var(--ink) !important; }
.cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.cal-dow { text-align: center; font-size: 11.5px; color: var(--muted); padding: 6px 0 8px; font-weight: 500; border-bottom: 1px solid var(--line); }
.cal-day {
  min-width: 0; overflow: hidden; min-height: 68px; border-bottom: 1px solid var(--line); padding: 5px 2px 4px; display: flex; flex-direction: column; align-items: center; gap: 3px;
  border-radius: 0; position: relative; text-align: center;
}
.cal-day .d { font-size: 14px; font-weight: 600; width: 28px; height: 28px; line-height: 28px; border-radius: 50%; }
.cal-day.other .d { color: #C4C4CC; }
.cal-day.is-today .d { background: var(--orange); color: #fff; }
.cal-day.sel { outline: 1.5px solid var(--ink); outline-offset: -2px; border-radius: 10px; }
.chip-mini {
  display: block; width: 94%; max-width: 94%; font-size: 9.5px; line-height: 1.25; font-weight: 600; background: #fff; border: 1px solid #DCDCE2; border-radius: 4px;
  padding: 1px 2px 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--ink-2);
  border-bottom-width: 2.5px;
}
.chip-mini.efi { border-bottom-color: var(--efi); }
.chip-mini.daniel { border-bottom-color: var(--daniel); }
.chip-mini.both { border-bottom-color: var(--both); }
.chip-mini.done { opacity: .45; text-decoration: line-through; }
.chip-mini.late { border-color: var(--red); color: var(--red); }
.more-mini { font-size: 10px; color: var(--muted); font-weight: 700; }
.day-panel h3 { font-size: 19px; font-weight: 800; margin: 22px 4px 12px; display: flex; align-items: center; justify-content: space-between; }
.day-panel h3 button { font-size: 14px; color: var(--orange); font-weight: 700; display: inline-flex; align-items: center; gap: 4px; }

/* ---------- guide + settings ---------- */
.section-title { font-size: 22px; font-weight: 800; margin: 8px 4px 12px; }
.g-card { padding: 18px; margin-bottom: 14px; }
.g-card h3 { display: flex; align-items: center; gap: 12px; margin: 0 0 10px; font-size: 18px; font-weight: 800; }
.circ { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; flex: none; }
.circ.orange { background: var(--orange-soft); color: var(--orange); }
.circ.green { background: var(--green-soft); color: var(--green); }
.circ.blue { background: var(--blue-soft); color: var(--blue); }
.circ.purple { background: var(--purple-soft); color: var(--purple); }
.circ.red { background: var(--red-soft); color: var(--red); }
.steps { margin: 0; padding: 0; list-style: none; counter-reset: s; display: grid; gap: 10px; }
.steps li { counter-increment: s; display: flex; gap: 12px; align-items: flex-start; font-size: 15.5px; color: var(--ink-2); }
.steps li::before { content: counter(s); flex: none; width: 26px; height: 26px; border-radius: 50%; background: var(--ink); color: #fff; font-size: 13px; font-weight: 800; display: grid; place-items: center; margin-top: 1px; }
.steps b { color: var(--ink); }
.g-note { font-size: 13.5px; background: #F6F6F8; border-radius: 14px; padding: 10px 12px; margin-top: 12px; color: var(--ink-2); }
.set-row { display: flex; align-items: center; gap: 14px; padding: 16px 18px; }
.set-row + .set-row { border-top: 1px solid var(--line); }
.set-row .txt { flex: 1; min-width: 0; }
.set-row .txt b { display: block; font-size: 16px; }
.set-row .txt span { font-size: 13px; color: var(--muted); }
.status-pill { font-size: 12px; font-weight: 800; padding: 4px 10px; border-radius: 999px; }
.status-pill.ok { background: var(--green-soft); color: var(--green); }
.status-pill.no { background: #F1F1F4; color: var(--muted); }
.set-form { padding: 18px; display: grid; gap: 12px; }

/* ---------- sheet ---------- */
.scrim { position: fixed; inset: 0; background: rgba(15, 15, 25, .38); z-index: 50; opacity: 0; transition: opacity .25s; }
.scrim.show { opacity: 1; }
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; background: var(--card);
  border-top-left-radius: 30px; border-top-right-radius: 30px; box-shadow: var(--shadow-lg);
  padding: 10px 20px calc(20px + var(--safe-b)); max-height: 92dvh; overflow-y: auto;
  transform: translateY(105%); transition: transform .38s var(--spring);
}
.sheet.show { transform: none; }
.grabber { width: 42px; height: 5px; border-radius: 3px; background: #DCDCE2; margin: 0 auto 12px; }
.sheet h2 { font-size: 24px; font-weight: 800; margin: 0 0 14px; display: flex; justify-content: space-between; align-items: center; }
.sheet form { display: grid; gap: 16px; }
.title-input { font-size: 20px; font-weight: 700; border: 0; border-bottom: 2px solid var(--line); border-radius: 0; background: transparent; padding: 8px 2px; outline: none; width: 100%; }
.title-input:focus { border-bottom-color: var(--orange); }
.lbl { font-size: 13.5px; font-weight: 700; color: var(--muted); margin-bottom: 8px; display: block; }
.seg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.seg button {
  border-radius: 16px; padding: 10px 6px; font-weight: 700; font-size: 15px; background: #F4F4F7; color: var(--ink-2);
  display: inline-flex; align-items: center; justify-content: center; gap: 7px; border: 2px solid transparent; transition: all .2s;
}
.seg button .dot { width: 10px; height: 10px; border-radius: 50%; }
.seg button[aria-pressed="true"].a-efi { background: var(--orange-soft); border-color: var(--efi); color: #B05500; }
.seg button[aria-pressed="true"].a-daniel { background: var(--purple-soft); border-color: var(--daniel); color: #6F2DA8; }
.seg button[aria-pressed="true"].a-both { background: var(--blue-soft); border-color: var(--both); color: #1D5FC2; }
.quick-dates { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.qd { padding: 8px 14px; border-radius: 999px; background: #F4F4F7; font-weight: 700; font-size: 14px; color: var(--ink-2); border: 2px solid transparent; }
.qd[aria-pressed="true"] { background: var(--orange-soft); color: #B05500; border-color: var(--orange); }
.dt-row { display: grid; grid-template-columns: 1.4fr 1fr; gap: 10px; }
.dt-row .input { padding: 12px 12px; font-size: 16px; min-height: 50px; text-align: start; }
.info-box { background: #F7F7F9; border-radius: 18px; padding: 12px 14px; font-size: 13.5px; color: var(--ink-2); display: grid; gap: 4px; }
.info-box b { color: var(--ink); }
.sheet-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

/* toast */
.toast {
  position: fixed; left: 50%; top: calc(14px + var(--safe-t)); z-index: 80; transform: translate(-50%, -150%);
  background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 16px; font-weight: 600; font-size: 15px;
  box-shadow: var(--shadow-lg); transition: transform .35s var(--spring), visibility 0s .35s; max-width: 90vw; text-align: center; visibility: hidden;
}
.toast.show { transform: translate(-50%, 0); visibility: visible; transition: transform .35s var(--spring); }

@media (min-width: 640px) {
  .app, .login-inner { max-width: 560px; margin: 0 auto; }
  .bottom-nav { max-width: 560px; margin: 0 auto; }
  .sheet { max-width: 560px; margin: 0 auto; }
  .fab { inset-inline-start: calc(50% - 260px); }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
