/* KFC Norway teaser: the landing. Tokens come from brand/tokens.css (synced from ../brand). */
*, *::before, *::after { box-sizing: border-box; }
html { background: var(--ink); }
body {
  margin: 0;
  min-height: 100svh;
  font-family: var(--f-ui);
  color: var(--white);
  background: var(--ink);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: clip;
}
button, input { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }
::selection { background: var(--red); color: var(--white); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }

/* one screen: the bucket (60% of the height) and the message under it, centred as a group */
.landing {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: calc(var(--hit) + var(--s-16)) var(--gutter) max(env(safe-area-inset-bottom), var(--s-32));
  overflow-x: clip;        /* the intro zooms the bucket past the screen edges: no sideways scroll meanwhile */
}

.top {
  position: absolute;
  top: max(env(safe-area-inset-top), var(--s-16));
  left: 0;
  right: 0;
  z-index: 2;              /* stays usable above the tap-anywhere start */
  display: flex;
  justify-content: center;
  gap: var(--s-8);
  pointer-events: none;    /* the strip lets taps through; only the buttons catch them */
}
.top > * { pointer-events: auto; }
.sound {
  user-select: none;
  -webkit-user-select: none;
  width: var(--hit);
  height: var(--hit);
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: color-mix(in srgb, var(--white) 10%, transparent);
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease-out), transform var(--dur-slow) var(--spring);
}
.sound svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
html:not(.is-mouse) .sound { display: none; }   /* phones stay silent */
.sound .i-on { display: none; }
.sound[aria-pressed="true"] .i-on { display: block; }
.sound[aria-pressed="true"] .i-off { display: none; }
/* sound is wanted but the browser still needs a tap: a gentle breath on the button */
.sound.is-waiting { animation: breathe 1.6s var(--ease) infinite; }
@media (prefers-reduced-motion: reduce) { .sound.is-waiting { animation: none; } }
@keyframes breathe { 50% { transform: scale(1.08); background: color-mix(in srgb, var(--white) 22%, transparent); } }
@media (hover: hover) and (pointer: fine) {
  .sound:hover { background: color-mix(in srgb, var(--white) 18%, transparent); }
}
.sound:active { transform: scale(0.94); transition: transform var(--dur-press) var(--press); }
.lang {
  min-width: var(--hit);
  height: var(--hit);
  padding: 0 var(--s-12);
  border: 0;
  border-radius: var(--r-pill);
  background: color-mix(in srgb, var(--white) 10%, transparent);
  font-family: var(--f-sans);
  font-size: var(--t-small);
  cursor: pointer;
  user-select: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background-color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out), transform var(--dur-slow) var(--spring);
}
@media (hover: hover) and (pointer: fine) {
  .lang:hover { background: color-mix(in srgb, var(--white) 18%, transparent); }
}
.lang svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.lang:active { transform: scale(0.95); transition: transform var(--dur-press) var(--press); }

/* the animation box: 60% of the screen height, never wider than it needs to be on phones */
.stage {
  flex: none;
  width: min(100%, 1100px);
  height: min(60svh, 96vw);
  margin-top: -3svh;     /* the room kept for the pointer arm sits above the bucket: lift the group a touch */
}
.stage canvas {
  display: block;
  width: 100%;
  height: 100%;
  /* the bucket reads its colours here: dark photos, white pointer arm on ink */
  --logo-tone: dark;
  --logo-arm: var(--white);
}

.message {
  display: grid;
  justify-items: center;
  align-content: start;
  gap: var(--s-16);
  text-align: center;
  padding-top: clamp(0px, 1svh, var(--s-12));
}
.title {
  margin: 0;
  font-family: var(--f-stripes);
  font-weight: 400;
  text-transform: uppercase;
  font-size: clamp(34px, 1.1rem + 3vw, 72px);
  line-height: var(--lh-tight);
  letter-spacing: var(--track-title);
}
.line { display: block; }        /* always two lines: THE WAIT / IS OVER */

