/* Legal reading pages: privacy policy (LT, EN), terms, delete account.
   Adds only what .prose lacks: numbered clause lists, keyboard-scrollable tables. */

.prose.legal { padding-bottom: clamp(40px, 6vw, 96px); overflow-wrap: break-word; }
.prose.legal > h2:first-child { margin-top: 0; }
.prose.legal .note + h2 { margin-top: clamp(40px, 5vw, 56px); }

/* clause numbers sit in the text, so the lists carry no bullets */
.prose .n { color: var(--ink-3); font-variant-numeric: tabular-nums; }
.prose h2 .n { color: inherit; }
.prose ul.nl { list-style: none; padding-left: 0; gap: 10px; }
.prose ul.nl--2 { padding-left: 1.4em; margin-top: 10px; gap: 6px; }

/* tables: the wrapper scrolls (focusable for keyboard), the table keeps its columns */
.prose .tbl { overflow-x: auto; overscroll-behavior-x: contain; border-radius: 4px; }
.prose .tbl:focus-visible { outline: 2px solid var(--violet); outline-offset: 4px; }
.prose .tbl table { display: table; min-width: 720px; }
.prose .tbl th, .prose .tbl td { min-width: 0; }

/* the four-column table in 4.1 steps out of the reading column on wide screens */
.prose .tbl--wide { width: min(100vw - 2 * var(--gutter), 1040px); position: relative; left: 50%; transform: translateX(-50%); }
.prose .tbl--wide table { min-width: 760px; }
.prose .tbl:not(.tbl--wide) table { min-width: 520px; }

/* tables on a phone: each row becomes a small card with its labels (page.js adds them) */
@media (max-width: 600px) {
  .prose .tbl.is-cards { overflow: visible; }
  .prose .tbl--wide.is-cards { width: auto; left: auto; transform: none; }
  .prose .tbl.is-cards table, .prose .tbl.is-cards tbody, .prose .tbl.is-cards tr, .prose .tbl.is-cards td { display: block; min-width: 0; width: auto; }
  .prose .tbl.is-cards thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .prose .tbl.is-cards tbody { display: grid; gap: 10px; }
  .prose .tbl.is-cards tr { padding: 6px 16px; border-radius: 16px; background: var(--paper); box-shadow: inset 0 0 0 1px var(--hair); }
  .prose .tbl.is-cards td { padding: 10px 0; font-size: 14.5px; }
  .prose .tbl.is-cards td + td { box-shadow: inset 0 1px 0 var(--hair); }
  .prose .tbl.is-cards td:last-child { box-shadow: inset 0 1px 0 var(--hair); }
  .prose .tbl.is-cards td:first-child { box-shadow: none; color: var(--ink); font-weight: 600; }
  .prose .tbl.is-cards td[data-label]::before { content: attr(data-label); display: block; margin-bottom: 3px; font-size: 12.5px; font-weight: 600; color: var(--ink-3); }
}
