/* ניהול: עדכוני נתונים, סטטיסטיקות, שאלות ללא תשובה */
/* ===== עדכוני נתונים (רק לבעל האתר) ===== */
.admin-only[hidden] {
  display: none !important;
}
.upd-count {
  margin-right: auto;
  margin-left: 8px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: #D93025;
  color: #FFFFFF;
  font-size: calc(12px * var(--a11y-text, 1));
  line-height: calc(18px * var(--a11y-text, 1));
  text-align: center;
}
.upd-count[hidden] {
  display: none;
}
/* טלפון: משמאל לפריט יש חץ, והמונה נעצר 12 פיקסלים לפניו */
@media (max-width: 767px) {
  .upd-count {
    margin-left: 30px;
  }
}
.upd-list {
  list-style: none;
  margin: 20px 0 0;
  padding: 0;
}
.upd-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 0;
  border-top: 1px solid var(--box-stroke);
}
.upd-item:first-child {
  border-top: none;
}
.upd-main {
  flex: 1;
  min-width: 0;
}
.upd-name {
  margin: 0;
  font-size: calc(16px * var(--a11y-text, 1));
  line-height: 1.3;
  color: var(--text);
}
.upd-meta {
  margin: 4px 0 0;
  font-size: calc(13px * var(--a11y-text, 1));
  line-height: 1.4;
  color: var(--placeholder);
}
.upd-meta.upd-dates {
  margin-top: 2px;
}
.upd-badge {
  flex: none;
  font-size: calc(13px * var(--a11y-text, 1));
  font-weight: 500;
  line-height: 1.3;
  white-space: nowrap;
  color: var(--placeholder);
}
.upd-badge.is-due {
  padding: 4px 10px;
  border-radius: 999px;
  background: #FDECEA;
  color: #D93025;
}
/* "סטטיסטיקות" (ניהול): כרטיסי מספרים 2 על 2, גרף פקודות ביום, פקודות פופולריות ותוכניות.
   הנתונים מגיעים מהפונקציה /api/admin-stats (רק לבעל האתר) */
.st-tiles {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 18px 0 0;
}
.st-tile {
  min-width: 0;
  padding: 12px 14px;
  border: 1px solid var(--box-stroke);
  border-radius: 14px;
  background: var(--box-bg);
}
.st-label, .st-num, .st-sub {
  margin: 0;
  overflow-wrap: anywhere;
}
.st-label {
  font-size: calc(13px * var(--a11y-text, 1));
  line-height: 1.3;
  color: var(--placeholder);
}
.st-num {
  margin-top: 4px;
  font-size: calc(26px * var(--a11y-text, 1));
  font-weight: 600;
  line-height: 1.15;
  color: var(--text);
}
.st-sub {
  margin-top: 2px;
  font-size: calc(12px * var(--a11y-text, 1));
  line-height: 1.4;
  color: var(--placeholder);
}
.st-sub b {
  font-weight: 500;
  color: var(--selected);
}
.st-h {
  margin: 22px 0 10px;
  font-size: calc(15px * var(--a11y-text, 1));
  font-weight: 600;
  line-height: 1.3;
  color: var(--text);
}
.st-box {
  padding: 14px;
  border: 1px solid var(--box-stroke);
  border-radius: 14px;
  background: var(--box-bg);
}
.st-range {
  display: flex;
  gap: 6px;
  margin: 10px 0 12px;
}
.st-range button {
  padding: 4px 10px;
  border: 1px solid var(--box-stroke);
  border-radius: 999px;
  background: none;
  font: inherit;
  font-size: calc(12px * var(--a11y-text, 1));
  line-height: 1.4;
  color: var(--placeholder);
  cursor: pointer;
}
.st-range button[aria-pressed="true"] {
  border-color: var(--send-active);
  background: var(--send-active);
  color: #FFFFFF;
}
.st-range button:focus-visible {
  outline: 2px solid var(--selected);
  outline-offset: 2px;
}
/* הגרף: הזמן משמאל לימין (היום מימין), כמו בגרפים של זמן */
.st-chart {
  display: flex;
  align-items: flex-end;
  gap: 5px;
  height: 110px;
  direction: ltr;
}
.st-chart.is-dense {
  gap: 2px;
}
.st-bar {
  flex: 1;
  min-width: 1px;
  border-radius: 4px 4px 0 0;
  background: var(--send-active);
  opacity: 0.85;
}
.st-chart.is-dense .st-bar {
  border-radius: 2px 2px 0 0;
}
.st-bar.is-today {
  opacity: 1;
}
.st-bar.is-zero {
  min-height: 1px;
  background: var(--box-stroke);
  opacity: 1;
}
.st-axis {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
  direction: ltr;
  font-size: calc(11px * var(--a11y-text, 1));
  color: var(--placeholder);
}
.st-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 0;
}
.st-row .st-name {
  flex: 0 0 120px;
  font-size: calc(13px * var(--a11y-text, 1));
  line-height: 1.3;
  color: var(--text);
}
.st-row .st-track {
  flex: 1;
  height: 8px;
  overflow: hidden;
  border-radius: 99px;
  background: var(--item-hover);
}
.st-row .st-fill {
  display: block;
  height: 100%;
  border-radius: 99px;
  background: var(--send-active);
}
.st-row .st-val {
  flex: 0 0 52px;
  font-size: calc(13px * var(--a11y-text, 1));
  text-align: left;
  color: var(--placeholder);
}
.st-plan {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  border-top: 1px solid var(--box-stroke);
  font-size: calc(14px * var(--a11y-text, 1));
  color: var(--text);
}
.st-plan:first-child {
  border-top: none;
}
.st-plan span:last-child {
  color: var(--placeholder);
}
.st-empty {
  margin: 0;
  font-size: calc(13px * var(--a11y-text, 1));
  color: var(--placeholder);
}
.st-foot {
  margin: 14px 0 0;
  font-size: calc(12px * var(--a11y-text, 1));
  line-height: 1.4;
  color: var(--placeholder);
}
.st-status {
  margin: 18px 0 0;
  font-size: calc(14px * var(--a11y-text, 1));
  line-height: 1.4;
  color: var(--placeholder);
}
.st-status.is-error {
  color: #D93025;
}
:root[data-theme="dark"] .st-status.is-error {
  color: #FF8A80;
}
/* הלוגו מעל המשפט בדף הצ'אט הראשי, 20 פיקסלים מעליו.
   ה-::before של הכותרת שומר את המקום (75 על 70 במחשב), והלוגו עצמו (.chat-logo, SVG) מונח עליו.
   כך הוא נשאר גם כשהטקסט של הכותרת מתחלף (אנימציה, שם המשתמש).
   צבע: #141414 במצב בהיר, #FFFFFF במצב כהה. העיניים חתוכות (שקופות), כך שרואים דרכן את רקע הדף.
   הסוכן "חי": ממצמץ, מסתכל ימינה, ומסתכל ימינה-למטה עם הטיה, בזמנים אקראיים (ראו בסקריפט) */