/* the laks flow: lines under the bucket while it spins, in the headline's place until the logo lands */
.message > .caption, .message > .title { grid-area: 1 / 1; }
.caption {
  display: grid;
  justify-items: center;
  align-self: start;
  font-family: var(--f-sans);
  font-size: var(--t-h3);
  line-height: var(--lh-heading);
}
.cap { grid-area: 1 / 1; margin: 0; }
.again { display: block; }        /* its own line: no gap left on the first line before it lands */
.cap, .again {
  opacity: 0;
  transform: translateY(0.4em);
  filter: blur(8px);
  transition: opacity 600ms var(--ease-out), transform 700ms var(--ease-out), filter 600ms var(--ease-out);
}
.cap.is-on, .again.is-on { opacity: 1; transform: none; filter: none; }
.cap.is-out { transform: translateY(-0.4em); }
.word { display: inline-block; }
.sub {
  margin: 0;
  max-width: 40ch;
  text-wrap: balance;
  font-size: var(--t-lead);
  line-height: 1.45;
  color: var(--on-ink-muted);
}

.notify {
  display: flex;
  gap: var(--s-8);
  width: min(100%, 440px);
  margin-top: var(--s-4);
}
.notify input {
  flex: 1;
  min-width: 0;
  height: var(--btn-h);
  padding: 0 var(--s-20);
  border: 2px solid transparent;
  border-radius: var(--r-pill);
  background: var(--white);
  color: var(--ink);
  font-size: 16px;
  transition: border-color var(--dur-fast) var(--ease-out);
}
/* email, optional number and button in one row; phones and narrow windows stack them (below) */
@media (min-width: 600px) {
  .notify { width: min(100%, 680px); }
  .notify #email { flex: 1 1 0; }
  .notify .tel { flex: 1 1 0; }
}
/* the phone field: +47 sits in front of what's typed (Norway is the default); gone when the number starts with + */
.tel { position: relative; display: flex; min-width: 0; }
.tel input { padding-left: 58px; }
.tel-cc { position: absolute; left: var(--s-20); top: 50%; translate: 0 -50%; color: var(--ink); font-size: 16px; pointer-events: none; transition: opacity var(--dur-fast) var(--ease-out); }
.tel.is-intl .tel-cc, .notify[data-state] .tel-cc { opacity: 0; }
.tel.is-intl input { padding-left: var(--s-20); }
.notify input::placeholder { color: color-mix(in srgb, var(--ink) 50%, transparent); }
.notify input:focus { outline: none; border-color: var(--red); }
.notify input[aria-invalid="true"] { border-color: var(--red); }
.sms-consent { grid-row: 4; display: flex; align-items: center; gap: var(--s-8); min-height: var(--hit); max-width: 40ch; font-size: var(--t-small); text-align: left; cursor: pointer; }
.sms-consent input { flex: none; width: var(--s-20); height: var(--s-20); accent-color: var(--red); }
.signup-error { grid-row: 5; max-width: 40ch; margin: 0; font-size: var(--t-small); }
.message:not(.is-revealed) .sms-consent { visibility: hidden; }
.notify[data-state] ~ .sms-consent { visibility: hidden; }
.cta {
  flex: none;
  height: var(--btn-h);
  padding: 0 var(--s-24);
  border: 0;
  border-radius: var(--r-pill);
  background: var(--red);
  font-family: var(--f-sans);
  font-size: 18px;
  cursor: pointer;
  user-select: none;
  transition: transform var(--dur-slow) var(--spring), box-shadow var(--dur-fast) var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .cta:hover { transform: translateY(-2px) scale(1.03); box-shadow: 0 0 0 5px var(--ring-on-dark); }
}
.cta:active { transform: scale(0.95); transition: transform var(--dur-press) var(--press); }
/* the thanks: a confirmation pill where the form was, led by the red check the button turned into */
.thanks {
  display: inline-flex; align-items: center; gap: var(--s-12);
  min-height: var(--btn-h); margin: 0; padding: 6px var(--s-24) 6px 8px;
  border-radius: var(--r-pill); background: color-mix(in srgb, var(--white) 10%, transparent);
  font-family: var(--f-sans); font-size: 18px; line-height: 1.25; text-align: left;
}
.thanks-check { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--red); }
.thanks-check svg { width: 24px; height: 24px; fill: none; stroke: var(--white); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }

