@font-face {
  font-family: "Fraunces";
  font-style: italic;
  font-weight: 300 700;
  font-display: swap;
  src: url("/static/fonts/fraunces-300-700-italic.woff2") format("woff2");
}
@font-face {
  font-family: "Fraunces";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("/static/fonts/fraunces-300-700-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Jost";
  font-style: italic;
  font-weight: 300 600;
  font-display: swap;
  src: url("/static/fonts/jost-300-600-italic.woff2") format("woff2");
}
@font-face {
  font-family: "Jost";
  font-style: normal;
  font-weight: 300 600;
  font-display: swap;
  src: url("/static/fonts/jost-300-600-normal.woff2") format("woff2");
}

/* The hidden attribute always wins over a component's display rule. */
[hidden] { display: none !important; }

/* Atelier — warm editorial on a white ground. Fraunces for display, a quiet
   geometric sans for everything functional. Museum-label captions, hairlines
   instead of boxes, one bronze accent. */
:root {
  --bg: #ffffff;
  --surface: #f7f5f1;
  --ink: #1f1c19;
  --ink-soft: #6b645b;
  --line: #e7e2d9;
  --accent: #8c6b3e;
  --accent-ink: #fbf9f4;
  --accent-soft: #f3ede2;
  --warn: #9a4a1f;
  --display: "Fraunces", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --text: "Jost", "Futura", "Century Gothic", "Segoe UI", sans-serif;
  --measure: 62ch;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1b1917;
    --surface: #23201d;
    --ink: #ece6db;
    --ink-soft: #a39b8f;
    --line: #3a352f;
    --accent: #cfae6e;
    --accent-ink: #1b1917;
    --accent-soft: #2b2620;
    --warn: #d98d5f;
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
::selection { background: var(--accent-soft); }

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--ink); color: var(--bg);
  padding: 10px 16px; text-decoration: none; font-family: var(--text);
}
.skip:focus-visible { left: 0; }
body {
  background: var(--bg);
  color: var(--ink);
  font: 400 16.5px/1.7 var(--text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: .18em; }
a:hover { text-decoration-color: var(--accent); color: var(--accent); }

h1, h2, h3 { font-family: var(--display); font-weight: 400; letter-spacing: -0.012em; margin: 0; font-optical-sizing: auto; }
h1 { font-size: clamp(36px, 5vw, 54px); line-height: 1.04; margin-bottom: 14px; }
h2 { font-size: clamp(26px, 2.8vw, 32px); line-height: 1.15; margin: 0 0 16px; }
.lede {
  font-family: var(--display); font-style: italic; font-weight: 400;
  font-size: clamp(18px, 1.9vw, 21px); line-height: 1.45;
  color: var(--ink-soft); max-width: var(--measure); margin: 0 0 22px;
}
.soft { color: var(--ink-soft); font-size: 14px; }
p { max-width: var(--measure); }
.eyebrow, .crumb, .badge, .btn, .top nav a, .info th, .bottom, .hero-art figcaption, .card-meta {
  font-family: var(--text); text-transform: uppercase; letter-spacing: .14em; font-size: 12px; font-weight: 500;
}
.eyebrow {
  color: var(--accent); margin: 0 0 18px; display: flex; align-items: center; gap: 12px;
}
.eyebrow::before { content: ""; width: 28px; height: 1px; background: var(--accent); }

/* ---- header ------------------------------------------------------------ */
.top {
  display: flex; align-items: center; justify-content: space-between; gap: 4px 24px;
  padding: 18px 40px; border-bottom: 1px solid var(--line);
  position: sticky; top: 0; background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  z-index: 10; flex-wrap: wrap;
}
.brand {
  font-family: var(--display); font-weight: 500; font-size: 22px; letter-spacing: -0.01em;
  color: var(--ink); text-decoration: none; padding: 2px 0;
}
.top nav { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.top nav::-webkit-scrollbar { display: none; }
.top nav a {
  color: var(--ink-soft); text-decoration: none; padding: 10px 12px; white-space: nowrap;
  border-bottom: 1px solid transparent;
}
.top nav a:hover { color: var(--ink); }
.top nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--accent); }
@media (max-width: 760px) {
  .top { padding: 14px 20px; }
  .top nav { flex-basis: 100%; margin: 4px -8px 0; padding: 0 4px; }
  .brand { font-size: 19px; }
}

main { max-width: 1160px; margin: 0 auto; padding: 24px 40px 96px; }
@media (max-width: 760px) { main { padding: 12px 20px 72px; } }

