/* andreas henrich — static rebuild of ahenrich.de */

:root {
  color-scheme: light;
  --bg: #fbfbfb;
  --text: #161616;
  --muted-line: #d5d5d2;
  --hover: #7a1414;
  --sidebar: 14.5rem;
  --gap: 2.75rem;
}

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

html {
  font-size: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 1rem;
  line-height: 1.5;
}

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

a {
  color: inherit;
}

a:hover,
a:focus-visible {
  color: var(--hover);
}

a:focus-visible,
.logo:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 3px;
}

.skip {
  position: absolute;
  left: 0.75rem;
  top: 0.75rem;
  z-index: 2;
  padding: 0.4rem 0.7rem;
  background: #fff;
  color: var(--text);
  transform: translateY(-200%);
}

.skip:focus {
  transform: none;
}

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

.shell {
  display: grid;
  grid-template-columns: var(--sidebar) minmax(0, 1fr);
  column-gap: var(--gap);
  row-gap: 2.5rem;
  max-width: 86rem;
  margin: 0 auto;
  padding: 1.35rem 1.5rem 3rem;
}

.sidebar {
  align-self: start;
}

.intro {
  max-width: 34rem;
  margin: 0 0 1.4rem;
  font-size: 0.9375rem;
  line-height: 1.45;
}

main {
  min-width: 0;
}

.site-footer {
  grid-column: 1 / -1;
  padding-top: 0.9rem;
  border-top: 1px solid var(--muted-line);
  font-size: 0.875rem;
}

.site-footer p {
  margin: 0;
}

.logo {
  display: inline-block;
  line-height: 0;
  text-decoration: none;
}

.logo img {
  width: 181px;
  height: 31px;
}

.nav-list {
  list-style: none;
  margin: 1.6rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.72rem;
  font-size: 0.9375rem;
}

.nav-list a {
  text-decoration: underline;
  text-underline-offset: 0.18em;
  text-decoration-thickness: 1px;
}

.nav-list a[aria-current="page"] {
  font-weight: 700;
}

.intro h1,
.page-title,
.prose h1 {
  margin: 0 0 0.8rem;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.35;
}

.intro p,
.prose p {
  margin: 0 0 0.8rem;
}

.hero {
  margin: 0 0 1.6rem;
}

.hero picture {
  display: block;
}

.hero img {
  display: block;
  width: min(100%, 52rem);
  height: auto;
}

.gallery {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 14rem), 15.5rem));
  gap: 1.15rem 1rem;
  align-items: start;
  justify-content: start;
  margin: 0;
  padding: 0;
}

.gallery-home {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 10rem), 14rem));
  max-width: 46rem;
}

.gallery li {
  margin: 0;
  padding: 0;
}

.gallery picture {
  display: block;
}

.gallery img {
  display: block;
  width: 100%;
  height: auto;
  background: #fff;
}

.gallery a {
  display: block;
  line-height: 0;
  text-decoration: none;
}

.gallery a:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 3px;
}

.prose {
  max-width: 38rem;
}

.prose address {
  font-style: normal;
  margin: 0 0 1rem;
}

.prose a {
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

.page-title {
  margin-bottom: 1rem;
}

@media (min-width: 761px) {
  .sidebar {
    position: sticky;
    top: 1.25rem;
  }
}

@media (max-width: 760px) {
  .shell {
    display: flex;
    flex-direction: column;
    gap: 1.35rem;
    padding: 1rem 1rem 2.5rem;
  }

  .site-footer {
    margin-top: 0.5rem;
  }

  .nav-list {
    gap: 0.85rem;
  }

  .nav-list a {
    display: inline-block;
    padding: 0.15rem 0;
  }

  .gallery,
  .gallery-home {
    width: 100%;
    max-width: none;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 420px) {
  .gallery-home {
    grid-template-columns: 1fr 1fr;
  }
}

@media print {
  body {
    background: #fff;
  }

  .skip,
  .site-footer {
    display: none;
  }

  .shell {
    display: block;
    max-width: none;
    padding: 0;
  }

  .sidebar {
    margin-bottom: 1rem;
  }

  a {
    text-decoration: underline;
  }
}
