/* tv-home's site: the launcher's own type (Outfit, and Cormorant italic for the quote) on its colours,
   the ivory mat and walnut wall of Art mode. */
@font-face {
  font-family: Outfit;
  src: url(fonts/outfit.woff2) format('woff2');
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: Cormorant;
  src: url(fonts/cormorant-italic.woff2) format('woff2');
  font-weight: 300 700;
  font-style: italic;
  font-display: swap;
}

:root {
  --paper: #f5f0e6;
  --ink: #1f1a15;
  --muted: #6b6258;
  --line: #ddd4c4;
  --card: #ebe3d4;
  --button-ink: #f5f0e6;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #16120e;
    --ink: #efe7d8;
    --muted: #a59a8a;
    --line: #342b22;
    --card: #221b15;
    --button-ink: #16120e;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 17px/1.55 Outfit, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-underline-offset: 3px; text-decoration-thickness: 1px; }

.bar, main, footer { width: min(1040px, 100% - 40px); margin-inline: auto; }

.bar { display: flex; justify-content: space-between; align-items: center; padding: 22px 0; }
.mark { font-weight: 600; letter-spacing: 0.01em; text-decoration: none; }
.bar-link { color: var(--muted); text-decoration: none; }
.bar-link:hover { color: var(--ink); }

.hero { padding: clamp(40px, 9vw, 96px) 0 clamp(28px, 5vw, 48px); max-width: 760px; }
h1 {
  font: italic 600 clamp(56px, 11vw, 112px)/0.95 Cormorant, Georgia, serif;
  letter-spacing: -0.01em;
  margin: 0 0 22px;
}
.sub { font-size: clamp(19px, 2.4vw, 23px); line-height: 1.45; color: var(--muted); margin: 0 0 30px; max-width: 34ch; text-wrap: pretty; }
.actions { display: flex; gap: 12px; flex-wrap: wrap; }
.button {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 46px; padding: 0 22px; border-radius: 999px;
  border: 1px solid var(--line); text-decoration: none; font-weight: 500;
  transition: border-color 0.15s, background 0.15s;
}
.button:hover { border-color: var(--ink); }
.button svg { width: 18px; height: 18px; }
.button.primary { background: var(--ink); color: var(--button-ink); border-color: var(--ink); }
.button.primary:hover { opacity: 0.88; }

/* The trailer, matted like Art mode's frames. */
.trailer { margin: 0 0 clamp(56px, 9vw, 96px); scroll-margin-top: 16px; }
.frame { padding: clamp(6px, 1.2vw, 12px); background: var(--card); border-radius: 14px; }
.frame video { display: block; width: 100%; aspect-ratio: 16 / 9; border-radius: 6px; background: #000; }
figcaption { color: var(--muted); font-size: 15px; margin-top: 12px; }

/* Screenshots sit in the same mat as the trailer. */
.shot { margin: 0; }
.shot img, .shot video, .stack { display: block; width: 100%; height: auto; border-radius: 10px; }
.shot video { aspect-ratio: 16 / 9; background: #000; }
.shot figcaption { margin-top: 10px; font-size: 14px; }

/* The why: the stock home beside tv-home, at one height. */
.why { margin-bottom: clamp(64px, 10vw, 112px); }
.why-text { max-width: 620px; margin-bottom: 28px; }
.why h2, .row h2 { font: italic 600 clamp(36px, 5vw, 48px)/1.05 Cormorant, Georgia, serif; margin: 0 0 12px; }
.why p, .row p { margin: 0; color: var(--muted); font-size: 18px; text-wrap: pretty; }
.pair { margin: 0; }
.side { display: flex; gap: 20px; align-items: flex-start; }
.side img { display: block; width: 100%; height: auto; border-radius: 10px; min-width: 0; }
.side .stock { flex: 0 0 25%; width: 25%; }
.pair figcaption { margin-top: 10px; font-size: 14px; text-wrap: pretty; }

/* Each thing you get beside its screenshot, sides alternating. */
.rows { display: grid; gap: clamp(48px, 7vw, 80px); margin-bottom: clamp(64px, 10vw, 112px); }
.row { display: grid; grid-template-columns: 3fr 2fr; gap: clamp(24px, 4vw, 48px); align-items: center; }
.row:nth-child(even) .shot { order: 2; }
.row .text { max-width: 400px; }
.row:nth-child(even) .text { justify-self: end; }

/* Three home screens, one after another. 12 seconds round. */
.stack { position: relative; aspect-ratio: 16 / 9; overflow: hidden; }
.stack img { position: absolute; inset: 0; }
.stack img + img { opacity: 0; animation: 12s linear infinite; }
.stack img:nth-child(2) { animation-name: second; }
.stack img:nth-child(3) { animation-name: third; }
@keyframes second { 0%, 33% { opacity: 0; } 42%, 75% { opacity: 1; } 75.1%, 100% { opacity: 0; } }
@keyframes third { 0%, 66% { opacity: 0; } 75%, 92% { opacity: 1; } 100% { opacity: 0; } }


.points {
  display: grid; gap: 36px 56px;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  margin-bottom: clamp(64px, 10vw, 112px);
}
.point h2 { font-size: 23px; font-weight: 600; line-height: 1.25; margin: 0 0 8px; }
.point p { margin: 0; color: var(--muted); text-wrap: pretty; }

.setup { max-width: 720px; margin-bottom: clamp(64px, 10vw, 112px); scroll-margin-top: 16px; }
.setup h2 { font: italic 600 clamp(40px, 6vw, 56px)/1 Cormorant, Georgia, serif; margin: 0 0 24px; }
.setup ol { padding-left: 1.3em; margin: 0 0 24px; }
.setup li { padding-left: 6px; margin-bottom: 16px; }
.setup li::marker { color: var(--muted); }
.prompt {
  display: flex; align-items: center; gap: 12px;
  margin-top: 12px; padding: 14px 14px 14px 18px;
  background: var(--card); border-radius: 10px;
}
.prompt code { flex: 1; font: 15px/1.5 ui-monospace, 'SF Mono', Menlo, monospace; }
.copy {
  flex: none; font: inherit; font-size: 14px; color: var(--ink); cursor: pointer;
  background: none; border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px;
}
.copy:hover { border-color: var(--ink); }
.more, .works { color: var(--muted); margin: 0 0 8px; }

footer { border-top: 1px solid var(--line); padding: 24px 0 40px; color: var(--muted); font-size: 14px; }
footer p { margin: 0 0 6px; }

@media (max-width: 760px) {
  .row { grid-template-columns: 1fr; gap: 20px; }
  .row:nth-child(even) .shot { order: 0; }
  .row:nth-child(even) .text { justify-self: start; }
  .row .text { max-width: none; }
  .side { gap: 12px; }
  .side .stock { flex-basis: 30%; width: 30%; }
}
@media (max-width: 640px) {
  .prompt { flex-direction: column; align-items: stretch; }
  .copy { align-self: flex-start; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
  .stack img + img { display: none; }
}
