/* ===================================================================
   activity-page.css — הרכיבים הייחודיים לעמוד פעילות
   ===================================================================
   נטען *אחרי* site.css, שמביא את כל שפת העיצוב של דף הבית —
   הידר, פוטר, קרוסלה, כרטיסי תרומה, כרטיסי פעילות וטוקנים.
   כאן רק מה שלא קיים בדף הבית: רצועת הכותרת, כרטיסי המספרים,
   כרטיסי "למי/איפה" ומסגרת המדיה המקווקוות.
   =================================================================== */

.act-main{ padding-block-end: clamp(20px, 4vw, 40px); }

/* המרווח שמעל רצועת הכותרת = בדיוק גובה שורת ההידר.
   ההידר גבוה יותר מתחת ל-1024px (המבורגר וכפתור התרומה בשורה
   אחרת), ולכן הערך גדל שם. נמדד: בלי זה הניווט נפל על התמונה
   ב-23px בכל שלושת הרוחבים הצרים. */
:root{ --act-hero-top: 26px; }
@media (max-width: 1024px){ :root{ --act-hero-top: 49px; } }

.act-wrap{
  width: min(100% - 40px, 1240px);
  margin-inline: auto;
}

/* ===================== רצועת הכותרת ===================== */
.act-hero{
  position: relative;
  border-radius: clamp(26px, 3vw, 44px);
  overflow: hidden;
  min-height: clamp(250px, 30vw, 330px);
  display: grid;
  place-items: center;
  text-align: center;
  padding: clamp(30px, 4vw, 56px) clamp(20px, 5vw, 74px);
  /* מתחיל בדיוק בתחתית שורת ההידר, בלי רווח קרם נראה.
     לא גבוה מזה: בכניסה לעמוד ההידר שקוף כמו בדף הבית, ואם
     התמונה הכהה עולה מאחוריו טקסט התפריט מפסיק להיות קריא.
     הלוגו ממילא תלוי נמוך יותר, ולכן הוא נחתך לתוך התמונה. */
  margin-block-start: var(--act-hero-top, 26px);
  isolation: isolate;
}
.act-hero-bg{
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  z-index: -2;
}
/* שכבת החום — מאפשרת לטקסט הלבן לשבת על כל תמונה */
.act-hero::after{
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg,
    rgba(67,31,16,.80) 0%, rgba(67,31,16,.66) 45%, rgba(67,31,16,.82) 100%);
}

