/* Tweakit
   Dark purple ground, deep orange accent. Ratios are WCAG 2 contrast.
   --bg            #160A1E
   --text          #F4EFE6   16.73:1 on --bg
   --text-soft     #C8B6D4   10.12:1 on --bg
   --orange        #F07820    6.76:1 on --bg
   --on-orange     #160A1E    6.76:1 on --orange
   --orange-hover  #FF8C42    8.28:1 with --on-orange
   --orange-press  #E8721A    6.25:1 with --on-orange
   --line          #6E5878    3.04:1 on --bg (dividers)
   --hover         #2A1836   14.30:1 with --text, 8.65:1 with --text-soft
   --focus         #F4EFE6   16.73:1 on --bg
*/

:root {
  --bg: #160a1e;
  --text: #f4efe6;
  --text-soft: #c8b6d4;
  --orange: #f07820;
  --on-orange: #160a1e;
  --orange-hover: #ff8c42;
  --orange-press: #e8721a;
  --line: #6e5878;
  --hover: #2a1836;
  --focus: #f4efe6;
  --sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif;
  --mono: ui-monospace, "Cascadia Mono", "Segoe UI Mono", "Liberation Mono", Menlo, Consolas, monospace;
  --measure: 46rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  color: var(--text);
  color-scheme: dark;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  border-top: 4px solid var(--orange);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
}

img {
  max-width: 100%;
  height: auto;
}

p,
h1,
h2,
h3,
li,
dd {
  overflow-wrap: break-word;
}

h1,
h2,
h3 {
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

h1 {
  margin: 0 0 0.8rem;
  font-size: clamp(2rem, 6vw, 2.6rem);
  letter-spacing: -0.03em;
}

h2 {
  margin: 0 0 0.7rem;
  font-size: 1.35rem;
}

h3 {
  margin: 0 0 0.3rem;
  font-size: 1.0625rem;
}

p {
  margin: 0 0 0.85rem;
}

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

a {
  text-underline-offset: 0.18em;
}

p a,
.text-list a,
.todo a,
dd a {
  padding-block: 0.2rem;
}

a:link,
a:visited {
  color: var(--orange);
}

a:focus,
a:focus-visible,
.button:focus-visible,
.brand:focus-visible,
.nav-list a:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

a:focus:not(:focus-visible) {
  outline: none;
}

::selection {
  background: var(--orange);
  color: var(--on-orange);
}

.skip {
  position: absolute;
  left: 0.75rem;
  top: 0.75rem;
  z-index: 10;
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  padding: 0.5rem 0.85rem;
  background: var(--orange);
  color: var(--on-orange);
  font-weight: 700;
  text-decoration: none;
}

a.skip:link,
a.skip:visited {
  color: var(--on-orange);
}

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

.skip:not(:focus):not(:focus-visible) {
  clip-path: inset(50%);
  width: 1px;
  height: 1px;
  min-height: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
  white-space: nowrap;
  border: 0;
}

.wrap {
  width: min(var(--measure), 100%);
  margin-inline: auto;
  padding-inline: 1.25rem;
}

main {
  flex: 1;
}

main:focus,
main:focus-visible {
  outline: none;
}

.site-header {
  padding-block: 0.7rem 0.55rem;
  border-bottom: 1px solid var(--line);
}

.header-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.25rem 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  min-height: 2.75rem;
  color: var(--text);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  text-decoration: none;
}

a.brand:link,
a.brand:visited {
  color: var(--text);
}

.brand__mark {
  width: 2.5rem;
  height: 2.5rem;
  flex: none;
}

.brand:hover .brand__word,
.brand:focus-visible .brand__word {
  text-decoration: underline;
  text-underline-offset: 0.14em;
}

.nav-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-list a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  padding: 0.25rem 0.7rem;
  color: var(--text);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.28em;
}

.nav-list a:link,
.nav-list a:visited {
  color: var(--text);
}

.nav-list a[aria-current="page"] {
  font-weight: 700;
  text-decoration-thickness: 3px;
}

.hero {
  padding-block: 1.8rem 2rem;
}

.hero h1 {
  font-size: clamp(2.6rem, 8vw, 3.9rem);
  line-height: 1.02;
  letter-spacing: -0.035em;
}

.kicker {
  margin: 0 0 0.75rem;
  font-family: var(--mono);
  font-size: 0.875rem;
  line-height: 1.4;
}

.lede {
  font-size: 1.1875rem;
  line-height: 1.5;
}

.page-intro {
  padding-block: 1.6rem 0.4rem;
}

section + section,
.service,
.closer,
.contact-block {
  border-top: 1px solid var(--line);
  padding-block: 1.6rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.25rem;
  margin-top: 1.15rem;
}

.actions a:not(.button) {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: 0.4rem 1rem;
  background: var(--orange);
  border: 2px solid var(--orange);
  color: var(--on-orange);
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
}

