:root {
  color-scheme: light;
  --bg: #f4f1ea;
  --ink: #1e2320;
  --muted: #626a64;
  --line: #d9d3c6;
  --panel: #fffaf1;
  --accent: #9d3b2e;
  --accent-strong: #74291f;
  --dark: #151918;
  font-family: "Segoe UI", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg);
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background: var(--bg);
}

body.page-enter {
  animation: page-enter 180ms ease-out;
}

a {
  color: inherit;
}

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

.hero,
.sub-hero {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  min-height: 42vh;
  padding: 56px clamp(22px, 5vw, 72px);
  color: #fffaf1;
  background:
    linear-gradient(90deg, rgba(21, 25, 24, 0.95), rgba(21, 25, 24, 0.68)),
    url("slides/seite-001.jpg") center / cover;
}

.sub-hero {
  display: block;
  min-height: 28vh;
}

.hero h1,
.sub-hero h1 {
  max-width: 960px;
  margin: 0;
  font-size: clamp(36px, 6vw, 74px);
  line-height: 1;
  letter-spacing: 0;
}

.sub-hero h1 {
  margin-top: 18px;
  font-size: clamp(30px, 4vw, 54px);
}

.hero p,
.sub-hero p {
  max-width: 720px;
  margin: 16px 0 0;
  color: #e4ded2;
  font-size: 18px;
  line-height: 1.5;
}

.kicker {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero .kicker {
  color: #f0b08d;
}

.shell {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 34px 0 52px;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.section-heading h2 {
  margin: 0;
  font-size: 28px;
}

.section-heading p {
  margin: 0;
  color: var(--muted);
}

.section-grid,
.page-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.section-card a,
.page-card a {
  display: grid;
  gap: 10px;
  min-height: 150px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: var(--panel);
  text-decoration: none;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.section-card a:hover,
.section-card a:focus-visible,
.page-card a:hover,
.page-card a:focus-visible {
  border-color: var(--accent);
  box-shadow: 0 14px 38px rgba(40, 31, 20, 0.12);
  outline: none;
  transform: translateY(-2px);
}

.section-card span,
.page-card span {
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
}

.section-card strong,
.page-card strong {
  font-size: 20px;
  line-height: 1.25;
}

.section-card small {
  color: var(--muted);
}

.page-card img {
  aspect-ratio: 16 / 9;
  width: 100%;
  object-fit: cover;
  border: 1px solid var(--line);
  background: #111;
}

.detail-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  min-height: 100vh;
}

.detail-stage {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 14px;
  min-width: 0;
  padding: 18px;
  background: var(--dark);
}

.detail-topline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #e4ded2;
  font-size: 14px;
}

.text-link {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

.visual {
  display: grid;
  place-items: center;
  min-height: 0;
  margin: 0;
}

.visual img {
  width: min(100%, calc((100vh - 118px) * 16 / 9));
  max-height: calc(100vh - 118px);
  object-fit: contain;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.42);
}

.page-nav {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.button {
  display: inline-grid;
  place-items: center;
  min-height: 42px;
  padding: 10px 14px;
  border: 1px solid rgba(255, 250, 241, 0.22);
  border-radius: 6px;
  color: #fffaf1;
  background: rgba(255, 250, 241, 0.08);
  text-decoration: none;
  cursor: pointer;
}

.button.primary {
  border-color: var(--accent);
  background: var(--accent);
}

.button:hover,
.button:focus-visible {
  background: var(--accent-strong);
  outline: none;
}

.button.disabled {
  color: rgba(255, 250, 241, 0.42);
  pointer-events: none;
}

.detail-text {
  min-width: 0;
  max-height: 100vh;
  padding: 28px 24px;
  overflow: auto;
  border-left: 1px solid var(--line);
  background: var(--panel);
}

.detail-text h1 {
  margin: 0 0 20px;
  font-size: 27px;
  line-height: 1.16;
  letter-spacing: 0;
}

.copy {
  display: grid;
  gap: 12px;
}

.copy p {
  margin: 0;
  color: #2d332f;
  font-size: 16px;
  line-height: 1.48;
}

.muted {
  color: var(--muted);
}

@keyframes page-enter {
  from {
    opacity: 0;
    transform: translateY(5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1050px) {
  .detail-shell {
    grid-template-columns: 1fr;
  }

  .detail-text {
    max-height: none;
    border-left: 0;
  }

  .visual img {
    width: 100%;
    max-height: none;
  }

  .section-grid,
  .page-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .hero {
    align-items: start;
    flex-direction: column;
    min-height: 48vh;
  }

  .section-heading {
    display: block;
  }

  .section-grid,
  .page-grid {
    grid-template-columns: 1fr;
  }
}
