/* Hotkhana — scroll motion system (pairs with /js/motion.js).
   Everything here only applies once motion.js adds .m-on to <html>, so the page is fully visible without JS,
   and nothing animates for visitors who ask their device to reduce motion. */
:root { --m-ease: cubic-bezier(.2, .8, .2, 1); --m-pop: cubic-bezier(.34, 1.56, .64, 1); --m-dur: .9s; }

/* ---------- scroll progress bar ---------- */
.m-progress { position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 9999; pointer-events: none;
  background: linear-gradient(90deg, #ff4f1f, #ffb020); transform-origin: 0 50%; transform: scaleX(var(--sp, 0)); }

/* ---------- base: hidden until in view ---------- */
.m-on .m { transition: opacity var(--m-dur) var(--m-ease), transform var(--m-dur) var(--m-ease), filter var(--m-dur) var(--m-ease), clip-path 1.1s var(--m-ease);
  transition-delay: var(--d, 0s); will-change: transform, opacity; }
.m-on .m.is-in { will-change: auto; }

/* rise: fade up out of a soft blur */
.m-on .m-rise:not(.is-in) { opacity: 0; transform: translate3d(0, 46px, 0); filter: blur(8px); }
/* slide in from the sides */
.m-on .m-left:not(.is-in) { opacity: 0; transform: translate3d(-90px, 0, 0) rotate(-2deg); }
.m-on .m-right:not(.is-in) { opacity: 0; transform: translate3d(90px, 0, 0) rotate(2deg); }
/* pop: scale up with overshoot */
.m-on .m-pop { transition-timing-function: var(--m-pop); }
.m-on .m-pop:not(.is-in) { opacity: 0; transform: scale(.55) rotate(-8deg); }
/* zoom: big and blurred, settling into place */
.m-on .m-zoom:not(.is-in) { opacity: 0; transform: scale(1.18); filter: blur(10px); }

/* headline words rise from behind a mask */
.m-on .m-split .m-w { display: inline-block; overflow: hidden; vertical-align: top; padding: .06em .02em .1em; margin: -.06em -.02em -.1em; }
.m-on .m-split .m-w > span { display: inline-block; transition: transform 1s var(--m-ease), opacity 1s var(--m-ease); transition-delay: calc(var(--d, 0s) + var(--i) * 60ms); }
.m-on .m-split:not(.is-in) .m-w > span { transform: translate3d(0, 110%, 0) rotate(6deg); opacity: 0; }

/* images: curtain wipe + settle from a zoom (direction set per image) */
.m-on .m-wipe { transition: clip-path 1.2s var(--m-ease), transform 1.6s var(--m-ease), filter 1.2s var(--m-ease); transition-delay: var(--d, 0s); }
.m-on .m-wipe:not(.is-in) { transform: scale(1.22); filter: saturate(.3) brightness(1.1); }
.m-on .m-wipe.m-up:not(.is-in) { clip-path: inset(100% 0 0 0); }
.m-on .m-wipe.m-lr:not(.is-in) { clip-path: inset(0 100% 0 0); }
.m-on .m-wipe.m-rl:not(.is-in) { clip-path: inset(0 0 0 100%); }
.m-on .m-wipe.m-iris:not(.is-in) { clip-path: circle(0% at 50% 50%); }
.m-on .m-wipe.is-in { clip-path: inset(0 0 0 0); }
.m-on .m-wipe.m-iris.is-in { clip-path: circle(75% at 50% 50%); }

/* cards: dealt out of a stacked deck at the grid's centre (offsets set by JS) */
.m-on .m-deal { transition: opacity .7s var(--m-ease), transform 1.15s cubic-bezier(.16, 1.1, .3, 1); transition-delay: var(--d, 0s); }
.m-on .m-deal:not(.is-in) { opacity: 0; transform: translate3d(var(--dx, 0), var(--dy, 60px), 0) rotate(var(--rot, 0deg)) scale(.82); }
.m-on .m-deal.is-in { z-index: auto; }

/* icons: flip in on the Y axis, spin again when their card is hovered */
.m-on .m-flip { transition: transform 1.1s var(--m-pop), opacity .6s var(--m-ease); transition-delay: var(--d, 0s); transform-style: preserve-3d; }
.m-on .m-flip:not(.is-in) { opacity: 0; transform: perspective(600px) rotateY(-200deg) scale(.4); }
@keyframes m-spinY { from { transform: perspective(600px) rotateY(0); } to { transform: perspective(600px) rotateY(360deg); } }
.m-hoverspin:hover .m-flip.is-in, .m-flip.is-in:hover { animation: m-spinY .9s var(--m-ease); }

/* hover tilt for cards (JS sets --rx/--ry) */
.m-tilt { transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: transform .5s var(--m-ease); }
.m-tilt.m-deal.is-in { transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); }

/* parallax drift (JS sets --py) */
.m-px { transform: translate3d(0, var(--py, 0px), 0) scale(var(--ps, 1.08)); }

/* ---------- hero: real food photos slide in, tilt and drift with scroll ---------- */
.hk-hero-photos { position: absolute; inset: 0; z-index: 5; pointer-events: none; }
.hk-polaroid { position: absolute; width: clamp(150px, 15vw, 230px); padding: 8px 8px 26px; background: #fff; border-radius: 14px;
  box-shadow: 0 30px 60px -20px rgba(0,0,0,.55); transform: translate3d(0, var(--py, 0px), 0) rotate(var(--r)); }
.hk-polaroid img { width: 100%; aspect-ratio: 4/5; object-fit: cover; border-radius: 8px; display: block; }
.hk-polaroid figcaption { position: absolute; left: 0; right: 0; bottom: 5px; text-align: center; font: 600 11px/1.2 Inter, system-ui, sans-serif; color: #6b7280; }
.hk-polaroid--a { left: 2.5%; top: 14%; --r: -9deg; }
.hk-polaroid--b { left: 11%; bottom: 3%; --r: 7deg; width: clamp(110px, 10vw, 160px); }
.hk-polaroid--c { right: 2.5%; top: 12%; --r: 8deg; }
.hk-polaroid--d { right: 11%; bottom: 3%; --r: -6deg; width: clamp(110px, 10vw, 160px); }
.m-on .hk-polaroid { transition: opacity 1s var(--m-ease), transform 1.4s cubic-bezier(.16, 1.1, .3, 1); transition-delay: var(--d, 0s); }
.m-on .hk-polaroid:not(.is-in) { opacity: 0; transform: translate3d(var(--fx, 0), 80px, 0) rotate(calc(var(--r) * -3)) scale(.7); }
.hk-polaroid--a, .hk-polaroid--b { --fx: -160px; } .hk-polaroid--c, .hk-polaroid--d { --fx: 160px; }
@media (max-width: 1100px) { .hk-hero-photos { display: none; } }

/* ---------- device showpiece: laptop lid opens, phone spins in, labels slide out ---------- */
.hk-devices { position: relative; max-width: 540px; margin: 0 auto; padding: 30px 0 60px; perspective: 1600px; }
.hk-devices__stage { position: relative; transform-style: preserve-3d; transform: rotateY(var(--sy, 0deg)) rotateX(var(--sx, 0deg)); transition: transform .2s linear; }
.hk-laptop { position: relative; width: 88%; transform-style: preserve-3d; }
.hk-laptop__lid { position: relative; background: #1d1d1f; border-radius: 16px 16px 4px 4px; padding: 12px 12px 14px; transform-origin: 50% 100%;
  box-shadow: 0 30px 60px -20px rgba(0,0,0,.6); }
.hk-laptop__screen { position: relative; aspect-ratio: 16/10; overflow: hidden; border-radius: 6px; background: #fff; }
.hk-laptop__screen img { width: 100%; display: block; animation: hk-scrollshot 26s ease-in-out infinite alternate; }
@keyframes hk-scrollshot { 0%, 8% { transform: translateY(0); } 92%, 100% { transform: translateY(calc(-100% + 300px)); } }
.hk-laptop__base { height: 14px; margin: 0 -6%; background: linear-gradient(#d4d4d8, #a1a1aa); border-radius: 0 0 14px 14px; position: relative; }
.hk-laptop__base::after { content: ""; position: absolute; left: 42%; right: 42%; top: 0; height: 5px; background: #8b8b93; border-radius: 0 0 6px 6px; }
.hk-phone { position: absolute; right: 1%; bottom: 10px; width: 31%; aspect-ratio: 9/19; background: #111; border-radius: 30px; padding: 7px;
  box-shadow: 0 40px 70px -24px rgba(0,0,0,.7), inset 0 0 0 2px #333; transform: translateZ(60px); }
.hk-phone__screen { position: relative; width: 100%; height: 100%; border-radius: 24px; overflow: hidden; background: #000; }
.hk-phone__screen video, .hk-phone__screen img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hk-phone__notch { position: absolute; top: 12px; left: 50%; width: 34%; height: 16px; transform: translateX(-50%); background: #111; border-radius: 10px; z-index: 2; }
.hk-float { position: absolute; z-index: 3; display: inline-flex; align-items: center; gap: 7px; background: #fff; color: #2a2a2a; border-radius: 999px;
  padding: 9px 14px; font: 700 12.5px/1 Inter, system-ui, sans-serif; white-space: nowrap; box-shadow: 0 16px 34px -12px rgba(0,0,0,.45); transform: translateZ(90px); }
.hk-float i { font-style: normal; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: #ff4f1f; color: #fff; font-size: 11px; }
.hk-float--green i { background: #1fa855; }
.hk-float--a { left: -4%; top: 6%; } .hk-float--b { right: 18%; top: -4%; } .hk-float--c { left: -6%; bottom: 26%; } .hk-float--d { right: 2%; bottom: -2%; }
@media (max-width: 640px) { .hk-float--a { left: 0; } .hk-float--c { left: 0; } .hk-float--d { right: 0; } }
/* entry choreography */
.m-on .hk-devices .hk-laptop__lid { transition: transform 1.5s cubic-bezier(.2, .9, .2, 1) .1s; }
.m-on .hk-devices:not(.is-in) .hk-laptop__lid { transform: rotateX(-95deg); }
.m-on .hk-devices .hk-laptop { transition: transform 1.2s var(--m-ease), opacity .8s var(--m-ease); }
.m-on .hk-devices:not(.is-in) .hk-laptop { transform: translateY(60px) rotateX(18deg); opacity: 0; }
.m-on .hk-devices .hk-phone { transition: transform 1.6s cubic-bezier(.16, 1.05, .3, 1) .55s, opacity .8s var(--m-ease) .55s; }
.m-on .hk-devices:not(.is-in) .hk-phone { transform: translate3d(260px, 40px, 60px) rotateY(-300deg) rotateZ(14deg); opacity: 0; }
.m-on .hk-devices .hk-float { transition: transform 1s var(--m-pop), opacity .5s var(--m-ease); transition-delay: calc(1.3s + var(--i) * .18s); }
.m-on .hk-devices:not(.is-in) .hk-float { transform: translate3d(var(--fx, 0), var(--fy, 0), 0) scale(.2); opacity: 0; }
.hk-float--a { --fx: 160px; --fy: 120px; } .hk-float--b { --fx: -60px; --fy: 160px; } .hk-float--c { --fx: 200px; --fy: -40px; } .hk-float--d { --fx: -140px; --fy: -100px; }
/* idle float once in */
@keyframes hk-bob { 50% { translate: 0 -8px; } }
.hk-devices.is-in .hk-phone { animation: hk-bob 5s ease-in-out 2.4s infinite; }
.hk-devices.is-in .hk-float { animation: hk-bob 4s ease-in-out infinite; animation-delay: calc(2.6s + var(--i) * .5s); }

/* ---------- respect reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .hk-laptop__screen img, .hk-devices.is-in .hk-phone, .hk-devices.is-in .hk-float { animation: none !important; }
  .m-progress { display: none; }
}

/* =========================================================
   Showpieces for inner pages (each replays whenever its section comes back into view)
   ========================================================= */

/* ---------- reel wall: three phones dealt out of one, playing real reels ---------- */
.hk-reels { position: relative; height: clamp(440px, 44vw, 580px); display: flex; align-items: center; justify-content: center; perspective: 1400px; }
.hk-reel { position: absolute; width: clamp(160px, 16vw, 228px); aspect-ratio: 9/19; margin: 0; background: #111; border-radius: 30px; padding: 7px;
  box-shadow: 0 40px 70px -24px rgba(0,0,0,.65), inset 0 0 0 2px #333; transition: transform 1.3s cubic-bezier(.16, 1.05, .3, 1), opacity .7s ease; }
.hk-reel__s { position: relative; width: 100%; height: 100%; border-radius: 24px; overflow: hidden; background: #000; }
.hk-reel__s video, .hk-reel__s img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hk-reel__s::before { content: ""; position: absolute; top: 10px; left: 50%; width: 34%; height: 15px; transform: translateX(-50%); background: #111; border-radius: 10px; z-index: 2; }
.hk-reel figcaption { position: absolute; left: 0; right: 0; bottom: -34px; text-align: center; font: 600 12.5px/1.2 Inter, system-ui, sans-serif; color: inherit; opacity: .8; }
.hk-reel--c { z-index: 3; transform: translateY(-3%); transition-delay: .05s; }
.hk-reel--l { z-index: 2; transform: translateX(-66%) rotate(-8deg) scale(.86); transition-delay: .45s; }
.hk-reel--r { z-index: 2; transform: translateX(66%) rotate(8deg) scale(.86); transition-delay: .55s; }
.m-on .hk-reels:not(.is-in) .hk-reel--c { transform: translateY(70px) rotateY(-200deg) scale(.6); opacity: 0; }
.m-on .hk-reels:not(.is-in) .hk-reel--l, .m-on .hk-reels:not(.is-in) .hk-reel--r { transform: translateX(0) rotate(0) scale(.6); opacity: 0; }
.hk-tag { position: absolute; z-index: 4; display: inline-flex; align-items: center; gap: 7px; background: #fff; color: #2a2a2a; border-radius: 999px; padding: 9px 14px;
  font: 700 12.5px/1 Inter, system-ui, sans-serif; white-space: nowrap; box-shadow: 0 16px 34px -12px rgba(0,0,0,.45);
  transition: transform 1s cubic-bezier(.34, 1.56, .64, 1), opacity .5s ease; transition-delay: calc(1.1s + var(--i, 0) * .18s); }
.hk-tag i { font-style: normal; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: #ff4f1f; color: #fff; font-size: 11px; }
.hk-tag--1 { left: 4%; top: 12%; } .hk-tag--2 { right: 3%; top: 22%; } .hk-tag--3 { left: 10%; bottom: 10%; }
.m-on .hk-reels:not(.is-in) .hk-tag, .m-on .hk-fan:not(.is-in) .hk-tag { transform: scale(.2) translateY(30px); opacity: 0; }
@keyframes hk-bob2 { 50% { translate: 0 -10px; } }
.hk-reels.is-in .hk-reel--c { animation: hk-bob2 6s ease-in-out 2s infinite; }
.hk-reels.is-in .hk-tag { animation: hk-bob2 4.5s ease-in-out infinite; animation-delay: calc(2.2s + var(--i, 0) * .6s); }
@media (max-width: 640px) {
  .hk-reels { height: 470px; } .hk-reel { width: 150px; }
  .hk-reel--l { transform: translateX(-58%) rotate(-7deg) scale(.82); } .hk-reel--r { transform: translateX(58%) rotate(7deg) scale(.82); }
  .hk-tag--1 { left: 0; } .hk-tag--2 { right: 0; } .hk-tag--3 { left: 2%; }
}

/* ---------- photo fan: a stacked deck that spreads into an arc ---------- */
.hk-fan { position: relative; height: clamp(380px, 38vw, 500px); display: flex; justify-content: center; align-items: flex-end; margin-top: 10px; }
.hk-fan__c { position: absolute; bottom: 6%; width: clamp(130px, 15vw, 210px); aspect-ratio: 4/5; margin: 0; border-radius: 18px; overflow: hidden; background: #111;
  border: 6px solid #fff; box-shadow: 0 26px 50px -20px rgba(0,0,0,.45); transform-origin: 50% 170%;
  transform: rotate(var(--a)) translateY(0); transition: transform 1.25s cubic-bezier(.16, 1.05, .3, 1), opacity .6s ease, box-shadow .4s;
  transition-delay: calc(var(--i) * .07s); z-index: var(--z); }
.hk-fan__c img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hk-fan__c figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 8px 7px; text-align: center; color: #fff; font: 600 11px/1.2 Inter, system-ui, sans-serif;
  background: linear-gradient(transparent, rgba(0,0,0,.75)); }
.hk-fan.is-in .hk-fan__c:hover { transform: rotate(var(--a)) translateY(-22px) scale(1.05); box-shadow: 0 36px 60px -20px rgba(0,0,0,.55); z-index: 20; transition-delay: 0s; transition-duration: .45s; }
.m-on .hk-fan:not(.is-in) .hk-fan__c { transform: rotate(calc(var(--a) * .08)) translateY(60px) scale(.88); opacity: .0; }
.hk-fan .hk-tag--1 { left: 6%; top: 4%; } .hk-fan .hk-tag--2 { right: 6%; top: 10%; }
@media (max-width: 640px) { .hk-fan { height: 330px; } .hk-fan__c { width: 118px; border-width: 4px; } .hk-fan__c { transform-origin: 50% 190%; } }

/* ---------- photo ribbon: two rows drifting in opposite directions ---------- */
.hk-ribbon { position: relative; overflow: hidden; padding: 10px 0; transform: rotate(-2deg); margin: 0 -2%; }
.hk-ribbon__row { display: flex; gap: 16px; width: max-content; padding: 8px 0; animation: hk-marq 55s linear infinite; animation-play-state: paused; }
.hk-ribbon__row--b { animation-direction: reverse; animation-duration: 65s; }
.hk-ribbon.is-in .hk-ribbon__row { animation-play-state: running; }
.hk-ribbon:hover .hk-ribbon__row { animation-play-state: paused; }
@keyframes hk-marq { to { transform: translateX(-50%); } }
.hk-ribbon__i { position: relative; flex: none; width: clamp(150px, 15vw, 210px); aspect-ratio: 4/5; margin: 0; border-radius: 16px; overflow: hidden; background: #111;
  box-shadow: 0 16px 30px -16px rgba(0,0,0,.4); }
.hk-ribbon__i img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .8s cubic-bezier(.2, .8, .2, 1); }
.hk-ribbon__i:hover img { transform: scale(1.08); }
.hk-ribbon__i figcaption { position: absolute; left: 8px; bottom: 8px; background: rgba(255,255,255,.92); color: #2a2a2a; border-radius: 999px; padding: 4px 9px; font: 700 10.5px/1.2 Inter, system-ui, sans-serif; }
.m-on .hk-ribbon .hk-ribbon__row { transition: opacity 1s ease, translate 1.4s cubic-bezier(.16, 1.05, .3, 1); }
.m-on .hk-ribbon:not(.is-in) .hk-ribbon__row--a { translate: -18% 0; opacity: 0; }
.m-on .hk-ribbon:not(.is-in) .hk-ribbon__row--b { translate: 18% 0; opacity: 0; }

/* smaller side photos for the centred banners of inner pages */
.hk-hero-photos--sm .hk-polaroid { width: clamp(110px, 10vw, 160px); padding: 6px 6px 22px; }
.hk-hero-photos--sm .hk-polaroid--a { top: 16%; left: 3%; } .hk-hero-photos--sm .hk-polaroid--b { bottom: 6%; left: 9%; top: auto; }
.hk-hero-photos--sm .hk-polaroid--c { top: 14%; right: 3%; } .hk-hero-photos--sm .hk-polaroid--d { bottom: 6%; right: 9%; top: auto; }
@media (max-width: 1180px) { .hk-hero-photos--sm { display: none; } }

@media (prefers-reduced-motion: reduce) {
  .hk-ribbon__row { animation: none !important; } .hk-reels.is-in .hk-reel--c, .hk-reels.is-in .hk-tag { animation: none !important; }
}

/* off-screen start positions (photos and phones that slide in from the sides) must never cause sideways scrolling */
html.m-on, html.m-on body { overflow-x: clip; }
.hk-hero-photos { overflow: hidden; }
