@font-face {
  font-family: "JetBrains Mono";
  src: url("/fonts/JetBrainsMono-Regular.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("/fonts/JetBrainsMono-Bold.ttf") format("truetype");
  font-weight: 700;
  font-display: swap;
}

/* golden: black on Golden's gold. Dark: the gold on black. */
:root {
  --bg: #fadc60;
  --fg: #141414;
  --dim: rgb(20 20 20 / 0.62);
  --line: rgb(20 20 20 / 0.55);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #222222;
    --fg: #fadc60;
    --dim: rgb(250 220 96 / 0.62);
    --line: rgb(250 220 96 / 0.55);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }

html {
  background: var(--bg);
  color: var(--fg);
  font: 15px/1.65 "JetBrains Mono", ui-monospace, Menlo, monospace;
  -webkit-text-size-adjust: 100%;
}
body { margin: 0; }

::selection { background: var(--fg); color: var(--bg); }

a { color: inherit; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.text { max-width: 68ch; }

/* header and footer: .wrap sets their sides; these set top and bottom */
header.wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 40px;
  padding-bottom: 20px;
}
.mark { display: flex; align-items: center; gap: 14px; text-decoration: none; font-weight: 700; font-size: 22px; }
.mark img { width: 42px; height: 42px; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 2px 10px;
  font-size: 13px;
  background: var(--fg);
  color: var(--bg);
}
.price { margin-left: 12px; font-weight: 700; }
.chip::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--bg); }

h1 {
  font-size: clamp(21px, 3.75vw, 39px);
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin: 56px 0 20px;
}
h2 { font-size: 15px; margin: 48px 0 8px; }
h2::before { content: "// "; color: var(--dim); font-weight: 400; }
h3 { font-size: 15px; margin: 28px 0 4px; }
p, ul, dl { margin: 0 0 14px; }
ul { padding-left: 2ch; }
.dim { color: var(--dim); }
.lede { font-size: 17px; }

figure { margin: 0; }
img { display: block; max-width: 100%; height: auto; }

/* the hero: the Duo open and an iPhone beside it, at one scale like the gallery */
.hero {
  --s: min(0.8px, (100vw - 48px) / 1150);
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 56px;
  margin: 56px 0 0;
}
.hero picture { width: calc(var(--w) * var(--s)); }
.hero img { width: 100%; }
@media (max-width: 640px) {
  .hero { --s: calc((100vw - 48px) / 1120); gap: 16px; }
}
/* the gallery: every device at one scale, so a closed Duo, an open one and an iPhone read
   as the same size in the hand; rows of them stand on a shared baseline */
.gallery {
  --s: min(1px, (100vw - 48px) / 560);
  display: flex;
  flex-direction: column;
  gap: 96px;
  margin-top: 120px;
}
.gallery .row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: flex-end;
  gap: 64px 80px;
}
.gallery picture { width: calc(var(--w) * var(--s)); }
.gallery img { width: 100%; }
@media (max-width: 640px) {
  .gallery { gap: 64px; margin-top: 80px; }
  .gallery .row { gap: 48px 32px; }
}

/* the press kit: facts as a two-column list, downloads as a grid of thumbnails */
dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: 4px 24px; }
dl.facts dt { color: var(--dim); }
dl.facts dd { margin: 0; }
.kit { display: grid; gap: 40px 32px; margin-top: 16px; }
.kit.icons { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
.kit.shots { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.kit figure { margin: 0; }
.kit.icons figure > a { display: block; padding: 20px; background: rgb(128 128 128 / 0.4); border-radius: 12px; }
.kit.icons img { width: 100%; height: auto; }
.kit.shots picture, .kit.shots img { display: block; width: 100%; height: 220px; object-fit: contain; }
.kit figcaption { margin-top: 10px; font-size: 13px; color: var(--dim); }
.kit figcaption a { color: var(--fg); }
a.chip { text-decoration: none; }

hr { border: 0; border-top: 1px solid var(--line); margin: 64px 0 0; }

footer.wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 20px;
  padding-bottom: 40px;
  font-size: 13px;
  color: var(--dim);
}
footer a { color: var(--fg); text-decoration: underline; }

.free { margin-top: 120px; }
