/* ============ Page-wide 3D depth scroll (scroll3d.js) ============
   Below the hero, every section moves in depth as you scroll:
   - blocks rise out of the screen with a perspective tilt (reveal),
   - photo / card grids tilt like a drum and glide at different speeds per column,
   - photo bands zoom while their text floats forward,
   - section headings rise layer by layer.
   Only compositor-friendly properties are used (translate / rotate / scale, opacity) and each
   frame JS writes just two variables, --s (position -1..1 through the viewport) and --a (|--s|),
   on the section container. Off for reduced-motion and Data Saver; phones get a lighter set
   (html.s3d-lite: no tilt, smaller moves). The hero keeps its own pinned 3D (hero-3d.js). */

/* ---------- 1. Reveal: blocks come forward out of the depth ---------- */
html.s3d-full.js [data-r]:not(:where(.event,.show,.shows,.time)){
  transform:perspective(1200px) translate3d(0,64px,-150px) rotateX(13deg);
  transform-origin:50% 100%;
  transition:opacity 1s var(--ease),transform 1.25s var(--ease);
  transition-delay:calc(var(--i,0)*110ms);
}
html.s3d-full.js [data-r].in{transform:none}
html.s3d-lite.js [data-r]:not(:where(.event,.show,.shows,.time)){transform:translate3d(0,40px,0) scale(.97)}
html.s3d-lite.js [data-r].in{transform:none}

/* ---------- 2. Section headings: eyebrow, title and lead rise at different speeds ---------- */
html.s3d-full .head>.eyebrow{translate:0 calc(var(--s,0)*-14px)}
html.s3d-full .head>h2{translate:0 calc(var(--s,0)*-26px)}
html.s3d-full .head>.lead{translate:0 calc(var(--s,0)*-38px)}

/* ---------- 3. About: photos sit on separate depth layers ---------- */
html.s3d-full .about-photos{perspective:1400px}
html.s3d-full .about-photos .ph{rotate:x calc(var(--s,0)*-6deg);transform-origin:50% 50%}
html.s3d-full .about-photos .ph:nth-child(1){translate:0 calc(var(--s,0)*-10px)}
html.s3d-full .about-photos .ph:nth-child(2){translate:0 calc(var(--s,0)*-22px)}
html.s3d-full .about-photos .ph:nth-child(3){translate:0 calc(var(--s,0)*-34px)}
html.s3d-full .about-photos .ph:nth-child(n+4){translate:0 calc(var(--s,0)*-46px)}
html.s3d-full .features{perspective:1000px}
html.s3d-full .features .feature{translate:0 calc(var(--s,0)*-16px);rotate:x calc(var(--s,0)*-5deg)}
html.s3d-full .features .feature:nth-child(2n){translate:0 calc(var(--s,0)*-34px)}
.about-photos.s3d-on .ph,.features.s3d-on .feature{will-change:translate,rotate}

/* ---------- 4. Photo bands: the picture zooms, the words float in front ---------- */
html.s3d .band .band-bg,html.s3d .res-bg{scale:calc(1.04 + (1 - var(--a,1))*.16);transform-origin:50% 50%}
html.s3d .band:hover .band-bg{scale:calc(1.04 + (1 - var(--a,1))*.16)}
html.s3d-full .band .band-inner{translate:0 calc(var(--s,0)*-44px);scale:calc(1 - var(--a,0)*.05)}
html.s3d-lite .band .band-inner{translate:0 calc(var(--s,0)*-20px)}
.band.s3d-on .band-bg,.reserve.s3d-on .res-bg{will-change:translate,scale}

/* ---------- 5. Menu cards and gallery: drum tilt, each column on its own speed ---------- */
html.s3d-full .menu-cat-grid,html.s3d-full .gal-grid{perspective:1500px}
html.s3d-full .menu-cat-grid .tcard,html.s3d-full .gal-grid .ph{
  rotate:x calc(var(--s,0)*-6deg);
  translate:0 calc(var(--s,0)*var(--k,1)*20px);
  transform-origin:50% 50%;
}
html.s3d-full .menu-cat-grid>:nth-child(4n+1),html.s3d-full .gal-grid>:nth-child(4n+1){--k:.4}
html.s3d-full .menu-cat-grid>:nth-child(4n+2),html.s3d-full .gal-grid>:nth-child(4n+2){--k:.8}
html.s3d-full .menu-cat-grid>:nth-child(4n+3),html.s3d-full .gal-grid>:nth-child(4n+3){--k:1.2}
html.s3d-full .menu-cat-grid>:nth-child(4n+4),html.s3d-full .gal-grid>:nth-child(4n+4){--k:1.6}
.menu-cat-grid.s3d-on .tcard,.gal-grid.s3d-on .ph{will-change:translate,rotate}

