/* Tigerstone motion: signature ring, masked headlines, section entrances. Transform and opacity only. */

/* Masked headline: each line rises from behind its own baseline */
.masked .line { display: block; overflow: hidden; padding-bottom: 0.1em; margin-bottom: -0.1em; }
.masked .line-inner { display: block; animation: line-rise 900ms var(--ease-out) both; animation-delay: 250ms; }
.masked .line:nth-child(2) .line-inner { animation-delay: 360ms; }

/* ---------- Section reveals: heading, then text, then picture ---------- */
.motion .reveal .r { opacity: 0; transform: translate3d(0, 28px, 0); transition: opacity 700ms var(--ease-out), transform 900ms var(--ease-out); transition-delay: var(--d, 0ms); }
.motion .reveal.in .r { opacity: 1; transform: none; }

.motion .cta.reveal .cta-title { opacity: 0; transform: translate3d(0, 48px, 0); transition: opacity 900ms var(--ease-out), transform 1100ms var(--ease-out); }
.motion .cta.reveal.in .cta-title { opacity: 1; transform: none; }

/* Sub-page hero: photo opens, mark turns */
.page-hero-photo .drift { animation: photo-open 1300ms var(--ease-out) 200ms both; }
.page-hero-mark { animation: spin 40s linear infinite, mark-in 1100ms var(--ease-out) 500ms both; }
.page-hero-arc { animation: spin 120s linear infinite reverse; }
.page-hero-actions { animation: fade-up 700ms var(--ease-out) 800ms both; }
.page-hero .hero-sentence { animation-delay: 650ms; }
.pitch-hero-shot { animation: photo-open 1300ms var(--ease-out) 300ms both; }
/* Ticker: constant motion, linear */
.ticker-track { animation: ticker 48s linear infinite; }
@media (hover: hover) and (pointer: fine) { .ticker:hover .ticker-track { animation-play-state: paused; } }

/* Marks that keep the brand's turn */
.portrait-ring-mark { animation: spin 60s linear infinite; }
.footer-o { animation: spin 24s linear infinite; }
.time-dot { animation: pulse 2s ease-in-out infinite; }
/* Timeline bars grow to scale when their section arrives */
.motion .reveal .tl-bar { transform: scaleX(0); transition: transform 1100ms var(--ease-out); }
.motion .reveal.in .tl-bar { transform: scaleX(1); }
.motion .reveal.in .tl-mc .tl-bar { transition-delay: 250ms; }
.motion .reveal.in .tl-ts .tl-bar { transition-delay: 500ms; }
/* Footer bars slide in from the right, one after another */
.cbar { animation: bar-in 900ms var(--ease-out) both; animation-timeline: view(); animation-range: entry 0% entry 60%; }
.cbar:nth-child(2) { animation-range: entry 10% entry 70%; }
.cbar:nth-child(3) { animation-range: entry 20% entry 80%; }

/* ---------- Keyframes ---------- */
@keyframes spin { to { rotate: 1turn; } }
@keyframes wave { 0% { opacity: 1; } 55% { opacity: 0.5; } 100% { opacity: 1; } }
@keyframes ring-in { from { opacity: 0; scale: calc(var(--s) * 0.55); } to { opacity: 1; scale: var(--s); } }
@keyframes line-rise { from { transform: translate3d(0, 105%, 0); } to { transform: none; } }
@keyframes fade-up { from { opacity: 0; transform: translate3d(0, 16px, 0); } to { opacity: 1; transform: none; } }
@keyframes photo-open { from { clip-path: inset(12% 0 0 0); opacity: 0.4; } to { clip-path: inset(0); opacity: 1; } }
@keyframes ticker { to { transform: translateX(-50%); } }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }
@keyframes bar-in { from { opacity: 0; translate: 80px 0; } to { opacity: 1; translate: 0 0; } }
@keyframes mark-in { from { opacity: 0; scale: 0.85; } to { opacity: 1; scale: 1; } }
@media (prefers-reduced-motion: no-preference) {
  ::view-transition-old(root) { animation: 180ms ease both vt-out; }
  ::view-transition-new(root) { animation: 380ms var(--ease-out) both vt-in; }
}
@keyframes vt-out { to { opacity: 0; } }
@keyframes vt-in { from { opacity: 0; } }


/* ---------- Reduced motion: keep content and fades, drop travel ---------- */
@media (prefers-reduced-motion: reduce) {
  .ring-item, .ring-bar::before, .brand-mark, .sit-mark, .page-hero-mark, .page-hero-arc, .page-hero-photo .drift, .pitch-hero-shot, .page-hero-actions, .masked .line-inner, .hero-sentence, .hero-action, .ticker-track, .portrait-ring-mark, .footer-o, .time-dot, .cbar { animation: none !important; }
  .motion .reveal .tl-bar { transform: none; }
  .site-header.is-hidden { transform: none; }
  .ticker-group[aria-hidden] { display: none; }
  .ticker-track { flex-wrap: wrap; width: auto; }
  .ticker-group { flex-wrap: wrap; row-gap: 12px; }
  .motion .reveal .r, .motion .cta.reveal .cta-title { transform: none !important; transition: opacity 300ms ease !important; }
  .sit-photo { transition: opacity 300ms ease; transform: none; }
  .stage { transition: none; }
  html { scroll-behavior: auto; }
}

/* Rhythm chart: an idle breath, like an equaliser at rest */
.rb { animation: rb-breathe 3.2s ease-in-out infinite; animation-delay: calc(var(--i) * -0.2s); }
@keyframes rb-breathe { 0%, 100% { translate: 0 0; } 50% { translate: 0 -6px; } }

/* Price: highlighters swipe in, spray strokes are drawn, the sticker slaps on */
.motion .price.reveal .hl::before { clip-path: inset(0 100% 0 0); transition: clip-path 650ms var(--ease-out) var(--hd, 600ms); }
.motion .price.reveal.in .hl::before { clip-path: inset(-20% -10% -20% -10%); }
.motion .price.reveal .strike path { stroke-dashoffset: 100; transition: stroke-dashoffset 450ms var(--ease-out) 450ms; }
.motion .price.reveal .strike-x path:last-child { transition-delay: 750ms; }
.motion .price.reveal.in .strike path { stroke-dashoffset: 0; }
.motion .price.reveal .sticker { opacity: 0; transform: rotate(-14deg) scale(1.35); transition: opacity 200ms ease 1300ms, transform 450ms cubic-bezier(0.34, 1.56, 0.64, 1) 1300ms; }
.motion .price.reveal.in .sticker { opacity: 1; transform: rotate(-5deg) scale(1); }
@media (prefers-reduced-motion: reduce) {
  .rb { animation: none !important; }
  .slat { display: none; }
  .stage-photo img, .stage-photo-mark img { transform: none !important; }
}
.motion .price.reveal .sticker-2 { transition-delay: 1450ms; }
.motion .price.reveal .savings-tag { opacity: 0; transform: rotate(-12deg) scale(1.4); transition: opacity 200ms ease 1900ms, transform 500ms cubic-bezier(0.34, 1.56, 0.64, 1) 1900ms; }
.motion .price.reveal.in .savings-tag { opacity: 1; transform: rotate(-3deg) scale(1); }
