/*
 * elidobit-consent.css — באנר העוגיות, חלון ההגדרות, וקישורי הפוטר המשפטיים.
 * תיקון 13, 18.11.2026. נטען בכל עמודי וורדפרס, ב-/agents/ וב-/review/.
 *
 * נגישות (AGENTS.md §2, ת"י 5568 / WCAG AA):
 *   טקסט #1f2937 על #ffffff = 14.7:1 · קישור #2f4691 על #ffffff = 8.2:1
 *   כפתור ראשי: לבן על #243150 = 12.1:1 · כפתור משני: #243150 על לבן = 12.1:1
 *   טבעת פוקוס 3px #b45309 (4.9:1 מול לבן) עם מרווח — אף פעם לא outline:none.
 * RTL (AGENTS.md §5): רק תכונות לוגיות. כל הכללים תחומים תחת .elido-cc* /
 * .elido-legal* כדי לא לדלוף לעיצוב של אלמנטור.
 */

.elido-cc,
.elido-cc *,
.elido-cc-modal,
.elido-cc-modal * {
  box-sizing: border-box;
}

.elido-cc {
  position: fixed;
  inset-inline: 0;
  bottom: 0;
  z-index: 2147483000;
  background: #ffffff;
  color: #1f2937;
  border-top: 3px solid #243150;
  box-shadow: 0 -6px 24px rgba(17, 24, 39, 0.18);
  font-family: 'Assistant', 'סימונה', 'Simona', -apple-system, 'Segoe UI', Arial, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  direction: rtl;
  text-align: start;
  max-height: 60vh;
  overflow-y: auto;
}
.elido-cc__inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 18px 28px;
}
.elido-cc__copy { flex: 1 1 auto; min-width: 0; }
.elido-cc__title { margin: 0 0 4px; font-size: 16px; color: #111827; }
.elido-cc__text { margin: 0; color: #1f2937; }
.elido-cc__link,
.elido-cc-modal a {
  color: #2f4691;
  text-decoration: underline;
  font-weight: 700;
}
.elido-cc__link:hover,
.elido-cc-modal a:hover { color: #1e2a4a; }

.elido-cc__actions {
  flex: 0 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.elido-cc__btn {
  -webkit-appearance: none;
  appearance: none;
  min-height: 44px;
  min-width: 128px;
  padding: 10px 18px;
  border-radius: 10px;
  border: 2px solid #243150;
  font: inherit;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  text-align: center;
}
/* "אישור הכול" ו"דחייה" — אותו סגנון בדיוק: אותו גודל, אותו צבע, אותה בולטות. */
.elido-cc__btn--main { background: #243150; color: #ffffff; }
.elido-cc__btn--main:hover { background: #2f4691; border-color: #2f4691; }
.elido-cc__btn--alt { background: #ffffff; color: #243150; }
.elido-cc__btn--alt:hover { background: #eef2fb; }

.elido-cc__btn:focus-visible,
.elido-cc__link:focus-visible,
.elido-cc-modal a:focus-visible,
.elido-cc-dialog__x:focus-visible,
.elido-cc-cat input:focus-visible,
.elido-legal-btn:focus-visible,
.elido-legal-links a:focus-visible,
.elido-consent-open--inline:focus-visible {
  outline: 3px solid #b45309;
  outline-offset: 2px;
}
.elido-cc-dialog:focus { outline: 3px solid #b45309; outline-offset: -3px; }

/* ---- layer 2 ---- */
.elido-cc-modal[hidden] { display: none !important; }
.elido-cc-modal {
  position: fixed;
  inset: 0;
  z-index: 2147483001;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  direction: rtl;
  font-family: 'Assistant', 'סימונה', 'Simona', -apple-system, 'Segoe UI', Arial, sans-serif;
}
.elido-cc-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(17, 24, 39, 0.55);
}
.elido-cc-dialog {
  position: relative;
  width: 100%;
  max-width: 560px;
  max-height: calc(100vh - 32px);
  overflow-y: auto;
  background: #ffffff;
  color: #1f2937;
  border-radius: 16px;
  padding: 24px 22px 20px;
  box-shadow: 0 20px 50px rgba(17, 24, 39, 0.35);
  font-size: 15px;
  line-height: 1.6;
  text-align: start;
}
.elido-cc-dialog__title {
  margin: 0 0 8px;
  padding-inline-end: 44px;
  font-size: 21px;
  line-height: 1.3;
  color: #111827;
  font-family: inherit;
}
.elido-cc-dialog__desc { margin: 0 0 14px; }
.elido-cc-dialog__x {
  position: absolute;
  inset-block-start: 12px;
  inset-inline-end: 12px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 2px solid transparent;
  background: #f3f4f6;
  color: #111827;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
}
.elido-cc-dialog__x:hover { background: #e5e7eb; }
.elido-cc-fs { border: 0; margin: 0; padding: 0; min-width: 0; }
.elido-cc-cat {
  border: 1px solid #d1d5db;
  border-radius: 12px;
  padding: 12px 14px;
  margin: 0 0 10px;
}
.elido-cc-cat__head { display: flex; align-items: center; gap: 10px; }
.elido-cc-cat__head label { font-weight: 700; color: #111827; cursor: pointer; }
.elido-cc-cat input[type="checkbox"] {
  width: 22px;
  height: 22px;
  margin: 0;
  flex: 0 0 auto;
  accent-color: #243150;
  cursor: pointer;
}
.elido-cc-cat input[disabled] { cursor: not-allowed; }
.elido-cc-cat__d { margin: 6px 0 0; padding-inline-start: 32px; color: #374151; font-size: 14px; }
.elido-cc-dialog__actions { margin-top: 14px; }

.elido-cc-sr {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0; border: 0;
  overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%);
  white-space: nowrap;
}

@media (max-width: 760px) {
  .elido-cc__inner { flex-direction: column; align-items: stretch; padding: 14px 14px 16px; gap: 12px; }
  .elido-cc { font-size: 14.5px; }
  .elido-cc__actions { display: grid; grid-template-columns: 1fr 1fr; }
  .elido-cc__btn { min-width: 0; width: 100%; }
  .elido-cc__btn--alt { grid-column: 1 / -1; }
  .elido-cc-dialog { padding: 20px 16px 16px; }
  .elido-cc-dialog__actions { display: grid; grid-template-columns: 1fr 1fr; }
}

/* ---- footer legal links (מדיניות פרטיות · הגדרות עוגיות) ---- */
.elido-legal-btn {
  -webkit-appearance: none;
  appearance: none;
  background: none;
  border: 0;
  padding: 0;
  margin: 0;
  font: inherit;
  color: inherit;
  text-decoration: underline;
  cursor: pointer;
  line-height: inherit;
}
.elido-legal-links { margin: 0; }
.elido-legal-links a { color: inherit; text-decoration: underline; }
.elido-legal-sep { padding-inline: 0.45em; }

/* בתוך פס הפוטר של דף הבית (אלמנטור, רקע #4C63A6 — לבן עליו 5.8:1).
   !important על הצבע: ה-kit של אלמנטור צובע p ו-a בסגוליות גבוהה יותר, וכך גם
   עקיפות הניגודיות ב-elidobit-a11y.php. בלי זה הטקסט יוצא #333 על כחול (2.6:1). */
p.elido-legal-links.elido-legal-links--band {
  color: #ffffff !important;
  font-size: 15px;
  line-height: 1.6;
  margin: 4px 0 0;
  text-align: center;
}
p.elido-legal-links--band a,
p.elido-legal-links--band .elido-legal-btn,
p.elido-legal-links--band .elido-legal-sep { color: #ffffff !important; }
/* בפוטר ברירת המחדל של התבנית (עמוד ההשוואה): .copyright הוא flex בשורה,
   אז מרווח מהשורה "כל הזכויות שמורות". טקסט #333 על לבן — 12.6:1. */
.site-footer .copyright p.elido-legal-links--theme,
p.elido-legal-links.elido-legal-links--theme { margin: 0 !important; }
.site-footer .copyright:has(> .elido-legal-links--theme) { flex-wrap: wrap; gap: 4px 24px; }

/* פוטר המעטפת: שורה שנייה מתחת ל"הצהרת נגישות", כמו בפס של דף הבית */
.ea-shell-footer .elido-legal-line { display: block; margin-top: 2px; }

/* פס משפטי עצמאי לעמודי אלמנטור בלי פוטר (שאלון, הצהרת נגישות) */
.elido-legal-footer {
  background: #4c63a6;
  color: #ffffff;
  direction: rtl;
  font-family: 'Assistant', 'סימונה', 'Simona', -apple-system, 'Segoe UI', Arial, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  padding: 16px 20px;
  text-align: center;
}
.elido-legal-footer p.elido-legal-links { margin: 0; color: #ffffff !important; font-size: 15px; }
.elido-legal-footer a,
.elido-legal-footer .elido-legal-btn,
.elido-legal-footer .elido-legal-sep { color: #ffffff !important; }
.elido-legal-footer .elido-legal-btn:focus-visible,
.elido-legal-footer a:focus-visible,
.elido-legal-links--band a:focus-visible,
.elido-legal-links--band .elido-legal-btn:focus-visible,
.ea-shell-footer .elido-legal-btn:focus-visible {
  outline: 3px solid #ffffff;
  outline-offset: 2px;
}

/* כפתור "שינוי הגדרות העוגיות" בתוך עמוד המדיניות */
.elido-consent-open--inline {
  -webkit-appearance: none;
  appearance: none;
  min-height: 44px;
  padding: 10px 18px;
  border-radius: 10px;
  border: 2px solid #243150;
  background: #ffffff;
  color: #243150;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
.elido-consent-open--inline:hover { background: #eef2fb; }

/* ---- form privacy notices and consent checkboxes ---- */
.elido-form-notice {
  font-size: 14px;
  line-height: 1.6;
  color: #1f2937;
  background: #f5f8fd;
  border: 1px solid #d6def0;
  border-inline-start: 4px solid #2f4691;
  border-radius: 10px;
  padding: 10px 14px;
  margin: 4px 0 10px;
  text-align: start;
  direction: rtl;
}
.elido-form-notice p { margin: 0 0 4px; color: #1f2937; font-size: 14px; line-height: 1.6; }
.elido-form-notice p:last-child { margin-bottom: 0; }
.elido-form-notice a { color: #2f4691; text-decoration: underline; font-weight: 700; }
.elido-form-notice a:focus-visible { outline: 3px solid #b45309; outline-offset: 2px; }

.elido-form-consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14.5px;
  line-height: 1.55;
  color: #1f2937;
  background: #ffffff;
  border: 1px solid #d6def0;
  border-radius: 10px;
  padding: 10px 14px;
  margin: 0 0 10px;
  text-align: start;
  direction: rtl;
}
.elido-form-consent input[type="checkbox"] {
  width: 22px;
  height: 22px;
  margin: 1px 0 0;
  flex: 0 0 auto;
  accent-color: #243150;
  cursor: pointer;
}
.elido-form-consent input[type="checkbox"]:focus-visible { outline: 3px solid #b45309; outline-offset: 2px; }
.elido-form-consent label { cursor: pointer; color: #1f2937; font-weight: 600; }
.elido-form-consent a { color: #2f4691; text-decoration: underline; font-weight: 700; }
.elido-form-consent .elido-req { color: #b91c1c; font-weight: 700; }

/* פוטר המעטפת של עמודי התוכן (#4C63A6): הכפתור נראה כמו הקישורים שלידו */
.ea-shell-footer .elido-legal-btn { color: #ffffff !important; text-decoration: none; font-weight: inherit; }
.ea-shell-footer .elido-legal-btn:hover,
.ea-shell-footer .elido-legal-btn:focus { text-decoration: underline; text-underline-offset: 3px; }
