:root {
  --ek-blue: #0057a8;
  --ek-blue-dark: #00335c;
  --ek-blue-darker: #001f38;
  --ek-white: #ffffff;
  --ek-ink: #1c2733;
  --ek-bg-soft: #f4f7fb;
  --font-display: "Poppins", "Inter", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
}

body {
  font-family: var(--font-body);
  color: var(--ek-ink);
}

h1, h2, h3, h4, .navbar-brand, .ek-display {
  font-family: var(--font-display);
}

/* Navbar */
.ek-navbar {
  background-color: var(--ek-blue-dark);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08);
}

.ek-brand-logo {
  height: 28px;
  width: auto;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.4));
}

.navbar-brand span {
  font-weight: 700;
  letter-spacing: 0.02em;
}

.ek-navbar .nav-link {
  color: rgba(255, 255, 255, 0.85);
  font-weight: 500;
}

.ek-navbar .nav-link:hover,
.ek-navbar .nav-link:focus {
  color: #ffffff;
}

.ek-navbar .nav-link.active {
  color: #ffffff;
  position: relative;
}

.ek-navbar .nav-link.active::after {
  content: "";
  position: absolute;
  left: 0.5rem;
  right: 0.5rem;
  bottom: -2px;
  height: 2px;
  background: #ffffff;
  border-radius: 2px;
}

/* Hero */
.ek-hero {
  position: relative;
  color: #fff;
  background: linear-gradient(180deg, rgba(0, 31, 56, 0.78), rgba(0, 51, 92, 0.85)), url("/assets/img/hero.jpg") center 30% / cover no-repeat;
  padding: 5rem 0 4.5rem;
}

.ek-hero__logo {
  width: 150px;
  height: auto;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.45));
}

.ek-hero h1 {
  font-weight: 700;
  font-size: clamp(2rem, 4.5vw, 3.2rem);
}

.ek-hero .lead {
  font-size: 1.15rem;
  color: rgba(255, 255, 255, 0.92);
  max-width: 46rem;
}

/* Stat pills */
.ek-stat {
  background: var(--ek-white);
  border-radius: 0.75rem;
  padding: 1.5rem 1rem;
  box-shadow: 0 6px 20px rgba(0, 51, 92, 0.08);
  text-align: center;
  height: 100%;
}

.ek-stat__value {
  font-family: var(--font-display);
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--ek-blue);
  line-height: 1;
}

.ek-stat__label {
  color: #5b6b7c;
  margin-top: 0.35rem;
}

/* Section helpers */
.ek-section {
  padding: 4rem 0;
}

.ek-section--soft {
  background: var(--ek-bg-soft);
}

.ek-section-title {
  font-weight: 700;
  color: var(--ek-blue-dark);
}

.ek-kicker {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ek-blue);
}

/* Nächstes/letztes Spiel: schwebendes Info-Widget (Startseite), verlinkt zu spielplan.php */
.ek-next-match {
  display: block;
  position: static;
  margin: 1.5rem auto 0;
  width: fit-content;
  background: rgba(0, 51, 92, 0.85);
  color: #fff;
  padding: 0.6rem 1rem;
  border-radius: 0.75rem;
  text-align: center;
  box-shadow: 0 4px 16px rgba(0, 51, 92, 0.25);
  text-decoration: none;
  transition: background-color 0.2s ease;
}

.ek-next-match:hover,
.ek-next-match:focus-visible {
  background: rgba(0, 87, 168, 0.9);
  color: #fff;
}

.ek-next-match__block + .ek-next-match__block {
  margin-top: 0.5rem;
  padding-top: 0.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.ek-next-match__kicker {
  margin: 0 0 0.3rem;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.75);
}

.ek-next-match__teams {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
}

.ek-next-match__logo {
  width: 28px;
  height: 28px;
  object-fit: contain;
  background: #fff;
  border-radius: 50%;
  padding: 3px;
}

.ek-next-match__vs {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.6);
}

.ek-next-match__score {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.85rem;
}

.ek-next-match__date {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.85rem;
  line-height: 1.2;
}

.ek-next-match__time {
  margin: 0;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.75);
}

.ek-next-match__link {
  margin: 0.5rem 0 0;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: rgba(255, 255, 255, 0.8);
}

@media (min-width: 992px) {
  .ek-next-match {
    position: fixed;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    margin: 0;
    z-index: 1015;
    border-radius: 0.75rem 0 0 0.75rem;
    backdrop-filter: blur(3px);
  }
}

/* Spielplan */
.ek-fixture-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.ek-fixture {
  border: 1px solid #e6ebf1;
  border-radius: 0.75rem;
  padding: 0.85rem 1.25rem;
  background: #fff;
}

.ek-fixture--played {
  background: var(--ek-bg-soft);
}

.ek-fixture__meta {
  font-size: 0.75rem;
  color: #8b9bb0;
  margin-bottom: 0.4rem;
}

