/* ==========================================================================
   student.css — Sapir Sabag Student Front
   v118: gift trigger in topbar + gift drawer (student area)
   ========================================================================== */

/* D4-fix: [hidden] חייב לנצח display:block/flex מ-author stylesheet */
[hidden] { display: none !important; }

/* ==========================================================================
   v51: SPA-lite — swap ישיר ללא View Transitions.
   fade-in קצרצר (80ms) מ-JS על .content-wrap בלבד.
   הנאבר והטופבר נשארים קבועים לחלוטין — הבועית מחליקה ב-spring.
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; }

html {
  direction: rtl;
  font-size: 16px;
  scroll-behavior: smooth;
  /* רקע השורש חם — כך אזור הסטטוס-בר (סוללה/וויפי) במובייל/PWA מקבל
     את צבע המוצר במקום פס לבן */
  background: var(--bg-warm);
  /* שומר מקום קבוע לפס הגלילה — מונע שינוי רוחב ה-viewport במעבר בין
     טאבים (תוכן בגבהים שונים), שגרם לקפיצה אופקית של הנאבר הממורכז (fixed). */
  scrollbar-gutter: stable;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--ink);
  /*
     רקע בסיס אחיד וחם. התמונה הזורמת (bg-main-3) מגיעה מ-.home-texture
     שהוא position:fixed inset:0 ומכסה תמיד את כל המסך - גם תחת ה-notch
     וה-home-indicator. נמנעים מ-background-attachment:fixed שנשבר במובייל
     ומשאיר רצועות לא-מכוסות בתחתית בגלילה.
  */
  background: var(--bg-warm);
  line-height: var(--lh-base);
  -webkit-font-smoothing: antialiased;
}

/* ---------- App Shell — גלובלי בכל הרוחבים ---------- */
/*
   מבנה: topbar ו-bottom-nav הם fixed ונשארים תמיד גלויים.
   student-shell וה-body גולשים בין שני הברים.
   בדסקטופ: app-column ממרכז את התוכן ב-max-width 520px.
   הטאב-בר התחתון גם הוא ממורכז ל-520px כדי לשמור על אפקט "מסגרת אפליקציה".
*/

.student-shell {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  position: relative;
  z-index: 1;
  /*
     הרקע עבר ל-body כדי שיכסה גם את האזור מאחורי הנאבר הקבוע.
     ה-shell עצמו שקוף — הוא רק מסגרת layout.
  */
  background: transparent;
}

/* ---------- App Top Bar (כל הרוחבים) ---------- */
/*
   v26: האדר צף ללא בר אטום.
   הלוגו והאווטאר מרחפים כאלמנטים fixed בפינות העליונות.
   ה-.app-topbar עצמו שקוף לחלוטין — אין בר רקע.
   הפייד העליון ב-.student-main דואג לקריאות.
*/
.app-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--sp-4);
  /* ללא רקע — צף על התוכן */
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  height: 56px;
  position: fixed;
  top: calc(env(safe-area-inset-top, 0px) + 12px);   /* אוויר מפס-הסטטוס - אחיד עם עמוד הבית הציבורי (לא דבוק למעלה) */
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 520px;
  z-index: 200;
  /* pointer-events רק על האלמנטים הפנימיים, לא על האזור הריק */
  pointer-events: none;
}

/* לוגו ואווטאר מקבלים pointer-events בנפרד */
.app-topbar-logo,
.app-topbar-avatar {
  pointer-events: auto;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font: inherit;
}

/* טריגר המתנה — חייב pointer-events מפורש (ה-.app-topbar הוא none) */
.app-topbar-gift { pointer-events: auto; }

/* תפריט אווטאר — פרופיל / התנתקות */
.app-topbar-avatar-wrap {
  position: relative;
  pointer-events: auto;
}
.avatar-menu {
  position: absolute;
  top: calc(100% + 8px);
  /* האווטאר בפינה השמאלית של ההאדר — התפריט נפתח פנימה (ימינה)
     כדי לא לברוח מרוחב המסך. */
  left: 0;
  right: auto;
  min-width: 150px;
  background: var(--paper, #fff);
  border: 1px solid rgba(195,174,190,.3);
  border-radius: 14px;
  box-shadow: 0 8px 28px rgba(74,52,34,.16);
  padding: 6px;
  z-index: 300;
}
.avatar-menu-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 9px;
  font-size: 14px;
  color: var(--ink-head);
  text-decoration: none;
  transition: background var(--t-fast);
}
.avatar-menu-item:hover,
.avatar-menu-item:focus-visible {
  background: rgba(232,219,220,.45);
}
.avatar-menu-item--muted { color: var(--muted); }
.avatar-menu-item svg { flex-shrink: 0; }

/* לוגו — ימין ב-RTL */
.app-topbar-logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  /* משטח גלאס עדין מאחורי הלוגו לקריאות על תוכן בהיר */
  background: rgba(251, 247, 247, 0.55);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-radius: 999px;
  padding: 5px 10px 5px 7px;
  border: 1px solid rgba(255,255,255,0.5);
  box-shadow: 0 2px 8px rgba(74,52,34,0.10);
  transition: background var(--t-fast), box-shadow var(--t-fast);
}

.app-topbar-logo:hover,
.app-topbar-logo:focus-visible {
  background: rgba(251, 247, 247, 0.80);
  box-shadow: 0 2px 12px rgba(74,52,34,0.16);
  outline: none;
}

.app-topbar-logo img {
  /* D1: גדל ל-44px (מוגדר ב-layout-student.php width/height) */
  width: 44px;
  height: 44px;
  object-fit: contain;
  filter: none;
  opacity: 1;
  display: block;
}

/* אווטאר — שמאל ב-RTL, קליקבילי */
.app-topbar-avatar {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  border-radius: 50%;
  /* משטח גלאס עדין מאחורי האווטאר */
  background: rgba(251, 247, 247, 0.55);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 3px;
  border: 1px solid rgba(255,255,255,0.5);
  box-shadow: 0 2px 8px rgba(74,52,34,0.10);
  transition: background var(--t-fast), transform var(--t-fast), box-shadow var(--t-fast);
}

.app-topbar-avatar:hover,
.app-topbar-avatar:focus-visible {
  background: rgba(251, 247, 247, 0.80);
  transform: scale(1.05);
  box-shadow: 0 2px 12px rgba(74,52,34,0.16);
  outline: none;
}

/* render_avatar מחזיר img/div — גודל קבוע */
.app-topbar-avatar img,
.app-topbar-avatar > div {
  width: 34px !important;
  height: 34px !important;
  border: none !important;
}

/* ---------- Main ---------- */
.student-main {
  flex: 1;
  background: transparent; /* הרקע מגיע מ-body */
  display: flex;
  justify-content: center;
  /* padding-top: גובה ה-topbar (56px) + 12px אוויר + safe-area (תואם לטופבר שירד 12px) */
  padding-top: calc(68px + env(safe-area-inset-top, 0px));
  /* padding-bottom: ה-content-wrap כבר מפנה מקום ל-capsule, אז כאן רק safe-area
     (היה 110px נוסף וגרם לרווח כפול ענק בתחתית) */
  padding-bottom: env(safe-area-inset-bottom, 0px);

  /*
     v45: הוחלפנו mask-image (שיוצר layer repaint כבד בגלילה)
     בגישה זולה יותר: pseudo-element ::after שמוסיף gradient שקוף
     מעל התוכן בתחתית — ללא repaint בגלילה.
  */
  overflow: hidden; /* חובה לclip ה-::after */
}

/* fade תחתון — pseudo-element סטטי במקום mask-image.
   position:sticky; bottom:0 — תמיד נשאר בתחתית ה-viewport ללא repaint. */
.student-main::after {
  content: '';
  display: block;
  position: sticky;
  bottom: 0;
  height: 70px;
  margin-top: -70px;
  background: linear-gradient(to top, var(--bg-warm, #f5ede5) 0%, transparent 100%);
  pointer-events: none;
  z-index: 1;
}

/* ---------- App Column — עמודה ממורכזת (חוויית אפליקציה בדסקטופ) ---------- */
.app-column {
  width: 100%;
  max-width: 520px;
  background: var(--bg-warm);
  min-height: 100%;
  /* הצל הצדדי בדסקטופ נותן תחושת "מסגרת אפליקציה" */
  box-shadow: 0 0 40px rgba(0,0,0,.18);
}

/* ---------- Content area ---------- */
.content-wrap {
  contain: layout style; /* מגביל repaint לקונטיינר */
  padding: var(--sp-5) var(--sp-4);
  /* מרווח תחתון אחיד מעל הנאבר הצף — משתנה משותף עם הבית המחובר (32px נראה). */
  padding-bottom: var(--shell-content-bottom);
}

/*
  v81-fix: focus management — SPA מבצע h2.focus() לנגישות אחרי ניווט.
  הדפדפן מצייר outline כחול דיפולטי על כל אלמנט שמקבל tabindex="-1" ועבר focus תכנותי.
  :not(:focus-visible) = נכבה רק כשה-focus הגיע מעכבר/תכנותי (לא מקלדת).
  כך: ניווט בין טאבים — אין מלבן. מקלדת Tab — ה-focus-visible הוגדר מותגית.
*/
[tabindex="-1"]:focus:not(:focus-visible) {
  outline: none;
}
/* -webkit-tap-highlight על אלמנטים שמקבלים focus תכנותי */
[tabindex="-1"] {
  -webkit-tap-highlight-color: transparent;
}

/* ---------- Welcome compact — ברכה קומפקטית שורה אחת ---------- */
/*
   v26: ברכת "שלום, נועה" קטנה ועדינה.
   לא תופסת נדל"ן — מפנה מקום לכרטיס המסר היומי שהוא האלמנט הבולט.
*/
.welcome-compact {
  display: flex;
  align-items: baseline;
  gap: var(--sp-2);
  margin-bottom: var(--sp-4);
  padding: 0 var(--sp-1);
}

/* הברכה — Level 1 בהיררכיה (v82: טוקנים סמנטיים) */
.welcome-compact .wc-greeting,
.welcome-compact .wc-name {
  font-family: var(--font-head);
  font-size: var(--fs-greeting);
  color: var(--c-greeting);
  font-weight: var(--fw-greeting);
}

/* ---------- Daily message card — כרטיס מסר יומי ספיר ---------- */
/*
   v26: האלמנט המוביל בראש עמוד הבית.
   עיצוב: כרטיס מותגי עם גרדיאנט mauve → peach, ספרה גדולה בולטת.
*/
/* מאוחד עם .pub-daily-card שבעמוד הבית — רקע תמונה + שכבת הבהרה + פינות 28 */
.daily-card {
  background:
    linear-gradient(rgba(255,255,255,0.22), rgba(255,255,255,0.22)),
    url('/assets/img/daily-msg-bg-2.jpg') center center / cover no-repeat,
    #f8eef1;
  background-origin: border-box;
  background-clip: border-box;
  border: 1px solid rgba(201,169,189,.45);
  border-radius: 28px;
  padding: var(--sp-5) var(--sp-5);
  margin-bottom: var(--sp-6);
  position: relative;
  overflow: hidden;
}

/* בוטל העיגול הדקורטיבי (עיצוב ישן) */
.daily-card::before { content: none; }

.daily-card-meta {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  margin-bottom: var(--sp-3);
  position: relative;
}

.daily-card-num {
  font-family: var(--font-head);
  font-size: 42px;
  line-height: 1;
  color: rgba(74, 52, 34, 0.22);
  font-weight: 400;
  flex-shrink: 0;
  /* ספרה גדולה דקורטיבית */
}

.daily-card-label {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.daily-card-label-top {
  font-size: var(--text-xs);
  color: rgba(74, 52, 34, 0.55);
  font-weight: 500;
}

.daily-card-label-title {
  font-family: var(--font-head);
  font-size: var(--text-xl);
  color: var(--ink-head);
  font-weight: 400;
  line-height: var(--lh-tight);
}

.daily-card-message {
  font-size: var(--text-base);
  color: var(--ink);
  line-height: var(--lh-base);
  position: relative;
}

/* ---------- Welcome / Hero strip — נשמר לתאימות אחורה ---------- */
.welcome-strip {
  background: linear-gradient(
    135deg,
    #c8a8b8 0%,
    #d4b8a8 45%,
    #e8d0be 100%
  );
  border-radius: var(--radius-lg);
  padding: var(--sp-6) var(--sp-7);
  color: var(--ink-head);
  margin-bottom: var(--sp-6);
  position: relative;
  overflow: hidden;
}

.welcome-strip::before {
  content: '';
  position: absolute;
  top: -40px;
  left: -40px;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: rgba(255,255,255,.18);
}

.welcome-strip .welcome-label {
  font-size: var(--text-sm);
  color: var(--accent);
  font-weight: 600;
  margin-bottom: var(--sp-2);
}

.welcome-strip h1 {
  margin: 0 0 var(--sp-2);
  font-family: var(--font-head);
  font-size: var(--h2);
  color: var(--ink-head);
  font-weight: 400;
  line-height: var(--lh-tight);
}

.welcome-strip .welcome-sub {
  font-size: var(--text-base);
  color: var(--ink);
  opacity: .75;
}

/* ---------- Home stacked cards (מפגש קרוב + שיעור אחרון, שוכבים) ---------- */
.home-stack {
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
  margin-bottom: var(--sp-6);
}
.home-card {
  background: var(--paper);
  border-radius: 24px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--line);
  padding: var(--sp-4) var(--sp-5);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
}
/* שיעור אחרון — נראות שונה: שקוף עם בורדר מאוב, להבדיל מהמפגש */
.home-card--lesson {
  background: transparent;
  box-shadow: none;
  border: 1px solid rgba(195, 174, 190, 0.55);
}
.home-card-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.home-card-label { font-size: var(--text-xs); color: var(--muted); }
.home-card-value {
  font-family: var(--font-head);
  font-size: var(--text-xl);
  color: var(--ink-head);
  line-height: 1.2;
}
.home-card-value--sm { font-size: var(--text-md); }
.home-card-value--muted { font-size: var(--text-lg); color: var(--muted); }
.home-card-sub { font-size: var(--text-sm); color: var(--muted); text-align: left; white-space: nowrap; }
.home-card-link { font-size: var(--text-sm); color: var(--accent); white-space: nowrap; text-decoration: none; }
.home-card-link:hover { text-decoration: underline; }

/* B3: כרטיס מפגש קרוב — 3 מדרגות גודל בלבד
   תווית: 14px muted (הוגדרה ב-home-card-label)
   תאריך: 21px semibold
   שעה + כתובת: 15px רגיל
*/
.home-card--meeting { align-items: center; } /* B1: center כדי שהחץ יתמרכז */
.home-card--meeting .home-card-main { gap: 5px; }
.home-card-meeting-date {
  font-family: var(--font-head);
  font-size: 21px; /* B3: היה text-xl (20-24px bold) — הורד לגודל אחד מסודר */
  font-weight: 600;
  color: var(--ink-head);
  line-height: 1.2;
}
.home-card-meeting-time {
  font-size: 15px; /* B3: היה text-base (15-16px) — אחיד עם הכתובת */
  color: var(--ink);
  font-weight: 400;
}
.home-card-meeting-loc {
  font-size: 15px; /* B3: היה text-sm (13-14px) — הועלה לאותו גודל כמו השעה */
  color: var(--muted);
  font-weight: 400;
}

/* ---------- באנר "חומרים הועלו" — הפניה לשיעורים ---------- */
.materials-banner {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  background: var(--accent);
  color: var(--on-accent);
  border-radius: var(--radius);
  padding: var(--sp-3) var(--sp-5);
  margin-bottom: var(--sp-5);
  text-decoration: none;
  box-shadow: var(--shadow-sm);
  transition: background var(--t-base);
}
.materials-banner:hover { background: var(--accent-mid); }
.materials-banner-icon { color: var(--accent-gold); font-size: 16px; flex-shrink: 0; }
.materials-banner-text { flex: 1; font-weight: 600; font-size: var(--text-base); }
.materials-banner-cta { font-size: var(--text-sm); opacity: .9; white-space: nowrap; }

/* ---------- Info cards ---------- */
.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--sp-4);
  margin-bottom: var(--sp-6);
}

.info-card {
  background: var(--paper);
  border-radius: var(--radius);
  padding: var(--sp-5);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--line);
}

.info-card .card-icon {
  font-size: 22px;
  margin-bottom: var(--sp-3);
  display: block;
}

.info-card .card-label {
  font-size: var(--text-xs);
  color: var(--muted);
  margin-bottom: var(--sp-1);
}

.info-card .card-value {
  font-family: var(--font-head);
  font-size: var(--text-xl);
  color: var(--ink-head);
  line-height: var(--lh-tight);
}

.info-card .card-sub {
  font-size: var(--text-sm);
  color: var(--muted);
  margin-top: var(--sp-1);
}

/* ---------- Section title ---------- */
/*
   היררכיה: ברכה (.welcome-compact) = --h2 (גדולה).
   כותרות סקשן = --text-xl, weight 500, צבע --muted — מדרגה אחת מתחת לברכה.
*/
/*
   section-title — כותרת סקשן קנונית (Level 2 בהיררכיה).
   v82: משתמש בטוקנים סמנטיים מ-tokens.css.
   מקביל ל-.pub-section-title, .pub-daily-section-title, .cp-section-title, .admin-section-title.
   שינוי בטוקן = שינוי בכולם.

   aliases (הוגדרו inline ב-public.php — הועברו לכאן):
     .pub-daily-section-title — כותרת "המסר היומי מספיר" ב-public_home
     .cp-section-title        — כותרת בפורטל המחזור (/c/)
*/
.section-title,
.pub-daily-section-title,
.cp-section-title {
  font-family: var(--font-head);
  font-size: var(--fs-section-title);
  color: var(--c-section-title);
  font-weight: var(--fw-section-title);
  margin: 0 0 var(--sp-4);
}

/* גרסה ללא קו (כלל): ה-::after הישן הוסר */

/* section-title ללא קו - class מפורש (למקרים שצריך ביטול) */
.section-title--no-line::after {
  display: none;
}

/* ---------- Lesson list ---------- */
.lesson-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.lesson-item {
  background: var(--paper);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  margin-bottom: var(--sp-3);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.lesson-header {
  padding: var(--sp-4) var(--sp-5);
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  cursor: pointer;
  transition: background var(--t-fast);
}

.lesson-header:hover { background: #faf6f3; }

.lesson-num {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-warm);
  border: 2px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-head);
  font-size: var(--text-md);
  color: var(--accent);
  flex-shrink: 0;
}

.lesson-info { flex: 1; min-width: 0; }

.lesson-title {
  font-family: var(--font-head);
  font-size: var(--text-lg);
  color: var(--ink-head);
  font-weight: 400;
}

.lesson-date {
  font-size: var(--text-sm);
  color: var(--muted);
  margin-top: 2px;
}

.lesson-toggle {
  font-size: 14px;
  color: var(--muted);
  transition: transform var(--t-base);
}

.lesson-item.open .lesson-toggle { transform: rotate(-90deg); }

.lesson-body {
  display: none;
  padding: 0 var(--sp-5) var(--sp-5);
  border-top: 1px solid var(--line);
}

.lesson-item.open .lesson-body { display: block; }

/* ---- אייקון (i) + טולטיפ בכותרת השיעורים ---- */
.lessons-info-tip {
  position: relative;
  display: inline-flex;
  align-items: center;
  cursor: pointer;
  color: var(--muted);
  /* לא מסתיר את הקו ::after של .section-title */
  flex-shrink: 0;
  margin-inline-start: 8px;
  padding: 4px;
  border-radius: 50%;
  transition: color var(--t-fast), background var(--t-fast);
}

.lessons-info-tip:hover,
.lessons-info-tip:focus,
.lessons-info-tip.tip-open {
  color: var(--accent);
  background: rgba(103,72,47,.08);
  outline: none;
}

.lessons-info-tooltip {
  display: none;
  position: absolute;
  /* יוצא מתחת לאייקון, מיושר לימין */
  top: calc(100% + 6px);
  right: 0;
  width: max-content;
  max-width: 220px;
  background: var(--accent-dark);
  color: var(--on-dark);
  font-size: var(--text-xs);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: var(--lh-base);
  padding: var(--sp-2) var(--sp-3);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  z-index: 50;
  pointer-events: none;
  white-space: normal;
  /* חץ קטן מעל הטולטיפ */
}

.lessons-info-tooltip::before {
  content: '';
  position: absolute;
  top: -5px;
  right: 8px;
  width: 10px;
  height: 10px;
  background: var(--accent-dark);
  transform: rotate(45deg);
  border-radius: 1px;
}

/* hover על desktop */
@media (hover: hover) {
  .lessons-info-tip:hover .lessons-info-tooltip {
    display: block;
  }
}

/* tap toggle על mobile (מנוהל ב-JS קטן inline) */
.lessons-info-tip.tip-open .lessons-info-tooltip {
  display: block;
}

/* focus-visible לנגישות מקלדת */
.lessons-info-tip:focus-visible .lessons-info-tooltip {
  display: block;
}

/* ---- פסקה/תיאור מפגש (session-desc) ---- */
.personal-note.session-desc {
  margin-top: var(--sp-4);
  margin-bottom: var(--sp-4);
}

.personal-note.session-desc .note-label {
  /* מסתיר את ה-label "מ-ספיר" — הפסקה עצמה מדברת */
  display: none;
}

/* ---- מפגש נעול (טרם שוחרר) ---- */
.lesson-locked .lesson-header { cursor: default; }
.lesson-locked .lesson-header:hover { background: inherit; }

.lesson-lock-icon {
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--muted);
  opacity: .55;
  flex-shrink: 0;
}

.lesson-lock-label {
  font-size: var(--text-xs);
  color: var(--muted);
}

/* גוף נעול — מוסתר (ההסבר מופיע פעם אחת בראש) */
.lesson-body--locked {
  display: none;
}

/* Personal note from Sapir */
.personal-note {
  background: linear-gradient(135deg, #fdf5ee 0%, #f9efe6 100%);
  border-radius: var(--radius-sm);
  border-right: 3px solid var(--accent-gold);
  padding: var(--sp-4);
  margin-bottom: var(--sp-4);
  margin-top: var(--sp-4);
}

.personal-note .note-label {
  font-size: 11px;
  color: var(--accent-gold);
  font-weight: 700;
  margin-bottom: var(--sp-2);
}

.personal-note p {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--ink);
  line-height: var(--lh-base);
}

/* Materials */
.materials-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.material-item {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  padding: var(--sp-3) var(--sp-4);
  border-radius: var(--radius-sm);
  text-decoration: none;
  color: var(--ink);
  font-size: var(--text-sm);
  transition: background var(--t-fast);
  border: 1px solid transparent;
}

.material-item:hover {
  background: var(--bg-warm);
  border-color: var(--line);
}

.material-icon {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  color: var(--accent);
}

/* ---------- Announcements ---------- */
.announcement-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.announcement-item {
  background: var(--paper);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  padding: var(--sp-4) var(--sp-5);
  margin-bottom: var(--sp-3);
  box-shadow: var(--shadow-sm);
}

.announcement-item.global {
  border-right: 3px solid var(--mauve);
}

.announcement-item .ann-title {
  font-family: var(--font-head);
  font-size: var(--text-lg);
  color: var(--ink-head);
  font-weight: 400;
  margin: 0 0 var(--sp-2);
}

.announcement-item .ann-body {
  font-size: var(--text-sm);
  color: var(--ink);
  line-height: var(--lh-base);
  margin: 0 0 var(--sp-3);
}