/* ---------- 6. Find us: the map comes forward from the picture ---------- */
html.s3d-full .loc{perspective:1400px}
html.s3d-full .loc .loc-map{translate:0 calc(var(--s,0)*-46px);rotate:x calc(var(--s,0)*-7deg)}
html.s3d-full .loc .loc-info{translate:0 calc(var(--s,0)*-22px)}

/* ---------- 7. About text, reviews, FAQ, footer ---------- */
html.s3d-full .about-grid>div:first-child>.eyebrow{translate:0 calc(var(--s,0)*-14px)}
html.s3d-full .about-grid>div:first-child>h2{translate:0 calc(var(--s,0)*-26px)}
html.s3d-full .about-grid>div:first-child>.lead{translate:0 calc(var(--s,0)*-38px)}

html.s3d-full .rvw{perspective:1400px}
html.s3d-full .rvw .rvHead{translate:0 calc(var(--s,0)*-26px)}
html.s3d-full .rvw .rvTrack{translate:0 calc(var(--s,0)*-18px);rotate:x calc(var(--s,0)*-4deg);transform-origin:50% 50%}

html.s3d-full .faq{perspective:1200px}
html.s3d-full .faq .eyebrow{translate:0 calc(var(--s,0)*-14px)}
html.s3d-full .faq .faq-title{translate:0 calc(var(--s,0)*-26px)}
html.s3d-full .faq .faq-list{translate:0 calc(var(--s,0)*-30px);rotate:x calc(var(--s,0)*-4deg);transform-origin:50% 50%}

html.s3d-full .ft-grid>*{translate:0 calc(var(--s,0)*-18px)}

.rvw.s3d-on .rvTrack,.faq.s3d-on .faq-list{will-change:translate,rotate}

/* ---------- 8. Depth glow: a background plane that moves slower than the content ---------- */
html.s3d-full :is(.section.about,.events,.gallery,.visit,.faq){isolation:isolate}
html.s3d-full :is(.section.about,.events,.gallery,.visit,.faq)::after{
  content:'';position:absolute;z-index:-1;pointer-events:none;
  width:70vmax;height:70vmax;left:var(--gx,60%);top:20%;margin:-35vmax 0 0 -35vmax;border-radius:50%;
  background:radial-gradient(closest-side,rgba(154,182,186,.14),rgba(63,84,86,.08) 55%,transparent);
  translate:0 calc(var(--s,0)*28vh);
}
html.s3d-full .events{--gx:30%}
html.s3d-full .visit{--gx:75%}
html.s3d-full .gallery{--gx:20%}
html.s3d-full .faq{--gx:70%}

/* ---------- Native scroll-driven version (Chrome, Edge, Safari 26+) ----------
   Same movement as the --s variables above, but run by the browser on the compositor with
   animation-timeline: view() instead of by JavaScript on every scroll frame. scroll3d.js skips its
   loop when this is supported (it adds html.s3d-native); Firefox keeps the JS version. The timeline
   runs from "just entering at the bottom" (= --s of +1) to "just leaving at the top" (= -1). */
