/* ===== HZNK חמ"ל מבצע — עיצוב ===== */
:root {
  --navy:    #102a54;
  --navy-2:  #16356a;
  --blue:    #2b7fff;
  --blue-soft:#e8f0ff;
  --bg:      #eef2f8;
  --card:    #ffffff;
  --ink:     #14203a;
  --muted:   #6b7892;
  --line:    #e1e7f1;
  --green:   #1faa6b;
  --green-bg:#e6f7ef;
  --orange:  #e8941a;
  --orange-bg:#fdf2e0;
  --red:     #e0463c;
  --red-bg:  #fcebe9;
  --radius:  16px;
  --shadow:  0 2px 10px rgba(16,42,84,.07);
  font-family: "Segoe UI", "Assistant", "Arial Hebrew", Arial, sans-serif;
}

* { box-sizing: border-box; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  -webkit-font-smoothing: antialiased;
}

/* ---- סרגל עליון ---- */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 14px 24px; flex-wrap: wrap;
  background: linear-gradient(120deg, var(--navy) 0%, var(--navy-2) 100%);
  color: #fff; box-shadow: var(--shadow);
}
.brand { display: flex; align-items: center; gap: 14px; }
.brand-mark {
  width: 52px; height: 52px; border-radius: 12px;
  display: grid; place-items: center; font-weight: 800; font-size: 17px;
  background: #fff; color: var(--navy); letter-spacing: -.5px;
  box-shadow: inset 0 0 0 3px var(--blue);
}
.brand-text h1 { margin: 0; font-size: 21px; font-weight: 800; }
.brand-text p  { margin: 2px 0 0; font-size: 13px; opacity: .8; }

.topbar-meta { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.live-pill {
  display: flex; align-items: center; gap: 7px;
  background: rgba(255,255,255,.12); padding: 7px 13px; border-radius: 999px;
  font-size: 13px; font-weight: 600;
}
.live-pill .dot {
  width: 9px; height: 9px; border-radius: 50%; background: #2dd47f;
  box-shadow: 0 0 0 0 rgba(45,212,127,.7); animation: pulse 1.8s infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(45,212,127,.6); }
  70%  { box-shadow: 0 0 0 8px rgba(45,212,127,0); }
  100% { box-shadow: 0 0 0 0 rgba(45,212,127,0); }
}
.clock-box, .sprint-badge {
  background: rgba(255,255,255,.1); border-radius: 12px; padding: 6px 14px;
  text-align: center; min-width: 92px;
}
.clock-label { display: block; font-size: 11px; opacity: .7; }
.clock-val { font-size: 20px; font-weight: 800; font-variant-numeric: tabular-nums; }
.sprint-badge { background: var(--blue); }
.sprint-num { display: block; font-size: 12px; font-weight: 700; opacity: .9; }
.sprint-time { font-size: 20px; font-weight: 800; font-variant-numeric: tabular-nums; }

/* ---- פריסה ---- */
.wrap { max-width: 1400px; margin: 0 auto; padding: 22px; }
.block { margin-top: 26px; }
.block-title {
  font-size: 17px; margin: 0 0 12px; font-weight: 800; color: var(--navy);
  display: flex; align-items: baseline; gap: 10px;
}
.block-title small { font-size: 12px; font-weight: 600; color: var(--muted); }

.card {
  background: var(--card); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 18px; border: 1px solid var(--line);
}

