/* קומפוננטות משותפות. סדר: מעטפת, כרטיס, תגיות, נקודות, לוח חודשי, לוח סידור, חלוניות, הודעות. */

/* ---------- מעטפת: סרגל צד מימין + אזור תוכן ---------- */
.app { display: grid; grid-template-columns: var(--sidebar-w) 1fr; min-height: 100vh; }
.sidebar {
  position: sticky; top: 0; height: 100vh; overflow-y: auto;
  background: var(--surface); border-inline-end: 1px solid var(--line);
  display: flex; flex-direction: column; gap: var(--s4); padding: var(--s5) var(--s4);
}
.brand { display: flex; align-items: center; gap: var(--s2); padding: 0 var(--s2) var(--s2); }
.brand-mark { width: 36px; height: 36px; border-radius: 10px; background: var(--primary); display: grid; place-items: center; color: #fff; font-weight: 700; }
.brand-name { font-weight: 700; font-size: var(--fs-lg); letter-spacing: .01em; }
.brand-sub { font-size: var(--fs-xs); color: var(--muted); }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav a {
  display: flex; align-items: center; gap: var(--s3); padding: 10px var(--s3);
  border-radius: var(--r-md); color: var(--ink); font-weight: 500; font-size: var(--fs-sm);
}
.nav a svg { width: 20px; height: 20px; color: var(--muted); flex: none; }
.nav a:hover { background: var(--surface-2); text-decoration: none; }
.nav a[aria-current="page"] { background: var(--primary-soft); color: var(--primary-ink); }
.nav a[aria-current="page"] svg { color: var(--primary); }
.nav a .soon { margin-inline-start: auto; font-size: 11px; color: var(--muted); }
.sidebar-foot { margin-top: auto; display: flex; flex-direction: column; gap: var(--s3); }
.user-chip { display: flex; align-items: center; gap: var(--s3); padding: var(--s3); border: 1px solid var(--line); border-radius: var(--r-lg); }
.avatar { width: 38px; height: 38px; border-radius: 50%; background: var(--primary-soft); color: var(--primary-ink); display: grid; place-items: center; font-weight: 600; flex: none; }
.user-chip .who { min-width: 0; }
.user-chip .who b { display: block; font-size: var(--fs-sm); }
.user-chip .who span { display: block; font-size: var(--fs-xs); color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 20; background: rgba(245, 248, 251, .92); backdrop-filter: blur(6px);
  display: flex; align-items: center; gap: var(--s3); flex-wrap: wrap;
  padding: var(--s4) var(--s6); border-bottom: 1px solid var(--line);
}
.topbar h1 { font-size: var(--fs-xl); }
.topbar .sub { color: var(--muted); font-size: var(--fs-sm); }
.topbar .spacer { flex: 1; }
.menu-btn { display: none; }
.content { padding: var(--s6); display: flex; flex-direction: column; gap: var(--s5); }

@media (max-width: 900px) {
  .app { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed; inset: 0 0 0 auto; width: min(84vw, 300px); z-index: 60;
    transform: translateX(100%); transition: transform .2s; box-shadow: var(--shadow-md);
  }
  .sidebar.open { transform: none; }
  .scrim { position: fixed; inset: 0; background: rgba(15, 23, 42, .35); z-index: 55; }
  .menu-btn { display: inline-grid; }
  .topbar { padding: var(--s3) var(--s4); }
  .topbar h1 { font-size: var(--fs-lg); }
  .content { padding: var(--s4); }
}

/* ---------- כרטיס ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-sm); }
.card-pad { padding: var(--s5); }
.card-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s3); padding: var(--s4) var(--s5); border-bottom: 1px solid var(--line); }

/* ---------- תגיות ---------- */
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px; border-radius: var(--r-pill); font-size: var(--fs-xs); font-weight: 600; white-space: nowrap; }
.badge-primary { background: var(--primary-soft); color: var(--primary-ink); }
.badge-want { background: var(--want-soft); color: #166534; }
.badge-can { background: var(--can-soft); color: var(--can-ink); }
.badge-cannot { background: var(--cannot-soft); color: #991B1B; }
.badge-draft { background: var(--surface-2); color: var(--muted); }
.count { min-width: 26px; height: 26px; padding: 0 8px; border-radius: var(--r-pill); border: 1px solid var(--line-strong); display: inline-grid; place-items: center; font-size: var(--fs-sm); font-weight: 600; }

/* ---------- נקודות בקשה ---------- */
.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }
.dot-want { background: var(--want); }
.dot-can { background: var(--can); }
.dot-cannot { background: var(--cannot); }
.legend { display: flex; flex-wrap: wrap; gap: var(--s4); align-items: center; font-size: var(--fs-sm); color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }

/* ---------- לשוניות וכפתורי בחירה ---------- */
.tabs { display: flex; gap: var(--s4); border-bottom: 1px solid var(--line); }
.tabs button {
  font: inherit; font-size: var(--fs-sm); background: none; border: 0; cursor: pointer; color: var(--muted);
  padding: var(--s2) 2px; border-bottom: 2px solid transparent; display: inline-flex; align-items: center; gap: 6px;
}
.tabs button[aria-selected="true"] { color: var(--primary-ink); border-bottom-color: var(--primary); font-weight: 600; }
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: var(--s2); }
.seg label { position: relative; }
.seg input { position: absolute; opacity: 0; inset: 0; pointer-events: none; }
.seg > label > span {
  display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 var(--s3);
  border: 1px solid var(--line-strong); border-radius: var(--r-md); cursor: pointer; font-size: var(--fs-sm); font-weight: 500; background: var(--surface);
}
.seg input:checked + span { border-color: var(--primary); background: var(--primary-soft); color: var(--primary-ink); }
.seg input:focus-visible + span { box-shadow: var(--focus); }