a.button:link,
a.button:visited {
  color: var(--on-orange);
  text-decoration: none;
}

.button:hover {
  background: var(--orange-hover);
  border-color: var(--orange-hover);
}

.button:active {
  background: var(--orange-press);
  border-color: var(--orange-press);
}

.index {
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}

.index li + li {
  margin-top: 0;
}

.index a {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.15rem;
  min-height: 2.75rem;
  padding-block: 0.8rem;
  border-bottom: 1px solid var(--line);
  color: var(--text);
  text-decoration: none;
}

.index a:link,
.index a:visited {
  color: var(--text);
}

.index a:hover,
.index a:focus-visible {
  background: var(--hover);
}

.index__name {
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

.index__meta {
  color: var(--text-soft);
}

.steps {
  margin: 0.4rem 0 0;
  padding: 0;
  list-style: none;
}

.steps li {
  display: grid;
  grid-template-columns: 2rem 1fr;
  column-gap: 0.7rem;
  padding-block: 0.85rem;
  border-top: 1px solid var(--line);
}

.steps li + li {
  margin-top: 0;
}

.steps li:last-child {
  border-bottom: 1px solid var(--line);
}

.step-num {
  grid-column: 1;
  grid-row: 1 / span 2;
  padding-top: 0.1rem;
  color: var(--orange);
  font-family: var(--mono);
  font-weight: 700;
}

.steps h3 {
  grid-column: 2;
  grid-row: 1;
  margin: 0;
}

.steps p {
  grid-column: 2;
  grid-row: 2;
  margin: 0;
}

.audiences {
  display: grid;
  margin-top: 0.4rem;
}

.audiences article {
  padding-block: 0.85rem;
  border-top: 1px solid var(--line);
}

.audiences article:last-child {
  border-bottom: 1px solid var(--line);
}

.flag {
  display: block;
  width: fit-content;
  max-width: 100%;
  margin: 0 0 0.75rem;
  padding: 0.05rem 0 0.05rem 0.65rem;
  border-left: 3px solid var(--text);
  color: var(--text);
  font-family: var(--mono);
  font-size: 0.875rem;
  font-weight: 400;
  line-height: 1.45;
}

.todo {
  margin: 0.9rem 0;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--text);
}

.todo p {
  margin: 0;
}

.text-list {
  margin: 0.4rem 0 0;
  padding-left: 1.2rem;
}

.text-list li + li {
  margin-top: 0.35rem;
}

.facts {
  display: grid;
  grid-template-columns: 5.5rem 1fr;
  gap: 0.55rem 1rem;
  margin: 0;
}

.facts dt {
  margin: 0;
  padding-top: 0.15rem;
  font-family: var(--mono);
  font-size: 0.875rem;
}

.facts dd {
  margin: 0;
}

address {
  margin: 0 0 0.35rem;
  font-style: normal;
}

.policy h2,
.contact-block h2 {
  margin-top: 0.3rem;
}

.policy h2 {
  margin-top: 1.7rem;
  padding-top: 1.15rem;
  border-top: 1px solid var(--line);
}

.service h2 {
  margin-bottom: 0.55rem;
}

.site-footer {
  margin-top: auto;
  padding-block: 1.25rem 2rem;
  border-top: 1px solid var(--line);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
  margin: 0.15rem 0 0.55rem;
  padding: 0;
  list-style: none;
}

.footer-links a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
}

.footer-note {
  margin: 0.15rem 0;
  color: var(--text-soft);
  font-size: 0.875rem;
}

section[id],
.service[id] {
  scroll-margin-top: 1rem;
}

@media (max-width: 28rem) {
  .facts {
    grid-template-columns: 1fr;
    gap: 0.1rem;
  }

  .facts dd {
    margin-bottom: 0.55rem;
  }
}

@media (min-width: 48rem) {
  .wrap {
    padding-inline: 1.5rem;
  }

  .index a {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
    align-items: baseline;
    column-gap: 1.5rem;
  }

  .audiences {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.15rem;
    margin-top: 0.8rem;
  }

  .audiences article,
  .audiences article:last-child {
    border-bottom: 0;
    border-top: 2px solid var(--text);
    padding-top: 0.7rem;
  }
}

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

@media (prefers-contrast: more) {
  :root {
    --text-soft: var(--text);
    --line: var(--text);
  }
}

@media (forced-colors: active) {
  .button,
  .flag,
  .todo {
    border: 2px solid ButtonText;
  }

  a:focus-visible,
  .button:focus-visible,
  .skip:focus {
    outline-color: Highlight;
  }
}

@media print {
  body {
    min-height: 0;
    background: #fff;
    color: #111;
    border: 0;
  }

  a:link,
  a:visited,
  .nav-list a,
  .index a,
  .index__meta,
  .footer-note {
    color: #111;
  }

  .button {
    background: #fff;
    border-color: #111;
    color: #111;
  }

  .skip {
    display: none;
  }
}
