/* Themen-Übersicht & Detail — Codarion Design Language */

body.page-themen main {
  background: transparent !important;
}

body.page-themen {
  background: #141f1a;
}

body.page-themen .site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 300;
}

body.page-themen .site-footer {
  position: relative;
  z-index: 3;
}

/* ── Hero ── */
.themen-hero {
  position: relative;
  z-index: 2;
  min-height: min(78vh, 720px);
  display: flex;
  align-items: flex-end;
  padding: clamp(6.5rem, 12vw, 8.5rem) 0 clamp(3rem, 6vw, 4.5rem);
  isolation: isolate;
}

.themen-hero--overview {
  min-height: min(86vh, 780px);
  align-items: center;
  overflow: hidden;
  background: #141f1a;
}

.themen-hero__photo--overview img {
  object-position: center 35%;
  filter: brightness(0.38) contrast(1.08) saturate(0.9);
}

.themen-overview-mosaic {
  position: absolute;
  right: clamp(1rem, 4vw, 3rem);
  top: 50%;
  z-index: 1;
  width: min(28vw, 320px);
  display: grid;
  gap: 0.65rem;
  transform: translateY(-42%);
  pointer-events: none;
}

.themen-overview-mosaic__tile {
  margin: 0;
  border-radius: 1rem;
  overflow: hidden;
  border: 1px solid rgba(214, 195, 163, 0.18);
  box-shadow: 0 18px 40px rgba(4, 8, 6, 0.35);
}

.themen-overview-mosaic__tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: 16 / 10;
  filter: brightness(0.72) saturate(0.95);
}

.themen-overview-mosaic__tile--1 {
  transform: translateX(8%) rotate(2.5deg);
}

.themen-overview-mosaic__tile--2 {
  width: 88%;
  margin-left: auto;
  transform: translateX(-4%) rotate(-2deg);
}

.themen-overview-mosaic__tile--3 {
  width: 78%;
  transform: translateX(12%) rotate(1.5deg);
}

.themen-hero--detail {
  min-height: min(88vh, 820px);
  align-items: center;
  padding-top: clamp(7rem, 14vw, 9rem);
}

.themen-hero__photo {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.themen-hero__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
  filter: brightness(0.42) contrast(1.06) saturate(0.88);
}

.themen-hero__photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(100deg, rgba(10, 16, 13, 0.88) 0%, rgba(12, 20, 16, 0.55) 48%, rgba(10, 16, 13, 0.35) 100%),
    linear-gradient(180deg, rgba(10, 16, 13, 0.35) 0%, rgba(10, 16, 13, 0.72) 100%);
}

.themen-hero .container {
  position: relative;
  z-index: 1;
  width: min(100% - 2.4rem, var(--container-max));
}

/* Hero-Text: weicher Nebel statt harter Rechteck-Karte
   (höhere Spezifität gegen pages.css body:not(.page-home) .page-hero__card) */
body.page-themen .themen-hero .page-hero__card {
  position: relative;
  isolation: isolate;
  max-width: min(40rem, 92vw);
  padding: clamp(1.5rem, 3.2vw, 2.35rem) clamp(1.75rem, 3.8vw, 2.85rem)
    clamp(1.55rem, 3vw, 2.2rem) clamp(1.7rem, 3.8vw, 2.85rem);
  border: none !important;
  border-radius: 2rem 1.25rem 2.35rem 1.45rem;
  background: transparent !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  box-shadow: none !important;
  overflow: visible;
}