/* ---------- לוח חודשי (בקשות עובד) ---------- */
.cal { padding: var(--s3); }
.cal-head, .cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); }
.cal-head div { text-align: center; padding: var(--s2) 0; font-size: var(--fs-sm); font-weight: 600; color: var(--muted); }
.cal-grid { border-top: 1px solid var(--line); border-inline-start: 1px solid var(--line); }
.cal-day {
  position: relative; min-height: 78px; padding: 8px; text-align: start;
  border: 0; border-bottom: 1px solid var(--line); border-inline-end: 1px solid var(--line);
  background: var(--surface); font: inherit; color: var(--ink); cursor: pointer;
  display: flex; flex-direction: column; justify-content: space-between; align-items: stretch; gap: 4px;
}
.cal-day:hover { background: #F8FBFE; }
.cal-day .n { font-weight: 600; font-size: var(--fs-sm); }
.cal-day .meta { display: flex; align-items: center; gap: 6px; justify-content: center; min-height: 14px; }
.cal-day .t { font-size: 11px; color: var(--muted); direction: ltr; unicode-bidi: isolate; }
.cal-day.out { background: var(--surface-2); color: var(--line-strong); cursor: default; }
.cal-day.past { color: var(--muted); cursor: default; }
.cal-day.past .n { color: var(--line-strong); }
.cal-day.today .n { color: var(--primary); }
.cal-day.sel { box-shadow: inset 0 0 0 2px var(--primary); background: var(--primary-soft); z-index: 1; }
.cal-day.shab .n { color: var(--muted); }
.cal-day .note-mark { position: absolute; top: 8px; inset-inline-end: 8px; width: 6px; height: 6px; border-radius: 50%; background: var(--primary); }
@media (max-width: 600px) {
  .cal { padding: var(--s1); }
  .cal-day { min-height: 56px; padding: 6px 4px; }
  .cal-day .t { display: none; }
}

/* ---------- לוח הסידור (מנהל) ---------- */
.board-wrap { overflow-x: auto; }
.board { width: 100%; min-width: 800px; border-collapse: separate; border-spacing: 0; table-layout: fixed; }
.board th, .board td { border-bottom: 1px solid var(--line); border-inline-start: 1px solid var(--line); vertical-align: top; }
.board thead th { position: sticky; top: 0; background: var(--surface); z-index: 2; padding: var(--s3) var(--s2); font-weight: 600; font-size: var(--fs-sm); text-align: center; }
.board thead th small { display: block; color: var(--muted); font-weight: 400; }
.board thead th.today { color: var(--primary-ink); background: var(--primary-soft); }
.board th.emp-col, .board td.emp { width: 156px; }
.board td.emp { padding: var(--s3); position: sticky; inset-inline-start: 0; background: var(--surface); z-index: 1; }
.emp-name { display: flex; align-items: center; gap: 8px; font-weight: 600; font-size: var(--fs-sm); }
.emp-role { font-size: var(--fs-xs); color: var(--muted); margin-inline-start: 18px; }
.emp-hours { font-size: var(--fs-xs); color: var(--muted); margin-inline-start: 18px; }
.role-dot { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.cell { position: relative; min-height: 76px; padding: 22px 6px 6px; display: flex; flex-direction: column; gap: 4px; }
.cell.drop-target { background: var(--primary-soft); }
.cell .add {
  min-height: 34px; border: 1px dashed transparent; background: none; border-radius: var(--r-sm); color: var(--muted);
  font: inherit; font-size: var(--fs-xs); cursor: pointer; opacity: 0; transition: opacity .1s;
}
.cell:hover .add, .cell .add:focus-visible { opacity: 1; border-color: var(--line-strong); }
.req-btn {
  position: absolute; top: 6px; inset-inline-start: 6px; display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 6px 2px 4px; border-radius: var(--r-pill); border: 0; background: transparent; cursor: pointer; font: inherit; font-size: 11px; color: var(--muted);
}
.req-btn:hover { background: var(--surface-2); }
.req-btn .t { direction: ltr; unicode-bidi: isolate; white-space: nowrap; }
.chip {
  display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 6px 4px; border-radius: var(--r-sm);
  border: 1px solid var(--role-slate-line); background: var(--role-slate); cursor: grab; font-size: var(--fs-sm); text-align: center; user-select: none; touch-action: none; font: inherit; font-size: var(--fs-sm); width: 100%;
}
.chip .tm { font-weight: 600; direction: ltr; unicode-bidi: isolate; font-variant-numeric: tabular-nums; white-space: nowrap; font-size: 13px; }
@media (max-width: 600px) { .board th.emp-col, .board td.emp { width: 118px; } .board td.emp { padding: var(--s2); } }
.chip .rl { font-size: 11px; color: #334155; }
.chip.draft { border-style: dashed; }
.chip.conflict { box-shadow: 0 0 0 2px var(--cannot); }
.chip.sortable-ghost { opacity: .35; }
.chip.sortable-drag { cursor: grabbing; box-shadow: var(--shadow-md); }
.board-foot { display: flex; flex-wrap: wrap; gap: var(--s5); align-items: center; padding: var(--s3) var(--s5); border-top: 1px solid var(--line); font-size: var(--fs-sm); color: var(--muted); }
.board-foot b { color: var(--ink); }

/* צבעי תפקידים */
.r-sky    { background: var(--role-sky);    border-color: var(--role-sky-line); }
.r-green  { background: var(--role-green);  border-color: var(--role-green-line); }
.r-amber  { background: var(--role-amber);  border-color: var(--role-amber-line); }
.r-violet { background: var(--role-violet); border-color: var(--role-violet-line); }
.r-pink   { background: var(--role-pink);   border-color: var(--role-pink-line); }
.r-teal   { background: var(--role-teal);   border-color: var(--role-teal-line); }
.r-orange { background: var(--role-orange); border-color: var(--role-orange-line); }
.r-slate  { background: var(--role-slate);  border-color: var(--role-slate-line); }
.rd-sky { background: var(--role-sky-line); } .rd-green { background: var(--role-green-line); } .rd-amber { background: var(--role-amber-line); }
.rd-violet { background: var(--role-violet-line); } .rd-pink { background: var(--role-pink-line); } .rd-teal { background: var(--role-teal-line); }
.rd-orange { background: var(--role-orange-line); } .rd-slate { background: var(--role-slate-line); }

/* ---------- סרגל צד של בקשות ---------- */
.board-layout { display: grid; grid-template-columns: minmax(0, 1fr) 296px; gap: var(--s5); align-items: start; }
.req-panel { position: sticky; top: 88px; max-height: calc(100vh - 112px); display: flex; flex-direction: column; }
.req-panel .tabs { padding: 0 var(--s5); }
.req-list { overflow-y: auto; padding: var(--s3); display: flex; flex-direction: column; gap: var(--s2); }
.req-item { border: 1px solid var(--line); border-radius: var(--r-md); padding: var(--s3); display: flex; flex-direction: column; gap: 4px; background: var(--surface); text-align: start; font: inherit; cursor: pointer; }
.req-item:hover { border-color: var(--line-strong); }
.req-item .row1 { display: flex; align-items: center; gap: 8px; }
.req-item .row1 b { font-size: var(--fs-sm); }
.req-item .row1 time { margin-inline-start: auto; font-size: var(--fs-xs); color: var(--muted); }
.req-item p { font-size: var(--fs-sm); color: var(--muted); }
@media (max-width: 1200px) { .board-layout { grid-template-columns: minmax(0, 1fr); } .req-panel { position: static; max-height: none; } }

/* ---------- חלוניות ---------- */
.popover {
  position: fixed; z-index: 80; width: 260px; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-md); box-shadow: var(--shadow-md); padding: var(--s4); display: flex; flex-direction: column; gap: var(--s2);
}
.modal-scrim { position: fixed; inset: 0; z-index: 90; background: rgba(15, 23, 42, .4); display: grid; place-items: center; padding: var(--s4); }
.modal { width: min(100%, 440px); max-height: calc(100vh - 32px); overflow-y: auto; background: var(--surface); border-radius: var(--r-lg); box-shadow: var(--shadow-md); }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: var(--s4) var(--s5); border-bottom: 1px solid var(--line); }
.modal-body { padding: var(--s5); display: flex; flex-direction: column; gap: var(--s4); }
.modal-foot { display: flex; gap: var(--s2); justify-content: flex-start; padding: var(--s4) var(--s5); border-top: 1px solid var(--line); flex-wrap: wrap; }
.modal-foot .end { margin-inline-start: auto; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s3); }
@media (max-width: 600px) {
  .modal-scrim { align-items: end; padding: 0; }
  .modal { width: 100%; border-radius: var(--r-lg) var(--r-lg) 0 0; }
}