.announcement-item .ann-meta {
  font-size: var(--text-xs);
  color: var(--muted);
}

/* ---------- Meetings accordion ---------- */

.meeting-accordion {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
}

/* פריט אקורדיון */
.meeting-item {
  background: var(--paper);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.meeting-item--past {
  opacity: .6;
}

/* ---- Summary (כותרת לחיצה) ---- */
.meeting-summary {
  /* מסיר עיצוב ברירת מחדל של <summary> */
  list-style: none;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--sp-3);
  padding: var(--sp-3) var(--sp-4);
  cursor: pointer;
  user-select: none;
  transition: background var(--t-fast);
  /* מבטל את ה-marker של WebKit/Firefox */
  -webkit-appearance: none;
}

.meeting-summary::-webkit-details-marker { display: none; }
.meeting-summary::marker { display: none; }

.meeting-summary:hover {
  background: #faf6f3;
}

/* תיבת תאריך — גרסה מוקטנת לסמארי */
/* תאריך עברי נקי (לא ריבוע מספר-גדול/חודש-קטן) */
.meeting-date-box {
  flex-shrink: 0;
  align-self: center;
  padding: 6px 12px;
  background: rgba(195, 174, 190, 0.18);
  border: 1px solid rgba(195, 174, 190, 0.40);
  border-radius: 999px;
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--accent);
  white-space: nowrap;
}

/* טקסט כותרת + badge */
.meeting-summary-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  min-width: 0;
}

.meeting-title {
  font-family: var(--font-head);
  font-size: var(--text-base);
  color: var(--ink-head);
  font-weight: 400;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* badge פיזי / זום */
.meeting-type-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 30px;
  width: fit-content;
  line-height: 1.4;
}
.meeting-type-badge svg { width: 11px; height: 11px; }

.meeting-type-badge svg {
  flex-shrink: 0;
}

.meeting-type-badge--physical {
  background: rgba(176, 137, 104, .12);
  color: var(--accent);
  border: 1px solid rgba(176, 137, 104, .25);
}

.meeting-type-badge--online {
  background: rgba(100, 120, 200, .10);
  color: #4a6bc8;
  border: 1px solid rgba(100, 120, 200, .22);
}

/* חץ disclosure — מסתובב כשפתוח */
.meeting-chevron {
  flex-shrink: 0;
  color: var(--mauve);
  display: flex;
  align-items: center;
  transition: transform var(--t-base), color var(--t-fast);
}

.meeting-item[open] .meeting-chevron {
  transform: rotate(180deg);
}

.meeting-item:hover .meeting-chevron {
  color: var(--accent-lavender);
}

/* ---- Body (תוכן מתקפל) ---- */
.meeting-body {
  padding: var(--sp-4) var(--sp-4) var(--sp-4) var(--sp-4);
  border-top: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}

/* שורת מידע (label + ערך) */
.meeting-body-row {
  display: flex;
  align-items: baseline;
  gap: var(--sp-2);
  font-size: var(--text-sm);
  color: var(--ink);
}

.meeting-body-label {
  font-size: var(--text-xs);
  color: var(--muted);
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
}

/* הוראות הגעה */
.meeting-body-instructions {
  font-size: var(--text-sm);
  color: var(--ink);
  background: var(--bg-warm);
  border-radius: var(--radius-sm);
  padding: var(--sp-3);
  line-height: var(--lh-base);
}

/* הערות — גופן קטן יותר, muted */
.meeting-body-row--notes {
  color: var(--muted);
  font-size: var(--text-xs);
  align-items: flex-start;
}

/* לינק מפה */
.meeting-map-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: var(--text-sm);
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
}

.meeting-map-link:hover {
  text-decoration: underline;
}

/* כפתור זום */
.meeting-zoom-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  background: #4a6bc8;
  color: #fff;
  font-size: var(--text-sm);
  font-weight: 600;
  padding: var(--sp-2) var(--sp-4);
  border-radius: var(--radius);
  text-decoration: none;
  transition: background var(--t-fast), transform var(--t-fast);
}

.meeting-zoom-btn:hover {
  background: #3a58b0;
  transform: scale(1.01);
}

/* animation — גוף נפתח בחלקות (prefers-reduced-motion נכבד) */
@media (prefers-reduced-motion: no-preference) {
  .meeting-body {
    animation: meeting-expand 0.22s cubic-bezier(0.22, 0.61, 0.36, 1);
  }

  @keyframes meeting-expand {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: none; }
  }
}

/* ---------- Blog ---------- */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--sp-5);
}

.blog-card {
  background: var(--paper);
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  transition: box-shadow var(--t-base), transform var(--t-base);
}

.blog-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.blog-card .blog-cover {
  height: 180px;
  background: var(--bg-warm);
  overflow: hidden;
}

.blog-card .blog-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.blog-card .blog-content {
  padding: var(--sp-4) var(--sp-5) var(--sp-5);
  flex: 1;
}

.blog-card .blog-date {
  font-size: var(--text-xs);
  color: var(--muted);
  margin-bottom: var(--sp-2);
}

.blog-card .blog-title {
  font-family: var(--font-head);
  font-size: var(--text-xl);
  color: var(--ink-head);
  font-weight: 400;
  line-height: var(--lh-tight);
  margin: 0;
}

/* ---------- Blog post ---------- */
.post-body {
  font-size: var(--text-md);
  line-height: 1.8;
  color: var(--ink);
  max-width: 680px;
}
.post-body p { margin: 0 0 var(--sp-5); }
.post-body h2 { font-family: var(--font-head); color: var(--ink-head); font-size: var(--h3); font-weight: 400; }

/* ---------- Students list ---------- */
.students-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: var(--sp-4);
}

.student-card {
  background: var(--paper);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  padding: var(--sp-5);
  text-align: center;
  box-shadow: var(--shadow-sm);
}

.student-card .student-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--bg-warm);
  border: 2px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-head);
  font-size: 22px;
  color: var(--accent);
  margin: 0 auto var(--sp-3);
}

.student-card .student-name {
  font-family: var(--font-head);
  font-size: var(--text-lg);
  color: var(--ink-head);
  font-weight: 400;
  margin-bottom: 3px;
}

.student-card .student-phone {
  font-size: var(--text-xs);
  color: var(--muted);
}

/* ---------- Survey ---------- */
.survey-card {
  background: var(--paper);
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  padding: var(--sp-6);
  box-shadow: var(--shadow-sm);
  margin-bottom: var(--sp-5);
}

.survey-question {
  font-family: var(--font-head);
  font-size: var(--h3);
  color: var(--ink-head);
  font-weight: 400;
  line-height: var(--lh-tight);
  margin: 0 0 var(--sp-5);
}

.survey-options {
  display: flex;
  gap: var(--sp-3);
  flex-wrap: wrap;
}

.survey-option {
  flex: 1;
  min-width: 120px;
  padding: var(--sp-4);
  border-radius: var(--radius);
  border: 2px solid var(--line);
  background: var(--cream);
  cursor: pointer;
  text-align: center;
  font-family: var(--font-head);
  font-size: var(--text-lg);
  color: var(--ink-head);
  transition: border-color var(--t-fast), background var(--t-fast);
  font-weight: 400;
}

.survey-option:hover {
  border-color: var(--accent-mid);
  background: var(--bg-warm);
}

.survey-option.voted {
  border-color: var(--accent);
  background: var(--bg-warm);
  color: var(--accent);
}

.survey-voted-label {
  font-size: var(--text-sm);
  color: var(--muted);
  margin-top: var(--sp-3);
}

/* ---------- Login page ---------- */
.login-page {
  min-height: 100vh;
  /* גרדיאנט עדין בגווני ספיר: dusty-rose → mauve → cream חמים
     מחליף את הרקע החום הכהה האחיד (accent-dark).
     נקודת ה-radial מאוורת מהמרכז-למטה — הכרטיס יושב מעל הגוון הקלות יותר. */
  background:
    radial-gradient(
      ellipse 80% 70% at 50% 110%,
      rgba(195, 174, 190, 0.55) 0%,
      rgba(212, 184, 184, 0.35) 35%,
      rgba(243, 232, 219, 0.65) 70%,
      rgba(251, 247, 247, 0.90) 100%
    ),
    linear-gradient(
      160deg,
      #e8d5d0 0%,
      #ddd0d8 40%,
      #e8d8c8 75%,
      #f3ebe3 100%
    );
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--sp-5);
}

.login-box {
  background: var(--paper);
  border-radius: var(--radius-xl);
  padding: var(--sp-6);
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow-modal);
  text-align: center;
}

.login-box .login-logo {
  width: auto;
  height: 96px;
  max-width: 86%;
  object-fit: contain;
  margin-bottom: var(--sp-3);
}

/* חץ חזרה לעמוד הבית — פינת הכרטיס (RTL: ימין = start), ורוד-מוב עדין */
.login-box { position: relative; }
.login-back {
  position: absolute;
  top: var(--sp-3);
  right: var(--sp-3);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  color: var(--mauve);
  background: transparent;
  transition: background var(--t-fast), color var(--t-fast);
  z-index: 3;
}
.login-back:hover {
  background: rgba(195,174,190,.16);
  color: var(--accent-lavender);
}
.login-back:focus-visible {
  outline: 2px solid var(--accent-lavender);
  outline-offset: 2px;
}

.login-box h1 {
  font-family: var(--font-head);
  font-size: clamp(20px, 2.6vw, 28px);
  color: var(--ink-head);
  font-weight: 400;
  margin: 0 0 var(--sp-2);
  line-height: var(--lh-tight);
}

/* כותרת מצב-הטבה — רגועה יותר ומעט כבדה יותר */
.login-box h1.login-gift-title {
  font-size: clamp(18px, 2vw, 22px);
  font-weight: 600;
  line-height: 1.35;
}

.login-box .login-eyebrow {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--accent-gold);
  margin: 0 0 var(--sp-2);
}

.login-box .login-sub {
  font-size: var(--text-sm);
  color: var(--muted);
  margin: 0 0 var(--sp-4);
}

/* פסקת ברוכה-הבאה במצב הטבה (login?gift / register?gift) */
.login-gift-intro {
  font-size: var(--text-sm);
  line-height: 1.6;
  color: var(--accent);
  text-align: center;
  margin: calc(-1 * var(--sp-2)) 0 var(--sp-4);
}
.login-gift-heart {
  display: inline-block;
  vertical-align: -2px;
  margin-inline-start: 4px;
  color: var(--mauve);
}

.login-box form {
  margin-top: var(--sp-2);
  text-align: right;
}

.login-box .form-group {
  display: block;
  margin-bottom: var(--sp-4);
}

.login-box .form-label {
  display: block;
  margin-bottom: var(--sp-2);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--ink-head);
}

.login-box .form-control {
  display: block;
  width: 100%;
  box-sizing: border-box;
  padding: var(--sp-3) var(--sp-4);
  font-family: inherit;
  font-size: var(--text-base);
  color: var(--ink);
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  text-align: right;
  transition: border-color var(--t-fast), box-shadow var(--t-fast);
}

.login-box .form-control:focus {
  outline: none;
  border-color: var(--accent);
  background: var(--paper);
  box-shadow: 0 0 0 3px rgba(103, 72, 47, 0.12);
}

.login-box .btn {
  display: flex;
  width: 100%;
  justify-content: center;
  align-items: center;
  margin-top: var(--sp-2);
  padding: var(--sp-4) var(--sp-5);
  font-family: inherit;
  font-size: var(--text-base);
  font-weight: 600;
  color: var(--on-accent);
  background: var(--accent);
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background var(--t-base);
}

.login-box .btn:hover {
  background: var(--accent-mid);
}

.login-hint {
  margin: var(--sp-3) 0 0;
  text-align: center;
  font-size: var(--text-xs);
  color: var(--muted);
}

/* ---------- אנימציית כניסה (stagger) ---------- */
.login-box .anim-item {
  opacity: 0;
  transform: translateY(16px);
}
.login-box.is-in .anim-item {
  animation: login-rise 0.55s cubic-bezier(0.22, 0.61, 0.36, 1) forwards;
}
.login-box.is-in .login-logo               { animation-delay: 0.05s; }
.login-box.is-in .login-eyebrow            { animation-delay: 0.10s; }
.login-box.is-in h1                         { animation-delay: 0.16s; }
.login-box.is-in .login-sub                 { animation-delay: 0.21s; }
.login-box.is-in form .form-group:nth-of-type(1) { animation-delay: 0.29s; }
.login-box.is-in form .form-group:nth-of-type(2) { animation-delay: 0.37s; }
.login-box.is-in form .btn                  { animation-delay: 0.45s; }
.login-box.is-in form .login-hint           { animation-delay: 0.53s; }

@keyframes login-rise {
  to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .login-box .anim-item { opacity: 1; transform: none; animation: none; }
}

/* חיווי שגיאה/הצלחה בעמודי האימות — צ'יפ מעוגל ועדין, צמוד לטקסט (לא קופסה) */
.login-error,
.login-box .flash {
  display: block;
  width: fit-content;
  max-width: 100%;
  margin: 0 auto var(--sp-3);
  padding: 12px 22px;
  border: none;
  border-radius: 18px;
  font-size: var(--text-sm);
  line-height: 1.65;
  text-align: center;
}
/* קישור בתוך הצ'יפ (למשל "שליחת קישור חדש") — אוויר קל מהטקסט */
.login-error a,
.login-box .flash a {
  display: inline-block;
  margin-top: 2px;
}
.login-error {
  background: var(--error-bg);
  color: var(--error-text);
}

/* ==========================================================================
   Public landing — עמוד ציבורי (public_home)
   Sections: header, hero, cohorts, about, articles, calculator, footer
   ========================================================================== */

/* בסיס לגוף העמוד הציבורי */
.public-body {
  background: var(--cream);
}

/* scroll-behavior כבר מוגדר ב-html (smooth) */

/* ---------- Header sticky ---------- */
.pub-header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: rgba(251, 247, 247, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--t-base), box-shadow var(--t-base);
}

.pub-header.is-scrolled {
  border-bottom-color: var(--line);
  box-shadow: 0 2px 16px rgba(61, 44, 30, .07);
}

.pub-header-inner {
  max-width: var(--wrap-max);
  margin: 0 auto;
  padding: var(--sp-3) var(--wrap-pad);
  display: flex;
  align-items: center;
  gap: var(--sp-5);
}

/* לוגו */
.pub-logo-link {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  text-decoration: none;
  flex-shrink: 0;
}

.pub-logo-img {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.pub-logo-text {
  font-family: var(--font-head);
  font-size: var(--text-lg);
  color: var(--ink-head);
  white-space: nowrap;
}

/* ניווט מרכזי */
.pub-nav {
  display: flex;
  align-items: center;
  gap: var(--sp-1);
  flex: 1;
  justify-content: center;
}

.pub-nav-link {
  color: var(--ink);
  text-decoration: none;
  font-size: var(--text-sm);
  font-weight: 500;
  padding: var(--sp-2) var(--sp-3);
  border-radius: var(--radius-sm);
  transition: background var(--t-fast), color var(--t-fast);
  white-space: nowrap;
}

.pub-nav-link:hover {
  background: var(--bg-warm);
  color: var(--accent);
}

/* CTA כפתור בהדר */
.pub-cta-btn {
  flex-shrink: 0;
  background: var(--accent);
  color: var(--on-accent);
  text-decoration: none;
  font-size: var(--text-sm);
  font-weight: 600;
  padding: var(--sp-2) var(--sp-5);
  border-radius: var(--radius-xl);
  transition: background var(--t-base), transform var(--t-fast);
  white-space: nowrap;
}

.pub-cta-btn:hover {
  background: var(--accent-mid);
  transform: scale(1.02);
}

/* כפתור המבורגר */
.pub-nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 38px;
  height: 38px;
  padding: var(--sp-2);
  background: none;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  cursor: pointer;
  margin-right: auto; /* RTL: דוחף לצד ימין */
}

.pub-nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--ink-head);
  border-radius: 2px;
  transition: opacity var(--t-fast), transform var(--t-fast);
}

/* תפריט mobile */
.pub-nav-mobile {
  display: none;
  flex-direction: column;
  gap: 0;
  padding: var(--sp-3) var(--wrap-pad) var(--sp-4);
  border-top: 1px solid var(--line);
  background: var(--cream);
}

.pub-nav-mobile.is-open {
  display: flex;
}

.pub-nav-mobile-link {
  color: var(--ink);
  text-decoration: none;
  font-size: var(--text-base);
  font-weight: 500;
  padding: var(--sp-3) 0;
  border-bottom: 1px solid var(--line);
  transition: color var(--t-fast);
}

.pub-nav-mobile-link:hover { color: var(--accent); }

.pub-nav-mobile-cta {
  margin-top: var(--sp-4);
  display: block;
  text-align: center;
  background: var(--accent);
  color: var(--on-accent);
  text-decoration: none;
  font-size: var(--text-base);
  font-weight: 600;
  padding: var(--sp-3) var(--sp-5);
  border-radius: var(--radius-xl);
  transition: background var(--t-base);
}

.pub-nav-mobile-cta:hover { background: var(--accent-mid); }

/* ---------- Scroll anchor offset ---------- */
/* כל section עם id מקבל margin-top כדי שה-sticky header לא יסתיר אותו */
section[id] {
  scroll-margin-top: 76px;
}

/* ---------- Fade-up animation ---------- */
.js-fade-up {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.55s cubic-bezier(0.22, 0.61, 0.36, 1),
              transform 0.55s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.js-fade-up.is-visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .js-fade-up { opacity: 1; transform: none; transition: none; }
}

/* באזור הסטודנטית אין IntersectionObserver לחשיפת fade-up (קיים רק בעמוד הציבורי).
   לכן רכיבים משותפים עם .js-fade-up (כמו סקשן הבלוג) היו נשארים שקופים ויוצרים
   "רווח ריק" בתחתית. מציגים אותם מיד. ה-content-wrap כבר עושה fade עדין משלו. */
body.student-area .js-fade-up { opacity: 1; transform: none; }

/* stagger כשכמה אחים */
.pub-cohorts-grid .js-fade-up:nth-child(2)  { transition-delay: 0.07s; }
.pub-cohorts-grid .js-fade-up:nth-child(3)  { transition-delay: 0.14s; }
.pub-cohorts-grid .js-fade-up:nth-child(4)  { transition-delay: 0.21s; }
.pub-articles-grid .js-fade-up:nth-child(2) { transition-delay: 0.07s; }
.pub-articles-grid .js-fade-up:nth-child(3) { transition-delay: 0.14s; }
.pub-articles-grid .js-fade-up:nth-child(4) { transition-delay: 0.21s; }
.pub-articles-grid .js-fade-up:nth-child(5) { transition-delay: 0.28s; }
.pub-articles-grid .js-fade-up:nth-child(6) { transition-delay: 0.35s; }

/* ---------- Section base ---------- */
.pub-section {
  padding: var(--sp-9) 0;
}

.pub-section--cream {
  background: var(--cream);
}

.pub-section--warm {
  background: var(--bg-warm);
}

.pub-section--dark {
  background: var(--accent-dark);
}

.pub-container {
  max-width: var(--wrap-max);
  margin: 0 auto;
  padding: 0 var(--wrap-pad);
}

.pub-section-head {
  text-align: center;
  margin-bottom: var(--sp-7);
}

.pub-section-eyebrow {
  font-size: 11px;
  font-weight: 700;
  color: var(--accent-gold);
  margin: 0 0 var(--sp-2);
}

.pub-section-eyebrow--light {
  color: var(--mauve);
}

/*
   pub-section-title — כותרת סקשן בחוויה הציבורית ובפורטל המחזור.
   v82: מאוחד עם .section-title (Level 2 בהיררכיה).
   ה-inline <style> ב-public.php שהגדיר את זה הוסר — ה-student.css הוא מקור האמת.
   הערה: ב-hero/landing הציבורי (pub-hero, pub-about) -- pub-section-title
   משמשת בהקשר גדול יותר, אבל גם שם היא כותרת-סקשן ולא כותרת-hero.
*/
.pub-section-title {
  font-family: var(--font-head);
  font-size: var(--fs-section-title);
  color: var(--c-section-title);
  font-weight: var(--fw-section-title);
  margin: 0;
}

.pub-section-title--light {
  color: var(--on-dark);
}

/*
   pub-greeting / pub-greeting-text — ברכה אישית בעמוד הציבורי (Level 1).
   v82: הועבר מ-public.php inline לכאן — student.css מקור האמת.
   מקביל ל-.welcome-compact .wc-greeting בחוויית הסטודנטיות.
*/
.pub-greeting {
  display: flex;
  align-items: baseline;
  gap: var(--sp-2);
  margin-bottom: var(--sp-5);
}
.pub-greeting-text {
  font-family: var(--font-head);
  font-size: clamp(22px, 2.8vw, 34px); /* ~20% קטן מ--fs-greeting (h2) */
  color: var(--c-greeting);
  font-weight: var(--fw-greeting);
}

/* ---------- Hero ---------- */
.pub-hero {
  position: relative;
  background: var(--accent-dark);
  padding: clamp(80px, 12vw, 140px) var(--wrap-pad) clamp(64px, 10vw, 120px);
  text-align: center;
  overflow: hidden;
}

.pub-hero-inner {
  position: relative;
  z-index: 1;
  max-width: 700px;
  margin: 0 auto;
}

.pub-hero-logo {
  width: clamp(56px, 8vw, 80px);
  filter: brightness(0) invert(1);
  opacity: .7;
  margin-bottom: var(--sp-6);
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.pub-hero-eyebrow {
  font-size: 11px;
  font-weight: 700;
  color: var(--mauve);
  margin: 0 0 var(--sp-4);
}

.pub-hero-heading {
  font-family: var(--font-head);
  font-size: clamp(40px, 6vw, 72px);
  color: var(--on-dark);
  font-weight: 400;
  line-height: var(--lh-tight);
  margin: 0 0 var(--sp-5);
}

.pub-hero-sub {
  font-size: var(--text-lg);
  color: rgba(233, 220, 207, .7);
  line-height: var(--lh-display);
  margin: 0 auto var(--sp-7);
  max-width: 560px;
}

.pub-hero-cta {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  background: var(--accent-gold);
  color: var(--accent-dark);
  text-decoration: none;
  font-family: var(--font-head);
  font-size: var(--text-lg);
  font-weight: 400;
  padding: var(--sp-4) var(--sp-7);
  border-radius: var(--radius-xl);
  transition: background var(--t-base), transform var(--t-fast);
  /* RTL: החץ בצד שמאל */
  flex-direction: row-reverse;
}

.pub-hero-cta:hover {
  background: #c49b79;
  transform: scale(1.02);
}

.pub-hero-cta svg {
  /* בעברית RTL: ה-chevron פונה ימינה */
  transform: scaleX(-1);
}

/* עיגולי רקע דקורטיביים */
.pub-hero-orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  opacity: .06;
}

.pub-hero-orb--a {
  width: 400px;
  height: 400px;
  background: var(--mauve);
  top: -100px;
  left: -100px;
}

.pub-hero-orb--b {
  width: 300px;
  height: 300px;
  background: var(--accent-gold);
  bottom: -80px;
  right: -60px;
}

/* ---------- Cohorts ---------- */
.pub-cohorts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: var(--sp-5);
}

.pub-cohort-card {
  background: var(--paper);
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  padding: var(--sp-6);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--t-base), transform var(--t-base);
}

