/* ==========================================================================
   Immersion Imagery — immersionimagery.com
   Static site. No build step. Edit these files directly.
   ========================================================================== */

:root {
  --bg:        #0B0B0C;
  --bg-elev:   #141417;
  --bg-raise:  #1B1B1F;
  --line:      #2A2A30;
  --text:      #EDEAE5;
  --muted:     #93939B;
  --dim:       #6C6C74;
  /* Brand gold. The logo was recoloured to match (#C0A068) — keep these two in
     step with it. The original red was #FE0000 if it's ever needed again. */
  --accent:    #C0A068;
  --accent-dim:#8A7343;

  --max:   1180px;
  --gutter: clamp(1.25rem, 4vw, 3rem);

  --font-display: 'Instrument Serif', Georgia, 'Times New Roman', serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: clamp(1rem, 0.97rem + 0.15vw, 1.0625rem);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }

a { color: inherit; text-decoration: none; }

::selection { background: var(--accent); color: #0B0B0C; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 999;
  background: var(--accent); color: #0B0B0C; padding: .75rem 1.25rem; font-weight: 600;
}
.skip:focus { left: 0; }

/* ---------- Typography ---------------------------------------------------- */

h1, h2, h3, h4 { margin: 0; font-weight: 400; line-height: 1.1; }

.display {
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: -0.015em;
  line-height: 1.04;
}

.eyebrow {
  font-size: .75rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 500;
  margin: 0 0 1.25rem;
}

.lede { font-size: clamp(1.125rem, 1.02rem + 0.5vw, 1.375rem); line-height: 1.6; color: #D8D4CD; }

.muted { color: var(--muted); }

/* ---------- Header -------------------------------------------------------- */

.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(11, 11, 12, 0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease), background .3s var(--ease);
}
.site-header.scrolled { border-bottom-color: var(--line); }

.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1.5rem; min-height: 76px;
}

.brand { display: flex; align-items: center; gap: .75rem; flex-shrink: 0; }
.brand img { height: 46px; width: auto; }
@media (max-width: 600px) { .brand img { height: 36px; } }
.footer-logo { height: 54px; width: auto; margin-bottom: 1.25rem; }
.brand-text {
  font-family: var(--font-display);
  font-size: 1.3rem;
  letter-spacing: .01em;
  line-height: 1;
}
.brand-text span { display: block; font-family: var(--font-body); font-size: .58rem; letter-spacing: .26em; text-transform: uppercase; color: var(--dim); margin-top: .3rem; }

.nav { display: flex; align-items: center; gap: 2rem; }
.nav a {
  font-size: .82rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--muted); font-weight: 500; position: relative; padding: .35rem 0;
  transition: color .25s var(--ease);
}
.nav a::after {
  content: ''; position: absolute; left: 0; bottom: 0; height: 1px; width: 0;
  background: var(--accent); transition: width .3s var(--ease);
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); }
.nav a:hover::after, .nav a[aria-current="page"]::after { width: 100%; }

.nav-toggle {
  display: none; background: none; border: 0; cursor: pointer; padding: .5rem;
  color: var(--text);
}
.nav-toggle svg { display: block; }

/* ---------- Hero ---------------------------------------------------------- */

.hero {
  position: relative;
  min-height: clamp(520px, 82vh, 820px);
  display: flex; align-items: flex-end;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}
.hero-media { position: absolute; inset: 0; z-index: 0; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; }
/* The hero now sits over poster artwork rather than a dark photograph, so the
   scrim has to work harder on the left where the headline sits. */
.hero-media::after {
  content: ''; position: absolute; inset: 0;
  background:
    linear-gradient(to top, var(--bg) 1%, rgba(11,11,12,.62) 45%, rgba(11,11,12,.42) 100%),
    linear-gradient(to right, rgba(11,11,12,.95) 0%, rgba(11,11,12,.82) 32%, rgba(11,11,12,.35) 66%, rgba(11,11,12,.15) 100%);
}
@media (max-width: 800px) {
  /* On a narrow screen a 3:1 banner would crop to almost nothing, so shorten
     the hero and let more of the artwork show. */
  .hero { min-height: clamp(440px, 68vh, 620px); }
  .hero-media::after {
    background:
      linear-gradient(to top, var(--bg) 1%, rgba(11,11,12,.72) 50%, rgba(11,11,12,.6) 100%);
  }
}
.hero-inner { position: relative; z-index: 1; width: 100%; padding-block: clamp(3rem, 8vh, 6rem); }
.hero h1 { font-size: clamp(2.75rem, 1.6rem + 5.2vw, 6rem); max-width: 16ch; }
.hero .lede { max-width: 46ch; margin-top: 1.75rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 2.5rem; }

