/* Delicate Few: one typeface, near-white ground, color only from the products. */
@font-face {
  font-family: "Instrument Sans";
  src: url("/assets/instrument-sans.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}

:root {
  --ground: #fbfbfa;
  --ink: #16191d;
  --ink-2: #4b5259;
  --ink-3: #565d64;
  --gutter: clamp(20px, 5vw, 64px);
  --page: 1360px;
}

* { box-sizing: border-box; }

html { overflow-x: clip; }

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: "Instrument Sans", "Helvetica Neue", Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--ink-3); }
a:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 4px; }

.page {
  min-height: 100vh;
  max-width: var(--page);
  margin: 0 auto;
  padding: 24px var(--gutter) 40px;
  display: flex;
  flex-direction: column;
  gap: clamp(40px, 7vw, 88px);
}

.top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 24px; }
.brand { font-size: clamp(1.375rem, 2vw, 1.625rem); font-weight: 600; letter-spacing: -0.02em; line-height: 1.2; text-decoration: none; }
.quiet { color: var(--ink-3); text-decoration: none; }

.hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr));
  gap: 32px clamp(32px, 6vw, 96px);
  align-items: center;
}
.hero h1 {
  margin: 0;
  font-size: clamp(2.75rem, 6.4vw, 5rem);
  font-weight: 500;
  letter-spacing: -0.032em;
  line-height: 1.04;
  text-wrap: balance;
}
.intro { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.what { margin: 0; font-size: clamp(1.25rem, 2vw, 1.5rem); font-weight: 500; letter-spacing: -0.012em; line-height: 1.3; }
.note { margin: 0; color: var(--ink-2); max-width: 32rem; text-wrap: balance; }

/* One row of equal cards that pans. The row runs to the window's edges and lines up with the page. */
.arrows { display: flex; justify-content: flex-end; gap: 8px; margin-bottom: 16px; }
.arrows[hidden] { display: none; }
.arrow {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid #dcdedf;
  border-radius: 50%;
  background: none;
  color: var(--ink);
  cursor: pointer;
  transition: background 0.15s ease, opacity 0.15s ease;
}
.arrow:hover:not(:disabled) { background: #eff0ef; }
.arrow:disabled { opacity: 0.3; cursor: default; }
.arrow:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }

.rail {
  --edge: max(var(--gutter), calc((100vw - var(--page)) / 2 + var(--gutter)));
  width: 100vw;
  margin-left: calc(50% - 50vw);
  padding-inline: var(--edge);
  scroll-padding-inline: var(--edge);
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.rail::-webkit-scrollbar { display: none; }
.rail:focus-visible { outline: 2px solid var(--ink); outline-offset: 4px; }

.card {
  flex: 0 0 min(400px, 82vw);
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  background: var(--tint);
  border-radius: 24px;
  overflow: hidden;
  color: var(--ink);
  text-decoration: none;
}
a.card:hover { color: var(--ink); }

.text { padding: 24px 24px 20px; flex-grow: 1; }
.card h2 {
  margin: 0 0 6px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 6px 12px;
  font-size: 1.375rem;
  font-weight: 600;
  letter-spacing: -0.015em;
}
.card p { margin: 0; color: #3a4046; text-wrap: pretty; }
.soon {
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1;
  padding: 6px 10px;
  border-radius: 999px;
  background: #fff;
  color: #3a4046;
  white-space: nowrap;
}

.shot {
  display: block;
  width: calc(100% - 48px);
  height: auto;
  aspect-ratio: 390 / 420;
  flex: none;
  margin: 0 24px -1px;
  border-radius: 16px 16px 0 0;
  object-fit: cover;
  object-position: top;
  background: var(--accent);
  box-shadow: 0 0 0 1px rgb(22 25 29 / 0.08);
}
/* The five verbs from the README, set large. The light moves slowly down the list. */
.verbs {
  list-style: none;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
  padding: 0 24px;
  overflow: hidden;
  color: #fff;
  font-size: clamp(1.875rem, 3vw, 2.5rem);
  font-weight: 500;
  letter-spacing: -0.028em;
  line-height: 1.22;
}

.whichbeep { --tint: #dbe3d5; --accent: oklch(45% 0.07 150); }
.glosignal { --tint: #f8e9da; --accent: #d07020; }
.spot      { --tint: #e3f2ea; --accent: #135f35; }
.outlook   { --tint: #e3e9f2; --accent: #3b5b8c; }
.twiddles  { --tint: #ffe4ed; --accent: #ff4d8d; }

.foot { margin-top: auto; display: flex; flex-wrap: wrap; gap: 8px 24px; font-size: 1rem; color: var(--ink-3); }
.copy { margin-left: auto; }

/* Wide windows have room for every card, so the row stops panning. */
@media (min-width: 1680px) {
  :root { --page: 2192px; }
  .rail { overflow-x: visible; scroll-snap-type: none; }
  .card { flex: 1 1 0; min-width: 0; }
}

/* Privacy and terms */
.doc { max-width: 40rem; }
.doc h1 { margin: 0 0 8px; font-size: clamp(2.25rem, 5vw, 3rem); font-weight: 500; letter-spacing: -0.026em; line-height: 1.1; }
.doc h2 { margin: 32px 0 6px; font-size: 1.25rem; font-weight: 600; letter-spacing: -0.012em; }
.doc p { margin: 0 0 12px; color: var(--ink-2); }
.doc .date { color: var(--ink-3); }

/* Motion. Everything here is optional: without it the page is simply still. */
@media (prefers-reduced-motion: no-preference) {
  /* The page settles in once, on load. */
  .hero h1, .intro, .card { animation: settle 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
  .intro { animation-delay: 0.08s; }
  .card:nth-child(1) { animation-delay: 0.16s; }
  .card:nth-child(2) { animation-delay: 0.22s; }
  .card:nth-child(3) { animation-delay: 0.28s; }
  .card:nth-child(4) { animation-delay: 0.34s; }
  .card:nth-child(5) { animation-delay: 0.4s; }

  .verbs li { animation: lit 12s ease-in-out infinite; }
  .verbs li:nth-child(2) { animation-delay: 2.4s; }
  .verbs li:nth-child(3) { animation-delay: 4.8s; }
  .verbs li:nth-child(4) { animation-delay: 7.2s; }
  .verbs li:nth-child(5) { animation-delay: 9.6s; }
  .verbs li { opacity: 0.42; }

  /* Hovering a card slowly scrolls through the real product, then returns. */
  @media (hover: hover) {
    img.shot { transition: object-position 1.4s cubic-bezier(0.3, 0, 0.2, 1); }
    .card:hover img.shot { object-position: bottom; transition: object-position 11s cubic-bezier(0.35, 0, 0.3, 1); }
  }
}

@keyframes settle {
  from { opacity: 0; transform: translateY(10px); }
}

@keyframes lit {
  0%, 22%, 100% { opacity: 0.42; }
  8%, 14% { opacity: 1; }
}