/* ---------- הודעות קופצות ---------- */
.toasts { position: fixed; bottom: calc(var(--s5) + env(safe-area-inset-bottom, 0px)); inset-inline-start: 50%; transform: translateX(50%); z-index: 100; display: flex; flex-direction: column; gap: var(--s2); align-items: center; }
.toast { background: var(--ink); color: #fff; padding: 10px 16px; border-radius: var(--r-md); font-size: var(--fs-sm); box-shadow: var(--shadow-md); }
.toast.err { background: var(--cannot); }

/* ---------- מסכי כניסה ---------- */
.auth-page { min-height: 100vh; display: grid; place-items: center; padding: var(--s6) var(--s4); background: linear-gradient(180deg, var(--primary-soft) 0, var(--bg) 320px); }
.auth-card { width: min(100%, 420px); padding: var(--s8) var(--s6); display: flex; flex-direction: column; gap: var(--s4); }
.auth-card .brand { justify-content: center; padding: 0; }
.auth-card h1 { font-size: var(--fs-xl); text-align: center; }
.auth-card .lead { text-align: center; color: var(--muted); }
.auth-card form { display: flex; flex-direction: column; gap: var(--s4); }
.auth-card .switch { text-align: center; font-size: var(--fs-sm); }
.link-btn { background: none; border: 0; padding: 0; font: inherit; color: var(--primary); cursor: pointer; }
.link-btn:hover { text-decoration: underline; }
.notice { padding: var(--s3) var(--s4); border-radius: var(--r-md); font-size: var(--fs-sm); background: var(--primary-soft); color: var(--primary-ink); }
.notice.warn { background: var(--can-soft); color: var(--can-ink); }
.notice.err { background: var(--cannot-soft); color: #991B1B; }
.demo-bar { background: var(--can-soft); color: var(--can-ink); text-align: center; font-size: var(--fs-xs); padding: 6px; }
.empty { padding: var(--s8) var(--s4); text-align: center; color: var(--muted); }

/* ---------- לוח בקרה לעובד (שלב 2) ---------- */
.dash { display: grid; grid-template-columns: minmax(0, 1fr) 340px; grid-template-areas: "hero alerts" "stats alerts" "cards alerts"; gap: var(--s5); align-items: start; }
.dash-hero { grid-area: hero; } .dash-stats { grid-area: stats; } .dash-cards { grid-area: cards; } .dash-side { grid-area: alerts; position: sticky; top: 88px; display: flex; flex-direction: column; gap: var(--s4); }
.greet h2 { font-size: var(--fs-xl); }
.greet p { color: var(--muted); margin-top: 2px; }
.hero { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s4); padding: var(--s5); background: linear-gradient(135deg, var(--primary) 0%, #0369A1 100%); color: #fff; border: 0; }
.hero .grow { flex: 1 1 220px; min-width: 0; }
.hero .k { font-size: var(--fs-xs); opacity: .8; }
.hero .v { font-size: var(--fs-lg); font-weight: 600; margin-top: 2px; }
.hero .s { font-size: var(--fs-sm); opacity: .9; margin-top: 4px; }
.hero .btn { background: #fff; color: var(--primary-ink); border-color: #fff; }
.hero .btn:hover { background: var(--primary-soft); }
.state-pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: var(--r-pill); background: rgba(255,255,255,.18); font-size: var(--fs-xs); font-weight: 600; }
.state-pill::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #CBD5E1; }
.state-pill.in::before { background: #4ADE80; box-shadow: 0 0 0 3px rgba(74,222,128,.3); }
.state-pill.stale::before { background: #FACC15; }
.dash-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s3); }
.stat { padding: var(--s4); }
.stat .k { font-size: var(--fs-xs); color: var(--muted); }
.stat .v { font-size: var(--fs-2xl); font-weight: 700; line-height: 1.15; margin-top: 4px; font-variant-numeric: tabular-nums; }
.stat .s { font-size: var(--fs-xs); color: var(--muted); margin-top: 2px; }
.dash-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s4); }
.action-card { display: flex; flex-direction: column; gap: var(--s3); padding: var(--s5); color: inherit; min-height: 168px; transition: border-color .15s, box-shadow .15s, transform .15s; }
a.action-card:hover { text-decoration: none; border-color: var(--primary); box-shadow: var(--shadow-md); transform: translateY(-1px); }
.action-card .ic { width: 48px; height: 48px; border-radius: var(--r-md); display: grid; place-items: center; background: var(--primary-soft); color: var(--primary); }
.action-card .ic svg { width: 26px; height: 26px; }
.action-card h3 { font-size: var(--fs-lg); display: flex; align-items: center; gap: var(--s2); }
.action-card p { color: var(--muted); font-size: var(--fs-sm); }
.action-card .foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: var(--s2); font-size: var(--fs-sm); color: var(--primary-ink); font-weight: 500; }
.action-card .foot svg { width: 18px; height: 18px; }
.action-card.soon { background: var(--surface-2); box-shadow: none; cursor: default; }
.action-card.soon .ic { background: var(--surface); color: var(--muted); }
.action-card.soon .foot { color: var(--muted); }
.alert-list { list-style: none; margin: 0; padding: 0; }
.alert-item { display: flex; gap: var(--s3); padding: var(--s3) var(--s4); border-top: 1px solid var(--line); font-size: var(--fs-sm); }
.alert-item:first-child { border-top: 0; }
.alert-item .mark { flex: none; width: 8px; height: 8px; border-radius: 50%; margin-top: 7px; background: var(--primary); }
.alert-item.warn .mark { background: var(--can); }
.alert-item.err .mark { background: var(--cannot); }
.alert-item a { font-weight: 500; }
.bell { position: relative; }
.bell .count-dot { position: absolute; top: 4px; inset-inline-end: 4px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--cannot); color: #fff; font-size: 11px; font-weight: 700; display: grid; place-items: center; border: 2px solid var(--surface); }
.bell-panel { position: absolute; top: calc(100% + 6px); inset-inline-end: 0; width: min(340px, calc(100vw - 32px)); z-index: 60; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-md); }
.bell-panel h3 { font-size: var(--fs-md); padding: var(--s3) var(--s4); border-bottom: 1px solid var(--line); }
@media (max-width: 1100px) {
  .dash { grid-template-columns: minmax(0, 1fr); grid-template-areas: "hero" "alerts" "stats" "cards"; }
  .dash-side { position: static; }
}
@media (max-width: 600px) {
  .dash-stats { gap: var(--s2); }
  .stat { padding: var(--s3); }
  .stat .v { font-size: var(--fs-xl); }
  .dash-cards { grid-template-columns: minmax(0, 1fr); gap: var(--s3); }
  .action-card { min-height: 0; flex-direction: row; flex-wrap: wrap; align-items: center; padding: var(--s4); }
  .action-card .ic { width: 42px; height: 42px; }
  .action-card .body { flex: 1 1 0; min-width: 0; }
  .action-card .foot { flex-basis: 100%; }
}

