/* Cover site — the shared base every site version loads before its own style.css: reset, a11y
   helpers, the mechanics a version's design builds on (unsubscribe steps, disclosures, spinner,
   reveal on scroll, mobile-menu scroll lock). No colours, fonts or layout here — those are the
   version's. Mobile first: a version's style.css starts at phone width and adds min-width queries. */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; min-height: 100vh; min-height: 100dvh; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-wrap: break-word; }
h1, h2, h3, h4, p, ul, ol, dl, dd, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg, video { display: block; max-width: 100%; }
button, input, textarea, select { font: inherit; color: inherit; }
a { text-underline-offset: 2px; }
[hidden] { display: none !important; }
[tabindex="-1"]:focus { outline: none; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; padding: 10px 14px; border-radius: 8px; background: #000; color: #fff; text-decoration: none; font-weight: 600; }
.skip:focus { top: calc(12px + env(safe-area-inset-top)); }
.wrap { width: 100%; margin-inline: auto; padding-inline: max(20px, env(safe-area-inset-left)) max(20px, env(safe-area-inset-right)); }
.nowrap { white-space: nowrap; }
.domain { overflow-wrap: anywhere; }

/* Mobile menu: nothing scrolls behind it. */
@media (max-width: 859.98px) { .menu-open, .menu-open body { overflow: hidden; } }

/* <details> without the browser's marker. */
summary { cursor: pointer; list-style: none; }
summary::-webkit-details-marker { display: none; }

/* Unsubscribe: body[data-step] shows one step at a time. */
.step { display: none; }
body[data-step="confirm"] .step-confirm, body[data-step="why"] .step-why, body[data-step="done"] .step-done { display: block; }
.answered-only { display: none; }
.answered .answered-only { display: inline; }
.answered .unanswered-only { display: none; }
.no-link .more > summary { display: none; }
.choices { border: 0; margin: 0; padding: 0; min-width: 0; }
.choice { cursor: pointer; }
.choice input { appearance: none; -webkit-appearance: none; flex: none; margin: 0; display: grid; place-items: center; cursor: pointer; }
.choice input::after { content: ""; transform: scale(0); transition: transform .12s ease; }
.choice input:checked::after { transform: scale(1); }
input[type=email], textarea { width: 100%; font-size: 16px; /* 16px: no zoom on iOS */ }
textarea { resize: vertical; }
.count { justify-self: end; font-variant-numeric: tabular-nums; }
.btn { -webkit-tap-highlight-color: transparent; }
.btn .spin { display: none; width: 16px; height: 16px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: site-spin .7s linear infinite; }
.btn[aria-busy="true"] .spin { display: inline-block; }
@keyframes site-spin { to { transform: rotate(360deg); } }

/* Reveal on scroll (site.js adds .can-reveal only when it will run). */
.can-reveal [data-reveal] { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s cubic-bezier(.2, .7, .2, 1); }
.can-reveal [data-reveal].is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
@media print {
  .site-header, .site-footer, .toc, .menu-btn, .skip { display: none !important; }
  body { background: #fff !important; color: #000 !important; }
}

/* "Remove me from all mailings" (global unsubscribe) — every version's unsubscribe form. */
.all-mail { display: flex; align-items: flex-start; gap: 10px; min-height: 44px; padding: 10px 0; font-size: 14.5px; line-height: 1.45; color: var(--ink-2, inherit); cursor: pointer; }
.all-mail input { flex: none; width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--accent, currentColor); cursor: pointer; }
.all-mail input:focus-visible { outline: 3px solid var(--focus, rgba(37, 99, 235, .3)); outline-offset: 2px; }