#chat-heading::before {
  content: "";
  display: block;
  width: 56px;
  height: 52px;
  margin: 0 auto 20px;
}
/* "דיווחים" (ניהול): הנושא, התיאור (כל הטקסט, עם ירידות השורה שנכתבו), ושורת פרטים. "מחיקה" בצד */
.upd-item.rp-item {
  align-items: flex-start;
}
.rp-text {
  margin: 4px 0 0;
  font-size: calc(14px * var(--a11y-text, 1));
  line-height: 1.45;
  color: var(--text);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.rp-part {
  display: inline-block;
  unicode-bidi: isolate;
}
.search-again.rp-delete {
  flex: none;
  margin: 0;
}
/* "העתק" בראש הרשימה של "שאלות ללא תשובה" */
.search-again.ua-copy {
  margin: 0;
}
/* מספר השאלות (מימין) ו"העתק" (משמאל) באותה שורה */
.ua-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 10px 0 12px;
}
.ua-count {
  margin: 0;
  font-size: calc(16px * var(--a11y-text, 1));
  font-weight: 600;
  color: var(--text);
}
.chat-logo {
  position: absolute;
  top: 0;
  left: 50%;
  width: 56px;
  height: 52px;
  transform: translateX(-50%);
  color: #1E6DF6;
  pointer-events: none;
}
/* כחול בשני המצבים (כמו לוגו הסוכן ליד התשובה). בניגודיות גבוהה: הכחול של מצב הניגודיות */
:root.a11y-contrast .chat-logo {
  color: var(--selected);
}
/* חלקי העין שזזים: כל העיניים (הטיה סביב המרכז שלהן), האישונים, והעפעף שיורד מלמעלה */
.chat-logo .eyes {
  transform-box: view-box;
  transform-origin: 698px 315px;
}
.chat-logo .pupil {
  transform-box: view-box;
}
.chat-logo .lid {
  transform-box: fill-box;
  transform-origin: 50% 0;
  transform: scaleY(0);
}
/* הלוגו רק במחשב: בטלפון הוא לא מוצג */
@media (max-width: 767px) {
  #chat-heading::before,
  .chat-logo {
    display: none;
  }
}
/* במחשב: רוחב 75 (גובה לפי היחס 56:52) */
@media (min-width: 768px) {
  #chat-heading::before,
  .chat-logo {
    width: 75px;
    height: 70px;
  }
}
/* App Check (7 ימים): בכל שורה דפדפן ומכשיר, ומתחת הסיבה */
.st-ac .st-row .st-name { flex-basis: 150px; }
.st-ac .st-ac-who, .st-ac .st-ac-why { display: block; }
.st-ac .st-ac-why { font-size: calc(12px * var(--a11y-text, 1)); color: var(--placeholder); }
.st-ac .st-ac-h { margin: 12px 0 2px; }
