:root {
  --paper: #ffffff;
  --ink: #18171f;
  --muted: #65636d;
  --brand: #4f46e5;
  --signal: #ff3d86;
  --soft: #f3f3f6;
  --line: #18171f;
  --type: "Bricolage Grotesque", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --shell: 1240px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  overflow-x: clip;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--type);
  font-optical-sizing: auto;
}

body::selection {
  background: var(--brand);
  color: var(--paper);
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 3px solid var(--signal);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 100;
  padding: 10px 14px;
  border: 2px solid var(--line);
  background: var(--paper);
  font-weight: 800;
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 22px;
  min-height: 72px;
  padding: 12px max(20px, calc((100% - var(--shell)) / 2));
  border-bottom: 2px solid var(--line);
  background: rgba(255, 255, 255, 0.97);
}

.brand {
  display: inline-flex;
  width: fit-content;
  min-height: 46px;
  align-items: center;
  gap: 10px;
  font-weight: 900;
}

.brand-symbol {
  display: block;
  width: 46px;
  height: auto;
  flex: 0 0 46px;
}

.brand-wordmark {
  white-space: nowrap;
  font-size: 1.16rem;
  font-weight: 900;
  line-height: 1;
}

.brand-primary {
  color: var(--brand);
}

.brand-accent {
  color: var(--signal);
}

.nav-links,
.footer-links,
.footer-legal {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}

.nav-links {
  justify-content: center;
  gap: 4px;
}

.nav-links a {
  padding: 9px 11px;
  border: 1px solid transparent;
  font-size: 0.78rem;
}

.nav-links a:hover,
.footer-links a:hover,
.footer-legal a:hover {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

.header-cta,
.home-cta,
.form-button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 2px solid var(--line);
  background: var(--signal);
  color: var(--ink);
  font-weight: 900;
  box-shadow: 4px 4px 0 var(--line);
  cursor: pointer;
}

.header-cta {
  justify-self: end;
  padding: 0 16px;
  font-size: 0.78rem;
}

.legal-hero {
  border-bottom: 2px solid var(--line);
  background: var(--brand);
  color: var(--paper);
}

.legal-hero-inner,
.legal-layout,
.footer-shell {
  width: min(var(--shell), calc(100% - 40px));
  margin: 0 auto;
}

.legal-hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 40px;
  align-items: end;
  padding: 70px 0 64px;
}

.breadcrumb {
  display: flex;
  gap: 8px;
  margin: 0 0 24px;
  font-size: 0.78rem;
  font-weight: 750;
}