/* Placeholder backdrop used until a real image is supplied */
.placeholder-bg {
  position: absolute; inset: 0;
  background:
    radial-gradient(120% 90% at 20% 10%, #22222A 0%, transparent 55%),
    radial-gradient(100% 80% at 85% 90%, #1A1A20 0%, transparent 60%),
    linear-gradient(160deg, #101014 0%, #0B0B0C 100%);
}
.placeholder-bg::before {
  content: ''; position: absolute; inset: 0; opacity: .5;
  background-image: repeating-linear-gradient(90deg, rgba(255,255,255,.022) 0 1px, transparent 1px 84px);
}

/* ---------- Buttons ------------------------------------------------------- */

.btn {
  display: inline-flex; align-items: center; gap: .6rem;
  padding: .9rem 1.75rem;
  font-size: .8rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
  border: 1px solid var(--accent); color: var(--accent);
  background: transparent; cursor: pointer;
  transition: background .3s var(--ease), color .3s var(--ease), transform .2s var(--ease);
}
.btn:hover { background: var(--accent); color: #0B0B0C; }
.btn:active { transform: translateY(1px); }
.btn--solid { background: var(--accent); color: #0B0B0C; }
.btn--solid:hover { background: transparent; color: var(--accent); }
.btn--ghost { border-color: var(--line); color: var(--text); }
.btn--ghost:hover { background: var(--text); color: #0B0B0C; border-color: var(--text); }

/* ---------- Sections ------------------------------------------------------ */

.section { padding-block: clamp(4rem, 9vw, 8rem); }
.section--tight { padding-block: clamp(3rem, 6vw, 5rem); }
.section + .section { border-top: 1px solid var(--line); }

.section-head { margin-bottom: clamp(2.5rem, 5vw, 4rem); max-width: 60ch; }
.section-head h2 { font-size: clamp(2rem, 1.4rem + 2.4vw, 3.25rem); }
.section-head p { margin: 1.25rem 0 0; }

.rule { height: 1px; background: var(--line); border: 0; margin: 0; }

/* ---------- Film cards ---------------------------------------------------- */

.film-grid {
  display: grid; gap: clamp(1.5rem, 3vw, 2.5rem);
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr));
}

.film-card { display: flex; flex-direction: column; }

.poster {
  position: relative; aspect-ratio: 2 / 3; overflow: hidden;
  background: var(--bg-elev); border: 1px solid var(--line);
  display: grid; place-items: center; text-align: center; padding: 1.5rem;
}
.poster img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.film-card:hover .poster img { transform: scale(1.04); }

/* Poster placeholder styling — looks deliberate, not broken */
.poster--empty {
  background:
    radial-gradient(90% 70% at 50% 0%, #23232B 0%, transparent 60%),
    linear-gradient(170deg, #17171C 0%, #0E0E11 100%);
}
.poster--empty::before {
  content: ''; position: absolute; inset: 0;
  background-image:
    repeating-linear-gradient(0deg, rgba(255,255,255,.03) 0 2px, transparent 2px 16px);
  opacity: .6;
}
.poster--empty .poster-title {
  position: relative;
  font-family: var(--font-display); font-size: 1.35rem; line-height: 1.2;
  color: #B4B0A8;
}
.poster--empty .poster-note {
  position: relative; display: block; margin-top: .9rem;
  font-size: .6rem; letter-spacing: .2em; text-transform: uppercase; color: var(--dim);
}

.film-card h3 { font-family: var(--font-display); font-size: 1.4rem; margin-top: 1.1rem; }
.film-meta {
  font-size: .72rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--accent); margin-top: .55rem;
}
.film-card p { margin: .85rem 0 0; font-size: .94rem; color: var(--muted); line-height: 1.65; }

.credits {
  margin: 1rem 0 0; padding: 0; list-style: none;
  font-size: .8rem; color: var(--dim); line-height: 1.75;
}
.credits strong { color: var(--muted); font-weight: 500; }

.laurel {
  display: inline-flex; align-items: center; gap: .45rem;
  margin-top: .9rem; padding: .35rem .7rem;
  border: 1px solid var(--accent-dim); color: var(--accent);
  font-size: .68rem; letter-spacing: .08em; text-transform: uppercase;
}

/* ---------- Status groups ------------------------------------------------- */

.status-group { margin-bottom: clamp(3.5rem, 7vw, 6rem); }
.status-group:last-child { margin-bottom: 0; }

.status-head {
  display: flex; align-items: baseline; gap: 1.25rem;
  margin-bottom: 2.25rem; padding-bottom: 1rem;
  border-bottom: 1px solid var(--line);
}
.status-head h2 {
  font-size: .82rem; letter-spacing: .2em; text-transform: uppercase;
  color: var(--text); font-weight: 600;
}
.status-head .count { font-size: .75rem; color: var(--dim); letter-spacing: .1em; margin-left: auto; }

/* ---------- Feature rows -------------------------------------------------- */

.feature {
  display: grid; gap: clamp(2rem, 5vw, 4.5rem); align-items: center;
  grid-template-columns: 1fr;
}
@media (min-width: 860px) {
  .feature { grid-template-columns: 1fr 1fr; }
  .feature--flip .feature-media { order: 2; }
}
.feature-media { position: relative; aspect-ratio: 16 / 10; overflow: hidden; border: 1px solid var(--line); }
.feature-media img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- Behind-the-scenes gallery ------------------------------------- */

.gallery {
  display: grid; gap: .75rem;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr));
}
.gallery a {
  display: block; position: relative; aspect-ratio: 3 / 2;
  overflow: hidden; border: 1px solid var(--line); background: var(--bg-elev);
}
.gallery img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .55s var(--ease), filter .35s var(--ease);
}
.gallery a:hover img, .gallery a:focus-visible img { transform: scale(1.05); filter: brightness(1.08); }
.gallery a::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(11,11,12,.35), transparent 45%);
  opacity: 0; transition: opacity .35s var(--ease); pointer-events: none;
}
.gallery a:hover::after { opacity: 1; }