/* notify submit (transitions.dev spinner-check-morph, adapted): the pill folds into a red circle while the input
   blurs away, a white spinner runs while the address goes out, the circle pops and hops as the check draws itself,
   then the form cross-blurs into the thanks line in the same grid cell. One data-state on the form drives it all. */
:root {
  --notify-fold-dur: 460ms;
  --notify-fold-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --check-spin-dur: 800ms;
  --check-ring-w: 2.5px;
  --check-hop: 4px;
  --check-up-dur: 250ms;
  --check-up-ease: cubic-bezier(0.34, 1.35, 0.64, 1);
  --check-down-dur: 300ms;
  --check-down-ease: cubic-bezier(0.14, 2.56, 0.94, 1);
  --check-pop-scale: 1.09;
  --check-pop-dur: 350ms;
  --check-pop-ease: cubic-bezier(0.34, 1.96, 0.94, 1);
  --check-fill-dur: 350ms;
  --check-draw-dur: 600ms;
  --check-draw-delay: 80ms;
  --check-draw-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --check-blur: 1px;
  --check-mark-w: 2.5;
}
.notify, .thanks { grid-row: 3; grid-column: 1; }
.thanks { align-self: center; }
.cta { position: relative; display: grid; grid-template: minmax(0, 1fr) / minmax(0, 1fr); place-items: center; }
.cta > * { grid-area: 1 / 1; }
.cta-label { white-space: nowrap; transition: opacity 160ms var(--ease-out), filter 160ms var(--ease-out); }
.cta-ring, .cta-arc { width: 22px; height: 22px; border-radius: 50%; border: var(--check-ring-w) solid transparent; opacity: 0; }
.cta-ring { border-color: color-mix(in srgb, var(--white) 28%, transparent); }
.cta-arc { border-top-color: var(--white); animation: cta-spin var(--check-spin-dur) linear infinite paused; }
@keyframes cta-spin { to { transform: rotate(360deg); } }
.cta-check { width: 26px; height: 26px; }
.cta-check path {
  fill: none;
  stroke: var(--white);
  stroke-width: var(--check-mark-w);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: var(--check-mark-len, 20);
  stroke-dashoffset: var(--check-mark-len, 20);
}

.message.is-revealed .notify[data-state] {
  pointer-events: none;
  transition: width var(--notify-fold-dur) var(--notify-fold-ease), gap var(--notify-fold-dur) var(--notify-fold-ease),
    opacity 420ms var(--ease-out), transform 420ms var(--ease-out), filter 420ms var(--ease-out);
  transition-delay: 0ms;
}
.notify[data-state] input {
  transition: opacity 180ms var(--ease-out), filter 180ms var(--ease-out), padding var(--notify-fold-dur) var(--notify-fold-ease),
    height var(--notify-fold-dur) var(--notify-fold-ease), border-width var(--notify-fold-dur) var(--notify-fold-ease);
}
.notify[data-state] .cta {
  transition: width var(--notify-fold-dur) var(--notify-fold-ease), padding var(--notify-fold-dur) var(--notify-fold-ease),
    scale var(--check-pop-dur) var(--check-pop-ease);
}
.message .notify[data-state] { width: var(--btn-h); gap: 0; }
.notify[data-state] input { opacity: 0; filter: blur(6px); padding: 0; border-width: 0; height: 0; }
.notify[data-state] .cta { width: var(--btn-h); padding: 0; transform: none; box-shadow: none; }
.notify[data-state] .cta-label { opacity: 0; filter: blur(4px); }
.notify[data-state="sending"] .cta-ring,
.notify[data-state="sending"] .cta-arc { opacity: 1; transition: opacity 240ms var(--ease-out) 220ms; }
.notify[data-state="sending"] .cta-arc { animation-play-state: running; }

