/* ==========================================================================
   Jolt Life
   Same palette and button language as cypresscreektv.com, extended for two
   card grids. Everything worth tuning is a custom property in :root.
   ========================================================================== */

:root {
  --ink: #0a0d0c;              /* page background */
  --ink-2: #0e1211;            /* alternating section band */
  --paper: #ffffff;
  --muted: rgba(255, 255, 255, 0.62);
  --faint: rgba(255, 255, 255, 0.42);
  --accent: #e11d18;           /* the red, carried over from Cypress Creek */
  --accent-hot: #ff2a24;
  --line: rgba(255, 255, 255, 0.18);
  --line-soft: rgba(255, 255, 255, 0.09);

  --container: 78rem;          /* outer width the content aligns to */
  --pad: clamp(1.25rem, 4vw, 3rem);
  --bar-h: 4.5rem;             /* sticky bar height; anchors offset by this */
  /* The SVG wordmark is a tighter crop than the old PNG (no built-in padding
     and a longer ratio), so these run larger than the PNG-era numbers to keep
     the same visual weight on screen. */
  --logo-w: clamp(13rem, 28vw, 20rem);
}

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

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

body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: "Helvetica Neue", Helvetica, Arial, system-ui, sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

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

/* Every jump target clears the sticky bar rather than hiding under it. */
:target,
section[id] { scroll-margin-top: var(--bar-h); }

/* --------------------------------------------------------------------------
   Sticky bar — transparent and out of the way until the hero is behind you
   -------------------------------------------------------------------------- */

.bar {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  height: var(--bar-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-inline: var(--pad);
  background: rgba(10, 13, 12, 0.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line-soft);
  /* Held off-screen over the hero. JS adds .is-visible past it. */
  transform: translateY(-100%);
  opacity: 0;
  transition: transform 0.28s ease, opacity 0.28s ease;
}

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

.bar__mark img { width: 8rem; }

.bar__nav {
  display: flex;
  gap: clamp(0.75rem, 3vw, 2rem);
}

.bar__nav a {
  position: relative;
  padding: 0.35rem 0;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  text-decoration: none;
  transition: color 0.18s ease;
}

/* The underline is drawn rather than inherited so it can animate from zero. */
.bar__nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.22s ease;
}

.bar__nav a:hover,
.bar__nav a:focus-visible,
.bar__nav a.is-current { color: var(--paper); }

.bar__nav a:hover::after,
.bar__nav a:focus-visible::after,
.bar__nav a.is-current::after { transform: scaleX(1); }

/* --------------------------------------------------------------------------
   Hero
   Stacking, bottom to top: graphic (0) → scrim (1) → content (2)
   -------------------------------------------------------------------------- */

.hero {
  position: relative;
  isolation: isolate;
  min-height: min(100svh, 52rem);
  display: flex;
  align-items: center;
  padding: calc(var(--bar-h) + 2rem) var(--pad) clamp(3rem, 8vh, 4.5rem);
  overflow: hidden;
}

.hero__media {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: var(--ink);
}

/* Fills the hero whatever its height, cropping from the centre. Swap the
   graphic and this needs no changes — only object-position if the crop is
   wrong for your art. */
.hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* Darkens the left for the wordmark and the bottom for the buttons */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(6, 9, 8, 0.94) 0%, rgba(6, 9, 8, 0.74) 40%, rgba(6, 9, 8, 0.18) 82%, rgba(6, 9, 8, 0.4) 100%),
    linear-gradient(180deg, rgba(6, 9, 8, 0.5) 0%, transparent 28%, rgba(6, 9, 8, 0.6) 76%, rgba(6, 9, 8, 0.95) 100%);
}

.hero__inner {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
}

.hero__logo { margin: 0; }

.hero__logo img {
  width: var(--logo-w);
  filter: drop-shadow(0 0.15em 1.75rem rgba(0, 0, 0, 0.7));
}

.rule {
  width: 4.5rem;
  height: 0.375rem;
  margin: clamp(1.5rem, 4vw, 2.25rem) 0 clamp(1.25rem, 3vw, 1.75rem);
  background: var(--accent);
}

.hero__tagline {
  max-width: 40rem;
  margin: 0 0 clamp(2rem, 5vw, 2.75rem);
  font-size: clamp(1.0625rem, 1.6vw, 1.3125rem);
  color: rgba(255, 255, 255, 0.86);
  text-shadow: 0 0.1em 1rem rgba(0, 0, 0, 0.6);
}

.hero__actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 17rem));
  gap: 0.75rem;
}

/* Chevron nudging you into the first section */
.hero__scroll {
  position: absolute;
  z-index: 2;
  left: 50%;
  bottom: clamp(1.25rem, 4vh, 2rem);
  translate: -50% 0;
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  color: var(--paper);
  opacity: 0.5;
  transition: opacity 0.18s ease, translate 0.18s ease;
}

