/* The home page. The colours are the clip's own: the night sky at its top, the lake below, and the soft mint of
   the sit's line of light. The fonts are the app's: Fluxisch Else for the words, Hanken Grotesk for the rest. */

@font-face {
  font-family: "Fluxisch Else";
  src: url("/fonts/FluxischElse-Light.otf") format("opentype");
  font-weight: 300;
  font-display: swap;
}
@font-face {
  font-family: "Hanken Grotesk";
  src: url("/fonts/HankenGrotesk-VariableFont_wght.ttf") format("truetype");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --sky: #20234e;
  --night: #1d2046;
  --deep: #17192f;
  --ink: #eeedf7;
  --soft: rgba(238, 237, 247, 0.76);
  --faint: rgba(238, 237, 247, 0.5);
  --mint: #a8e0cc;
  --words: "Fluxisch Else", ui-sans-serif, system-ui, sans-serif;
  --plain: "Hanken Grotesk", ui-sans-serif, system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: linear-gradient(var(--night) 0, var(--night) 60%, var(--deep) 100%) var(--deep);
  color: var(--ink);
  font: 400 17px/1.6 var(--plain);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { font-family: var(--words); font-weight: 300; margin: 0; text-wrap: balance; }
p { margin: 0; }

.name { font: 300 22px/1 var(--words); letter-spacing: 0.01em; }
.soon {
  font: 600 12px/1 var(--plain);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--mint);
}

/* The hero: the night clip filling the screen, the words in the open sky to the left of the tree. */
.hero {
  position: relative;
  height: 100vh;
  height: 100svh;
  min-height: 520px;
  overflow: hidden;
  background: var(--sky);
}
.scene {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* Cropped from the right on a narrower window, so the tree moves right and the open sky stays by the words,
     and from the bottom on a wider one, so the treetop stays in view. */
  object-position: 0% 15%;
  background: url("/media/night-wide.jpg") 0% 15% / cover no-repeat;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(to right, rgba(29, 32, 70, 0.55), rgba(29, 32, 70, 0) 46%),
    linear-gradient(to bottom, rgba(29, 32, 70, 0) 78%, var(--night) 100%);
}
.copy {
  position: absolute;
  z-index: 1;
  left: max(24px, 6vw);
  top: 16svh;
  width: min(30rem, 31vw);
}
.copy .name { margin-bottom: 28px; }
.copy h1 {
  font-size: clamp(34px, 3.7vw, 60px);
  line-height: 1.08;
  letter-spacing: -0.01em;
  margin-bottom: 20px;
}
.copy .lede {
  font: 300 clamp(19px, 1.5vw, 23px)/1.4 var(--words);
  color: var(--soft);
  margin-bottom: 26px;
}

/* On a tall screen the clip stands under the words, its empty sky behind them. */
@media (max-aspect-ratio: 3/4) {
  .hero { height: auto; min-height: 0; }
  .hero::after { display: none; }
  .scene {
    position: relative;
    display: block;
    height: auto;
    aspect-ratio: 780 / 1688;
    margin-top: clamp(104px, 30vw, 170px);
    object-position: center;
    background: url("/media/night-tall.jpg") center / cover no-repeat;
    -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 9%, #000 90%, transparent 100%);
    mask-image: linear-gradient(to bottom, transparent 0, #000 9%, #000 90%, transparent 100%);
  }
  .copy { left: 0; right: 0; top: 0; width: auto; padding: 32px 24px 0; }
  .copy .name { margin-bottom: 20px; }
  .copy h1 { font-size: clamp(30px, 8.4vw, 48px); margin-bottom: 12px; }
  .copy .lede { font-size: clamp(18px, 4.8vw, 22px); margin-bottom: 0; }
  .copy .soon { display: none; }
}

/* A new leaf: the sunrise clip in the shape of a phone's screen, beside a few words. */
main { padding: 0 24px; }
.leaf {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(32px, 7vw, 96px);
  max-width: 1040px;
  margin: 0 auto;
  padding: clamp(64px, 11vw, 140px) 0 clamp(56px, 9vw, 120px);
}
.phone {
  flex: 0 0 auto;
  width: min(300px, 70vw);
  aspect-ratio: 640 / 1386;
  border-radius: 34px;
  object-fit: cover;
  background: var(--deep) url("/media/leaf.jpg") center / cover no-repeat;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.07), 0 30px 80px rgba(6, 7, 20, 0.55);
}
.leaf .text { max-width: 26rem; }
.leaf h2 {
  font-size: clamp(28px, 3.2vw, 44px);
  line-height: 1.1;
  margin-bottom: 18px;
}
.leaf p { color: var(--soft); }
@media (max-width: 720px) {
  .leaf { flex-direction: column; align-items: flex-start; }
  .phone { align-self: center; }
}

/* Three short notes, each under a small line of light like the sit's. */
.points {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(32px, 4vw, 56px);
  max-width: 1040px;
  margin: 0 auto;
  padding: clamp(24px, 4vw, 48px) 0 clamp(72px, 10vw, 128px);
}
@media (max-width: 820px) {
  .points { grid-template-columns: minmax(0, 1fr); max-width: 30rem; }
}
.points h3 { font-size: 26px; line-height: 1.15; margin-bottom: 10px; }
.points p { color: var(--soft); }
.line {
  position: relative;
  display: block;
  width: 44px;
  height: 2px;
  margin-bottom: 22px;
  border-radius: 1px;
  background: linear-gradient(to right, rgba(168, 224, 204, 0.15), var(--mint));
}
.line::after {
  content: "";
  position: absolute;
  right: -3px;
  top: -2px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #f4fffa;
  box-shadow: 0 0 8px 3px rgba(168, 224, 204, 0.55);
}

.end {
  text-align: center;
  padding: clamp(32px, 6vw, 64px) 0 clamp(72px, 10vw, 120px);
}
.end .name { font-size: 30px; margin-bottom: 16px; }

footer {
  padding: 28px 24px 40px;
  text-align: center;
  color: var(--faint);
  font-size: 13px;
}

/* The 404 page. */
.lost {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 20px;
  text-align: center;
}
.lost h1 { font-size: clamp(32px, 6vw, 52px); line-height: 1.1; }
.lost a { color: var(--mint); text-decoration: none; border-bottom: 1px solid rgba(168, 224, 204, 0.4); }
