/* ==========================================================================
   LAYOUT CSS - Farbige Sektions-Räume, Header (einzeilig!), Grids & Footer
   ========================================================================== */

.l-container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-padding);
}

.l-container--narrow {
  max-width: 880px;
}

.l-section__header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: var(--space-lg);
  margin-bottom: var(--space-2xl);
}

.c-section-header__subtitle {
  margin-top: var(--space-xs);
  font-size: var(--text-md);
  color: var(--color-text-muted);
  max-width: 64ch;
}

.l-section--dark .c-section-header__subtitle {
  color: #cbd5e1;
}

.l-section {
  padding-block: var(--space-section);
  position: relative;
}

/* 1. Warmes Atelier-Sandstein (mit feiner architektonischer Punkt-Struktur) */
.l-section--sand {
  background-color: var(--color-bg);
  background-image:
    radial-gradient(rgba(15, 28, 54, 0.06) 1px, transparent 1px),
    linear-gradient(135deg, rgba(155, 44, 98, 0.035) 0%, rgba(29, 88, 232, 0.04) 100%);
  background-size: 24px 24px, 100% 100%;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

/* 2. Edles Schiefer-Blaugrau (Für das Fachbeitrags- & Publikations-Dossier) */
.l-section--dossier {
  background-color: var(--color-bg-cool);
  background-image:
    linear-gradient(180deg, rgba(15, 28, 54, 0.04) 0%, rgba(29, 88, 232, 0.06) 100%);
  border-top: 1px solid var(--color-border-cool);
  border-bottom: 1px solid var(--color-border-cool);
}

/* 3. Verlags-Edition (Warmes Pergament & Kupfer-Hauch für die Fachbücher) */
.l-section--books {
  background:
    radial-gradient(circle at 12% 20%, rgba(155, 44, 98, 0.07) 0%, transparent 45%),
    radial-gradient(circle at 88% 80%, rgba(223, 83, 32, 0.07) 0%, transparent 45%),
    var(--color-bg-warm);
  border-bottom: 1px solid var(--color-border);
}

/* 4. Tiefes Marine-Nachtblau (Seminare, E-Learning & Kongresse) */
.l-section--dark {
  background:
    radial-gradient(circle at 85% 12%, rgba(155, 44, 98, 0.25) 0%, transparent 42%),
    radial-gradient(circle at 15% 85%, rgba(29, 88, 232, 0.22) 0%, transparent 45%),
    var(--color-primary-dark);
  color: #f8fafc;
}

.l-section--dark h2,
.l-section--dark h3,
.l-section--dark h4 {
  color: #ffffff;
}

/* Sektions-Header */
.c-section-header {
  max-width: 980px;
  margin-bottom: var(--space-2xl);
}

.c-section-header--split {
  max-width: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: var(--space-lg);
}

.c-section-header__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--font-sans);
  font-size: var(--text-xs);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--color-berry);
  background: rgba(155, 44, 98, 0.09);
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-full);
  margin-bottom: var(--space-sm);
}

.l-section--dark .c-section-header__eyebrow {
  background: rgba(255, 255, 255, 0.1);
  color: #93c5fd;
}

.c-section-header__lead {
  margin-top: var(--space-sm);
  font-size: var(--text-md);
  color: var(--color-text-muted);
  max-width: 64ch;
}

.l-section--dark .c-section-header__lead {
  color: #cbd5e1;
}

/* ==========================================================================
   PITCH-BAR (Konzept- & Portrait-Umschalter)
   ========================================================================== */
.c-pitch-bar {
  background: #060d1a;
  color: #e2e8f0;
  font-size: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  padding-block: 0.45rem;
  position: relative;
  z-index: 200;
}

.c-pitch-bar__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
}

.c-pitch-bar__label {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-weight: 600;
  color: #94a3b8;
}

.c-pitch-bar__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.22);
}

.c-pitch-bar__controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.c-pitch-bar__group {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.3rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 0.2rem 0.45rem;
  border-radius: var(--radius-full);
}