/* done: the spinner pauses and fades, the circle pops 9% and hops, the check draws while the pop is still landing */
.notify[data-state="done"] .cta-ring { opacity: 0; transition: opacity calc(var(--check-fill-dur) * 0.7) ease; }
.notify[data-state="done"] .cta-arc { opacity: 0; transition: opacity calc(var(--check-fill-dur) * 0.5) ease; }
.notify[data-state="done"] .cta,
.notify[data-state="out"] .cta {
  scale: var(--check-pop-scale);
  animation-name: cta-hop-up, cta-hop-down;
  animation-duration: var(--check-up-dur), var(--check-down-dur);
  animation-timing-function: var(--check-up-ease), var(--check-down-ease);
  animation-delay: 0ms, var(--check-up-dur);
  animation-fill-mode: forwards, forwards;
}
@keyframes cta-hop-up { from { transform: translateY(0); } to { transform: translateY(calc(var(--check-hop) * -1)); } }
@keyframes cta-hop-down { from { transform: translateY(calc(var(--check-hop) * -1)); } to { transform: translateY(0); } }
.notify[data-state="done"] .cta-check path,
.notify[data-state="out"] .cta-check path {
  stroke-dashoffset: 0;
  transition: stroke-dashoffset var(--check-draw-dur) var(--check-draw-ease) calc(var(--check-fill-dur) + var(--check-draw-delay) - 200ms);
}
.notify.is-crossing { filter: blur(var(--check-blur)); }

/* out: the circle blurs away as the thanks line rises out of a blur into its place */
.message .notify[data-state="out"] { opacity: 0; transform: scale(0.86); filter: blur(8px); }
.thanks.is-arriving { opacity: 0; transform: translateY(10px); filter: blur(10px); }
.message .thanks { transition-delay: 120ms; }

@media (prefers-reduced-motion: reduce) {
  .cta-arc { animation: none !important; }
  .notify[data-state="sending"] .cta-arc { opacity: 0; }
  .notify[data-state] .cta { animation: none !important; }
  .notify.is-crossing, .message .notify[data-state="out"], .thanks.is-arriving { filter: none; }
}

