:root {
  --bg: #F1EFEA;
  --ink: #2A241F;
  --muted: #6B6058;
  --label: #8A7E74;
  --rust: #B5462B;
  --card: #111111;
  --white: #FFFCFA;
  --rule: rgba(42, 36, 31, 0.16);
  --brown: #5C534C;
  --serif: "Bodoni Moda", "Playfair Display", Didot, "Times New Roman", serif;
  --sans: "DM Sans", "Helvetica Neue", system-ui, sans-serif;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--bg); color: var(--ink); }
html { height: 100%; }
body {
  min-height: 100%;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.45;
  color: var(--brown);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
button, input { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; }
a { color: var(--rust); }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

.view-home { min-height: 100vh; padding: calc(28px + var(--safe-top)) 22px calc(48px + var(--safe-bottom)); max-width: 720px; margin: 0 auto; }
.view-reader { min-height: 100vh; }

.brand {
  margin: 0 0 18px;
  font-family: var(--serif);
  font-size: 15px;
  font-weight: 400;
  letter-spacing: 0.01em;
  color: var(--ink);
}
.brand em { font-style: italic; color: var(--ink); }

.home-title {
  margin: 0 0 14px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(34px, 9vw, 52px);
  line-height: 1.05;
  color: var(--ink);
  letter-spacing: -0.02em;
}
.home-title em { font-style: italic; color: var(--rust); }
.home-lead { margin: 0 0 28px; max-width: 28em; color: var(--muted); font-size: 15px; }

.search-wrap input {
  width: 100%;
  border: 0;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 1px 0 rgba(42,36,31,0.06), 0 8px 24px rgba(42,36,31,0.05);
  padding: 14px 18px;
  outline: none;
}
.search-wrap input:focus { box-shadow: 0 0 0 2px var(--rust), 0 8px 24px rgba(42,36,31,0.05); }
.search-wrap input::placeholder { color: #A39A93; }

.sort-row { display: flex; align-items: center; gap: 12px; margin: 16px 0 12px; flex-wrap: wrap; }
.sort-label {
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--label);
  font-weight: 500;
}
.sort-pills, .chips { display: flex; flex-wrap: wrap; gap: 8px; }
.pill, .chip {
  padding: 7px 12px;
  border-radius: 999px;
  background: transparent;
  border: 1px solid var(--rule);
  color: var(--muted);
  font-size: 13px;
}
.pill.is-active, .chip.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--white);
}

.result-count { margin: 18px 0 10px; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--label); }
.topic-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.topic-card {
  display: block;
  width: 100%;
  text-align: left;
  background: #fff;
  border-radius: 18px;
  padding: 18px 18px 16px;
  box-shadow: 0 1px 0 rgba(42,36,31,0.05), 0 10px 28px rgba(42,36,31,0.04);
  color: inherit;
}
.topic-card:hover { transform: translateY(-1px); }
.topic-card .kicker {
  margin: 0 0 8px;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--rust);
  font-weight: 500;
}
.topic-card h2 {
  margin: 0 0 6px;
  font-family: var(--serif);
  font-size: 26px;
  line-height: 1.15;
  font-weight: 400;
  color: var(--ink);
}
.topic-card p { margin: 0; color: var(--muted); font-size: 14px; }
.empty { text-align: center; color: var(--muted); padding: 32px 8px; }

/* Reader / slides */
.view-reader { position: relative; background: var(--bg); }
.slides { min-height: 100vh; outline: none; touch-action: pan-y; }
.slide {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  padding: calc(16px + var(--safe-top)) 22px calc(16px + var(--safe-bottom));
}
.slide-inner { flex: 1; display: flex; flex-direction: column; width: 100%; max-width: 430px; margin: 0 auto; }

