/* ==========================================================================
   Bedrock Media — home page motion and interaction layer
   Loaded only on the home page, after style.css. Every effect degrades to the
   static layout, and prefers-reduced-motion turns the lot off.
   ========================================================================== */

/* ---------- hero entrance ---------------------------------------------- */
.hero__letters { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: 0.06em; }
.hero__letter { display: inline-block; transform: translateY(110%); animation: letter-up 0.9s var(--ease) forwards; }
.hero__letter:nth-child(1) { animation-delay: 0.05s; }
.hero__letter:nth-child(2) { animation-delay: 0.11s; }
.hero__letter:nth-child(3) { animation-delay: 0.17s; }
.hero__letter:nth-child(4) { animation-delay: 0.23s; }
.hero__letter:nth-child(5) { animation-delay: 0.29s; }
.hero__letter:nth-child(6) { animation-delay: 0.35s; }
.hero__letter:nth-child(7) { animation-delay: 0.41s; }
.hero__wordmark sup { opacity: 0; animation: fade-in 0.6s var(--ease) 0.75s forwards; }
.hero__side { opacity: 0; transform: translateY(14px); animation: rise 0.8s var(--ease) 0.5s forwards; }
.hero__media { opacity: 0; transform: translateY(18px) scale(0.985); animation: media-in 1.1s var(--ease) 0.35s forwards; will-change: transform; }
.hero__trust, .hero__card { opacity: 0; animation: fade-in 0.7s var(--ease) 1.1s forwards; }

@keyframes letter-up { to { transform: translateY(0); } }
@keyframes fade-in { to { opacity: 1; } }
@keyframes rise { to { opacity: 1; transform: none; } }
@keyframes media-in { to { opacity: 1; transform: none; } }

/* ---------- living strata canvas --------------------------------------- */
.hero__canvas { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; transition: opacity 0.8s var(--ease); pointer-events: none; }
.hero__media.is-live .hero__canvas { opacity: 1; }
.hero__media.is-live { cursor: none; }
.hero__media.is-live .hero__card { cursor: pointer; }

/* ---------- statement: scroll-lit words -------------------------------- */
.statement__text.is-scroll .w { color: rgba(17, 17, 17, 0.16); transition: color 0.35s var(--ease); }
.statement__text.is-scroll .w.on { color: var(--ink); }
.statement__text.is-scroll span:not(.w) .w.on { color: var(--muted); }

/* ---------- fact cards ------------------------------------------------- */
.fact { transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease); }
.fact:hover { box-shadow: 0 24px 50px rgba(17, 17, 17, 0.12); }
.fact--dark::after { content: ""; position: absolute; inset: -40%; background: conic-gradient(from 180deg at 50% 50%, transparent 0 70%, rgba(242, 242, 240, 0.12) 80%, transparent 90%); animation: sheen 9s linear infinite; pointer-events: none; }
@keyframes sheen { to { transform: rotate(360deg); } }
.fact--dark > * { position: relative; }

/* ---------- gantt: bars grow in, playhead sweeps ----------------------- */
.gantt { position: relative; overflow: hidden; }
.gantt__col { position: relative; border-radius: 12px; transition: background 0.3s var(--ease); }
.gantt__col:hover { background: rgba(255, 255, 255, 0.55); }
.gantt__bar { transform: scaleX(0); transform-origin: left center; transition: transform 1s var(--ease), background 0.3s; }
.gantt__bar > span { opacity: 0; transition: opacity 0.4s var(--ease); }
.gantt.is-live .gantt__bar { transform: scaleX(1); }
.gantt.is-live .gantt__bar > span { opacity: 1; }
.gantt.is-live .gantt__col:nth-child(1) .gantt__bar { transition-delay: 0.1s; }
.gantt.is-live .gantt__col:nth-child(2) .gantt__bar { transition-delay: 0.45s; }
.gantt.is-live .gantt__col:nth-child(3) .gantt__bar { transition-delay: 0.8s; }
.gantt.is-live .gantt__col:nth-child(4) .gantt__bar { transition-delay: 1.15s; }
.gantt.is-live .gantt__col:nth-child(1) .gantt__bar > span { transition-delay: 0.6s; }
.gantt.is-live .gantt__col:nth-child(2) .gantt__bar > span { transition-delay: 0.95s; }
.gantt.is-live .gantt__col:nth-child(3) .gantt__bar > span { transition-delay: 1.3s; }
.gantt.is-live .gantt__col:nth-child(4) .gantt__bar > span { transition-delay: 1.65s; }
.gantt__col:hover .gantt__bar { background: var(--ember); }
.gantt__playhead { position: absolute; top: 20px; bottom: 20px; left: 20px; width: 2px; background: var(--ember); opacity: 0; pointer-events: none; }
.gantt.is-live .gantt__playhead { animation: sweep 2.4s var(--ease) 0.1s forwards; }
@keyframes sweep { 0% { left: 20px; opacity: 1; } 85% { opacity: 1; } 100% { left: calc(100% - 22px); opacity: 0; } }