.pub-cohort-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.pub-cohort-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  color: var(--accent-gold);
  background: rgba(176, 137, 104, .1);
  padding: 3px var(--sp-3);
  border-radius: var(--radius-sm);
  margin-bottom: var(--sp-3);
}

.pub-cohort-name {
  font-family: var(--font-head);
  font-size: var(--h3);
  color: var(--ink-head);
  font-weight: 400;
  margin: 0 0 var(--sp-1);
  line-height: var(--lh-tight);
}

.pub-cohort-course {
  font-size: var(--text-sm);
  color: var(--muted);
  margin: 0 0 var(--sp-4);
}

.pub-cohort-date {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--text-sm);
  color: var(--accent);
  font-weight: 500;
}

/* ---------- Empty state ---------- */
.pub-empty-note {
  text-align: center;
  font-size: var(--text-base);
  color: var(--muted);
  padding: var(--sp-7) 0;
  margin: 0;
}

/* ---------- About ---------- */
.pub-about-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: var(--sp-9);
  align-items: center;
}

.pub-portrait-placeholder {
  width: 100%;
  aspect-ratio: 3 / 4;
  max-width: 280px;
  border-radius: var(--radius-xl);
  background: var(--soft);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
}

.pub-portrait-logo {
  width: 72px;
  opacity: .25;
}

.pub-about-text .pub-section-eyebrow {
  text-align: right;
  display: block;
  margin-bottom: var(--sp-2);
}

.pub-about-text .pub-section-title {
  text-align: right;
  margin-bottom: var(--sp-5);
}

.pub-about-body {
  font-size: var(--text-md);
  color: var(--ink);
  line-height: var(--lh-base);
  margin: 0 0 var(--sp-4);
}

.pub-about-cta {
  display: inline-flex;
  margin-top: var(--sp-3);
  background: var(--accent);
  color: var(--on-accent);
  text-decoration: none;
  font-size: var(--text-sm);
  font-weight: 600;
  padding: var(--sp-3) var(--sp-6);
  border-radius: var(--radius-xl);
  transition: background var(--t-base);
}

.pub-about-cta:hover { background: var(--accent-mid); }

/* ---------- Articles ---------- */
.pub-articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--sp-5);
}

.pub-article-card {
  background: var(--paper);
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--t-base), transform var(--t-base);
}

.pub-article-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.pub-article-inner {
  padding: var(--sp-5) var(--sp-6) var(--sp-6);
  display: flex;
  flex-direction: column;
  height: 100%;
}

.pub-article-date {
  font-size: var(--text-xs);
  color: var(--muted);
  margin-bottom: var(--sp-2);
}

.pub-article-title {
  font-family: var(--font-head);
  font-size: var(--text-xl);
  color: var(--ink-head);
  font-weight: 400;
  line-height: var(--lh-tight);
  margin: 0 0 var(--sp-3);
}

.pub-article-excerpt {
  font-size: var(--text-sm);
  color: var(--muted);
  line-height: var(--lh-base);
  margin: 0 0 var(--sp-4);
  flex: 1;
}

/* read-more disabled (אין עמוד מאמר עדיין) */
.pub-article-read {
  display: inline-block;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--muted);
  cursor: default;
  text-decoration: none;
  opacity: .55;
  margin-top: auto;
}

/* ---------- Calculator teaser ---------- */
.pub-calc-wrap {
  position: relative;
  text-align: center;
  padding-top: var(--sp-9);
  padding-bottom: var(--sp-9);
  overflow: hidden;
}

.pub-calc-orb {
  position: absolute;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  background: var(--mauve);
  opacity: .06;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.pub-calc-sub {
  font-size: var(--text-lg);
  color: rgba(233, 220, 207, .65);
  line-height: var(--lh-display);
  margin: var(--sp-4) auto var(--sp-7);
  max-width: 480px;
  position: relative;
}

.pub-calc-soon {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  background: rgba(176, 137, 104, .18);
  color: var(--accent-gold);
  border: 1px solid rgba(176, 137, 104, .35);
  font-family: var(--font-head);
  font-size: var(--text-lg);
  font-weight: 400;
  padding: var(--sp-4) var(--sp-8);
  border-radius: var(--radius-xl);
  cursor: not-allowed;
  opacity: .7;
  position: relative;
}

/* ---------- Footer ---------- */
.pub-footer {
  background: var(--accent-dark);
  padding: var(--sp-7) 0;
}

.pub-footer-inner {
  max-width: var(--wrap-max);
  margin: 0 auto;
  padding: 0 var(--wrap-pad);
  display: flex;
  align-items: center;
  gap: var(--sp-6);
  flex-wrap: wrap;
}

.pub-footer-logo-link {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  text-decoration: none;
}

.pub-footer-logo {
  width: 32px;
  filter: brightness(0) invert(1);
  opacity: .7;
}

.pub-footer-name {
  font-family: var(--font-head);
  font-size: var(--text-lg);
  color: var(--on-dark);
  opacity: .7;
}

.pub-footer-nav {
  display: flex;
  gap: var(--sp-4);
  flex-wrap: wrap;
  flex: 1;
  justify-content: center;
}

.pub-footer-nav a {
  font-size: var(--text-sm);
  color: rgba(233, 220, 207, .5);
  text-decoration: none;
  transition: color var(--t-fast);
}

.pub-footer-nav a:hover {
  color: var(--on-dark);
}

.pub-footer-copy {
  font-size: var(--text-xs);
  color: rgba(233, 220, 207, .35);
  margin: 0;
  white-space: nowrap;
}

/* ---------- Responsive — 768px ---------- */
@media (max-width: 768px) {
  .pub-nav         { display: none; }
  .pub-cta-btn     { display: none; }
  .pub-nav-toggle  { display: flex; }

  .pub-about-grid {
    grid-template-columns: 1fr;
    gap: var(--sp-6);
  }

  .pub-portrait-placeholder {
    max-width: 220px;
    margin: 0 auto;
    aspect-ratio: 1;
    border-radius: 50%;
  }

  .pub-about-text .pub-section-eyebrow,
  .pub-about-text .pub-section-title {
    text-align: center;
  }

  .pub-about-cta { display: block; text-align: center; }

  .pub-footer-inner { flex-direction: column; gap: var(--sp-5); text-align: center; }
  .pub-footer-nav   { justify-content: center; }
}

/* ---------- Responsive — 480px ---------- */
@media (max-width: 480px) {
  .pub-cohorts-grid  { grid-template-columns: 1fr; }
  .pub-articles-grid { grid-template-columns: 1fr; }

  .pub-hero-heading { font-size: clamp(32px, 9vw, 48px); }

  .pub-header-inner { gap: var(--sp-3); }

  .pub-footer-inner { gap: var(--sp-4); }
}

/* ==========================================================================
   APP SHELL — bottom tab bar + hamburger drawer
   פעיל בכל הרוחבים. אין תפריט צד.
   ========================================================================== */

/* --- soon badge --- */
.soon-badge {
  font-size: 10px;
  font-weight: 600;
  background: rgba(176,137,104,.15);
  color: var(--accent-gold);
  border: 1px solid rgba(176,137,104,.3);
  border-radius: 30px;
  padding: 2px 7px;
}

/* ---- body lock כשה-drawer פתוח ---- */
body.drawer-open {
  overflow: hidden;
}

/* ---- Bottom tab bar — Floating Glass Capsule ---- */
/*
   מרחף מעל התוכן עם margin מכל הצדדים (לא מודבק לקצה).
   קפסולה זכוכית לרקע בהיר (cream/beige) של ספיר.
   בועית (pill-indicator) זזה בין הטאבים בחלקה.
   גרסה v23: פוליש בועית — גובה 52px, מרכוז אנכי מדויק, פדינג בריא.
*/

/* שכבה חיצונית — מטרתה: מיקום ומרחק מהקצוות */
.student-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  /* רוחב = מלא עד 520px, אבל ה-capsule בפנים מוגבלת ל-488px עם margin */
  width: 100%;
  max-width: 520px;
  /* padding: מרחק מהתחתית (safe-area + 14px), צדדים (16px לכל צד) - מיושר לנאבר הבית */
  padding: 0 16px calc(14px + env(safe-area-inset-bottom, 0px));
  box-sizing: border-box;
  background: transparent;
  z-index: 200;
  pointer-events: none; /* ה-nav עצמו יקבל pointer-events */
}

/* ה-capsule עצמה — הזכוכית + הצורה */
.bottom-nav-inner {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-around;
  /* גובה 72px: אוויר מסביב לבועית 56px */
  height: 72px;
  /* padding אופקי 9px: טאבי הקצה (והבועית ברוחבם) שומרים מרחק מהקיר המעוגל.
     offsetLeft של הטאבים יחסי ל-inner שהוא ה-offsetParent — חישובי pill תקינים. */
  padding-left: 9px;
  padding-right: 9px;
  box-sizing: border-box;
  position: relative; /* עבור pill-indicator absolute */
  pointer-events: auto;

  /* Glass */
  background: rgba(251, 247, 247, 0.82);
  backdrop-filter: blur(20px) saturate(1.5);
  -webkit-backdrop-filter: blur(20px) saturate(1.5);

  /* קפסולה מלאה */
  border-radius: 999px;

  /* border עדין — שכבת זכוכית */
  border: 1px solid rgba(255, 255, 255, 0.65);

  /* צל מרחף רך */
  box-shadow:
    0 8px 32px rgba(74, 52, 34, 0.13),
    0 2px 8px rgba(74, 52, 34, 0.07),
    inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

/* ---- Pill indicator — הבועית שזזה ---- */
/*
   מוצבת absolute מאחורי הפריטים.
   JS מחשב את ה-translateX לפי מיקום הטאב הפעיל.
   RTL: הטאב הראשון (index=0) הוא הימני ביותר.
   v23: גובה 52px = תוכן (22+4+14=40px) + 6px למעלה + 6px למטה.
   inner הוא 68px → בועית ממורכזת, נשאר 8px אוויר מכל צד לחומה הקפסולה.
*/
.pill-indicator {
  position: absolute;
  top: 50%;
  left: 0; /* JS מעדכן את left — לא translateX */
  /* רוחב + גובה נקבע ב-JS לפי גודל הטאב */
  height: 56px;
  width: 72px; /* ערך ברירת מחדל, JS מעדכן */
  background: rgba(232, 219, 220, 0.85);
  border-radius: 999px;
  border: 1px solid rgba(195, 174, 190, 0.35);
  box-shadow:
    0 2px 8px rgba(195, 174, 190, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.6);
  transform: translateY(-50%);
  /* spring overshoot — מחליק ועובר מעט את היעד וחוזר (JS מגדיר inline בלחיצה) */
  transition:
    left  0.42s cubic-bezier(0.34, 1.42, 0.64, 1),
    width 0.42s cubic-bezier(0.34, 1.42, 0.64, 1);
  pointer-events: none;
  z-index: 0;
  will-change: left;
}

/* ביטול אנימציה ל-reduced-motion */
@media (prefers-reduced-motion: reduce) {
  .pill-indicator {
    transition: none;
  }
}

/* ---- פריטי ניווט ---- */
.bottom-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  flex: 1;
  min-width: 0;
  /* padding אנכי: 14px מכל צד — מספיק לבועית 52px (14+22+4+14+14=68 = inner).
     padding אופקי: 6px לשמור מרחק מהקצוות הצדדיים של הקפסולה. */
  padding: 16px 6px;
  /* צבע לא-פעיל: חום כהה מעומעם */
  color: rgba(74, 52, 34, 0.62);
  text-decoration: none;
  /* crossfade צבע — 200ms */
  transition: color 200ms ease-out;
  min-height: 56px; /* touch target — מותאם לגובה הבועית */
  position: relative;
  z-index: 1; /* מעל הבועית */
  border-radius: 999px;
}

.bottom-nav-item.active {
  /* צבע פעיל — חום כהה מלא של ספיר */
  color: var(--accent-dark, #4a3422);
}

/* ביטול ה-::before הישן (פס גרדיאנט) — הוחלף בבועית */
.bottom-nav-item.active::before {
  display: none;
}

.bottom-nav-icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.bottom-nav-label {
  font-size: 11px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 64px;
}

/* ---- Hamburger drawer (כל הרוחבים) ---- */
.mobile-drawer {
  display: block;
  position: fixed;
  inset: 0;
  z-index: 400;
  pointer-events: none;
}

.mobile-drawer.is-open {
  pointer-events: auto;
}

/* overlay */
.mobile-drawer-overlay {
  position: absolute;
  inset: 0;
  background: rgba(40,25,20,.55);
  opacity: 0;
  transition: opacity var(--t-base);
}

.mobile-drawer.is-open .mobile-drawer-overlay {
  opacity: 1;
}

/* panel — slide in from right (RTL) */
.mobile-drawer-panel {
  position: absolute;
  top: 0;
  right: 0;
  width: min(320px, 88vw);
  height: 100%;
  /* drawer — מעט יותר כהה מהטופ-בר, אבל אחיד בתחושה */
  background: #3a2518;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  transform: translateX(100%);
  transition: transform 0.28s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.mobile-drawer.is-open .mobile-drawer-panel {
  transform: translateX(0);
}

.mobile-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--sp-5) var(--sp-5) var(--sp-4);
  border-bottom: 1px solid rgba(255,255,255,.08);
  flex-shrink: 0;
  margin-top: env(safe-area-inset-top, 0px);
}

.mobile-drawer-user {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
}

.user-avatar--sm {
  width: 38px;
  height: 38px;
  font-size: 16px;
}

.mobile-drawer-user .user-name {
  font-size: var(--text-sm);
  color: var(--on-dark);
  opacity: .9;
  font-weight: 500;
}

.mobile-drawer-user .user-role {
  font-size: 11px;
  color: rgba(233,220,207,.4);
  margin-top: 2px;
}

.mobile-drawer-close {
  width: 44px;
  height: 44px;
  background: none;
  border: none;
  cursor: pointer;
  color: rgba(233,220,207,.6);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  transition: background var(--t-fast), color var(--t-fast);
  flex-shrink: 0;
}

.mobile-drawer-close:hover,
.mobile-drawer-close:active {
  background: rgba(255,255,255,.1);
  color: var(--on-dark);
}

.mobile-drawer-cohort {
  padding: var(--sp-3) var(--sp-5);
  background: rgba(255,255,255,.05);
  border-bottom: 1px solid rgba(255,255,255,.06);
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.mobile-drawer-cohort .cohort-label {
  font-size: 10px;
  color: rgba(233,220,207,.4);
}

.mobile-drawer-cohort .cohort-name {
  font-size: var(--text-sm);
  color: var(--accent-gold);
  font-weight: 600;
}

.mobile-drawer-nav {
  flex: 1;
  padding: var(--sp-3) 0;
  display: flex;
  flex-direction: column;
}

.mobile-drawer-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--sp-4) var(--sp-5);
  color: rgba(233,220,207,.75);
  text-decoration: none;
  font-size: var(--text-base);
  font-weight: 500;
  border-bottom: 1px solid rgba(255,255,255,.04);
  transition: background var(--t-fast), color var(--t-fast);
  min-height: 52px;
}

.mobile-drawer-link.active,
.mobile-drawer-link:active {
  background: rgba(255,255,255,.08);
  color: var(--on-dark);
}

.mobile-drawer-link--soon {
  color: rgba(233,220,207,.35);
  cursor: default;
  pointer-events: none;
}

.mobile-drawer-footer {
  padding: var(--sp-5);
  border-top: 1px solid rgba(255,255,255,.08);
  padding-bottom: calc(var(--sp-5) + env(safe-area-inset-bottom, 0px));
  flex-shrink: 0;
}

.mobile-drawer-logout {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  color: rgba(233,220,207,.5);
  text-decoration: none;
  font-size: var(--text-sm);
  font-weight: 500;
  padding: var(--sp-3) 0;
  transition: color var(--t-fast);
  min-height: 44px;
}

.mobile-drawer-logout:hover,
.mobile-drawer-logout:active {
  color: var(--on-dark);
}

/* ---- Layout tweaks ---- */
.meeting-accordion { width: 100%; }

/* --- 480px tweaks --- */
@media (max-width: 480px) {
  .blog-grid { grid-template-columns: 1fr; }
  .students-grid { grid-template-columns: repeat(2, 1fr); }
  .survey-options { flex-direction: column; }
  .content-wrap {
    padding: var(--sp-3);
    /* מרווח תחתון אחיד מעל הנאבר הצף — אותו משתנה משותף, 32px נראה. */
    padding-bottom: var(--shell-content-bottom);
  }
}

/* --- prefers-reduced-motion --- */
@media (prefers-reduced-motion: reduce) {
  .mobile-drawer-panel { transition: none; }
  .mobile-drawer-overlay { transition: none; }
}

/* ==========================================================================
   Global form + button primitives — נדרש לעמוד הפרופיל ועמודים נוספים
   (ה-form/btn מוגדרים ב-login-box — כאן הגרסה הגלובלית)
   ========================================================================== */

.form-group {
  margin-bottom: var(--sp-4);
}

.form-label {
  display: block;
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--ink-head);
  margin-bottom: var(--sp-2);
}

.form-control {
  display: block;
  width: 100%;
  box-sizing: border-box;
  padding: var(--sp-3) var(--sp-4);
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--ink);
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 16px;
  text-align: right;
  transition: border-color var(--t-fast), box-shadow var(--t-fast), background var(--t-fast);
  -webkit-appearance: none;
  appearance: none;
  outline: none;
}

.form-control:focus {
  border-color: var(--accent);
  background: var(--paper);
  box-shadow: 0 0 0 3px rgba(103, 72, 47, 0.12);
}

.form-control::placeholder {
  color: var(--muted);
  opacity: 0.7;
}

textarea.form-control {
  resize: vertical;
  min-height: 100px;
  line-height: var(--lh-base);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 600;
  padding: var(--sp-3) var(--sp-5);
  border-radius: var(--radius-btn, 999px);
  border: none;
  cursor: pointer;
  transition: background var(--t-base), transform var(--t-fast), box-shadow var(--t-fast);
  text-decoration: none;
  white-space: nowrap;
}

.btn:active { transform: scale(0.97); }

.btn-primary {
  /* גוון מוב חמים של ספיר (במקום החום הקודם) */
  background: linear-gradient(165deg, #8a7286 0%, #5f4a59 100%);
  color: var(--on-accent);
}

.btn-primary:hover { background: linear-gradient(165deg, #978099 0%, #6b5566 100%); }
.btn-primary:active { transform: scale(0.97); }

.btn-sm {
  font-size: var(--text-sm);
  padding: var(--sp-2) var(--sp-4);
}

/* Flash messages */
/* טוסט קליל בתחתית המסך - נעלם בפייד אחרי כ-2 שניות */
.flash {
  position: fixed;
  bottom: calc(108px + env(safe-area-inset-bottom, 0px));
  left: 50%;
  transform: translateX(-50%);
  z-index: 9500;
  max-width: calc(100vw - 32px);
  width: max-content;
  padding: 12px 24px;
  border-radius: 16px;
  font-size: var(--text-sm);
  font-weight: 600;
  margin: 0;
  border: 1.5px solid transparent;
  box-shadow: 0 6px 24px rgba(74,52,34,.16);
  text-align: center;
  pointer-events: none;
  animation: flash-toast 2.6s ease forwards;
}
@keyframes flash-toast {
  0%   { opacity: 0; transform: translateX(-50%) translateY(14px); }
  8%   { opacity: 1; transform: translateX(-50%) translateY(0); }
  78%  { opacity: 1; transform: translateX(-50%) translateY(0); }
  100% { opacity: 0; transform: translateX(-50%) translateY(10px); }
}

.flash-success, .flash-info {
  background: #f0f7ee;
  border-color: #3a6034;   /* בורדר ירוק חזק = צבע הפונט */
  color: #3a6034;
}

.flash-error {
  background: var(--error-bg);
  border-color: var(--error-text);   /* בורדר אדום חזק = צבע הפונט */
  color: var(--error-text);
}

/* ==========================================================================
   Profile page — /student/profile
   v28: תוקן --surface/--border → tokens נכונים. צורף global form/btn למעלה.
   ========================================================================== */

/* "+ הוספת תאריך" צמוד לכותרת המסר היומי - מקור יחיד, משותף לבית הציבורי ולדאשבורד הסטודנטית.
   טקסט קטן בלי מסגרת, כמו "כל הפרקים" (עקביות) */
.pub-daily-add-date {
  margin-inline-start: auto;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--accent-lavender);
  text-decoration: none;
  white-space: nowrap;
  transition: color var(--t-fast);
}
.pub-daily-add-date svg { flex-shrink: 0; }
.pub-daily-add-date:hover { color: var(--accent); }

.profile-page {
  padding-bottom: var(--sp-4);
  /* מונע "ריקוד"/גלילה צידית - שום ילד לא בורח מעבר לרוחב */
  overflow-x: clip;
}
.profile-page * { min-width: 0; }

.profile-avatar-section {
  text-align: center;
  padding: var(--sp-6) 0 var(--sp-5);
}

/* אווטר לחיץ עם שכבת עיפרון חצי-גובה (פותח מודל החלפה) */
.profile-avatar-edit {
  position: relative;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  border: none;
  padding: 0;
  margin: 0 auto;
  display: block;
  overflow: hidden;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.profile-avatar-edit img,
.profile-avatar-edit > div {
  width: 96px !important;
  height: 96px !important;
  border: none !important;
}
.profile-avatar-pencil {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 60%;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 9px;
  color: #fff;
  /* פייד רך לשקיפות מלאה למעלה - בלי קצה חד */
  background: linear-gradient(to top, rgba(74,52,34,.66) 0%, rgba(74,52,34,.30) 45%, rgba(74,52,34,0) 100%);
  transition: background var(--t-fast);
}
.profile-avatar-edit:hover .profile-avatar-pencil {
  background: linear-gradient(to top, rgba(74,52,34,.76) 0%, rgba(74,52,34,.38) 45%, rgba(74,52,34,0) 100%);
}

/* מודל החלפת תמונת פרופיל */
.profile-avatar-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 600;
  background: rgba(74,52,34,.42);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--sp-5);
  opacity: 0;
  pointer-events: none;
  transition: opacity .22s ease;
}
.profile-avatar-modal-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}
.profile-avatar-modal {
  position: relative;
  width: 100%;
  max-width: 360px;
  background: var(--bg-warm);
  border-radius: var(--radius-lg);
  padding: var(--sp-6) var(--sp-5) var(--sp-5);
  box-shadow: 0 16px 48px rgba(74,52,34,.22);
  text-align: center;
  transform: translateY(8px) scale(.98);
  transition: transform .22s ease;
}
.profile-avatar-modal-backdrop.open .profile-avatar-modal {
  transform: translateY(0) scale(1);
}
.profile-avatar-modal-close {
  position: absolute;
  top: 10px;
  inset-inline-end: 10px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: none;
  color: var(--muted);
  cursor: pointer;
  border-radius: 50%;
  transition: background var(--t-fast), color var(--t-fast);
}
.profile-avatar-modal-close:hover { background: rgba(195,174,190,.2); color: var(--ink); }
.profile-avatar-modal-title {
  font-family: var(--font-head);
  font-size: var(--fs-card-title);
  color: var(--c-card-title);
  margin: 0 0 var(--sp-4);
}
.profile-avatar-modal-preview { margin-bottom: var(--sp-4); }
.profile-avatar-modal .profile-avatar-form { align-items: center; }