body.page-themen .themen-hero .page-hero__card::before {
  content: "";
  position: absolute;
  inset: -0.35rem -1.5rem -0.35rem -0.35rem;
  z-index: -1;
  border-radius: inherit;
  background:
    radial-gradient(ellipse 85% 75% at 14% 20%, rgba(199, 155, 95, 0.12), transparent 58%),
    linear-gradient(
      112deg,
      rgba(12, 20, 16, 0.82) 0%,
      rgba(16, 28, 22, 0.68) 52%,
      rgba(16, 28, 22, 0.22) 82%,
      transparent 100%
    );
  backdrop-filter: blur(22px) saturate(1.06);
  -webkit-backdrop-filter: blur(22px) saturate(1.06);
  box-shadow:
    0 30px 70px rgba(4, 8, 6, 0.3),
    inset 0 1px 0 rgba(242, 234, 220, 0.07);
  -webkit-mask-image: linear-gradient(105deg, #000 0%, #000 72%, transparent 100%);
  mask-image: linear-gradient(105deg, #000 0%, #000 72%, transparent 100%);
  pointer-events: none;
}

body.page-themen .themen-hero .page-hero__card::after {
  content: "";
  position: absolute;
  left: 0.55rem;
  top: 1.4rem;
  bottom: 1.4rem;
  width: 2px;
  z-index: -1;
  border-radius: 999px;
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(199, 155, 95, 0.9) 16%,
    rgba(217, 198, 166, 0.5) 58%,
    transparent 100%
  );
  pointer-events: none;
}

body.page-themen .themen-hero--overview .page-hero__card::before {
  inset: 0;
  -webkit-mask-image: none;
  mask-image: none;
  border: 1px solid rgba(214, 195, 163, 0.12);
  background:
    radial-gradient(ellipse 80% 70% at 18% 12%, rgba(199, 155, 95, 0.12), transparent 55%),
    linear-gradient(165deg, rgba(14, 24, 18, 0.74) 0%, rgba(18, 30, 24, 0.82) 100%);
}

body.page-themen .themen-hero .page-hero__brand {
  margin: 0 0 0.4rem;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3vw, 2.35rem);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: 0.02em;
  color: var(--gold-accent);
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.35);
}

body.page-themen .themen-hero .page-hero__card .eyebrow {
  margin: 0 0 0.65rem;
  opacity: 0.92;
}

body.page-themen .themen-hero .page-hero__card h1 {
  max-width: 14ch;
  margin: 0;
  font-size: clamp(1.55rem, 3.1vw, 2.35rem);
  line-height: 1.18;
  letter-spacing: -0.015em;
  color: var(--text-light);
  text-shadow: 0 2px 22px rgba(0, 0, 0, 0.28);
}

body.page-themen .themen-hero .page-hero__card .lead {
  max-width: 34rem;
  margin: 0.95rem 0 0;
  font-size: clamp(0.95rem, 1.35vw, 1.08rem);
  line-height: 1.62;
  color: rgba(242, 234, 220, 0.86);
}

body.page-themen .themen-hero .page-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin-top: 1.35rem;
}

body.page-themen .themen-hero .page-hero__actions .btn {
  min-width: 9.5rem;
  justify-content: center;
}

.themen-crumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
  margin: 0 0 0.7rem;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(200, 184, 160, 0.78);
}

.themen-crumb a {
  color: var(--gold-accent);
  text-decoration: none;
  border-bottom: 1px solid rgba(199, 155, 95, 0.35);
  transition: color 0.2s ease, border-color 0.2s ease;
}

.themen-crumb a:hover {
  color: var(--text-light);
  border-color: rgba(242, 234, 220, 0.45);
}

/* ── Overview: Jump strip ── */
.themen-jump {
  z-index: 2;
  padding-top: clamp(1.75rem, 4vw, 2.75rem);
  padding-bottom: clamp(1.75rem, 4vw, 2.75rem);
  border-bottom: 1px solid var(--page-line);
}

.themen-jump__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}

.themen-jump__list a {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0.95rem 1rem;
  border-radius: 1rem;
  border: 1px solid rgba(214, 195, 163, 0.14);
  background: linear-gradient(165deg, rgba(24, 38, 30, 0.55) 0%, rgba(16, 26, 20, 0.72) 100%);
  transition: border-color 0.25s ease, transform 0.25s ease, background 0.25s ease;
}

.themen-jump__list a:hover,
.themen-jump__list a:focus-visible {
  border-color: rgba(199, 155, 95, 0.45);
  transform: translateY(-2px);
  outline: none;
  background: linear-gradient(165deg, rgba(32, 50, 40, 0.7) 0%, rgba(20, 34, 26, 0.82) 100%);
}