/* ---------- Lightbox ------------------------------------------------------
   Built by JavaScript. Without JS the gallery links still open the full-size
   image directly, so nothing is lost.
   -------------------------------------------------------------------------- */

.lightbox {
  position: fixed; inset: 0; z-index: 2000;
  background: rgba(6, 6, 7, .96);
  display: grid; place-items: center;
  padding: clamp(1rem, 4vw, 3rem);
  opacity: 0; visibility: hidden;
  transition: opacity .3s var(--ease), visibility .3s var(--ease);
}
.lightbox[data-open="true"] { opacity: 1; visibility: visible; }
body.lb-locked { overflow: hidden; }

.lb-figure { margin: 0; display: grid; place-items: center; gap: 1rem; max-width: 100%; max-height: 100%; }
.lb-figure img {
  max-width: 100%; max-height: calc(100vh - 9rem);
  width: auto; height: auto; object-fit: contain;
  border: 1px solid var(--line);
  opacity: 0; transition: opacity .3s var(--ease);
}
.lightbox[data-loaded="true"] .lb-figure img { opacity: 1; }
.lb-caption {
  font-size: .78rem; letter-spacing: .12em; text-transform: uppercase;
  color: var(--muted); text-align: center;
}
.lb-caption b { color: var(--accent); font-weight: 500; }

.lb-btn {
  position: absolute; z-index: 2;
  display: grid; place-items: center;
  width: 48px; height: 48px;
  background: rgba(20, 20, 23, .82); color: var(--text);
  border: 1px solid var(--line); cursor: pointer;
  transition: background .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease);
}
.lb-btn:hover { background: var(--accent); color: #0B0B0C; border-color: var(--accent); }
.lb-close { top: clamp(.75rem, 2vw, 1.5rem); right: clamp(.75rem, 2vw, 1.5rem); }
.lb-prev  { left: clamp(.5rem, 2vw, 1.5rem);  top: 50%; transform: translateY(-50%); }
.lb-next  { right: clamp(.5rem, 2vw, 1.5rem); top: 50%; transform: translateY(-50%); }
.lb-btn[hidden] { display: none; }

.lb-spinner {
  position: absolute; width: 34px; height: 34px;
  border: 2px solid var(--line); border-top-color: var(--accent);
  border-radius: 50%; animation: lb-spin .7s linear infinite;
  opacity: 1; transition: opacity .2s;
}
.lightbox[data-loaded="true"] .lb-spinner { opacity: 0; }
@keyframes lb-spin { to { transform: rotate(360deg); } }

@media (max-width: 600px) {
  .lb-btn { width: 42px; height: 42px; }
  .lb-prev { left: .4rem; } .lb-next { right: .4rem; }
  .lb-figure img { max-height: calc(100vh - 11rem); }
}

/* ---------- Awards -------------------------------------------------------- */

.awards { display: grid; gap: 0; }
.award {
  display: grid; gap: .35rem 2rem; padding: 1.5rem 0;
  border-bottom: 1px solid var(--line);
  grid-template-columns: 1fr;
}
@media (min-width: 720px) {
  .award { grid-template-columns: 1fr 2fr auto; align-items: baseline; }
}
.award:first-child { border-top: 1px solid var(--line); }
.award-film { font-family: var(--font-display); font-size: 1.2rem; }
.award-name { color: var(--muted); font-size: .95rem; }
.award-name strong { color: var(--accent); font-weight: 500; }
.award-year { font-size: .78rem; letter-spacing: .12em; color: var(--dim); }

/* ---------- Team ---------------------------------------------------------- */

.team { display: grid; gap: clamp(2.5rem, 5vw, 4rem); }
@media (min-width: 800px) { .team { grid-template-columns: 1fr 1fr; } }

/* Small portrait beside the bio, rather than a large photo above it. */
.person { display: grid; grid-template-columns: 132px 1fr; gap: 1.5rem 1.75rem; align-items: start; }
.person-photo {
  width: 132px; aspect-ratio: 4 / 5; overflow: hidden;
  border: 1px solid var(--line); position: relative; grid-row: span 2;
}
.person-photo img { width: 100%; height: 100%; object-fit: cover; }
.person > h3, .person > .role, .person > p { grid-column: 2; }
.person h3 { font-family: var(--font-display); font-size: 1.6rem; }
.person .role {
  font-size: .72rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--accent); margin: .5rem 0 1rem;
}
.person p { color: var(--muted); margin: 0 0 1rem; font-size: .95rem; }