.hero__scroll svg { width: 1.5rem; height: 1.5rem; }

.hero__scroll:hover,
.hero__scroll:focus-visible {
  opacity: 1;
  translate: -50% 3px;
}

/* --------------------------------------------------------------------------
   Buttons — lifted from Cypress Creek so the two sites feel related
   -------------------------------------------------------------------------- */

.actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: 0.75rem;
  max-width: 58rem;
}

.btn {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 1.0625rem 1.375rem;
  border: 1px solid var(--line);
  border-radius: 0.25rem;
  background: rgba(10, 13, 12, 0.5);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: var(--paper);
  text-decoration: none;
  transition: background-color 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}

.btn__label {
  font-size: 1rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.btn__sub {
  font-size: 0.8125rem;
  color: var(--muted);
}

.btn:hover,
.btn:focus-visible {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.45);
  transform: translateY(-2px);
}

.btn--primary {
  background: var(--accent);
  border-color: var(--accent);
}

.btn--primary .btn__sub { color: rgba(255, 255, 255, 0.82); }

.btn--primary:hover,
.btn--primary:focus-visible {
  background: var(--accent-hot);
  border-color: var(--accent-hot);
}

.btn:focus-visible {
  outline: 2px solid var(--paper);
  outline-offset: 3px;
}

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

.section {
  padding: clamp(4rem, 11vh, 7.5rem) var(--pad);
}

/* The seam under the hero: its dark fade already separates, so the first
   section doesn't need the full top padding on top of the hero's bottom
   padding — together they read as a hole in the page. */
.hero + .section { padding-top: clamp(2rem, 5vh, 3rem); }

.section--alt {
  background: var(--ink-2);
  border-block: 1px solid var(--line-soft);
}

.section__inner {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
}

.section__head { margin-bottom: clamp(2.25rem, 5vw, 3.5rem); }
.section__head--flush { margin-bottom: clamp(1.75rem, 4vw, 2.5rem); }

.section__title {
  margin: 0;
  font-size: clamp(1.875rem, 4.5vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.08;
}

.section__lede {
  max-width: 46rem;
  margin: 1rem 0 0;
  font-size: clamp(1rem, 1.4vw, 1.125rem);
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   Grids
   Brands are 16:9 and wide; shows are 2:3 posters and narrow. The shapes are
   deliberately different so the two sections never read as one list twice.
   -------------------------------------------------------------------------- */

.grid { display: grid; gap: clamp(1rem, 2.5vw, 1.75rem); }

/* Brands use auto-FIT with a 24rem ceiling rather than 1fr: with one brand in
   the section, a 1fr track would stretch that single card across the whole
   78rem container and its 16:9 art would tower over everything. Capped, the
   lone card sits at a sane size, and three of them still fill the row exactly
   once you add more (3 x 24rem + gaps fits inside 78rem).

   Shows keep 1fr — there are seven of them, so the row is always full. 16rem
   is the minimum that yields four columns at container width. */
.grid--brands { grid-template-columns: repeat(auto-fit, minmax(20rem, 24rem)); }
.grid--shows  { grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr)); }

/* While there is only one brand, 24rem leaves the key art too small to read.
   Give a lone card more room; the moment a second one lands this stops
   matching and both fall back to the 24rem track above. */
.grid--brands:has(.card:only-child) { grid-template-columns: minmax(0, 32rem); }

/* --------------------------------------------------------------------------
   Brand card
   -------------------------------------------------------------------------- */

.card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line-soft);
  border-radius: 0.25rem;
  background: rgba(255, 255, 255, 0.02);
  overflow: hidden;
  transition: border-color 0.18s ease, transform 0.18s ease, background-color 0.18s ease;
}

.card:hover {
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.045);
  transform: translateY(-3px);
}

.card__art {
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #101416;
  border-bottom: 1px solid var(--line-soft);
}

.card__art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.card:hover .card__art img { transform: scale(1.03); }

.card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 1.25rem 1.375rem 1.125rem;
}

.card__title {
  margin: 0;
  font-size: 1.0625rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* Brand logo standing in for the title text. Sized against the type it
   replaced, not the box, so a long wordmark stays a heading, not a banner. */
.card__title--logo img {
  width: min(13rem, 70%);
  height: auto;
}

/* Homestead Oil's wordmark is a single wide line (11:1) where Cypress
   Creek's is a stacked lockup — at equal widths it reads far lighter, so it
   gets more of the card to carry comparable weight. */
.card__title--logo img[src*="homestead"] { width: min(22rem, 100%); }

.card__meta {
  margin: 0.375rem 0 0;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
}

.card__blurb {
  margin: 0.75rem 0 0;
  font-size: 0.9375rem;
  color: var(--muted);
}

/* Pushed to the bottom so cards of unequal copy still line their feet up. */
.card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: auto;
  padding-top: 1.125rem;
}