/* the caption flows' start: tap anywhere (a red dot with a hand, two quiet rings breathing out), sound comes on */
.gate {
  position: fixed;
  inset: 0;
  display: grid;
  place-content: center;
  justify-items: center;
  cursor: pointer;
  transition: opacity 500ms var(--ease-out), transform 600ms var(--ease-out);
}
.gate.is-gone { opacity: 0; transform: scale(0.96); pointer-events: none; }
body.is-gated .top .sound, body.is-gated .stage { opacity: 0; }
.tap {
  position: relative;
  width: 168px;
  height: 168px;
  display: grid;
  place-items: center;
  margin-bottom: var(--s-32);
  border: 0;
  background: transparent;
  cursor: pointer;
}
.ring { position: absolute; border-radius: 50%; border: 1px solid color-mix(in srgb, var(--white) 22%, transparent); animation: ring 2.4s var(--ease-out) infinite; }
.ring-1 { inset: 28px; }
.ring-2 { inset: 0; border-color: color-mix(in srgb, var(--white) 10%, transparent); animation-delay: 0.3s; }
@keyframes ring { 0% { transform: scale(0.92); opacity: 0; } 30% { opacity: 1; } 100% { transform: scale(1.06); opacity: 0.4; } }
.dot {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--red);
  transition: transform var(--dur-slow) var(--spring);
}
.dot .i-cursor, .is-mouse .dot .i-hand { display: none; }
.is-mouse .dot .i-cursor { display: block; }
.dot svg { width: 28px; height: 28px; fill: none; stroke: var(--white); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
@media (hover: hover) and (pointer: fine) { .gate:hover .dot { transform: scale(1.06); } }
.gate:active .dot { transform: scale(0.94); transition: transform var(--dur-press) var(--press); }
.tap-title { margin: 0; font-family: var(--f-stripes); font-size: 34px; line-height: var(--lh-tight); letter-spacing: var(--track-title); text-transform: uppercase; }   /* Stripes titles are uppercase by brand */
.tap-sub { margin: var(--s-8) 0 0; font-size: var(--t-small); color: var(--on-ink-muted); }

/* company info toast (Paper E3): bottom right on desktop, across the bottom on phones; it rises in with a soft
   spring and its lines follow one by one */
.toast {
  position: fixed;
  right: max(env(safe-area-inset-right), var(--s-32));
  bottom: max(env(safe-area-inset-bottom), var(--s-32));
  z-index: 3;
  width: min(340px, calc(100vw - 2 * var(--gutter)));
  display: grid;
  grid-template-columns: minmax(0, 1fr);   /* the photo fits the card, never widens it */
  gap: var(--s-12);
  padding: var(--s-20) var(--s-20) var(--s-24);
  border-radius: var(--r-card, 20px);
  background: color-mix(in srgb, var(--white) 10%, var(--ink));
  font-size: var(--t-small);
  line-height: 1.45;
  color: var(--on-ink-muted);
  opacity: 0;
  transform: translateY(24px) scale(0.96);
  transform-origin: 100% 100%;
  overflow: hidden;
  transition: opacity 400ms var(--ease-out), transform 700ms var(--spring), width 450ms var(--ease-out), height 450ms var(--ease-out), padding 450ms var(--ease-out), border-radius 450ms var(--ease-out);
}
.toast.is-in { opacity: 1; transform: none; }
/* closed: the card shrinks into a small round info button in the same corner; a click opens it again */
.toast.is-mini { width: var(--hit) !important; height: var(--hit) !important; padding: 0; border-radius: 50%; cursor: pointer; }
.toast.is-mini > :not(.toast-mini) { opacity: 0 !important; transition: opacity 150ms var(--ease-out) !important; pointer-events: none; }
.toast-mini {
  position: absolute;
  right: 0;
  bottom: 0;
  width: var(--hit);
  height: var(--hit);
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  background: transparent;
  opacity: 0 !important;
  pointer-events: none;
  transition: opacity 250ms var(--ease-out) !important;
}
.toast.is-mini .toast-mini { opacity: 1 !important; pointer-events: auto; transition-delay: 200ms !important; }
.toast-mini svg { width: 22px; height: 22px; fill: none; stroke: var(--white); stroke-width: 1.7; stroke-linecap: round; }
.toast.is-out { opacity: 0; transform: translateY(16px) scale(0.98); transition: opacity 250ms var(--ease-out), transform 300ms var(--ease-out); }
.toast-head { display: flex; align-items: center; justify-content: space-between; }
.toast-title { margin: 0; font-family: var(--f-sans); font-size: 17px; color: var(--white); }
.toast-close {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: color-mix(in srgb, var(--white) 10%, transparent);
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease-out), transform var(--dur-slow) var(--spring);
}
.toast-close::before { content: ""; position: absolute; width: var(--hit); height: var(--hit); }
.toast-close svg { width: 12px; height: 12px; fill: none; stroke: var(--white); stroke-width: 1.6; stroke-linecap: round; }
@media (hover: hover) and (pointer: fine) { .toast-close:hover { background: color-mix(in srgb, var(--white) 18%, transparent); transform: rotate(90deg); } }
.toast-line { margin: 0; }
.toast-mail { color: var(--white); text-decoration: none; justify-self: start; }
@media (hover: hover) and (pointer: fine) { .toast-mail:hover { text-decoration: underline; text-underline-offset: 3px; } }
.toast-legal { font-size: 12px; color: color-mix(in srgb, var(--white) 45%, transparent); }
.toast > * { opacity: 0; transform: translateY(6px); transition: opacity 400ms var(--ease-out), transform 500ms var(--ease-out); }
.toast.is-in > * { opacity: 1; transform: none; }
.toast.is-in > :nth-child(2) { transition-delay: 120ms; }
.toast.is-in > :nth-child(3) { transition-delay: 180ms; }
.toast.is-in > :nth-child(4) { transition-delay: 240ms; }
.toast.is-in > :nth-child(5) { transition-delay: 300ms; }
@media (max-width: 600px) {
  /* phones: the info button sits in the empty top right corner, clear of the sign-up form at any screen height;
     a tap opens the card down from there, over the bucket */
  .toast { z-index: 20; top: max(env(safe-area-inset-top), var(--s-16)); bottom: auto; left: auto; right: var(--gutter); width: calc(100vw - 2 * var(--gutter)); transform-origin: 100% 0; }
  .toast-mini { top: 0; bottom: auto; }
}