@media (max-width: 520px) {
  .person { grid-template-columns: 96px 1fr; gap: 1rem 1.25rem; }
  .person-photo { width: 96px; }
  .person h3 { font-size: 1.4rem; }
}

/* ---------- Stats --------------------------------------------------------- */

.stats { display: grid; gap: 2rem; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.stat-num { font-family: var(--font-display); font-size: clamp(2.5rem, 2rem + 2vw, 3.75rem); color: var(--accent); line-height: 1; }
.stat-label { font-size: .74rem; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); margin-top: .75rem; }

/* ---------- Contact ------------------------------------------------------- */

.contact-grid { display: grid; gap: clamp(2.5rem, 5vw, 4rem); }
@media (min-width: 800px) { .contact-grid { grid-template-columns: 1.2fr 1fr; } }

.contact-item { padding: 1.5rem 0; border-bottom: 1px solid var(--line); }
.contact-item:first-child { border-top: 1px solid var(--line); }
.contact-label { font-size: .7rem; letter-spacing: .18em; text-transform: uppercase; color: var(--dim); margin-bottom: .5rem; }
.contact-value { font-size: 1.1rem; }
.contact-value a { border-bottom: 1px solid var(--accent-dim); transition: border-color .25s var(--ease); }
.contact-value a:hover { border-bottom-color: var(--accent); color: var(--accent); }

.socials { display: flex; gap: .75rem; flex-wrap: wrap; margin-top: 1.5rem; }
.social {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border: 1px solid var(--line); color: var(--muted);
  transition: border-color .25s var(--ease), color .25s var(--ease), background .25s var(--ease);
}
.social:hover { border-color: var(--accent); color: var(--accent); }

/* ---------- Footer -------------------------------------------------------- */

.site-footer { border-top: 1px solid var(--line); padding-block: clamp(3rem, 6vw, 4.5rem) 2.5rem; }
.footer-top { display: grid; gap: 2.5rem; margin-bottom: 3rem; }
@media (min-width: 760px) { .footer-top { grid-template-columns: 2fr 1fr 1fr; } }
.footer-col h4 { font-size: .7rem; letter-spacing: .18em; text-transform: uppercase; color: var(--dim); margin-bottom: 1.1rem; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .6rem; }
.footer-col a { color: var(--muted); font-size: .92rem; transition: color .25s var(--ease); }
.footer-col a:hover { color: var(--accent); }
.footer-bottom {
  display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between;
  padding-top: 2rem; border-top: 1px solid var(--line);
  font-size: .8rem; color: var(--dim);
}

/* ---------- Reveal on scroll ----------------------------------------------
   Deliberately scoped to .js — that class is added by an inline script in the
   <head> of each page. If JavaScript is unavailable or fails, .js is never
   added, these rules never apply, and all content stays visible.
   Never write a bare `.reveal { opacity: 0 }` here.
   -------------------------------------------------------------------------- */

.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ---------- Mobile nav ---------------------------------------------------- */

@media (max-width: 800px) {
  .nav-toggle { display: block; }
  .nav {
    position: fixed; inset: 76px 0 auto; background: var(--bg);
    flex-direction: column; align-items: stretch; gap: 0;
    padding: 1rem var(--gutter) 2rem;
    border-bottom: 1px solid var(--line);
    transform: translateY(-120%); transition: transform .35s var(--ease);
    max-height: calc(100vh - 76px); overflow-y: auto;
  }
  .nav[data-open="true"] { transform: none; }
  .nav a { padding: 1rem 0; font-size: 1rem; border-bottom: 1px solid var(--line); }
  .nav a::after { display: none; }
}
