/* ==== DLTS Knowledge Hub – RTL, מודרני ונקי עם אנימציות ==== */
.dlts-kc { direction: rtl; font-family: "Heebo", "Alef", Arial, sans-serif; color:#1f2937; }
.dlts-kc .dlts-kc-container { max-width: 1240px; margin: 24px auto; padding: 16px; }
.dlts-kc h2 { margin: 6px 0 16px; font-size: 26px; font-weight: 800; letter-spacing: -0.02em; }
.dlts-kc .dlts-toolbar { display:flex; gap:12px; flex-wrap:wrap; margin: 8px 0 16px; }

/* Cards grid */
.dlts-kc .dlts-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(260px,1fr)); gap: 18px; }
.dlts-kc .dlts-card {
  background: #fff; border:1px solid #eaeaea; border-radius: 18px; padding:16px;
  box-shadow: 0 6px 22px rgba(0,0,0,.06); display:flex; flex-direction:column; gap:10px;
  transform: translateY(0); transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.dlts-kc .dlts-card:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(0,0,0,.08); border-color:#e2e2e2; }
.dlts-kc .dlts-title { font-weight:700; font-size:18px; display:flex; align-items:center; gap:8px; }
.dlts-kc .dlts-title .dot { display:inline-block; width:8px; height:8px; background:#10b981; border-radius:999px; animation:blink 1.8s infinite ease-in-out; }
@keyframes blink { 0%,100% {opacity:.35} 50% {opacity:1} }

.dlts-kc .dlts-meta { font-size: 13px; color:#6b7280; }
.dlts-kc .dlts-actions { display:flex; gap:8px; flex-wrap:wrap; margin-top:6px; }

/* Buttons */
.dlts-kc .btn {
  border:0; border-radius: 12px; padding:10px 14px; cursor:pointer;
  background:#6b7280; color:#ffffff; font-weight:700;
  transition: transform .12s ease, background .2s ease, box-shadow .2s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,.12);
}
.dlts-kc .btn:hover { background:#4b5563; transform: translateY(-1px); }
.dlts-kc .btn:active { transform: translateY(0); }
.dlts-kc .btn.primary { background:#3b82f6; color:#fff; box-shadow: 0 4px 12px rgba(59,130,246,.25); }
.dlts-kc .btn.primary:hover { background:#2563eb; }
.dlts-kc .btn.danger { background:#ef4444; color:#fff; }
.dlts-kc .btn.danger:hover { background:#dc2626; }
.dlts-kc .btn.ghost { background:transparent; color:#374151; border:1px solid #e5e7eb; }

/* Inputs */
.dlts-kc input[type="text"], .dlts-kc input[type="url"], .dlts-kc select, .dlts-kc textarea {
  width:100%; border:1px solid #e5e7eb; border-radius:12px; padding:10px 12px; background:#fff; transition: box-shadow .2s ease, border-color .2s ease;
}
.dlts-kc input:focus, .dlts-kc select:focus, .dlts-kc textarea:focus { outline:none; border-color:#3DC1BC; box-shadow:0 0 0 4px rgba(61,193,188,.12); }

.dlts-kc .dlts-row { display:grid; grid-template-columns: 1fr 1fr; gap:12px; }
@media (max-width: 820px){ .dlts-kc .dlts-row { grid-template-columns: 1fr; } }

/* List */
.dlts-kc .dlts-list { border:1px solid #eee; border-radius: 14px; overflow: hidden; background:#fff; margin-top:12px; }
.dlts-kc .dlts-list .dlts-list-head { background:linear-gradient(90deg,#f9fafb,#f3f4f6); padding:12px 14px; font-weight:800; }
.dlts-kc .dlts-list .dlts-list-body { max-height: 560px; overflow:auto; }
.dlts-kc .dlts-item { display:grid; grid-template-columns: 1fr auto auto; gap:8px; align-items:center; padding:10px 12px; border-bottom:1px solid #f3f4f6; }
.dlts-kc .dlts-item:last-child { border-bottom:0; }
.dlts-kc .dlts-item .name { font-weight:600; }

/* Chips/Tags + muted */
.dlts-kc .dlts-tag { display:inline-block; font-size:12px; padding:2px 8px; border-radius:999px; background:#eef2ff; color:#3730a3; margin-inline-start:6px; }
.dlts-kc .dlts-tag.note { background:#ecfeff; color:#155e75; }
.dlts-kc .muted { color:#6b7280; }

/* Base modal (admin notes etc.) */
.dlts-kc .dlts-modal-backdrop { position:fixed; inset:0; background:rgba(0,0,0,.35); opacity:0; transition:.18s ease; display:flex; align-items:center; justify-content:center; z-index:9999; }
.dlts-kc .dlts-modal { width:min(860px,92vw); background:#fff; border-radius:16px; transform:translateY(10px); opacity:0; transition:.18s ease; padding:12px 14px; box-shadow: 0 10px 30px rgba(0,0,0,.2); }
.dlts-kc .dlts-modal-backdrop.show { opacity:1; }
.dlts-kc .dlts-modal.show { transform:translateY(0); opacity:1; }
.dlts-kc .dlts-modal .dlts-modal-head { display:flex; justify-content:space-between; align-items:center; border-bottom:1px solid #eee; padding-bottom:10px; margin-bottom:10px; }

/* ===== Lightbox / Preview (לצפייה ב-iframe) ===== */
body.dlts-modal-open { overflow: hidden; }
.dlts-kc .dlts-lightbox-backdrop {
  position: fixed; inset: 0; background: rgba(0,0,0,.55);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity .2s ease; z-index: 10000;
}
.dlts-kc .dlts-lightbox-backdrop.show { opacity: 1; }
.dlts-kc .dlts-lightbox {
  width: min(1280px, 96vw); height: min(88vh, 96vh);
  background: #111827; border-radius: 16px; box-shadow: 0 20px 50px rgba(0,0,0,.35);
  display: flex; flex-direction: column; overflow: hidden;
  transform: translateY(8px); opacity: 0; transition: transform .2s ease, opacity .2s ease;
}
.dlts-kc .dlts-lightbox.show { transform: translateY(0); opacity: 1; }
.dlts-kc .dlts-lightbox-head {
  display:flex; align-items:center; justify-content:space-between;
  background: #0b1220; color:#e5e7eb; padding: 10px 14px; border-bottom: 1px solid rgba(255,255,255,.06);
}
.dlts-kc .dlts-lightbox-title { font-weight:700; font-size:15px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.dlts-kc .dlts-lightbox-actions { display:flex; gap:8px; }
.dlts-kc .dlts-lightbox-actions .btn { background:#374151; box-shadow:none; }
.dlts-kc .dlts-lightbox-actions .btn:hover { background:#4b5563; }
.dlts-kc .dlts-lightbox-body { flex: 1; background:#111827; }
.dlts-kc .dlts-iframe { width:100%; height:100%; border:0; display:block; background:#111827; }

/* Staff items grid inside modal */
.dlts-kc .dlts-items-grid {
  display:grid; grid-template-columns: repeat(auto-fill, minmax(260px,1fr)); gap:12px;
}
.dlts-kc .dlts-item-card {
  background:#fff; border:1px solid #eee; border-radius:14px; padding:12px; display:flex; flex-direction:column; gap:8px;
  box-shadow:0 6px 18px rgba(0,0,0,.06);
}
.dlts-kc .dlts-item-card .title { font-weight:700; font-size:15px; }
.dlts-kc .dlts-item-card .meta { font-size:12px; color:#6b7280; display:flex; gap:8px; align-items:center; }
.dlts-kc .dlts-item-card .actions { display:flex; gap:8px; flex-wrap:wrap; }

/* ===== Notes inside modal ===== */
.dlts-kc .dlts-note{
  max-height: 72vh;            /* שומר בתוך המודל */
  overflow: auto;              /* גלילה פנימית לתוכן ארוך */
  direction: rtl;
  text-align: right;
  line-height: 1.8;
  font-size: 15px;
  color: #1f2937;
  word-break: break-word;
  overflow-wrap: anywhere;
  white-space: pre-wrap;       /* שומר ירידות שורה אם הגיע טקסט "רגיל" */
  padding: 4px 2px;
}

/* טיפוגרפיה בסיסית */
.dlts-kc .dlts-note p{ margin:0 0 12px; }
.dlts-kc .dlts-note h1,
.dlts-kc .dlts-note h2,
.dlts-kc .dlts-note h3{ margin:8px 0 10px; font-weight:800; }
.dlts-kc .dlts-note h1{ font-size:22px; }
.dlts-kc .dlts-note h2{ font-size:19px; }
.dlts-kc .dlts-note h3{ font-size:17px; }
.dlts-kc .dlts-note ul, .dlts-kc .dlts-note ol{ margin:0 0 12px; padding-inline-start: 20px; }
.dlts-kc .dlts-note li{ margin:4px 0; }
.dlts-kc .dlts-note a{ color:#2563eb; text-decoration:underline; }
.dlts-kc .dlts-note blockquote{
  margin:10px 0; padding:10px 12px; background:#f9fafb;
  border-right:4px solid #e5e7eb; border-radius:8px;
}

/* קוד/טבלאות/מדיה */
.dlts-kc .dlts-note code{ font-family: ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace; background:#f3f4f6; padding:2px 6px; border-radius:6px; }
.dlts-kc .dlts-note pre{
  background:#0b1220; color:#e5e7eb; padding:10px 12px; border-radius:10px;
  overflow:auto; white-space:pre;
}
.dlts-kc .dlts-note table{ width:100%; border-collapse:collapse; display:block; overflow:auto; }
.dlts-kc .dlts-note th, .dlts-kc .dlts-note td{ border:1px solid #e5e7eb; padding:8px; }
.dlts-kc .dlts-note img, .dlts-kc .dlts-note video{ max-width:100%; height:auto; display:block; }
.dlts-kc .dlts-note iframe, .dlts-kc .dlts-note embed, .dlts-kc .dlts-note object{
  max-width:100%; width:100%; border:0;
}