/* ---------- expect ------------------------------------------------------ */
.expect__big { position: relative; display: inline-block; }
.expect__hero.is-live .expect__big::after { content: ""; position: absolute; left: 0.1em; top: 50%; width: 0.9em; height: 0.9em; margin-top: -0.45em; border-radius: 50%; border: 2px solid var(--ember); animation: ping 1.8s var(--ease) 0.2s 2; pointer-events: none; }
@keyframes ping { 0% { transform: scale(0.6); opacity: 0.9; } 100% { transform: scale(2.4); opacity: 0; } }
.expect__card { transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), border-color 0.3s; }
.expect__card:hover { border-color: transparent; box-shadow: 0 24px 50px rgba(17, 17, 17, 0.10); }

/* ---------- marquee ----------------------------------------------------- */
.marquee { display: flex; gap: 56px; overflow: hidden; margin-top: 40px; padding-top: 28px; border-top: 1px solid var(--line); -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.marquee__track { display: flex; gap: 56px; flex-shrink: 0; min-width: 100%; justify-content: space-around; font-family: var(--font-display); font-size: 20px; font-weight: 500; color: var(--muted); white-space: nowrap; animation: marquee 32s linear infinite; }
.marquee__track li::before { content: "\25C6"; font-size: 8px; margin-right: 14px; vertical-align: middle; color: var(--ember); }
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(calc(-100% - 56px)); } }

/* ---------- tilt + cursor ring ----------------------------------------- */
.tilt { transform-style: preserve-3d; will-change: transform; }
.cursor { position: fixed; left: 0; top: 0; z-index: 90; width: 14px; height: 14px; border-radius: 50%; background: var(--ink); mix-blend-mode: difference; pointer-events: none; transition: width 0.25s var(--ease), height 0.25s var(--ease), background 0.25s; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--canvas); }
.cursor.is-big { width: 64px; height: 64px; background: var(--canvas); }
.cursor::after { content: attr(data-label); opacity: 0; transition: opacity 0.2s; color: var(--ink); }
.cursor.is-big::after { opacity: 1; }
.cursor.is-big { mix-blend-mode: normal; background: rgba(242, 242, 240, 0.9); box-shadow: 0 8px 24px rgba(17, 17, 17, 0.18); }

/* ---------- reduced motion: everything static -------------------------- */
@media (prefers-reduced-motion: reduce) {
    .hero__letter, .hero__wordmark sup, .hero__side, .hero__media, .hero__trust, .hero__card { animation: none; opacity: 1; transform: none; }
    .hero__canvas { display: none; }
    .hero__media.is-live { cursor: auto; }
    .fact--dark::after { animation: none; display: none; }
    .gantt__bar { transform: none; }
    .gantt__bar > span { opacity: 1; }
    .gantt__playhead { display: none; }
    .marquee__track { animation: none; }
    .marquee__track[aria-hidden="true"] { display: none; }
    .cursor { display: none; }
}
@media (pointer: coarse) {
    .cursor { display: none; }
    .hero__media.is-live { cursor: auto; }
}
