/* ===== Site refresh (Step 2): hero, featured events, calendar, menu ===== */

/* Show content immediately instead of fading it in on scroll (avoids blank areas) */
.wow { visibility: visible !important; animation-name: none !important; }

#schedule, .gw-events { scroll-margin-top: 80px; }
.gw-section-title {
    font-family: 'Vollkorn', 'Noto Serif', serif; font-style: italic; color: var(--gw-brown);
    text-align: center; font-size: 30px; margin: 0 0 22px;
}
.gw-btn--light { background: rgba(255,255,255,.92); color: var(--gw-green-dark) !important; border-color: rgba(255,255,255,.92); }
.gw-btn--light:hover, .gw-btn--light:focus { background: #fff; }
.gw-btn.is-disabled { opacity: .35; pointer-events: none; }

/* ---------- Hero slideshow ---------- */
.gw-hero { position: relative; height: min(78vh, 680px); min-height: 440px; overflow: hidden; background: #2b2b2b; color: #fff; }
.gw-hero__slides, .gw-hero__img, .gw-hero__shade { position: absolute; inset: 0; }
.gw-hero__img { width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1.4s ease; transform: scale(1.04); }
.gw-hero__img.is-on { opacity: 1; animation: gw-zoom 9s ease-out forwards; }
@keyframes gw-zoom { from { transform: scale(1.04); } to { transform: scale(1.12); } }
@media (prefers-reduced-motion: reduce) { .gw-hero__img.is-on { animation: none; } .gw-hero__img { transition: none; } }
.gw-hero__shade { background: linear-gradient(90deg, rgba(14,38,32,.82) 0%, rgba(14,38,32,.55) 45%, rgba(14,38,32,.1) 80%), linear-gradient(0deg, rgba(0,0,0,.35), rgba(0,0,0,0) 40%); }
.gw-hero__content { position: relative; z-index: 2; height: 100%; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; text-align: left; }
.gw-hero__title { font-family: 'Vollkorn', 'Noto Serif', serif; font-style: italic; font-weight: 500; color: #fff; font-size: clamp(32px, 4.6vw, 58px); line-height: 1.12; max-width: 640px; margin: 0 0 16px; text-shadow: 0 2px 18px rgba(0,0,0,.35); }
.gw-hero__sub { font-size: clamp(17px, 1.6vw, 21px); line-height: 1.5; max-width: 560px; color: rgba(255,255,255,.92); margin: 0 0 26px; }
.gw-hero__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.gw-hero__actions .gw-btn:first-child { background: #fff; color: var(--gw-green-dark) !important; border-color: #fff; }
.gw-hero__actions .gw-btn--light { background: rgba(255,255,255,.14); color: #fff !important; border-color: rgba(255,255,255,.6); backdrop-filter: blur(2px); }
.gw-hero__actions .gw-btn--light:hover { background: rgba(255,255,255,.26); }
.gw-hero__dots { position: absolute; z-index: 3; bottom: 18px; left: 50%; transform: translateX(-50%); display: flex; gap: 8px; }
.gw-hero__dot { width: 10px; height: 10px; border-radius: 50%; border: 2px solid #fff; background: transparent; padding: 0; cursor: pointer; opacity: .8; }
.gw-hero__dot.is-on { background: #fff; opacity: 1; }

/* ---------- Featured events ---------- */
.gw-events { background: var(--gw-green-tint); padding: 44px 0 40px; }
.gw-events__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 20px; max-width: 1060px; margin: 0 auto; }
.gw-events__grid.is-single { grid-template-columns: 1fr; max-width: 900px; }
.gw-event { display: flex; flex-direction: column; background: #fff; border-radius: 10px; overflow: hidden; box-shadow: 0 2px 14px rgba(0,0,0,.08); text-align: left; }
.gw-events__grid.is-single .gw-event { flex-direction: row; }
.gw-event__img { display: block; background: #f4f4f4; }
.gw-event__img img { display: block; width: 100%; height: 100%; max-height: 360px; object-fit: contain; }
.gw-events__grid.is-single .gw-event__img { flex: 0 0 42%; }
.gw-event__body { padding: 22px 24px; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 10px; }
.gw-event__when { color: var(--gw-green); font-weight: 700; font-size: 14px; text-transform: uppercase; letter-spacing: .5px; }
.gw-event__title { font-family: 'Vollkorn', 'Noto Serif', serif; color: var(--gw-brown); font-size: 26px; line-height: 1.2; margin: 0; }
.gw-event__desc { color: var(--gw-text); font-size: 16px; line-height: 1.55; margin: 0; }

/* ---------- Calendar ---------- */
.gw-cal__bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; margin: 0 auto 16px; max-width: 1170px; }
.gw-cal__nav { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.gw-cal__nav .gw-btn { padding: 7px 12px; }
.gw-cal__month { font-family: 'Vollkorn', 'Noto Serif', serif; color: var(--gw-brown); font-size: 28px; margin: 0; min-width: 210px; text-align: center; }
.gw-cal__today { font-size: 14px; }
.gw-cal__sub { font-size: 14px; color: var(--gw-muted); display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.gw-cal__grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border-top: 1px solid var(--gw-line); border-left: 1px solid var(--gw-line); background: #fff; border-radius: 6px; overflow: hidden; }
.gw-cal__dow { background: var(--gw-green); color: #fff; font-size: 13px; font-weight: 700; text-align: center; padding: 8px 4px; border-right: 1px solid rgba(255,255,255,.2); }
.gw-cal__cell { min-height: 118px; border-right: 1px solid var(--gw-line); border-bottom: 1px solid var(--gw-line); padding: 6px 6px 8px; display: flex; flex-direction: column; gap: 4px; text-align: left; }
.gw-cal__cell.is-other { background: #fafafa; }
.gw-cal__cell.is-other .gw-cal__num { color: #bbb; }
.gw-cal__cell.is-past .gw-cal__ev { opacity: .55; }
.gw-cal__cell.is-today { background: #f3faf7; box-shadow: inset 0 0 0 2px var(--gw-green); }
.gw-cal__num { font-size: 13px; font-weight: 700; color: var(--gw-muted); }
.gw-cal__cell.is-today .gw-cal__num { color: #fff; background: var(--gw-green); border-radius: 999px; width: 24px; height: 24px; display: inline-flex; align-items: center; justify-content: center; }
.gw-cal__ev { display: block; width: 100%; text-align: left; border: none; border-left: 3px solid var(--gw-green); background: var(--gw-green-tint); border-radius: 4px; padding: 3px 6px; font-size: 12px; line-height: 1.3; color: var(--gw-text); cursor: pointer; }
.gw-cal__ev[hidden] { display: none; }
.gw-cal__ev:hover, .gw-cal__ev:focus { filter: brightness(.96); outline: 2px solid rgba(45,105,92,.35); }
.gw-cal__ev--online { border-left-color: #2a5d8f; background: #eef5fc; }
.gw-cal__ev--both { border-left-color: #5b3f86; background: #f4f0f9; }
.gw-cal__ev.is-cancelled { border-left-color: var(--gw-red); background: #fbeeec; }
.gw-cal__ev.is-cancelled .gw-cal__evtitle { color: var(--gw-muted); }
.gw-cal__evtime { font-weight: 700; margin-right: 3px; }
.gw-cal__evtitle { overflow-wrap: anywhere; }
.gw-cal__evnote { display: block; color: var(--gw-red); font-weight: 700; font-size: 11px; }
.gw-cal__list { display: none; }
.gw-cal__item[hidden] { display: none; }
.gw-cal__dialog { border: none; border-radius: 10px; padding: 0; width: min(620px, 94vw); box-shadow: 0 12px 40px rgba(0,0,0,.35); }
.gw-cal__dialog::backdrop { background: rgba(0,0,0,.45); }
.gw-cal__dialog-head { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px 0; font-weight: 700; color: var(--gw-brown); }
.gw-cal__close { border: none; background: none; font-size: 28px; line-height: 1; color: var(--gw-muted); cursor: pointer; }
.gw-cal__dialog .gw-class { margin: 10px 16px 16px; }
@media (max-width: 767px) {
    .gw-cal__grid { display: none; }
    .gw-cal__list { display: block; max-width: 860px; margin: 0 auto; }
    .gw-cal__month { font-size: 23px; min-width: 0; }
    .gw-cal__bar { justify-content: center; }
}

/* ---------- Menu ---------- */
header nav ul li a[aria-current="page"] { color: var(--gw-green) !important; font-weight: 700; }
header nav ul li.menu-item-has-children > ul { min-width: 220px; z-index: 1000; }
header nav ul li.menu-item-has-children > ul li a { text-align: left; white-space: nowrap; }
@media (min-width: 993px) {
    /* open dropdowns for keyboard users too */
    header nav ul li.menu-item-has-children:focus-within > ul { opacity: 1; visibility: visible; top: 100%; }
}
@media (max-width: 992px) {
    header nav ul li.menu-item-has-children > ul { position: static; opacity: 1; visibility: visible; min-width: 0; box-shadow: none; }
    header nav ul li.menu-item-has-children > ul li a { text-align: center; white-space: normal; }
}

@media (max-width: 600px) {
    .gw-hero { height: 76vh; min-height: 460px; }
    .gw-hero__shade { background: linear-gradient(0deg, rgba(14,38,32,.9) 0%, rgba(14,38,32,.6) 55%, rgba(14,38,32,.25) 100%); }
    .gw-hero__content { justify-content: flex-end; padding-bottom: 54px; }
    .gw-hero__actions { width: 100%; }
    .gw-hero__actions .gw-btn { flex: 1 1 100%; justify-content: center; }
    .gw-events__grid.is-single .gw-event { flex-direction: column; }
    .gw-event__title { font-size: 22px; }
}

/* ---------- Donate popup: PayPal button ---------- */
.gw-donate-online { margin: 30px 20px; padding: 22px 24px; background: var(--gw-green-tint); border-radius: 10px; text-align: center; }
.gw-donate-online h4 { font-family: 'Vollkorn', 'Noto Serif', serif; color: var(--gw-brown); font-size: 24px; margin: 0 0 8px; }
.gw-donate-online p { font-size: 16px; line-height: 1.55; color: var(--gw-text); margin: 0 0 16px; }
.gw-donate-online form { margin: 0; float: none; }
.gw-donate-btn { font-size: 18px; padding: 14px 26px; justify-content: center; width: 100%; max-width: 380px; cursor: pointer; }
.gw-donate-cards { margin-top: 14px; font-size: 30px; color: #6b7c77; display: flex; justify-content: center; gap: 10px; }
@media (max-width: 767px) {
    /* Phones: online donation first, and keep everything inside the screen */
    #donation_modal .popup-content { display: flex; flex-direction: column-reverse; }
    #donation_modal .popup-content > [class*="col-"] { float: none; width: 100%; margin-left: 0; margin-right: 0; padding-left: 0; padding-right: 0; }
    #donation_modal .popup-content .donation_form > .col-sm-12 { padding-left: 0; padding-right: 0; }
    .gw-donate-online { margin: 18px 12px 6px; padding: 18px 14px; }
}

/* ---------- Tighter spacing between sections (all pages) ---------- */
.block { padding-top: 36px; padding-bottom: 36px; }
.block.remove-gap { padding-top: 0; }
.block.remove-bottom-gap { padding-bottom: 0; }
.decorated-title { padding: 26px 30px; }
.kollel_section_subtitle { margin: -10px auto 22px; }
#staff, #mission { margin-top: -36px; }
.gw-events { padding: 30px 0 32px; }
.gw-lead { margin: 4px auto 18px; }
@media (max-width: 767px) {
    .block { padding-top: 26px; padding-bottom: 26px; }
    .decorated-title { padding: 22px 15px; }
}

/* ---------- "Watch the latest shiur" (program pages) ---------- */
.gw-media { background: var(--gw-green-tint); padding: 34px 0 40px; clear: both; float: left; width: 100%; }
.gw-media .gw-section-title { margin-bottom: 18px; }
.gw-media__video { max-width: 860px; margin: 0 auto; background: #fff; border-radius: 10px; overflow: hidden; box-shadow: 0 2px 14px rgba(0,0,0,.08); }
.gw-media__frame { position: relative; aspect-ratio: 16 / 9; background: #000; }
.gw-media__frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.gw-media__info { padding: 14px 18px 16px; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 16px; text-align: left; }
.gw-media__title { font-family: 'Vollkorn', 'Noto Serif', serif; font-size: 20px; color: var(--gw-brown); flex: 1 1 100%; }
.gw-media__date { font-size: 14px; color: var(--gw-muted); }
.gw-media__more { font-size: 14px; font-weight: 700; margin-left: auto; }
.gw-media__more .fa { color: #c4302b; }
.gw-media__audio { max-width: 860px; margin: 24px auto 0; text-align: left; }
.gw-media__sub { font-size: 17px; color: var(--gw-brown); margin: 0 0 10px; font-family: 'Vollkorn', 'Noto Serif', serif; }
.gw-media__sub .fa { color: var(--gw-green); margin-right: 4px; }
.gw-media__player { width: 100%; height: 180px; border: 0; border-radius: 8px; background: #fff; display: block; }
.gw-media__audio audio { width: 100%; }
@media (max-width: 600px) {
    .gw-media { padding: 24px 0 28px; }
    .gw-media__info { padding: 12px 14px 14px; }
    .gw-media__more { margin-left: 0; }
}

/* ---------- Rows of cards with arrows at the ends (home page programs + faculty) ---------- */
.gw-scroller { position: relative; padding: 0 46px; }
.gw-scroller.is-static { padding: 0; }
.gw-scroller.is-static .gw-scroller__btn { display: none; }
.gw-scroller__viewport { overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; scroll-behavior: smooth; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.gw-scroller__viewport::-webkit-scrollbar { display: none; }
.gw-scroller__track { list-style: none; margin: 0; padding: 4px 2px 10px; display: flex; gap: 14px; width: max-content; }
.gw-scroller.is-static .gw-scroller__track { width: auto; justify-content: center; flex-wrap: wrap; }
.gw-scroller__track > li { float: none; margin: 0; padding: 0; width: auto; scroll-snap-align: start; }
.gw-scroller__btn { position: absolute; top: 50%; transform: translateY(-60%); width: 38px; height: 38px; border-radius: 50%; border: 1px solid #c8d6d1; background: #fff; color: var(--gw-green-dark); box-shadow: 0 2px 8px rgba(0,0,0,.12); display: flex; align-items: center; justify-content: center; cursor: pointer; z-index: 2; padding: 0; font-size: 15px; }
.gw-scroller__btn:hover:not(:disabled) { background: var(--gw-green); border-color: var(--gw-green); color: #fff; }
.gw-scroller__btn:disabled { opacity: .3; cursor: default; box-shadow: none; }
.gw-scroller__btn.is-prev { left: 0; }
.gw-scroller__btn.is-next { right: 0; }
@media (max-width: 600px) {
    .gw-scroller { padding: 0 34px; }
    .gw-scroller__btn { width: 30px; height: 30px; font-size: 12px; }
}

/* Programs */
.gw-reel { padding: 26px 0 30px; clear: both; }
.gw-reel__head { display: flex; align-items: baseline; justify-content: center; gap: 6px 18px; flex-wrap: wrap; margin-bottom: 12px; }
.gw-reel__head .gw-section-title { margin: 0; }
.gw-reel__all { font-weight: 700; font-size: 14.5px; }
.gw-reel__card { display: flex; flex-direction: column; width: 200px; height: 100%; background: #fff; border-radius: 10px; overflow: hidden; box-shadow: 0 2px 10px rgba(0,0,0,.1); text-decoration: none !important; transition: transform .15s, box-shadow .15s; }
.gw-reel__card:hover, .gw-reel__card:focus { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0,0,0,.16); }
.gw-reel__img { display: block; aspect-ratio: 4 / 3; background: var(--gw-green-tint); overflow: hidden; }
.gw-reel__img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gw-reel__title { display: block; padding: 8px 10px 10px; font-family: 'Vollkorn', 'Noto Serif', serif; color: var(--gw-brown); font-size: 15.5px; line-height: 1.25; text-align: center; }
@media (max-width: 600px) { .gw-reel__card { width: 150px; } .gw-reel__title { font-size: 14px; } }

/* Faculty */
.gw-faculty { background: var(--gw-green-tint); padding: 30px 0 34px; clear: both; float: left; width: 100%; }
.gw-faculty .gw-section-title { margin-bottom: 6px; }
.gw-faculty .gw-lead { margin: 0 auto 16px; font-size: 15.5px; }
.gw-faculty .gw-scroller__track { align-items: flex-start; }
.gw-person { width: 230px; background: #fff; border-radius: 10px; overflow: hidden; box-shadow: 0 2px 10px rgba(0,0,0,.08); text-align: left; }
.gw-person__img { aspect-ratio: 1 / 1; background: #e9efed; display: flex; align-items: center; justify-content: center; color: #b7c9c3; font-size: 60px; overflow: hidden; }
.gw-person__img img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; display: block; }
.gw-person__body { padding: 12px 14px 14px; }
.gw-person__role { font-family: 'Noto Sans', sans-serif; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .6px; color: var(--gw-green); }
.gw-person__name { font-family: 'Vollkorn', 'Noto Serif', serif; color: var(--gw-brown); font-size: 19px; line-height: 1.2; margin: 2px 0 6px; }
.gw-person__bio { margin: 0; font-size: 13.5px; line-height: 1.5; color: var(--gw-muted); display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.gw-person.is-open .gw-person__bio { display: block; -webkit-line-clamp: unset; overflow: visible; }
.gw-person__more { font-family: 'Noto Sans', sans-serif; background: none; border: 0; padding: 0; margin-top: 4px; font-size: 13px; font-weight: 700; color: var(--gw-green-dark); cursor: pointer; }
.gw-person__more[hidden] { display: none; }
@media (max-width: 600px) { .gw-person { width: 200px; } }

/* Mission */
#mission.gw-mission { background: #fff; padding: 30px 0 38px; margin-top: 0; clear: both; float: left; width: 100%; }
#mission.gw-mission:before { display: none; }
.gw-mission .gw-section-title { margin-bottom: 8px; }
.gw-mission__intro { text-align: center; font-size: 17px; color: var(--gw-muted); margin: 0 0 14px; }
.gw-mission__pillars { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 14px; max-width: 900px; margin: 0 auto 20px; }
.gw-mission__pillar { display: flex; gap: 14px; align-items: flex-start; background: var(--gw-green-tint); border-radius: 10px; padding: 16px 18px; text-align: left; }
.gw-mission__pillar p { margin: 0; font-size: 15.5px; line-height: 1.6; color: var(--gw-text); }
.gw-mission__pillar strong { color: var(--gw-green-dark); }
.gw-mission__icon { flex: none; width: 44px; height: 44px; border-radius: 10px; background: var(--gw-green); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 20px; }
.gw-mission__text { max-width: 780px; margin: 0 auto; text-align: left; }
.gw-mission__text p { font-size: 15.5px; line-height: 1.75; color: var(--gw-text); margin: 0 0 12px; }
