/* Legal page styles, layered on css/site.css (tokens, nav, footer).
 * One accent per view: these pages use Dino Teal for links and heading marks.
 * Body prose is the system stack for readability; headings stay Rajdhani.
 */

.legal {
  padding: 4.2rem 0 5rem;
}

.legal article {
  max-width: 780px;
}

.legal h1 {
  margin: 0 0 0.6rem;
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  line-height: 0.95;
  letter-spacing: -0.03em;
  text-transform: uppercase;
}

.legal .last-updated {
  margin: 0 0 2.2rem;
  padding-bottom: 1.4rem;
  border-bottom: 1px solid rgba(167, 139, 250, 0.25);
  color: var(--cream);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  font-size: 0.95rem;
}

.legal h2 {
  margin: 2.6rem 0 0.8rem;
  font-size: 1.55rem;
  letter-spacing: 0.01em;
}

.legal h2::before {
  content: '';
  display: block;
  width: 2.6rem;
  height: 0.28rem;
  margin-bottom: 0.55rem;
  border-radius: 999px;
  background: var(--teal);
}

.legal p,
.legal li {
  color: var(--muted);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  font-size: 0.98rem;
  line-height: 1.7;
}

.legal p strong,
.legal li strong {
  color: var(--white);
}

.legal ul {
  margin: 0.8rem 0 0;
  padding-left: 1.3rem;
}

.legal li {
  margin-bottom: 0.5rem;
}

.legal table {
  width: 100%;
  margin: 1.2rem 0 1.6rem;
  border-collapse: collapse;
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  font-size: 0.9rem;
}

.legal th {
  padding: 0.6rem 0.75rem;
  border: 1px solid rgba(167, 139, 250, 0.28);
  border-bottom: 2px solid rgba(45, 212, 191, 0.5);
  background: rgba(45, 20, 87, 0.65);
  color: var(--white);
  text-align: left;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.legal td {
  padding: 0.65rem 0.75rem;
  border: 1px solid rgba(167, 139, 250, 0.2);
  color: var(--muted);
  vertical-align: top;
  line-height: 1.55;
}

.legal td strong {
  color: var(--white);
}

.legal a {
  color: var(--teal);
}

@media (max-width: 640px) {
  .legal {
    padding: 2.6rem 0 3.4rem;
  }
  .legal table,
  .legal thead,
  .legal tbody,
  .legal tr,
  .legal td,
  .legal th {
    display: block;
  }
  .legal thead {
    /* Collapsed, not display:none, so column headers stay in the accessibility
       tree; sized to max-content so the hidden cells cannot register as
       self-overflow or shredded at narrow widths. */
    position: absolute;
    width: max-content;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }
  .legal tr {
    margin-bottom: 0.9rem;
    border: 1px solid rgba(167, 139, 250, 0.2);
    border-radius: 0.8rem;
    overflow: hidden;
  }
  .legal td {
    border: 0;
    border-bottom: 1px solid rgba(167, 139, 250, 0.14);
  }
  .legal td:last-child {
    border-bottom: 0;
  }
}
