/* Gemeinsame Gestaltung für alle Seiten von wolske.dev */
:root {
  --bg: #f6f5f1;
  --fg: #1b1b1a;
  --muted: #63615a;
  --accent: #946500;
  --code-bg: #ebe9e2;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111110;
    --fg: #ecebe6;
    --muted: #8b8a84;
    --accent: #f5c542;
    --code-bg: #1c1c1a;
  }
}
* { box-sizing: border-box; margin: 0; }
html, body { height: 100%; }
body {
  background: var(--bg);
  color: var(--fg);
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  display: grid;
  padding: 24px 16px;
}
main {
  align-self: center;
  justify-self: center;
  max-width: 36rem;
  width: 100%;
}
.prompt { color: var(--muted); font-size: 0.95rem; margin-bottom: 0.75rem; overflow-wrap: anywhere; }
h1 {
  font-size: clamp(2.4rem, 9vw, 4.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.05;
}
h1 .tld { color: var(--accent); }
.cursor {
  display: inline-block;
  width: 0.55em;
  height: 0.9em;
  margin-left: 0.08em;
  vertical-align: -0.08em;
  background: var(--accent);
  animation: blink 1.1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .cursor { animation: none; } }
p.tagline {
  margin-top: 1.25rem;
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--muted);
}
ul.links {
  list-style: none;
  padding: 0;
  margin-top: 2rem;
  display: grid;
  gap: 0.6rem;
  font-size: 1rem;
}
ul.links li { display: flex; gap: 1ch; min-width: 0; }
ul.links .label { color: var(--muted); flex: 0 0 9ch; }
ul.links a,
.rueckweg a {
  color: var(--fg);
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.25em;
  overflow-wrap: anywhere;
}
ul.links a:hover,
.rueckweg a:hover { color: var(--accent); }
ul.links a:focus-visible,
.rueckweg a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
p.fehler {
  color: var(--muted);
  font-size: 0.95rem;
  margin-top: -0.25rem;
  margin-bottom: 1.25rem;
  overflow-wrap: anywhere;
}
/* Tipp-Animation (terminal.js): noch nicht erschienene Zeilen sind nur durchsichtig,
   bleiben aber für Screenreader lesbar und halten ihren Platz. */
.verborgen { opacity: 0; }
/* Nur für Screenreader sichtbar. */
.nur-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.sitzung {
  display: grid;
  gap: 0.35rem;
  font-size: 1rem;
  line-height: 1.5;
  overflow-wrap: anywhere;
}
.sitzung .ps,
.sitzung .ausgabe { color: var(--muted); }
.sitzung .ausgabe { white-space: pre-wrap; }
.sitzung h1 {
  font-size: inherit;
  letter-spacing: normal;
  line-height: inherit;
}
.sitzung .kommentar { color: var(--muted); white-space: pre; }
.tagline + .sitzung { margin-top: 2rem; }
.sitzung .rueckweg { margin-top: 0.75rem; }

/* Projektseiten (scripts/projektseite.mjs, z. B. eink.wolske.dev): README als Ausgabe von "cat". */
main.projekt { align-self: start; max-width: 48rem; min-width: 0; }
body:has(main.projekt) { grid-template-columns: minmax(0, 1fr); }
.projekt .sitzung { grid-template-columns: minmax(0, 1fr); }
.projekt .sitzung .ok { color: var(--fg); }
.inhalt ul { list-style: none; padding: 0; display: grid; gap: 0.2rem; color: var(--muted); }
.readme {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.9rem;
  margin: 0.5rem 0 1.5rem;
  line-height: 1.6;
  overflow-wrap: break-word;
}
.readme :is(h1, h2, h3, h4, h5, h6) { font-size: 1rem; font-weight: 700; line-height: 1.4; margin-top: 1rem; scroll-margin-top: 1rem; }
.sitzung .readme h1 { font-size: clamp(1.6rem, 6vw, 2.4rem); letter-spacing: -0.02em; line-height: 1.1; margin-top: 0; }
.readme h2 { font-size: 1.15rem; margin-top: 2rem; }
.readme :is(h2, h3, h4)::before { color: var(--accent); }
.readme h2::before { content: "## "; }
.readme h3::before { content: "### "; }
.readme h4::before { content: "#### "; }
.readme :is(ul, ol) { padding-left: 3ch; display: grid; gap: 0.3rem; }
.readme pre,
.readme .tabelle { overflow-x: auto; }
.readme pre {
  padding: 0.75rem 1rem;
  border-left: 2px solid var(--accent);
  background: var(--code-bg);
  line-height: 1.45;
  font-size: 0.9rem;
}
.readme code { font: inherit; }
.readme :not(pre) > code { background: var(--code-bg); padding: 0.05em 0.3em; border-radius: 3px; }
.readme table { border-collapse: collapse; font-size: 0.9rem; }
.readme :is(th, td) { border: 1px solid var(--muted); padding: 0.3rem 0.6rem; text-align: left; vertical-align: top; }
.readme blockquote { border-left: 2px solid var(--muted); padding-left: 1.5ch; color: var(--muted); }
.readme hr { border: 0; border-top: 1px dashed var(--muted); }
.readme a,
.inhalt a,
.projekt .ausgabe a {
  color: var(--fg);
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.2em;
}
.readme a:hover,
.inhalt a:hover,
.projekt .ausgabe a:hover { color: var(--accent); }
:is(.readme, .inhalt, .projekt .ausgabe) a:focus-visible,
.readme :is(pre, .tabelle):focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