/* ---- KPI ראשי ---- */
.kpi-row { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 16px; }
.kpi {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 20px; border: 1px solid var(--line); position: relative; overflow: hidden;
}
.kpi.hero { background: linear-gradient(135deg, var(--navy) 0%, var(--navy-2) 100%); color: #fff; border: none; }
.kpi h3 { margin: 0 0 10px; font-size: 14px; font-weight: 700; opacity: .85; }
.kpi .big { font-size: 44px; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; }
.kpi .big small { font-size: 18px; font-weight: 600; opacity: .6; }
.kpi .sub { font-size: 13px; margin-top: 8px; opacity: .8; }

.bar { height: 12px; border-radius: 999px; background: rgba(255,255,255,.22); margin-top: 14px; overflow: hidden; }
.kpi:not(.hero) .bar { background: #eef1f7; }
.bar > i { display: block; height: 100%; border-radius: 999px; background: var(--blue); transition: width .6s ease; }

.split { display: flex; gap: 10px; margin-top: 6px; }
.split .seg { flex: 1; text-align: center; padding: 10px; border-radius: 12px; background: #f5f8fd; }
.split .seg b { display: block; font-size: 26px; font-weight: 800; }
.split .seg span { font-size: 12px; color: var(--muted); }
.split .seg.rep b { color: var(--blue); }
.split .seg.qr b { color: #7b54d6; }

.countdown-big { font-size: 46px; font-weight: 800; font-variant-numeric: tabular-nums; color: var(--navy); }

/* ---- צבעי רמזור ---- */
.rag-green  { --rc: var(--green);  --rcb: var(--green-bg); }
.rag-orange { --rc: var(--orange); --rcb: var(--orange-bg); }
.rag-red    { --rc: var(--red);    --rcb: var(--red-bg); }
.pace { font-weight: 800; color: var(--rc); }

/* ---- אזורים ---- */
.areas-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.area-card {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 18px; border: 1px solid var(--line); border-top: 5px solid var(--rc);
}
.area-card .area-head { display: flex; justify-content: space-between; align-items: center; }
.area-card h3 { margin: 0; font-size: 18px; font-weight: 800; }
.chip { font-size: 11px; font-weight: 700; padding: 4px 10px; border-radius: 999px; background: var(--rcb); color: var(--rc); }
.area-card .num { font-size: 34px; font-weight: 800; margin-top: 8px; font-variant-numeric: tabular-nums; }
.area-card .num small { font-size: 15px; color: var(--muted); font-weight: 600; }
.area-meta { display: flex; gap: 14px; margin-top: 10px; font-size: 13px; color: var(--muted); }
.area-meta b { color: var(--ink); }

/* ---- צוותים ---- */
.teams-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.team-card {
  background: var(--card); border-radius: 14px; box-shadow: var(--shadow);
  padding: 14px; border: 1px solid var(--line); border-right: 5px solid var(--rc);
}
.team-card h4 { margin: 0 0 4px; font-size: 15px; font-weight: 800; }
.team-card .t-area { font-size: 11px; color: var(--muted); }
.team-card .t-num { font-size: 26px; font-weight: 800; margin-top: 6px; font-variant-numeric: tabular-nums; }
.team-card .t-num small { font-size: 12px; color: var(--muted); }
.team-card .t-pace { font-size: 12px; margin-top: 4px; }

/* ---- חמ"ל ---- */
.cmd-row { display: grid; grid-template-columns: 1fr 1.4fr; gap: 16px; margin-top: 26px; }
.q-list { list-style: none; margin: 0; padding: 0; }
.q-list li { padding: 11px 0; border-bottom: 1px dashed var(--line); font-size: 14px; }
.q-list li:last-child { border-bottom: none; }
.q-list .q { color: var(--muted); display: block; font-size: 12px; margin-bottom: 3px; }
.q-list .a { font-weight: 700; }

.reco-list { display: flex; flex-direction: column; gap: 10px; }
.reco {
  border: 1px solid var(--line); border-right: 5px solid var(--rc, var(--blue));
  border-radius: 12px; padding: 12px 14px; background: #fcfdff;
}
.reco .reco-head { display: flex; align-items: center; gap: 8px; }
.reco .code { font-size: 11px; font-weight: 800; background: var(--navy); color: #fff; padding: 2px 8px; border-radius: 6px; }
.reco .reco-title { font-weight: 800; font-size: 14px; }
.reco .reco-where { font-size: 12px; color: var(--rc, var(--blue)); font-weight: 700; }
.reco .reco-action { font-size: 13px; margin-top: 6px; color: #36425e; }
.reco-list.muted .reco { border-right-color: var(--muted); opacity: .92; }
.manual-playbook { margin-top: 14px; }
.manual-playbook summary { cursor: pointer; font-weight: 700; color: var(--navy); font-size: 13px; }
.empty-note { color: var(--muted); font-size: 13px; padding: 10px 0; }

/* ---- טבלת נציגים ---- */
.table-wrap { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); border: 1px solid var(--line); overflow: hidden; }
.reps-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.reps-table th, .reps-table td { padding: 10px 14px; text-align: right; }
.reps-table thead th { background: var(--navy); color: #fff; font-weight: 700; font-size: 12px; }
.reps-table tbody tr { border-top: 1px solid var(--line); }
.reps-table tbody tr:nth-child(even) { background: #f8fafd; }
.reps-table .rep-name { font-weight: 700; }
.reps-table .lead-flag { font-size: 10px; background: var(--blue-soft); color: var(--blue); padding: 1px 6px; border-radius: 5px; margin-right: 5px; }
.status-dot { display: inline-block; width: 11px; height: 11px; border-radius: 50%; background: var(--rc); }
.mini-bar { width: 70px; height: 8px; border-radius: 999px; background: #eef1f7; overflow: hidden; display: inline-block; vertical-align: middle; margin-left: 8px; }
.mini-bar > i { display: block; height: 100%; background: var(--rc); }

/* ---- פוטר ---- */
.foot {
  max-width: 1400px; margin: 28px auto 18px; padding: 0 22px;
  display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  font-size: 12px; color: var(--muted);
}

/* ---- רספונסיבי ---- */
@media (max-width: 1100px) {
  .kpi-row { grid-template-columns: 1fr; }
  .areas-grid { grid-template-columns: 1fr; }
  .teams-grid { grid-template-columns: repeat(2, 1fr); }
  .cmd-row { grid-template-columns: 1fr; }
}
@media (max-width: 620px) {
  .teams-grid { grid-template-columns: 1fr; }
  .reps-table th:nth-child(4), .reps-table td:nth-child(4) { display: none; }
}
