@font-face { font-family: "Serif"; src: url("/fonts/serif.woff2") format("woff2"); font-weight: 200 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Serif"; src: url("/fonts/serif-italic.woff2") format("woff2"); font-weight: 200 900; font-style: italic; font-display: swap; }
@font-face { font-family: "Plex Mono"; src: url("/fonts/plex-mono-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Plex Mono"; src: url("/fonts/plex-mono-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --paper: #f4f1ea;
  --surface: #fbfaf6;
  --ink: #171a17;
  --muted: #5a5f58;
  --rule: #d9d4c7;
  --green: #1f5a3d;
  --green-ink: #174a31;
  --green-wash: rgb(31 90 61 / 0.07);
  --green-line: rgb(31 90 61 / 0.35);
  --red: #9b2a22;
  --serif: "Serif", "Iowan Old Style", Charter, Georgia, serif;
  --mono: "Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0f1210;
    --surface: #161a17;
    --ink: #e9ebe4;
    --muted: #a0a69c;
    --rule: #2a302b;
    --green: #6fc196;
    --green-ink: #8fd4ad;
    --green-wash: rgb(111 193 150 / 0.08);
    --green-line: rgb(111 193 150 / 0.4);
    --red: #e0796f;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 4.5rem; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--serif); font-size: 1.0625rem; line-height: 1.5;
  font-optical-sizing: auto; -webkit-font-smoothing: antialiased;
  font-variant-numeric: oldstyle-nums proportional-nums;
  hyphens: manual;
}
::selection { background: var(--green); color: var(--paper); }
a { color: inherit; text-decoration-color: var(--green-line); text-underline-offset: 0.18em; }
:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; border-radius: 3px; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums lining-nums; letter-spacing: -0.01em; }

main {
  max-width: 50rem; margin: 0 auto;
  padding: max(2.5rem, env(safe-area-inset-top)) clamp(1.1rem, 5vw, 2.5rem) max(3rem, env(safe-area-inset-bottom));
}

/* masthead */
.mast { border-bottom: 1px solid var(--ink); padding-bottom: 1.4rem; margin-bottom: 0; }
.kicker { font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--green); margin: 0 0 0.9rem; }
h1 { font-weight: 600; font-size: clamp(2.4rem, 8vw, 3.6rem); line-height: 1.02; letter-spacing: -0.02em; margin: 0; font-variation-settings: "opsz" 60; }
h1 em { font-style: italic; font-weight: 400; color: var(--green); }
.lede { color: var(--muted); max-width: 36rem; margin: 1rem 0 0; font-size: 1.08rem; }
.lede strong { color: var(--ink); font-weight: 600; }

/* nav */
nav.jump {
  position: sticky; top: 0; z-index: 5; background: var(--paper);
  display: flex; gap: 0.35rem; overflow-x: auto; scrollbar-width: none;
  padding: 0.7rem 0; border-bottom: 1px solid var(--rule);
  margin: 0 calc(-1 * clamp(1.1rem, 5vw, 2.5rem)); padding-left: clamp(1.1rem, 5vw, 2.5rem); padding-right: clamp(1.1rem, 5vw, 2.5rem);
}
nav.jump::-webkit-scrollbar { display: none; }
nav.jump a {
  flex: none; text-decoration: none; font-family: var(--mono); font-size: 0.8rem;
  padding: 0.38rem 0.75rem; border: 1px solid var(--rule); border-radius: 999px; color: var(--ink); background: var(--surface);
}
nav.jump a:hover { border-color: var(--green); color: var(--green-ink); }
nav.jump a span { color: var(--muted); margin-left: 0.35rem; }

/* sections */
section.group { padding-top: 2.6rem; }
.ghead { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; border-bottom: 1px solid var(--rule); padding-bottom: 0.6rem; }
h2 { font-size: 1.85rem; font-weight: 600; letter-spacing: -0.015em; margin: 0; line-height: 1.1; font-variation-settings: "opsz" 40; }
.budget { font-family: var(--mono); font-size: 0.8rem; color: var(--muted); white-space: nowrap; }
.gnote { color: var(--muted); margin: 0.75rem 0 0; max-width: 38rem; }
.gnote strong { color: var(--ink); font-weight: 600; }

/* gift rows */
.list { list-style: none; margin: 0; padding: 0; }
.gift {
  display: grid; grid-template-columns: 6.5rem 1fr; gap: 1.1rem;
  padding: 1.25rem 0; border-bottom: 1px solid var(--rule); align-items: start;
}
.ph {
  width: 6.5rem; aspect-ratio: 1; background: #fff; border-radius: 6px; overflow: hidden;
  display: grid; place-items: center; border: 1px solid var(--rule);
}
.ph img { width: 100%; height: 100%; object-fit: contain; padding: 0.4rem; display: block; }
.ph.cover img { object-fit: cover; padding: 0; }
.ph.type { background: var(--green); color: var(--paper); border-color: var(--green); font-family: var(--serif); font-style: italic; font-size: 1.5rem; text-align: center; line-height: 1.05; padding: 0.5rem; }
@media (prefers-color-scheme: dark) { .ph.type { color: #0f1210; } }
.gift h3 { margin: 0; font-size: 1.2rem; font-weight: 600; line-height: 1.25; letter-spacing: -0.005em; }
.gift .by { font-weight: 400; color: var(--muted); }
.pick {
  display: inline-block; vertical-align: 0.15em; margin-left: 0.4rem;
  font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--green-ink); border: 1px solid var(--green-line); background: var(--green-wash); border-radius: 3px; padding: 0.05rem 0.35rem;
}
.why { margin: 0.35rem 0 0; }
.spec { margin: 0.35rem 0 0; color: var(--muted); font-size: 0.95rem; }
.row { display: flex; align-items: center; gap: 0.9rem; flex-wrap: wrap; margin-top: 0.7rem; }
.price { font-family: var(--mono); font-size: 0.95rem; font-weight: 500; }
.price small { font-weight: 400; color: var(--muted); font-size: 0.8rem; }
.buy {
  font-family: var(--mono); font-size: 0.82rem; text-decoration: none; font-weight: 500;
  color: var(--paper); background: var(--green); padding: 0.42rem 0.8rem; border-radius: 4px;
}
.buy:hover { background: var(--green-ink); }
@media (prefers-color-scheme: dark) { .buy { color: #0f1210; } }
.alt { font-family: var(--mono); font-size: 0.8rem; color: var(--muted); }
.alt a { color: var(--muted); }
.must {
  margin: 0.55rem 0 0; font-size: 0.92rem; color: var(--red);
  font-family: var(--mono); letter-spacing: -0.01em;
}

/* tiers */
h4.tier { font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--green); margin: 1.6rem 0 0; font-weight: 500; }

footer { margin-top: 3rem; padding-top: 1.2rem; border-top: 1px solid var(--ink); color: var(--muted); font-size: 0.9rem; }
footer p { margin: 0 0 0.5rem; }

@media (min-width: 700px) {
  .gift { grid-template-columns: 8rem 1fr; gap: 1.4rem; }
  .ph { width: 8rem; }
}
@media (max-width: 380px) {
  .gift { grid-template-columns: 5rem 1fr; gap: 0.85rem; }
  .ph { width: 5rem; }
}