.profile-name {
  font-family: var(--font-head);
  font-size: var(--h3);
  font-weight: 400;
  color: var(--ink-head);
  margin: var(--sp-3) 0 var(--sp-1);
}

.profile-role {
  font-size: var(--text-sm);
  color: var(--muted);
  margin: 0 0 var(--sp-3);
}

/* כרטיס סקציה — תוקן: --surface/--border הוחלפו ב-tokens קיימים */
.profile-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--sp-5);
  margin-bottom: var(--sp-4);
  box-shadow: var(--shadow-sm);
}

/* profile-card-title — Level 3 (כותרת כרטיס, v82: טוקנים) */
.profile-card-title {
  font-family: var(--font-head);
  font-size: var(--fs-card-title);
  font-weight: var(--fw-card-title);
  color: var(--c-card-title);
  margin: 0 0 var(--sp-4);
}

/* העלאת תמונה */
.profile-avatar-form {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
}

.profile-file-label {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--accent);
  cursor: pointer;
  padding: var(--sp-2) var(--sp-4);
  border: 1.5px solid var(--accent);
  border-radius: var(--radius);
  width: fit-content;
  transition: background var(--t-fast), color var(--t-fast);
}

.profile-file-label:hover {
  background: var(--accent);
  color: var(--on-accent);
}

.profile-file-input {
  display: none;
}

.profile-hint {
  font-size: var(--text-xs);
  color: var(--muted);
  margin: 0;
}

/* טופס פרטים */
.profile-details-form .form-group {
  margin-bottom: var(--sp-4);
}

/* טופס בקשה */
.profile-request-form .form-group {
  margin-bottom: var(--sp-4);
}

/* ==========================================================================
   מחשבון נומרולוגי — מסלול חיים
   סקשן בעמוד הבית של הסטודנטית (student_home).
   מובייל-first, RTL, שפת המותג של ספיר.
   v27
   ========================================================================== */

.numcalc-section {
  margin-top: var(--sp-7);
  /* מונע layout-shift בין לואדר לתוצאה — הסקציה שומרת גובה מינימלי */
  min-height: 320px;
}

/* ---- כרטיס קלט ---- */
/* כרטיס המחשבון — בורדר גרדיאנט ורוד-מוב בולט, רקע נקי אחיד (שינוי 3) */
/* כרטיס המחשבון — כלי נעים: רקע שמנת-אפרסק חם, בורדר עדין, פינות גדולות (לפי פיגמה) */
.numcalc-card {
  border: 1.5px solid rgba(212,184,158,.5);
  border-radius: 32px;
  background: #f6ebe0;
  padding: var(--sp-6) var(--sp-5) var(--sp-6);
  box-shadow: 0 8px 26px rgba(74,52,34,.10);
}

/* כותרת ראשית בתוך הכרטיס (שינוי 1) */
.numcalc-card-heading {
  font-family: var(--font-head);
  font-size: clamp(20px, 2.4vw, 26px);
  font-weight: 600;
  color: var(--ink-head);
  text-align: center;
  margin: 0 0 var(--sp-5);
  line-height: 1.35;
}

.numcalc-card.exiting {
  animation: numcalc-exit 0.28s cubic-bezier(0.4,0,1,1) forwards;
}

@keyframes numcalc-exit {
  to { opacity: 0; transform: scale(0.97) translateY(-6px); }
}

.numcalc-intro {
  margin-bottom: var(--sp-4);
}

/* שינוי 2: לא אפור, גדול יותר — תת-כותרת מזמינה */
.numcalc-intro p {
  font-size: var(--text-base);
  color: var(--ink);
  margin: 0;
  line-height: 1.65;
}

/* E2: מרכוז טקסט intro */
.numcalc-intro--center p {
  text-align: center;
}

/* ---- שדה ---- */
/* שינוי 4: שדות לא רוחב מלא — ממורכזים עם max-width */
.numcalc-field {
  margin-bottom: var(--sp-4);
  max-width: 320px;
  margin-left: auto;
  margin-right: auto;
}

.numcalc-label {
  display: block;
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--ink);
  margin-bottom: var(--sp-2);
}

/* iOS Safari מזניק זום אוטומטי בפוקוס כששדה קטן מ-16px - וזה מושך את כל העמוד
   ויוצר גלילה הצידה. אכיפת מינימום 16px על כל שדה שאפשר להקליד/לבחור בו. */
input:not([type="checkbox"]):not([type="radio"]):not([type="range"]),
select,
textarea {
  font-size: max(16px, 1em);
}

.numcalc-input {
  width: 100%;
  padding: 15px 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--ink);
  direction: rtl;
  outline: none;
  box-sizing: border-box;
  transition: border-color var(--t-fast), box-shadow var(--t-fast), background var(--t-fast);
  -webkit-appearance: none;
  appearance: none;
}

.numcalc-input:focus {
  border-color: var(--accent);
  background: var(--paper);
  box-shadow: 0 0 0 3px rgba(103,72,47,0.10);
}

.numcalc-input::placeholder {
  color: var(--muted);
  opacity: 0.65;
}

/* שדה תאריך עם כפתור לוח שנה */
.numcalc-date-wrap {
  position: relative;
}

.numcalc-input--date {
  padding-left: 40px; /* מקום לכפתור הלוח (LTR = left בגלל dir:ltr בפנים) */
  cursor: pointer;
}

.numcalc-cal-btn {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--accent);
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  transition: color var(--t-fast), background var(--t-fast);
}

.numcalc-cal-btn:hover {
  color: var(--accent-mid);
  background: rgba(103,72,47,0.07);
}

.numcalc-hint {
  display: block;
  font-size: 11px;
  color: var(--muted);
  margin-top: 5px;
}

/* ---- שגיאה ---- */
/* ממורכזת כמו השדות (שינוי 4) */
.numcalc-error {
  display: none;
  background: var(--error-bg);
  border: 1px solid var(--error-border);
  border-radius: var(--radius-sm);
  padding: 9px 13px;
  font-size: var(--text-xs);
  color: var(--error-text);
  margin-bottom: var(--sp-3);
  text-align: center;
  max-width: 360px;
  margin-left: auto;
  margin-right: auto;
}

.numcalc-error.visible {
  display: block;
}

/* ---- כפתור חישוב ---- */
/* שינוי 5: pill עגול, לא רוחב מלא, ממורכז */
.numcalc-btn-primary {
  display: block;
  width: auto;
  margin: var(--sp-4) auto 0;
  padding: 14px 38px;
  background: linear-gradient(165deg, #8a6442 0%, #5e4028 100%);
  color: var(--on-accent);
  border: none;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 500;
  cursor: pointer;
  box-shadow: 0 6px 16px rgba(103,72,47,0.22);
  transition: background 0.22s ease, box-shadow 0.18s ease, transform 0.12s ease;
}

.numcalc-btn-primary:hover {
  background: linear-gradient(165deg, #94704c 0%, #65462c 100%);
  box-shadow: 0 9px 22px rgba(103,72,47,0.28);
}

.numcalc-btn-primary:active {
  transform: scale(0.97);
  box-shadow: 0 3px 9px rgba(103,72,47,0.20);
}

/* ---- Loader ---- */
.numcalc-loader {
  background: linear-gradient(180deg, var(--accent-dark) 0%, #3a2718 100%);
  border-radius: var(--radius-lg);
  height: 200px;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding-bottom: 28px;
  box-shadow: var(--shadow-md);
  animation: numcalc-card-enter 0.38s cubic-bezier(0.22,0.61,0.36,1) forwards;
}

/* E5: לואדר ורוד — v30 */
.numcalc-loader--rose {
  background: linear-gradient(180deg,
    rgba(232, 219, 220, 0.35) 0%,
    rgba(248, 238, 238, 0.55) 100%);
  border: 1px solid rgba(195, 174, 190, 0.40);
  box-shadow: var(--shadow-sm);
}

.numcalc-loader--rose .numcalc-loader-label {
  color: var(--accent);
}

.numcalc-loader--rose .numcalc-dot {
  background: var(--mauve);
}

/* v31: לואדר ספיר בתוך כרטיס המחשבון */
.numcalc-loader--sapir {
  background: rgba(251, 245, 244, 0.72);
  border: 1px solid rgba(195, 174, 190, 0.35);
  box-shadow: var(--shadow-sm);
  height: auto;
  padding: var(--sp-7) var(--sp-5) var(--sp-6);
  gap: var(--sp-4);
  justify-content: center;
}

.numcalc-loader--sapir .sapir-loader {
  width: 112px;
}

.numcalc-loader-sapir-label {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--muted);
  margin: 0;
  text-align: center;
}

.numcalc-loader[hidden] {
  display: none;
}

@keyframes numcalc-card-enter {
  from { opacity: 0; transform: scale(0.97) translateY(8px); }
  to   { opacity: 1; transform: none; }
}

.numcalc-loader-nums {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.numcalc-ln {
  position: absolute;
  font-family: var(--font-head);
  font-weight: 400;
  opacity: 0;
  bottom: -40px;
  animation: numcalc-float linear infinite;
  will-change: transform, opacity;
}

/* E5: צבעי מספרים — גוונים ורודים/מוב של המותג על הלואדר הבהיר */
.numcalc-ln.nl1 { left: 8%;  font-size: 48px; animation-duration: 2.7s; animation-delay: 0.0s; color: #C3AEBE; }
.numcalc-ln.nl2 { left: 22%; font-size: 20px; animation-duration: 2.1s; animation-delay: 0.6s; color: #80687A; }
.numcalc-ln.nl3 { left: 44%; font-size: 60px; animation-duration: 3.1s; animation-delay: 1.1s; color: #E8DBDC; }
.numcalc-ln.nl4 { left: 68%; font-size: 18px; animation-duration: 2.0s; animation-delay: 1.5s; color: #C3AEBE; }
.numcalc-ln.nl5 { left: 82%; font-size: 38px; animation-duration: 2.5s; animation-delay: 0.8s; color: #80687A; }
.numcalc-ln.nl6 { left: 3%;  font-size: 26px; animation-duration: 2.3s; animation-delay: 1.8s; color: #D4B8C8; }
.numcalc-ln.nl7 { left: 35%; font-size: 22px; animation-duration: 2.4s; animation-delay: 0.3s; color: #C3AEBE; }
.numcalc-ln.nl8 { left: 57%; font-size: 34px; animation-duration: 2.2s; animation-delay: 1.2s; color: #80687A; }
.numcalc-ln.nl9 { left: 17%; font-size: 52px; animation-duration: 2.9s; animation-delay: 0.9s; color: #E8DBDC; }

@keyframes numcalc-float {
  0%   { opacity: 0;    transform: translateY(0)      scale(0.45) rotate(-10deg); }
  8%   { opacity: 0.80; transform: translateY(-16px)  scale(1)    rotate(0deg); }
  55%  { opacity: 0.50; transform: translateY(-130px) scale(1.05) rotate(5deg); }
  85%  { opacity: 0.12; transform: translateY(-190px) scale(0.85) rotate(-4deg); }
  100% { opacity: 0;    transform: translateY(-230px) scale(0.6)  rotate(-8deg); }
}

.numcalc-loader-glow {
  position: absolute;
  width: 200px;
  height: 100px;
  background: radial-gradient(ellipse at center, rgba(195,174,190,0.30) 0%, transparent 70%);
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  animation: numcalc-glow-breath 2.2s ease-in-out infinite;
}

@keyframes numcalc-glow-breath {
  0%, 100% { opacity: 0.5; transform: translateX(-50%) scaleX(1); }
  50%       { opacity: 1;   transform: translateX(-50%) scaleX(1.3); }
}

.numcalc-loader-label {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 3px;
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--soft);
}

.numcalc-dot {
  display: inline-block;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--mauve);
  opacity: 0;
  animation: numcalc-dot-pop 1.6s ease-in-out infinite;
  margin-right: 1px;
}

.numcalc-dot:nth-child(2) { animation-delay: 0.00s; }
.numcalc-dot:nth-child(3) { animation-delay: 0.25s; }
.numcalc-dot:nth-child(4) { animation-delay: 0.50s; }

@keyframes numcalc-dot-pop {
  0%, 100% { opacity: 0;   transform: translateY(0); }
  40%       { opacity: 1;   transform: translateY(-4px); }
  70%       { opacity: 0.6; transform: translateY(0); }
}

/* ---- תוצאה ---- */
.numcalc-result {
  animation: numcalc-card-enter 0.42s cubic-bezier(0.22,0.61,0.36,1) forwards;
}

.numcalc-result[hidden] {
  display: none;
}

/* hero: ספרה גדולה + ארכטיפ — מאוחד עם משטח כרטיס המחשבון, נקי בלי בלוב */
.numcalc-result-hero {
  background: #f6ebe0;
  border: 1.5px solid rgba(212,184,158,.5);
  border-radius: 32px;
  padding: var(--sp-7) var(--sp-5);
  text-align: center;
  margin-bottom: var(--sp-5);
  position: relative;
  overflow: hidden;
}

.numcalc-result-hero::before { content: none; }

.numcalc-result-label-top {
  font-size: 10px;
  font-weight: 600;
  color: rgba(74,52,34,0.55);
  margin-bottom: var(--sp-3);
}

.numcalc-result-num {
  font-family: var(--font-head);
  /* -20% מהגודל הקודם (80->64, 110->88) + מסגרת קטנה רכה סביב הספרה */
  font-size: clamp(64px, 18vw, 88px);
  font-weight: 400;
  color: var(--ink-deep);
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.5em;
  padding: 0.12em 0.28em;
  margin-bottom: var(--sp-3);
  border: 1.5px solid rgba(195,174,190,.5);
  border-radius: 22px;
  background: rgba(232,219,220,.28);
}

.numcalc-result-num.spinning {
  color: var(--mauve);
}

.numcalc-result-num.settled {
  animation: numcalc-num-settle 0.45s cubic-bezier(0.34,1.56,0.64,1) forwards;
}

@keyframes numcalc-num-settle {
  0%   { transform: scale(0.78); opacity: 0.4; }
  60%  { transform: scale(1.07); opacity: 1; }
  100% { transform: scale(1);    opacity: 1; }
}

.numcalc-result-archetype {
  font-family: var(--font-head);
  font-size: var(--h3);
  color: var(--accent);
  font-weight: 600;
}

/* שיתוף וואטסאפ בתוצאת המחשבון - חברים ומשפחה */
.numcalc-share-wa {
  display: flex;
  width: fit-content;
  align-items: center;
  gap: 8px;
  margin: var(--sp-7, 48px) auto 0;
  padding: 10px 20px;
  border-radius: 999px;
  background: #22A65A; /* ירוק רגוע יותר - הטקסט הלבן בולט */
  color: #fff;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 600;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(30,120,70,.22);
  transition: transform var(--t-fast), box-shadow var(--t-fast), background var(--t-fast);
}
.numcalc-share-wa:hover { transform: translateY(-1px); background: #1E9850; box-shadow: 0 6px 16px rgba(30,120,70,.30); }
.numcalc-share-wa svg { flex-shrink: 0; }

/* פסקת הפרשנות — בתוך הכרטיס, בלי ציטוט ובלי תיבה */
.numcalc-meaning {
  margin: var(--sp-5) auto 0;
  max-width: 44ch;
  font-size: var(--text-base);
  color: var(--ink);
  line-height: 1.9;
  text-align: center;
}

/* שלבי חישוב — אקורדיון פנימי בתוך הכרטיס: רק קו תחתון לשורת ה-summary */
.numcalc-steps-details {
  margin-top: var(--sp-5);
  text-align: right;
}

.numcalc-steps-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--sp-3) var(--sp-1);
  cursor: pointer;
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--muted);
  list-style: none;
  user-select: none;
  border-bottom: 1px solid var(--line);
  transition: color var(--t-fast);
}

.numcalc-steps-summary::-webkit-details-marker { display: none; }

.numcalc-steps-summary:hover {
  color: var(--accent);
}

.numcalc-steps-details[open] .numcalc-steps-chevron {
  transform: rotate(180deg);
}

.numcalc-steps-chevron {
  flex-shrink: 0;
  color: var(--mauve);
  transition: transform var(--t-base), color var(--t-fast);
}

.numcalc-steps-details:hover .numcalc-steps-chevron {
  color: var(--accent-lavender);
}

.numcalc-steps-body {
  padding: var(--sp-3) var(--sp-1) 0;
}

/* טבלת שלבי חישוב */
.ncalc-steps-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: var(--sp-2);
}

/* בלי קווי הפרדה בין השורות — מספיק ברור שכל שורה היא "X מול חישוב" */
.ncalc-steps-table tr { border: none; }

.ncalc-step-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--muted);
  padding: 6px 4px 6px 14px;
  white-space: nowrap;
  width: 1%;
  text-align: right;
  vertical-align: baseline;
}

.ncalc-step-calc {
  font-size: 13px;
  font-weight: 400;
  color: var(--ink);
  padding: 6px 4px;
  font-variant-numeric: tabular-nums;
  word-break: break-word;
  vertical-align: baseline;
}

/* שורת "מסלול" הסופית — מודגשת בעדינות בצבע בלבד, בלי קו ובלי bold כבד */
.ncalc-step-final .ncalc-step-label { color: var(--accent); font-weight: 600; }
.ncalc-step-final .ncalc-step-calc { color: var(--ink-head); font-weight: 500; }

/* E6: שורת follow אינסטגרם */
.numcalc-follow-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-3);
  margin-bottom: var(--sp-5);
  padding: var(--sp-4);
  background: #faf5f1;
  border-radius: var(--radius-lg);
  border: none;
}

.numcalc-follow-text {
  font-size: var(--text-sm);
  color: var(--ink);
}

.numcalc-follow-link {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  color: var(--accent);
  font-size: var(--text-sm);
  font-weight: 600;
  text-decoration: none;
  transition: color var(--t-fast);
}

.numcalc-follow-link:hover {
  color: var(--accent-mid);
  text-decoration: underline;
}

.numcalc-ig-icon {
  flex-shrink: 0;
  color: var(--accent);
}

/* כפתור reset — כפתור pill בולט (לא קישור) */
.numcalc-btn-reset {
  display: flex;
  width: fit-content;
  align-items: center;
  justify-content: center;
  background: rgba(195,174,190,.16);
  border: 1px solid rgba(195,174,190,.4);
  border-radius: 999px;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--accent);
  padding: 12px 34px;
  margin: var(--sp-5) auto 0;
  transition: background var(--t-fast), color var(--t-fast), transform .12s ease;
}

.numcalc-btn-reset:hover {
  background: rgba(195,174,190,.30);
  color: var(--accent-dark);
}
.numcalc-btn-reset:active { transform: scale(0.97); }

/* ---- לוח שנה ---- */
.numcalc-cal-popup {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  left: 0;
  z-index: 300;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 14px 14px;
  box-shadow: var(--shadow-lg);
  display: none;
}

.numcalc-cal-popup.open {
  display: block;
  animation: numcalc-cal-in 0.14s ease;
}
/* פתיחה כלפי מעלה כשאין מקום למטה (השדה נמוך / נאבר תחתון) */
.numcalc-cal-popup.ncal-up {
  top: auto;
  bottom: calc(100% + 6px);
}

@keyframes numcalc-cal-in {
  from { opacity: 0; transform: translateY(-5px); }
  to   { opacity: 1; transform: none; }
}

.ncal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  direction: rtl;
  margin-bottom: var(--sp-3);
}

.ncal-nav {
  background: none;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  width: 30px;
  height: 30px;
  cursor: pointer;
  font-size: 16px;
  color: var(--muted);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--t-fast), color var(--t-fast);
  font-family: var(--font-body);
  flex-shrink: 0;
  line-height: 1;
}

.ncal-nav:hover {
  background: var(--soft);
  color: var(--accent);
}

.ncal-title {
  display: flex;
  align-items: center;
  gap: 2px;
}

.ncal-title-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-head);
  padding: 5px 8px;
  border-radius: var(--radius-sm);
  transition: background var(--t-fast);
}

.ncal-title-btn:hover { background: var(--soft); }

.ncal-title-label {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-head);
  padding: 5px 8px;
}

.ncal-days-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 1px;
}

.ncal-dow {
  text-align: center;
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 600;
  color: var(--accent-gold);
  padding: 2px 0 6px;
}

.ncal-day {
  text-align: center;
  padding: 6px 2px;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 400;
  color: var(--ink);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background var(--t-fast), color var(--t-fast);
  line-height: 1;
  user-select: none;
}

.ncal-day:not(.ncal-empty):hover { background: var(--soft); }
.ncal-empty { cursor: default; }
.ncal-today { color: var(--accent-gold); font-weight: 700; }
.ncal-selected { background: var(--accent) !important; color: var(--on-accent) !important; font-weight: 600; }

.ncal-months-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 5px;
  direction: rtl;
}

.ncal-month-btn {
  background: none;
  border: 1px solid transparent;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 400;
  color: var(--ink);
  padding: 9px 5px;
  border-radius: var(--radius-sm);
  transition: background var(--t-fast);
  text-align: center;
}

.ncal-month-btn:hover { background: var(--soft); }
.ncal-month-btn.active { background: var(--accent); color: var(--on-accent); font-weight: 600; }

.ncal-years-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 3px;
  max-height: 190px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--mauve) transparent;
}

.ncal-years-grid::-webkit-scrollbar { width: 4px; }
.ncal-years-grid::-webkit-scrollbar-thumb { background: var(--mauve); border-radius: 4px; }

.ncal-year-btn {
  background: none;
  border: 1px solid transparent;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 400;
  color: var(--ink);
  padding: 7px 3px;
  border-radius: var(--radius-sm);
  transition: background var(--t-fast);
  text-align: center;
}

.ncal-year-btn:hover { background: var(--soft); }
.ncal-year-btn.active { background: var(--accent); color: var(--on-accent); font-weight: 600; }

/* ---- prefers-reduced-motion ---- */
@media (prefers-reduced-motion: reduce) {
  .numcalc-ln,
  .numcalc-loader-glow,
  .numcalc-dot {
    animation: none;
    opacity: 0.5;
  }
  .numcalc-result-num.settled { animation: none; }
  .numcalc-card.exiting { animation: none; }
  .numcalc-loader,
  .numcalc-result { animation: none; }
}

/* ==========================================================================
   סקר הצבעה (v32) — גרף עמודות אנכי + מודל הצבעה
   ========================================================================== */

/* ---- מבנה הסקשן — ללא קופסה לבנה, ישירות על הרקע ---- */
/* D1: מרווח אמיתי מהמחשבון מעליו.
   padding-top: 1px — מונע margin collapse עם ה-numcalc-section.
   margin-top: 88px — מרווח ויזואלי ברור. */
#poll-section {
  padding: 1px 0 0;
  margin-top: 88px;
}

