/* noahlampert.com/privacy, on top of site.css. */
/* One reading column on phones and laptops: head, the switch, the sections. From 1100 px the
   head spans the width, so the h1 starts at the gutter under the logo like every other page,
   and the switch and a short contents list sit in a sticky aside beside the text. */
.privacy-grid { display: grid; grid-template-areas: "head" "aside" "body"; max-width: calc(var(--readw) + 2 * var(--gutter)); }
.privacy-head { grid-area: head; padding-top: clamp(32px, 6vw, 72px); }
.privacy-aside { grid-area: aside; margin-top: clamp(28px, 4vw, 44px); }
.privacy-body { grid-area: body; min-width: 0; }
.privacy-toc { display: none; }
@media (min-width: 1100px) {
  .privacy-grid { grid-template-columns: 20rem minmax(0, 1fr); grid-template-areas: "head head" "aside body"; column-gap: 64px; max-width: min(var(--maxw), calc(var(--readw) + 20rem + 64px + 2 * var(--gutter))); } /* lines up with the header */
  .privacy-aside { position: sticky; top: calc(var(--top-h) + 24px); align-self: start; display: grid; gap: 28px; margin-top: clamp(32px, 6vw, 72px); }
  .privacy-aside .optout { padding: 24px; }
  .privacy-toc { display: block; }
}
.privacy-toc ol { list-style: none; margin-top: 10px; border-top: 1px solid var(--line); }
.privacy-toc a { display: block; padding: 9px 2px; border-bottom: 1px solid var(--line); color: var(--soft); text-decoration: none; font-size: 0.9375rem; }
.privacy-toc a:hover, .privacy-toc a:focus-visible { color: var(--text); }
.privacy-head h1 { margin-top: 12px; max-width: 12ch; }
/* Short sections: h3-sized headings and a shorter thread between them. */
.privacy-page .sec { --gap: clamp(40px, 5vw, 64px); }
.privacy-page .sec-head { display: grid; grid-template-columns: none; margin-bottom: 14px; }
.privacy-page main h2 { font-size: var(--fs-h3); line-height: 1.15; }
.updated { margin-top: 18px; font-family: var(--mono); font-size: var(--fs-meta); letter-spacing: 0.03em; color: var(--soft); }

.prose { max-width: 72ch; }
.prose > p { color: var(--soft); font-size: 1.0625rem; }
.prose > p + p, .prose .rows + p { margin-top: 18px; }
.prose .rows { margin-top: 0; }
.prose a { color: var(--text); text-underline-offset: 3px; }

/* The opt-out: a switch, on = not counted. */
.optout { display: grid; gap: 10px; justify-items: start; padding: clamp(20px, 3vw, 36px); }
.optout > p:not(.label) { color: var(--soft); max-width: 60ch; }
/* The switch says its state in words too: OFF beside the knob on the left, ON once it slides right. */
.switch {
  position: relative; width: 84px; height: 36px; margin-top: 8px; padding: 0; cursor: pointer;
  border-radius: 999px; border: 1px solid var(--line-2); background: rgba(251, 241, 208, 0.06);
  transition: background 0.2s ease, border-color 0.2s ease;
}
.switch .knob { position: absolute; top: 3px; left: 3px; width: 28px; height: 28px; border-radius: 50%; background: var(--soft); transition: transform 0.2s ease, background 0.2s ease; }
.switch[aria-checked="true"] { background: var(--acc); border-color: var(--acc); }
.switch::after { content: "Off"; position: absolute; top: 0; right: 12px; line-height: 34px; font: 500 var(--fs-meta)/34px var(--mono); letter-spacing: 0.07em; text-transform: uppercase; color: var(--soft); }
.switch[aria-checked="true"] .knob { transform: translateX(48px); background: var(--bg); }
.switch[aria-checked="true"]::after { content: "On"; right: auto; left: 14px; color: var(--bg); }
.switch:hover { border-color: var(--text); }
.optout-status { font-family: var(--mono); font-size: var(--fs-meta); letter-spacing: 0.03em; line-height: 1.6; color: var(--text) !important; }
@media (prefers-reduced-motion: reduce) { .switch, .switch .knob { transition: none; } }
