.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--background);
  border-bottom: 1px solid var(--border);
}

.nav-in {
  display: flex;
  align-items: baseline;
  gap: 2.25rem;
  height: 3.75rem;
  padding-top: 1.35rem;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-display);
  font-optical-sizing: auto;
  font-variation-settings: "SOFT" 0, "WONK" 1;
  font-weight: 700;
  font-size: 1.125rem;
  letter-spacing: -0.03em;
  text-decoration: none;
}
.wordmark picture {
  display: flex;
  flex: none;
}
.wordmark img {
  width: 1.45em;
  height: 1.45em;
  flex: none;
}

.nav nav {
  display: flex;
  gap: 1.5rem;
  margin-left: auto;
}

.nav nav a,
.nav-repo {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.02em;
  color: var(--muted-foreground);
  text-decoration: none;
  padding-bottom: 0.2rem;
  border-bottom: 1px solid transparent;
}
.nav nav a:hover,
.nav-repo:hover {
  color: var(--foreground);
  border-bottom-color: var(--primary);
}

.nav-repo {
  padding-left: 1.5rem;
  border-left: 1px solid var(--border);
  white-space: nowrap;
}
.nav-repo:hover { border-left-color: var(--border); }

.gh {
  flex: none;
  width: 1em;
  height: 1em;
  fill: currentColor;
  vertical-align: -0.14em;
  margin-right: 0.45em;
}

.theme {
  display: flex;
  align-items: center;
  justify-content: center;

  align-self: center;
  position: relative;
  top: 0.25rem;
  flex: none;
  width: 1.4rem;
  height: 1.4rem;
  margin-left: 1.35rem;
  padding: 0;
  background: none;
  border: 0;
  color: var(--muted-foreground);
  cursor: pointer;
  transition: color 0.15s ease;
}
.theme:hover { color: var(--foreground); }
.theme .ico { margin-top: 0; width: 0.9rem; height: 0.9rem; }

.cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.5rem;
}

.btn {
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  letter-spacing: 0.02em;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn-primary {
  display: inline-block;
  padding: 0.75rem 1.35rem;
  background: var(--primary);
  color: var(--primary-foreground);
  font-weight: 500;
  border-radius: var(--radius-s);
}
.btn-primary:hover { background: var(--primary-hover); }

.btn-quiet {
  color: var(--muted-foreground);
  padding-bottom: 0.25rem;
  border-bottom: 1px solid var(--border-strong);
}
.btn-quiet:hover {
  color: var(--foreground);
  border-bottom-color: var(--primary);
}

.shot { position: relative; }

.plate {
  position: relative;
  overflow: hidden;
  background-color: var(--sunken);
  background-image: repeating-linear-gradient(
    -45deg,
    color-mix(in oklab, var(--border) 55%, transparent) 0 1px,
    transparent 1px 11px
  );
  border: 1px solid var(--border);
  border-radius: var(--radius-s);
}

.plate::after {
  content: "";
  position: absolute;
  inset: 0.5rem;
  border: 1px solid var(--border-soft);
  pointer-events: none;
}

.shot figcaption {
  margin-top: 0.9rem;
  font-family: var(--font-display);
  font-optical-sizing: auto;
  font-variation-settings: "SOFT" 20, "WONK" 1;
  font-style: italic;
  font-size: 0.9375rem;
  line-height: 1.45;
  color: var(--muted-foreground);
  max-width: 52ch;
}

.plate picture { display: block; height: 100%; }
.plate img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}
.plate:has(img) { background-image: none; }
.plate:has(img)::after { inset: 0; border-color: color-mix(in oklab, var(--foreground) 12%, transparent); }

.shot-16x9 .plate { aspect-ratio: 16 / 9; }
.shot-3x2 .plate  { aspect-ratio: 3 / 2; }
.shot-4x3 .plate  { aspect-ratio: 4 / 3; }

.shot-phone { justify-self: center; width: max-content; }
.shot-phone .plate {
  aspect-ratio: 9 / 19.5;
  height: clamp(360px, 65vh, 700px);
  width: auto;
}

.sprite { display: none; }

.ico {
  flex: none;
  width: 1.15em;
  height: 1.15em;
  margin-top: 0.16em;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.brand {
  flex: none;
  width: 1.05rem;
  height: 1.05rem;

  align-self: flex-start;
  margin-top: 0.22rem;
  fill: currentColor;
}

.tight {
  margin-top: 1.75rem;
  border-top: 1px solid var(--border);
  max-width: 52ch;
}
.tight li {
  position: relative;
  padding: 0.8rem 0 0.8rem 1.6rem;
  border-bottom: 1px solid var(--border-soft);
  font-size: 0.9375rem;
  color: var(--muted-foreground);
}
.tight li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1.55rem;
  width: 0.7rem;
  height: 1px;
  background: var(--primary);
}

code { color: var(--foreground); }

pre {
  margin: 1.75rem 0;
  padding: 1.15rem 1.35rem;
  background: var(--sunken);
  border: 1px solid var(--border);
  border-left: 2px solid var(--primary);
  border-radius: 0 var(--radius-s) var(--radius-s) 0;
  overflow-x: auto;
}
pre code {
  font-size: 0.8125rem;
  line-height: 1.95;
  color: var(--muted-foreground);
  white-space: pre;
}

@media (max-width: 720px) {
  .nav-in { gap: 1rem; height: 3.4rem; padding-top: 1.15rem; }
  .nav nav { display: none; }
  .nav-repo { margin-left: auto; padding-left: 0; border-left: 0; }
  .theme { margin-left: 0.75rem; }

  .shot figcaption { font-size: 0.875rem; margin-top: 0.7rem; }
  .plate::after { inset: 0.35rem; }
}