.c-pitch-bar__group-title {
  font-size: 0.7rem;
  font-weight: 700;
  color: #94a3b8;
  padding-inline: 0.35rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.c-pitch-bar__btn {
  appearance: none;
  border: 1px solid transparent;
  background: transparent;
  color: #cbd5e1;
  font-family: var(--font-sans);
  font-size: 0.74rem;
  font-weight: 600;
  padding: 0.22rem 0.65rem;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.c-pitch-bar__btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

.c-pitch-bar__btn[data-set-theme][aria-pressed="true"] {
  background: var(--color-accent);
  border-color: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

.c-pitch-bar__btn[data-set-portrait][aria-pressed="true"] {
  background: #df5320;
  border-color: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

/* ==========================================================================
   HEADER & HAUPTNAVIGATION (Garantiert einzeilig & aufgeräumt!)
   ========================================================================== */
.c-header {
  position: sticky;
  top: 0;
  z-index: 150;
  background-color: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(15, 28, 54, 0.1);
  transition: box-shadow var(--transition-fast);
}

.c-header--scrolled {
  box-shadow: var(--shadow-card);
}

.c-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 5rem;
  gap: var(--space-md);
}

.c-header__brand {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}

.c-header__logo {
  height: 52px;
  width: auto;
  display: block;
  transition: height var(--transition-fast);
}

@media (max-width: 1024px) {
  .c-header__logo {
    height: 54px;
  }
}

.c-nav {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.c-nav__list {
  display: flex;
  align-items: center;
  gap: 0.2rem;
  list-style: none;
}

.c-nav__link {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--color-text-main);
  text-decoration: none;
  padding: 0.42rem 0.55rem;
  border-radius: var(--radius-sm);
  white-space: nowrap;
  position: relative;
  transition: color var(--transition-fast), background-color var(--transition-fast);
}

.c-nav__link:hover,
.c-nav__link[aria-current="page"] {
  color: var(--color-accent);
  background-color: var(--color-accent-soft);
}

.c-header__toggle {
  display: none;
  appearance: none;
  background: transparent;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 0.5rem;
  color: var(--color-primary);
  cursor: pointer;
}

@media (max-width: 1200px) {
  .c-header__toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .c-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    box-shadow: var(--shadow-hover);
    padding: var(--space-lg) var(--container-padding);
    flex-direction: column;
    align-items: stretch;
  }

  .c-nav.is-open {
    display: flex;
  }

  .c-nav__list {
    flex-direction: column;
    align-items: stretch;
  }

  .c-nav__link {
    display: block;
    padding: 0.7rem 0.5rem;
    font-size: var(--text-base);
  }
}

/* ==========================================================================
   GRID SYSTEME
   ========================================================================== */
.l-grid,
.l-grid-3,
.l-grid--3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-lg);
}

.l-grid-2,
.l-grid--2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-xl);
}

.l-grid > *,
.l-grid-3 > *,
.l-grid--3 > *,
.l-grid-2 > *,
.l-grid--2 > * {
  min-width: 0;
}

@media (max-width: 960px) {
  .l-grid,
  .l-grid-3,
  .l-grid--3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .l-grid-2,
  .l-grid--2 {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-lg);
  }
}

@media (max-width: 640px) {
  .l-grid,
  .l-grid-3,
  .l-grid--3 {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.c-footer {
  background-color: #060d1a;
  color: #cbd5e1;
  padding-top: var(--space-3xl);
  padding-bottom: var(--space-xl);
  font-size: var(--text-sm);
}

.c-footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1.3fr;
  gap: var(--space-2xl);
  padding-bottom: var(--space-2xl);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

@media (max-width: 900px) {
  .c-footer__grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 560px) {
  .c-footer__grid {
    grid-template-columns: 1fr;
  }
}

.c-footer__logo-wrap {
  display: inline-block;
  background: #ffffff;
  padding: 0.5rem 0.85rem;
  border-radius: var(--radius-sm);
  margin-bottom: var(--space-md);
}

.c-footer__brand {
  font-family: var(--font-heading);
  font-size: var(--text-base);
  font-weight: 700;
  color: #ffffff;
  margin-bottom: var(--space-sm);
  letter-spacing: -0.01em;
}

.c-footer__brand span {
  color: var(--color-terracotta);
}

.c-footer__title,
.c-footer__heading {
  color: #ffffff;
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: var(--space-md);
}

.c-footer__list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.c-footer__link,
.c-footer__list a {
  color: #cbd5e1;
  text-decoration: none;
}

.c-footer__link:hover,
.c-footer__list a:hover {
  color: #ffffff;
  text-decoration: underline;
}

.c-footer__bottom {
  padding-top: var(--space-lg);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-md);
  color: #94a3b8;
  font-size: var(--text-xs);
}