.act-crumb{
  color: rgba(255,255,255,.78);
  font-size: clamp(13px, 1.1vw, 15px);
  margin: 0 0 clamp(6px, 1vw, 12px);
}
.act-crumb a{ color: inherit; text-decoration: none; }
.act-crumb a:hover{ color:#fff; text-decoration: underline; }

/* אותו גודל כמו כותרת ההירו בדף הבית — כותרת מכובדת, לא כותרת משנה */
.act-title{
  font-size: var(--font-display);
  font-weight: 800;
  line-height: 1.08;
  margin: 0 0 clamp(10px, 1.4vw, 18px);
  color: #fff;
}
/* רק המילה האחרונה בגרדיאנט. inline-block נדרש כי
   background-clip:text לא עוקב אחרי אלמנט inline שנשבר לשתי שורות. */
.act-title .is-accent{
  display: inline-block;
  background: var(--grad-accent);
  -webkit-background-clip: text; background-clip: text;
  color: transparent; -webkit-text-fill-color: transparent;
}
.act-lead{
  color: #fff;
  font-size: clamp(15px, 1.25vw, 19px);
  line-height: 1.62;
  max-width: 62ch;
  margin: 0 auto;
}
.act-lead b{ font-weight: 700; }

/* ===================== שלוש העמודות ===================== */
.act-cols{
  display: grid;
  gap: clamp(14px, 1.6vw, 24px);
  grid-template-columns: minmax(0,.86fr) minmax(0,2fr) minmax(0,.86fr);
  align-items: center;
  margin-block: clamp(28px, 4vw, 56px);
}
.act-side{ display: grid; gap: clamp(12px, 1.4vw, 20px); }

/* --- כרטיס מספר --- */
.act-stat{
  background: #FBEDE9;
  border-radius: 20px;
  padding: clamp(16px, 1.7vw, 26px) clamp(14px, 1.5vw, 22px);
  text-align: center;
}
.act-stat b{
  display: block;
  font-size: clamp(26px, 2.6vw, 40px);
  font-weight: 800;
  line-height: 1.1;
  /* בידוד LTR — אחרת ה-bidi מעביר את הסימן + לצד השני של המספר */
  direction: ltr; unicode-bidi: isolate;
  background: var(--grad-accent);
  -webkit-background-clip: text; background-clip: text;
  color: transparent; -webkit-text-fill-color: transparent;
}
.act-stat span{
  display: block; margin-top: 6px;
  font-size: clamp(12px, 1vw, 14px);
  font-weight: 600; line-height: 1.4;
  color: var(--ink);
}

/* --- כרטיס "למי / איפה" --- */
.act-note{
  background: #FBEDE9;
  border-radius: 20px;
  padding: clamp(16px, 1.7vw, 26px) clamp(14px, 1.5vw, 22px);
}
.act-note h2{
  font-size: clamp(20px, 2vw, 28px);
  font-weight: 800; line-height: 1.15; margin: 0 0 6px;
  background: var(--grad-accent);
  -webkit-background-clip: text; background-clip: text;
  color: transparent; -webkit-text-fill-color: transparent;
}
.act-note p{
  margin: 0;
  font-size: clamp(12px, 1vw, 14px);
  line-height: 1.55; font-weight: 500;
  color: var(--ink);
}

/* --- מסגרת המדיה המקווקוות --- */
.act-media{
  position: relative;
  border: 2px dashed #C9BCAF;
  border-radius: 22px;
  padding: 10px;
  aspect-ratio: 16/11;
}
.act-media-inner{
  position: relative;
  width: 100%; height: 100%;
  border-radius: 14px; overflow: hidden;
  background: #EDE4DA;
}
.act-media img, .act-media video{
  width: 100%; height: 100%; object-fit: cover; display: block;
}
.act-play{
  position: absolute; inset: 0; margin: auto;
  width: clamp(54px, 5vw, 72px); height: clamp(54px, 5vw, 72px);
  display: grid; place-items: center;
  background: rgba(255,255,255,.16);
  border: 2px solid #fff; border-radius: 50%;
  cursor: pointer; padding: 0;
  backdrop-filter: blur(3px);
  transition: transform .22s ease, background .22s ease;
}
.act-play:hover{ transform: scale(1.07); background: rgba(255,255,255,.3); }
.act-play svg{ width: 38%; height: 38%; fill: #fff; margin-inline-start: 8%; }
.act-media.is-playing .act-play{ opacity: 0; pointer-events: none; }

/* ===================== רצועת הקרוסלה ===================== */
/* אותה קרוסלה תלת-ממדית של ההירו, רק בהקשר של העמוד הזה */
.act-gallery{
  position: relative;
  margin-block: clamp(20px, 3vw, 38px);
  /* בדף הבית .gallery3d משאיר 72px בתחתית לפס השותפים שיושב מעליו.
     כאן השותפים הם אלמנט נפרד בזרימה, ולכן אין מה לשמור. */
  --g-bottom: 0px;
}
/* הכרטיסים גבוהים מ-340px, וגובה ברירת המחדל של ‎.hero-slot‎ חתך אותם:
   נמדד כרטיס 345px בתוך מיכל 280px. הגובה כאן נותן לקשת מקום מלא. */
.act-gallery .hero-slot{
  margin: 0;
  min-height: clamp(380px, 33vw, 470px);
}

/* ===================== פס השותפים ===================== */
/* בדף הבית ‎.partners‎ הוא absolute בתוך ההירו. כאן אין הירו, ולכן
   בלי העקיפה הזו הוא נצמד לחלון וצף מעל התוכן. */
.act-partners{ position: relative; margin-block: clamp(6px, 1.4vw, 18px); }
.act-partners .partners{
  position: static;
  inset: auto;
  justify-content: center;
}
.act-partners-label{ display: none; }
.activity-page .act-partners .act-partners-label{ color: #786b62; }

/* בכל עמודי הפעילות פס השותפים נכנס לקיפול הראשון בדסקטופ.
   הוא נשאר אלמנט בזרימה, כך שהאזור הבא מתחיל מיד אחריו. */
@media (min-width: 1025px){
  .activity-page .act-partners{
    --partner-h: 38px;
    --pdiv-h: 38px;
    margin-block: -42px 0;
    z-index: 5;
  }
  .activity-page .act-partners-label{
    display: block;
    margin-inline-end: 18px;
    color: #9F938B;
    font-size: 15px;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
  }
  .activity-page .act-partners .partner-mizam .mizam-text{
    font-size: 12px;
    line-height: 1.16;
  }
}

/* ===================== כותרת "עוד פעילויות" ===================== */
.act-more{ margin-block: clamp(30px, 4vw, 56px) clamp(10px, 2vw, 20px); }
.act-more-title{
  text-align: center;
  font-size: var(--font-section-title);
  font-weight: 800; line-height: 1.15;
  margin: 0 0 clamp(18px, 2.4vw, 32px);
}
.act-more-title .is-accent{
  background: var(--grad-accent);
  -webkit-background-clip: text; background-clip: text;
  color: transparent; -webkit-text-fill-color: transparent;
}

/* ===================== טאבלט ===================== */
@media (max-width: 1024px){
  .activity-page .act-more{
    margin-block: 20px 16px;
    overflow: hidden;
  }

  .activity-page .act-more .act-wrap{
    width: min(100%, 620px);
  }

  .activity-page .act-more-title{
    margin: 0 14px 12px;
  }

  /* רוחב המסילה = שני עיגולים ושני רווחים: בכל עצירה
     עיגול שלם במרכז וחצי עיגול מכל צד. */
  body.activity-page .act-more .activities-grid{
    position: relative;
    display: flex;
    flex-flow: row nowrap;
    justify-content: flex-start;
    align-items: center;
    /* 5.10.2026: the cards used to sit almost edge to edge on a phone (was 12px) */
    gap: 22px !important;
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 12px 0;
    overflow-x: auto;
    overflow-y: hidden;
    direction: ltr;
    scroll-snap-type: x mandatory;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
    cursor: grab;
  }

  .activity-page .act-more .activities-grid::-webkit-scrollbar{
    display: none;
  }

  .activity-page .act-more .activities-grid.is-dragging{
    scroll-snap-type: none;
    cursor: grabbing;
    user-select: none;
  }

  .activity-page .act-more .activity-item{
    flex: 0 0 calc((100% - 44px) / 2);
    width: calc((100% - 44px) / 2);
    max-width: none;
    min-width: 0;
    scroll-snap-align: center;
    scroll-snap-stop: always;
    direction: rtl;
  }

  .activity-page .act-more .activity-card,
  .activity-page .act-more .activity-card.active{
    display: block;
    width: 100%;
    height: auto !important;
    aspect-ratio: 1 / 1 !important;
    cursor: inherit;
  }

  .activity-page .act-more .activity-card .activity-card__label{
    width: max-content;
    max-width: 90%;
    bottom: 13%;
    padding: 6px 8px;
    font-size: clamp(11px, 3.2vw, 17px);
    line-height: 1.2;
    white-space: nowrap;
  }

  .activity-page .act-more .activity-card__label span{
    white-space: nowrap;
  }

  .activity-page .act-more .activity-card__image{
    user-select: none;
    -webkit-user-drag: none;
  }

  .activity-page .act-more .activities-grid:focus-visible{
    outline: 2px solid var(--orange);
    outline-offset: -2px;
    border-radius: 12px;
  }

  .act-cols{
    grid-template-columns: repeat(2, minmax(0,1fr));
    gap: clamp(12px, 2vw, 18px);
  }
  /* המדיה עוברת לרוחב מלא מעל שני טורי הכרטיסים */
  .act-media{ grid-column: 1 / -1; order: -1; aspect-ratio: 16/9; }
  .act-side{ gap: 12px; }
}

/* Footer refinements belong to activity pages only; desktop and home stay intact. */
@media (max-width: 1024px){
  body.activity-page .footer-section{
    /* These override the site's mobile-control tokens on the section itself. */
    --ft-logo: clamp(90px, 14vw, 110px) !important;
    --ft-logo-ring: 10px;
    --ft-logo-out: .38;
    --ft-pad-top: calc(var(--ft-logo) * .62 + var(--ft-logo-ring) + 8px) !important;
    padding-block: var(--ft-pad-top) 28px;
  }

  body.activity-page .ft-logo{
    width: var(--ft-logo) !important;
    height: var(--ft-logo);
  }

  .activity-page .ft-cta-row{
    flex-flow: row nowrap;
    gap: 10px;
  }

  body.activity-page .ft-btn{
    position: relative;
    flex: 1 1 0;
    width: auto;
    max-width: 200px;
    min-width: 0;
    height: 36px;
    min-height: 36px;
    padding: 0 8px !important;
    justify-content: center;
    gap: 5px;
    font-size: clamp(11px, 3vw, 13px);
    line-height: 1;
    white-space: nowrap;
  }

  /* Keep a 44px touch area around the visually shorter buttons. */
  .activity-page .ft-btn::before{
    content: '';
    position: absolute;
    inset-inline: 0;
    top: 50%;
    height: 44px;
    transform: translateY(-50%);
  }

  .activity-page .ft-btn svg{
    flex: 0 0 13px;
    width: 13px;
    height: 13px;
  }

  /* הפוטר הוא קומפוננטה משותפת בכל העמודים הפנימיים, כולל אודות.
     הכותרת מקבלת רוחב גמיש כדי שהמילה "הסיבה" לא תיחתך במסכים צרים. */
  body.activity-page .footer-section .ft-title{
    width:100%;
    max-width:calc(100% - 24px);
    margin-inline:auto;
    font-size:clamp(23px, 6.6vw, 27px) !important;
    line-height:1.05 !important;
    white-space:normal;
    overflow:visible;
  }
  body.activity-page .footer-section .ft-title > span{
    display:block;
    white-space:normal;
    overflow:visible;
  }

  .activity-page .ft-cols{
    align-items: start;
    gap: 22px 16px;
    text-align: center;
  }

  .activity-page .ft-col{
    min-width: 0;
    text-align: center;
  }

  .activity-page .ft-col h3{
    margin-bottom: 7px;
    line-height: 1.2;
  }

  .activity-page .ft-col li{
    margin-bottom: 2px;
    line-height: 1.3;
  }

  body.activity-page .ft-col a,
  body.activity-page .ft-col span{
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 24px;
    padding-block: 2px;
    line-height: 1.3;
    text-align: center;
  }

  .activity-page .ft-contact li{
    justify-content: center;
    align-items: center;
    gap: 5px;
  }

  .activity-page .ft-contact li > a,
  .activity-page .ft-contact li > span{
    flex: 0 1 auto;
    min-width: 0;
  }

  .activity-page .ft-contact svg{ margin-top: 0; }

  .activity-page .ft-contact li a[href^="mailto"]{
    font-size: clamp(10px, 2.6vw, 13px);
    white-space: nowrap;
  }

  .activity-page .footer-section .give-strip{
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
    gap: 16px 12px;
    padding: 18px 12px;
    text-align: center;
  }

  .activity-page .footer-section .give-strip-title{
    order: 0;
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .2em;
    width: 100%;
    font-size: 24px;
    line-height: 1.2;
    text-align: center;
  }

  .activity-page .footer-section .give-strip-title .title-highlight{
    margin-inline: 0;
  }

  .activity-page .footer-section .give-trust{
    order: 1;
    min-width: 0;
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }

  .activity-page .footer-section .give-tile{
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
  }

  .activity-page .footer-section .give-trust-text{ text-align: center; }

  .activity-page .footer-section .give-trust-text h3{
    margin-bottom: 3px;
    font-size: 13px;
    line-height: 1.25;
  }

  .activity-page .footer-section .give-trust-text p{
    font-size: 11.5px;
    line-height: 1.3;
  }
}

@media (max-width: 359px){
  .activity-page .ft-contact li a[href^="mailto"]{ font-size: 13px; }
}

/* ===================== נייד ===================== */
@media (max-width: 640px){
  .act-wrap{ width: min(100% - 28px, 1240px); }
  .act-hero{ min-height: 210px; border-radius: 24px; }
  .act-cols{ grid-template-columns: 1fr; }
  .act-media{ aspect-ratio: 4/3; }
  .act-side{ grid-template-columns: repeat(2, minmax(0,1fr)); }
  .act-side.act-side-notes{ grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce){
  .act-play{ transition: none; }
}