.replay {
  width: var(--hit);
  height: var(--hit);
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: color-mix(in srgb, var(--white) 10%, transparent);
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease-out), transform var(--dur-slow) var(--spring);
}
.replay svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: transform var(--dur-slow) var(--spring); }
@media (hover: hover) and (pointer: fine) {
  .replay:hover { background: color-mix(in srgb, var(--white) 18%, transparent); }
  .replay:hover svg { transform: rotate(-30deg); }
}
.replay:active { transform: scale(0.94); transition: transform var(--dur-press) var(--press); }

@media (max-width: 599px) {
  .notify { flex-direction: column; }
  .notify input, .notify .tel { flex: none; width: 100%; }
  .cta { width: 100%; }
}
/* short phones: the stacked form needs the room, so the bucket gives some up */
@media (max-width: 599px) and (max-height: 760px) {
  .stage { height: min(37svh, 96vw); }
}

/* entrance: the page fades up out of black, then the bucket starts; the message rises in when the logo lands */
.top, .stage { transition: opacity 900ms var(--ease-out), transform 1100ms var(--ease-out); }
body.is-loading .top { opacity: 0; }
body.is-loading .stage { opacity: 0; transform: scale(0.94); }

.word, .sub, .notify, .thanks {
  transition: opacity 700ms var(--ease-out), transform 800ms var(--ease-out), filter 700ms var(--ease-out);
}
.message:not(.is-revealed) .word { opacity: 0; transform: translateY(0.35em); filter: blur(10px); }
.message:not(.is-revealed) .sub,
.message:not(.is-revealed) .notify { opacity: 0; transform: translateY(12px); }
.message.is-revealed .word { transition-delay: calc(var(--i) * 90ms); }
.message.is-revealed .sub { transition-delay: 420ms; }
.message.is-revealed .notify { transition-delay: 560ms; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 1ms !important; transition-delay: 0ms !important; animation-duration: 1ms !important; }
  .message:not(.is-revealed) .word { filter: none; }
  .cap, .again { filter: none; }
}

/* store flow (?flow=store): the storefront render over the stage, flying into the bucket */
.storefront { position: fixed; inset: 0; z-index: 5; overflow: hidden; pointer-events: none; transition: opacity 1000ms cubic-bezier(0.4, 0, 0.2, 1); }
.storefront img { position: absolute; left: 0; top: 0; width: 2000px; height: 1125px; max-width: none; transform-origin: 0 0; will-change: transform, filter; }
.storefront.is-gone { opacity: 0; }
.storefront video { position: absolute; left: 0; top: 0; max-width: none; transform-origin: 0 0; opacity: 0; }
.storefront.is-video { background: #101010; }
.storefront.is-video video { opacity: 1; }
.storefront.is-video img { opacity: 0; }
/* Storo: the clip fades in over the leaning-in render instead of cutting (main.js storeFlyVideo) */
.storefront.is-blend video { transition: opacity 320ms ease-out; }
.storefront.is-blend.is-video img { opacity: 0; transition: opacity 320ms ease-out 80ms; }
/* a quiet loader at the foot of the still while the clip buffers: a small ink disc with a white spinner (readable on
   any part of the render), fading in only after 600 ms so quick loads never see it */
.store-load {
  position: absolute;
  left: 50%;
  bottom: max(env(safe-area-inset-bottom), var(--s-32));
  width: var(--hit);
  height: var(--hit);
  margin-left: calc(var(--hit) / -2);
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--ink);
  opacity: 0;
  scale: 0.8;
  filter: blur(4px);
  transition: opacity 240ms var(--ease-out), scale 240ms var(--ease-out), filter 240ms var(--ease-out);
}
.store-load::after {
  content: '';
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2.5px solid color-mix(in srgb, var(--white) 25%, transparent);
  border-top-color: var(--white);
  animation: cta-spin 800ms linear infinite;
}
.storefront.is-waiting .store-load {
  opacity: 1;
  scale: 1;
  filter: none;
  transition: opacity 400ms var(--ease-out) 600ms, scale 500ms var(--spring) 600ms, filter 400ms var(--ease-out) 600ms;
}
@media (prefers-reduced-motion: reduce) {
  .store-load::after { animation: none !important; border-color: var(--white); border-right-color: transparent; }
}
body.is-store .stage canvas { opacity: 0; transition: opacity 1000ms cubic-bezier(0.4, 0, 0.2, 1); }
body.is-store.store-landed .stage canvas { opacity: 1; transition: none; }   /* shows at once under the clip, which then dissolves away */
body.is-store .top { z-index: 6; }
body.is-store .stage { transform: none !important; }
body.is-store .gate { z-index: 7; }

