.legal-page {
  min-height: 100vh;
  background: var(--paper);
}

.legal-hero {
  position: relative;
  overflow: hidden;
  padding: 148px 0 64px;
  color: var(--white);
  background: var(--ink);
  isolation: isolate;
}

.legal-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background: linear-gradient(115deg, #070c11, #10212a 62%, #0b1118);
}

.legal-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0.18;
  background-image: linear-gradient(rgba(126, 222, 231, 0.16) 1px, transparent 1px), linear-gradient(90deg, rgba(126, 222, 231, 0.12) 1px, transparent 1px);
  background-size: 72px 72px;
  -webkit-mask-image: linear-gradient(to right, black, transparent 86%);
  mask-image: linear-gradient(to right, black, transparent 86%);
}

.legal-hero__inner {
  position: relative;
}

.legal-hero .section-heading {
  max-width: 800px;
}

.legal-hero .eyebrow {
  color: var(--signal);
  font-size: 0.73rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.legal-hero h1 {
  max-width: 16ch;
  margin: 0.7rem 0 1rem;
  font-size: clamp(2.8rem, 6vw, 5.8rem);
  line-height: 0.98;
}

.legal-hero .section-heading > p:last-child {
  max-width: 64ch;
  color: rgba(255, 255, 255, 0.72);
  font-size: clamp(1rem, 1.5vw, 1.15rem);
}

.legal-content {
  display: grid;
  gap: 1rem;
  padding-block: clamp(2.5rem, 6vw, 5rem);
}

.legal-block {
  min-width: 0;
  padding: clamp(1.25rem, 3vw, 2rem);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 12px 32px rgba(8, 20, 29, 0.055);
}

.legal-block h2 {
  margin: 0 0 0.9rem;
  font-size: clamp(1.35rem, 2.5vw, 2rem);
  line-height: 1.15;
}

.legal-block p,
.legal-block li {
  color: var(--muted);
  line-height: 1.75;
  overflow-wrap: anywhere;
}

.legal-block p + p,
.legal-block ul + p,
.legal-block p + ul,
.legal-block .legal-table-wrap + p {
  margin-top: 0.85rem;
}

.legal-block ul {
  display: grid;
  gap: 0.45rem;
  padding-left: 1.2rem;
  list-style: square;
}

.legal-block li::marker {
  color: var(--signal-deep);
}

.legal-block a:not(.button) {
  color: #006f79;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

.legal-meta {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  border-top: 4px solid var(--signal-deep);
}

.legal-meta p {
  display: grid;
  gap: 0.2rem;
  line-height: 1.45;
}

.legal-meta strong {
  color: var(--text);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.legal-placeholder {
  border-color: #91a7af;
  border-left: 4px solid var(--signal-deep);
  background: #fafdfe;
}

.legal-placeholder h2::after {
  content: "Te controleren";
  display: inline-flex;
  margin-left: 0.65rem;
  padding: 0.3rem 0.45rem;
  vertical-align: middle;
  border: 1px solid #8aa5ad;
  border-radius: 3px;
  color: #486069;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.legal-note {
  padding: 0.85rem 1rem;
  border-left: 3px solid var(--signal-deep);
  background: var(--mist);
}

.legal-table-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
}

.legal-table {
  width: 100%;
  min-width: 940px;
  border-spacing: 0;
  border-collapse: separate;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--white);
}

.legal-table caption {
  padding: 0 0 0.8rem;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 600;
  text-align: left;
}

.legal-table th,
.legal-table td {
  min-width: 145px;
  padding: 0.9rem;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  vertical-align: top;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.55;
  text-align: left;
  overflow-wrap: anywhere;
}

.legal-table th {
  color: var(--text);
  background: #edf3f5;
  font-weight: 800;
}

.legal-table tr > :last-child {
  border-right: 0;
}

.legal-table tbody tr:last-child > * {
  border-bottom: 0;
}

.legal-content > p:last-child {
  margin-top: 1rem;
}

.legal-content > p:last-child .btn {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.74rem 1.08rem;
  border: 1px solid var(--signal);
  border-radius: 4px;
  color: var(--ink);
  background: var(--signal);
  font-weight: 700;
  text-decoration: none;
}

.legal-content > p:last-child .btn:hover {
  background: #50e8f0;
}

.legal-redirect-page {
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 2rem;
  color: var(--white);
  background: var(--ink);
}

.legal-redirect-brand {
  position: fixed;
  top: 1.5rem;
  left: 50%;
  z-index: 1;
  width: min(calc(100% - 3rem), 1280px);
  transform: translateX(-50%);
}

.legal-redirect {
  width: min(100%, 680px);
  padding: clamp(1.5rem, 5vw, 3.5rem);
  border: 1px solid #34424c;
  border-top: 4px solid var(--signal);
  border-radius: var(--radius);
  background: var(--ink-soft);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.3);
}