.themen-jump__num {
  font-family: var(--font-heading);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--gold-accent);
}

.themen-jump__label {
  font-family: var(--font-display);
  font-size: clamp(1.05rem, 1.8vw, 1.25rem);
  color: var(--text-light);
}

/* ── Overview: alternating feature rail ── */
.themen-rail {
  position: relative;
  z-index: 2;
}

.themen-feature {
  position: relative;
  padding: clamp(3.5rem, 8vw, 6.5rem) 0;
  border-top: 1px solid rgba(214, 195, 163, 0.08);
}

.themen-feature--odd {
  background:
    radial-gradient(ellipse 55% 60% at 8% 40%, rgba(199, 155, 95, 0.08), transparent 55%),
    linear-gradient(180deg, rgba(14, 22, 18, 0.92) 0%, rgba(16, 26, 20, 0.95) 100%);
}

.themen-feature--even {
  background:
    radial-gradient(ellipse 50% 55% at 92% 45%, rgba(61, 122, 88, 0.12), transparent 50%),
    linear-gradient(180deg, rgba(18, 30, 24, 0.94) 0%, rgba(14, 22, 18, 0.96) 100%);
}

.themen-feature--featured {
  padding-top: clamp(4.5rem, 9vw, 7.5rem);
  padding-bottom: clamp(4.5rem, 9vw, 7.5rem);
  background:
    radial-gradient(ellipse 70% 55% at 20% 30%, rgba(199, 155, 95, 0.14), transparent 55%),
    linear-gradient(165deg, rgba(20, 34, 26, 0.96) 0%, rgba(12, 18, 15, 0.97) 100%);
}

.themen-feature__grid {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: clamp(1.75rem, 4.5vw, 3.75rem);
  align-items: center;
}

.themen-feature--even .themen-feature__grid {
  grid-template-columns: 1fr 1.15fr;
}

.themen-feature--even .themen-feature__visual {
  order: 2;
}

.themen-feature--even .themen-feature__copy {
  order: 1;
}

.themen-feature--featured .themen-feature__grid {
  grid-template-columns: 1.25fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
}

.themen-feature__visual {
  position: relative;
  display: block;
  border-radius: 1.6rem 1.1rem 1.9rem 1.25rem;
  overflow: hidden;
  border: 1px solid rgba(214, 195, 163, 0.16);
  box-shadow: 0 28px 60px rgba(4, 8, 6, 0.32);
  aspect-ratio: 5 / 4;
}

.themen-feature--featured .themen-feature__visual {
  aspect-ratio: 16 / 11;
  border-radius: 2rem 1.25rem 2.4rem 1.5rem;
}

.themen-feature__visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s ease;
}

.themen-feature__visual:hover img,
.themen-feature__visual:focus-visible img {
  transform: scale(1.04);
}

.themen-feature__index {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  line-height: 1;
  color: rgba(242, 234, 220, 0.88);
  text-shadow: 0 8px 28px rgba(0, 0, 0, 0.45);
  pointer-events: none;
}

.themen-feature__copy .eyebrow {
  margin-bottom: 0.75rem;
}

.themen-feature__copy h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3.2vw, 2.55rem);
  font-weight: 600;
  line-height: 1.18;
  color: var(--text-light);
}

.themen-feature__copy h2 a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.themen-feature__copy h2 a:hover,
.themen-feature__copy h2 a:focus-visible {
  color: var(--gold-accent);
  outline: none;
}

.themen-feature__lead {
  margin: 1rem 0 0;
  max-width: 34rem;
  color: var(--text-muted);
  font-size: clamp(1rem, 1.4vw, 1.1rem);
  line-height: 1.65;
}

.themen-feature__hints {
  list-style: none;
  margin: 1.35rem 0 0;
  padding: 0;
  max-width: 32rem;
}

.themen-feature__hints li {
  position: relative;
  padding: 0.55rem 0 0.55rem 1.2rem;
  color: rgba(242, 234, 220, 0.88);
  font-size: 0.96rem;
  line-height: 1.45;
  border-bottom: 1px solid rgba(214, 195, 163, 0.1);
}

