/**
 * Landing panel.
 *
 * Sits above every other layer and slides up to reveal the browse screen. The
 * draft composed it in a 340x720 artboard: art across the top ~58%, a fade into
 * the page colour, a quote in the upper right, and the identity block anchored
 * to the bottom. Those are expressed proportionally here, with the top and
 * bottom anchored to the safe areas.
 */

.landing {
  position: absolute;
  inset: 0;
  /* Above the overlay host, so it covers the sheet and player too. */
  z-index: 20;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  background: var(--surface-app);
  transform: translateY(0);
  transition: transform 0.8s cubic-bezier(0.7, 0, 0.2, 1);

  /*
   * The draft calls for assets/bg-orbit-3.png, which does not exist yet.
   * Swapping it is this one line.
   */
  --landing-art: url('../assets/saturn-rings.png');
}

.landing.is-entered {
  transform: translateY(-102%);
  pointer-events: none;
}

/* ---- Backdrop ---- */

.landing__art {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 58%;
  background: var(--landing-art) center top / cover no-repeat;
  opacity: 0.85;
}

/* The draft's veil over the art, kept as a pseudo-element rather than a
   second node. */
.landing__art::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(10, 10, 9, 0.3);
}

/* Carries the art down into the page colour so the copy sits on solid ground. */
.landing__fade {
  position: absolute;
  left: 0;
  right: 0;
  top: 14%;
  bottom: 0;
  background: linear-gradient(rgba(10, 10, 9, 0), var(--surface-app) 50%);
}

/* ---- Quote ---- */

.landing__quote {
  position: relative;
  margin: 0;
  /* Right-aligned in the upper right, clear of the notch. */
  margin-left: 38%;
  margin-right: calc(var(--gutter) + var(--sar));
  margin-top: calc(var(--sat) + clamp(28px, 7vh, 64px));
  margin-bottom: auto;
  font-size: var(--fs-base);
  line-height: 1.6;
  color: var(--text-primary);
  text-align: right;
  text-wrap: pretty;
  text-shadow: 0 2px 12px rgba(10, 10, 9, 0.8);
}

/* ---- Identity and copy ---- */

.landing__content {
  position: relative;
  flex: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
  padding-left: max(var(--gutter), var(--sal));
  padding-right: max(var(--gutter), var(--sar));
  padding-bottom: max(var(--space-xl), calc(var(--sab) + var(--space-sm)));
}

.landing__identity {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.landing__eyebrow {
  font-family: var(--font-mono);
  font-size: var(--fs-sm);
  line-height: 1;
  letter-spacing: 0.18em;
  color: var(--text-dim);
}

/**
 * The wordmark, painted in the accent.
 *
 * The file carries a hardcoded fill, so it is used as a mask rather than an
 * image: the glyph's alpha punches through a block of --accent. That keeps the
 * colour in one place (the token) instead of baked into the asset, and means
 * re-exporting the SVG in any colour changes nothing here.
 *
 * The ratio is the source viewBox, 54.00781 / 8.892658.
 */
.landing__wordmark {
  width: min(92%, 320px);
  aspect-ratio: 54.00781 / 8.892658;
  background-color: var(--accent);
  -webkit-mask: url('../assets/wordmark.svg') left center / contain no-repeat;
  mask: url('../assets/wordmark.svg') left center / contain no-repeat;
}

.landing__copy {
  display: flex;
  flex-direction: column;
  gap: 9px;
  font-size: var(--fs-md);
  line-height: 1.5;
  color: var(--text-secondary);
  text-wrap: pretty;
}

.landing__copy p {
  margin: 0;
}

/*
 * Two steps up from the draft's 8px. It now carries a source credit and a
 * contact address, which are there to be read rather than merely present, and
 * the long lines wrap rather than being held to one line each.
 */
.landing__legal {
  display: flex;
  flex-direction: column;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  line-height: 1.5;
  letter-spacing: 0.04em;
  color: var(--text-ghost);
  text-wrap: pretty;
}

/* ---- Descend cue ---- */

.landing__enter {
  align-self: center;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: var(--tap-min);
  min-height: var(--tap-min);
  padding: 0;
  border: 0;
  background: none;
  color: var(--accent);
  cursor: pointer;
}