/* כותרת סקשן — מאוחד עם section-title (v82) */
/* פאנל רך לכל סקשן הסקר — גרדיאנט ורוד מעומעם נעים */
/* כרטיס הסקר — נקי ותחום, עקבי עם כרטיס המחשבון (מילוי בהיר + בורדר מוב) */
.poll-soft {
  position: relative;
  border: 2.5px solid transparent;
  border-radius: 28px;
  background:
    #f4e7ed padding-box,
    linear-gradient(135deg, #b094a8 0%, #c9a9bd 50%, #b094a8 100%) border-box;
  padding: var(--sp-6) var(--sp-5);
  margin-top: var(--sp-6);
  box-shadow: 0 10px 32px rgba(74,52,34,.14);
}

.poll-section-title {
  font-family: var(--font-head);
  font-size: var(--fs-section-title);
  font-weight: var(--fw-section-title);
  color: var(--c-section-title);
  margin: 0 0 var(--sp-2);
  line-height: var(--lh-tight);
}
/* כותרת ממורכזת בסקר */
.poll-section-title--center { text-align: center; }

/* שאלת הסקר — תת-כותרת, היררכיה נמוכה, ממורכזת */
.poll-question--sub {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 400;
  color: var(--muted);
  text-align: center;
  margin: 0 0 var(--sp-5);
  line-height: 1.5;
}

/* ---- גרף עמודות — בלי מסגרת/קווי רשת (יושב ישר על הפאנל הרך) ---- */
.poll-chart {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: var(--sp-6);
  height: 230px;
  margin-bottom: var(--sp-3);
  padding: 0 var(--sp-2);
  background: none;
  border: none;
  transition: box-shadow var(--t-base);
}

/* מצב סלקטבילי — ציור גבול מותגי עדין */
.poll-chart--selectable {
  cursor: default;
}

.poll-voted-label .poll-heart {
  vertical-align: -3px;
  margin-inline-end: 4px;
  color: #c97a8a;
}

.poll-col-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-2);
  flex: 1;
  max-width: 120px;
  outline: none;
}

/* עמודה קליקבילית */
.poll-col-wrap--clickable {
  cursor: pointer;
  border-radius: var(--radius-sm);
  transition: opacity var(--t-fast);
}

.poll-col-wrap--clickable:hover {
  opacity: 0.85;
}

.poll-col-wrap--clickable:focus-visible {
  box-shadow: 0 0 0 3px rgba(201, 122, 138, 0.45);
}

/* עמודה נבחרת */
.poll-col-wrap.is-selected .poll-col-bar {
  outline: 3px solid rgba(74, 52, 34, 0.75);
  outline-offset: 2px;
}

.poll-col-wrap.is-selected .poll-col-label {
  color: var(--ink-head);
  font-weight: 700;
}

/* A2: אחוז בתוך העמודה — מוצג absolute בתוך ה-bar */
.poll-col-pct {
  display: none;
}

/* מכל העמודה — גובה דינמי לפי ה-JS */
.poll-col-bar-wrap {
  width: 100%;
  display: flex;
  align-items: flex-end;
  height: 168px;
}

.poll-col-bar {
  width: 100%;
  height: 0%;
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  transition: height 0.65s cubic-bezier(0.22, 0.61, 0.36, 1);
  min-height: 4px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* מספר אחוז בתוך העמודה */
.poll-col-bar::after {
  content: attr(data-pct);
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-head);
  font-size: var(--text-sm);
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
  pointer-events: none;
}

/* צבעים רוויים */
.poll-col-bar--a {
  background: #C97A8A;
  color: rgba(255,255,255,0.92);
}

.poll-col-bar--b {
  background: #7A5A84;
  color: rgba(255,255,255,0.92);
}

.poll-col-bar--c {
  background: #4A7A84;
  color: rgba(255,255,255,0.92);
}

.poll-col-bar--d {
  background: #7A844A;
  color: rgba(255,255,255,0.92);
}

/* תווית מתחת לעמודה */
.poll-col-label {
  font-size: var(--text-xs);
  color: var(--muted);
  font-weight: 500;
  text-align: center;
  line-height: 1.35;
  padding-top: var(--sp-1);
  width: 100%;
  transition: color var(--t-fast), font-weight var(--t-fast);
}

/* ---- כפתור "אני רוצה להצביע" (v86) ---- */
.poll-vote-btn-wrap {
  display: flex;
  justify-content: center;
  margin-top: var(--sp-5);
}

.poll-vote-btn {
  padding: 14px 38px;
  background: linear-gradient(165deg, #8a6442 0%, #5e4028 100%);
  color: var(--on-accent);
  border: none;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 500;
  cursor: pointer;
  transition: background 0.22s ease, transform var(--t-fast), box-shadow var(--t-fast);
  box-shadow: 0 6px 16px rgba(103,72,47,0.22);
}

.poll-vote-btn:hover {
  background: linear-gradient(165deg, #94704c 0%, #65462c 100%);
  transform: translateY(-1px);
  box-shadow: 0 9px 22px rgba(103,72,47,0.28);
}

.poll-vote-btn:active {
  transform: translateY(0);
}

/* מצב "כבר הצביעה" */
.poll-voted-label {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  margin-top: var(--sp-5);
  font-family: var(--font-head);
  font-size: var(--text-base);
  font-weight: 600;
  color: var(--ink-head);
}

/* ---- מגירת הצבעה bottom-sheet (v86) ---- */
.poll-drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(74,52,34,.38);
  z-index: 600;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
}

.poll-drawer-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.poll-drawer {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) translateY(100%);
  width: 100%;
  max-width: 520px;
  background: var(--bg-warm);
  border-radius: var(--r-lg, 18px) var(--r-lg, 18px) 0 0;
  padding: var(--sp-5) var(--sp-5) calc(var(--sp-6) + env(safe-area-inset-bottom, 0px));
  z-index: 601;
  box-shadow: 0 -8px 32px rgba(74,52,34,.18);
  transition: transform .3s cubic-bezier(0.32,0.72,0,1);
}

.poll-drawer-backdrop.open .poll-drawer {
  transform: translateX(-50%) translateY(0);
}

.poll-drawer-handle {
  width: 36px;
  height: 4px;
  background: rgba(195,174,190,.5);
  border-radius: 2px;
  margin: 0 auto var(--sp-4);
}

.poll-drawer-close {
  position: absolute;
  top: -52px;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 40px;
  border: none;
  background: #fff;
  box-shadow: var(--shadow-md);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--muted);
  transition: color var(--t-fast);
}

.poll-drawer-close:hover { color: var(--accent); }

.poll-drawer-title {
  font-family: var(--font-head);
  font-size: var(--text-xl);
  color: var(--ink-head);
  font-weight: 600;
  margin: 0 0 var(--sp-4);
  line-height: var(--lh-tight);
  text-wrap: balance;
}

/* כרטיסי בחירה — radio גדולים וברורים */
.poll-drawer-options {
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
  margin-bottom: var(--sp-5);
}

.poll-option-card {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  padding: 18px var(--sp-4);
  /* רקע עדין — לא לבן מלא, שמנת שקופה-למחצה */
  background: rgba(251,247,247,.45);
  border: 1.5px solid rgba(195,174,190,.40);
  border-radius: 16px;
  cursor: pointer;
  transition: border-color var(--t-fast), background var(--t-fast);
  position: relative;
  min-height: 60px; /* תגיות גדולות */
  text-align: center;
}

.poll-option-card:hover {
  border-color: var(--accent-lavender);
  background: rgba(232,219,220,.34);
}

/* radio input מוסתר — הכרטיס כולו הוא ה"תגית" הנבחרת */
.poll-option-radio {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

/* האינדיקטור (עיגול radio) הוסר — בחירה מסומנת ע"י מילוי הכרטיס */
.poll-option-indicator { display: none; }

/* מצב נבחר — מילוי ברור של ה"תגית" */
.poll-option-card:has(.poll-option-radio:checked) {
  border-color: var(--accent-lavender);
  background: rgba(195,174,190,.42);
}

.poll-option-card:has(.poll-option-radio:checked) .poll-option-label {
  color: var(--ink-head);
  font-weight: 600;
}

.poll-option-label {
  font-family: var(--font-body);
  font-size: var(--text-lg);
  font-weight: 500;
  color: var(--ink-head);
  line-height: var(--lh-tight);
}

/* focus visible נגיש */
.poll-option-radio:focus-visible ~ .poll-option-label {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* כפתור שליחה במגירה */
.poll-drawer-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 14px var(--sp-6);
  background: linear-gradient(165deg, #8a6442 0%, #5e4028 100%);
  color: var(--on-accent);
  border: none;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 500;
  cursor: pointer;
  transition: background 0.22s ease, transform var(--t-fast), box-shadow var(--t-fast);
  box-shadow: 0 6px 16px rgba(103,72,47,0.22);
}

.poll-drawer-submit:disabled {
  background: rgba(195,174,190,.35);
  color: var(--muted);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.poll-drawer-submit:not(:disabled):hover {
  background: linear-gradient(165deg, #94704c 0%, #65462c 100%);
  transform: translateY(-1px);
  box-shadow: 0 9px 22px rgba(103,72,47,0.28);
}

.poll-drawer-submit:not(:disabled):active {
  transform: translateY(0);
}

/* prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
  .poll-col-bar { transition: none; }
  .poll-drawer { transition: none; }
  .poll-drawer-backdrop { transition: none; }
  .poll-option-card { transition: none; }
  .poll-option-indicator::after { transition: none; }
}

/* ---- backward compat stubs ---- */
.poll-modal-backdrop {
  display: none; /* מודל הוסר בv84 */
}
.poll-submit-wrap { display: none; } /* הוחלף בpoll-vote-btn-wrap בv86 */

/* ==========================================================================
   v32 additions
   ========================================================================== */

/* B: רקע שמנת לאזור הסטודנטיות — מחליף את ה-rose.
   השמנת יושב על html (לא על body) כדי ששכבת הטקסטורה (body::before,
   z-index:-1) תצויר מעליו ולא תיבלע מתחתיו. */
html:has(body.student-area) {
  background: var(--bg-warm);
}
body.student-area {
  background: transparent;
}
/* כפתור הנגישות (resolve-a11y) - מורם רק בעמודים שיש בהם נאבר תחתון.
   בעמוד בלי נאבר (מאמר, עמוד ציבורי פנימי) הוא יושב בפינה כרגיל -
   תיקון "הנגישות קפץ למעלה" (גיא, 23.7.26). */
@media (max-width: 600px) {
  body:has(.student-bottom-nav) .ra-widget,
  body:has(.pub-bottom-nav) .ra-widget { bottom: calc(104px + env(safe-area-inset-bottom, 0px)); }
}

/* עמוד פנימי (drill-down): בלי נאבר תחתון; משחררים את המקום שהיה שמור לו */
body.student-area--inner .student-bottom-nav { display: none; }
body.student-area--inner .content-wrap {
  padding-bottom: calc(var(--sp-7) + env(safe-area-inset-bottom, 0px));
}

/* רקע חלק אחד על כל המסך: עמודת האפליקציה שקופה ובלי צל,
   כך שאין שום מדרגה/הילה סביבה וגם מאחורי ההאדר רואים את אותו שמנת */
body.student-area .app-column {
  background: transparent;
  box-shadow: none;
}

/* טקסטורת רקע — זהה לעמוד הבית הציבורי (bg-main-3 + שכבה לבנה רכה).
   z-index 0 מתחת ל-shell (z-index 1). מוצגת בכל עמודי הסטודנטית. */
.home-texture {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  /* שכבות (מלמעלה למטה):
     1. פס עליון בצבע המוצר (--bg-warm) שדועך לשקוף — מאחד את אזור הסטטוס-בר
        (סוללה/וויפי) עם הרקע כך שאין תפר צבע. זה התיקון הקבוע לבאג החוזר.
     2. שכבה לבנה רכה (62%) — מבהירה לכיוון לבן, זהה לעמוד הבית הציבורי.
     3. תמונת הרקע. */
  background:
    /* כיסוי קרם רק לאזור פס-הסטטוס (תיקון התפר) - דועך גבוה, בלי באנד פייד מעל התוכן */
    linear-gradient(to bottom,
      var(--bg-warm) 0,
      var(--bg-warm) calc(env(safe-area-inset-top, 0px) + 10px),
      rgba(243, 232, 219, 0) calc(env(safe-area-inset-top, 0px) + 52px)),
    linear-gradient(rgba(255, 255, 255, 0.62), rgba(255, 255, 255, 0.62)),
    url('../img/bg-main-3.jpg') center center / cover no-repeat;
}
.home-texture[hidden] { display: none; }

/* ==========================================================================
   A2: כלל גלובלי — מינימום 14px לכל טקסט קריאה
   תוקף כל class שהיה מתחת ל-14px (text-xs = 12px, hardcoded 11px).
   חריגים מותרים: badge numbers דקורטיביות, meeting-date-box day/month,
   pub-section-eyebrow (landing ציבורי).
   ========================================================================== */

/* B2: תווית "המפגש הקרוב" / "שיעור אחרון" — אייקון מיושר לטקסט */
.home-card-label {
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--muted);
}

/* תאריך שיעור + תוויות שיעורים */
.lesson-date                        { font-size: 14px; }
.lesson-lock-label                  { font-size: 14px; }

/* מטא הכרזות */
.announcement-item .ann-meta        { font-size: 14px; }

/* תאריך בלוג */
.blog-card .blog-date               { font-size: 14px; }

/* טלפון כרטיס סטודנטית */
.student-card .student-phone        { font-size: 14px; }

/* תווית personal-note */
.personal-note .note-label          { font-size: 14px; }

/* meeting body label + notes */
.meeting-body-label                 { font-size: 14px; }
.meeting-body-row--notes            { font-size: 14px; }

/* badge פיזי/זום — קטן ועדין גם במובייל */
.meeting-type-badge                 { font-size: 10px; }

/* תווית עמודה בסקר */
.poll-col-label                     { font-size: 14px; }

/* info-card label */
.info-card .card-label              { font-size: 14px; }

/* steps-table label */
.ncalc-step-label                   { font-size: 14px; }
.ncalc-step-calc                    { font-size: 14px; }

/* D: כרטיס מפגש קרוב — כולו קליקבילי */
.home-card--meeting-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.home-card--meeting-link .home-card--meeting {
  cursor: pointer;
  transition: box-shadow var(--t-base), transform var(--t-fast);
}

.home-card--meeting-link:hover .home-card--meeting {
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

/* B1: חץ ← — ממורכז אנכית באמצע הכרטיס */
.home-card-arrow {
  font-size: var(--text-lg);
  color: var(--mauve);
  flex-shrink: 0;
  align-self: center; /* B1: היה flex-start, הוגדר ל-center */
  transition: color var(--t-fast);
}

.home-card--meeting-link:hover .home-card-arrow {
  color: var(--accent-lavender);
}

/* E: סטטוס "עלו חומרים" על כרטיס השיעור האחרון */
.lesson-materials-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 600;
  color: #3a7d44;
  background: rgba(58, 125, 68, 0.10);
  border: 1px solid rgba(58, 125, 68, 0.22);
  border-radius: 30px;
  padding: 2px 8px;
  margin-top: 4px;
  width: fit-content;
}

/* C: אייקון play בכרטיס שיעור אחרון — מיושר לטקסט התווית (home-card-label) */
.home-card--lesson .home-card-label {
  align-items: center; /* C: SVG מיושר לטקסט */
}

/* E: החץ בכרטיס השיעור — רק חץ, בלי טקסט */
.home-card--lesson .home-card-link {
  font-size: var(--text-lg);
  text-decoration: none;
  color: var(--accent);
  border: none;
  line-height: 1;
  align-self: center; /* C: גם החץ ממורכז אנכית */
}

/* F: נקודת נוטיפיקציה על אייקון שיעורים בנאבר */
.bottom-nav-item {
  position: relative; /* כבר מוגדר למעלה — שמירה */
}

.bottom-nav-badge {
  position: absolute;
  top: 10px;
  /* ב-RTL האייקון ממורכז — הנקודה יושבת מעל ימינה */
  right: calc(50% - 14px);
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #e05070;
  border: 1.5px solid var(--bg-warm, #fff);
  pointer-events: none;
  z-index: 2;
}

/* כרטיס שיעור אחרון — anchor קישור */
.home-card--lesson-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.home-card--lesson-link .home-card--lesson {
  cursor: pointer;
  transition: box-shadow var(--t-base), transform var(--t-fast);
}

.home-card--lesson-link:hover .home-card--lesson {
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

/* A1: כותרת "המסר היומי מספיר" + תאריך — גדלה מ-text-sm ל-text-base */
.daily-card-label-top--main {
  font-size: var(--text-base); /* A1: הוגדל (היה text-sm = 13-14px) */
  color: rgba(74, 52, 34, 0.80);
  font-weight: 600;
}

/* A2: תאריך — מינימום 14px (היה text-xs = 12px) */
.daily-card-label-date {
  font-size: 14px;
  color: rgba(74, 52, 34, 0.50);
  font-weight: 400;
  margin-top: 2px;
}

/* ==========================================================================
   v54: Blog / Content System
   ========================================================================== */

/* ---- Blog grid (shared: public home + student home + blog pages) ---- */
.blog-grid-section {
  margin-top: var(--sp-6);
  margin-bottom: var(--sp-6);
}

.blog-grid-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--sp-3);
  margin-bottom: var(--sp-4);
}

/* כותרת בלוג בבית — מדרגה אחת מתחת לברכה, כמו שאר כותרות הסקשן */
.blog-grid-title {
  font-family: var(--font-head);
  font-size: var(--text-xl);
  color: var(--ink-head);
  font-weight: 600;
  margin: 0;
}

.blog-see-all {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--accent-lavender);
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
  transition: color var(--t-fast);
}
.blog-see-all:hover {
  color: var(--accent-lavender);
  text-decoration: underline;
}

.blog-card-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--sp-3);
}

/* גריד עמוד בלוג מלא — עמודה אחת רחבה יותר */
.blog-card-grid--full {
  grid-template-columns: 1fr;
}
@media (min-width: 440px) {
  .blog-card-grid--full {
    grid-template-columns: repeat(2, 1fr);
  }
}

.blog-card {
  display: flex;
  flex-direction: column;
  background: var(--paper);
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  overflow: hidden;
  transition: box-shadow var(--t-fast), transform var(--t-fast);
}
.blog-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.blog-card-img {
  position: relative;
  aspect-ratio: var(--img-ratio);
  overflow: hidden;
  flex-shrink: 0;
}
.blog-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .4s ease;
}
.blog-card:hover .blog-card-img img {
  transform: scale(1.03);
}

.blog-card-cat {
  position: absolute;
  bottom: var(--sp-2);
  right: var(--sp-2);
  font-size: 10px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 30px;
  background: rgba(255,255,255,.78);
  color: var(--accent-dark);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,.55);
  white-space: nowrap;
  max-width: calc(100% - var(--sp-4));
  overflow: hidden;
  text-overflow: ellipsis;
}

.blog-card-body {
  padding: var(--sp-3) var(--sp-3) var(--sp-4);
  display: flex;
  flex-direction: column;
  gap: var(--sp-1);
  flex: 1;
}

.blog-card-title {
  font-family: var(--font-head);
  font-size: var(--text-sm);
  color: var(--ink-head);
  font-weight: 600;
  line-height: 1.35;
  margin: 0;
}

.blog-card-excerpt {
  font-size: var(--text-xs);
  color: var(--muted);
  line-height: 1.5;
  margin: 0;
}

/* ---- Blog home list — שורות אופקיות (סקשני בית) ---- */
.blog-list-rows {
  display: flex;
  flex-direction: column;
}

.blog-list-row {
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  padding: var(--sp-3) 0;
  text-decoration: none;
  transition: opacity var(--t-fast);
}
.blog-list-row:hover { opacity: .78; }
.blog-list-row--border {
  border-top: 1px solid rgba(195, 174, 190, .22);
}

.blog-list-thumb {
  position: relative;
  flex-shrink: 0;
  width: 108px;
  aspect-ratio: var(--img-ratio);
  border-radius: var(--radius);
  overflow: hidden;
  background: linear-gradient(135deg,#c3aebe 0%,#e8dbdc 100%);
}
.blog-list-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
/* תגית קטגוריה קטנה על התמונה הממוזערת */
.blog-list-cat {
  position: absolute;
  top: 6px;
  inset-inline-start: 6px;
  z-index: 2;
  display: inline-block;
  max-width: calc(100% - 12px);
  padding: 2px 8px;
  font-family: var(--font-body);
  font-size: 10.5px;
  font-weight: 600;
  line-height: 1.5;
  color: var(--ink-head);
  background: rgba(255,255,255,.88);
  -webkit-backdrop-filter: blur(3px);
          backdrop-filter: blur(3px);
  border-radius: 999px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-shadow: 0 1px 3px rgba(74,52,34,.12);
}

.blog-list-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.blog-list-title {
  font-family: var(--font-head);
  font-size: var(--text-base);
  font-weight: 600;
  color: var(--ink-head);
  line-height: 1.4;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-list-excerpt {
  font-size: var(--text-xs);
  color: var(--muted);
  line-height: 1.45;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---- Blog list: כל מאמר = כרטיס לבן נפרד, רווחים ביניהם (v91) ---- */
.blog-list-cards {
  gap: var(--sp-3);
}

/* ---- פודקאסט: גריד 2 בשורה - תמונה מלמעלה, כותרת מתחת (עד 2 שורות) ---- */
.blog-list-rows { flex-direction: row; flex-wrap: wrap; }
.blog-list-rows > * { width: 100%; }
.blog-list-rows > .pub-podcast-row {
  width: calc(50% - (var(--sp-3) / 2));
  flex-direction: column;
  align-items: stretch;
  gap: var(--sp-2);
}
.pub-podcast-row .pub-lite-yt--row { width: 100%; }
.pub-podcast-row .blog-list-body { width: 100%; }
.pub-podcast-row .blog-list-title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.4;
}
.pub-podcast-row .blog-list-arrow { display: none; }
.blog-list-cards .blog-list-row {
  background: var(--paper);
  border-radius: 24px;
  box-shadow: 0 2px 10px rgba(74,52,34,.07), 0 1px 3px rgba(74,52,34,.04);
  padding: var(--sp-3) var(--sp-4);
}
.blog-list-cards .blog-list-row:hover {
  opacity: 1;
  box-shadow: 0 4px 16px rgba(74,52,34,.11), 0 1px 3px rgba(74,52,34,.05);
}

/* ---- הצצה למאמר רביעי: כרטיס מתחת, מכוסה בגרדיאנט מצבע הרקע, כפתור מעליו ---- */
.pub-guest-peek-zone {
  position: relative;
  margin-top: var(--sp-3);
  min-height: 124px;
}
/* הכרטיס עצמו דוהה לשקיפות כלפי מטה (mask) — מתמזג עם כל רקע שמאחור.
   עמום + טשטוש קל גם בחלק העליון כדי שהכותרת לא תהיה חשופה/קריאה לגמרי (לא לחיצה). */
.pub-guest-peek-card {
  background: var(--cream);
  border-radius: 24px;
  box-shadow: 0 2px 10px rgba(74,52,34,.05);
  padding: var(--sp-3) var(--sp-4);
  pointer-events: none;
  opacity: .5;
  filter: blur(1.4px);
  -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,.72) 0%, rgba(0,0,0,.6) 24%, transparent 82%);
          mask-image: linear-gradient(to bottom, rgba(0,0,0,.72) 0%, rgba(0,0,0,.6) 24%, transparent 82%);
}
.pub-guest-peek-zone .pub-guest-more-wrap {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 2px;
  padding: 0;
  display: flex;
  justify-content: center;
  z-index: 2;
}

/* חץ הפניה בצד שמאל של כל שורה (RTL) — שברון בוורוד-מוב עדין של ספיר.
   margin-inline-start שומר מרווח בריא מהכותרת (לא צפיפות לחץ בכותרות ארוכות). */
.blog-list-arrow {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  margin-inline-start: var(--sp-2);
  color: var(--accent-lavender);
  line-height: 1;
  transition: color var(--t-fast), transform var(--t-fast);
}
.blog-list-row:hover .blog-list-arrow {
  color: var(--accent-lavender);
  transform: translateX(-2px);
}