.link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--paper);
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  text-decoration: none;
  border-bottom: 2px solid var(--accent);
  padding-bottom: 0.15rem;
  transition: color 0.18s ease;
}

.link svg {
  width: 0.95rem;
  height: 0.95rem;
  transition: transform 0.18s ease;
}

.link:hover svg { transform: translateX(3px); }
.link:hover { color: var(--accent-hot); }

/* --------------------------------------------------------------------------
   Social glyph rows
   -------------------------------------------------------------------------- */

.social { display: flex; gap: 0.25rem; }

.social a,
.social .social__soon {
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;          /* full tap target around a small glyph */
  border-radius: 0.25rem;
  color: var(--paper);
  opacity: 0.6;
  transition: opacity 0.18s ease, background-color 0.18s ease;
}

/* Accounts that exist but haven't launched: the glyphs stay as a signal of
   where the brand will live, but they are spans, not links — dimmer, no
   hover, nothing to click. Swap them back to <a> tags at launch. */
.social .social__soon {
  opacity: 0.3;
  cursor: default;
}

.social svg {
  width: 1.125rem;
  height: 1.125rem;
  fill: currentColor;
}

/* Instagram is drawn as outlines, not a filled silhouette. This has to be a
   CSS rule rather than a fill="none" attribute — the rule above would win. */
.social svg.is-stroke {
  fill: none;
  stroke: currentColor;
}

.social a:hover,
.social a:focus-visible {
  opacity: 1;
  background: rgba(255, 255, 255, 0.1);
}

/* --------------------------------------------------------------------------
   Show poster
   -------------------------------------------------------------------------- */

.show {
  display: flex;
  flex-direction: column;
  transition: transform 0.18s ease;
}

.show:hover { transform: translateY(-3px); }

.show__art {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border: 1px solid var(--line-soft);
  border-radius: 0.25rem;
  background: #101416;
  transition: border-color 0.18s ease;
}

.show:hover .show__art { border-color: rgba(255, 255, 255, 0.3); }

.show__art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.show:hover .show__art img { transform: scale(1.03); }

.show__body { padding: 0.9375rem 0.125rem 0; }

.show__title {
  margin: 0;
  font-size: 1rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* The network logo, under the poster. Height-normalised in the SVG files, so
   one rule sizes every network; width falls out of each logo's own ratio.
   Dimmed to sit behind the art in the hierarchy — these are credits, not the
   subject. */
.show__net {
  height: 1.125rem;
  width: auto;
  margin-top: 0.125rem;
  opacity: 0.55;
  /* Forces any logo to solid white, whatever colours the file ships with —
     new network files need no editing, just drop them in. */
  filter: brightness(0) invert(1);
  transition: opacity 0.18s ease;
}

/* Per-logo balance: marks with stacked or two-line lockups need more height
   than wide wordmarks to carry the same visual weight. */
.show__net[src*="magnolia"] { height: 1.625rem; }
.show__net[src*="turbo"] { height: 1.25rem; }
.show__net[src*="motortrend"] { height: 1rem; }

/* A show credited to more than one network — the logos sit in a row. */
.show__nets {
  display: flex;
  align-items: center;
  gap: 0.875rem;
}

.show:hover .show__net { opacity: 0.85; }

/* Visually hidden, still read by screen readers and search engines. */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.show__blurb {
  margin: 0.5rem 0 0;
  font-size: 0.875rem;
  color: var(--muted);
}

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

.foot {
  padding: clamp(2.5rem, 7vh, 4rem) var(--pad) clamp(2rem, 5vh, 3rem);
  border-top: 1px solid var(--line-soft);
}

.foot__inner {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.8125rem;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.foot__inner img { width: 8rem; opacity: 0.72; }
.foot__inner p { margin: 0; }

/* --------------------------------------------------------------------------
   Focus + motion
   -------------------------------------------------------------------------- */

a:focus-visible {
  outline: 2px solid var(--paper);
  outline-offset: 3px;
}

@media (max-width: 44rem) {
  .hero { min-height: auto; }
  .hero__actions { grid-template-columns: 1fr; }

  /* No blur on phones — it smears the graphic into a frosted smudge behind
     the button text. Near-solid instead. */
  .btn {
    background: rgba(10, 13, 12, 0.88);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  .btn--primary { background: var(--accent); }

  .grid--shows { grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr)); }
  .bar__nav { gap: 0.875rem; }
  .bar__nav a { font-size: 0.6875rem; letter-spacing: 0.08em; }
  .bar__mark img { width: 6rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
