:root {
  --ink: #16212a;
  --muted: #5d6972;
  --paper: #f5f2ec;
  --chalk: #fbfaf7;
  --concrete: #d8d5ce;
  --line: #b8c0c5;
  --blue: #0f5f88;
  --blue-deep: #08384f;
  --steel: #687883;
  --focus: #ffbf47;
  --max: 1180px;
}

* { box-sizing: border-box; }

html {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(22, 33, 42, .055) 1px, transparent 1px) 0 0 / 64px 64px,
    linear-gradient(0deg, rgba(22, 33, 42, .045) 1px, transparent 1px) 0 0 / 64px 64px,
    var(--paper);
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
p { margin: 0 0 1rem; color: var(--muted); }

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

.skip-link {
  position: absolute;
  left: 1rem;
  top: .75rem;
  z-index: 20;
  padding: .6rem .8rem;
  background: var(--ink);
  color: #fff;
  transform: translateY(-160%);
}

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

.shell {
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
  min-height: 100vh;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  align-self: start;
  min-height: 100vh;
  padding: 1.25rem;
  background: rgba(245, 242, 236, .94);
  border-right: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.brand {
  display: grid;
  gap: .65rem;
  text-decoration: none;
  margin-bottom: 1.5rem;
}

.brand-mark {
  width: 54px;
  height: 54px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5px;
}

.brand-mark span {
  background: var(--blue);
  border: 1px solid var(--blue-deep);
}

.brand-mark span:nth-child(2),
.brand-mark span:nth-child(3) { background: var(--concrete); }

.brand-name {
  font-size: 1.25rem;
  font-weight: 760;
  letter-spacing: 0;
}

.brand-tag {
  font-size: .86rem;
  color: var(--muted);
}

.nav-toggle { display: none; }

.primary-nav {
  display: grid;
  gap: .2rem;
}

.primary-nav a {
  display: flex;
  align-items: center;
  min-height: 2.35rem;
  padding: .45rem .55rem;
  text-decoration: none;
  border-left: 3px solid transparent;
  color: var(--muted);
}

.primary-nav a[aria-current="page"],
.primary-nav a:hover {
  color: var(--ink);
  background: rgba(15, 95, 136, .08);
  border-color: var(--blue);
}

.rail-note {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  font-size: .86rem;
  color: var(--muted);
}

main { min-width: 0; }

.page {
  width: min(var(--max), calc(100% - 2rem));
  margin: 0 auto;
  padding: 3rem 0;
}

.hero {
  min-height: 88vh;
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(320px, .98fr);
  gap: 2rem;
  align-items: end;
  padding-top: 1.5rem;
}

.eyebrow {
  margin: 0 0 .75rem;
  color: var(--blue-deep);
  font-size: .82rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-weight: 760;
}

h1, h2, h3 {
  margin: 0;
  line-height: 1.05;
  letter-spacing: 0;
}

h1 {
  font-size: clamp(2.6rem, 7vw, 5.8rem);
  max-width: 9ch;
}

.hero-copy {
  font-size: clamp(1.05rem, 2vw, 1.32rem);
  max-width: 42rem;
  color: #34414a;
}

.hero-media {
  align-self: stretch;
  min-height: 520px;
  position: relative;
  overflow: hidden;
  border-left: 10px solid var(--blue);
}

.hero-media img,
.feature-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.caption {
  font-size: .78rem;
  color: var(--muted);
  margin-top: .55rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  margin-top: 1.35rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.8rem;
  padding: .72rem 1rem;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: #fff;
  text-decoration: none;
  font-weight: 720;
}

.button.secondary {
  background: transparent;
  color: var(--ink);
}

.grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1rem;
}

.band {
  padding: 3rem 0;
  border-top: 1px solid var(--line);
}

.intro {
  grid-column: span 5;
}

.intro h2,
.content h2 {
  font-size: clamp(1.8rem, 3.4vw, 3rem);
  margin-bottom: 1rem;
}