/* ---- home hero --------------------------------------------------------- */
.hero {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: 56px; align-items: center; padding: 56px 0 72px;
}
.hero h1 { font-size: clamp(38px, 4.8vw, 60px); }
.hero .lede { margin-bottom: 28px; }
.hero-art { margin: 0; }
.hero-art > a { display: block; text-decoration: none; }
.hero-art img {
  width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 2px;
  box-shadow: 0 40px 70px -40px rgba(40, 30, 15, .55);
}
.hero-art figcaption { color: var(--ink-soft); margin-top: 14px; }
.hero-art figcaption a { color: var(--ink); text-decoration: none; }
.hero-art figcaption a:hover { color: var(--accent); }
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; gap: 36px; padding: 32px 0 48px; }
  .hero-art img { box-shadow: 0 24px 40px -30px rgba(40, 30, 15, .5); }
}

/* ---- buttons + forms --------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  background: var(--ink); color: var(--bg); border: 1px solid var(--ink);
  border-radius: 2px; padding: 14px 22px; text-decoration: none; cursor: pointer;
  line-height: 1; transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.btn:hover { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn.ghost:hover { border-color: var(--ink); background: transparent; color: var(--ink); }
.btn.disabled { opacity: .5; cursor: default; }
.btn.dl svg { width: 16px; height: 16px; fill: currentColor; flex: none; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

.capture { display: flex; gap: 14px; flex-wrap: wrap; align-items: flex-end; margin: 12px 0 8px; max-width: 560px; }
.capture input[type="email"] {
  flex: 1 1 240px; padding: 12px 2px; font: 16px/1.3 var(--text);
  border: 0; border-bottom: 1px solid var(--ink-soft); border-radius: 0;
  background: transparent; color: var(--ink);
}
.capture input[type="email"]::placeholder { color: var(--ink-soft); opacity: .8; }
.capture input[type="email"]:focus { outline: none; border-bottom-color: var(--accent); }
.capture .hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form-msg { flex-basis: 100%; margin: 6px 0 0; color: var(--accent); font-size: 14px; }
.form-msg.err { color: var(--warn); }
@media (max-width: 560px) { .capture .btn { flex: 1 1 100%; } }

/* ---- sections ---------------------------------------------------------- */
section { margin: 0; }
.recent, .app, .notes, .file + section { border-top: 1px solid var(--line); padding-top: 44px; margin-top: 44px; }
.sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-bottom: 28px; }
.sec-head h2 { margin: 0; }
.sec-head .btn.ghost { padding: 12px 18px; }

.grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 40px 28px; margin: 0;
}
@media (max-width: 560px) { .grid { grid-template-columns: repeat(2, 1fr); gap: 26px 16px; } }
.card { display: block; text-decoration: none; color: var(--ink); position: relative; }
.card-media { display: block; overflow: hidden; border-radius: 2px; background: var(--accent-soft); }
.card img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
@media (prefers-reduced-motion: no-preference) {
  .card img { transition: transform .5s cubic-bezier(.2, .7, .2, 1); }
  .card:hover img, .card:focus-visible img { transform: scale(1.03); }
}
.card-body { display: flex; flex-direction: column; gap: 3px; padding: 14px 2px 0; }
.card-meta { font-size: 12.5px; letter-spacing: .04em; color: var(--ink-soft); }
.card-badges { display: flex; flex-wrap: wrap; gap: 2px 12px; margin-top: 2px; }
.card-t { font-family: var(--display); font-weight: 500; font-size: 19px; line-height: 1.2; }
.card:hover .card-t { color: var(--accent); }
.badge { color: var(--ink-soft); }
.badge.free, .badge.avail { color: var(--accent); }

