/*
 * Deine Umzugshelfer (deine-umzugshelfer.de): the instruction sheet of a pattern envelope.
 * Manila tissue ground, drafting black, muted blue-grey. Dressmaker red is used for the one active mark of a page
 * only. Dashed rules, circled part numbers, no shadows.
 */

@font-face {
  font-family: Archivo;
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("../fonts/archivo-latin-variable.woff2") format("woff2");
}

@font-face {
  font-family: "JetBrains Mono";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/jetbrains-mono-latin-variable.woff2") format("woff2");
}

:root {
  --paper: #ece4d0;
  --paper-hi: #f5f0e2;
  --ink: #16130f;
  --ink-soft: #5a5346;
  --blue: #7a8ca6;
  --red: #d33b2c;
  --logo-ink: var(--ink);
  --logo-accent: var(--red);
  --head: archivo, "Helvetica Neue", arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "Cascadia Mono", "Courier New",
    monospace;
  --wrap: 1280px;
  --gutter: clamp(16px, 4vw, 40px);
  --rule: 1.5px dashed var(--ink);
}

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

html {
  scroll-padding-top: 16px;
  color-scheme: light;
  scrollbar-color: var(--ink) var(--paper);
  scrollbar-width: thin;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 1.0625rem/1.6 var(--head);
  caret-color: var(--ink);
  accent-color: var(--ink);
  hyphens: auto;
  overflow-wrap: break-word;
}

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

h1,
h2,
h3,
p,
ul,
ol,
figure,
address {
  margin: 0;
}

a {
  color: inherit;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 0.2em;
}

a:hover {
  text-decoration-thickness: 3px;
}

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

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.skip {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 10;
  padding: 10px 14px;
  background: var(--ink);
  color: var(--paper);
  font-weight: 700;
  transform: translateY(-200%);
}

.skip:focus {
  transform: none;
}

/* Line drawings: one stroke weight, drawn in the sprite */
.ico {
  flex: none;
  fill: none;
  stroke: currentcolor;
  stroke-width: 2px;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sprite symbol * {
  vector-effect: non-scaling-stroke;
}

.ico-lg {
  width: 88px;
  height: 80px;
}

.ico-sm {
  width: 28px;
  height: 28px;
}

/* Top bar */
.bar {
  border-bottom: 2px solid var(--ink);
}

.bar-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 28px;
  padding-block: 12px;
}

.brand {
  display: inline-flex;
  margin-right: auto;
  line-height: 0;
  text-decoration: none;
}

.logo-svg {
  display: block;
  height: 40px;
  width: auto;
  aspect-ratio: 312.85 / 60;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.nav a {
  padding: 7px 12px;
  border: 1.5px solid transparent;
  font-size: 0.9375rem;
  font-weight: 700;
  text-decoration: none;
  transition: background-color 0.15s ease-out;
}

.nav a:hover {
  border-color: var(--ink);
}

.nav a[aria-current="page"] {
  border-color: var(--ink);
  background: var(--paper-hi);
}

/* Headings */
h1 {
  font-size: clamp(1.875rem, 1.1rem + 3.2vw, 3.25rem);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

h2 {
  font-size: 1.375rem;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

h3 {
  font-size: 1.0625rem;
  font-weight: 700;
  line-height: 1.3;
}

.sub {
  max-width: 40em;
  margin-top: 14px;
  font-size: 1.1875rem;
  line-height: 1.45;
  text-wrap: pretty;
}

/* Buttons: outlined, never a booking call to action */
.btn {
  display: inline-block;
  padding: 0.8em 1.25em;
  border: 2px solid var(--ink);
  background: transparent;
  color: var(--ink);
  font-size: 1.0625rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  transition:
    background-color 0.15s ease-out,
    color 0.15s ease-out;
}

.btn:hover {
  background: var(--ink);
  color: var(--paper);
}

/* Home page, first viewport */
.hero {
  display: grid;
  grid-template:
    "main places" auto
    "facts places" 1fr / minmax(0, 1fr) 400px;
  gap: 0 40px;
  padding-top: 32px;
}

.hero-main {
  grid-area: main;
}

.hero > .places {
  grid-area: places;
}

.acts {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 22px;
}

.acts-end {
  margin: 44px 0 0;
}

.parts-wrap {
  margin-top: 28px;
}

.parts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  padding: 0;
  border-block: var(--rule);
  list-style: none;
}

.part {
  border-right: var(--rule);
}

.part:last-child {
  border-right: 0;
}

.part a {
  position: relative;
  display: block;
  min-height: 200px;
  padding: 16px 14px;
  text-decoration: none;
  transition: background-color 0.15s ease-out;
}

.part a:hover {
  background: rgb(255 255 255 / 40%);
}

.part .ico-lg {
  display: block;
  margin: 14px auto 10px;
}

.part b {
  display: block;
  font-size: 1.125rem;
  line-height: 1.2;
}

.part small {
  display: block;
  margin-top: 4px;
  color: var(--ink-soft);
  font: 400 0.8125rem/1.4 var(--mono);
  hyphens: none;
}

/* Circled part numbers */
.n {
  display: inline-grid;
  flex: none;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  font: 700 0.9375rem/1 var(--mono);
  font-variant-numeric: tabular-nums;
}

.part .n {
  position: absolute;
  top: 12px;
  left: 12px;
}

.page-city .n-active {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--paper);
}

.n-active {
  width: 56px;
  height: 56px;
  border-color: var(--red);
  background: var(--red);
  color: #fff;
  font-size: 1.5rem;
}

.hero-facts {
  grid-area: facts;
  padding-top: 16px;
}

.facts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 26px;
  margin: 0;
  padding: 0;
  font: 700 0.875rem/1.4 var(--mono);
  list-style: none;
  hyphens: none;
}