.ek-fixture__teams {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.ek-fixture__team {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  min-width: 0;
}

.ek-fixture__logo {
  width: 24px;
  height: 24px;
  object-fit: contain;
  flex-shrink: 0;
}

.ek-fixture__score {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--ek-blue-dark);
  min-width: 2.5em;
  text-align: center;
}

.ek-fixture__vs {
  color: #8b9bb0;
  min-width: 2.5em;
  text-align: center;
}

.ek-fixture__goals {
  margin-top: 0.5rem;
  font-size: 0.75rem;
  color: #5b6b7c;
  text-align: center;
}

@media (max-width: 575.98px) {
  .ek-fixture__teams {
    flex-direction: column;
    gap: 0.35rem;
  }
}

/* Blau-Weiße-Nacht-Overlay (Startseite) */
.ek-bwn-overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgba(0, 10, 20, 0.85);
  backdrop-filter: blur(2px);
}

.ek-bwn-overlay[hidden] {
  display: none;
}

.ek-bwn-overlay__card {
  position: relative;
  width: 100%;
  max-width: 640px;
  border-radius: 1rem;
  overflow: hidden;
  background: #000;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.ek-bwn-overlay__video-wrap {
  position: relative;
}

.ek-bwn-overlay__video {
  display: block;
  width: 100%;
  aspect-ratio: 854 / 480;
  object-fit: cover;
}

.ek-bwn-overlay__mute {
  position: absolute;
  bottom: 0.75rem;
  right: 0.75rem;
  z-index: 1;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.ek-bwn-overlay__mute:hover,
.ek-bwn-overlay__mute:focus-visible {
  background: rgba(255, 255, 255, 0.35);
}

.ek-bwn-overlay__body {
  padding: 1.5rem;
  text-align: center;
  color: #fff;
  background: var(--ek-blue-dark);
}

.ek-bwn-overlay__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.6rem;
  margin: 0 0 0.35rem;
}

.ek-bwn-overlay__text {
  margin: 0 0 1rem;
  opacity: 0.9;
}

.ek-bwn-overlay__close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 1;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.ek-bwn-overlay__close:hover,
.ek-bwn-overlay__close:focus-visible {
  background: rgba(255, 255, 255, 0.35);
}

@media (max-width: 480px) {
  .ek-bwn-overlay__title {
    font-size: 1.3rem;
  }
}

/* Zitat (z. B. auf Mitglied werden) */
.ek-quote {
  border-left: 3px solid var(--ek-blue);
  padding: 0.25rem 0 0.25rem 1.25rem;
  margin: 0;
}

.ek-quote p {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--ek-ink);
}

.ek-quote .blockquote-footer {
  font-size: 0.9rem;
}

/* Cards */
.ek-card {
  border: none;
  border-radius: 0.75rem;
  box-shadow: 0 6px 20px rgba(0, 51, 92, 0.08);
}

.ek-btn-primary {
  background-color: var(--ek-blue);
  border-color: var(--ek-blue);
}

.ek-btn-primary:hover,
.ek-btn-primary:focus {
  background-color: var(--ek-blue-dark);
  border-color: var(--ek-blue-dark);
}

/* Timeline (Historie) */
.ek-timeline {
  position: relative;
  padding-left: 2.25rem;
  border-left: 3px solid #d8e3f0;
}

.ek-timeline__item {
  position: relative;
  padding-bottom: 2.5rem;
}

.ek-timeline__item:last-child {
  padding-bottom: 0;
}

.ek-timeline__item::before {
  content: "";
  position: absolute;
  left: -2.55rem;
  top: 0.2rem;
  width: 1rem;
  height: 1rem;
  background: var(--ek-blue);
  border: 3px solid #fff;
  border-radius: 50%;
  box-shadow: 0 0 0 3px #d8e3f0;
}

.ek-timeline__year {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--ek-blue);
  font-size: 1.1rem;
}

/* Crest / symbol card */
.ek-crest {
  background: var(--ek-blue-dark);
  color: #fff;
  border-radius: 0.75rem;
  padding: 2rem;
}

/* Satzung */
.ek-toc {
  position: sticky;
  top: 5.5rem;
}

.ek-toc .nav-link {
  color: #45566a;
  padding: 0.3rem 0.6rem;
  border-radius: 0.4rem;
  font-size: 0.92rem;
}

.ek-toc .nav-link.active {
  background: var(--ek-blue);
  color: #fff;
}

.ek-paragraph {
  scroll-margin-top: 5.5rem;
  padding-bottom: 2.25rem;
  margin-bottom: 2.25rem;
  border-bottom: 1px solid #e6ebf1;
}

.ek-paragraph:last-child {
  border-bottom: none;
}

.ek-paragraph h2 {
  color: var(--ek-blue-dark);
  font-weight: 700;
  font-size: 1.3rem;
}

