/* A single persistent ticket travels through three scenes as the page scrolls. */
.homepage .how.ticket-story {
  --story-padding: 96px;
  --story-top: 104px;
  --story-progress: 0;
  padding: var(--story-padding) 0;
  background: var(--experience-deep);
  color: var(--experience-paper);
  overflow: clip;
  position: relative;
}
.story-layout { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); align-items: center; gap: 90px; }
.story-scroll-active { min-height: calc(var(--story-height) + var(--story-travel) + 2 * var(--story-padding)); }
.story-scroll-active .story-layout { position: sticky; top: var(--story-top); }
.story-copy { min-width: 0; }
.story-copy .eyebrow { color: #b8c9a5; font-size: 9px; letter-spacing: .12em; white-space: normal; }
.story-copy h2 { margin-top: 22px; font-size: clamp(42px,4.7vw,64px); font-weight: 500; line-height: 1.08; letter-spacing: -.06em; }
.story-copy h2 em { color: var(--experience-gold); }
.story-intro { max-width: 370px; margin-top: 23px; color: #c1cfb8; font-size: 14px; line-height: 1.8; }
.story-navigation { display: none; margin-top: 29px; }
.story-ready .story-navigation { display: grid; }
.story-tab { display: grid; grid-template-columns: 30px minmax(0,1fr) 24px; gap: 14px; align-items: center; padding: 17px 0; border: 0; border-top: 1px solid #dce6cf30; color: #a4b99d; background: none; cursor: pointer; text-align: left; transition: color .3s; }
.story-tab strong { display: block; font-family: var(--font-display); font-size: 17px; font-weight: 500; letter-spacing: -.03em; }
.story-tab small { display: block; margin-top: 5px; font-size: 11px; line-height: 1.4; color: #b7c6ac; }
.story-number { font-size: 11px; font-variant-numeric: tabular-nums; }
.story-arrow { opacity: 0; transform: translate(-5px,5px); font-size: 23px; transition: opacity .3s,transform .4s; }
.story-tab:hover,.story-tab[aria-selected=true] { color: #fffef5; }
.story-tab[aria-selected=true] .story-number { color: var(--experience-gold); }
.story-tab[aria-selected=true] .story-arrow { opacity: 1; transform: none; }
.story-scroll-hint { display: none; align-items: center; gap: 10px; margin-top: 19px; font-size: 10px; color: #b7c6ac; }
.story-ready .story-scroll-hint { display: flex; }
.story-scroll-hint > span { color: var(--experience-gold); font-size: 16px; }
.story-stage { min-width: 0; overflow: hidden; background: var(--experience-paper); color: var(--experience-ink); border-radius: 18px; box-shadow: 0 24px 60px #031d182a; }
.story-stage-heading { display: flex; justify-content: space-between; gap: 12px; align-items: center; padding: 17px 23px; border-bottom: 1px solid #dfe4d7; font-size: 8px; letter-spacing: .07em; }
.story-stage-heading > span:first-child { display: flex; align-items: center; gap: 8px; }
.story-stage-heading i { width: 6px; height: 6px; border-radius: 50%; background: #849467; }
#storyPosition { white-space: nowrap; font-variant-numeric: tabular-nums; color: #6c7c5f; }
.story-art { height: 330px; position: relative; isolation: isolate; background: #e8eee2; overflow: hidden; }
.story-orbit { position: absolute; width: 315px; height: 315px; left: calc(50% - 157px); top: 20px; border: 1px solid #9caa892c; border-radius: 50%; box-shadow: 0 0 0 42px #9caa8908,0 0 0 84px #9caa8907; }
.story-context { position: absolute; opacity: 0; transition: opacity .45s,transform .65s var(--experience-ease); pointer-events: none; }
.story-shop { width: 82%; max-width: 402px; top: 25px; left: 50%; transform: translate(-50%,12px) scale(.96); background: #fffef9; border: 1px solid #d8e0cf; border-radius: 10px; overflow: hidden; box-shadow: 0 14px 30px #183b2212; }
.story-shop-bar { height: 30px; display: flex; align-items: center; gap: 4px; padding: 0 12px; }
.story-shop-bar > span { width: 4px; height: 4px; border-radius: 50%; background: #c7cdbf; }
.story-shop-bar small { margin-left: auto; font-size: 8px; color: #67775e; }
.story-shop > img { width: 100%; height: 137px; object-fit: cover; object-position: center 40%; }
.story-shop-footer { display: flex; justify-content: space-between; gap: 10px; padding: 13px; font-size: 10px; }
.story-shop-footer span:last-child { color: #7f8a73; font-size: 8px; }
[data-story-step=create] .story-shop { opacity: 1; transform: translate(-50%,0) scale(1); }
.story-phone { width: 76%; max-width: 300px; height: 301px; top: 14px; left: 50%; padding: 29px 19px; transform: translate(-50%,12px) scale(.96); background: #fffefa; border: 5px solid #254d3d; border-radius: 26px; box-shadow: 0 17px 28px #163a2d15; text-align: center; }
.story-phone-speaker { position: absolute; top: 9px; left: calc(50% - 21px); width: 42px; height: 4px; border-radius: 5px; background: #b9c6ad; }
.story-phone-title { display: block; font: 500 19px/1.2 var(--font-display); letter-spacing: -.04em; }
.story-phone-sub { display: block; font-size: 9px; margin-top: 7px; color: #64765a; }
.story-phone-bottom { position: absolute; bottom: 18px; left: 21px; right: 21px; display: flex; justify-content: space-between; font-size: 10px; color: #7a896f; }
.story-phone-bottom > span { color: var(--experience-ink); }
[data-story-step=share] .story-phone { opacity: 1; transform: translate(-50%,0) scale(1); }
.story-scanner { inset: 47px 38px 58px; transform: scale(1.08); }
.story-scanner > span { position: absolute; width: 28px; height: 28px; border: 2px solid #81976e; }
.story-scanner > span:nth-child(1) { left: 0; top: 0; border-right: 0; border-bottom: 0; border-top-left-radius: 10px; }
.story-scanner > span:nth-child(2) { right: 0; top: 0; border-left: 0; border-bottom: 0; border-top-right-radius: 10px; }
.story-scanner > span:nth-child(3) { left: 0; bottom: 0; border-right: 0; border-top: 0; border-bottom-left-radius: 10px; }
.story-scanner > span:nth-child(4) { right: 0; bottom: 0; border-left: 0; border-top: 0; border-bottom-right-radius: 10px; }
[data-story-step=scan] .story-scanner { opacity: 1; transform: scale(1); }
.story-ticket { --story-ticket-x: -10px; --story-ticket-y: 34px; --story-ticket-rotate: -7deg; --story-ticket-scale: 1; position: absolute; left: 50%; top: 50%; width: min(360px,85%); display: grid; grid-template-columns: minmax(0,1fr) 92px; border-radius: 10px; background: var(--experience-ink); box-shadow: 0 16px 24px #163a2d26; transform: translate(calc(-50% + var(--story-ticket-x)),calc(-50% + var(--story-ticket-y))) rotate(var(--story-ticket-rotate)) scale(var(--story-ticket-scale)); transform-origin: center; z-index: 2; mask-image: radial-gradient(circle at calc(100% - 92px) 0,transparent 7px,#000 7.5px),radial-gradient(circle at calc(100% - 92px) 100%,transparent 7px,#000 7.5px); mask-composite: intersect; }
.story-ticket-main { padding: 18px 22px; color: #fffef5; min-width: 0; }
.story-ticket-brand { display: flex; align-items: center; gap: 5px; font-size: 10px; }
.story-ticket-brand img { width: 9px; height: 14px; filter: brightness(0) invert(1); }
.story-ticket-brand small { margin-left: auto; font-size: 6px; letter-spacing: .08em; color: #d4bf86; }
.story-ticket-main > strong { display: block; margin: 22px 0 20px; font: 500 31px/1.08 var(--font-display); letter-spacing: -.05em; }
.story-ticket-meta { display: grid; gap: 5px; font-size: 6px; letter-spacing: .06em; color: #c8d7bb; }
.story-ticket-meta span:first-child { color: #e9e3c7; font-size: 8px; letter-spacing: .1em; }
.story-ticket-stub { padding: 18px 12px; background: #fffdf2; border-left: 1px dashed #99aa85; display: flex; flex-direction: column; align-items: center; justify-content: space-between; gap: 15px; }
.story-ticket-stub > span { color: #738267; font-size: 6px; letter-spacing: .13em; }
.story-code { position: relative; width: 67px; height: 67px; }
.story-code > img { width: 100%; height: 100%; mix-blend-mode: multiply; transition: opacity .3s; }
.story-scan-beam { position: absolute; top: 0; left: -6px; right: -6px; height: 2px; background: #729958; box-shadow: 0 0 12px #6d964c; opacity: 0; }
.story-scan-check { position: absolute; inset: 9px; display: grid; place-items: center; border-radius: 50%; background: var(--experience-ink); color: white; opacity: 0; transform: scale(.7); transition: opacity .3s,transform .4s var(--experience-ease); }
[data-scan-state=scanning] .story-scan-beam { opacity: 1; animation: story-scan .8s ease-in-out both; }
[data-scan-state=valid] .story-code > img,[data-scan-state=duplicate] .story-code > img { opacity: .14; }
[data-scan-state=valid] .story-scan-check,[data-scan-state=duplicate] .story-scan-check { opacity: 1; transform: scale(1); }
[data-scan-state=duplicate] .story-scan-check { background: #866d39; }
.story-arrival { position: absolute; left: 50%; bottom: 17px; transform: translate(-50%,8px); opacity: 0; color: var(--experience-ink); font-size: 11px; white-space: nowrap; transition: opacity .4s,transform .4s; }
.story-arrival > span { margin-right: 6px; }
[data-story-step=scan] [data-scan-state=valid] .story-arrival { opacity: 1; transform: translate(-50%,0); }
.story-captions { padding: 23px 26px 22px; }
.story-panel + .story-panel { margin-top: 25px; }
.story-ready .story-captions { min-height: 194px; }
.story-ready .story-panel { margin: 0; }
.story-overline { font-size: 8px; letter-spacing: .09em; color: #677c5c; }
.story-panel h3 { margin-top: 8px; font: 500 24px/1.2 var(--font-display); letter-spacing: -.045em; }
.story-panel p { margin-top: 10px; font-size: 12px; line-height: 1.75; color: #607059; max-width: 420px; }
.story-next,.story-scan-reset { display: none; }
.story-ready .story-next { display: inline-flex; align-items: center; gap: 12px; padding: 11px 0 0; min-height: 36px; border: 0; background: transparent; font-size: 11px; font-weight: 600; color: var(--experience-ink); cursor: pointer; }
.story-next > span { font-size: 16px; transition: transform .25s; }
.story-next:hover > span { transform: translateX(4px); }
.story-next:disabled { cursor: wait; opacity: .6; }
.story-scan-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.story-ready .story-scan-reset { display: inline-block; padding-top: 11px; border: 0; background: transparent; color: #65765c; font-size: 10px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.story-progress { display: none; height: 3px; background: #dfe6d6; }
.story-ready .story-progress { display: block; }
.story-progress > span { display: block; height: 100%; background: #819967; transform: scaleX(var(--story-progress)); transform-origin: left; }
.homepage.motion-paused .story-ticket { transform: translate(-50%,-50%) !important; }
@keyframes story-scan { from { transform: translateY(0); } to { transform: translateY(67px); } }

@media (max-width:1150px) {
  .story-layout { gap: 45px; }
  .story-copy h2 { font-size: 49px; }
  .story-art { height: 307px; }
  .story-phone { height: 278px; }
  .story-ticket-main { padding-inline: 18px; }
  .story-ticket-main > strong { font-size: 28px; }
  .story-captions { padding-inline: 22px; }
  .story-panel h3 { font-size: 21px; }
}
@media (min-width:641px) and (max-width:860px) {
  .story-layout { gap: 28px; }
  .story-copy h2 { font-size: 39px; }
  .story-intro { font-size: 12px; }
  .story-tab { gap: 8px; grid-template-columns: 24px minmax(0,1fr) 17px; }
  .story-tab strong { font-size: 15px; }
  .story-tab small { font-size: 10px; }
  .story-stage-heading { padding-inline: 16px; font-size: 6px; }
  .story-art { height: 282px; }
  .story-shop { top: 30px; }
  .story-phone { height: 253px; padding-top: 25px; }
  .story-phone-sub { font-size: 8px; }
  .story-ticket { grid-template-columns: minmax(0,1fr) 72px; width: 87%; mask-image: radial-gradient(circle at calc(100% - 72px) 0,transparent 6px,#000 6.5px),radial-gradient(circle at calc(100% - 72px) 100%,transparent 6px,#000 6.5px); }
  .story-ticket-main { padding: 17px 14px; }
  .story-ticket-main > strong { font-size: 23px; margin: 20px 0; }
  .story-ticket-brand { font-size: 8px; }
  .story-ticket-brand small { font-size: 5px; }
  .story-ticket-stub { padding-inline: 9px; }
  .story-code { width: 52px; height: 52px; }
  .story-scanner { inset-inline: 16px; }
  .story-ready .story-captions { min-height: 207px; }
}
@media (max-width:640px) {
  .homepage .how.ticket-story { --story-padding: 60px; --story-top: 88px; }
  .story-layout { grid-template-columns: 1fr; gap: 20px; }
  .story-copy .eyebrow { font-size: 8px; }
  .story-copy h2 { margin-top: 15px; font-size: 37px; }
  .story-intro { margin-top: 13px; font-size: 12px; line-height: 1.65; max-width: 350px; }
  .story-navigation { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 13px; margin-top: 20px; }
  .story-tab { display: flex; align-items: center; gap: 8px; padding: 13px 0 0; }
  .story-tab strong { font-size: 10px; }
  .story-tab small,.story-arrow { display: none; }
  .story-tab[aria-selected=true] { border-top-color: var(--experience-gold); }
  .story-number { font-size: 9px; }
  .story-ready .story-scroll-hint { display: none; }
  .story-stage { border-radius: 14px; }
  .story-stage-heading { min-height: 36px; padding: 11px 17px; font-size: 6px; }
  .story-art { height: 213px; }
  .story-orbit { top: -32px; width: 275px; height: 275px; left: calc(50% - 137px); }
  .story-shop { top: 10px; width: 82%; }
  .story-shop-bar { height: 24px; }
  .story-shop > img { height: 102px; }
  .story-shop-footer { padding: 9px 12px; font-size: 9px; }
  .story-phone { top: 7px; height: 199px; border-width: 3px; border-radius: 18px; padding: 22px 13px; }
  .story-phone-speaker { top: 6px; height: 3px; }
  .story-phone-title { font-size: 14px; }
  .story-phone-sub { font-size: 7px; margin-top: 3px; }
  .story-phone-bottom { bottom: 10px; font-size: 8px; }
  .story-ticket { width: 83%; grid-template-columns: minmax(0,1fr) 73px; mask-image: radial-gradient(circle at calc(100% - 73px) 0,transparent 6px,#000 6.5px),radial-gradient(circle at calc(100% - 73px) 100%,transparent 6px,#000 6.5px); }
  .story-ticket-main { padding: 12px 16px; }
  .story-ticket-main > strong { font-size: 24px; margin: 13px 0 12px; }
  .story-ticket-brand { font-size: 8px; }
  .story-ticket-brand small { font-size: 5px; }
  .story-ticket-meta { font-size: 5px; gap: 3px; }
  .story-ticket-meta span:first-child { font-size: 7px; }
  .story-ticket-stub { padding: 13px 9px; gap: 9px; }
  .story-code { width: 53px; height: 53px; }
  .story-scan-check { inset: 6px; }
  .story-scanner { inset: 23px 18px 30px; }
  .story-scanner > span { width: 20px; height: 20px; }
  .story-arrival { bottom: 6px; font-size: 9px; }
  .story-captions { padding: 17px 19px 15px; }
  .story-ready .story-captions { min-height: 167px; }
  .story-overline { font-size: 7px; }
  .story-panel h3 { margin-top: 6px; font-size: 19px; }
  .story-panel p { font-size: 11px; line-height: 1.65; margin-top: 7px; }
  .story-ready .story-next { padding-top: 8px; min-height: 33px; font-size: 10px; }
  .story-ready .story-scan-reset { padding-top: 8px; font-size: 9px; }
  .story-scan-actions { gap: 12px; }
}
@media (max-width:360px) {
  .story-copy h2 { font-size: 32px; }
  .story-copy .eyebrow { font-size: 7px; }
  .story-intro { font-size: 11px; }
  .story-tab { gap: 5px; }
  .story-tab strong { font-size: 9px; }
  .story-art { height: 199px; }
  .story-phone { height: 185px; }
  .story-ticket { width: 87%; }
  .story-ticket-main { padding-inline: 12px; }
  .story-ticket-main > strong { font-size: 22px; }
  .story-ticket-brand small { font-size: 4px; }
  .story-ticket-meta { font-size: 4px; }
  .story-panel h3 { font-size: 18px; }
  .story-ready .story-captions { min-height: 185px; }
}
@media (prefers-reduced-motion:reduce) {
  .story-ticket { transform: translate(-50%,-50%) !important; }
}
