/*
 * Jinn Studios — styles.css
 * -------------------------
 * Only what Tailwind's CDN build can't express cleanly: the nav's transparent→solid scroll
 * state, the reduced-motion/failed-load static hero fallback, the section-header underline
 * token, card styling shared across capabilities/projects/press/CTA banners, and the
 * fade+rise reveal transition used by every below-fold section (app.js just toggles a class;
 * the actual motion lives here).
 */

html {
  scroll-behavior: auto; /* let Lenis own smooth scrolling; don't double up with native CSS smoothing */
}

section[id] {
  scroll-margin-top: 88px; /* keeps anchor-jumped sections clear of the fixed nav */
}

/* ---------------------------------------------------------------------- */
/* Nav: transparent over the hero, solid once scrolled                    */
/* ---------------------------------------------------------------------- */

#site-nav {
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.45), transparent);
  border-bottom: 1px solid transparent;
}

#site-nav.site-nav--solid {
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

/* ---------------------------------------------------------------------- */
/* Static fallback: reduced-motion, or frame 0 failing to load            */
/* ---------------------------------------------------------------------- */

.hero-static-fallback {
  background: url('images/hero-poster.webp') center center / cover no-repeat;
}

/* ---------------------------------------------------------------------- */
/* Section header underline — the mint bar under every section title,     */
/* the one recurring brand motif carried over from old_site's home.css.   */
/* ---------------------------------------------------------------------- */

.section-header h2 {
  position: relative;
  padding-bottom: 22px;
}

.section-header h2::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 64px;
  height: 3px;
  border-radius: 2px;
  background: linear-gradient(90deg, #15c79a, #0ba67e);
  box-shadow: 0 0 12px rgba(21, 199, 154, 0.45);
}

/* ---------------------------------------------------------------------- */
/* Card surface shared by capability / project / press / CTA blocks       */
/* ---------------------------------------------------------------------- */

.price-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1rem;
  transition: border-color 0.3s ease, transform 0.3s ease, background 0.3s ease;
}

.price-card:hover {
  border-color: rgba(21, 199, 154, 0.35);
  background: rgba(255, 255, 255, 0.045);
  transform: translateY(-4px);
}

.cap-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 0.75rem;
  background: rgba(21, 199, 154, 0.1);
  border: 1px solid rgba(21, 199, 154, 0.25);
  color: #3be3b8;
}

.cap-icon svg {
  width: 24px;
  height: 24px;
}

/* ---------------------------------------------------------------------- */
/* Reveal — fade+rise on first scroll into view. app.js toggles           */
/* `.is-visible`; the transition itself lives here so timing/easing stay  */
/* in one place. Mirrors old_site's fadeUp (opacity+translateY) idiom,    */
/* just scroll-triggered via CSS transitions instead of anime.js.         */
/* ---------------------------------------------------------------------- */

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s cubic-bezier(0.16, 0.8, 0.24, 1), transform 0.7s cubic-bezier(0.16, 0.8, 0.24, 1);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Staggered entrance for grid/list children — capability cards, project cards, team cards,
   stat blocks. Six steps covers every grid on this page (the largest is the 6-card
   capabilities grid); anything beyond nth-child(6) just shares that last delay. */
.reveal-group > .reveal:nth-child(1) { transition-delay: 0ms; }
.reveal-group > .reveal:nth-child(2) { transition-delay: 80ms; }
.reveal-group > .reveal:nth-child(3) { transition-delay: 160ms; }
.reveal-group > .reveal:nth-child(4) { transition-delay: 240ms; }
.reveal-group > .reveal:nth-child(5) { transition-delay: 320ms; }
.reveal-group > .reveal:nth-child(n+6) { transition-delay: 400ms; }

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}