.themen-feature__hints li:last-child {
  border-bottom: none;
}

.themen-feature__hints li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1rem;
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 50%;
  background: var(--gold-accent);
}

.themen-feature__cta {
  display: inline-flex;
  margin-top: 1.45rem;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.86rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-accent);
  border-bottom: 1px solid rgba(199, 155, 95, 0.4);
  padding-bottom: 0.15rem;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.themen-feature__cta:hover,
.themen-feature__cta:focus-visible {
  color: var(--text-light);
  border-color: rgba(242, 234, 220, 0.5);
  outline: none;
}

/* ── Detail split ── */
.themen-split {
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  gap: clamp(1.75rem, 4vw, 3.25rem);
  align-items: center;
}

.themen-split--reverse {
  grid-template-columns: 1.05fr 1fr;
}

.themen-split--reverse .themen-split__visual {
  order: 0;
}

.themen-split--reverse .themen-split__copy {
  order: 1;
}

.themen-figure {
  margin: 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--page-line);
  box-shadow: var(--shadow-proof);
}

.themen-figure img {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 11;
  object-fit: cover;
}

.themen-figure figcaption {
  padding: 0.7rem 1rem 0.9rem;
  font-size: 0.78rem;
  color: var(--text-muted);
  background: rgba(16, 24, 20, 0.92);
}

.themen-related {
  max-width: 40rem;
  margin: 0 auto;
  text-align: center;
}

.themen-related .page-statement__title {
  margin-bottom: 0.75rem;
}

.themen-related p {
  color: var(--text-muted);
  margin: 0 0 1.25rem;
}

.themen-more {
  max-width: 36rem;
  margin: 0 auto;
  text-align: center;
}

.themen-more ul {
  list-style: none;
  margin: 1rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.themen-more a {
  color: var(--gold-accent);
  font-family: var(--font-heading);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.themen-more a:hover {
  color: var(--text-light);
}

@media (max-width: 1100px) {
  .themen-overview-mosaic {
    width: min(24vw, 240px);
    right: 1rem;
  }
}

@media (max-width: 900px) {
  .themen-overview-mosaic {
    display: none;
  }

  .themen-jump__list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .themen-feature__grid,
  .themen-feature--even .themen-feature__grid,
  .themen-feature--featured .themen-feature__grid {
    grid-template-columns: 1fr;
    gap: 1.35rem;
  }

  .themen-feature--even .themen-feature__visual,
  .themen-feature--even .themen-feature__copy {
    order: unset;
  }

  .themen-feature__visual {
    aspect-ratio: 16 / 11;
  }

  .themen-split,
  .themen-split--reverse {
    grid-template-columns: 1fr;
  }

  .themen-split--reverse .themen-split__visual,
  .themen-split--reverse .themen-split__copy {
    order: unset;
  }

  .themen-hero--detail,
  .themen-hero--overview {
    min-height: auto;
    align-items: flex-end;
  }

  .themen-hero__photo img {
    object-position: center 30%;
  }

  body.page-themen .themen-hero .page-hero__card {
    max-width: 100%;
    border-radius: 1.5rem 1.1rem 1.75rem 1.2rem;
    padding-left: clamp(1.35rem, 4vw, 1.7rem);
  }

  body.page-themen .themen-hero .page-hero__card::before {
    inset: -0.2rem -0.6rem -0.2rem -0.2rem;
    -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 86%, transparent 100%);
    mask-image: linear-gradient(180deg, #000 0%, #000 86%, transparent 100%);
  }

  body.page-themen .themen-hero--overview .page-hero__card::before {
    inset: 0;
    -webkit-mask-image: none;
    mask-image: none;
  }

  body.page-themen .themen-hero .page-hero__card h1 {
    max-width: 16ch;
  }

  body.page-themen .themen-hero .page-hero__actions .btn {
    flex: 1 1 calc(50% - 0.4rem);
    min-width: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .themen-feature__visual img,
  .themen-jump__list a {
    transition: none;
  }

  .themen-jump__list a:hover,
  .themen-jump__list a:focus-visible {
    transform: none;
  }
}
