/* Full-screen pages (chapters) and the reveal-on-scroll base.
   Loaded in number order by templates/site.php (order matters: later files win). */
/* ===== chapters: flowing sections; each one rises out of depth as it scrolls in and drifts away as it leaves ===== */
.anchor{display:block;height:0;position:relative;top:-8px}
.chapter{position:relative;border-radius:34px 34px 0 0;margin-top:-34px;--p:0}
.chapter + .anchor + .chapter::after{content:"";position:absolute;left:0;right:0;top:-36px;height:36px;pointer-events:none;border-radius:34px 34px 0 0;
  background:linear-gradient(to top,rgba(0,0,0,.45),transparent)}
.chapter::before{content:"";position:absolute;left:8%;right:8%;top:0;height:1px;z-index:6;pointer-events:none;
  background:linear-gradient(90deg,transparent,rgba(226,189,120,.55),transparent)}
.chapter:first-of-type::before{display:none}
.chapter:first-of-type{border-radius:0;box-shadow:none;margin-top:0}
/* the flag ribbon ends the home page: the next page must not overlap it */
.c-home + .anchor + .chapter{margin-top:0}
.c-home + .anchor + .chapter::after{display:none}
.flags{z-index:3}
.ch-in{position:relative;min-height:100svh;display:flex;flex-direction:column;justify-content:center;padding:calc(var(--head) + 40px) 0 80px;border-radius:inherit;overflow:hidden}
/* --p: -1 = page is one screen below, 0 = page fills the screen, +1 = page has scrolled one screen up.
   The content glides a little slower than the page (parallax) and fades at the edges. Pure translate + opacity: crisp text, GPU-cheap. */
/* page content itself is never transformed (keeps text and photos pixel-sharp); the glide comes from the scroll, the life from the reveals */
/* gold edge light on the page that is arriving */
.ch-in::before{content:"";position:absolute;left:0;right:0;top:0;height:40%;pointer-events:none;
  background:linear-gradient(180deg,rgba(226,189,120,.16),transparent);opacity:calc(max(0, var(--p) * -1));will-change:opacity}
.c-home .ch-in::before{display:none}
.c-home .ch-in{background:radial-gradient(1000px 700px at 78% 30%,rgba(226,189,120,.13),transparent 60%),radial-gradient(900px 700px at 0% 100%,rgba(31,95,128,.35),transparent 60%),linear-gradient(180deg,#081d2e,#05162a)}
.c-branches .ch-in{background:radial-gradient(900px 600px at 10% 10%,rgba(31,95,128,.38),transparent 60%),linear-gradient(180deg,#0a2234,#06182a)}
.c-reviews .ch-in{background:radial-gradient(800px 600px at 70% 40%,rgba(226,189,120,.14),transparent 62%),linear-gradient(180deg,#0c273c,#081d2e)}
.c-about .ch-in{background:radial-gradient(900px 700px at 90% 80%,rgba(31,95,128,.4),transparent 60%),linear-gradient(180deg,#0a2234,#061829)}
.c-faq .ch-in{background:radial-gradient(900px 600px at 20% 0%,rgba(226,189,120,.1),transparent 60%),linear-gradient(180deg,#0b2438,#041120);justify-content:flex-start}
.ch-head{max-width:760px;margin-bottom:clamp(30px,4vw,52px)}
.ch-head p{color:var(--mist);margin-top:18px;font-size:21px;max-width:52ch}
.ch-head p.kicker{margin:0 0 22px;font-size:18px;color:var(--gold)}

/* reveal on scroll: replays each time a block scrolls back into view */
[data-r]{opacity:0;transition:opacity .7s cubic-bezier(.22,.61,.36,1),transform .8s var(--ease);transition-delay:calc(var(--i,0) * 80ms)}
[data-r="rise"]{transform:translate3d(0,36px,0)}
[data-r="left"]{transform:translate3d(-40px,0,0)}
[data-r="right"]{transform:translate3d(40px,0,0)}
[data-r="zoom"]{transform:translate3d(0,24px,0)}
[data-r].in{opacity:1;transform:none}
/* headings rise word by word from behind a hairline */
.ww{display:inline-block;overflow:hidden;vertical-align:bottom;padding:0 .02em;margin:0 -.02em}
.ww > i{display:inline-block;font-style:normal;transform:translate3d(0,110%,0);transition:transform .8s cubic-bezier(.2,.8,.2,1);transition-delay:calc(var(--j,0) * 55ms + 100ms)}
.in .ww > i{transform:none}
.kicker::before{transform-origin:0 50%;transform:scaleX(0);transition:transform .9s var(--ease) .1s}
.in.kicker::before,.in .kicker::before{transform:none}