/* ---- Search + category chips ---- */
.blog-search-wrap { position: relative; }
.blog-search-form { display: flex; }
.blog-search-input {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--ink);
  background: var(--paper);
  outline: none;
  transition: border-color var(--t-fast), box-shadow var(--t-fast);
}
.blog-search-input:focus {
  border-color: var(--accent-lavender);
  box-shadow: 0 0 0 3px rgba(195,174,190,.2);
}
.blog-search-input::placeholder { color: var(--muted); }

.blog-cat-chips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  margin-bottom: var(--sp-2);
}

.blog-cat-chip {
  display: inline-flex;
  align-items: center;
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: transparent;
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
  transition: background var(--t-fast), border-color var(--t-fast), color var(--t-fast);
  cursor: pointer;
  white-space: nowrap;
}
.blog-cat-chip:hover {
  background: rgba(195,174,190,.15);
  border-color: var(--accent-lavender);
}
.blog-cat-chip.active {
  background: rgba(232,219,220,.65);
  border-color: rgba(195,174,190,.5);
  color: var(--accent-dark);
  font-weight: 600;
}

/* ---- badge סוג כלי ברשימה השוכבת (קבצים/מדיה) ---- */
.blog-list-tool-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
  margin-top: 3px;
}

/* ---- Post page ---- */
.pub-content--post {
  padding-top: calc(56px + env(safe-area-inset-top, 0px) + var(--sp-2));
}

.post-hero {
  position: relative;
  aspect-ratio: var(--img-ratio);
  overflow: hidden;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  margin: 0 0 var(--sp-5);
}
.post-hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.post-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 40%, rgba(0,0,0,.28) 100%);
}
.post-hero-content {
  position: absolute;
  bottom: var(--sp-4);
  right: var(--sp-4);
  left: var(--sp-4);
}

.post-cat-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(255,255,255,.82);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--accent-dark);
}

.post-article {
  padding: 0 var(--sp-4) var(--sp-10);
}

.post-back-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: var(--text-sm);
  color: var(--muted);
  text-decoration: none;
  margin-bottom: var(--sp-4);
  transition: color var(--t-fast);
}
.post-back-link svg {
  color: var(--mauve);
  transition: color var(--t-fast);
}
.post-back-link:hover { color: var(--accent); }
.post-back-link:hover svg { color: var(--accent-lavender); }

.post-header { margin-bottom: var(--sp-5); }

.post-title {
  font-family: var(--font-head);
  font-size: var(--h2);
  color: var(--ink-head);
  font-weight: 600;
  line-height: 1.25;
  margin: 0 0 var(--sp-2);
}

.post-subtitle {
  font-size: var(--text-lg);
  color: var(--ink);
  margin: 0 0 var(--sp-3);
  line-height: 1.5;
}

.post-meta {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--text-sm);
  color: var(--muted);
}
.post-meta-sep { color: var(--border); }

/* תוכן עניינים */
.post-toc {
  background: rgba(232,219,220,.35);
  border: 1px solid rgba(195,174,190,.35);
  border-radius: var(--radius);
  padding: var(--sp-4) var(--sp-5);
  margin-bottom: var(--sp-5);
}
.post-toc-title {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--ink-head);
  margin-bottom: var(--sp-2);
}
.post-toc-list {
  margin: 0;
  padding-right: var(--sp-5);
  display: flex;
  flex-direction: column;
  gap: var(--sp-1);
}
.post-toc-list a {
  font-size: var(--text-sm);
  color: var(--accent);
  text-decoration: none;
}
.post-toc-list a:hover { text-decoration: underline; }

/* תוכן מאמר */
.post-content {
  line-height: 1.8;
  color: var(--ink);
  margin-bottom: var(--sp-6);
}
.post-content h2 {
  font-family: var(--font-head);
  font-size: var(--h3);
  color: var(--ink-head);
  font-weight: 600;
  margin: 1.6em 0 .5em;
  scroll-margin-top: 70px;
}
.post-content h3 {
  font-family: var(--font-head);
  font-size: var(--text-xl);
  color: var(--ink-head);
  font-weight: 600;
  margin: 1.3em 0 .4em;
}
.post-content p  { margin: 0 0 1em; }
.post-content strong { color: var(--ink-head); }
.post-content blockquote {
  border-right: 3px solid var(--accent);
  padding-right: var(--sp-4);
  color: var(--muted);
  margin: 1.2em 0;
}
.post-content a { color: var(--accent); }
.post-content ul, .post-content ol {
  padding-right: var(--sp-6);
  margin: .5em 0 1em;
}
.post-content li { margin-bottom: .35em; }

/* FAQ אקורדיון */
.post-faq { margin-top: var(--sp-6); }
.post-faq-title {
  font-family: var(--font-head);
  font-size: var(--h3);
  color: var(--ink-head);
  font-weight: 600;
  margin: 0 0 var(--sp-4);
}
.post-faq-list {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
}
.post-faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--paper);
}
.post-faq-q {
  padding: var(--sp-4) var(--sp-4);
  font-weight: 600;
  font-size: var(--text-base);
  color: var(--ink-head);
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
}
.post-faq-q::-webkit-details-marker { display: none; }
.post-faq-q::after {
  content: '+';
  font-size: 18px;
  color: var(--muted);
  flex-shrink: 0;
  transition: transform .2s ease;
}
.post-faq-item[open] .post-faq-q::after { transform: rotate(45deg); }
.post-faq-a {
  padding: 0 var(--sp-4) var(--sp-4);
  font-size: var(--text-sm);
  color: var(--ink);
  line-height: 1.65;
}

/* ---- pub-content: student area padding tweak for post ---- */
.student-area .post-article {
  padding-bottom: calc(var(--sp-10) + env(safe-area-inset-bottom, 0px));
}

/* ==========================================================================
   v55: Blog Content Redesign — חיפוש + צ'יפים + גריד + ריווח
   ========================================================================== */

/* ---- ריווח ראש עמוד תוכן ---- */
.pub-content-view {
  padding-top: var(--sp-4);
}

/* ---- Search wrap: קפסולה מותגית עם אייקון ---- */
.blog-search-wrap {
  position: relative;
}

.blog-search-icon {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  pointer-events: none;
  display: flex;
  align-items: center;
}

.blog-search-input {
  width: 100%;
  padding: 11px 44px 11px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--ink);
  background: var(--paper);
  outline: none;
  box-shadow: none;
  transition: border-color 180ms ease;
  -webkit-appearance: none;
  appearance: none;
}
.blog-search-input:focus {
  border-color: var(--mauve);
  box-shadow: none;
}
.blog-search-input::placeholder {
  color: var(--muted);
  opacity: .7;
}

/* ---- צ'יפי קטגוריה ---- */
.blog-cat-chips {
  display: flex;
  flex-wrap: nowrap;
  gap: var(--sp-2);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding-bottom: 2px;
  margin-bottom: var(--sp-3);
}
.blog-cat-chips::-webkit-scrollbar { display: none; }

.blog-cat-chip {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1.5px solid var(--border);
  background: transparent;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
  -webkit-tap-highlight-color: transparent;
}
.blog-cat-chip:hover {
  background: rgba(195,174,190,.12);
  border-color: rgba(195,174,190,.6);
}
.blog-cat-chip.active {
  background: rgba(232,219,220,.7);
  border-color: rgba(195,174,190,.55);
  color: var(--accent-dark);
  font-weight: 600;
}

/* ---- גריד כרטיסים ---- */
.blog-card-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--sp-3);
}

.blog-card-grid--full {
  grid-template-columns: repeat(2, 1fr);
}

@media (max-width: 380px) {
  .blog-card-grid,
  .blog-card-grid--full {
    grid-template-columns: 1fr;
  }
}

/* ---- כרטיס מאמר ---- */
.blog-card {
  display: flex;
  flex-direction: column;
  background: var(--paper);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: 0 1px 4px rgba(74,52,34,.07);
  text-decoration: none;
  overflow: hidden;
  transition: box-shadow 200ms ease, transform 200ms ease;
  -webkit-tap-highlight-color: transparent;
}
.blog-card:hover {
  box-shadow: 0 4px 18px rgba(74,52,34,.12);
  transform: translateY(-2px);
}

.blog-card-img {
  position: relative;
  aspect-ratio: var(--img-ratio);
  overflow: hidden;
  flex-shrink: 0;
}
.blog-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .4s ease;
}
.blog-card:hover .blog-card-img img {
  transform: scale(1.04);
}

/* תגית קטגוריה על התמונה - זכוכית עדינה */
.blog-card-cat {
  position: absolute;
  bottom: var(--sp-2);
  right: var(--sp-2);
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 30px;
  background: rgba(255,255,255,.82);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,.6);
  color: var(--accent-dark);
  white-space: nowrap;
  max-width: calc(100% - var(--sp-4));
  overflow: hidden;
  text-overflow: ellipsis;
}

.blog-card-body {
  padding: var(--sp-3) var(--sp-3) var(--sp-4);
  display: flex;
  flex-direction: column;
  gap: 5px;
  flex: 1;
}

.blog-card-title {
  font-family: var(--font-head);
  font-size: 14px;
  color: var(--ink-head);
  font-weight: 600;
  line-height: 1.35;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-card-excerpt {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.5;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---- FAQ אקורדיון מותגי (כלל גיא: קו זהב תחתון בלבד כשפתוח) ---- */
.post-faq-item {
  border: none;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  background: transparent;
  overflow: visible;
}
.post-faq-item:first-child {
  border-top: 1px solid var(--border);
}
.post-faq-item[open] {
  border-bottom-color: var(--accent-gold);
}
.post-faq-q {
  padding: var(--sp-4) 0;
  font-weight: 600;
  font-size: var(--text-base);
  color: var(--ink-head);
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
  background: none;
}
.post-faq-q::-webkit-details-marker { display: none; }
.post-faq-q::after {
  content: '';
  width: 16px;
  height: 16px;
  border-left: 1.5px solid var(--muted);
  border-bottom: 1.5px solid var(--muted);
  transform: rotate(-45deg);
  flex-shrink: 0;
  margin-top: -4px;
  transition: transform .2s ease;
}
.post-faq-item[open] .post-faq-q::after {
  transform: rotate(-225deg);
  margin-top: 4px;
}
.post-faq-a {
  padding: 0 0 var(--sp-4);
  font-size: var(--text-sm);
  color: var(--ink);
  line-height: 1.7;
}

/* ---- section spacing ---- */
.pub-section { padding: var(--sp-3) 0 0; }
.pub-section + .pub-section { margin-top: 0; }

/* ---- empty state ---- */
.pub-empty-note {
  font-size: var(--text-sm);
  color: var(--muted);
  text-align: center;
  padding: var(--sp-6) 0;
  grid-column: 1 / -1;
}

/* ==========================================================================
   Profile — פרטים אישיים: read/edit inline
   v59
   ========================================================================== */

/* שורת כותרת עם עיפרון */
.profile-card-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
  margin-bottom: var(--sp-4);
}

.profile-card-title--inline {
  /* מבטל את ה-margin/border שמוגדר ב-.profile-card-title */
  margin: 0;
  padding: 0;
  border: none;
}

/* כפתור עיפרון */
.profile-edit-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background: none;
  border: 1px solid transparent;
  cursor: pointer;
  color: var(--muted);
  transition: color var(--t-fast), background var(--t-fast), border-color var(--t-fast);
  flex-shrink: 0;
}

.profile-edit-btn:hover,
.profile-edit-btn:focus-visible {
  color: var(--accent);
  background: rgba(103, 72, 47, 0.07);
  border-color: rgba(103, 72, 47, 0.15);
  outline: none;
}

/* ---- מצב קריאה: רשימת פרטים ---- */
.profile-details-list {
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}

.profile-detail-row {
  display: flex;
  align-items: baseline;
  gap: var(--sp-3);
  min-height: 24px;
}

.profile-detail-label {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
  flex-shrink: 0;
  min-width: 86px;
}

.profile-detail-value {
  font-size: var(--text-sm);
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  flex-wrap: wrap;
  margin: 0;
}

.profile-detail-empty {
  color: var(--muted);
  font-style: italic;
  font-size: var(--text-sm);
}

/* אייקון מנעול + "קבוע" ליד המייל */
.profile-detail-locked {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 11px;
  color: var(--muted);
  opacity: 0.7;
  font-style: normal;
}

/* ---- מצב עריכה ---- */
.profile-details-edit .form-group {
  margin-bottom: var(--sp-4);
}

/* מייל ב-readonly בתוך עריכה */
.profile-email-readonly {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-3) var(--sp-4);
  background: var(--bg-warm);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: var(--text-sm);
  color: var(--muted);
}

.profile-edit-actions {
  display: flex;
  gap: var(--sp-3);
  margin-top: var(--sp-5);
  padding-top: var(--sp-4);
  border-top: 1px solid var(--line);
}

/* כפתור משני (ביטול) */
.btn-secondary {
  background: var(--bg-warm);
  color: var(--ink-head);
  border: 1px solid var(--line);
}

.btn-secondary:hover {
  background: var(--soft);
  border-color: var(--border);
}

/* ---- טוסט "נשמר בהצלחה" ---- */
.profile-toast {
  position: fixed;
  /* מעל הנאבר התחתון, ממורכז */
  bottom: calc(110px + env(safe-area-inset-bottom, 0px));
  left: 50%;
  transform: translateX(-50%);
  z-index: 300;

  display: flex;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-2) var(--sp-4);

  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: var(--shadow-md);

  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--ink-head);
  white-space: nowrap;

  /* כניסה */
  animation: profile-toast-in 0.28s cubic-bezier(0.22, 0.61, 0.36, 1) both;
}

.profile-toast[hidden] {
  display: none;
}

.profile-toast svg {
  color: #5a8c52;
  flex-shrink: 0;
}

.profile-toast--error svg {
  color: var(--error-text);
}

.profile-toast--error {
  border-color: var(--error-border);
  color: var(--error-text);
}

@keyframes profile-toast-in {
  from { opacity: 0; transform: translateX(-50%) translateY(10px); }
  to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .profile-toast { animation: none; }
}

/* ==========================================================
   Sapir Loader v4 — הלב עולה ראשון, הקשר אחריו, ואז glint
   שחי בתוך ה-SVG עם clip על צורת הלוגו - שום דבר לא נחתך.
   לולאה 3.4s. markup: .sapir-loader > svg.sl-logo (מוזרק ב-JS)
   ========================================================== */
.sapir-loader {
  position: relative;
  width: 220px;
  aspect-ratio: 519 / 311;
}
.sapir-loader svg.sl-logo {
  width: 100%;
  height: 100%;
  display: block;
  overflow: visible;
}
.sl-heart, .sl-knot, .sl-glint {
  transform-box: fill-box;
  transform-origin: center;
}
/* ביט 1: הלב (0-14%) */
.sl-heart { animation: slHeart 3.4s cubic-bezier(0.22, 1, 0.36, 1) infinite; }
@keyframes slHeart {
  0%        { opacity: 0; transform: scale(.45); }
  14%, 90%  { opacity: 1; transform: scale(1); }
  98%, 100% { opacity: 0; transform: scale(.97); }
}
/* ביט 2: הקשר (10-34%) */
.sl-knot { animation: slKnot 3.4s cubic-bezier(0.22, 1, 0.36, 1) infinite; }
@keyframes slKnot {
  0%, 10%   { opacity: 0; transform: scale(.93); }
  34%       { opacity: 1; transform: scale(1); }
  /* נשימה עדינה סביב הלב */
  52%       { opacity: 1; transform: scale(1.022); }
  68%       { opacity: 1; transform: scale(1); }
  82%       { opacity: 1; transform: scale(1.014); }
  90%       { opacity: 1; transform: scale(1); }
  98%, 100% { opacity: 0; transform: scale(1); }
}
/* ביט 3: glint - פס אור שעובר על הלוגו (55-78%) */
.sl-glint { animation: slGlintMove 3.4s ease-in-out infinite; }
@keyframes slGlintMove {
  0%, 54%   { transform: translateX(0); opacity: 0; }
  57%       { opacity: 1; }
  78%       { transform: translateX(980px); opacity: 1; }
  80%, 100% { transform: translateX(980px); opacity: 0; }
}
.sapir-loader-overlay {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(243, 232, 219, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 998;
}
@media (prefers-reduced-motion: reduce) {
  .sl-heart, .sl-knot, .sl-glint { animation: none; }
  .sl-glint { opacity: 0; }
}

/* ==========================================================================
   v67: Member dates section — "התאריכים שלי"
   משותף ל-/profile (member) ו-/student/profile (student)
   ========================================================================== */

.md-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
}

.md-item {
  background: var(--bg-warm);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--sp-3) var(--sp-3);
  transition: border-color var(--t-fast);
}

.md-item:focus-within {
  border-color: rgba(195,174,190,.6);
}

.md-item-view {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-2);
}

.md-item-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.md-item-label {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--ink-head);
  line-height: 1.3;
}

.md-item-date {
  font-size: var(--text-xs);
  color: var(--muted);
}

.md-item-actions {
  display: flex;
  gap: var(--sp-1);
  flex-shrink: 0;
}

.md-btn {
  width: 30px;
  height: 30px;
  border: none;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background var(--t-fast), color var(--t-fast);
  background: transparent;
  color: var(--muted);
}

.md-btn:hover { background: rgba(195,174,190,.2); }
.md-btn--edit:hover { color: var(--accent); }
.md-btn--delete:hover { color: #c0392b; background: rgba(192,57,43,.08); }

.md-item-edit {
  padding-top: var(--sp-2);
}

.md-edit-fields {
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
  margin-bottom: var(--sp-4);
}

.md-edit-actions {
  display: flex;
  gap: var(--sp-3);
}

.md-empty {
  list-style: none;
  padding: var(--sp-3) 0;
}

/* טופס הוספה */
.md-add-form {
  margin-top: var(--sp-3);
  padding-top: var(--sp-3);
  border-top: 1px solid var(--line);
}

/* ==========================================================================
   v68: כלים מספיר — tool cards (קארד אחיד לגריד ציבורי + סטודנטית)
   ========================================================================== */

/* ---- tool-card: כרטיס כלי ---- */
.tool-card {
  display: flex;
  flex-direction: column;
  background: var(--paper);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  overflow: hidden;
  transition: box-shadow var(--t-fast), transform var(--t-fast);
}
.tool-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.tool-card-img {
  width: 100%;
  aspect-ratio: var(--img-ratio);
  position: relative;
  overflow: hidden;
}
.tool-card-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}

/* badge סוג עדין — מסמך/סרטון/עמוד */
.tool-type-badge {
  position: absolute;
  bottom: var(--sp-2);
  right: var(--sp-2);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 30px;
  background: rgba(251,247,247,.88);
  color: var(--accent-dark);
  border: 1px solid rgba(195,174,190,.35);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.tool-card-body {
  padding: var(--sp-3) var(--sp-4);
  display: flex;
  flex-direction: column;
  gap: var(--sp-1);
}
.tool-card-title {
  font-family: var(--font-head);
  font-size: var(--text-base);
  font-weight: 600;
  color: var(--ink-head);
  margin: 0;
  line-height: var(--lh-tight);
}
.tool-card-desc {
  font-size: var(--text-xs);
  color: var(--muted);
  line-height: var(--lh-base);
  margin: 0;
}
.tool-card-date {
  font-size: 11px;
  color: var(--muted);
  opacity: .7;
}

/* ---- עמוד פנימי כלי ---- */
.tool-post-hero {
  width: 100%;
  aspect-ratio: var(--img-ratio);
  position: relative;
  overflow: hidden;
}
.tool-post-hero-img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
.tool-post-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 50%, rgba(74,52,34,.18) 100%);
  pointer-events: none;
}

.tool-post-article {
  padding: var(--sp-5) var(--sp-4) calc(var(--sp-8) + env(safe-area-inset-bottom, 0px));
}

.tool-post-type-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--accent-dark);
  margin-bottom: var(--sp-3);
}

/* כפתור הורדה */
.tool-download-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-3) var(--sp-6);
  background: var(--accent-dark);
  color: var(--on-dark);
  border-radius: 999px;
  font-size: var(--text-base);
  font-weight: 600;
  text-decoration: none;
  transition: opacity var(--t-fast);
  margin-top: var(--sp-4);
}
.tool-download-btn:hover { opacity: .85; }

/* embed וידאו */
.tool-video-embed {
  position: relative;
  aspect-ratio: 16/9;
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: var(--sp-4);
  background: #000;
}
.tool-video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* וידאו native */
.tool-video-native {
  width: 100%;
  border-radius: var(--radius);
  margin-top: var(--sp-4);
  display: block;
}

.tool-post-action { margin-top: var(--sp-2); }

.tool-coming-soon {
  font-size: var(--text-base);
  color: var(--muted);
  margin-top: var(--sp-4);
}

/* ---- תווית סקשן בין מאמרים לכלים ---- */
.content-section-label {
  font-family: var(--font-head);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--muted);
  margin: 0 0 var(--sp-3);
}


/* ==========================================================================
   v69 — energy chip
   ========================================================================== */

/* ---- chip אנרגיית היום ---- */
.energy-chip {
  display: inline-flex;
  align-items: center;
  padding: var(--sp-1) var(--sp-3);
  background: color-mix(in srgb, var(--accent-dark) 10%, var(--surface));
  border: 1px solid color-mix(in srgb, var(--accent-dark) 22%, transparent);
  border-radius: 999px;
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--accent-dark);
  margin-bottom: var(--sp-4);
}

/* ==========================================================================
   v71 — עמוד מאמר מחודש: כותב + pull-quote + image_credit + "תוכן נוסף"
   ========================================================================== */

/* ---- Hero מחודש: גדול יותר, מעוגל, תגית קטגוריה כ-pill ---- */
.post-hero {
  position: relative;
  aspect-ratio: var(--img-ratio);
  overflow: hidden;
  border-radius: var(--radius-xl);
  margin: 0 0 0;
}
.post-hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.post-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 50%, rgba(0,0,0,.22) 100%);
}
.post-hero-content {
  position: absolute;
  bottom: var(--sp-4);
  right: var(--sp-4);
  left: var(--sp-4);
}
.post-cat-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,.88);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--accent-dark);
}

/* ---- קרדיט תמונה ---- */
.post-image-credit {
  font-size: 11px;
  color: var(--muted);
  text-align: right;
  margin: var(--sp-3) 0 0;   /* יישור לקצה הימני האחיד (כמו התמונה/כותרת) + מעט אוויר מהתמונה */
  opacity: .75;
}

/* ---- article padding ---- */
.post-article {
  padding: var(--sp-4) var(--sp-4) var(--sp-10);
}
.student-area .post-article {
  padding-bottom: calc(var(--sp-10) + env(safe-area-inset-bottom, 0px));
}

/* ---- back link ---- */
.post-back-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: var(--text-sm);
  color: var(--muted);
  text-decoration: none;
  margin-bottom: var(--sp-4);
  transition: color var(--t-fast);
}
.post-back-link svg {
  color: var(--mauve);
  transition: color var(--t-fast);
}
.post-back-link:hover { color: var(--accent); }
.post-back-link:hover svg { color: var(--accent-lavender); }

/* ---- header ---- */
.post-header { margin-bottom: var(--sp-6); text-align: right; }

