:root {
  color-scheme: dark;
  --ink: #e8f0f5;
  --muted: #91a6b5;
  --paper: #102332;
  --paper-deep: #091822;
  --rule: #294758;
  --signal: #efc56a;
  --signal-soft: #8c7138;
  --focus: #8bd5ff;
  --measure: 74rem;
  font-family: "Cascadia Code", "Source Code Pro", "DejaVu Sans Mono", "Liberation Mono", monospace;
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 18rem;
  background: var(--paper-deep);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, transparent 0 2.95rem, rgb(239 197 106 / 10%) 2.95rem 3rem, transparent 3rem),
    var(--paper-deep);
  font-size: 1rem;
  line-height: 1.65;
}

a {
  color: inherit;
  text-decoration-color: var(--signal-soft);
  text-underline-offset: 0.22em;
  text-decoration-thickness: 0.08em;
}

a:hover {
  color: var(--signal);
  text-decoration-color: currentColor;
}

a:focus-visible {
  outline: 0.14rem solid var(--focus);
  outline-offset: 0.24rem;
  border-radius: 0.1rem;
}

.manual {
  width: min(calc(100% - 2rem), var(--measure));
  min-height: 100vh;
  margin: 0 auto;
  padding: 1.25rem clamp(0rem, 2vw, 1.5rem) 2rem;
  background: var(--paper);
  border-inline: 1px solid var(--rule);
  box-shadow: 0 0 4rem rgb(0 0 0 / 28%);
}

.manual-head,
.manual-foot {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1rem;
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.035em;
}

.manual-head {
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--rule);
}

.manual-head > :last-child,
.manual-foot > :last-child {
  text-align: right;
}

.manual-head a,
.manual-foot a {
  text-decoration: none;
}

.prompt {
  margin: clamp(3.5rem, 10vw, 7rem) 0 clamp(3rem, 7vw, 5rem);
  padding-left: clamp(0rem, 12vw, 8.5rem);
  color: var(--muted);
  font-size: clamp(0.78rem, 1.3vw, 0.95rem);
  white-space: nowrap;
  overflow: hidden;
}

.prompt-user {
  color: var(--signal);
}

.prompt-path {
  color: var(--focus);
}

article section {
  display: grid;
  grid-template-columns: minmax(7rem, 9rem) minmax(0, 1fr);
  column-gap: clamp(1.5rem, 4vw, 4rem);
  margin: 0 0 clamp(2.75rem, 6vw, 4.5rem);
}

h1,
h2 {
  margin: 0;
  color: var(--signal);
  font-size: 0.79rem;
  font-weight: 700;
  line-height: 1.65;
  letter-spacing: 0.08em;
}

.section-body {
  min-width: 0;
  max-width: 60rem;
}

.hero-copy p {
  max-width: 39rem;
  margin: -0.2rem 0 0;
  font-size: clamp(1.65rem, 5vw, 3.5rem);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.045em;
}

.hero-copy strong {
  color: var(--signal);
  font-weight: 700;
}

.prose {
  max-width: 47rem;
}

.prose p,
.see-also {
  margin: 0 0 1.1rem;
}

.prose p:last-child {
  margin-bottom: 0;
}

.synopsis {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 2rem;
}

.synopsis code {
  color: var(--ink);
  font: inherit;
  overflow-wrap: anywhere;
}

.state {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  color: var(--muted);
  font-size: 0.82rem;
}

.state-dot {
  width: 0.55rem;
  height: 0.55rem;
  background: var(--signal);
  border-radius: 50%;
  box-shadow: 0 0 0 0.22rem rgb(239 197 106 / 12%);
}

.properties {
  margin: 0;
  border-top: 1px solid var(--rule);
}

.properties div {
  display: grid;
  grid-template-columns: minmax(8rem, 0.7fr) 1fr;
  gap: 1rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--rule);
}

.properties dt {
  color: var(--muted);
}

.properties dd {
  margin: 0;
}

.manual-links {
  margin: 1.5rem 0;
  padding: 0;
  border-top: 1px solid var(--rule);
  list-style: none;
}

.manual-links li {
  border-bottom: 1px solid var(--rule);
}

.manual-links a {
  display: grid;
  grid-template-columns: minmax(9rem, 1fr) 2fr;
  gap: 1rem;
  padding: 0.8rem 0;
  text-decoration: none;
}

.manual-links span {
  color: var(--signal);
}

.manual-links small {
  color: var(--muted);
  font: inherit;
}

.index-link {
  color: var(--signal);
}

.manual-foot {
  margin-top: clamp(4rem, 10vw, 8rem);
  padding-top: 0.75rem;
  border-top: 1px solid var(--rule);
}

.man-page article {
  margin-top: clamp(2.5rem, 7vw, 5rem);
}

.man-page .page-intro {
  display: grid;
  grid-template-columns: minmax(7rem, 9rem) minmax(0, 1fr);
  gap: clamp(1.5rem, 4vw, 4rem);
  margin-bottom: 2rem;
}

.page-intro p {
  margin: 0;
  color: var(--muted);
}

.man-output {
  margin: 0;
  padding: clamp(1rem, 3vw, 2rem);
  color: #dbe8ef;
  background: var(--paper-deep);
  border: 1px solid var(--rule);
  overflow-x: auto;
  font: 0.78rem/1.48 "Cascadia Code", "Source Code Pro", "DejaVu Sans Mono", "Liberation Mono", monospace;
  tab-size: 8;
  white-space: pre;
}

.manual-index {
  margin-top: clamp(3rem, 8vw, 6rem);
}

.manual-index h1 {
  margin-bottom: 2rem;
  font-size: clamp(1.7rem, 5vw, 3.4rem);
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.manual-index > p {
  max-width: 48rem;
  color: var(--muted);
}

.source-note {
  margin: 1rem 0 0;
  color: var(--muted);
  font-size: 0.75rem;
}

@media (max-width: 44rem) {
  body {
    background: var(--paper);
  }

  .manual {
    width: 100%;
    padding-inline: 1rem;
    border: 0;
    box-shadow: none;
  }

  .manual-head,
  .manual-foot {
    grid-template-columns: 1fr auto;
  }

  .manual-head > :last-child,
  .manual-foot > :last-child {
    display: none;
  }

  .prompt {
    padding-left: 0;
  }

  article section,
  .man-page .page-intro {
    grid-template-columns: 1fr;
    gap: 0.65rem;
  }

  h1,
  h2 {
    padding-bottom: 0.35rem;
    border-bottom: 1px solid var(--rule);
  }

  .properties div,
  .manual-links a {
    grid-template-columns: 1fr;
    gap: 0.1rem;
  }

  .man-output {
    margin-inline: -1rem;
    border-inline: 0;
    font-size: 0.7rem;
  }
}

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