:root {
  color-scheme: dark;
  --ink: #0a0c0f;
  --raised: #12161b;
  --raised-2: #191e24;
  --line: #2a3038;
  --paper: #f3f0e8;
  --muted: #959ca5;
  --signal: #ff5c35;
  --signal-soft: #ff8d73;
  --mint: #65e6bd;
  --max: 1180px;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: "Avenir Next", Avenir, "Segoe UI", sans-serif;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  min-width: 320px;
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 78% 32%, rgb(255 92 53 / 9%), transparent 24rem),
    var(--ink);
  color: var(--paper);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
button, input { font: inherit; }

.skip-link {
  position: fixed;
  z-index: 100;
  top: .75rem;
  left: .75rem;
  padding: .6rem .9rem;
  background: var(--paper);
  color: var(--ink);
  transform: translateY(-180%);
}

.skip-link:focus { transform: translateY(0); }

.page {
  width: min(calc(100% - 3rem), var(--max));
  min-height: 100svh;
  margin-inline: auto;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
}

.site-header {
  min-height: 4rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: .68rem;
  font-weight: 680;
  letter-spacing: -.025em;
  text-decoration: none;
}

.brand-mark {
  width: 2rem;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: .42rem .42rem 1rem .42rem;
  background: var(--signal);
  color: var(--ink);
  font-family: var(--mono);
  font-size: .7rem;
  font-weight: 900;
  transform: rotate(-4deg);
}

.header-link {
  min-height: 2.75rem;
  display: inline-flex;
  align-items: center;
  gap: .28rem;
  padding-inline: .25rem;
  color: var(--muted);
  font-size: .82rem;
  font-weight: 650;
  text-decoration: none;
  transition: color 150ms ease;
}

.header-link:hover,
.header-link:focus-visible { color: var(--paper); }

main {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, .82fr) minmax(31rem, 1.18fr);
  align-items: center;
  gap: clamp(2.5rem, 7vw, 7rem);
  padding-block: clamp(1.8rem, 5vh, 3.8rem);
}

h1 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(4.3rem, 7.7vw, 7rem);
  font-weight: 600;
  letter-spacing: -.065em;
  line-height: .82;
  text-wrap: balance;
}

h1 em { color: var(--signal); font-weight: inherit; }

.lede {
  max-width: 28rem;
  margin: 1.65rem 0 0;
  color: #c7c7c3;
  font-size: clamp(1rem, 1.4vw, 1.16rem);
  line-height: 1.55;
  text-wrap: balance;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .65rem;
  margin-top: 1.6rem;
}

.button {
  min-height: 3rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  padding: .72rem 1.15rem;
  border: 1px solid var(--line);
  color: var(--paper);
  font-size: .82rem;
  font-weight: 750;
  text-decoration: none;
  transition: transform 150ms ease, border-color 150ms ease, background 150ms ease;
}

.button:hover { transform: translateY(-2px); }
.button-primary { border-color: var(--signal); background: var(--signal); color: var(--ink); }
.button-primary:hover { background: var(--signal-soft); border-color: var(--signal-soft); }

.relay {
  position: relative;
  height: min(31rem, calc(100svh - 10.5rem));
  min-height: 25rem;
  overflow: hidden;
  border: 1px solid var(--line);
  background: rgb(14 17 21 / 72%);
  box-shadow: 0 2rem 6rem rgb(0 0 0 / 25%);
  isolation: isolate;
}

.relay-grid {
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: .23;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 2.4rem 2.4rem;
  mask-image: linear-gradient(to bottom right, black, transparent 75%);
}

.terminal {
  position: absolute;
  z-index: 3;
  top: 16%;
  left: 5%;
  width: 64%;
  border: 1px solid #464d56;
  background: #101319;
  box-shadow: 0 1.5rem 3.5rem rgb(0 0 0 / 45%);
  transform: rotate(-1.5deg);
}