.post-title {
  font-family: var(--font-head);
  font-size: clamp(22px, 5vw, 32px);
  color: var(--ink-head);
  font-weight: 700;
  line-height: 1.22;
  margin: var(--sp-2) 0 var(--sp-3);   /* אוויר מעל (מהתמונה/קרדיט) ומתחת */
  text-align: right;                    /* יישור מדויק לימין (בלי balance שמרכז) */
}
.post-subtitle {
  font-size: var(--text-md);
  color: var(--ink);
  margin: 0 0 var(--sp-4);
  line-height: 1.55;
  text-align: right;
}

/* ---- שורת כותב ---- */
.post-byline {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--text-sm);
  color: var(--muted);
  margin-top: var(--sp-5);   /* אוויר בין הכותרת/תקציר לשורת הכותב */
  flex-wrap: wrap;
}
.post-author-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  display: inline-block;
}
.post-author-avatar--initial {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--mauve) 0%, var(--soft) 100%);
  color: var(--accent-dark);
  font-weight: 600;
  flex-shrink: 0;
  vertical-align: middle;
}
.post-byline-name {
  font-weight: 600;
  color: var(--ink);
  font-size: var(--text-sm);
}
.post-byline-sep {
  color: var(--border);
  font-size: 14px;
}
.post-byline-date {
  font-size: var(--text-xs);
  color: var(--muted);
}

/* ---- תוכן עניינים ---- */
.post-toc {
  background: rgba(232,219,220,.3);
  border: 1px solid rgba(195,174,190,.3);
  border-radius: var(--radius);
  padding: var(--sp-4) var(--sp-5);
  margin-bottom: var(--sp-6);
}
.post-toc-title {
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--ink-head);
  margin-bottom: var(--sp-2);
}
.post-toc-list {
  margin: 0;
  padding-right: var(--sp-5);
  display: flex;
  flex-direction: column;
  gap: 6px;
  counter-reset: toc-ctr;
}
.post-toc-list a {
  font-size: var(--text-sm);
  color: var(--accent);
  text-decoration: none;
  line-height: 1.5;
}
.post-toc-list a:hover { text-decoration: underline; }

/* ---- תוכן מאמר ---- */
.post-content {
  line-height: 1.85;
  color: var(--ink);
  margin-bottom: var(--sp-7);
  font-size: var(--text-base);
}
.post-content h2 {
  font-family: var(--font-head);
  font-size: clamp(18px, 3.5vw, 22px);
  color: var(--ink-head);
  font-weight: 700;
  margin: 2em 0 .6em;
  scroll-margin-top: 70px;
}
.post-content h3 {
  font-family: var(--font-head);
  font-size: var(--text-lg);
  color: var(--ink-head);
  font-weight: 600;
  margin: 1.6em 0 .5em;
}
.post-content p { margin: 0 0 1.1em; }
.post-content strong { color: var(--ink-head); font-weight: 700; }
.post-content a { color: var(--accent); text-decoration: underline; }
.post-content ul, .post-content ol {
  padding-right: var(--sp-6);
  margin: .6em 0 1.1em;
}
.post-content li { margin-bottom: .4em; }

/* ---- pull-quote (blockquote) ---- */
/* ציטוט נקי: בלי בורדר/קופסה. גרש פתיחה גדול בצבע חזק, טקסט מודגש ממורכז. */
.post-content blockquote {
  position: relative;
  border: none;
  background: rgba(195,174,190,.10);
  border-inline-start: 3px solid var(--accent-lavender, #80687a);
  border-radius: 12px;
  margin: var(--sp-6) 0;
  padding: var(--sp-4) var(--sp-5) var(--sp-4) var(--sp-4);
  text-align: start;
}
.post-content blockquote::before {
  content: '\201D';
  position: absolute;
  top: 2px;
  inset-inline-start: var(--sp-3);
  font-family: Georgia, serif;
  font-size: 34px;
  line-height: 1;
  color: var(--accent-lavender, #80687a);
  opacity: .5;
  font-weight: 700;
  pointer-events: none;
}
.post-content blockquote p {
  font-family: var(--font-head);
  font-size: clamp(18px, 4.6vw, 22px);
  line-height: 1.6;
  color: var(--ink-head);
  font-weight: 600;
  margin: 0;
  font-style: normal;
}

/* ---- תמונת אמצע במאמר (figure) ---- */
.post-body-figure {
  margin: var(--sp-7) 0;
  padding: 0;
  border: none;
  display: block;
}
.post-body-figure img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius-lg, 16px);
  object-fit: cover;
}
.post-body-figure figcaption {
  margin-top: var(--sp-2);
  font-size: 11px;
  color: var(--muted);
  text-align: right;   /* קרדיט תמונה תמיד לימין */
  opacity: .78;
  font-weight: 500;
  line-height: 1.45;
}

/* ---- FAQ ---- */
.post-faq { margin-top: var(--sp-6); }
.post-faq-title {
  font-family: var(--font-head);
  font-size: var(--h3);
  color: var(--ink-head);
  font-weight: 700;
  margin: 0 0 var(--sp-4);
}
.post-faq-list {
  display: flex;
  flex-direction: column;
}
.post-faq-item {
  border-bottom: 1px solid var(--border);
  background: transparent;
  overflow: hidden;
}
.post-faq-item:first-child { border-top: 1px solid var(--border); }
.post-faq-item[open] {
  border-bottom-color: var(--accent-gold);
}
.post-faq-q {
  padding: var(--sp-4) 0;
  font-weight: 600;
  font-size: var(--text-base);
  color: var(--ink-head);
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
}
.post-faq-q::-webkit-details-marker { display: none; }
.post-faq-q::after {
  content: '+';
  font-size: 20px;
  color: var(--accent-gold);
  flex-shrink: 0;
  transition: transform .2s ease;
  font-weight: 300;
  line-height: 1;
}
.post-faq-item[open] .post-faq-q::after { transform: rotate(45deg); }
.post-faq-a {
  padding: 0 0 var(--sp-4);
  font-size: var(--text-sm);
  color: var(--ink);
  line-height: 1.7;
}

/* ---- "תוכן נוסף" ---- */
.post-related {
  margin-top: var(--sp-8);
  padding-top: var(--sp-6);
  border-top: 1px solid var(--border);
}
.post-related-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--sp-4);
}
.post-related-title {
  font-family: var(--font-head);
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--ink-head);
  margin: 0;
}
.post-related-see-all {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: var(--text-sm);
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
  white-space: nowrap;
}
.post-related-see-all:hover { text-decoration: underline; }
.post-related-list { display: flex; flex-direction: column; }
.post-related-row {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  padding: var(--sp-3) 0;
  text-decoration: none;
  color: inherit;
  transition: opacity var(--t-fast);
}
.post-related-row:hover { opacity: .8; }
.post-related-row--border { border-top: 1px solid rgba(195,174,190,.3); }
.post-related-thumb {
  width: 68px;
  height: 50px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  flex-shrink: 0;
  background: linear-gradient(135deg, var(--mauve) 0%, var(--soft) 100%);
}
.post-related-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.post-related-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.post-related-post-title {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--ink-head);
  margin: 0;
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.post-related-date {
  font-size: var(--text-xs);
  color: var(--muted);
}

/* ---- pub-content--post top padding ---- */
.pub-content--post {
  padding-top: calc(56px + env(safe-area-inset-top, 0px) + var(--sp-2));
}
.pub-content--post .post-hero {
  border-radius: var(--radius-xl);
  margin: 0 0 0;
}
/* reset כפילות מ-v55 שיורשנות ל-post-hero מ-CSS קודם */
/* v71 מגדיר post-hero מחדש באופן מלא למעלה - מובטח שהגדרות חדשות ינצחו */

/* =======================================================================
   v72 — הכשרות, קפסולת מפגש, עמוד פנימי
   ======================================================================= */

/* ---- קפסולת מפגש קרוב ---- */
.meeting-capsule {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  padding: var(--sp-3) var(--sp-5);
  background: #fff;
  border: 1px solid rgba(195,174,190,.5);
  border-radius: 999px;
  text-decoration: none;
  color: var(--ink);
  flex-wrap: wrap;
  margin-bottom: var(--sp-5);
  box-shadow: 0 2px 10px rgba(128,104,122,.10);
  transition: box-shadow var(--t-fast), transform var(--t-fast), border-color var(--t-fast);
  cursor: pointer;
}
.meeting-capsule:hover {
  box-shadow: 0 5px 16px rgba(128,104,122,.16);
  border-color: rgba(195,174,190,.7);
}
.meeting-capsule--changed {
  background: rgba(220,120,60,.12);
  border-color: rgba(220,120,60,.4);
  color: var(--ink);
}
.meeting-capsule--changed:hover {
  background: rgba(220,120,60,.18);
}
.meeting-capsule--empty {
  cursor: default;
  opacity: .72;
}
.meeting-capsule-label {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
}
.meeting-capsule-icon {
  color: var(--accent-lavender);
  flex-shrink: 0;
}
.meeting-capsule-date {
  font-size: var(--text-base);
  font-weight: 600;
  color: var(--ink-head);
  white-space: nowrap;
}
.meeting-capsule-time {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--ink);
  white-space: nowrap;
  direction: ltr;
}
.meeting-capsule-loc {
  font-size: var(--text-sm);
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 140px;
}
.meeting-capsule-changed-badge {
  font-size: 11px;
  font-weight: 600;
  color: #b85c1a;
  background: rgba(220,120,60,.15);
  border-radius: 30px;
  padding: 2px 9px;
  white-space: nowrap;
  flex-shrink: 0;
}
.meeting-capsule-arrow {
  margin-right: auto;
  display: flex;
  align-items: center;
  color: var(--mauve);
  flex-shrink: 0;
  transition: color var(--t-fast);
}

.meeting-capsule:hover .meeting-capsule-arrow {
  color: var(--accent-lavender);
}
.meeting-capsule-empty-text {
  font-size: var(--text-base);
  color: var(--muted);
}

/* ---- עמוד פנימי (שיעורים/מפגשים/קבוצה) ---- */
.inner-page-header {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  margin-bottom: var(--sp-5);
  padding-top: var(--sp-1);
}
.inner-page-back {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(195,174,190,.18);
  border: 1px solid rgba(195,174,190,.3);
  color: var(--mauve);
  text-decoration: none;
  flex-shrink: 0;
  transition: background var(--t-fast), color var(--t-fast);
}
.inner-page-back:hover {
  background: rgba(195,174,190,.32);
  color: var(--accent-lavender);
}
.inner-page-back:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.inner-page-title {
  font-family: var(--font-head);
  /* כותרות שורת חץ-החזור קטנות ב-20% בכל העמודים הפנימיים (בקשת גיא) */
  font-size: calc(var(--h3) * 0.8);
  color: var(--ink-head);
  font-weight: 600;
  margin: 0;
  flex: 1;
  text-align: center;
  /* כדי להתמרכז ביחס לכרטיס, לא רק לחץ */
  margin-left: 36px;
}

/* sub-header שיעורים (מחליף h2 section-title) */
.lessons-subheader {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  margin-bottom: var(--sp-4);
}
.lessons-course-name {
  font-family: var(--font-head);
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--ink-head);
}

/* label קבוצה */
.group-cohort-label {
  font-size: var(--text-sm);
  color: var(--muted);
  font-weight: 600;
  margin: 0 0 var(--sp-4);
}

/* ---- כרטיסי הכשרות ---- */
.training-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: var(--sp-4) var(--sp-5);
  margin-bottom: var(--sp-4);
}
.training-card--enrolled {
  border-color: rgba(195,174,190,.5);
}
.training-card--locked {
  background: rgba(195,174,190,.08);
  border-style: dashed;
  border-color: rgba(195,174,190,.4);
  cursor: pointer;
  padding: var(--sp-4) var(--sp-5);
}
.training-card--locked:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.training-card-header {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  margin-bottom: var(--sp-4);
}
.training-card-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(195,174,190,.2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  flex-shrink: 0;
}
.training-card-meta {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.training-card-type {
  font-family: var(--font-head);
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--ink-head);
}
.training-card-cohort {
  font-size: var(--text-xs);
  color: var(--muted);
  font-weight: 500;
}
/* כרטיס הכשרה מאוחד - לחיץ, חיווי התקדמות, חץ כניסה בצד שמאל */
.training-card--link {
  display: flex;
  align-items: center;
  gap: var(--sp-5);
  text-decoration: none;
  color: inherit;
  transition: box-shadow var(--t-fast), transform var(--t-fast), border-color var(--t-fast);
}
.training-card--link:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--accent-lavender);
}
.training-card-body { flex: 1; min-width: 0; }
.training-card--link .training-card-header { margin-bottom: var(--sp-3); }
.training-card-enter-arrow {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  color: var(--accent-lavender);
  transition: transform var(--t-fast);
}
.training-card--link:hover .training-card-enter-arrow { transform: translateX(-3px); }
/* תגית קטנה (מחזור / קורס מתקדם) - בורדר עדין בלבד, בלי רקע */
.training-card-tag {
  align-self: flex-start;
  font-size: 11px;
  font-weight: 600;
  color: var(--accent-lavender);
  border: 1px solid rgba(128,104,122,.4);
  border-radius: 999px;
  padding: 2px 10px;
  margin-bottom: 4px;
}
.training-card-icon--locked { background: rgba(195,174,190,.14); color: var(--muted); }
.training-progress { margin-bottom: var(--sp-3); }
.training-progress-row {
  display: flex; align-items: baseline; justify-content: space-between;
  margin-bottom: 6px;
}
.training-progress-count { font-size: var(--text-sm); color: var(--ink-head); font-weight: 600; }
.training-progress-pct { font-size: var(--text-xs); color: var(--accent-lavender); font-weight: 600; }
.training-progress-bar {
  height: 6px; border-radius: 999px; background: rgba(195,174,190,.22); overflow: hidden;
}
.training-progress-bar > span {
  display: block; height: 100%; border-radius: 999px; background: var(--accent-lavender);
}
/* "השיעור הבא" — תווית קטנה מעל, שם המפגש מתחת (מסודר, מיושר לימין) */
.training-next {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.training-next-label {
  font-size: var(--text-xs);
  color: var(--muted);
  font-weight: 500;
}
.training-next-title { font-size: var(--text-base); color: var(--ink-head); font-weight: 600; line-height: 1.4; }
.training-next-title--done { color: var(--accent-lavender); }
/* הערת "הקוד" הנעול */
.training-locked-note {
  font-size: var(--text-xs);
  color: var(--muted);
  margin: var(--sp-2) 0 0;
  line-height: 1.5;
}
.training-entries {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
}
.training-entry {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  padding: var(--sp-3) var(--sp-3);
  background: var(--bg-warm);
  border: 1px solid rgba(195,174,190,.25);
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--ink);
  transition: background var(--t-fast), border-color var(--t-fast);
}
.training-entry:hover {
  background: rgba(195,174,190,.18);
  border-color: rgba(195,174,190,.4);
}
.training-entry:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--radius);
}
.training-entry-icon {
  color: var(--accent);
  flex-shrink: 0;
}
.training-entry-label {
  font-weight: 500;
  font-size: var(--text-base);
  flex: 1;
}
.training-entry-arrow {
  color: var(--mauve);
  font-size: var(--text-sm);
  transition: color var(--t-fast);
}

.training-entry:hover .training-entry-arrow {
  color: var(--accent-lavender);
}
/* קוד נעול */
.training-locked-row {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
}
.training-locked-icon {
  color: var(--muted);
  flex-shrink: 0;
}
.training-locked-name {
  font-family: var(--font-head);
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--muted);
}
.training-locked-sub {
  font-size: var(--text-xs);
  color: var(--muted);
  margin-right: auto;
}
.training-locked-tooltip {
  margin: var(--sp-2) 0 0;
  font-size: var(--text-sm);
  color: var(--muted);
  background: rgba(195,174,190,.12);
  border-radius: var(--radius);
  padding: var(--sp-2) var(--sp-3);
}

/* קורסים דיגיטליים ב-student (pub-online-card--soon: לא קליקבילי) */
.pub-online-card--soon {
  pointer-events: none;
  cursor: default;
  opacity: .82;
}

/* section-title--sm */
.section-title--sm {
  font-size: var(--text-base);
  font-weight: 600;
}

/* ==========================================================================
   v73 — content type segmented control + search expand
   ========================================================================== */

/* ---- Segmented control ראשי (מאמרים / קבצים / מדיה) ---- */
/*
   v83: טאבי underline — שורת טאבים עם קו דק קוסט-טו-קוסט.
   הטאב הפעיל: קו תחתון עבה בצבע מותג. אין קפסולה, אין גלאס, אין בועית.
   לא מתחרה ב-bottom-nav (שנשאר glass-capsule ייחודי).
*/
.ctype-segmented {
  display: flex;
  align-items: stretch;
  width: 100%;
  position: relative;
  padding: 0;
  box-sizing: border-box;
  margin-bottom: var(--sp-4);
  /* קו דק קצה-לקצה מתחת לטאבים (בלי sticky - גלילה רגילה) */
  border-bottom: 1px solid rgba(195,174,190,.35);
  background: none;
  border-radius: 0;
  border-top: none;
  border-right: none;
  border-left: none;
  box-shadow: none;
}

/* אינדיקטור underline זוחל (מחליף את ה-pill) */
.ctype-pill {
  position: absolute;
  bottom: -1px; /* יושב על הקו */
  left: 0;
  height: 2.5px;
  border-radius: 2px 2px 0 0;
  background: var(--accent);
  transition:
    left .32s cubic-bezier(0.4, 0, 0.2, 1),
    width .32s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
  z-index: 1;
  will-change: left, width;
  /* אין border, אין box-shadow, אין inset */
  border: none;
  box-shadow: none;
}
@media (prefers-reduced-motion: reduce) {
  .ctype-pill { transition: none; }
}

/* כפתור בודד */
.ctype-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  height: 44px;
  border: none;
  background: none;
  border-radius: 0;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  color: rgba(74,52,34,.45);
  cursor: pointer;
  position: relative;
  z-index: 1;
  transition: color .2s ease;
  white-space: nowrap;
  padding: 0 8px;
  -webkit-tap-highlight-color: transparent;
}
.ctype-btn.active {
  color: var(--accent-dark);
  font-weight: 700;
}
.ctype-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
  border-radius: 4px;
}

/* ---- שורת כותרת + אייקון חיפוש ---- */
.content-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--sp-3);
  min-height: 36px;
}
.content-header-title {
  font-family: var(--font-head);
  font-size: var(--h3);
  font-weight: 600;
  color: var(--ink-head);
  margin: 0;
}
.content-search-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: none;
  background: rgba(195,174,190,.15);
  border-radius: 50%;
  color: var(--muted);
  cursor: pointer;
  flex-shrink: 0;
  transition: background .22s ease, color .22s ease;
  -webkit-tap-highlight-color: transparent;
}
.content-search-btn:hover { background: rgba(195,174,190,.28); color: var(--accent-dark); }
.content-search-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.content-search-btn[aria-expanded="true"] { background: rgba(195,174,190,.30); color: var(--accent-dark); }

/* מורפינג עדין בין זכוכית מגדלת ל-X — שתי אייקונות ערומות במרכז */
.csb-ico {
  position: absolute;
  top: 50%; left: 50%;
  transform-origin: center;
  transition:
    opacity .24s ease,
    transform .36s cubic-bezier(0.34, 1.4, 0.5, 1); /* טיפה ספרינגי, לא מוגזם */
}
.csb-ico-search { opacity: 1; transform: translate(-50%,-50%) rotate(0deg)   scale(1);  }
.csb-ico-close  { opacity: 0; transform: translate(-50%,-50%) rotate(-75deg) scale(.55); }
.content-search-btn[aria-expanded="true"] .csb-ico-search { opacity: 0; transform: translate(-50%,-50%) rotate(75deg) scale(.55); }
.content-search-btn[aria-expanded="true"] .csb-ico-close  { opacity: 1; transform: translate(-50%,-50%) rotate(0deg)  scale(1);  }
@media (prefers-reduced-motion: reduce) {
  .csb-ico { transition: opacity .15s ease; }
  .csb-ico-search, .csb-ico-close,
  .content-search-btn[aria-expanded="true"] .csb-ico-search,
  .content-search-btn[aria-expanded="true"] .csb-ico-close { transform: translate(-50%,-50%); }
}

/* ---- שדה חיפוש collapse ---- */
.content-search-collapse {
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  transition:
    max-height .28s cubic-bezier(0.4,0,0.2,1),
    opacity .22s ease,
    margin-bottom .28s cubic-bezier(0.4,0,0.2,1);
  margin-bottom: 0;
}
.content-search-collapse.open {
  max-height: 56px;
  opacity: 1;
  margin-bottom: var(--sp-3);
}
@media (prefers-reduced-motion: reduce) {
  .content-search-collapse { transition: none; }
  .content-search-collapse.open { max-height: 56px; opacity: 1; margin-bottom: var(--sp-3); }
}

/* ==========================================================================
   v75: Daily section — carousel dots + feedback tag
   ========================================================================== */

/* נקודות חיווי — גם בקרוסלת הסקרים (pub-polls) וגם בקרוסלת המסרים (pub-daily) */
.pub-daily-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: var(--sp-3);
}
.pub-daily-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(195,174,190,.38);
  transition: background .2s, width .2s;
  flex-shrink: 0;
}
.pub-daily-dot.active {
  background: var(--accent);
  width: 14px;
  border-radius: 3px;
}

/* ==========================================================================
   v87: נעילת תוכן לאורחת — כפתור "הצג עוד" + מגירת הזמנה
   ========================================================================== */

/* עטיפת כפתור מנעול מתחת לרשימת המאמרים */
.pub-guest-more-wrap {
  display: flex;
  justify-content: center;
  padding: var(--sp-4) 0 var(--sp-2);
}

/* כפתור מנעול */
.pub-guest-more-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 10px var(--sp-5);
  background: rgba(255,255,255,.82);
  -webkit-backdrop-filter: blur(6px);
          backdrop-filter: blur(6px);
  border: 1px solid rgba(195,174,190,.32);
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--accent);
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(74,52,34,.07);
  transition: background var(--t-fast), box-shadow var(--t-fast), transform var(--t-fast);
}
.pub-guest-more-btn:hover {
  background: rgba(232,219,220,.45);
  box-shadow: 0 4px 18px rgba(195,174,190,.32);
  transform: translateY(-1px);
}
.pub-guest-more-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
@media (prefers-reduced-motion: reduce) {
  .pub-guest-more-btn { transition: none; }
}

/* לב במגירה */
.guest-content-heart {
  display: flex;
  justify-content: center;
  margin-bottom: var(--sp-3);
}
.guest-content-heart svg {
  animation: guestHeartPulse 2.4s ease-in-out infinite;
}
@keyframes guestHeartPulse {
  0%, 100% { transform: scale(1); }
  50%       { transform: scale(1.08); }
}
@media (prefers-reduced-motion: reduce) {
  .guest-content-heart svg { animation: none; }
}

/* ==========================================================================
   v118 — טריגר מתנה בטופבר (אזור סטודנטית) + מגירת מתנה
   ========================================================================== */

/* ---- טריגר "מתנה בשבילך" בטופבר הסטודנטית ---- */
.app-topbar-gift {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px 6px 10px;
  background: rgba(232,219,220,.52);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(195,174,190,.45);
  border-radius: 999px;
  box-shadow: 0 2px 8px rgba(74,52,34,.09);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--accent-lavender);
  cursor: pointer;
  transition: background var(--t-fast), box-shadow var(--t-fast);
  /* RTL: נמצא בין הלוגו לאווטאר */
  margin-inline-start: auto;
  margin-inline-end: var(--sp-2);
  white-space: nowrap;
}
.app-topbar-gift:hover,
.app-topbar-gift:focus-visible {
  background: rgba(232,219,220,.75);
  box-shadow: 0 2px 12px rgba(195,174,190,.35);
  outline: none;
}
.app-topbar-gift:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.app-topbar-gift-icon {
  flex-shrink: 0;
  display: block;
}