/* intro flows (?flow=headline, ?flow=photos): an ink overlay plays the type, then hands over to the bucket */
.intro { position: fixed; inset: 0; z-index: 5; display: grid; place-items: center; overflow: hidden; pointer-events: none; background: var(--ink); transition: opacity 700ms var(--ease-out); }
.intro.is-gone { opacity: 0; }
.intro__title { position: relative; margin: 0; font-family: var(--f-stripes); font-weight: 400; text-transform: uppercase; line-height: 0.86; color: var(--white); }
.intro__line { display: block; }
body.is-intro .stage canvas { opacity: 0; scale: 0.55; filter: blur(10px); }
body.is-intro.intro-landed .stage canvas,
body.is-intro.intro-spinning .stage canvas { opacity: 1; scale: 1; filter: none; transition: opacity 500ms var(--ease-out), scale 900ms var(--spring), filter 500ms var(--ease-out); }

/* headline: the website hero cut-in at poster size over a photo, then the words fold into the bucket */
.intro--headline .intro__photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; scale: 1.06; transition: opacity 900ms var(--ease-out), scale 3600ms cubic-bezier(0.22, 1, 0.36, 1); }
.intro--headline .intro__shade { position: absolute; inset: 0; background: linear-gradient(20deg, rgb(16 16 16 / 78%) 0%, rgb(16 16 16 / 40%) 50%, rgb(16 16 16 / 15%) 80%); opacity: 0; transition: opacity 900ms var(--ease-out); }
.intro--headline.is-on .intro__photo { opacity: 1; scale: 1; }
.intro--headline.is-on .intro__shade { opacity: 1; }
.intro--headline .intro__title {
  font-size: min(calc((100vw - 4 * var(--gutter)) / 6.6), 28svh);
  white-space: nowrap;
  justify-self: start;
  margin-left: var(--gutter);
  translate: var(--nudge, 0px) 0;
  transition: translate 260ms var(--ease-out), transform 520ms cubic-bezier(0.55, 0, 0.75, 0.2), opacity 420ms ease-in 120ms, filter 520ms ease-in;
}
.intro--headline .intro__line { transition: opacity 90ms linear, translate 300ms var(--ease-out), filter 300ms var(--ease-out); }
.intro--headline .intro__line.is-off { opacity: 0; translate: 60px 0; filter: blur(10px); }
.intro--headline .intro__line.is-landing { translate: -90px 0; filter: blur(14px); transition: none; }
.intro--headline.is-folding .intro__title { transform: scale(0.08); opacity: 0; filter: blur(12px); }
.intro--headline.is-folding .intro__photo, .intro--headline.is-folding .intro__shade { opacity: 0; transition: opacity 600ms ease-in; }
.intro--headline.is-folding { background: var(--ink); }
@media (min-width: 900px) { .intro--headline .intro__title { margin-left: calc(var(--gutter) * 3); } }