.facts li::before {
  content: "+ ";
}

.grain {
  display: block;
  width: 100%;
  height: 14px;
  margin-top: 22px;
  fill: none;
  stroke: var(--blue);
  stroke-width: 1.5px;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Size chart: tables */
.places h2 {
  margin-bottom: 10px;
  font: 700 0.875rem/1.3 var(--mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.chart-wrap {
  position: relative;
  overflow-x: auto;
}

.places .chart-wrap::before {
  content: "";
  position: absolute;
  top: 0;
  left: 22px;
  width: 12px;
  height: 7px;
  background: var(--ink);
  clip-path: polygon(0 0, 100% 0, 50% 100%);
}

.chart {
  width: 100%;
  border: 2px solid var(--ink);
  border-collapse: collapse;
  background: rgb(255 255 255 / 35%);
  font-variant-numeric: tabular-nums;
}

.chart-note {
  margin-bottom: 8px;
  color: var(--ink-soft);
  font: 400 0.8125rem/1.4 var(--mono);
  hyphens: none;
}

.chart th,
.chart td {
  padding: 9px 12px;
  border: 1.5px solid var(--blue);
  text-align: left;
  vertical-align: top;
}

.chart thead th {
  background: var(--blue);
  color: var(--ink);
  font: 700 0.8125rem/1.3 var(--mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.chart tbody th {
  width: 36%;
  border-right: 2px solid var(--ink);
  font: 700 0.8125rem/1.5 var(--mono);
  hyphens: none;
}

.chart td {
  font-size: 1rem;
}

.chart .is-active th {
  background: var(--red);
  color: #fff;
}

.chart .is-active td {
  font-weight: 800;
}

/* Inner pages */
.page {
  padding-block: 36px 24px;
}

.page-head {
  display: flex;
  align-items: flex-start;
  gap: 24px;
  padding-bottom: 28px;
  border-bottom: var(--rule);
}

.page-head-text {
  flex: 1;
  min-width: 0;
}

.page-ico {
  margin-left: auto;
}

.part-ref {
  margin-top: 12px;
  color: var(--ink-soft);
  font: 400 0.8125rem/1.4 var(--mono);
  hyphens: none;
}

.page-cols {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 48px;
  padding-top: 32px;
}

.page-error .page-head {
  border-bottom: 0;
}

.page-legal .page-cols,
.page-error .page-cols {
  grid-template-columns: minmax(0, 1fr);
}

.prose {
  max-width: 70ch;
}

.prose > * + * {
  margin-top: 1em;
}

.prose p {
  text-wrap: pretty;
}

.prose > h2 {
  margin-top: 2.2em;
  padding-top: 0.9em;
  border-top: var(--rule);
}

.prose > h2:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.prose > h3 {
  margin-top: 1.6em;
}

.home-body {
  padding-block: 40px 24px;
}

.home-body .prose {
  max-width: 76ch;
}

.note {
  padding: 14px 16px;
  border: 2px solid var(--ink);
  background: var(--paper-hi);
}

.items,
.steps,
.checks,
.links,
.downloads {
  padding: 0;
  list-style: none;
}

.items li,
.checks li {
  position: relative;
  padding-left: 26px;
}

.items li + li,
.checks li + li,
.links li + li {
  margin-top: 0.45em;
}

.items li::before {
  content: "";
  position: absolute;
  top: 0.68em;
  left: 4px;
  width: 8px;
  height: 8px;
  background: var(--ink);
}

.items-no li::before {
  top: 0;
  left: 2px;
  width: auto;
  height: auto;
  background: none;
  content: "\00d7";
  font: 700 1.125rem/1.6 var(--mono);
}

.checks li::before {
  content: "";
  position: absolute;
  top: 0.32em;
  left: 0;
  width: 17px;
  height: 17px;
  border: 1.5px solid var(--ink);
  background: var(--paper-hi);
}

.group + .group {
  margin-top: 1.6em;
}

.group h2 {
  margin-bottom: 0.6em;
  padding-top: 0.9em;
  border-top: var(--rule);
}

.steps {
  counter-reset: step;
}

.steps li {
  position: relative;
  min-height: 32px;
  padding-left: 46px;
  counter-increment: step;
}

.steps li + li {
  margin-top: 0.7em;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  top: 0;
  left: 0;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  font: 700 0.9375rem/1 var(--mono);
}

.dos {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-block: var(--rule);
}

.dos section {
  padding: 18px 20px 20px 0;
}

.dos section + section {
  padding: 18px 0 20px 24px;
  border-left: var(--rule);
}

.dos h2 {
  margin-bottom: 0.7em;
  font: 700 0.875rem/1.3 var(--mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.links a {
  display: inline-block;
  padding-block: 2px;
  font-weight: 600;
}

.downloads li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 12px;
  padding-block: 8px;
  border-bottom: var(--rule);
}

.downloads a {
  font-weight: 700;
}

.meta {
  color: var(--ink-soft);
  font: 400 0.8125rem/1.4 var(--mono);
  font-variant-numeric: tabular-nums;
}

.operator {
  padding: 16px 18px;
  border: var(--rule);
  font-style: normal;
}

/* Side column: the parts index and the places */
.side {
  align-self: start;
}

.side h2 {
  margin-bottom: 10px;
  font: 700 0.875rem/1.3 var(--mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.partlist {
  padding: 0;
  border-block: var(--rule);
  list-style: none;
}

.partlist li + li {
  border-top: var(--rule);
}

.partlist a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 4px;
  font-weight: 700;
  text-decoration: none;
}

.partlist a:hover {
  background: rgb(255 255 255 / 40%);
}

.partlist .n {
  width: 28px;
  height: 28px;
  font-size: 0.875rem;
}

.partlist .is-active .n {
  background: var(--ink);
  color: var(--paper);
}

.back {
  margin-top: 40px;
  font-weight: 600;
}

/* Footer */
.foot {
  margin-top: 48px;
  border-top: 2px solid var(--ink);
}

.foot-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 28px;
  padding-block: 20px 28px;
}

.foot-id {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 20px;
}

.foot-logo {
  display: inline-flex;
  line-height: 0;
}

.foot-logo .logo-svg {
  height: 30px;
}

.foot-brand {
  margin: 0;
  font: 400 0.8125rem/1.4 var(--mono);
}

.foot-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 22px;
  font-size: 0.9375rem;
  font-weight: 600;
}

.foot-ext {
  color: var(--ink-soft);
  font: 400 0.8125rem/1.4 var(--mono);
}

/* Narrower screens */
@media (max-width: 1080px) {
  .hero {
    grid-template:
      "main" auto
      "facts" auto
      "places" auto / minmax(0, 1fr);
    gap: 0;
  }

  .hero > .places {
    max-width: 560px;
    margin-top: 32px;
  }

  .page-cols {
    grid-template-columns: minmax(0, 1fr);
    gap: 36px;
  }

  .side {
    max-width: 420px;
  }
}

@media (max-width: 820px) {
  .parts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .part:nth-child(2) {
    border-right: 0;
  }

  .part:nth-child(n + 3) {
    border-top: var(--rule);
  }

  .page-ico {
    display: none;
  }
}

@media (max-width: 600px) {
  body {
    font-size: 1rem;
  }

  .brand {
    flex-basis: 100%;
  }

  .nav {
    flex: 1 1 100%;
    margin-inline: -12px;
  }

  .parts {
    grid-template-columns: minmax(0, 1fr);
  }

  .part {
    border-right: 0;
  }

  .part + .part {
    border-top: var(--rule);
  }

  .part a {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr);
    column-gap: 14px;
    align-items: center;
    min-height: 0;
    padding: 14px 8px 14px 4px;
  }

  .part .n {
    top: 8px;
    left: 2px;
    width: 24px;
    height: 24px;
    font-size: 0.75rem;
  }

  .part .ico-lg {
    grid-row: 1 / span 2;
    grid-column: 1;
    width: 60px;
    height: 56px;
    margin: 0 auto;
  }

  .part b,
  .part small {
    grid-column: 2;
  }

  .page-head {
    gap: 14px;
  }

  .n-active {
    width: 42px;
    height: 42px;
    font-size: 1.25rem;
  }

  .dos {
    grid-template-columns: minmax(0, 1fr);
  }

  .dos section + section {
    padding: 18px 0 20px;
    border-top: var(--rule);
    border-left: 0;
  }

  .chart th,
  .chart td {
    padding: 8px 9px;
  }
}

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

@media print {
  .bar,
  .side,
  .back,
  .foot-nav,
  .btn,
  .ico-lg {
    display: none;
  }

  body {
    background: #fff;
  }
}