/* ---- מגירת מתנה — backdrop + drawer (אזור סטודנטית) ---- */
.gift-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(74,52,34,.38);
  z-index: 500;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
}
.gift-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}
.gift-drawer {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) translateY(100%);
  width: 100%;
  max-width: 520px;
  background: var(--bg-warm, #fdf6f0);
  border-radius: var(--radius-lg, 20px) var(--radius-lg, 20px) 0 0;
  padding: var(--sp-6) var(--sp-5) calc(var(--sp-8) + env(safe-area-inset-bottom, 0px));
  z-index: 501;
  box-shadow: 0 -8px 32px rgba(74,52,34,.18);
  transition: transform .3s cubic-bezier(0.32,0.72,0,1);
}
.gift-backdrop.open .gift-drawer {
  transform: translateX(-50%) translateY(0);
}
.gift-drawer-handle {
  width: 36px;
  height: 4px;
  background: rgba(195,174,190,.5);
  border-radius: 2px;
  margin: 0 auto var(--sp-4);
}
.gift-drawer-close {
  position: absolute;
  top: -52px;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 40px;
  border: none;
  background: #fff;
  box-shadow: var(--shadow-md);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--muted);
  transition: color var(--t-fast);
}
.gift-drawer-close:hover { color: var(--accent); }
.gift-drawer-close:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.gift-drawer-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  margin: var(--sp-2) auto var(--sp-4);
  border-radius: 50%;
  background: rgba(195,174,190,.18);
  color: var(--accent);
}
.gift-drawer-title {
  font-family: var(--font-head);
  font-size: var(--text-xl);
  color: var(--ink-head);
  font-weight: 600;
  margin: 0 0 var(--sp-3);
  text-align: center;
}
.gift-drawer-body {
  font-size: var(--text-base);
  color: var(--ink);
  line-height: var(--lh-base);
  margin: 0 0 var(--sp-5);
  text-align: center;
}

/* ריבוע קופון עם בורדר מקווקו */
.gift-coupon-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 0 var(--sp-3);
}
.gift-coupon {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: var(--sp-3) 46px;
  border: 2px dashed var(--mauve);
  border-radius: var(--radius-md, 12px);
  background: rgba(232,219,220,.20);
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--ink-head);
  cursor: pointer;
  transition: background var(--t-fast);
  direction: ltr;
}
.gift-coupon:hover { background: rgba(232,219,220,.40); }
.gift-coupon:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.gift-coupon-copy-icon {
  position: absolute;
  inset-inline-end: 16px;
  top: 50%;
  transform: translateY(-50%);
  flex-shrink: 0;
  color: var(--mauve);
}
.gift-copied-msg {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: var(--radius-md, 12px);
  background: linear-gradient(165deg, #8a7286, #5f4a59);
  color: #fff;
  font-size: var(--text-base);
  font-weight: 700;
  white-space: nowrap;
  opacity: 0;
  transform: scale(.92);
  pointer-events: none;
  transition: opacity .18s ease, transform .32s cubic-bezier(0.34, 1.45, 0.5, 1);
}
.gift-copied-msg svg { stroke: #fff; }
.gift-copied-msg.visible { opacity: 1; transform: scale(1); }
@media (prefers-reduced-motion: reduce) {
  .gift-copied-msg { transition: opacity .15s ease; transform: none; }
  .gift-copied-msg.visible { transform: none; }
}

/* הנחיה קטנה מתחת לקופון */
.gift-hint {
  font-size: var(--text-sm);
  color: var(--muted);
  text-align: center;
  margin: 0 0 var(--sp-5);
}

/* כפתור CTA ראשי */
.gift-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  padding: var(--sp-3) var(--sp-6);
  background: var(--accent-dark);
  color: #fff;
  border-radius: 999px;
  font-size: var(--text-base);
  font-weight: 600;
  text-decoration: none;
  transition: opacity var(--t-fast);
  margin-bottom: var(--sp-3);
}
.gift-cta:hover { opacity: .85; }

/* הערת תחתית — מושתקת */
.gift-disclaimer {
  font-size: 11px;
  color: var(--muted);
  text-align: center;
  opacity: .75;
  margin: 0;
}

/* ============================================================
   קישורים משפטיים קטנים (תקנון / נגישות / פרטיות)
   ============================================================ */
.legal-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  font-size: 11px;
}
.legal-links a {
  color: var(--muted);
  text-decoration: none;
  opacity: .8;
  transition: color var(--t-fast), opacity var(--t-fast);
}
.legal-links a:hover {
  color: var(--accent);
  opacity: 1;
}
.legal-links-sep {
  color: var(--muted);
  opacity: .4;
}

/* ============================================================
   עמוד משפטי פנימי (/legal/:slug)
   ============================================================ */
.legal-page {
  min-height: 100vh;
  background: var(--bg-warm);
  display: flex;
  justify-content: center;
  padding: var(--sp-6) var(--sp-4) var(--sp-8);
}
.legal-card {
  position: relative;
  width: 100%;
  max-width: 680px;
  background: var(--paper);
  border-radius: var(--radius-xl);
  box-shadow: 0 10px 40px rgba(74,52,34,.10);
  padding: var(--sp-7) var(--sp-6) var(--sp-6);
}
.legal-back {
  position: absolute;
  top: var(--sp-5);
  inset-inline-start: var(--sp-5);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  color: var(--mauve);
  background: rgba(195,174,190,.14);
  transition: background var(--t-fast);
}
.legal-back:hover { background: rgba(195,174,190,.28); }
.legal-logo {
  display: block;
  height: 64px;
  width: auto;
  margin: 0 auto var(--sp-4);
}
.legal-title {
  font-family: var(--font-head);
  font-size: var(--text-2xl);
  font-weight: 600;
  color: var(--ink-head);
  text-align: center;
  margin: 0 0 var(--sp-5);
}
.legal-content {
  font-size: var(--text-base);
  line-height: 1.85;
  color: var(--ink);
}
.legal-content p { margin: 0 0 var(--sp-4); }
.legal-h2 {
  font-family: var(--font-head);
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--ink-head);
  margin: var(--sp-5) 0 var(--sp-2);
}
.legal-updated {
  font-size: var(--text-xs);
  color: var(--muted);
  text-align: center;
  margin: var(--sp-6) 0 0;
}
.legal-foot-links {
  margin-top: var(--sp-5);
  padding-top: var(--sp-4);
  border-top: 1px solid rgba(195,174,190,.25);
}

/* ==========================================================================
   מילון מושגים — explorer (חיפוש + תגיות + מגירה + empty) + סקשן בית
   ========================================================================== */
.gloss-card { /* כשמוצג בעמוד /glossary בתוך legal-card */
  text-align: right;
}
.gloss-title {
  font-family: var(--font-head);
  font-size: var(--text-2xl);
  font-weight: 600;
  color: var(--ink-head);
  text-align: center;
  margin: 0 0 var(--sp-5);
}
.gloss-search-wrap {
  position: relative;
  margin: 0 0 var(--sp-5);
}
.gloss-search-icon {
  position: absolute;
  inset-inline-start: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--mauve);
  pointer-events: none;
  display: flex;
}
.gloss-search-input {
  width: 100%;
  box-sizing: border-box;
  padding: 13px 44px 13px 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--ink);
  outline: none;
  transition: border-color var(--t-fast), box-shadow var(--t-fast);
}
.gloss-search-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(103,72,47,.10);
}
.gloss-tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-3);
  justify-content: center;
}
.gloss-tag {
  border: 1px solid rgba(195,174,190,.5);
  background: rgba(195,174,190,.12);
  color: var(--ink-head);
  border-radius: 999px;
  padding: 7px 15px;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  line-height: 1.3;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  transition: background var(--t-fast), border-color var(--t-fast), transform .12s ease;
}
.gloss-tag:hover {
  background: rgba(195,174,190,.26);
  border-color: var(--mauve);
}
.gloss-tag:active { transform: scale(0.96); }
.gloss-tag[hidden] { display: none; }

.gloss-empty {
  text-align: center;
  padding: var(--sp-7) var(--sp-4);
  color: var(--muted);
}
.gloss-empty-emoji { font-size: 40px; display: block; margin-bottom: var(--sp-3); }
.gloss-empty p { font-size: var(--text-base); margin: 0; }

/* מגירת פירוט מושג — bottom sheet (כמו מגירת המתנה) */
.gloss-drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(74,52,34,.32);
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
  z-index: 600;
}
.gloss-drawer-backdrop.open { opacity: 1; pointer-events: auto; }
.gloss-drawer {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) translateY(100%);
  width: 100%;
  max-width: 520px;
  background: var(--bg-warm);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  padding: var(--sp-6) var(--sp-5) calc(var(--sp-8) + env(safe-area-inset-bottom, 0px));
  box-shadow: 0 -8px 32px rgba(74,52,34,.18);
  transition: transform .3s cubic-bezier(0.32,0.72,0,1);
}
.gloss-drawer-backdrop.open .gloss-drawer { transform: translateX(-50%) translateY(0); }
.gloss-drawer-handle {
  width: 36px; height: 4px;
  background: rgba(195,174,190,.5);
  border-radius: 2px;
  margin: 0 auto var(--sp-4);
}
.gloss-drawer-close {
  position: absolute;
  top: -52px;
  left: 50%;
  transform: translateX(-50%);
  width: 40px; height: 40px;
  border: none;
  background: #fff;
  box-shadow: var(--shadow-md);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--muted);
  transition: color var(--t-fast);
}
.gloss-drawer-close:hover { color: var(--accent); }
.gloss-drawer-term {
  font-family: var(--font-head);
  font-size: var(--text-xl);
  font-weight: 600;
  color: var(--ink-head);
  text-align: center;
  margin: 0 0 var(--sp-3);
}
.gloss-drawer-def {
  font-size: var(--text-base);
  line-height: 1.85;
  color: var(--ink);
  text-align: center;
  margin: 0;
}

/* סקשן מילון מושגים בעמוד הבית */
.gloss-home-tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
}

/* תגית "יום משוב" כפתור לחיץ (פותח מגירת הסבר) */
.feedback-tag-btn { cursor: pointer; font-family: inherit; }
.feedback-tag-btn:hover { filter: brightness(.97); }
.stu-feedback-tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 10px;
  border-radius: 999px;
  background: rgba(195,174,190,.22);
  border: 1px solid rgba(195,174,190,.45);
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
  white-space: nowrap;
}

/* אנימציית רקע עדינה גם בכרטיס המסר היומי של הסטודנטית (זהה לעמוד הבית הציבורי) */
.daily-card > * { position: relative; z-index: 1; }
.daily-card::before {
  content: '';
  position: absolute;
  top: -35%;
  inset-inline-start: -15%;
  width: 65%;
  height: 95%;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%,
    rgba(243,232,219,.75) 0%, rgba(232,219,220,.40) 42%, transparent 70%);
  filter: blur(30px);
  pointer-events: none;
  z-index: 0;
  animation: pubDailyDrift 18s ease-in-out infinite;
  will-change: transform;
}
@keyframes pubDailyDrift {
  0%   { transform: translate(0, 0) scale(1); }
  33%  { transform: translate(45%, 16%) scale(1.14); }
  66%  { transform: translate(14%, 32%) scale(.94); }
  100% { transform: translate(0, 0) scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  .daily-card::before { animation: none; }
}

/* ===== הכשרות דיגיטליות — כרטיסים לבנים כמו הבלוג (ציבורי + סטודנטית) ===== */
.digi-course-list { display: flex; flex-direction: column; gap: var(--sp-3); }
.digi-course-row {
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  padding: var(--sp-3) var(--sp-4);
  background: var(--paper);
  border-radius: 24px;
  box-shadow: 0 2px 10px rgba(74,52,34,.07), 0 1px 3px rgba(74,52,34,.04);
  text-decoration: none;
  color: inherit;
  transition: box-shadow var(--t-fast), transform var(--t-fast);
}
.digi-course-row:hover {
  box-shadow: 0 4px 16px rgba(74,52,34,.11), 0 1px 3px rgba(74,52,34,.05);
  transform: translateY(-1px);
}
.digi-course-row--border { border-top: none; } /* כרטיסים נפרדים — בלי קו, יש רווח */
.digi-course-thumb {
  flex-shrink: 0;
  width: 104px;
  height: 72px;
  border-radius: var(--radius);
  overflow: hidden;
  background: linear-gradient(135deg,#c3aebe 0%,#e8dbdc 100%);
}
.digi-course-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.digi-course-rowbody { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.digi-course-rowtitle {
  font-family: var(--font-head);
  font-size: var(--text-base);
  font-weight: 600;
  color: var(--ink-head);
  margin: 0;
  line-height: 1.35;
}
.digi-course-enter { flex-shrink: 0; display: flex; align-items: center; color: var(--accent-lavender); }
.digi-course-meta {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: var(--sp-3);
  flex-wrap: wrap;
}
.digi-course-dur { display: inline-flex; align-items: center; gap: 4px; font-size: var(--text-xs); color: var(--muted); }
/* תגית "דיגיטלי" עם אייקון מצלמה — מחליפה את המחיר */
.digi-course-tag {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: var(--text-xs); font-weight: 600; color: var(--accent-lavender, #80687A);
  background: rgba(128,104,122,.12); padding: 3px 10px; border-radius: 999px;
}
.digi-course-tag svg { flex-shrink: 0; }

/* ===== עמוד קורס דיגיטלי פנימי (/course/:id) ===== */
.course-page-body { margin: 0; background: var(--bg-warm); color: var(--ink); font-family: var(--font-body); -webkit-font-smoothing: antialiased; }
.course-page {
  position: relative;
  max-width: 520px; /* אחיד עם רוחב הלובי — בלי קפיצת רוחב בין עמודים */
  margin: 0 auto;
  padding: calc(env(safe-area-inset-top,0px) + 16px) var(--sp-4) calc(var(--sp-8) + env(safe-area-inset-bottom,0px));
}
/* תמונת נושא (hero) של ההכשרה — כמו בעמוד הפוסט */
.course-hero { width: 100%; aspect-ratio: var(--img-ratio); border-radius: 18px; overflow: hidden;
  margin-bottom: var(--sp-5); background: rgba(195,174,190,.15); box-shadow: 0 4px 18px rgba(74,52,34,.10); }
.course-hero img { width: 100%; height: 100%; object-fit: cover; display: block; }
.course-back {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 50%;
  background: rgba(255,255,255,.72); border: 1px solid rgba(195,174,190,.4);
  color: var(--accent); margin-bottom: var(--sp-4);
  box-shadow: 0 2px 8px rgba(74,52,34,.08);
}
.course-hero {
  border-radius: 20px; overflow: hidden; margin-bottom: var(--sp-5);
  box-shadow: 0 6px 20px rgba(74,52,34,.12);
}
.course-hero img { width: 100%; display: block; }
.course-meta-top { display: flex; align-items: center; gap: var(--sp-3); margin-bottom: var(--sp-3); }
.course-meta-top .course-price {
  font-size: var(--text-xs); font-weight: 600; color: var(--accent);
  background: rgba(195,174,190,.18); padding: 3px 12px; border-radius: 999px;
}
.course-meta-top .course-price.is-free { color: #3b6d11; background: rgba(99,153,34,.14); }
.course-dur { display: inline-flex; align-items: center; gap: 4px; font-size: var(--text-sm); color: var(--muted); }
.course-title { font-family: var(--font-head); font-size: clamp(23px, 5vw, 29px); font-weight: 700; color: var(--ink-head); margin: 0 0 var(--sp-2); line-height: 1.25; }
.course-subtitle { font-size: var(--text-lg); color: var(--ink); margin: 0 0 var(--sp-4); line-height: 1.5; }
.course-desc { font-size: var(--text-base); line-height: 1.8; color: var(--ink); margin-bottom: var(--sp-5); }
/* הצצה בווידאו לקורס */
.course-video-wrap { margin: 0 0 var(--sp-5); }
.course-video-label { display: block; font-size: var(--text-sm); font-weight: 600; color: var(--accent-lavender); margin-bottom: var(--sp-2); }
.course-video { position: relative; width: 100%; aspect-ratio: 16/9; border-radius: 16px; overflow: hidden; background: #000; box-shadow: 0 6px 22px rgba(74,52,34,.14); }
.course-video iframe, .course-video video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }
.course-acc-list { display: flex; flex-direction: column; margin: var(--sp-4) 0; }
.course-acc { border-bottom: 1px solid rgba(195,174,190,.25); }
.course-acc-summary {
  display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3);
  padding: var(--sp-3) 0; cursor: pointer; list-style: none;
  font-family: var(--font-head); font-weight: 600; font-size: var(--text-base); color: var(--ink-head);
}
.course-acc-summary::-webkit-details-marker { display: none; }
.course-acc-chev { color: var(--accent-lavender); flex-shrink: 0; transition: transform .2s ease; }
.course-acc[open] .course-acc-chev { transform: rotate(180deg); }
.course-acc-body { padding: 0 0 var(--sp-3); color: var(--ink); line-height: 1.7; font-size: var(--text-sm); }
.course-faq-title { font-family: var(--font-head); font-size: var(--text-xl); color: var(--ink-head); margin: var(--sp-6) 0 var(--sp-1); }
.course-cta {
  display: flex; align-items: center; justify-content: center; gap: var(--sp-2);
  margin-top: var(--sp-6); padding: 14px;
  border-radius: 999px; background: linear-gradient(165deg, #8a6442 0%, #5e4028 100%);
  color: #fff; font-weight: 500; text-decoration: none;
  box-shadow: 0 6px 16px rgba(103,72,47,.22);
  transition: background .22s ease;
}
.course-cta:hover { background: linear-gradient(165deg, #94704c 0%, #65462c 100%); }

/* ============================================================
   אקורדיון + hero קנוני — סגנון עמוד המחזור, משותף לכל העמודים הפנימיים.
   (עמוד המחזור עצמו מגדיר inline אותם ערכים; כאן זה הופך אותם לזמינים בכל מקום.)
   ============================================================ */
.cp-hero { background: var(--cream, rgba(243,234,228,.55)); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: var(--sp-5); margin-bottom: var(--sp-5); text-align: center; }
.cp-hero-eyebrow { font-size: var(--text-sm); color: var(--accent-gold, #a07840); font-weight: 600; margin: 0 0 var(--sp-2); }
.cp-hero-title { font-family: var(--font-head); font-size: var(--h2); font-weight: 400; color: var(--ink-head); margin: 0 0 var(--sp-3); line-height: 1.25; }
.cp-hero-title--bold { font-weight: 600; }
/* לוגו המפתח כפוקוס ה-hero (מהדף נחיתה). הטקסט "המפתח" נשאר לקורא מסך בלבד */
.cp-hero-logo { display: block; margin: 0 auto var(--sp-2); width: auto; height: auto; max-width: 210px; max-height: 76px; }
.cp-hero--mafteach .cp-hero-title { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.cp-hero-sub { font-size: var(--text-base); color: var(--muted); margin: 0 0 var(--sp-3); }
.cp-hero-meta { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: var(--sp-3); font-size: var(--text-sm); color: var(--muted); }
.cp-hero-meta-item { display: flex; align-items: center; gap: 5px; }
.cp-hero-badge { display: inline-flex; align-items: center; gap: 7px; margin-top: var(--sp-3); padding: 7px 16px; border-radius: 999px; background: rgba(128,104,122,.12); color: var(--accent-lavender); font-size: var(--text-sm); font-weight: 600; }
.cp-section-title { font-family: var(--font-head); font-size: var(--h3); font-weight: 500; color: var(--ink-head); margin: 0 0 var(--sp-3); }
.cp-lessons-list { display: flex; flex-direction: column; gap: 10px; }
.cp-lesson-acc { background: var(--cream, rgba(243,234,228,.55)); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.cp-lesson-acc--plain { display: flex; align-items: center; gap: var(--sp-3); padding: var(--sp-3) var(--sp-4); }
.cp-lesson-acc-summary { display: flex; align-items: center; gap: var(--sp-3); padding: var(--sp-3) var(--sp-4); cursor: pointer; list-style: none; user-select: none; }
.cp-lesson-acc-summary::-webkit-details-marker { display: none; }
.cp-lesson-num { flex-shrink: 0; font-family: var(--font-head); font-size: var(--text-sm); font-weight: 600; color: var(--muted); min-width: 20px; }
.cp-lesson-title { flex: 1; font-size: var(--text-base); color: var(--ink); }
.cp-lesson-chevron { flex-shrink: 0; color: var(--mauve); transition: transform var(--t-base, .25s) ease, color var(--t-fast, .15s) ease; }
.cp-lesson-acc[open] .cp-lesson-chevron { transform: rotate(180deg); }
.cp-lesson-acc-summary:hover .cp-lesson-chevron { color: var(--accent-lavender); }
.cp-lesson-acc-body { margin: 0; padding: 0 var(--sp-4) var(--sp-4); font-size: var(--text-sm); line-height: 1.75; color: var(--muted); }

/* האחדה: אקורדיון הקורס הדיגיטלי מקבל את אותו מראה כרטיס-קרם */
.course-acc-list { gap: 10px; }
.course-acc {
  border-bottom: none;
  background: var(--paper, #fff);
  border: 1px solid rgba(195,174,190,.45);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: border-color .2s ease, box-shadow .2s ease;
}
.course-acc[open] {
  border-color: var(--accent-lavender);
  box-shadow: 0 4px 16px rgba(74,52,34,.10);
}
.course-acc-summary { padding: var(--sp-3) var(--sp-4); }
/* בפתיחה: קו מפריד יורד מתחת לכותרת */
.course-acc[open] .course-acc-summary {
  border-bottom: 1px solid rgba(195,174,190,.35);
  margin-bottom: var(--sp-3);
}
.course-acc-body { padding: 0 var(--sp-4) var(--sp-3); }

/* ===== אייקון נגישות במובייל =====
   הנאבר התחתון ממורכז (max 520px); במסך צר הוא מגיע לפינת ה-FAB.
   במובייל: מרימים את הווידג'ט מעל הנאבר + מקטינים 25% (54px→40px) שיהיה פחות צועק.
   override בקובץ הפרויקט בלבד - לא נוגעים בווידג'ט הקנוני resolve-a11y.css. */
@media (max-width: 560px) {
  .ra-toggle { width: 40px !important; height: 40px !important; }
  .ra-toggle svg, .ra-toggle img { width: 22px !important; height: 22px !important; }
}


/* ---- שדה העלאת קובץ - זהה לרכיב הקנוני באדמין (סשן העיצוב 23.7.26) ---- */
input[type="file"] {
  padding: var(--sp-2);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  background: var(--paper);
  cursor: pointer;
  font-size: var(--text-sm);
  color: var(--muted);
  transition: border-color var(--t-fast);
}
input[type="file"]::file-selector-button {
  margin-inline-end: var(--sp-3);
  padding: 8px var(--sp-4);
  border: none;
  border-radius: var(--radius-sm);
  background: var(--accent-pale);
  color: var(--accent);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 600;
  cursor: pointer;
  transition: background var(--t-fast), color var(--t-fast);
}
input[type="file"]::file-selector-button:hover {
  background: var(--accent);
  color: var(--on-accent);
}
input[type="file"]:hover { border-color: var(--accent); }