/* photos: the footer wordmark, full width, food photos flashing inside the letters */
.intro--photos .intro__title {
  font-size: min(calc((100vw - 2 * var(--gutter)) / (var(--chars, 8) * 0.8)), 40svh);
  text-align: center;
  color: transparent;
  background: var(--white) url(brand/images/attract/1.webp) 50% 50% / cover no-repeat;
  -webkit-background-clip: text; background-clip: text;
  animation: intro-flash 1.2s step-end infinite;
  opacity: 0; scale: 1.06; filter: blur(16px);
  transition: opacity 700ms var(--ease-out), scale 1200ms cubic-bezier(0.22, 1, 0.36, 1), filter 800ms var(--ease-out);
}
.intro--photos.is-on .intro__title { opacity: 1; scale: 1; filter: none; }
.intro--photos.is-leaving { opacity: 0; transition: opacity 1100ms cubic-bezier(0.4, 0, 0.2, 1); }
.intro--photos.is-leaving .intro__title { scale: 0.92; filter: blur(10px); transition: scale 1100ms cubic-bezier(0.4, 0, 0.2, 1), filter 1100ms cubic-bezier(0.4, 0, 0.2, 1); }
/* the bucket spins in on top of the wordmark, from small to big */
body.is-intro.intro-photos .stage canvas { scale: 0.06; filter: none; }
body.is-intro.intro-photos.intro-spinning .stage canvas { scale: 1; transition: opacity 300ms var(--ease-out), scale 2600ms cubic-bezier(0.45, 0, 0.25, 1); }
body.is-intro.intro-spinning .stage { position: relative; z-index: 6; }
@keyframes intro-flash {
  0%   { background-image: url(brand/images/attract/1.webp); }
  20%  { background-image: url(brand/images/attract/2.webp); }
  40%  { background-image: url(brand/images/attract/3.webp); }
  60%  { background-image: url(brand/images/attract/4.webp); }
  80%  { background-image: url(brand/images/attract/5.webp); }
  100% { background-image: url(brand/images/attract/1.webp); }
}
@media (prefers-reduced-motion: reduce) {
  .intro { display: none; }
  body.is-intro .stage canvas { opacity: 1; scale: 1; filter: none; }
}
body.is-intro .top { z-index: 6; }   /* the back button and controls stay above the intro type */

/* fade-only storefront (?flow=storo-fade): the render drifts in slowly while it holds, then dims, softens and drifts a
   little further as it dissolves; the logo comes up out of a soft blur under it and settles into place */
body.is-fade-flow .storefront img { scale: 1; transition: scale 2600ms linear; }
body.is-fade-flow .storefront.is-drift img { scale: 1.03; }
body.is-fade-flow .storefront.is-gone { opacity: 1; }
body.is-fade-flow .storefront.is-gone img {
  opacity: 0; scale: 1.07; filter: blur(14px) brightness(0.55);
  transition: opacity 1500ms cubic-bezier(0.4, 0, 0.2, 1), scale 1600ms cubic-bezier(0.33, 0, 0.2, 1), filter 1300ms cubic-bezier(0.4, 0, 0.2, 1);
}
body.is-store.is-fade-flow .stage canvas { opacity: 0; scale: 0.93; filter: blur(10px); }
body.is-store.is-fade-flow.store-landed .stage canvas {
  opacity: 1; scale: 1; filter: none;
  transition: opacity 1100ms cubic-bezier(0.4, 0, 0.2, 1) 350ms, filter 1100ms cubic-bezier(0.4, 0, 0.2, 1) 350ms, scale 1500ms cubic-bezier(0.22, 1, 0.36, 1) 350ms;
}
@media (prefers-reduced-motion: reduce) {
  body.is-fade-flow .storefront img, body.is-store.is-fade-flow .stage canvas { scale: 1 !important; filter: none !important; }
}

/* bucket window (?flow=storo-bucket): the render seen through the KFC bucket silhouette, closing onto the live bucket */
.storefront.is-window {
  -webkit-mask: url(brand/images/kfc-colonel-side.svg) no-repeat; mask: url(brand/images/kfc-colonel-side.svg) no-repeat;
  -webkit-mask-size: var(--mw) var(--mh); mask-size: var(--mw) var(--mh);
  -webkit-mask-position: var(--mx) var(--my); mask-position: var(--mx) var(--my);
}
.storefront.is-window.is-gone { opacity: 0; transition: opacity 600ms cubic-bezier(0.4, 0, 0.2, 1); }

/* Safari edges: strips behind the status bar and the bottom toolbar in the page's ink (iOS 26 reads the strip itself) */
:root { --edge-top-background: var(--ink); --edge-bottom-background: var(--ink); }
.edge-top, .edge-bottom { position: fixed; left: 0; right: 0; z-index: 30; pointer-events: none; }
.edge-top { top: 0; height: max(12px, env(safe-area-inset-top)); background: var(--edge-top-background); }
.edge-bottom { bottom: 0; height: max(12px, env(safe-area-inset-bottom)); background: var(--edge-bottom-background); }
.edge-top::after, .edge-bottom::after { content: ""; position: absolute; inset: 0; }
.edge-top::after { background: var(--edge-top-background); }
.edge-bottom::after { background: var(--edge-bottom-background); }
