/* ==========================================================================
   Misc pages — Privacy notice template (.pv) and the 404 recovery page (.nf)
   ========================================================================== */

.pv-head__grid, .pv-body, .nf__grid { display: grid; grid-template-columns: repeat(var(--cols), minmax(0, 1fr)); column-gap: var(--gutter); }

/* ==========================================================================
   Privacy — a long-form reading page. Calm type, ~65ch measure,
   sticky contents on desktop, every body marked as placeholder.
   ========================================================================== */
.pv-head { padding-block: clamp(28px, 4vw, 64px) clamp(40px, 4.4vw, 72px); }
.pv-head__grid { row-gap: 22px; align-items: end; }
.pv-head__eyebrow { grid-column: 1 / -1; }
.pv-head__title { grid-column: 1 / span 8; font-variation-settings: "wdth" 80; }
.pv-head__lead { grid-column: 1 / span 6; }
.pv-meta { grid-column: 1 / -1; display: flex; flex-wrap: wrap; margin-top: 18px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.pv-meta > div { display: grid; gap: 6px; align-content: start; padding: 16px 32px 16px 0; margin-right: 32px; border-right: 1px solid var(--line); }
.pv-meta > div:last-child { border-right: 0; margin-right: 0; }
.pv-meta dt { font-family: var(--mono); font-size: var(--t-meta); font-weight: 500; letter-spacing: .05em; text-transform: uppercase; color: var(--fg-2); }
.pv-meta dd { font-size: 1rem; line-height: 1.4; font-weight: 520; }

.pv-banner {
  margin-top: clamp(28px, 3vw, 44px); display: flex; gap: 16px; align-items: flex-start;
  padding: 20px 24px 22px 20px; border-radius: var(--r-media); background: var(--ink); color: var(--paper);
}
.pv-banner__icon { flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--tomato); color: var(--ink); }
.pv-banner__icon .icon { width: 20px; height: 20px; stroke-width: 2; }
.pv-banner__text { display: grid; gap: 4px; font-size: 1rem; line-height: 1.5; color: var(--muted-on-ink); max-width: 33em; text-wrap: pretty; }
.pv-banner__title { color: var(--paper); font-weight: 650; font-size: 1.0625rem; }

.pv-body { padding-bottom: var(--section); align-items: start; }

/* ---------- contents ---------- */
.pv-toc { grid-column: 1 / span 3; position: sticky; top: calc(var(--header-h) + 28px); align-self: start; padding-top: 52px; }
.pv-toc__label { margin-bottom: 14px; }
.pv-toc__toggle { display: none; }
.pv-toc__list { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--line); }
.pv-toc__btn {
  position: relative; width: 100%; display: flex; align-items: baseline; gap: 12px; min-height: 44px; padding: 10px 8px 10px 18px; margin-left: -1px;
  border: 0; border-left: 2px solid transparent; background: transparent; text-align: left; color: var(--fg-2);
  font-size: .9375rem; line-height: 1.35; font-weight: 500; transition: color 140ms var(--ease), border-color 140ms var(--ease), background-color 140ms var(--ease);
}
.pv-toc__btn:hover { color: var(--fg); border-left-color: var(--field); }
.pv-toc__btn[aria-current="location"] { color: var(--fg); font-weight: 640; border-left-color: var(--tomato); }
.pv-toc__btn:focus-visible { outline-offset: -2px; }
.pv-toc__n { flex: none; font-family: var(--mono); font-size: .6875rem; letter-spacing: .04em; color: var(--fg-2); font-weight: 500; }
.pv-toc__btn[aria-current="location"] .pv-toc__n { color: var(--accent-text); }

/* ---------- sections ---------- */
.pv-content { grid-column: 5 / span 7; min-width: 0; }
.pv-sec { padding-block: 52px 8px; }
.pv-sec + .pv-sec { border-top: 1px solid var(--line); margin-top: 44px; }
.pv-sec__title {
  display: flex; align-items: baseline; gap: 16px;
  font-size: clamp(1.5rem, 1.2rem + .95vw, 2.125rem); line-height: 1.12; font-weight: 700; letter-spacing: -0.018em; font-variation-settings: "wdth" 88; text-wrap: balance;
}
.pv-sec__n { flex: none; font-family: var(--mono); font-size: .8125rem; font-weight: 500; letter-spacing: .04em; color: var(--accent-text); transform: translateY(-.3em); }
/* One right edge for every block in a section. 30 × the body size (not 65ch: Archivo sets far more characters per
   "0"-width than the ch unit assumes) gives a median of ~64 and a maximum of ~70 characters per line (DEV.md: 55–70).
   Expressed against --t-body rather than em so children with smaller type share the same edge. */