/* ---- gallery filters ----------------------------------------------------- */
.filters { display: grid; gap: 8px; margin: 26px 0 34px; padding: 16px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.filter-group { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 18px; }
.filter-label { font-family: var(--text); text-transform: uppercase; letter-spacing: .14em; font-size: 11px; font-weight: 500; color: var(--ink-soft); min-width: 44px; }
.chip { font-family: var(--text); text-transform: uppercase; letter-spacing: .12em; font-size: 12px; font-weight: 500; color: var(--ink-soft); text-decoration: none; padding: 5px 0; border-bottom: 1px solid transparent; white-space: nowrap; }
.chip:hover { color: var(--ink); }
.chip.active { color: var(--ink); border-bottom-color: var(--accent); }
.chip .count { color: var(--ink-soft); font-weight: 400; margin-left: 2px; }

/* ---- app teasers ------------------------------------------------------- */
.app p { max-width: 58ch; }
.app-h { display: flex; align-items: center; gap: 14px; }
.app-icon { width: 40px; height: 40px; border-radius: 9px; }
h1 .app-icon { width: 52px; height: 52px; border-radius: 12px; }

/* ---- file + piece pages ------------------------------------------------ */
.crumb { color: var(--ink-soft); margin: 0 0 22px; }
.crumb a { color: var(--ink-soft); text-decoration: none; }
.crumb a:hover { color: var(--accent); }
.file h1 { margin-top: 0; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; margin: 8px 0 0; }
.split.product { grid-template-columns: 7fr 5fr; align-items: start; }
.gallery { display: grid; gap: 14px; margin: 0; }
.gallery img { border-radius: 2px; }
.buy-col { position: sticky; top: 92px; }
.action { border: 1px solid var(--line); border-radius: 2px; padding: 26px; }
.action + .action { margin-top: 16px; }
.action .eyebrow { margin-bottom: 14px; }
.piece > .eyebrow { margin-bottom: 12px; }
.action .capture { margin-top: 6px; }
.rot-note { margin: 0 0 12px; font-size: 14px; color: var(--ink-soft); }
.price-line { font-family: var(--display); font-weight: 400; font-size: 30px; line-height: 1.1; margin: 0 0 14px; }
.buy-col .info { margin-top: 26px; }
.buy-col > p { margin-top: 22px; }
@media (max-width: 760px) {
  .split, .split.product { grid-template-columns: 1fr; gap: 26px; }
  .buy-col { position: static; }
}

.info { border-collapse: collapse; width: 100%; font-size: 15px; }
.info th, .info td { text-align: left; padding: 11px 12px 11px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.info th { color: var(--ink-soft); white-space: nowrap; padding-right: 24px; font-weight: 500; }
.info a { color: var(--ink); }

.notes p { max-width: 68ch; }
.video { aspect-ratio: 16 / 9; margin: 40px 0; }
.video iframe { width: 100%; height: 100%; border: 0; border-radius: 2px; }
/* YouTube Shorts are vertical */
.video.short { aspect-ratio: 9 / 16; max-width: 360px; }
.video-grid { display: grid; gap: 32px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); margin-top: 32px; }
.video-grid .video { margin: 0; }
.video-grid .video.short { max-width: none; }
.video-item { margin: 0; }
.video-item figcaption { margin-top: 10px; }
.ar-block { margin-top: 18px; }
model-viewer { width: 100%; height: 300px; background: var(--surface); border: 1px solid var(--line); border-radius: 2px; margin-bottom: 12px; }

/* ---- footer ------------------------------------------------------------ */
.bottom {
  border-top: 1px solid var(--line); padding: 36px 40px 56px;
  color: var(--ink-soft); text-align: center; letter-spacing: .12em;
}
.bottom p { margin: 8px auto; max-width: none; }
.bottom p:first-child { font-family: var(--display); font-style: italic; text-transform: none; letter-spacing: 0; font-size: 17px; color: var(--ink); }
.bottom a { color: var(--ink-soft); text-decoration: none; }
.bottom a:hover { color: var(--accent); }

/* ---- long-form pages ----------------------------------------------------- */
main > ul, main > p { max-width: var(--measure); }
main > ul { padding-left: 1.2em; }
main > ul li { margin: 8px 0; }
main > h2 { margin-top: 44px; }

/* Download verification: unobtrusive until someone wants it. */
.verify { margin: 12px 0 22px; max-width: var(--measure); }
.verify summary { cursor: pointer; font-size: 14px; color: var(--ink-soft); padding: 4px 0; }
.verify summary:hover { color: var(--accent); }
.verify .soft { margin: 8px 0; }
.verify code { font-family: ui-monospace, Consolas, monospace; font-size: 12px; word-break: break-all; }
.sums { border-collapse: collapse; width: 100%; margin: 8px 0; }
.sums th { text-align: left; font-size: 12px; color: var(--ink-soft); font-weight: 500; padding: 4px 12px 4px 0; vertical-align: top; white-space: nowrap; }
.sums td { padding: 4px 0; }

/* The header is sticky, so anchor jumps must clear it or the target lands
   underneath. Nav wraps to a second row under 760px, hence the taller value. */
html { scroll-padding-top: 96px; }
@media (max-width: 760px) { html { scroll-padding-top: 132px; } }

/* Early access: two steps Google requires, numbered so the order is obvious. */
.steps { margin: 0 0 1.1rem; padding-left: 1.4em; }
.steps li { margin-bottom: 1rem; }
.steps li::marker { font-weight: 700; }
.steps .actions { margin: .5rem 0 0; }

/* Contact form: labelled fields, full-width inputs, no address on the page. */
.contact { max-width: 34rem; }
.contact .field { display: flex; flex-direction: column; gap: .35rem; margin: 0 0 1rem; }
.contact label { font-size: .85rem; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-soft); }
.contact input, .contact textarea {
  font: inherit; font-size: 16px; color: var(--ink); background: var(--bg);
  border: 1px solid var(--line); border-radius: 2px; padding: .6rem .7rem; width: 100%;
}
.contact textarea { resize: vertical; min-height: 8rem; }
.contact input:focus-visible, .contact textarea:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.contact .hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
