/* Arc preview page. Link AFTER /base.css (which provides --font-sans).

   The tokens and the type scale are Wavelength's, unchanged, so the two product
   pages are the same site. The one thing that differs is the measure: this page
   is a video of an editing window with take names and a ruler in it, and at the
   720px reading width of a text page none of that is legible. So the page is as
   wide as the video and no wider. */

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

:root {
  --color-ground:         #0f0f0f;
  --color-surface:        #161616;
  --color-border:         #272727;
  --color-text-primary:   #e8e4de;
  --color-text-secondary: #b4afa8;
  --color-text-tertiary:  #7d7872;
  --color-accent:         #c8a97e;
  --color-accent-dim:     #8a7659;
  --max-width:            1120px;
  --reading-width:        1120px;

  --fs-label: 0.852rem;
  --fs-small: 1rem;
  --fs-body:  1.174rem;
  --fs-lede:  1.378rem;
  --fs-title: clamp(1.618rem, 5vw, 2.618rem);
}

html {
  background-color: var(--color-ground);
  color: var(--color-text-primary);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

body {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.75rem 1.5rem 2.5rem;
}

/* The same warm glow the other product page opens with. */
body::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: 100vw;
  height: 700px;
  transform: translateX(-50%);
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(70% 60% at 50% 0%, rgba(200, 169, 126, 0.12), transparent 70%);
}

.page { width: 100%; max-width: var(--max-width); }

a { color: inherit; }

/* ---- The page has one job: the film, and the way to hear about it ----
   No headline on screen. The page is the video and the signup under it, and a
   line of type above the film would only push it down. The document still has a
   heading, for a screen reader and for search; it is simply not drawn. */
.offscreen {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ---- The film, full bleed ----
   Edge to edge, and no taller than the viewport minus the room the signup needs:
   the two things this page is for have to be on screen together, on a laptop and
   on a phone. `contain` rather than `cover` because the window chrome is the
   point -- cropping it would be cropping the evidence that this is an app. */
.film {
  position: relative;
  width: 100vw;
  margin-left: calc(50% - 50vw);
  /* The band is painted the app's own background, so where the film does not
     reach the edge of a wide window the page still reads as one surface rather
     than as a video with bars beside it. */
  background: #15171c;
}

.film video {
  display: block;
  width: 100%;
  height: auto;
  max-height: calc(100svh - 15rem);
  object-fit: contain;
}

/* One control, because the browser will not start a video with sound in it and
   a muted demo of an audio tool is only half the product. An icon in the corner
   and no words: it is the control every video on a phone already has, and a
   viewer reaches for it without reading anything. */
.sound {
  position: absolute;
  left: 1rem;
  top: 1rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(15, 15, 15, 0.55);
  color: #fff;
  cursor: pointer;
  backdrop-filter: blur(8px);
  transition: background 0.15s ease, transform 0.12s ease;
}

.sound:hover { background: rgba(15, 15, 15, 0.78); transform: scale(1.05); }
.sound:active { transform: scale(0.96); }

.sound svg { width: 26px; height: 26px; fill: currentColor; }

/* Muted shows the speaker crossed out, playing shows it with its waves. Off
   aria-pressed, so what a screen reader is told and what is drawn are one fact. */
.sound[aria-pressed="false"] .sound-waves { display: none; }
.sound[aria-pressed="true"]  .sound-slash { display: none; }

/* ---- Signup: Wavelength's beta form, component for component ---- */
/* The only words on the page, so they carry it. */
.beta-cta { margin-top: 2rem; text-align: center; }

.beta-title {
  font-size: var(--fs-lede);
  font-weight: 700;
  color: var(--color-text-primary);
  margin-bottom: 1.1rem;
}

.beta-form {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  flex-wrap: wrap;
}

.beta-input {
  font-family: inherit;
  font-size: var(--fs-small);
  padding: 0.6rem 0.95rem;
  min-width: 220px;
  color: var(--color-text-primary);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 999px;
}

.beta-input::placeholder { color: var(--color-text-tertiary); }
.beta-input:focus { outline: none; border-color: var(--color-accent-dim); }

.beta-submit {
  font-family: inherit;
  font-size: var(--fs-small);
  font-weight: 500;
  padding: 0.6rem 1.2rem;
  color: var(--color-accent);
  background: transparent;
  border: 1px solid var(--color-accent-dim);
  border-radius: 999px;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.beta-submit:hover { border-color: var(--color-accent); color: var(--color-text-primary); }
.beta-submit:disabled { opacity: 0.5; cursor: default; }

.beta-note,
.beta-done {
  font-size: var(--fs-label);
  color: var(--color-text-tertiary);
  margin-top: 0.85rem;
}

.beta-done { color: var(--color-accent); }

/* ---- Footer ---- */
.page-footer {
  width: 100%;
  max-width: var(--reading-width);
  border-top: 1px solid var(--color-border);
  padding-top: 2rem;
  margin-top: 4rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  font-size: var(--fs-label);
  color: var(--color-text-tertiary);
  letter-spacing: 0.04em;
}

.page-footer a { color: var(--color-text-tertiary); text-decoration: none; transition: color 0.15s ease; }
.page-footer a:hover { color: var(--color-text-secondary); }

.footer-links { display: flex; gap: 1.5rem; list-style: none; }

@media (max-width: 600px) {
  body { padding: 1.25rem 1.2rem 2rem; }
  .film video { max-height: calc(100svh - 16rem); }
  .sound { right: 0.6rem; bottom: 0.6rem; padding: 0.4rem 0.7rem; }
}