.ek-paragraph p,
.ek-paragraph li {
  color: #33404d;
}

.ek-avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  background: var(--ek-blue);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.6rem;
}

.ek-avatar-photo {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}

@media (max-width: 420px) {
  .ek-avatar,
  .ek-avatar-photo {
    width: 72px;
    height: 72px;
  }

  .ek-avatar {
    font-size: 1.3rem;
  }
}

/* Footer */
.ek-footer {
  background: var(--ek-blue-darker);
  color: rgba(255, 255, 255, 0.85);
}

.ek-social a {
  color: rgba(255, 255, 255, 0.75);
  display: inline-flex;
}

.ek-social a:hover,
.ek-social a:focus {
  color: #ffffff;
}

/* Mobile TOC improvements */
@media (max-width: 991.98px) {
  .ek-toc {
    position: static;
    margin-bottom: 1.5rem;
  }
  
  .ek-toc .card {
    padding: 0;
    box-shadow: none;
    border: none;
    border-radius: 0;
  }
  
  .ek-toc details {
    border: 1px solid var(--ek-border);
    border-radius: 0.5rem;
    overflow: hidden;
  }
  
  .ek-toc details summary {
    padding: 0.75rem 1rem;
    font-weight: 600;
    cursor: pointer;
    outline: none;
  }
  
  .ek-toc details summary::-webkit-details-marker {
    display: none;
  }
  
  .ek-toc details ul {
    margin: 0;
    padding: 0 0 0.75rem 0;
    list-style: none;
    border-top: 1px solid var(--ek-border);
  }
  
  .ek-toc details li {
    padding: 0.5rem 1rem;
  }
  
  .ek-toc details li a {
    color: #45566a;
    text-decoration: none;
  }
  
  .ek-toc details li a:hover {
    color: var(--ek-blue);
  }
}

/* IBAN input (Mitglied werden) */
.ek-iban-group {
  max-width: 30rem;
  flex-wrap: nowrap;
}

.ek-iban-prefix {
  font-family: var(--font-display);
  font-weight: 700;
  color: #5b6b7c;
  background: var(--ek-bg-soft);
  flex: 0 0 auto;
}

.ek-iban-block {
  text-align: center;
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0.04em;
  min-width: 0;
  flex: 1 1 0;
  padding-left: 0.25rem;
  padding-right: 0.25rem;
}

/* Bootstraps eingebaute Validierungsicons brauchen mehr Platz, als die schmalen
   Blöcke bieten (verdecken sonst die letzte Ziffer) – Randfarbe genügt als Signal,
   der Hinweistext darunter liefert den Rest. */
.ek-iban-block.is-invalid,
.ek-iban-block.is-valid {
  background-image: none;
  padding-right: 0.25rem;
}

.ek-iban-block.is-invalid {
  border-color: #d9534f;
}

.ek-iban-block.is-valid {
  border-color: #3c9a5f;
}

@media (max-width: 420px) {
  .ek-iban-group {
    max-width: none;
  }

  .ek-iban-block {
    font-size: 0.85rem;
    padding-left: 0.15rem;
    padding-right: 0.15rem;
  }
}

/* News cards */
.ek-news-meta {
  font-size: 0.85rem;
  color: #8b9bb0;
}

.ek-news-date {
  font-weight: 600;
}

.ek-news-author::before {
  content: "• ";
}

/* Navbar Links (Text, kein Icon) */
.navbar .nav-link {
  padding: 0.5rem 0.85rem !important;
  border-radius: 0.5rem;
  transition: background-color 0.2s ease, border-color 0.2s ease;
  border: 1px solid transparent;
}

@media (min-width: 1200px) {
  .navbar .nav-link {
    margin: 0 0.15rem;
    white-space: nowrap;
  }

  .navbar .nav-link:hover,
  .navbar .nav-link:focus-visible {
    background-color: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
  }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
  .navbar .nav-link {
    transition: none;
  }
}
/* Timeline (News) */
.ek-timeline {
  position: relative;
  padding-left: 1.5rem;
  border-left: 2px solid #d8e3f0;
}

.ek-timeline__item {
  position: relative;
  padding-bottom: 1.5rem;
}

.ek-timeline__item::before {
  content: "";
  position: absolute;
  left: -1.7rem;
  top: 0.4rem;
  width: 0.6rem;
  height: 0.6rem;
  background: var(--ek-blue);
  border: 2px solid #fff;
  border-radius: 50%;
  box-shadow: 0 0 0 2px #d8e3f0;
}

.ek-timeline__year {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--ek-blue);
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.ek-timeline__month {
  font-weight: 600;
  color: var(--ek-blue);
  margin-right: 0.3rem;
}

.ek-timeline__title {
  color: var(--ek-ink);
  transition: color 0.2s;
}

.ek-timeline__title:hover {
  color: var(--ek-blue);
}