.pv-ph { --pv-measure: calc(var(--t-body) * 30); margin-top: 22px; padding-left: clamp(16px, 2vw, 26px); border-left: 2px dashed var(--field); display: grid; gap: 20px; }
.pv-ph > p, .pv-ph li { max-width: var(--pv-measure); font-size: var(--t-body); line-height: 1.65; text-wrap: pretty; }
.pv-ph__flag { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; font-size: .875rem !important; line-height: 1.4 !important; color: var(--fg-2); }
.pv-tok {
  font-family: var(--mono); font-size: .78em; letter-spacing: 0; color: var(--ink); white-space: normal;
  background: var(--paper-2); box-shadow: inset 0 0 0 1px var(--field); border-radius: 3px; padding: .12em .45em;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.pv-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.pv-list li { position: relative; padding-left: 22px; }
.pv-list li::before { content: ""; position: absolute; left: 0; top: .78em; width: 10px; height: 2px; border-radius: 2px; background: var(--tomato); }
.pv-list strong { font-weight: 640; }
.pv-opt { font-size: .875em; color: var(--fg-2); margin-left: 4px; }
.pv-opt::before { content: "· "; }
.pv-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px var(--gutter); max-width: var(--pv-measure); }
.pv-col { display: grid; gap: 12px; align-content: start; padding-top: 14px; border-top: 1.5px solid var(--fg); }
.pv-col .pv-list li { font-size: 1rem; line-height: 1.45; }
.pv-col__k { font-family: var(--mono); font-size: var(--t-meta); font-weight: 500; letter-spacing: .05em; text-transform: uppercase; color: var(--fg-2); }
.pv-facts { border-top: 1px solid var(--line); max-width: var(--pv-measure); }
.pv-facts__row { display: grid; grid-template-columns: minmax(0, 15em) minmax(0, 1fr); gap: 8px 20px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.pv-facts dt { font-size: .9375rem; line-height: 1.5; font-weight: 620; }
.pv-facts dd { font-size: .9375rem; line-height: 1.5; }
/* paper-2 panel: secondary text steps down to --muted-2 (5.45:1) as on .on-paper-2; --muted is only 4.41:1 here */
.pv-mail { --fg-2: var(--muted-2); display: grid; gap: 8px; padding: 18px 20px; border-radius: var(--r-media); background: var(--paper-2); max-width: var(--pv-measure); }
.pv-mail__label { display: flex; align-items: center; gap: 12px; }
.pv-mail__row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; }
.pv-mail__addr { font-size: 1.1875rem; font-weight: 640; overflow-wrap: anywhere; user-select: all; }
.pv-mail .copy-btn { min-height: 44px; padding-inline: 14px; }
.pv-end { margin-top: 64px; padding-top: 22px; border-top: 2px solid var(--fg); display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 16px 24px; }
.pv-end__text { font-size: .9375rem; color: var(--fg-2); max-width: 44ch; }
.pv-up { display: inline-flex; transform: rotate(180deg); }
.btn:hover .pv-up .icon { transform: translateY(2px); }