.reader-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}
.back {
  font-size: 13px;
  color: var(--muted);
  padding: 4px 0;
}
.back:hover { color: var(--ink); }
.logo-small {
  font-family: var(--serif);
  font-size: 15px;
  color: var(--ink);
  margin: 0;
}
.logo-small em { font-style: italic; }
.progress { display: flex; gap: 8px; }
.dot {
  width: 22px; height: 22px;
  border-radius: 50%;
  border: 1.5px solid var(--ink);
  color: var(--ink);
  font-size: 11px;
  display: grid; place-items: center;
  font-family: var(--sans);
  font-weight: 500;
  background: transparent;
}
.dot.is-active { background: var(--rust); border-color: var(--rust); color: #fff; }
.dot.is-done { background: var(--ink); border-color: var(--ink); color: #fff; }

.lbl {
  margin: 0 0 8px;
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--label);
  font-weight: 500;
}

/* Intro */
.intro-title {
  margin: 8px 0 28px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(40px, 11vw, 58px);
  line-height: 0.98;
  color: var(--ink);
  letter-spacing: -0.03em;
}
.intro-title em { font-style: italic; color: var(--rust); font-weight: 400; }
.er-sagt {
  background: #fff;
  border-radius: 16px;
  padding: 18px 20px 20px;
  box-shadow: 0 10px 30px rgba(42,36,31,0.08), 0 1px 0 rgba(42,36,31,0.06);
}
.er-sagt .quote {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(22px, 6vw, 28px);
  line-height: 1.2;
  color: var(--ink);
  font-weight: 400;
}
.chat-dots {
  width: 62px;
  height: 34px;
  margin: 14px 0 0 6px;
  background: #111;
  border-radius: 16px 16px 16px 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.chat-dots span {
  width: 7px; height: 7px; border-radius: 50%; background: #fff;
}
.chat-dots span:nth-child(2) { background: var(--rust); }
.intro-sub {
  margin: 28px 0 0;
  font-size: 16px;
  color: var(--brown);
  max-width: 22em;
}
.intro-grow { flex: 1; }

/* Situation */
.sit-text {
  margin: 0 0 22px;
  font-family: var(--serif);
  font-size: clamp(26px, 7vw, 34px);
  line-height: 1.15;
  color: var(--ink);
  font-weight: 400;
}
.say-card {
  background: var(--card);
  color: var(--white);
  border-radius: 18px;
  padding: 22px 22px 24px;
  margin: 0 0 22px;
}
.say-card .lbl { color: rgba(255,252,250,0.55); }
.say-card .quote {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(24px, 6.4vw, 32px);
  line-height: 1.2;
  color: #fff;
  font-weight: 400;
}
.happens { margin: 0; font-size: 16px; line-height: 1.5; color: var(--brown); }

/* Takeaway */
.slide-take { background: var(--rust); color: #fff; }
.slide-take .take-top {
  display: flex; justify-content: flex-end; margin-bottom: 24px;
}
.take-lbl {
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.8);
  font-weight: 500;
}
.take-statement {
  margin: 0 0 10px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(30px, 8vw, 42px);
  line-height: 1.12;
  color: #fff;
  letter-spacing: -0.02em;
}
.take-statement em, .take-second {
  display: block;
  margin-top: 8px;
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(26px, 6.5vw, 36px);
  line-height: 1.15;
  color: #fff;
}
.take-card {
  margin-top: auto;
  background: #F3EDE7;
  color: var(--ink);
  border-radius: 18px;
  padding: 18px 18px 16px;
}
.take-card p { margin: 0 0 10px; font-size: 14px; color: var(--brown); line-height: 1.45; }
.take-card a { color: var(--rust); text-decoration: none; font-weight: 500; font-size: 13px; }
.take-card a:hover { text-decoration: underline; }

/* Footer of a slide */
.slide-foot {
  margin-top: auto;
  padding-top: 22px;
  border-top: 1px solid var(--rule);
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--label);
  font-weight: 500;
}
.slide-take .slide-foot { border-top-color: rgba(255,255,255,0.28); color: rgba(255,255,255,0.8); }
.foot-right { white-space: nowrap; }

.quelle {
  margin: 10px 0 0;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: none;
}
.quelle a { color: inherit; }

.nav-arrow {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  width: 44px; height: 44px;
  border-radius: 50%;
  background: rgba(241,239,234,0.8);
  color: var(--ink);
  font-size: 28px;
  line-height: 1;
  display: grid; place-items: center;
  box-shadow: 0 4px 16px rgba(42,36,31,0.08);
}
.nav-prev { left: max(8px, calc((100vw - 520px) / 2)); }
.nav-next { right: max(8px, calc((100vw - 520px) / 2)); }
.nav-arrow[disabled] { opacity: 0.25; pointer-events: none; }
@media (max-width: 720px) {
  .nav-arrow { display: none; } /* swipe + tap on mobile */
}

@media (min-width: 900px) {
  .view-home { padding-top: 56px; }
  .topic-list { grid-template-columns: 1fr 1fr; }
  .slide-inner { max-width: 480px; }
}