/* ---------- מסך החתמה ---------- */
.tap-page { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; background: linear-gradient(180deg, var(--primary-soft) 0, var(--bg) 360px); }
.tap-top { display: flex; align-items: center; gap: var(--s3); padding: var(--s4); max-width: 520px; width: 100%; margin: 0 auto; }
.tap-top .spacer { flex: 1; }
.tap-main { flex: 1; display: flex; flex-direction: column; align-items: center; gap: var(--s5); padding: var(--s4) var(--s4) var(--s8); max-width: 520px; width: 100%; margin: 0 auto; text-align: center; }
.tap-who { font-size: var(--fs-lg); font-weight: 600; }
.tap-now { font-size: 56px; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; letter-spacing: -1px; }
.tap-date { color: var(--muted); margin-top: 6px; }
.tap-btn { width: 220px; height: 220px; border-radius: 50%; border: 0; cursor: pointer; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--s2); font: inherit; font-size: var(--fs-xl); font-weight: 700; color: #fff; background: var(--want); box-shadow: 0 12px 32px rgba(22,163,74,.35), inset 0 -6px 0 rgba(0,0,0,.08); transition: transform .12s; -webkit-tap-highlight-color: transparent; }
.tap-btn.out { background: var(--primary); box-shadow: 0 12px 32px rgba(2,132,199,.35), inset 0 -6px 0 rgba(0,0,0,.08); }
.tap-btn svg { width: 44px; height: 44px; }
.tap-btn:active { transform: scale(.96); }
.tap-btn:disabled { opacity: .7; cursor: wait; }
.tap-result { width: 100%; padding: var(--s6) var(--s5); display: flex; flex-direction: column; align-items: center; gap: var(--s2); }
.tap-result .big-ic { width: 88px; height: 88px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: var(--want); animation: pop .35s ease-out; }
.tap-result.out .big-ic { background: var(--primary); }
.tap-result.repeat .big-ic { background: var(--muted); }
.tap-result.err .big-ic { background: var(--cannot); }
.tap-result .big-ic svg { width: 48px; height: 48px; stroke-width: 2.4; }
.tap-result h2 { font-size: var(--fs-xl); margin-top: var(--s2); }
.tap-result .when { font-size: 44px; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.1; }
.tap-result p { color: var(--muted); }
@keyframes pop { from { transform: scale(.6); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .tap-result .big-ic { animation: none; } .tap-btn, .action-card { transition: none; } }
.tap-log { width: 100%; text-align: start; }
.tap-log ul { list-style: none; margin: 0; padding: 0; }
.tap-log li { display: flex; justify-content: space-between; padding: var(--s2) var(--s4); border-top: 1px solid var(--line); font-size: var(--fs-sm); }
.tap-log li:first-child { border-top: 0; }

/* ---------- המשמרות שלי ---------- */
.week-list { list-style: none; margin: 0; padding: 0; }
.week-list > li { display: grid; grid-template-columns: 92px minmax(0, 1fr) auto; gap: var(--s3); align-items: start; padding: var(--s3) var(--s5); border-top: 1px solid var(--line); }
.week-list > li:first-child { border-top: 0; }
.week-list > li.today { background: var(--primary-soft); }
.week-list .d b { display: block; }
.week-list .d span { font-size: var(--fs-xs); color: var(--muted); }
.week-list .sh { display: flex; flex-direction: column; gap: 4px; }
.week-list .sh .line { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2); }
.week-list .sh .tm { font-weight: 600; white-space: nowrap; }
.week-list .att { font-size: var(--fs-xs); color: var(--muted); }
.week-list .hrs { font-size: var(--fs-sm); color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
@media (max-width: 600px) { .week-list > li { grid-template-columns: 64px minmax(0, 1fr) auto; padding: var(--s3) var(--s4); } }

/* ---------- השעות שלי + תיקוני נוכחות ---------- */
.nav a .nav-badge { margin-inline-start: auto; min-width: 22px; height: 22px; padding: 0 6px; font-size: 11px; background: var(--cannot); color: #fff; border: 0; }
.hours-top { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: var(--s4); }
.hours-main { padding: var(--s5); display: flex; flex-direction: column; gap: var(--s3); }
.hours-main .big { display: flex; align-items: baseline; gap: var(--s2); flex-wrap: wrap; }
.hours-main .big b { font-size: 40px; line-height: 1; font-variant-numeric: tabular-nums; }
.hours-main .big span { color: var(--muted); }
.bar { height: 10px; border-radius: var(--r-pill); background: var(--surface-2); overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: inherit; background: var(--primary); min-width: 2px; }
.bar > i.over { background: var(--can); }
.split { padding: var(--s4) var(--s5); display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: var(--s3); align-content: start; }
.split div { display: flex; flex-direction: column; gap: 2px; }
.split .k { font-size: var(--fs-xs); color: var(--muted); }
.split .v { font-size: var(--fs-lg); font-weight: 600; font-variant-numeric: tabular-nums; }
.split .v.zero { color: var(--line-strong); }
.days-table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.days-table th { text-align: start; font-weight: 500; color: var(--muted); font-size: var(--fs-xs); padding: var(--s2) var(--s4); border-bottom: 1px solid var(--line); background: var(--surface-2); }
.days-table td { padding: var(--s3) var(--s4); border-bottom: 1px solid var(--line); vertical-align: top; }
.days-table tr:last-child td { border-bottom: 0; }
.days-table tr.today td { background: var(--primary-soft); }
.days-table tr.issue td:first-child { box-shadow: inset -3px 0 0 var(--can); }
.days-table .num { font-variant-numeric: tabular-nums; font-weight: 600; white-space: nowrap; }
.days-table .sub { display: block; font-size: var(--fs-xs); color: var(--muted); font-weight: 400; }
.days-table .marks { display: flex; flex-wrap: wrap; gap: 4px 10px; }
.days-table .marks .fix { color: var(--primary-ink); }
.days-table .row-act { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.btn-sm { min-height: 32px; padding: 4px 10px; font-size: var(--fs-xs); }
.fix-list { list-style: none; margin: 0; padding: 0; }
.fix-list li { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2) var(--s3); padding: var(--s3) var(--s5); border-top: 1px solid var(--line); font-size: var(--fs-sm); }
.fix-list li:first-child { border-top: 0; }
.fix-list .grow { flex: 1 1 200px; min-width: 0; }
.fix-list .note { color: var(--muted); font-size: var(--fs-xs); display: block; }
@media (max-width: 900px) { .hours-top { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 640px) {
  .days-table thead { display: none; }
  .days-table, .days-table tbody, .days-table tr, .days-table td { display: block; width: 100%; }
  .days-table tr { padding: var(--s3) var(--s4); border-bottom: 1px solid var(--line); display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px var(--s3); }
  .days-table td { padding: 0; border: 0; }
  .days-table td[data-k="day"] { grid-column: 1; }
  .days-table td[data-k="worked"] { grid-column: 2; grid-row: 1; text-align: end; }
  .days-table td[data-k="planned"], .days-table td[data-k="marks"], .days-table td[data-k="act"] { grid-column: 1 / -1; }
  .days-table td[data-k="planned"]:empty { display: none; }
  .days-table tr.today td { background: none; } .days-table tr.today { background: var(--primary-soft); }
  .days-table tr.issue td:first-child { box-shadow: none; } .days-table tr.issue { box-shadow: inset -3px 0 0 var(--can); }
  .hours-main .big b { font-size: 34px; }
}
a.stat-link { color: inherit; transition: border-color .15s; }
a.stat-link:hover { text-decoration: none; border-color: var(--primary); }

.app-row { display: flex; align-items: center; gap: var(--s3); padding: var(--s3) var(--s4); border-top: 1px solid var(--line); flex-wrap: wrap; }
.card-head + .app-row { border-top: 0; }
.app-row .ic { flex: none; width: 36px; height: 36px; border-radius: var(--r-md); background: var(--primary-soft); color: var(--primary); display: grid; place-items: center; }
.app-row .ic svg { width: 20px; height: 20px; }
.app-row .grow { flex: 1 1 160px; min-width: 0; }
.app-row b { font-size: var(--fs-sm); }
.app-row p { font-size: var(--fs-xs); color: var(--muted); margin-top: 2px; }
.app-row .acts { display: flex; gap: 6px; margin-inline-start: auto; }
.chip.rule-warn { box-shadow: inset 0 0 0 2px var(--can); }
.rules-box { display: flex; flex-direction: column; gap: 6px; }
.rules-box ul { margin: 0; padding-inline-start: 18px; display: flex; flex-direction: column; gap: 2px; }
.rules-box .link-btn { color: var(--can-ink); font-weight: 600; text-decoration: underline; }
