/* ------------------------------------------------------------------ fonts
   Self-hosted on purpose: hotlinking Google Fonts sends every visitor's IP to
   Google, which Austrian/German courts have ruled a GDPR violation. */
@font-face {
  font-family: 'Literata';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url(/assets/fonts/literata-400-700var-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Literata';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url(/assets/fonts/literata-400-700var-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/ibm-plex-mono-400-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/ibm-plex-mono-400-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(/assets/fonts/ibm-plex-mono-600-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(/assets/fonts/ibm-plex-mono-600-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ------------------------------------------------------------------ tokens
   Alpine meadow and limestone: the Tennengebirge is pale grey rock above
   green pasture, so the palette is exactly that. */
:root {
  --paper: #f7f6f1;
  --paper-2: #efeee6;
  --card: #ffffff;
  --ink: #1d2721;
  --ink-2: #435047;
  --muted: #6a746c;
  --line: #dddcd0;
  --green: #2e6a3e;
  --green-ink: #24553a;
  --green-soft: #e2ede1;
  --sky: #dce8ec;
  --serif: 'Literata', Georgia, 'Times New Roman', serif;
  --mono: 'IBM Plex Mono', ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace;
  --radius: 10px;
  --shell: 72rem;
  --narrow: 44rem;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #151a17;
    --paper-2: #1b211d;
    --card: #1e2520;
    --ink: #e8ebe6;
    --ink-2: #c3cac2;
    --muted: #97a097;
    --line: #313a33;
    --green: #8cc79a;
    --green-ink: #a6d6b1;
    --green-soft: #243328;
    --sky: #1f2a2e;
  }
  img[src$='.svg']:not(.keep) { filter: saturate(0.85) brightness(0.92); }
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.0625rem;
  line-height: 1.65;
  text-rendering: optimizeLegibility;
}

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

a { color: var(--green-ink); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--green); outline-offset: 2px; border-radius: 3px; }

h1, h2, h3 { line-height: 1.2; font-weight: 650; letter-spacing: -0.01em; margin: 0 0 0.5em; }
h1 { font-size: clamp(1.9rem, 1.3rem + 2.6vw, 3rem); }
h2 { font-size: clamp(1.35rem, 1.1rem + 1vw, 1.75rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }

.skip {
  position: absolute; left: -999px; top: 0.5rem;
  background: var(--ink); color: var(--paper); padding: 0.5rem 1rem; z-index: 10;
}
.skip:focus { left: 1rem; }

.eyebrow, .meta, time, .chips, .nav, .lang, .button, .section-head a, .foot-links {
  font-family: var(--mono);
  font-size: 0.8125rem;
  letter-spacing: 0.02em;
}
.eyebrow { text-transform: uppercase; color: var(--muted); margin-bottom: 0.75rem; }
.eyebrow a { color: inherit; }
.meta { color: var(--muted); margin: 0 0 0.35rem; }
.meta a { color: var(--green-ink); text-decoration: none; }
.lead { font-size: 1.2rem; color: var(--ink-2); }

.shell { max-width: var(--shell); margin: 0 auto; padding: 0 1.25rem; }
.shell.narrow { max-width: var(--narrow); }
main > .shell { margin-block: 3rem; }

/* ------------------------------------------------------------------ masthead */
.masthead { border-bottom: 1px solid var(--line); background: var(--paper); }
.bar {
  max-width: var(--shell); margin: 0 auto; padding: 0.8rem 1.25rem;
  display: flex; align-items: center; gap: 0.75rem 1.5rem; flex-wrap: wrap;
}
.wordmark {
  display: flex; align-items: center; gap: 0.6rem;
  color: var(--ink); text-decoration: none; font-weight: 700; font-size: 1.2rem; line-height: 1;
}
.wordmark img { flex: none; }
.wordmark small {
  display: block; font-family: var(--mono); font-weight: 400; font-size: 0.7rem;
  color: var(--muted); text-transform: uppercase; letter-spacing: 0.08em; margin-top: 0.25rem;
}
.nav { display: flex; flex-wrap: wrap; gap: 0.25rem 1.1rem; margin-left: auto; }
.nav a { color: var(--ink-2); text-decoration: none; padding: 0.25rem 0; border-bottom: 2px solid transparent; }
.nav a:hover, .nav a[aria-current] { color: var(--ink); border-bottom-color: var(--green); }
.lang {
  color: var(--ink); text-decoration: none; border: 1px solid var(--line); border-radius: 999px;
  padding: 0.2rem 0.65rem; background: var(--card);
}
.lang:hover { border-color: var(--green); }

@media (max-width: 40rem) {
  .bar { gap: 0.5rem 1rem; }
  .nav { order: 3; width: 100%; margin-left: 0; overflow-x: auto; flex-wrap: nowrap; white-space: nowrap; padding-bottom: 0.2rem; }
  .lang { margin-left: auto; }
}

/* ------------------------------------------------------------------ hero */
.hero {
  background: linear-gradient(180deg, var(--sky) 0%, var(--paper) 100%);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}
.hero-text { max-width: var(--shell); margin: 0 auto; padding: 3.5rem 1.25rem 1rem; }
.hero-text h1 { max-width: 20ch; }
.hero-text .lead { max-width: 40rem; }
.hero-art { width: 100%; max-height: 22rem; object-fit: cover; object-position: bottom; }

.button {
  display: inline-block; background: var(--green); color: #fff; text-decoration: none;
  padding: 0.6rem 1.1rem; border-radius: 999px; border: 1px solid var(--green); margin: 0 0.4rem 0.4rem 0;
}
.button:hover { background: var(--green-ink); }
.button.ghost { background: transparent; color: var(--green-ink); }
@media (prefers-color-scheme: dark) { .button { color: #102015; } }

/* ------------------------------------------------------------------ sections */
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.25rem; }
.section-head h2 { margin: 0; }
.section-head a { text-decoration: none; }

.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 19rem), 1fr)); gap: 1.25rem; }
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
}
.card-art img { width: 100%; aspect-ratio: 32 / 14; object-fit: cover; background: var(--green-soft); }
.card-body { padding: 1rem 1.15rem 1.2rem; }
.card h3 { font-size: 1.15rem; margin-bottom: 0.4rem; }
.card h3 a { color: var(--ink); text-decoration: none; }
.card h3 a:hover { text-decoration: underline; }
.card p:last-child { margin: 0; color: var(--ink-2); font-size: 0.975rem; }

