/* =========================================================
   sections.css — Homepage sections, in page order
   ========================================================= */

/* hero slider */
.hero-slider{position:relative;height:clamp(520px,calc(100vh - 118px),780px);height:clamp(520px,calc(100svh - 118px),780px);padding:0;background:var(--navy);color:#fff;overflow:hidden;--hs-delay:6s}
.hs-viewport{position:absolute;inset:0;touch-action:pan-y}
.hs-slide{position:absolute;inset:0;opacity:0;visibility:hidden;transition:opacity 1s ease,visibility 0s linear 1s}
.hs-slide.is-active{opacity:1;visibility:visible;transition:opacity 1s ease,visibility 0s}
.hs-media{position:absolute;inset:0;background-color:var(--navy);transform:scale(1.07);transition:transform 9s ease-out}
.hs-slide.is-active .hs-media{transform:scale(1)}
.hs-slide:after{content:"";position:absolute;inset:0;z-index:1;pointer-events:none;
  background:linear-gradient(90deg,rgba(16,18,74,.92) 0%,rgba(16,18,74,.72) 36%,rgba(16,18,74,.18) 72%,rgba(16,18,74,0) 100%),linear-gradient(0deg,rgba(16,18,74,.6) 0%,rgba(16,18,74,0) 30%)}
.hero-video{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.hv{transition:opacity 1.2s ease}
.hs-content{position:relative;z-index:2;height:100%;display:flex;align-items:center;padding-bottom:64px}
.hs-text{max-width:620px}
.hs-text .eyebrow{color:var(--peri-2);font-size:.86rem}
.hs-title{color:#fff;font-size:clamp(2.2rem,4.6vw,3.8rem);line-height:1.06;margin:8px 0 22px}
.hs-text p{color:rgba(255,255,255,.84);font-size:1rem;max-width:520px;margin-bottom:34px}
.hs-title--long{font-size:clamp(2rem,3.7vw,3.1rem)}
/* outlined title: only the letters' border shows, the photo shows through them (solid white where text-stroke isn't supported) */
@supports (-webkit-text-stroke:1px #fff){.hs-title--outline{color:transparent;-webkit-text-stroke:1.5px #fff;letter-spacing:.01em}}
/* the motto on each slide: same type as the title, set in the bottom-right corner (over the parked cars) */
.hs-text .hs-motto{position:absolute;right:24px;bottom:clamp(104px,13vh,140px);max-width:9.5em;margin:0;text-align:right;font:400 clamp(2rem,3.7vw,3.1rem)/1.06 "Young Serif",Georgia,serif;color:#fff;text-shadow:0 4px 24px rgba(10,8,40,.65)}
@media (max-width:1360px){.hs-text .hs-motto{right:96px}} /* clear of the assistant button, like .hs-controls */
.hs-text>*{opacity:0;transform:translateY(18px);transition:opacity .7s ease,transform .7s ease}
.hs-slide.is-active .hs-text>*{opacity:1;transform:none}
.hs-slide.is-active .hs-text>:nth-child(2){transition-delay:.12s}
.hs-slide.is-active .hs-text>:nth-child(3){transition-delay:.24s}
.hs-slide.is-active .hs-text>:nth-child(4){transition-delay:.36s}
/* slide with the XVIII Conference seal (and a button under it) to the left of the text */
.hs-content--seal{gap:clamp(28px,4vw,64px)}
.hs-seal-col{flex:none;display:flex;flex-direction:column;align-items:center;gap:22px}
.hs-seal{width:clamp(150px,16vw,230px);height:auto;border-radius:50%;filter:drop-shadow(0 18px 40px rgba(0,0,0,.5))}
.hs-seal-col>*{opacity:0;transform:scale(.94);transition:opacity .9s ease,transform .9s ease}
.hs-slide.is-active .hs-seal-col>*{opacity:1;transform:none}
.hs-slide.is-active .hs-seal-col>.btn{transition-delay:.3s}
@media (max-width:860px){
  .hs-text .hs-motto{position:static;max-width:none;text-align:left;font-size:1.6rem;margin-bottom:26px}
  .hs-content.hs-content--seal{flex-direction:column;align-items:flex-start;justify-content:flex-end;gap:18px}
  .hs-seal-col{gap:16px}
  .hs-seal{width:clamp(110px,28vw,150px)}
}
@media (prefers-reduced-motion:reduce){.hs-seal-col>*{transition:none;transform:none}}

/* slider controls */
.hs-controls{position:absolute;left:0;right:0;bottom:30px;z-index:3;display:flex;align-items:center;gap:24px}
.hs-dots{display:flex;gap:10px;flex:1;max-width:360px}
.hs-dot{position:relative;flex:1;height:24px;padding:0;background:none;border:none;cursor:pointer}
.hs-dot:before,.hs-dot span{content:"";position:absolute;left:0;top:50%;height:2px;margin-top:-1px}
.hs-dot:before{right:0;background:rgba(255,255,255,.3)}
.hs-dot span{width:0;background:#fff}
.hs-dot.is-active span{animation:hs-progress var(--hs-delay) linear forwards}
.hero-slider.is-held .hs-dot.is-active span{animation-play-state:paused}
@keyframes hs-progress{from{width:0}to{width:100%}}
.hs-count{font-size:.74rem;font-weight:500;letter-spacing:.16em;color:rgba(255,255,255,.7);font-variant-numeric:tabular-nums;white-space:nowrap}
.hs-count b{color:#fff;font-weight:700}
.hs-nav{display:flex;gap:10px;margin-left:auto}
.hs-btn{width:46px;height:46px;border-radius:50%;border:1px solid rgba(255,255,255,.45);background:rgba(16,18,74,.3);color:#fff;display:flex;align-items:center;justify-content:center;cursor:pointer;backdrop-filter:blur(4px);transition:background .2s,color .2s,border-color .2s}
.hs-btn:hover{background:#fff;color:var(--navy);border-color:#fff}
.hs-btn svg{width:16px;height:16px;stroke:currentColor;fill:none;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.hs-toggle .ico-play{fill:currentColor;stroke:none}
.hs-toggle .ico-play,.hero-slider.is-user-paused .hs-toggle .ico-pause{display:none}
.hero-slider.is-user-paused .hs-toggle .ico-play{display:block}
.hs-btn:focus-visible,.hs-dot:focus-visible,.hero-slider .btn:focus-visible{outline:2px solid var(--peri);outline-offset:3px}
@media (prefers-reduced-motion:reduce){
  .hero-video{display:none}
  .hs-slide,.hs-media,.hs-text>*{transition:none!important}
  .hs-media{transform:none}
  .hs-dot.is-active span{animation:none;width:100%}
}

/* beliefs band */
/* "Welcome / The Grand Lodge of Liberia" under the slider: "Liberia" in purple with a gold underline */
.big-name{margin:0 auto 64px;text-align:center}
.big-name-kicker{display:block;font-size:.78rem;font-weight:700;letter-spacing:.3em;text-transform:uppercase;color:var(--purple);margin-bottom:14px}
.big-name h2{font-size:clamp(2rem,4.4vw,3.4rem);line-height:1.15;color:var(--navy)}
.big-name h2 span{color:var(--purple);text-decoration:underline;text-decoration-color:var(--gold);text-decoration-thickness:.07em;text-underline-offset:.16em;text-decoration-skip-ink:none}
.card-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:0;border:1px solid var(--line);background:#fff}
.icard{border-right:1px solid var(--line);transition:background .2s;display:block}
.icard:last-child{border-right:none}
.icard:hover{background:#fbfbff}
.icard-head{display:flex;align-items:center;justify-content:center;gap:6px;padding:18px 14px;border-bottom:1px solid var(--line)}
.icard-head svg{width:13px;height:13px;stroke:var(--ink);fill:none;stroke-width:1.4}
.icard-body{padding:26px 24px 30px}
.icard-body .ico{width:46px;height:46px;stroke:var(--navy);fill:none;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;margin-bottom:18px}
.icard-body p{font-size:.8rem;color:var(--muted);line-height:1.8}
.ring{width:46px;height:46px;border-radius:50%;border:1.5px solid var(--navy);display:flex;align-items:center;justify-content:center;font-family:"Young Serif",serif;color:var(--navy);font-size:.95rem;margin-bottom:18px}
.icard-body h3{font-size:1.1rem;margin-bottom:6px}
.card-grid--3{grid-template-columns:repeat(3,1fr)}

/* post cards */
.post{position:relative;border:1px solid var(--line);background:#fff;padding-bottom:34px}
.post .ph{height:var(--h,220px)}
.post-head{position:relative;background:#fff;margin:-54px 54px 0 0;padding:20px 26px 4px}
.post h3{font-size:1.28rem;line-height:1.15;margin-bottom:12px}
.meta{display:flex;align-items:center;gap:8px;font-size:.56rem;font-weight:500;letter-spacing:.14em;text-transform:uppercase;color:var(--muted);margin-bottom:4px}
.meta svg{width:12px;height:12px;flex:none;stroke:var(--ink);fill:none;stroke-width:1.3}
.post p{padding:10px 26px 0;font-size:.82rem;color:var(--muted);line-height:1.85}
.post .more{position:absolute;right:24px;bottom:-12px}
.plaque{display:flex;gap:12px;align-items:center;padding:14px 26px 0}
.plaque img{width:44px;height:64px;object-fit:cover;border:1px solid var(--line)}
.plaque span{font-size:.72rem;color:var(--muted)}

/* welcome / grand master */
.welcome{position:relative;background:var(--lav);padding:90px 0;overflow:hidden}
.welcome-photo{position:absolute;top:0;bottom:0;right:0;width:46%;background-color:#e7e7ea}
/* soft fade from the lavender background into the portrait */
.welcome-photo:before{content:"";position:absolute;inset:0 auto 0 0;width:90px;background:linear-gradient(90deg,var(--lav),rgba(246,247,253,0))}
.welcome .wrap{position:relative;display:grid;grid-template-columns:56fr 44fr;align-items:end}
.welcome .wcard{align-self:stretch}
.wcard{background:#fff;border:1px solid var(--line);padding:56px 48px}
.wcard h2{font-size:clamp(1.7rem,2.6vw,2.1rem);margin-bottom:16px}
.wcard p{font-size:.84rem;color:var(--muted);margin-bottom:12px;max-width:520px}
.stats{display:grid;grid-template-columns:repeat(4,1fr);gap:20px;margin-top:34px}
.stat b{display:block;font-weight:300;font-size:2.7rem;line-height:1;color:var(--navy);letter-spacing:-.02em}
.stat span{display:block;font-size:.68rem;color:var(--muted);margin-top:10px;line-height:1.4}
.wquote{position:relative;justify-self:end;width:min(290px,100%);margin-bottom:-40px;background:var(--navy);color:#fff;padding:26px 24px;display:flex;flex-direction:column;justify-content:center;box-shadow:0 24px 50px -24px rgba(16,18,74,.6)}
.wquote blockquote{font-family:"Young Serif",serif;font-size:.98rem;line-height:1.45;margin-bottom:18px}
.signature{font-size:.8rem;font-weight:500}
.signature small{display:block;color:var(--peri-2);font-size:.7rem;margin-top:4px;font-weight:400}

/* heritage */
.timeline{display:grid;grid-template-columns:repeat(6,1fr);gap:28px;border-top:1px solid var(--lav-3)}
.tl{position:relative;padding-top:30px}
.tl i{position:absolute;top:-7px;left:0;width:13px;height:13px;background:#fff;border:2px solid var(--peri)}
.tl.key i{background:var(--navy);border-color:var(--navy)}
.tl b{font-family:"Young Serif",serif;font-weight:400;font-size:1.6rem;color:var(--navy);display:block;line-height:1}
.tl p{font-size:.8rem;color:var(--muted);margin-top:12px;line-height:1.7}

/* events + news */
.ev-grid{display:grid;grid-template-columns:1fr 300px;gap:40px;align-items:start}
.ev-box{border:1px solid var(--line);padding:0 28px}
.event{display:grid;grid-template-columns:132px 1fr auto;gap:26px;padding:28px 0;border-bottom:1px solid var(--line);align-items:start}
.event:last-child{border-bottom:none}
.ev-thumb{height:100px;background:var(--navy);color:#fff;display:flex;flex-direction:column;align-items:center;justify-content:center}
.ev-thumb b{font-family:"Young Serif",serif;font-weight:400;font-size:2.2rem;line-height:1}
.ev-thumb span{font-size:.6rem;letter-spacing:.18em;text-transform:uppercase;color:var(--peri-2);margin-top:6px}
.ev-meta{display:flex;gap:10px;align-items:center;font-size:.74rem;color:var(--muted);margin-bottom:6px;flex-wrap:wrap}
.chip{background:var(--peri);color:var(--navy);padding:2px 8px;font-size:.68rem;font-weight:500}
.event h3{font-size:1.12rem;margin-bottom:4px}
.event p{font-size:.82rem;color:var(--muted)}
/* the title links to the event's details page; the link covers the whole row */
.event{position:relative}
.ev-link{color:inherit;transition:color .2s}
.ev-link:after{content:"";position:absolute;inset:0}
.event:hover .ev-link{color:var(--accent)}
.ev-link:focus-visible{outline:2px solid var(--peri);outline-offset:3px}
.ev-del{position:relative;z-index:1}
/* Featured event card: homepage "Upcoming Events" and the Events page (events.js) */
.ev-feature{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(0,1fr);margin-bottom:64px;border:1px solid var(--line);background:#fff;color:inherit;
  box-shadow:0 18px 40px -28px rgba(16,18,74,.35);transition:box-shadow .25s,transform .25s}
.ev-feature:hover{transform:translateY(-3px);box-shadow:0 26px 50px -26px rgba(16,18,74,.45)}
.ev-feature:focus-visible{outline:2px solid var(--peri);outline-offset:4px}
.ev-feature-img{background:var(--navy)}
.ev-feature-img img{display:block;width:100%;height:100%;object-fit:cover}
.ev-feature-body{display:flex;flex-direction:column;align-items:flex-start;justify-content:center;padding:clamp(28px,4vw,52px)}
.ev-feature-body h2{font-size:clamp(1.6rem,2.8vw,2.3rem);line-height:1.12;margin:6px 0 12px}
.ev-feature-when{font-size:.82rem;font-weight:700;letter-spacing:.04em;color:var(--accent);margin-bottom:12px}
.ev-feature-body p:not(.ev-feature-when){color:var(--muted);margin-bottom:26px}
.ev-feature:hover .btn{background:var(--navy);color:#fff}
.ev-actions{display:flex;gap:12px;margin-top:30px;flex-wrap:wrap}
.empty-note{padding:28px 0;color:var(--muted)}
.archive-note{font-size:.74rem;color:var(--muted);margin-top:14px;font-style:italic}
.news-box{border:1px solid var(--line);padding:26px 24px 10px}
.news-box .label{display:block;margin-bottom:6px}
.news{display:grid;grid-template-columns:58px 1fr;gap:14px;padding:18px 0;border-bottom:1px solid var(--line);align-items:center}
.news:last-child{border-bottom:none}
.news .ph{height:58px}
.news h4{font-family:"DM Sans",sans-serif;font-weight:700;font-size:.8rem;line-height:1.35;color:var(--navy)}
.news p{font-size:.72rem;color:var(--muted);line-height:1.5;margin-top:3px}
.news .tag{display:block;font-size:.56rem;font-weight:500;letter-spacing:.16em;text-transform:uppercase;color:var(--muted);margin-top:5px}
.news-more{text-align:center;margin-top:-18px;position:relative}

/* contact */
.contact-grid{display:grid;grid-template-columns:5fr 7fr;gap:32px;align-items:stretch}
.contact-card{background:#fff;border:1px solid var(--line);padding:44px 40px}
.contact-card h2{font-size:1.7rem;margin:0 0 26px}
.contact-row{display:flex;gap:14px;margin-bottom:16px;font-size:.88rem;color:var(--muted)}
.contact-row svg{width:18px;height:18px;flex:none;margin-top:3px;stroke:var(--accent);fill:none;stroke-width:1.6}
.contact-row b{display:block;color:var(--ink);font-size:.6rem;font-weight:700;letter-spacing:.18em;text-transform:uppercase}
.contact-form{margin-top:26px;display:grid;gap:12px}
input,textarea,select{width:100%;padding:13px 14px;border:1px solid var(--line);background:var(--lav);color:var(--ink);font:inherit;font-size:.88rem;border-radius:0}
input:focus,textarea:focus,select:focus{outline:2px solid var(--peri);outline-offset:-1px}
input::placeholder,textarea::placeholder{color:#9599ae}
.map{border:1px solid var(--line);min-height:440px;background:#fff}
.map iframe{width:100%;height:100%;min-height:440px;border:0;display:block;filter:saturate(.7)}

/* ad-style clickable slides (slider.js) */
.hs-slide[data-href]{cursor:pointer}
body.editing .hs-slide[data-href]{cursor:auto}

/* "From the Grand Lodge" — three learning boxes in a row (reuses .post cards) */
.learn-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:32px;align-items:stretch}
.learn-grid .post{display:flex;flex-direction:column}
@media (max-width:860px){.learn-grid{grid-template-columns:1fr;gap:48px;max-width:560px;margin:0 auto}}
/* four cards (one per "About us" menu item): 4 across, 2 on tablets, 1 on phones */
.learn-grid--4{grid-template-columns:repeat(4,minmax(0,1fr));gap:26px}
.learn-grid--4 .post-head{margin-right:28px;padding:18px 20px 4px}
.learn-grid--4 .post p{padding:10px 20px 0}
@media (max-width:1180px){.learn-grid--4{grid-template-columns:repeat(2,minmax(0,1fr));gap:48px 32px;max-width:900px;margin:0 auto}}
@media (max-width:640px){.learn-grid--4{grid-template-columns:1fr;max-width:480px}}
/* three portraits side by side in place of a card photo */
.post-trio{display:grid;grid-template-columns:repeat(3,1fr);gap:2px;height:var(--h,220px);background:var(--line)}
.post-trio img{width:100%;height:100%;object-fit:cover;object-position:50% 8%}

/* Banner slides (an image with its own text, e.g. the XVIII Conference banners).
   Desktop (1081px+): the banner fills the whole hero (edges trimmed to fit, like a
   cover photo). Tablets and phones: filling would cut away the wording, so the
   whole banner is shown full width over a blurred copy of itself. */
.hs-slide--banner:after{background:linear-gradient(0deg,rgba(10,6,30,.55) 0%,rgba(10,6,30,0) 22%)} /* keeps the controls readable */
.hs-slide--banner .hs-media,.hs-slide--banner.is-active .hs-media{filter:blur(28px) brightness(.62) saturate(1.15);transform:scale(1.2)}
.hs-banner{position:absolute;z-index:0;inset:0;width:100%;height:100%;object-fit:cover;object-position:var(--focus,50% 50%);
  opacity:0;transform:scale(1.04);transition:opacity .8s ease,transform 6s ease-out}
.hs-slide--banner.is-active .hs-banner{opacity:1;transform:none}
@media (max-width:1080px){
  .hs-slide--banner:after{display:none}
  .hs-banner{top:16px;left:0;width:100%;height:calc(100% - 16px - 84px);object-fit:contain;filter:drop-shadow(0 18px 30px rgba(0,0,0,.45))}
}
/* Desktop: the hero keeps a 2:1 shape (half the window's width), so the banners
   fill it with only their decorative edges trimmed at any screen size.
   --left keeps a banner's left side (e.g. the flags circle) in view. */
@media (min-width:1081px){
  .hero-slider{height:max(520px,50vw)}
  .hs-banner--left{object-position:15% 50%}
}
@media (prefers-reduced-motion:reduce){.hs-banner{transition:none;transform:none}}