@media (max-width: 1199px) {
  .pv-toc { grid-column: 1 / span 3; }
  .pv-content { grid-column: 4 / -1; padding-left: 24px; }
}
@media (max-width: 1023px) {
  .pv-head__title, .pv-head__lead { grid-column: 1 / -1; }
  .pv-meta { display: grid; grid-template-columns: auto auto minmax(0, 1fr); }
  .pv-toc { grid-column: 1 / -1; position: static; padding-top: 0; margin-top: 8px; }
  .pv-toc__label { display: none; }
  .pv-toc__toggle {
    display: flex; align-items: center; gap: 12px; width: 100%; min-height: 56px; padding: 0 2px; border: 0;
    border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: transparent; color: var(--fg); text-align: left;
  }
  .pv-toc__toggle .label { color: var(--fg); }
  .pv-toc__count { font-size: .875rem; color: var(--fg-2); margin-right: auto; }
  .pv-toc__sign { position: relative; flex: none; width: 32px; height: 32px; border-radius: 50%; border: 1.5px solid currentColor; }
  .pv-toc__sign::before, .pv-toc__sign::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 1.5px; margin: -.75px 0 0 -6px; background: currentColor; transition: transform 180ms var(--ease); }
  .pv-toc__sign::after { transform: rotate(90deg); }
  .pv-toc__toggle[aria-expanded="true"] .pv-toc__sign::after { transform: rotate(0deg); }
  .pv-toc__list { display: none; border-left: 0; padding: 6px 0 10px; border-bottom: 1px solid var(--line); }
  .pv-toc.is-open .pv-toc__list { display: block; }
  .pv-toc__btn { padding-left: 2px; border-left: 0; margin-left: 0; }
  .pv-toc__btn[aria-current="location"] { box-shadow: inset 3px 0 0 var(--tomato); padding-left: 14px; }
  .pv-content { grid-column: 1 / -1; padding-left: 0; }
}
@media (min-width: 600px) and (max-width: 1023px) {
  .pv-toc.is-open .pv-toc__list { columns: 2; column-gap: var(--gutter); }
  .pv-toc__list li { break-inside: avoid; }
}
@media (max-width: 767px) {
  .pv-meta { display: grid; grid-template-columns: minmax(0, 1fr); }
  .pv-meta > div { border-right: 0; margin-right: 0; padding: 12px 0; grid-template-columns: 8.5em minmax(0, 1fr); gap: 12px; }
  .pv-meta > div + div { border-top: 1px solid var(--line); }
  .pv-banner { padding: 16px 16px 18px; gap: 12px; }
  .pv-banner__icon { width: 30px; height: 30px; }
  .pv-cols { grid-template-columns: minmax(0, 1fr); }
  .pv-facts__row { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .pv-sec { padding-top: 40px; }
  .pv-sec + .pv-sec { margin-top: 32px; }
}

/* ==========================================================================
   404 — "This page didn't make the final cut."
   ========================================================================== */
.nf { padding-block: clamp(32px, 5vw, 88px) var(--section); }
.nf__grid { row-gap: 48px; align-items: center; }
.nf__copy { grid-column: 1 / span 7; display: grid; gap: 26px; justify-items: start; }
.nf__title {
  font-size: var(--t-page); line-height: .96; font-weight: 740; letter-spacing: -0.032em;
  font-variation-settings: "wdth" 78; text-wrap: balance; max-width: 9em;
}
.nf__lead { max-width: 28em; }

.nf-edit { grid-column: 8 / -1; display: grid; gap: 18px; min-width: 0; }
.nf-strip {
  --hole: color-mix(in srgb, var(--paper) 24%, transparent);
  padding: 26px 14px; border-radius: 6px; transform: rotate(-1.2deg);
  background:
    radial-gradient(circle, var(--hole) 0 38%, transparent 42%) 0 8px / 18px 11px repeat-x,
    radial-gradient(circle, var(--hole) 0 38%, transparent 42%) 0 calc(100% - 8px) / 18px 11px repeat-x,
    var(--ink);
  box-shadow: 0 34px 60px -36px var(--ink);
}
.nf-strip__edge { display: flex; justify-content: space-between; font-family: var(--mono); font-size: .6875rem; letter-spacing: .05em; text-transform: uppercase; color: var(--muted-on-ink); margin-bottom: 10px; }
.nf-strip__frames { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.nf-strip__frame { position: relative; aspect-ratio: 4 / 5; overflow: hidden; border-radius: 2px; background: var(--ink-2); }
.nf-strip__frame img { width: 100%; height: 100%; object-fit: cover; filter: saturate(.85); }
.nf-strip__frame > span:last-child {
  position: absolute; left: 6px; bottom: 6px; font-family: var(--mono); font-size: .625rem; letter-spacing: .04em; line-height: 1;
  color: var(--paper); background: color-mix(in srgb, var(--ink) 75%, transparent); padding: 3px 5px; border-radius: 2px;
}
.nf-strip__frame.is-missing img { visibility: hidden; }
.nf-strip__frame--gap {
  display: grid; align-content: center; justify-items: center; gap: 8px; padding: 10px; text-align: center;
  background: transparent; box-shadow: inset 0 0 0 1.5px var(--tomato); border-radius: 3px;
  background-image: repeating-linear-gradient(135deg, color-mix(in srgb, var(--tomato) 16%, transparent) 0 1px, transparent 1px 9px);
}
.nf-strip__x { font-family: var(--mono); font-size: .6875rem; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; white-space: nowrap; color: var(--ink); background: var(--tomato); padding: 4px 6px; border-radius: 2px; }
.nf-strip__path { font-family: var(--mono); font-size: .75rem; line-height: 1.3; color: var(--paper); overflow-wrap: anywhere; max-width: 100%; }
.nf-edl { display: grid; border-top: 1.5px solid var(--fg); }
.nf-edl > div { display: grid; grid-template-columns: 7.5em minmax(0, 1fr); gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); align-items: baseline; }
.nf-edl dt { font-family: var(--mono); font-size: var(--t-meta); font-weight: 500; letter-spacing: .05em; text-transform: uppercase; color: var(--fg-2); }
.nf-edl dd { font-size: 1rem; line-height: 1.4; font-weight: 540; min-width: 0; }
.nf__lead .nf-path { font-size: .82em; }
.nf-path { font-family: var(--mono); font-size: .9375rem; overflow-wrap: anywhere; background: var(--paper-2); padding: 2px 6px; border-radius: 3px; }

.nf__next { grid-column: 1 / -1; margin-top: clamp(8px, 4vw, 64px); }
.nf__next-label { margin-bottom: 14px; }
.nf-links { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: var(--gutter); }
.nf-links li { border-top: 2px solid var(--fg); }
.nf-link {
  position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "n go" "t go" "d d";
  gap: 8px 16px; min-height: 100%; padding: 18px 0 28px; text-decoration: none; color: var(--fg);
}
.nf-link__n { grid-area: n; font-family: var(--mono); font-size: var(--t-meta); font-weight: 500; letter-spacing: .05em; color: var(--fg-2); }
.nf-link__t {
  grid-area: t; justify-self: start; position: relative;
  font-size: clamp(1.75rem, 1.3rem + 1.4vw, 2.75rem); line-height: 1.02; font-weight: 720; letter-spacing: -0.026em; font-variation-settings: "wdth" 82;
}
.nf-link__t::after { content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 3px; border-radius: 3px; background: var(--tomato); transform: scaleX(0); transform-origin: left; transition: transform 200ms var(--ease); }
.nf-link:hover .nf-link__t::after, .nf-link:focus-visible .nf-link__t::after { transform: scaleX(1); }
.nf-link__d { grid-area: d; font-size: 1rem; line-height: 1.45; color: var(--fg-2); margin-top: 6px; }
.nf-link__go { grid-area: go; align-self: start; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; border: 1.5px solid var(--fg); transition: background-color 160ms var(--ease), color 160ms var(--ease); }
.nf-link__go .icon { width: 20px; height: 20px; transition: transform 160ms var(--ease); }
.nf-link:hover .nf-link__go { background: var(--fg); color: var(--bg); }
.nf-link:hover .nf-link__go .icon { transform: translate(2px, -2px); }
.nf-link:focus-visible { outline-offset: 6px; }

@media (max-width: 1023px) {
  .nf__copy { grid-column: 1 / -1; }
  .nf-edit { grid-column: 1 / span 6; }
  .nf-links { grid-template-columns: minmax(0, 1fr); }
  .nf-links li { border-top-width: 1px; }
  .nf-links li:first-child { border-top-width: 2px; }
  .nf-link { padding: 18px 0 20px; }
}
@media (max-width: 767px) {
  .nf__grid { row-gap: 40px; }
  .nf-edit { grid-column: 1 / -1; order: 2; }
  .nf__next { order: 1; margin-top: 0; }
  .nf-strip { padding: 22px 10px; }
  .nf-strip__frames { gap: 7px; }
  .nf-link__go { width: 44px; height: 44px; }
}
@media (max-width: 359px) {
  .nf-strip__frame--gap { padding: 8px 4px; }
  .nf-strip__x { font-size: .5625rem; letter-spacing: .03em; padding: 3px 4px; }
  .nf-strip__path { font-size: .6875rem; }
}