.breadcrumb a {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.legal-hero h1 {
  max-width: 880px;
  margin: 0;
  font-size: clamp(3rem, 7vw, 6rem);
  font-weight: 800;
  line-height: 0.93;
  letter-spacing: 0;
  text-wrap: balance;
}

.draft-badge {
  width: fit-content;
  max-width: 250px;
  padding: 14px 16px;
  border: 2px solid var(--paper);
  background: var(--signal);
  color: var(--ink);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
  box-shadow: 5px 5px 0 var(--ink);
}

.legal-layout {
  display: grid;
  grid-template-columns: 250px minmax(0, 760px);
  gap: clamp(46px, 8vw, 110px);
  justify-content: start;
  padding: 64px 0 90px;
}

.legal-toc {
  align-self: start;
  border: 2px solid var(--line);
  background: var(--soft);
}

.legal-toc strong {
  display: block;
  padding: 14px 16px;
  border-bottom: 2px solid var(--line);
  background: var(--ink);
  color: var(--paper);
  font-size: 0.76rem;
  text-transform: uppercase;
}

.legal-toc ol {
  margin: 0;
  padding: 8px 0;
  list-style: none;
}

.legal-toc a {
  display: block;
  padding: 8px 16px;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.3;
}

.legal-toc a:hover {
  background: var(--paper);
  color: var(--ink);
}

.legal-content {
  min-width: 0;
}

.status-note,
.prototype-note {
  margin: 0 0 38px;
  padding: 20px;
  border: 2px solid var(--line);
  background: #fff2f7;
  box-shadow: 6px 6px 0 var(--signal);
  line-height: 1.55;
}

.status-note strong,
.prototype-note strong {
  display: block;
  margin-bottom: 6px;
}

.legal-content section {
  padding: 0 0 40px;
  scroll-margin-top: 96px;
}

.legal-content h2 {
  margin: 0 0 16px;
  font-size: clamp(1.75rem, 4vw, 2.65rem);
  line-height: 1;
  letter-spacing: 0;
  text-wrap: balance;
}

.legal-content h3 {
  margin: 26px 0 10px;
  font-size: 1.15rem;
}

.legal-content p,
.legal-content li {
  color: #3f3d46;
  font-size: 1.02rem;
  line-height: 1.7;
}

.legal-content p {
  margin: 0 0 16px;
}

.legal-content ul,
.legal-content ol {
  margin: 0 0 18px;
  padding-left: 22px;
}

.legal-content li + li {
  margin-top: 8px;
}

.decision-list {
  padding: 0;
  list-style: none;
}

.decision-list li {
  margin-top: 0;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  background: var(--soft);
}

.decision-list li:first-child {
  border-top: 1px solid var(--line);
}

.home-panel {
  padding: 32px;
  border: 2px solid var(--line);
  background: var(--ink);
  color: var(--paper);
  box-shadow: 8px 8px 0 var(--brand);
}

.home-panel h2,
.home-panel p {
  color: var(--paper);
}

.home-panel p {
  max-width: 560px;
  color: rgba(255, 255, 255, 0.76);
}

.home-cta {
  margin-top: 8px;
  padding: 0 18px;
}

.request-form {
  display: grid;
  gap: 18px;
  margin-top: 24px;
  padding: 26px;
  border: 2px solid var(--line);
  background: var(--soft);
}

.field {
  display: grid;
  gap: 7px;
}

.field label,
.field legend {
  font-size: 0.82rem;
  font-weight: 850;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 48px;
  padding: 11px 12px;
  border: 2px solid var(--line);
  border-radius: 0;
  background: var(--paper);
  color: var(--ink);
}

.field textarea {
  min-height: 120px;
  resize: vertical;
}

.form-button {
  width: fit-content;
  padding: 0 20px;
}

.form-status {
  min-height: 1.5em;
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.form-status.is-visible {
  padding: 12px;
  border-left: 5px solid var(--signal);
  background: var(--paper);
  color: var(--ink);
}

.site-footer {
  border-top: 2px solid var(--line);
  background: var(--ink);
  color: var(--paper);
}

.footer-shell {
  display: grid;
  grid-template-columns: minmax(190px, 0.7fr) minmax(0, 1.3fr);
  gap: 42px;
  padding: 46px 0 34px;
}

.footer-brand .brand {
  color: var(--paper);
}

.footer-brand .brand-primary {
  color: var(--paper);
}

.footer-brand p {
  max-width: 320px;
  margin: 22px 0 0;
  color: rgba(255, 255, 255, 0.68);
  line-height: 1.5;
}

.footer-nav {
  display: grid;
  gap: 22px;
}

.footer-nav strong {
  display: block;
  margin-bottom: 10px;
  color: rgba(255, 255, 255, 0.52);
  font-size: 0.7rem;
  text-transform: uppercase;
}

.footer-links,
.footer-legal {
  gap: 10px 20px;
}

.footer-links a,
.footer-legal a {
  font-size: 0.82rem;
}

.footer-bottom {
  grid-column: 1 / -1;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.25);
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.74rem;
}

@media (max-width: 900px) {
  .site-header {
    grid-template-columns: 1fr auto;
  }

  .nav-links {
    display: none;
  }

  .legal-layout {
    grid-template-columns: 1fr;
    gap: 34px;
  }

  .legal-toc {
    width: min(100%, 520px);
  }
}

@media (max-width: 700px) {
  .site-header {
    min-height: 62px;
    padding: 9px 14px;
  }

  .brand {
    min-height: 39px;
    gap: 8px;
  }

  .brand-symbol {
    width: 39px;
    flex-basis: 39px;
  }

  .brand-wordmark {
    font-size: 0.96rem;
  }

  .header-cta {
    width: 44px;
    min-height: 42px;
    overflow: hidden;
    padding: 0;
    font-size: 0;
  }

  .header-cta span {
    font-size: 1rem;
  }

  .legal-hero-inner,
  .legal-layout,
  .footer-shell {
    width: min(var(--shell), calc(100% - 32px));
  }

  .legal-hero-inner {
    grid-template-columns: 1fr;
    gap: 28px;
    padding: 50px 0 46px;
  }

  .legal-layout {
    padding: 42px 0 68px;
  }

  .legal-toc {
    width: 100%;
  }

  .legal-content p,
  .legal-content li {
    font-size: 0.98rem;
  }

  .home-panel,
  .request-form {
    padding: 20px;
  }

  .footer-shell {
    grid-template-columns: 1fr;
  }

  .footer-bottom {
    grid-column: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
