/* Faluf concept pages (deepwater, outclimb, sendline .faluf.com). One template; each concept's colours come from its
   key art (theme.css, written by build.mjs) and its wordmark has its own cut of Archivo. */

@font-face {
  font-family: "Archivo";
  src: url("fonts/archivo-var-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

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

html {
  background: var(--bg);
  color: var(--ink);
  font-family: "Archivo", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

body {
  margin: 0;
}

a {
  color: inherit;
  text-underline-offset: 0.2em;
  text-decoration-thickness: 1px;
}

a:focus-visible,
.play:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 4px;
}

/* ---------- the hero: the trailer ---------- */

.hero {
  --player-accent: var(--accent);
  --player-ink: var(--ink);
  position: relative;
  height: max(34rem, min(100svh, 56.25vw));
  overflow: hidden;
  background: var(--bg);
}

.hero-video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: var(--bg);
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 35%;
  background: linear-gradient(to bottom, transparent, var(--bg));
  pointer-events: none;
}

.hero.is-playing::after {
  display: none;
}

.hero.is-playing .hero-video {
  object-fit: contain;
  background: #000;
}

.hero-overlay,
.after {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  flex-direction: column;
  padding: clamp(4.5rem, 10vh, 6.5rem) clamp(1.25rem, 6vw, 5rem) clamp(2rem, 8vh, 5rem);
}

.hero.is-playing .hero-overlay,
.hero.is-ended .hero-overlay {
  display: none;
}

/* A dark veil behind the title keeps it readable over bright key art. */
.hero-overlay {
  background: linear-gradient(to bottom, rgb(0 0 0 / 55%), rgb(0 0 0 / 0%) 45%);
}

.kind {
  margin: 0 0 0.6rem;
  font-size: 0.9375rem;
  color: var(--quiet);
  text-shadow: 0 0 1rem rgb(0 0 0 / 80%);
}

.wordmark {
  margin: 0;
  line-height: 0.95;
  color: var(--ink);
  text-shadow: 0 0 2rem rgb(0 0 0 / 55%);
}

.wordmark-deepwater {
  font-size: clamp(2.4rem, 7vw, 6rem);
  font-weight: 500;
  font-stretch: 112%;
  letter-spacing: 0.16em;
}

.wordmark-outclimb {
  font-size: clamp(3rem, 10vw, 8.5rem);
  font-weight: 900;
  font-stretch: 62%;
  letter-spacing: -0.01em;
}

.wordmark-sendline {
  font-size: clamp(2.6rem, 8.5vw, 7.25rem);
  font-weight: 800;
  font-stretch: 125%;
  letter-spacing: 0.02em;
  transform: skewX(-9deg);
  transform-origin: left bottom;
}

.tagline {
  max-width: 34em;
  margin: 1rem 0 0;
  font-size: clamp(1.05rem, 1.8vw, 1.35rem);
  text-shadow: 0 0 1.25rem rgb(0 0 0 / 85%);
}

.start {
  margin-top: auto;
}

.play {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.85rem 1.6rem 0.85rem 1.25rem;
  border: 1px solid var(--accent);
  border-radius: 2rem;
  background: rgb(0 0 0 / 55%);
  color: var(--ink);
  font: inherit;
  font-size: 1.0625rem;
  font-weight: 600;
  cursor: pointer;
}

.play:hover {
  background: var(--accent);
  color: #111;
}

.play-icon {
  width: 1.25rem;
  height: 1.25rem;
  fill: currentColor;
}

.after {
  align-items: center;
  justify-content: center;
  gap: 2rem;
  background: rgb(0 0 0 / 70%);
}

.after[hidden] {
  display: none;
}

.end-line {
  margin: 0;
  font-size: clamp(1.8rem, 5vw, 3.4rem);
  font-weight: 300;
  text-align: center;
  animation: surface 1.4s ease-out both;
}

@keyframes surface {
  from {
    opacity: 0;
  }
}

/* ---------- the story ---------- */

.story,
.footer {
  max-width: calc(36rem + 2 * clamp(1.25rem, 5vw, 2.5rem));
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 2.5rem);
}

.story {
  padding-top: clamp(2.5rem, 6vw, 4.5rem);
}

.prose p {
  margin: 0 0 1.1em;
  font-size: 1.1875rem;
  line-height: 1.65;
  color: var(--quiet);
}

.prose p:first-child {
  color: var(--ink);
  font-size: 1.3rem;
}

.status {
  margin: 2rem 0 0;
  font-weight: 600;
  color: var(--accent);
}

.footer {
  margin-top: clamp(4rem, 10vw, 6rem);
  padding-top: 1.5rem;
  padding-bottom: 3rem;
  border-top: 1px solid color-mix(in srgb, var(--quiet) 25%, transparent);
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--quiet);
}

.footer p {
  margin: 0;
}

/* ---------- the way home ---------- */

/* Faluf's wordmark as on faluf.com, top left over the hero; it steps aside while the trailer plays. */
.site-bar {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 5;
  padding: clamp(1rem, 2.4vw, 1.6rem) clamp(1.25rem, 6vw, 5rem);
  transition: opacity 0.4s ease;
}

body:has(.hero.is-playing) .site-bar {
  opacity: 0;
  pointer-events: none;
}

.faluf-mark {
  color: var(--ink);
  font-size: 1.5rem;
  font-weight: 800;
  font-stretch: 62%;
  letter-spacing: 0.04em;
  text-decoration: none;
  text-shadow: 0 1px 0.75rem rgb(0 0 0 / 60%);
}

.faluf-mark:hover {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.25em;
}

.faluf-mark:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 4px;
}
