:root {
  color-scheme: dark;
  --bg: #000000;
  --text: #f2f2f2;
  --muted: #979797;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", sans-serif;
  overflow-x: hidden;
}

.page-shell {
  width: 100%;
  min-height: 100vh;
  background: var(--bg);
}

.page {
  position: relative;
  width: 100%;
  min-height: 100vh;
  overflow: visible;
}

.screen {
  position: relative;
  width: 100%;
  min-height: 100vh;
}

.screen--one {
  padding: 0 48px 48px;
}

.top-nav {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%); /* Centers vertically & horizontally */
  display: flex;
  align-items: center;
  justify-content: center;
  gap: min(3vw, 32px);
  flex-wrap: wrap;
  z-index: 4;
}

.top-nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: clamp(1rem, 1.2vw, 1.25rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  transition: color 180ms ease;
}

.top-nav a:hover,
.top-nav a:focus-visible {
  color: var(--text);
}

.hero {
  position: absolute;
  left: 48px;
  right: 48px;
  bottom: 140px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.hero h1 {
  margin: 0;
  font-family: "Geist Mono", monospace;
  font-size: clamp(3.5rem, 8vw, 8rem);
  line-height: 0.9;
  font-weight: 400;
  letter-spacing: -0.03em;
  color: var(--text);
  max-width: 1000px;
}

.hero-subtext {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  color: var(--muted);
  font-size: clamp(1.1rem, 1.6vw, 1.5rem);
  font-weight: 500;
  letter-spacing: -0.02em;
}

.scroll-indicator {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  color: var(--text);
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
  font-size: 32px;
  line-height: 1;
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.scroll-indicator.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.screen--two {
  position: relative; /* Flows naturally below screen one */
  width: 100%;
  min-height: 100vh;
  z-index: 3;
  padding: 0 48px;
  background: var(--bg);
  
  /* Initial hidden state */
  opacity: 0;
  transform: translateY(80px); 
  transition: transform 800ms ease-out, opacity 800ms ease-out;
}

.screen--two.is-open {
  opacity: 1;
  transform: translateY(0);
}

.portrait-frame {
  position: absolute;
  top: 225px;
  left: 48px;
  width: 318px;
  height: 481px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.08),
    rgba(255, 255, 255, 0.02)
  );
}

.greeting {
  position: absolute;
  top: 154px;
  left: 48px;
  margin: 0;
  font-size: 24px;
  font-weight: 600;
  color: var(--text);
}

.quote {
  position: absolute;
  top: 444px;
  right: 120px;
  margin: 0;
  font-size: 120px;
  line-height: 1;
  color: var(--text);
}

.body-copy {
  position: absolute;
  top: 225px;
  left: 390px;
  max-width: 660px;
  margin: 0;
  font-size: 24px;
  line-height: 1.5;
  color: #dedede;
}

@media (max-width: 900px) {
  .screen--one {
    padding: 24px 24px 96px;
  }

  .top-nav {
    position: static;
    transform: none;
    justify-content: flex-start;
    margin-top: 24px;
    margin-bottom: 48px;
  }

  .hero {
    position: static;
    margin-top: 24px;
  }

  .hero-subtext {
    flex-direction: column;
    gap: 8px;
  }

  .scroll-indicator {
    bottom: 16px;
  }

  .screen--two {
    padding: 24px;
  }

  .portrait-frame {
    top: 180px;
    left: 24px;
    width: 220px;
    height: 320px;
  }

  .greeting {
    top: 120px;
    left: 24px;
  }

  .quote {
    top: 220px;
    right: 24px;
    font-size: 72px;
  }

  .body-copy {
    top: 180px;
    left: 270px;
    font-size: 18px;
    max-width: none;
  }
}
