:root {
  --night: #241820;
  --night-2: #342430;
  --rose: #c73e66;
  --rose-deep: #7c1a3d;
  --blush: #f6efe9;
  --card: #fffaf7;
  --ink: #241820;
  --muted: #5c4e55;
  --line: #ead9df;
  --focus: #1d4e89;
  --sans: "Segoe UI", Candara, "Trebuchet MS", sans-serif;
  --mono: Consolas, "Cascadia Mono", "Courier New", monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--blush);
  font-family: var(--sans);
  font-size: 1.05rem;
  line-height: 1.65;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--rose-deep);
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  background: var(--night);
  color: #fffaf7;
  padding: 0.65rem 0.9rem;
  z-index: 30;
}

.skip:focus {
  top: 0.75rem;
}

.shell {
  min-height: 100vh;
}

.rail {
  background: var(--night);
  color: #fffaf7;
  border-bottom: 6px solid var(--rose);
}

.rail-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1.1rem;
}

.brand {
  color: #fffaf7;
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.brand small {
  display: block;
  font-weight: 400;
  color: #e7c3cf;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
}

.menu-btn {
  min-height: 48px;
  min-width: 48px;
  border: 1px solid #6a4a58;
  background: transparent;
  color: #fffaf7;
  font: inherit;
  padding: 0.4rem 0.85rem;
  cursor: pointer;
}

.rail-nav {
  display: none;
  flex-direction: column;
  padding: 0 1.1rem 1.1rem;
  gap: 0.25rem;
}

.rail-nav.is-open {
  display: flex;
}

.rail-nav a {
  color: #fffaf7;
  text-decoration: none;
  padding: 0.7rem 0.75rem;
  min-height: 48px;
  display: flex;
  align-items: center;
  border-left: 3px solid transparent;
}

.rail-nav a.is-here {
  border-left-color: var(--rose);
  background: var(--night-2);
}

.rail-cta {
  margin-top: 0.4rem;
  background: var(--rose-deep);
  border-left-color: transparent;
  justify-content: center;
}

.rail-meta {
  margin: 0.8rem 0 0;
  color: #e7c3cf;
  font-family: var(--mono);
  font-size: 0.75rem;
  padding: 0 0.75rem;
}

.stage {
  padding: 1.25rem 1rem 3rem;
}

.hero,
.sheet,
.warn,
.site-foot {
  background: var(--card);
  border: 1px solid var(--line);
}

.hero {
  padding: 1.4rem 1.15rem 1.3rem;
  border-top: 8px solid var(--night);
}

.kicker {
  margin: 0 0 0.7rem;
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: var(--rose-deep);
}

h1,
h2,
h3 {
  line-height: 1.2;
  font-weight: 600;
}

h1 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 5vw, 3.15rem);
  max-width: 16ch;
}

h2 {
  margin: 0 0 0.9rem;
  font-size: clamp(1.45rem, 2.4vw, 1.9rem);
}

h3 {
  margin: 1.4rem 0 0.45rem;
  font-size: 1.12rem;
}

p {
  margin: 0 0 0.9rem;
}

.cut {
  margin: 0.2rem 0 1rem;
  font-weight: 700;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  min-height: 48px;
  margin: 1rem 0 1.1rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.7rem 1.1rem;
  background: var(--rose-deep);
  color: #fffaf7;
  text-decoration: none;
  font-weight: 600;
}

.btn-line {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--night);
}

.facts {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.7rem;
  margin: 0;
}

.facts div {
  border-top: 1px solid var(--line);
  padding-top: 0.65rem;
}

.facts dt {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--muted);
}

.facts dd {
  margin: 0.15rem 0 0;
  font-weight: 600;
}

.sheet,
.warn {
  margin-top: 1rem;
  padding: 1.25rem 1.15rem 1.35rem;
}

.sheet-tag {
  margin: 0 0 0.55rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--muted);
}

.steps,
.ticks {
  margin: 0 0 1rem;
  padding-left: 1.2rem;
}

.steps li,
.ticks li {
  margin: 0.4rem 0;
}

.flow {
  margin: 1rem 0 0.4rem;
}

.flow img {
  width: 100%;
  height: auto;
  background: var(--card);
  border: 1px solid var(--line);
}

.flow figcaption {
  margin-top: 0.45rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.warn {
  background: #2a1c24;
  color: #fffaf7;
  border-color: #2a1c24;
}

.warn h2,
.warn .cut {
  color: #fffaf7;
}

.warn .sheet-tag {
  color: #f0c3d0;
}

.warn a {
  color: #ffd0de;
}

.site-foot {
  margin-top: 1rem;
  background: var(--night);
  color: #fffaf7;
  border-color: var(--night);
  padding: 1.3rem 1.15rem 1.1rem;
}

.foot-grid {
  display: grid;
  gap: 1.2rem;
}

.foot-label {
  margin: 0 0 0.35rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  color: #e7c3cf;
}

.site-foot a {
  display: block;
  color: #fffaf7;
  margin: 0.25rem 0;
}

.site-foot p {
  margin: 0 0 0.45rem;
}

.foot-end {
  margin-top: 1rem;
  padding-top: 0.8rem;
  border-top: 1px solid #4a3340;
  color: #e7c3cf;
  font-size: 0.92rem;
}

@media (min-width: 720px) {
  .stage {
    padding: 1.6rem 1.5rem 3.2rem;
  }

  .hero,
  .sheet,
  .warn,
  .site-foot {
    padding: 1.6rem 1.5rem;
  }

  .facts {
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
  }

  .facts div {
    border-top: 0;
    border-left: 3px solid var(--rose);
    padding: 0.2rem 0 0.2rem 0.8rem;
  }

  .foot-grid {
    grid-template-columns: 1.4fr 1fr 1fr;
  }
}

@media (min-width: 980px) {
  .shell {
    display: grid;
    grid-template-columns: 16.5rem 1fr;
    align-items: start;
  }

  .rail {
    position: sticky;
    top: 0;
    height: 100vh;
    border-bottom: 0;
    border-right: 6px solid var(--rose);
    display: flex;
    flex-direction: column;
  }

  .rail-head {
    display: block;
    padding: 1.4rem 1.2rem 0.4rem;
  }

  .menu-btn {
    display: none;
  }

  .rail-nav {
    display: flex;
    padding: 0.6rem 0.9rem 1rem;
  }

  .stage {
    padding: 2rem 2rem 4rem;
    max-width: 58rem;
  }

  section {
    scroll-margin-top: 1.25rem;
  }
}

@media (max-width: 979px) {
  section {
    scroll-margin-top: 5.5rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
