/* Khaliswala: cinematic scroll scenes for the home page.
   Works with assets/js/cinema.js, which writes --p (0..1 scroll progress) on each [data-cine] block.
   Without JS or with "reduce motion", html has no .cine class and everything falls back to a normal stacked page. */

:root{--grain:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 .55 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>")}

/* ---------- shared bits (always on) ---------- */
.hero-dim{position:absolute;inset:0;z-index:1;background:#0b2412;opacity:0;pointer-events:none}
.hero-cap,.scroll-cue{display:none}
.pg-home .chap{padding:0;background:#0d2616;color:#fff}
.scene{position:relative;min-height:80vh;min-height:80svh;display:flex;align-items:center;overflow:hidden;padding:90px 0}
.scene .bgp{position:absolute;inset:0}
.scene .bgp img{top:0;height:100%}
.scene::before{content:"";position:absolute;inset:0;z-index:1;background:linear-gradient(90deg,rgba(8,28,14,.82),rgba(8,28,14,.38) 62%,rgba(8,28,14,.55))}
.scene::after{content:"";position:absolute;inset:0;z-index:1;pointer-events:none;background:radial-gradient(ellipse at 50% 45%,transparent 52%,rgba(0,0,0,.5)),var(--grain);background-size:auto,180px}
.scene-in{position:relative;z-index:2;width:100%;display:grid;grid-template-columns:1.1fr .9fr;gap:48px;align-items:center}
.scene.solo .scene-in{grid-template-columns:1fr}
.scene-txt{max-width:560px}
.scene .eyebrow{color:#e8d9b8}
.scene h2{color:#fff;font-size:clamp(2.6rem,7vw,5.2rem);line-height:1.02;margin-bottom:.35em}
.scene h2 em{color:#c6ec9a}
.scene p{font-size:clamp(1.05rem,2vw,1.3rem);color:#eef2e6;margin:0 0 26px;max-width:46ch}
.scene-prod{margin:0;justify-self:center;width:min(380px,100%);aspect-ratio:4/5;border-radius:28px;overflow:hidden;box-shadow:0 40px 80px rgba(0,0,0,.45);background:#14411f}
.scene-prod img{width:100%;height:100%;object-fit:cover;display:block}
.chap-nav{display:none}
.words span{display:inline}
@media(max-width:860px){
  .scene-in{grid-template-columns:1fr;gap:26px}
  .scene-prod{width:min(190px,48vw);aspect-ratio:1;order:-1;justify-self:start;border-radius:22px}
}

/* ---------- cinematic mode ---------- */
html.cine .cine-hero{height:230vh;height:230svh;position:relative}
html.cine .cine-hero .hero{position:sticky;top:0;height:100vh;height:100svh;min-height:0}
html.cine .cine-hero .hero .wrap{will-change:transform,opacity}
html.cine .cine-hero.past .hero .wrap{visibility:hidden}
html.cine .hero-cap{display:block;position:absolute;z-index:3;left:0;right:0;top:50%;margin:0;padding:0 24px;text-align:center;color:#fff;font:700 clamp(2.2rem,7vw,5.4rem)/1.05 "Playfair Display",Georgia,serif;letter-spacing:-.01em;text-shadow:0 4px 40px rgba(0,0,0,.45);
  opacity:0;transform:translateY(-50%);will-change:opacity}
html.cine .hero-cap em{color:#c6ec9a}
html.cine .scroll-cue{display:flex;position:absolute;z-index:3;left:50%;bottom:78px;transform:translateX(-50%);flex-direction:column;align-items:center;gap:10px;color:#fff;font:600 .72rem Manrope,sans-serif;letter-spacing:.2em;text-transform:uppercase}
html.cine .scroll-cue i{width:1px;height:46px;background:rgba(255,255,255,.35);position:relative;overflow:hidden}
html.cine .scroll-cue i::after{content:"";position:absolute;left:0;top:-40%;width:1px;height:40%;background:#fff;animation:cue 1.8s cubic-bezier(.6,0,.3,1) infinite}
@keyframes cue{to{top:100%}}

/* chapter: three pinned scenes that crossfade and push in */
html.cine .chap{height:400vh;height:calc(var(--n,3)*100svh + 100svh);overflow:clip}
html.cine .chap-stick{position:sticky;top:0;height:100vh;height:100svh;overflow:hidden;isolation:isolate}
html.cine .scene{position:absolute;inset:0;min-height:0;padding:0;opacity:0;will-change:opacity}
html.cine .scene:first-of-type{opacity:1}
html.cine .scene.off{visibility:hidden}
html.cine .scene .bgp img{transform-origin:50% 55%;transform:scale(1.06);will-change:transform}
html.cine .scene-in{height:100%;padding-top:70px}
html.cine .scene-txt{will-change:transform,opacity}
html.cine .scene-prod{will-change:transform,opacity}
html.cine .scene .btn{pointer-events:auto}
html.cine .scene:not(.on){pointer-events:none}
html.cine .chap-nav{display:grid;gap:6px;position:absolute;z-index:5;right:clamp(10px,2.2vw,28px);top:50%;transform:translateY(-50%)}
.chap-nav button{display:flex;align-items:center;justify-content:flex-end;gap:10px;background:none;border:0;padding:6px 0;color:rgba(255,255,255,.62);font:700 .72rem Manrope,sans-serif;letter-spacing:.16em;text-transform:uppercase;cursor:pointer}
.chap-nav button::after{content:"";width:9px;height:9px;border-radius:50%;border:1.5px solid currentColor;transition:background .3s,transform .3s}
.chap-nav button span{opacity:0;transform:translateX(6px);transition:opacity .3s,transform .3s}
.chap-nav button:hover span,.chap-nav button:focus-visible span,.chap-nav button.on span{opacity:1;transform:none}
.chap-nav button.on{color:#fff}.chap-nav button.on::after{background:#c6ec9a;border-color:#c6ec9a;transform:scale(1.35)}
.chap-nav button:focus-visible{outline:2px solid #c6ec9a;outline-offset:4px;border-radius:6px}
@media(max-width:860px){
  html.cine .scene-in{align-content:center;padding-top:76px}
  html.cine .scene-prod{width:min(150px,38vw)}
  html.cine .chap-nav button span{display:none}
}

/* band: pinned, background pushes in, the paragraph lights up word by word */
html.cine .cine-band{height:270vh;height:270svh;position:relative}
html.cine .cine-band .band{position:sticky;top:0;height:100vh;height:100svh;min-height:0;padding:0}
html.cine .cine-band .band .wrap{padding:0 20px;width:100%}
html.cine .cine-band .bgp img{transform-origin:50% 50%;will-change:transform}
html.cine .cine-band .band::before{background:rgba(12,40,20,.66)}
html.cine .cine-band .band::after{content:"";position:absolute;inset:0;z-index:1;pointer-events:none;background:radial-gradient(ellipse at 50% 50%,transparent 45%,rgba(0,0,0,.5)),var(--grain);background-size:auto,180px}
html.cine .cine-band h2{transform-origin:50% 60%;will-change:transform}
html.cine .band .words{max-width:780px;font:600 clamp(1.25rem,2.8vw,2rem)/1.5 Manrope,sans-serif;margin:18px auto 0;text-wrap:balance}
html.cine .band .words span{opacity:.16}

/* our story photo drifts inside its frame */
html.cine .stack .im img{transition:none;will-change:transform}

/* brand philosophy: Khalis Khao / Pakao / Lagao pillars */
.kk{display:grid;grid-template-columns:repeat(3,1fr);gap:0 44px;width:100%;max-width:940px;margin:40px auto 0;text-align:left}
.kk-c{position:relative;display:flex;flex-direction:column;padding:18px 0 4px;color:#fff;border-top:1px solid rgba(255,255,255,.38);transition:border-color .3s}
.kk-c small{font:600 .72rem Manrope,sans-serif;letter-spacing:.2em;text-transform:uppercase;color:#c6ec9a}
.kk-c b{margin-top:2px;color:#c6ec9a;font:italic 600 clamp(2rem,3.8vw,2.9rem)/1.08 'Playfair Display',Georgia,serif}
.kk-c span{margin-top:8px;font-size:.95rem;line-height:1.45;color:#e4ecd9}
.kk-c em{margin-top:16px;display:inline-flex;align-items:center;gap:8px;font:600 .86rem Manrope,sans-serif;font-style:normal;color:#e8d9b8;transition:color .3s,gap .3s}
.kk-c em .i{width:15px;height:15px}
.kk-c:hover,.kk-c:focus-visible{border-top-color:#c6ec9a;outline:none}
.kk-c:hover em,.kk-c:focus-visible em{color:#c6ec9a;gap:13px}
@media(max-width:700px){.kk{grid-template-columns:1fr;gap:0;margin-top:26px;max-width:420px}.kk-c{flex-direction:row;align-items:baseline;flex-wrap:wrap;column-gap:10px;padding:14px 0}.kk-c small{display:none}.kk-c b{font-size:1.7rem;margin:0}.kk-c span{flex:1 1 100%;order:3;margin-top:2px;font-size:.88rem}.kk-c em{margin:0 0 0 auto;order:2;font-size:.8rem}}

/* ---------- phones: brand philosophy replaces the khao/pakao/lagao scenes, right after the hero ---------- */
.band-m{display:none}
@media(max-width:860px){
  .band-m{display:block}
  .chap-d,.band-d{display:none}
  .band-m .band{min-height:0}
  .band-m .band .wrap{padding:56px 20px 52px}
  .band-m .kk-c small{display:inline;order:0;font:italic 600 1.7rem/1.2 'Playfair Display',Georgia,serif;letter-spacing:0;text-transform:none;color:#c6ec9a;margin-right:-2px}
  .band-m .kk-c b{order:1}
}