.chips { list-style: none; padding: 0; margin: 0 0 2rem; display: flex; flex-wrap: wrap; gap: 0.5rem; }
.chips a {
  display: inline-block; padding: 0.3rem 0.8rem; border-radius: 999px; text-decoration: none;
  background: var(--green-soft); color: var(--green-ink); border: 1px solid transparent;
}
.chips a:hover { border-color: var(--green); }
.chips a[aria-current] { background: var(--green); color: var(--paper); }

.guides { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 16rem), 1fr)); gap: 1rem; }
.guide {
  display: flex; gap: 1rem; align-items: flex-start; padding: 1rem; text-decoration: none; color: var(--ink-2);
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); font-size: 0.95rem; line-height: 1.5;
}
.guide:hover { border-color: var(--green); }
.guide img { width: 4rem; height: 4rem; flex: none; }
.guide strong { display: block; color: var(--ink); font-size: 1.05rem; margin-bottom: 0.2rem; }

/* ------------------------------------------------------------------ lists */
.page-head { margin-bottom: 2rem; }
.year h2 { font-family: var(--mono); font-size: 0.95rem; color: var(--muted); border-bottom: 1px solid var(--line); padding-bottom: 0.4rem; margin-top: 2.5rem; }
.entries { list-style: none; padding: 0; margin: 0; }
.entry { display: grid; grid-template-columns: 9.5rem 1fr; gap: 0.25rem 1.25rem; padding: 1.1rem 0; border-bottom: 1px solid var(--line); }
.entry:last-child { border-bottom: 0; }
.entry time { color: var(--muted); padding-top: 0.2rem; }
.entry h3 { margin-bottom: 0.3rem; }
.entry h3 a { color: var(--ink); text-decoration: none; }
.entry h3 a:hover { text-decoration: underline; }
.entry p { margin-bottom: 0.3rem; color: var(--ink-2); }
@media (max-width: 36rem) { .entry { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------------ article */
.post-art { width: 100%; max-height: 12rem; object-fit: cover; border-radius: var(--radius); background: var(--green-soft); margin-bottom: 2rem; }
.page .post-art { width: 5rem; height: 5rem; background: none; border-radius: 0; margin-bottom: 1.5rem; }
.prose h2 { margin-top: 2rem; }
.prose h3 { margin-top: 1.5rem; }
.prose ul, .prose ol { padding-left: 1.25rem; }
.prose li { margin-bottom: 0.35rem; }
.prose blockquote { margin: 1.5rem 0; padding: 0.25rem 0 0.25rem 1.1rem; border-left: 3px solid var(--green); color: var(--ink-2); font-style: italic; }
.prose table { width: 100%; border-collapse: collapse; font-size: 0.95rem; display: block; overflow-x: auto; }
.prose th, .prose td { text-align: left; padding: 0.45rem 0.6rem; border-bottom: 1px solid var(--line); }

.sources {
  margin: 2.5rem 0; padding: 1.1rem 1.25rem; background: var(--paper-2);
  border: 1px solid var(--line); border-radius: var(--radius); font-size: 0.95rem;
}
.sources h2 { font-family: var(--mono); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); margin-bottom: 0.4rem; }
.sources p { margin-bottom: 0.4rem; color: var(--ink-2); }
.sources ul { margin: 0; padding-left: 1.1rem; }
.sources a { overflow-wrap: anywhere; }
.sources a::after { content: ' ↗'; }

.related { margin-top: 2.5rem; }
.related h2 { font-size: 1.2rem; }
.back { margin-top: 2rem; font-family: var(--mono); font-size: 0.875rem; }

/* ------------------------------------------------------------------ footer */
.site-foot { border-top: 1px solid var(--line); background: var(--paper-2); margin-top: 4rem; }
.foot-inner { max-width: var(--shell); margin: 0 auto; padding: 2rem 1.25rem 2.5rem; }
.independent { max-width: 48rem; color: var(--muted); font-size: 0.9rem; }
.foot-links { display: flex; flex-wrap: wrap; gap: 0.5rem 1.25rem; margin: 0; }
