/* Long pages: privacy, terms, delete-account, support. A warm head with an illustration, the short version on a
   Butter note, a table of contents beside the text on wide screens, and calm, readable prose. */

.legal-head { padding-block: 36px 24px; }
.legal-head-grid { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px 40px; align-items: center; }
.legal-head-copy { display: grid; gap: 14px; justify-items: start; max-width: 680px; }
.legal-head h1 { font-size: clamp(40px, 6.4vw, 68px); letter-spacing: -0.04em; line-height: 0.98; }
.legal-head .lead { font-size: clamp(18px, 2vw, 20px); color: var(--muted); }
.updated { font-size: 14.5px; color: var(--muted); }
.legal-art { width: clamp(160px, 24vw, 270px); height: auto; }
.art-blob, .art-bite { fill: #2E1838; }
.art-z { fill: #FFE08A; font-family: var(--f-display); font-weight: 900; font-size: 24px; }
.art-z.small { font-size: 16px; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .art-blob, :root:not([data-theme="light"]) .art-bite { fill: #2E1E35; } }
:root[data-theme="dark"] .art-blob, :root[data-theme="dark"] .art-bite { fill: #2E1E35; }

.legal-layout { display: grid; gap: 20px; padding-bottom: 40px; }
.legal-prose { max-width: 720px; min-width: 0; }
.legal-prose h2 { font-size: clamp(25px, 3.4vw, 30px); margin-top: 30px; scroll-margin-top: 90px; }
.legal-prose h3 { font-size: 19px; margin-top: 10px; }
.legal-prose p, .legal-prose li { line-height: 1.6; }
.legal-prose b { font-weight: 700; }

/* table of contents */
.toc { background: var(--surface); border-radius: 22px; box-shadow: var(--shadow); padding: 4px 18px; align-self: start; }
.toc summary { cursor: pointer; list-style: none; padding: 13px 0; font-weight: 700; display: flex; justify-content: space-between; align-items: center; }
.toc summary::-webkit-details-marker { display: none; }
.toc summary::after { content: "+"; font-family: var(--f-display); font-weight: 800; font-size: 20px; width: 30px; height: 30px; border-radius: 50%; background: var(--peach); display: grid; place-items: center; transition: transform .2s; }
.toc[open] summary::after { transform: rotate(45deg); }
.toc ol { margin: 0 0 14px; padding-left: 22px; display: grid; gap: 4px; font-size: 15.5px; }
.toc ol li::marker { color: var(--muted); font-size: 13px; }
.toc a { color: var(--ink); text-decoration: none; display: inline-block; padding-block: 3px; }
.toc a:hover { text-decoration: underline; }

/* the short version: a Butter note, a little askew */
.short { background: var(--butter); color: var(--on-butter); border-radius: 26px; padding: 22px 24px 24px; rotate: -1deg; box-shadow: var(--shadow); margin-bottom: 8px; }
.short h2 { margin-top: 0; font-size: 23px; color: var(--on-butter); }
.short ul { margin-top: 10px; }
.short li, .short a { color: var(--on-butter); }

/* tables */
.table-wrap { overflow-x: auto; border-radius: 22px; background: var(--surface); box-shadow: var(--shadow); }
.legal-prose table { width: 100%; border-collapse: collapse; font-size: 15.5px; }
.legal-prose th { text-align: left; font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); font-weight: 700; padding: 14px 16px 10px; background: var(--surface-2); }
.legal-prose td { padding: 12px 16px; border-top: 1px solid var(--line); vertical-align: top; }
.legal-prose td:last-child { color: var(--muted); }
.legal-prose tr td:first-child { width: 58%; }

/* "Coming" */
.coming-list { list-style: none; padding-left: 0 !important; gap: 12px !important; }
.coming-list li { background: var(--surface); border-radius: 20px; padding: 14px 18px; box-shadow: var(--shadow); }

@media (min-width: 1000px) {
  .legal-head { padding-block: 56px 36px; }
  .legal-layout { grid-template-columns: 250px minmax(0, 720px); gap: 56px; justify-content: center; }
  .toc { position: sticky; top: 88px; max-height: calc(100vh - 110px); overflow: auto; background: transparent; box-shadow: none; padding: 0; }
  .toc summary { display: none; }
  .toc ol { margin: 0; font-size: 15px; }
}
@media (max-width: 640px) {
  .legal-head { padding-top: 20px; }
  .legal-head-grid { grid-template-columns: 1fr; }
  .legal-art { order: -1; width: 150px; justify-self: start; }
  .short { rotate: -0.6deg; padding: 18px 18px 20px; }
  .legal-prose td, .legal-prose th { padding-inline: 12px; }
}

.art-soft { fill: var(--peach); }

/* emergency: Siren only here, always with its icon */
.sos-note { display: grid; grid-template-columns: 36px 1fr; gap: 12px; align-items: start; background: var(--siren-soft); border: 2px solid var(--siren); border-radius: 22px; padding: 16px 18px; }
.sos-ico { width: 36px; height: 36px; border-radius: 50%; background: var(--siren); color: #FFFFFF; display: grid; place-items: center; }
.sos-ico svg { width: 20px; height: 20px; }
.sos-note p { color: var(--ink); }

/* support: contact and emergency side by side, then questions per topic */
.help { display: grid; gap: 44px; padding-bottom: 48px; max-width: 980px; }
.help-top { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 18px; align-items: stretch; }
.help-contact { background: var(--surface); border-radius: 30px; box-shadow: var(--shadow); padding: 26px; display: grid; gap: 12px; justify-items: start; align-content: start; }
.help-contact h2, .help-sos h2 { font-size: 26px; }
.help-contact p { color: var(--muted); }
.help-contact .btn { white-space: normal; }
.help-tip { font-size: 14.5px; }
.help-sos { border-radius: 30px; padding: 24px; align-content: start; }
.help-sos h2 { margin-bottom: 6px; font-size: 22px; }
.help-group { display: grid; gap: 16px; }
.help-group h2 { font-size: clamp(26px, 3.6vw, 34px); display: flex; align-items: center; gap: 14px; scroll-margin-top: 90px; }
.qa { display: grid; gap: 10px; }
.qa details { background: var(--surface); border-radius: 22px; padding: 0 20px; box-shadow: var(--shadow); }
.qa summary { cursor: pointer; list-style: none; padding: 17px 0; font-weight: 700; display: flex; justify-content: space-between; gap: 12px; align-items: center; }
.qa summary::-webkit-details-marker { display: none; }
.qa summary::after { content: "+"; font-family: var(--f-display); font-weight: 800; font-size: 21px; width: 32px; height: 32px; border-radius: 50%; background: var(--peach); display: grid; place-items: center; flex: none; transition: transform .2s; }
.qa details[open] summary::after { transform: rotate(45deg); }
.qa details p { padding-bottom: 18px; color: var(--muted); line-height: 1.6; }
.qa details a { color: var(--ink); font-weight: 600; }
@media (max-width: 760px) {
  .help-top { grid-template-columns: 1fr; }
  .help-contact, .help-sos { padding: 20px; border-radius: 26px; }
}
.help-page .legal-head .wrap { max-width: 980px; }

/* delete-account */
.del-ways { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; align-items: stretch; }
.del-way { position: relative; background: var(--surface); border-radius: 30px; box-shadow: var(--shadow); padding: 26px; display: grid; gap: 12px; justify-items: start; align-content: start; }
.del-way h2 { font-size: 26px; }
.del-way p { color: var(--muted); }
.del-way .btn { white-space: normal; text-align: left; }
.del-tag { width: 48px; height: 48px; display: grid; place-items: center; background: var(--butter); color: var(--on-butter); border-radius: 52% 48% 46% 54% / 56% 50% 50% 44%; }
.del-tag svg { width: 24px; height: 24px; }
.del-way + .del-way .del-tag { background: var(--mint); color: var(--on-mint); }
.steps { margin: 0; padding: 0; list-style: none; counter-reset: step; display: grid; gap: 10px; }
.steps li { counter-increment: step; position: relative; padding-left: 38px; min-height: 26px; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 26px; height: 26px; border-radius: 50%; background: var(--peach); display: grid; place-items: center; font-weight: 800; font-size: 14px; }
.del-note { font-size: 15px; }
.del-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.del-option { background: var(--surface); border-radius: 24px; box-shadow: var(--shadow); padding: 20px 22px; display: grid; gap: 6px; }
.del-option h3 { font-size: 20px; }
.del-option p { color: var(--muted); }
.del-before { rotate: 0.8deg; }
.del-before p { color: var(--on-butter); }
.del-before h2 { margin-bottom: 6px; }
.del-lists { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; align-items: start; }
.del-list { background: var(--surface); border-radius: 24px; box-shadow: var(--shadow); padding: 20px 22px; display: grid; gap: 10px; }
.del-list h3 { font-size: 20px; display: flex; align-items: center; gap: 10px; }
.del-list h3::before { content: ""; width: 14px; height: 14px; border-radius: 50%; background: var(--mint); }
.del-list.kept h3::before { background: var(--butter); }
.del-list ul { margin: 0; padding-left: 20px; display: grid; gap: 8px; }
.del-list li { line-height: 1.55; }
.wave-hand { transform-box: fill-box; transform-origin: 50% 100%; animation: wave-hello 2.4s ease-in-out infinite; }
@keyframes wave-hello { 0%, 60%, 100% { rotate: 0deg; } 15%, 45% { rotate: 16deg; } 30% { rotate: -10deg; } }
@media (max-width: 760px) {
  .del-ways, .del-options, .del-lists { grid-template-columns: 1fr; }
  .del-way { padding: 20px; border-radius: 26px; }
}