.legal-redirect .brand {
  margin-bottom: clamp(2.5rem, 7vw, 5rem);
}

.legal-redirect .kicker {
  margin-bottom: 0.65rem;
}

.legal-redirect h1 {
  max-width: 12ch;
  font-size: clamp(2rem, 7vw, 4.2rem);
  line-height: 1;
}

.legal-redirect > p:not(.kicker) {
  max-width: 48ch;
  margin-top: 1rem;
  color: #b7c2c9;
}

.legal-redirect .button {
  margin-top: 2rem;
}

@media (max-width: 700px) {
  .legal-hero {
    padding: 116px 0 46px;
  }

  .legal-hero h1 {
    max-width: 100%;
    font-size: clamp(2.35rem, 12vw, 4rem);
    overflow-wrap: anywhere;
  }

  .legal-content {
    gap: 0.75rem;
  }

  .legal-block {
    padding: 1.15rem;
  }

  .legal-meta {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .legal-meta p + p {
    margin-top: 0;
    padding-top: 0.75rem;
    border-top: 1px solid var(--line);
  }

  .legal-placeholder h2::after {
    display: flex;
    width: max-content;
    margin: 0.55rem 0 0;
  }

  .legal-table {
    min-width: 880px;
  }

  .legal-content > p:last-child .btn {
    width: 100%;
  }
}

@media print {
  @page {
    size: A4;
    margin: 15mm;
  }

  html,
  body,
  .legal-page {
    color: #000 !important;
    background: #fff !important;
  }

  .skip-link,
  .preview-header,
  .preview-footer,
  .legal-redirect-brand,
  .cookie-consent,
  .cookie-modal,
  .cookie-preferences-slot,
  .legal-content > p:last-child {
    display: none !important;
  }

  .shell {
    width: 100% !important;
    max-width: none !important;
  }

  .legal-hero {
    padding: 0 0 10mm;
    color: #000 !important;
    background: #fff !important;
  }

  .legal-hero::before,
  .legal-hero::after {
    display: none;
  }

  .legal-hero .eyebrow,
  .legal-hero .section-heading > p:last-child {
    color: #000 !important;
  }

  .legal-hero h1 {
    font-size: 25pt;
  }

  .legal-content {
    display: block;
    padding: 0;
  }

  .legal-block {
    margin: 0 0 5mm;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: #fff !important;
    box-shadow: none;
  }

  .legal-block h2 {
    margin: 0 0 2mm;
    font-size: 15pt;
  }

  .legal-block p,
  .legal-block li {
    color: #000 !important;
    font-size: 9.5pt;
    line-height: 1.45;
  }

  .legal-placeholder h2::after {
    color: #000;
    border-color: #000;
  }

  .legal-table-wrap {
    overflow: visible;
  }

  .legal-table {
    min-width: 0;
    font-size: 7pt;
  }

  .legal-table th,
  .legal-table td {
    min-width: 0;
    padding: 1.5mm;
    color: #000 !important;
    background: #fff !important;
    font-size: 7pt;
    line-height: 1.25;
  }

  a {
    color: #000 !important;
    text-decoration: underline;
  }
}
