:root {
  --bg: #1a1612;
  --cream: #f0ead6;
  --gold: #c9a961;
  --warm-gray: #c9c2b2;
  --warm-gray-low: rgba(201, 194, 178, 0.55);

  --serif: "DM Serif Display", Georgia, "Times New Roman", serif;
  --sans: "Source Sans 3", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Consolas, monospace;

  --hero-pad-x: clamp(1.25rem, 4vw, 4rem);
  --hero-pad-y: clamp(1.5rem, 4vh, 3rem);
}

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

html,
body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--cream);
  font-family: var(--sans);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  min-height: 100vh;
  overflow-x: hidden;
}

main {
  display: block;
}

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

/* ============================================================
   HERO
   ============================================================ */

.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  height: 100svh;
  min-height: 600px;
  overflow: hidden;
  isolation: isolate;
}

/* --- Media layer ------------------------------------------------ */

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

.hero__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* Anchor the warm pool of light to the left third on wide screens. */
  object-position: 25% center;
  display: block;
  pointer-events: none;
  will-change: opacity;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      to bottom,
      rgba(26, 22, 18, 0.72) 0%,
      rgba(26, 22, 18, 0.18) 18%,
      rgba(26, 22, 18, 0) 38%,
      rgba(26, 22, 18, 0) 62%,
      rgba(26, 22, 18, 0.28) 82%,
      rgba(26, 22, 18, 0.78) 100%
    ),
    /* Right-side wash so the typography sits on a calmer field. */
    linear-gradient(
      to left,
      rgba(26, 22, 18, 0.55) 0%,
      rgba(26, 22, 18, 0.18) 45%,
      rgba(26, 22, 18, 0) 70%
    );
  pointer-events: none;
}

/* --- Content layer ---------------------------------------------- */

.hero__content {
  position: relative;
  z-index: 1;
  height: 100%;
  display: grid;
  grid-template-rows: auto 1fr auto;
  /* Type lives on the right two-thirds on wide screens. */
  grid-template-columns: 1fr;
  padding: var(--hero-pad-y) var(--hero-pad-x);
  gap: 1rem;
}

.hero__eyebrow {
  grid-row: 1;
  display: flex;
  justify-content: flex-end;
}

.hero__eyebrow span {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.22em;
}

.hero__headline {
  grid-row: 2;
  align-self: center;
  justify-self: end;
  margin: 0;
  max-width: min(62ch, 66%);
  text-align: left;

  font-family: var(--serif);
  font-weight: 400;
  font-style: normal;
  color: var(--cream);
  font-size: clamp(2rem, 5.2vw, 5rem);
  line-height: 1.08;
  letter-spacing: -0.005em;
  text-wrap: balance;
}

.hero__headline em {
  font-style: italic;
  color: var(--gold);
}

.hero__attribution {
  grid-row: 3;
  display: flex;
  justify-content: flex-end;
}

.hero__attribution span {
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 400;
  color: var(--warm-gray);
  opacity: 0.7;
  text-transform: uppercase;
  letter-spacing: 0.18em;
}

/* --- Scroll affordance ------------------------------------------ */

.hero__scroll {
  position: absolute;
  bottom: calc(var(--hero-pad-y) * 0.6);
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;

  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;

  font-family: var(--mono);
  font-size: 0.62rem;
  font-weight: 400;
  color: var(--warm-gray-low);
  text-transform: uppercase;
  letter-spacing: 0.32em;

  transition: color 240ms ease, transform 240ms ease;
}

.hero__scroll:hover,
.hero__scroll:focus-visible {
  color: var(--gold);
  outline: none;
}

.hero__scroll-chevron {
  animation: chevron-drift 2.4s ease-in-out infinite;
}

@keyframes chevron-drift {
  0%, 100% { transform: translateY(0); opacity: 0.6; }
  50%      { transform: translateY(4px); opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .hero__scroll-chevron { animation: none; }
}

/* --- Placeholder for future sections ---------------------------- */

.placeholder {
  height: 1px;
  width: 100%;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

/* Tablet: keep right-aligned typography but loosen widths. */
@media (max-width: 1024px) {
  .hero__headline {
    max-width: 78%;
    font-size: clamp(1.9rem, 4.8vw, 3.6rem);
  }
}

/* Mobile: center type stack, video stays as background. */
@media (max-width: 720px) {
  .hero__video {
    /* Pull the warm pool toward center on narrow screens
       so it sits behind the centered type without clipping. */
    object-position: 35% center;
  }

  .hero__overlay {
    background:
      linear-gradient(
        to bottom,
        rgba(26, 22, 18, 0.78) 0%,
        rgba(26, 22, 18, 0.30) 22%,
        rgba(26, 22, 18, 0.30) 78%,
        rgba(26, 22, 18, 0.85) 100%
      );
  }

  .hero__content {
    grid-template-rows: auto 1fr auto;
    text-align: center;
    padding-inline: clamp(1.25rem, 6vw, 2rem);
  }

  .hero__eyebrow,
  .hero__attribution {
    justify-content: center;
  }

  .hero__eyebrow span {
    font-size: 0.66rem;
    letter-spacing: 0.2em;
  }

  .hero__attribution span {
    font-size: 0.6rem;
    letter-spacing: 0.16em;
  }

  .hero__headline {
    justify-self: center;
    text-align: center;
    max-width: 22ch;
    font-size: clamp(1.7rem, 8.5vw, 2.6rem);
    line-height: 1.14;
  }
}

@media (max-width: 380px) {
  .hero__headline {
    font-size: clamp(1.55rem, 8vw, 2rem);
  }

  .hero__attribution span {
    font-size: 0.56rem;
  }
}