.modules {
  grid-column: span 7;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.module,
.notice,
.form-panel,
.diagnostic-panel {
  background: rgba(251, 250, 247, .9);
  padding: 1.1rem;
}

.module h3 {
  font-size: 1.05rem;
  margin-bottom: .45rem;
}

.module p,
.legal-list li,
.checklist li { font-size: .95rem; }

.page-head {
  padding: 3rem 0 2rem;
  border-bottom: 1px solid var(--line);
}

.page-head h1 {
  max-width: 12ch;
  font-size: clamp(2.4rem, 5.6vw, 4.8rem);
}

.two-col {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(320px, 1.1fr);
  gap: 2rem;
  align-items: start;
}

.feature-media {
  min-height: 360px;
  overflow: hidden;
  border-top: 8px solid var(--blue);
}

.content {
  display: grid;
  gap: 1.5rem;
}

.steps {
  counter-reset: step;
  display: grid;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.step {
  counter-increment: step;
  display: grid;
  grid-template-columns: 4rem 1fr;
  gap: 1rem;
  padding: 1rem;
  background: var(--chalk);
}

.step::before {
  content: counter(step, decimal-leading-zero);
  color: var(--blue);
  font-weight: 800;
}

form {
  display: grid;
  gap: 1rem;
}

label {
  display: grid;
  gap: .35rem;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--steel);
  border-radius: 0;
  background: #fff;
  color: var(--ink);
  font: inherit;
  padding: .72rem .75rem;
}

textarea { min-height: 9rem; resize: vertical; }

.check {
  display: flex;
  align-items: flex-start;
  gap: .6rem;
  font-weight: 500;
}

.check input { width: auto; margin-top: .25rem; }

.status {
  min-height: 1.5rem;
  color: var(--blue-deep);
  font-weight: 700;
}

.diagnostic-grid {
  display: grid;
  grid-template-columns: minmax(0, .95fr) minmax(320px, 1.05fr);
  gap: 1rem;
}

.result {
  white-space: pre-line;
  background: var(--chalk);
  border: 1px solid var(--line);
  padding: 1rem;
  min-height: 13rem;
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2rem 0;
  background: rgba(22, 33, 42, .04);
}

.footer-inner {
  width: min(var(--max), calc(100% - 2rem));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr .8fr .8fr;
  gap: 1rem;
}

.footer-inner a { color: var(--blue-deep); }

.cookie-banner {
  position: fixed;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 30;
  display: none;
  max-width: 760px;
  padding: 1rem;
  background: var(--ink);
  color: #fff;
  box-shadow: 0 14px 44px rgba(0, 0, 0, .24);
}

.cookie-banner p { color: #e7eef2; }
.cookie-banner.is-visible { display: block; }
.cookie-actions { display: flex; flex-wrap: wrap; gap: .65rem; }
.cookie-actions button,
form button {
  min-height: 2.65rem;
  border: 1px solid currentColor;
  padding: .65rem .9rem;
  background: var(--blue);
  color: #fff;
  font: inherit;
  font-weight: 760;
  cursor: pointer;
}
.cookie-actions button.secondary { background: transparent; }

.legal-list,
.checklist {
  display: grid;
  gap: .75rem;
  padding-left: 1.1rem;
  color: var(--muted);
}

@media (max-width: 900px) {
  .shell { display: block; }
  .site-header {
    min-height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .nav-toggle {
    display: inline-flex;
    min-height: 2.5rem;
    padding: .5rem .75rem;
    border: 1px solid var(--ink);
    background: transparent;
    font: inherit;
    font-weight: 760;
  }
  .primary-nav { display: none; margin-top: 1rem; }
  .primary-nav.is-open { display: grid; }
  .rail-note { display: none; }
  .hero,
  .two-col,
  .diagnostic-grid,
  .footer-inner { grid-template-columns: 1fr; }
  .hero { min-height: auto; }
  .hero-media { min-height: 320px; }
  .intro,
  .modules { grid-column: 1 / -1; }
}

@media (max-width: 620px) {
  .page { padding: 1.5rem 0; }
  .modules { grid-template-columns: 1fr; }
  .step { grid-template-columns: 1fr; }
  h1 { font-size: clamp(2.25rem, 16vw, 3.6rem); }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: .001ms !important;
    scroll-behavior: auto !important;
    transition-duration: .001ms !important;
  }
}
