/* Legal documents and cookie choices use the existing Ruststat monochrome system. */
body { padding-bottom: var(--rs-cookie-space, 0px); }
.rs-legal { width: min(1180px, calc(100% - var(--rs-gutter, 24px) * 2)); margin: 64px auto 88px; }
.rs-legal h1 { max-width: 880px; font: 650 clamp(30px, 4.4vw, 60px)/1.12 var(--rs-font); letter-spacing: -.045em; margin: 22px 0; }
.rs-legal-lead { max-width: 65ch; font-size: 18px; line-height: 1.65; }
.rs-legal-meta { color: var(--rs-muted); font-size: 14px; margin: 20px 0 40px; }
.rs-legal-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 64px; align-items: start; }
.rs-legal-nav { position: sticky; top: 116px; display: grid; gap: 5px; }
.rs-legal-nav a { display: block; padding: 10px 12px; font-size: 15px; line-height: 1.5; text-decoration: none; }
.rs-legal-nav a:hover, .rs-legal-nav a[aria-current] { background: var(--rs-raised); }
.rs-legal article { min-width: 0; font-size: 16px; line-height: 1.75; overflow-wrap: anywhere; }
.rs-legal article h2 { font-size: 23px; line-height: 1.35; margin: 0 0 16px; letter-spacing: -.025em; }
.rs-legal article p { margin: 0 0 16px; }
.rs-legal p, body[data-rs-page='legal'] #rs-footer > p { max-width: 65ch; }
.rs-legal article section { margin-bottom: 44px; scroll-margin-top: 112px; }
.rs-legal article ul, .rs-legal article ol { padding-left: 23px; margin: 0 0 20px; }
.rs-legal article li { margin: 8px 0; }
.rs-legal article a, .rs-legal-back { text-underline-offset: 4px; }
.rs-legal-note { background: var(--rs-raised); padding: 22px; margin: 0 0 32px; }
.rs-legal-note p:last-child { margin-bottom: 0; }
.rs-legal-dl { margin: 0; }
.rs-legal-dl dt { color: var(--rs-muted); margin-top: 16px; font-size: 14px; }
.rs-legal-dl dd { margin: 4px 0 16px; }
.rs-document-list { display: grid; gap: 0; }
.rs-document-list > div { padding: 20px 0; }
.rs-document-list a { text-decoration: none; }
.rs-legal .rs-document-list h3 { font-size: 22px; line-height: 1.35; margin: 0 0 7px; }
.rs-legal .rs-document-list p { font-size: 16px; color: var(--rs-muted); margin: 0; }
.rs-document-list a:hover { text-decoration: underline; text-underline-offset: 5px; }
.rs-legal-button, .rs-cookie-actions button { padding: 13px 18px; background: var(--rs-ink); color: var(--rs-ground); border: 0; border-radius: 3px; min-height: 46px; font: 650 14px/1.4 var(--rs-font); cursor: pointer; text-decoration: none; display: inline-block; }
.rs-legal-button:hover, .rs-cookie-actions button:hover { background: #d8d8d8; }
.rs-legal-button:active, .rs-cookie-actions button:active { transform: translateY(1px); }
.rs-legal-check { display: flex; align-items: flex-start; gap: 10px; font: 400 14px/1.65 var(--rs-font) !important; color: var(--rs-ink) !important; margin: 16px 0; text-transform: none !important; letter-spacing: 0 !important; }
.rs-legal-check input { width: 18px !important; height: 18px !important; min-height: 18px !important; flex: 0 0 18px; margin: 3px 0 0; accent-color: var(--rs-ink); }
.rs-legal-form-note { font-size: 13px; line-height: 1.65; color: var(--rs-muted); }
.rs-cookie-banner { position: fixed; z-index: 1300; bottom: 22px; left: 50%; transform: translateX(-50%); width: min(1090px, calc(100% - 40px)); max-height: calc(100dvh - 44px); overflow: auto; background: #292929; color: #f1f1f1; padding: 20px; display: grid; grid-template-columns: minmax(0,1fr) 224px; gap: 36px; border-radius: 4px; box-shadow: 0 12px 55px #0008; } /* taste-skill-ignore: The cookie banner is a floating overlay; a shadow separates it from the page. */
.rs-cookie-banner h2 { margin: 0 0 8px; font: 650 22px/1.3 var(--rs-font); letter-spacing: -.025em; }
.rs-cookie-banner p { margin: 0 0 8px; font: 400 16px/1.5 var(--rs-font); }
.rs-cookie-copy p { max-width: 65ch; }
.rs-cookie-links { display: flex; gap: 12px 22px; flex-wrap: wrap; font-size: 13px; }
.rs-cookie-links a { text-underline-offset: 4px; }
.rs-cookie-actions { display: grid; gap: 10px; align-content: center; }
.rs-cookie-actions button { width: 100%; }
.rs-cookie-actions .rs-cookie-close { background: transparent; color: #f1f1f1; text-decoration: underline; }
.rs-cookie-error:empty, .rs-cookie-current:empty { display: none; }
.rs-footer-legal { display: flex; flex-wrap: wrap; gap: 16px 24px; margin-top: 28px; max-width: 1000px; }
.rs-footer-legal a, .rs-footer-legal button { font: 400 14px/1.5 var(--rs-font); color: var(--rs-muted); background: transparent; padding: 0; border: 0; cursor: pointer; text-decoration: none; min-height: 26px; }
.rs-footer-legal a:hover, .rs-footer-legal button:hover { color: var(--rs-ink); text-decoration: underline; text-underline-offset: 4px; }
.rs-visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
/* Keep legal text unobstructed; on these pages the same controls sit after the document. */
body[data-rs-page='legal'] { padding-bottom: 0; }
body[data-rs-page='legal'] .rs-cookie-banner { position: relative; left: auto; bottom: auto; transform: none; margin: 0 auto 32px; box-shadow: none; } /* taste-skill-ignore: Removes the overlay shadow when the banner is in document flow. */
@media (max-width: 800px) {
  .rs-legal-layout { grid-template-columns: 1fr; gap: 34px; }
  .rs-legal-nav { position: static; display: flex; flex-wrap: wrap; gap: 4px; }
  .rs-legal-nav a { font-size: 14px; padding: 8px 10px; background: var(--rs-surface); }
  .rs-legal { margin-top: 40px; }
  .rs-cookie-banner { gap: 20px; grid-template-columns: 1fr; padding: 22px; }
  .rs-cookie-actions { grid-template-columns: 1fr 1fr; }
  .rs-cookie-actions .rs-cookie-close, .rs-cookie-error { grid-column: 1 / -1; }
}
@media (max-width: 440px) {
  .rs-cookie-banner { width: calc(100% - 24px); bottom: 12px; padding: 16px; gap: 12px; }
  .rs-cookie-banner h2 { font-size: 20px; }
  .rs-cookie-actions { grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 8px; }
  .rs-cookie-actions button { min-height: 54px; padding: 10px 8px; }
  .rs-legal h1 { font-size: 30px; }
  .rs-legal article h2 { font-size: 22px; }
}
@media (prefers-reduced-motion: reduce) { .rs-cookie-actions button:active, .rs-legal-button:active { transform: none; } }
@media print {
  #rs-header, #rs-footer, #rs-cookie-banner, .rs-legal-nav, .rs-legal-back, .rs-legal-button { display: none !important; }
  html, body { background: white !important; color: black !important; }
  .rs-legal { margin: 0; width: 100%; }
  .rs-legal-layout { display: block; }
  .rs-legal-note { background: #eee; }
  .rs-legal a { color: inherit; }
}

.auth-modal .rs-legal-check a, .auth-modal .rs-legal-form-note a { text-decoration: underline; text-underline-offset: 3px; }