@supports (animation-timeline: view()) {
  html.s3d-native :is(.about-photos,.features,.band,.reserve,.menu-cat-grid,.gal-grid,.loc,.head,.about-grid>div:first-child,.rvw,.faq,.ft-grid,.events,.gallery,.visit,.section.about){view-timeline:--sec block}

  @keyframes s3d-slide{from{translate:0 var(--s3y,0px);rotate:x var(--s3r,0deg)}to{translate:0 calc(var(--s3y,0px)*-1);rotate:x calc(var(--s3r,0deg)*-1)}}
  @keyframes s3d-zoom{0%,100%{scale:1.04}50%{scale:1.2}}
  @keyframes s3d-float{from{translate:0 var(--s3y,0px);scale:.95}50%{translate:0 0;scale:1}to{translate:0 calc(var(--s3y,0px)*-1);scale:.95}}

  html.s3d-native .head>.eyebrow,html.s3d-native .head>h2,html.s3d-native .head>.lead,
  html.s3d-native .about-photos .ph,html.s3d-native .features .feature,
  html.s3d-native .menu-cat-grid .tcard,html.s3d-native .gal-grid .ph,
  html.s3d-native .loc .loc-map,html.s3d-native .loc .loc-info{animation:s3d-slide linear both;animation-timeline:--sec;animation-range:cover 0% cover 100%}
  html.s3d-native .about-grid>div:first-child>:is(.eyebrow,h2,.lead),
  html.s3d-native .rvw .rvHead,html.s3d-native .rvw .rvTrack,
  html.s3d-native .faq .eyebrow,html.s3d-native .faq .faq-title,html.s3d-native .faq .faq-list,
  html.s3d-native .ft-grid>*{animation:s3d-slide linear both;animation-timeline:--sec;animation-range:cover 0% cover 100%}
  html.s3d-native .band .band-bg,html.s3d-native .res-bg{animation:s3d-zoom linear both;animation-timeline:--sec;animation-range:cover 0% cover 100%}
  html.s3d-native .band .band-inner{animation:s3d-slide linear both;animation-timeline:--sec;animation-range:cover 0% cover 100%}
  html.s3d-native.s3d-full .band .band-inner{animation-name:s3d-float}

  /* amounts: the same numbers as the variable version */
  html.s3d-native .head>.eyebrow{--s3y:-14px}
  html.s3d-native .head>h2{--s3y:-26px}
  html.s3d-native .head>.lead{--s3y:-38px}
  html.s3d-native .about-photos .ph{--s3r:-6deg}
  html.s3d-native .about-photos .ph:nth-child(1){--s3y:-10px}
  html.s3d-native .about-photos .ph:nth-child(2){--s3y:-22px}
  html.s3d-native .about-photos .ph:nth-child(3){--s3y:-34px}
  html.s3d-native .about-photos .ph:nth-child(n+4){--s3y:-46px}
  html.s3d-native .features .feature{--s3y:-16px;--s3r:-5deg}
  html.s3d-native .features .feature:nth-child(2n){--s3y:-34px}
  html.s3d-native .menu-cat-grid .tcard,html.s3d-native .gal-grid .ph{--s3y:calc(var(--k,1)*20px);--s3r:-6deg}
  html.s3d-native .loc .loc-map{--s3y:-46px;--s3r:-7deg}
  html.s3d-native .loc .loc-info{--s3y:-22px}
  html.s3d-native .about-grid>div:first-child>.eyebrow{--s3y:-14px}
  html.s3d-native .about-grid>div:first-child>h2{--s3y:-26px}
  html.s3d-native .about-grid>div:first-child>.lead{--s3y:-38px}
  html.s3d-native .rvw .rvHead{--s3y:-26px}
  html.s3d-native .rvw .rvTrack{--s3y:-18px;--s3r:-4deg}
  html.s3d-native .faq .eyebrow{--s3y:-14px}
  html.s3d-native .faq .faq-title{--s3y:-26px}
  html.s3d-native .faq .faq-list{--s3y:-30px;--s3r:-4deg}
  html.s3d-native .ft-grid>*{--s3y:-18px}
  html.s3d-native.s3d-full .band .band-inner{--s3y:-44px}
  html.s3d-native.s3d-lite .band .band-inner{--s3y:-20px}
  /* head effects, tiles and the map are desktop-only (phones: reveal + band moves) */
  html.s3d-native.s3d-lite :is(.head>*,.about-photos .ph,.features .feature,.menu-cat-grid .tcard,.gal-grid .ph,.loc .loc-map,.loc .loc-info,
    .about-grid>div:first-child>*,.rvw .rvHead,.rvw .rvTrack,.faq .eyebrow,.faq .faq-title,.faq .faq-list,.ft-grid>*){animation:none}
  @keyframes s3d-glow{from{translate:0 28vh}to{translate:0 -28vh}}
  html.s3d-native :is(.section.about,.events,.gallery,.visit,.faq)::after{
    animation:s3d-glow linear both;animation-timeline:--sec;animation-range:cover 0% cover 100%;
  }
}

@media (prefers-reduced-motion:reduce){
  html.s3d *{translate:none!important;rotate:none!important}
}

/* ---------- Interactive layer (interact3d.js): pointer tilt + scroll-velocity lean ----------
   Uses the separate `transform` property, so it adds to the scroll animation (translate / rotate / scale). */
html.s3d-full :is(.menu-cat-grid .tcard,.gal-grid .ph,.about-photos .ph,.features .feature){
  transform:perspective(900px) rotateX(calc(var(--ix,0deg) + var(--vel,0)*-2.2deg)) rotateY(var(--iy,0deg)) translateZ(0)!important;
}
html.s3d-full .loc .loc-map{transform:perspective(1000px) rotateX(var(--ix,0deg)) rotateY(var(--iy,0deg))!important}
html.s3d-full .tilt-on{will-change:transform;}
/* the spring in JS does the easing, so drop any CSS transform transition on these */
html.s3d-full .features .feature{transition:border-color .4s}
html.perf-1 :is(.menu-cat-grid .tcard,.gal-grid .ph,.about-photos .ph,.features .feature,.loc .loc-map){transform:none!important}
html.perf-1 :is(.section.about,.events,.gallery,.visit,.faq)::after{display:none}

/* table availability note under the reserve form's date / time row */
.rb-avail{margin:2px 0 10px;padding:9px 14px;border-radius:12px;font-size:13px;line-height:1.4;background:rgba(215,170,90,.14);color:var(--cream,#fbf7e2);border:1px solid rgba(215,170,90,.4)}
.rb-avail[data-st=x]{background:rgba(200,80,70,.14);border-color:rgba(200,80,70,.45)}
.rb-avail[hidden]{display:none}