.terminal-bar {
  min-height: 2.45rem;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: .6rem .75rem;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-family: var(--mono);
  font-size: .57rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.terminal-bar > span:first-child { display: flex; gap: .28rem; }
.terminal-bar i { width: .42rem; aspect-ratio: 1; border-radius: 50%; background: #444b54; }
.terminal-bar i:first-child { background: var(--signal); }
.terminal-bar b { justify-self: end; color: var(--mint); font-weight: 700; }

.terminal label {
  display: block;
  padding: .9rem .9rem .35rem;
  color: var(--muted);
  font-family: var(--mono);
  font-size: .58rem;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.terminal input {
  width: calc(100% - 1.8rem);
  margin: 0 .9rem .7rem;
  padding: .65rem .72rem;
  border: 1px solid var(--line);
  border-radius: 0;
  outline: none;
  background: var(--raised-2);
  color: var(--paper);
  font-family: var(--mono);
  font-size: .76rem;
}

.terminal input:focus { border-color: var(--signal); box-shadow: 0 0 0 2px rgb(255 92 53 / 18%); }

pre { margin: 0; overflow-x: hidden; }

.terminal pre {
  min-height: 5.2rem;
  padding: .8rem .9rem;
  border-block: 1px solid var(--line);
  color: #b8bec5;
  font-family: var(--mono);
  font-size: clamp(.57rem, .82vw, .68rem);
  line-height: 1.65;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.terminal pre::first-line { color: var(--signal-soft); }

#copy-command {
  width: 100%;
  min-height: 2.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .6rem .9rem;
  border: 0;
  background: transparent;
  color: var(--paper);
  font-family: var(--mono);
  font-size: .66rem;
  font-weight: 750;
  cursor: pointer;
}

#copy-command:hover,
#copy-command:focus-visible { background: var(--raised-2); outline: 0; }

.route {
  position: absolute;
  z-index: 2;
  top: 53%;
  left: 51%;
  right: 16%;
  height: 1px;
  background: #4b535d;
  transform: rotate(-5deg);
}

.route-label {
  position: absolute;
  top: -1.3rem;
  left: 48%;
  color: var(--muted);
  font-family: var(--mono);
  font-size: .55rem;
  letter-spacing: .1em;
}

.route-pulse {
  position: absolute;
  top: -3px;
  left: 0;
  width: 7px;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--signal);
  box-shadow: 0 0 1rem var(--signal);
  animation: deliver 2.7s cubic-bezier(.65, 0, .35, 1) infinite;
}

.phone {
  position: absolute;
  z-index: 4;
  top: 6%;
  right: 4%;
  width: 35%;
  height: 82%;
  overflow: hidden;
  border: .35rem solid #2d333b;
  border-radius: 2.7rem;
  background:
    radial-gradient(circle at 75% 76%, rgb(255 92 53 / 42%), transparent 38%),
    linear-gradient(150deg, #252c35, #0d1014 67%);
  box-shadow: 0 1.8rem 4rem rgb(0 0 0 / 52%), inset 0 0 0 1px #515963;
  transform: rotate(3.5deg);
}

.phone-island {
  position: absolute;
  z-index: 2;
  top: .48rem;
  left: 50%;
  width: 4.5rem;
  height: 1.2rem;
  border-radius: 2rem;
  background: #050607;
  transform: translateX(-50%);
}

.phone-time {
  display: flex;
  justify-content: space-between;
  padding: .7rem 1rem;
  font-size: .5rem;
  font-weight: 800;
}

.lock-date { padding-top: 1.1rem; text-align: center; }
.lock-date span { display: block; color: #c0c5cc; font-size: .58rem; }
.lock-date strong { display: block; font-family: var(--serif); font-size: 3.2rem; font-weight: 400; line-height: .9; }

.notification {
  position: absolute;
  top: 29%;
  left: .48rem;
  right: .48rem;
  display: flex;
  gap: .55rem;
  padding: .65rem;
  border-radius: 1.05rem;
  background: rgb(230 233 234 / 91%);
  color: #111318;
  box-shadow: 0 .7rem 1.5rem rgb(0 0 0 / 28%);
  backdrop-filter: blur(18px);
}

.notification-icon {
  flex: 0 0 auto;
  width: 1.8rem;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: .45rem .45rem .85rem .45rem;
  background: var(--signal);
  color: var(--ink);
  font-family: var(--mono);
  font-size: .55rem;
  font-weight: 900;
}

.notification-copy {
  min-width: 0;
  display: flex;
  flex: 1;
  flex-direction: column;
  font-size: .58rem;
}

.notification-copy > span { display: flex; justify-content: space-between; gap: .4rem; }
.notification-copy small { color: #686e75; }
.notification-copy strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.home-indicator {
  position: absolute;
  bottom: .4rem;
  left: 50%;
  width: 4rem;
  height: .18rem;
  border-radius: 1rem;
  background: #e8e8e5;
  transform: translateX(-50%);
}

footer {
  min-height: 3.4rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  color: var(--muted);
  font-family: var(--mono);
  font-size: .6rem;
  letter-spacing: .04em;
  text-transform: uppercase;
}

footer p { margin: 0; }

@keyframes deliver {
  0% { left: 0; opacity: 0; }
  12%, 82% { opacity: 1; }
  100% { left: 100%; opacity: 0; }
}

@media (max-width: 900px) {
  .page { width: min(calc(100% - 2rem), 42rem); }

  main {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding-block: 1.8rem;
  }

  .hero-copy { text-align: center; }
  .lede { margin-inline: auto; }
  .hero-actions { justify-content: center; }

  .relay {
    width: 100%;
    height: 24rem;
    min-height: 0;
  }
}

@media (max-width: 560px) {
  .page { width: calc(100% - 2rem); }
  .site-header { min-height: 3.5rem; }

  main { gap: 1.1rem; padding-block: 1.25rem; }
  h1 { font-size: clamp(3.3rem, 16vw, 4.25rem); line-height: .84; }
  .lede { max-width: 23rem; margin-top: 1rem; font-size: .94rem; line-height: 1.42; }
  .hero-actions { margin-top: 1rem; }
  .button { min-height: 2.75rem; padding: .62rem .9rem; }
  .relay { height: 19rem; }
  .terminal { top: 7%; left: 3.5%; width: 76%; }
  .terminal-bar { min-height: 2rem; padding: .45rem .58rem; }
  .terminal label { padding: .55rem .65rem .22rem; }
  .terminal input { width: calc(100% - 1.3rem); margin: 0 .65rem .48rem; padding: .48rem .55rem; font-size: .66rem; }
  .terminal pre { min-height: 3.9rem; padding: .55rem .65rem; font-size: .5rem; line-height: 1.5; }
  #copy-command { min-height: 2.2rem; padding: .42rem .65rem; font-size: .57rem; }

  .route { left: 55%; right: 10%; top: 47%; }
  .phone { top: 5%; right: 2.5%; width: 34%; height: 79%; border-width: .25rem; border-radius: 2rem; }
  .phone-island { width: 3rem; height: .82rem; top: .32rem; }
  .phone-time { padding: .48rem .6rem; font-size: .38rem; }
  .lock-date { padding-top: .6rem; }
  .lock-date span { font-size: .4rem; }
  .lock-date strong { font-size: 2rem; }
  .notification { top: 29%; left: .28rem; right: .28rem; gap: .3rem; padding: .4rem; border-radius: .72rem; }
  .notification-icon { width: 1.25rem; font-size: .38rem; }
  .notification-copy { font-size: .4rem; }
  footer { min-height: 3rem; font-size: .5rem; }
}

@media (max-height: 720px) and (min-width: 901px) {
  .site-header { min-height: 4rem; }
  main { padding-block: 1.4rem; }
  h1 { font-size: clamp(4rem, 7vw, 5.7rem); }
  .lede { margin-top: 1.25rem; }
  .hero-actions { margin-top: 1.25rem; }
  .relay { height: calc(100svh - 10rem); min-height: 22rem; }
  footer { min-height: 3rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
