:root {
  --legal-ink: #111a2f;
  --legal-muted: #5c667b;
  --legal-line: #dfe5ef;
  --legal-blue: #1778ff;
  --legal-surface: #f4f7fb;
}

body.legal-page { margin: 0; color: var(--legal-ink); background: var(--legal-surface); }
.legal-header { position: sticky; z-index: 20; top: 0; min-height: 72px; padding: 0 max(20px, calc((100vw - 1040px) / 2)); display: flex; align-items: center; justify-content: space-between; gap: 24px; border-bottom: 1px solid rgba(17,26,47,.08); background: rgba(255,255,255,.9); backdrop-filter: blur(18px); }
.legal-header .brand { color: var(--legal-ink); }
.legal-header__back { min-height: 44px; display: inline-flex; align-items: center; color: var(--legal-blue); font-size: 14px; font-weight: 700; }
.legal-main { width: min(100% - 32px, 1040px); margin: 0 auto; padding: clamp(52px, 8vw, 96px) 0 110px; }
.legal-hero { max-width: 820px; margin-bottom: 42px; }
.legal-kicker { margin: 0 0 14px; color: var(--legal-blue); font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.legal-hero h1 { margin: 0 0 20px; font-size: clamp(38px, 6vw, 70px); line-height: 1; letter-spacing: -.055em; }
.legal-lead { max-width: 760px; margin: 0; color: var(--legal-muted); font-size: clamp(17px, 2vw, 20px); line-height: 1.65; }
.legal-meta { margin: 28px 0 0; padding: 16px 18px; display: flex; flex-wrap: wrap; gap: 8px 22px; border: 1px solid var(--legal-line); border-radius: 16px; background: white; color: var(--legal-muted); font-size: 13px; }
.legal-draft { margin: 0 0 28px; padding: 18px 20px; border: 1px solid #f1d39b; border-radius: 16px; background: #fff8e9; color: #694a0d; line-height: 1.55; }
.legal-document { padding: clamp(24px, 5vw, 54px); border: 1px solid var(--legal-line); border-radius: 28px; background: white; box-shadow: 0 22px 60px rgba(25,42,78,.07); }
.legal-document section + section { margin-top: 38px; padding-top: 38px; border-top: 1px solid var(--legal-line); }
.legal-document h2 { margin: 0 0 16px; font-size: clamp(23px, 3vw, 32px); line-height: 1.15; letter-spacing: -.035em; }
.legal-document h3 { margin: 24px 0 10px; font-size: 18px; }
.legal-document p, .legal-document li { color: #384358; line-height: 1.7; }
.legal-document ul, .legal-document ol { padding-left: 22px; }
.legal-document a { color: var(--legal-blue); text-decoration: underline; text-underline-offset: 3px; }
.legal-details { display: grid; grid-template-columns: minmax(180px, .7fr) 1fr; gap: 0; border: 1px solid var(--legal-line); border-radius: 18px; overflow: hidden; }
.legal-details dt, .legal-details dd { margin: 0; padding: 15px 18px; border-bottom: 1px solid var(--legal-line); }
.legal-details dt { color: var(--legal-muted); background: #f8fafd; }
.legal-details dd { font-weight: 700; overflow-wrap: anywhere; }
.legal-details dt:last-of-type, .legal-details dd:last-of-type { border-bottom: 0; }
.legal-footer { padding: 34px max(20px, calc((100vw - 1040px) / 2)); color: rgba(255,255,255,.65); background: #050914; }
.legal-footer__links { margin-bottom: 14px; display: flex; flex-wrap: wrap; gap: 10px 20px; }
.legal-footer a { color: white; }

.cookie-banner[hidden], .cookie-dialog[hidden] { display: none; }
.cookie-banner { position: fixed; z-index: 1000; right: 20px; bottom: 20px; width: min(520px, calc(100vw - 40px)); padding: 22px; color: white; border: 1px solid rgba(255,255,255,.16); border-radius: 22px; background: rgba(7,11,24,.94); box-shadow: 0 26px 70px rgba(0,0,0,.34); backdrop-filter: blur(20px); }
.cookie-banner h2, .cookie-dialog h2 { margin: 0 0 9px; font-size: 21px; letter-spacing: -.025em; }
.cookie-banner p, .cookie-dialog p { margin: 0; color: rgba(255,255,255,.68); font-size: 13px; line-height: 1.55; }
.cookie-banner a, .cookie-dialog a { color: #65e8ff; }
.cookie-actions { margin-top: 18px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.cookie-button { min-height: 46px; padding: 9px 12px; color: white; border: 1px solid rgba(255,255,255,.24); border-radius: 13px; background: transparent; cursor: pointer; font: inherit; font-size: 12px; font-weight: 700; }
.cookie-button:hover, .cookie-button:focus-visible { border-color: #65e8ff; background: rgba(101,232,255,.1); }
.cookie-button--primary { color: #07101d; border-color: transparent; background: linear-gradient(120deg,#7446ff,#27d6ee); }
.cookie-dialog { position: fixed; z-index: 1002; inset: 0; padding: 20px; display: grid; place-items: center; background: rgba(2,6,16,.72); }
.cookie-dialog__panel { width: min(560px, 100%); padding: 26px; color: white; border: 1px solid rgba(255,255,255,.16); border-radius: 24px; background: #0b1325; box-shadow: 0 28px 80px rgba(0,0,0,.4); }
.cookie-option { margin-top: 18px; padding: 16px; display: grid; grid-template-columns: 1fr auto; gap: 5px 16px; border: 1px solid rgba(255,255,255,.12); border-radius: 16px; }
.cookie-option strong { font-size: 14px; }
.cookie-option small { color: rgba(255,255,255,.58); line-height: 1.45; }
.cookie-option input { width: 22px; height: 22px; accent-color: #27d6ee; }
.cookie-dialog__actions { margin-top: 20px; display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }

@media (max-width: 600px) {
  .legal-header { min-height: 64px; }
  .legal-header .brand span { font-size: 17px; }
  .legal-main { width: min(100% - 24px, 1040px); padding-top: 42px; }
  .legal-document { padding: 24px 19px; border-radius: 22px; }
  .legal-details { grid-template-columns: 1fr; }
  .legal-details dt { padding-bottom: 5px; border-bottom: 0; }
  .legal-details dd { padding-top: 5px; }
  .cookie-banner { right: 12px; bottom: 12px; width: calc(100vw - 24px); padding: 18px; }
  .cookie-actions { grid-template-columns: 1fr; }
  .cookie-dialog { padding: 12px; }
  .cookie-dialog__panel { padding: 22px 18px; }
}
